diff --git a/.eslintignore b/.eslintignore index ce54730f4b..fba46e4328 100644 --- a/.eslintignore +++ b/.eslintignore @@ -21,3 +21,8 @@ src/v0/destinations/personalize/scripts/ test/integrations/destinations/testTypes.d.ts *.config*.js scripts/skipPrepareScript.js +*.yaml +*.yml +.eslintignore +.prettierignore +*.json diff --git a/.eslintrc.json b/.eslintrc.json index 556470697d..144b90e348 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -19,7 +19,8 @@ "parserOptions": { "ecmaVersion": 12, "sourceType": "module", - "project": "./tsconfig.json" + "project": "./tsconfig.json", + "extraFileExtensions": [".yaml"] }, "rules": { "unicorn/filename-case": [ diff --git a/.github/workflows/build-pr-artifacts.yml b/.github/workflows/build-pr-artifacts.yml index 9938563bf0..f6aaa18940 100644 --- a/.github/workflows/build-pr-artifacts.yml +++ b/.github/workflows/build-pr-artifacts.yml @@ -7,6 +7,10 @@ on: - reopened - synchronize +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: generate-tag-names: runs-on: ubuntu-latest diff --git a/.github/workflows/build-push-docker-image.yml b/.github/workflows/build-push-docker-image.yml index 0d3494e8d1..cffb5f91da 100644 --- a/.github/workflows/build-push-docker-image.yml +++ b/.github/workflows/build-push-docker-image.yml @@ -23,6 +23,15 @@ on: type: string build_type: type: string + use_merge_sha: + type: boolean + default: false + skip_tests: + type: boolean + default: false + description: if this option is true, we would skip tests while building docker image + workflow_url: + type: string secrets: DOCKERHUB_PROD_TOKEN: required: true @@ -31,27 +40,74 @@ env: DOCKERHUB_USERNAME: rudderlabs jobs: + get_sha: + runs-on: ubuntu-latest + name: Get SHA information + outputs: + sha: ${{steps.getSHA.outputs.SHA}} + steps: + - name: Checkout SHA + id: getSHA + run: | + if ${{inputs.use_merge_sha}} == true; then + sha=$(echo ${{github.sha}}) + else + sha=$(echo ${{ github.event.pull_request.head.sha }}) + fi + echo "SHA: $sha" + echo "SHA=$sha" >> $GITHUB_OUTPUT + + get_changed_files: + runs-on: ubuntu-latest + name: Get Changed files + outputs: + should_execute_tests: ${{ steps.processing.outputs.should_execute_tests }} + steps: + - name: Checkout + uses: actions/checkout@v4.1.1 + with: + fetch-depth: 1 + - id: files + uses: Ana06/get-changed-files@v1.2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + format: 'json' + - id: processing + run: | + readarray -t modified_files <<<"$(jq -r '.[]' <<<'${{ steps.files.outputs.modified }}')" + echo "Modified files: $modified_files" + found=false + for modified_file in "${modified_files[@]}"; do + if [[ "$modified_file" == "Dockerfile" || "$modified_file" == "docker-compose.yml" || "$modified_file" == "Dockerfile" || "$modified_file" == "Dockerfile-ut-func" ]]; then + found=true + break + fi + done + echo "Match Found: $found" + echo "::set-output name=should_execute_tests::$found" + build-transformer-image-arm64: name: Build Transformer Docker Image ARM64 runs-on: [self-hosted, Linux, ARM64] + needs: [get_sha, get_changed_files] steps: - name: Checkout uses: actions/checkout@v4.1.1 with: - ref: ${{ github.event.pull_request.head.sha }} + ref: ${{ needs.get_sha.outputs.sha }} fetch-depth: 1 - name: Setup Docker Buildx - uses: docker/setup-buildx-action@v3.0.0 + uses: docker/setup-buildx-action@v3.6.1 - name: Login to DockerHub - uses: docker/login-action@v2.1.0 + uses: docker/login-action@v3.3.0 with: username: ${{ env.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PROD_TOKEN }} - name: Build Docker Image - uses: docker/build-push-action@v5.1.0 + uses: docker/build-push-action@v6.7.0 with: context: . file: ${{ inputs.dockerfile }} @@ -62,12 +118,13 @@ jobs: # cache-to: type=gha,mode=max - name: Run Tests + if: ${{ inputs.skip_tests != true || needs.get_changed_files.outputs.should_execute_tests == true }} run: | docker run ${{ inputs.build_tag }} npm run test:js:ci docker run ${{ inputs.build_tag }} npm run test:ts:ci - name: Build and Push Multi-platform Images - uses: docker/build-push-action@v5.1.0 + uses: docker/build-push-action@v6.7.0 with: context: . file: ${{ inputs.dockerfile }} @@ -85,24 +142,25 @@ jobs: build-transformer-image-amd64: name: Build Transformer Docker Image AMD64 runs-on: [self-hosted, Linux, X64] + needs: [get_sha, get_changed_files] steps: - name: Checkout uses: actions/checkout@v4.1.1 with: - ref: ${{ github.event.pull_request.head.sha }} + ref: ${{ needs.get_sha.outputs.sha }} fetch-depth: 1 - name: Setup Docker Buildx - uses: docker/setup-buildx-action@v3.0.0 + uses: docker/setup-buildx-action@v3.6.1 - name: Login to DockerHub - uses: docker/login-action@v2.1.0 + uses: docker/login-action@v3.3.0 with: username: ${{ env.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PROD_TOKEN }} - name: Build Docker Image - uses: docker/build-push-action@v5.1.0 + uses: docker/build-push-action@v6.7.0 with: context: . file: ${{ inputs.dockerfile }} @@ -113,12 +171,13 @@ jobs: # cache-to: type=gha,mode=max - name: Run Tests + if: ${{ inputs.skip_tests != true || needs.get_changed_files.outputs.should_execute_tests == true }} run: | docker run ${{ inputs.build_tag }} npm run test:js:ci docker run ${{ inputs.build_tag }} npm run test:ts:ci - name: Build and Push Multi-platform Images - uses: docker/build-push-action@v5.1.0 + uses: docker/build-push-action@v6.7.0 with: context: . file: ${{ inputs.dockerfile }} @@ -140,10 +199,10 @@ jobs: steps: - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3.0.0 + uses: docker/setup-buildx-action@v3.6.1 - name: Login to DockerHub - uses: docker/login-action@v2.1.0 + uses: docker/login-action@v3.3.0 with: username: ${{ env.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PROD_TOKEN }} diff --git a/.github/workflows/check-pr-title.yml b/.github/workflows/check-pr-title.yml index 48098e276c..74c96d70ad 100644 --- a/.github/workflows/check-pr-title.yml +++ b/.github/workflows/check-pr-title.yml @@ -8,6 +8,10 @@ on: - reopened - synchronize +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: check-pr-title: name: Check PR Title diff --git a/.github/workflows/commitlint.yml b/.github/workflows/commitlint.yml index a8ff39eee0..7f6d068e15 100644 --- a/.github/workflows/commitlint.yml +++ b/.github/workflows/commitlint.yml @@ -2,6 +2,10 @@ name: Commitlint on: [push] +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: commitlint: runs-on: ubuntu-latest @@ -12,7 +16,7 @@ jobs: fetch-depth: 0 - name: Setup Node - uses: actions/setup-node@v4.0.1 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' diff --git a/.github/workflows/component-test-report.yml b/.github/workflows/component-test-report.yml index 3d457df9ff..02df1478d4 100644 --- a/.github/workflows/component-test-report.yml +++ b/.github/workflows/component-test-report.yml @@ -7,6 +7,10 @@ on: - reopened - synchronize +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + permissions: id-token: write # allows the JWT to be requested from GitHub's OIDC provider contents: read # This is required for actions/checkout @@ -28,7 +32,7 @@ jobs: fetch-depth: 1 - name: Setup Node - uses: actions/setup-node@v4.0.2 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' diff --git a/.github/workflows/draft-new-release.yml b/.github/workflows/draft-new-release.yml index 95431fef8e..82174d1d72 100644 --- a/.github/workflows/draft-new-release.yml +++ b/.github/workflows/draft-new-release.yml @@ -16,7 +16,7 @@ jobs: fetch-depth: 0 - name: Setup Node - uses: actions/setup-node@v4.0.2 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' diff --git a/.github/workflows/dt-test-and-report-code-coverage.yml b/.github/workflows/dt-test-and-report-code-coverage.yml index 4375b3383e..85625a1558 100644 --- a/.github/workflows/dt-test-and-report-code-coverage.yml +++ b/.github/workflows/dt-test-and-report-code-coverage.yml @@ -8,11 +8,27 @@ on: pull_request: types: ['opened', 'reopened', 'synchronize'] +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: + get_workflow_url: + runs-on: ubuntu-latest + steps: + - id: get_url + run: | + curl -s https://api.github.com/repos/${{ github.repository }}/actions/workflows/${{ github.workflow }}/runs/${{ github.run_id }} | jq -r .html_url >> workflow_url.txt + echo "::set-output name=workflow_url::$(cat workflow_url.txt)" + outputs: + url: ${{ steps.get_url.outputs.workflow_url }} + coverage: name: Code Coverage runs-on: ubuntu-latest - + needs: [get_workflow_url] + outputs: + tests_run_outcome: ${{steps.run_tests.outcome}} steps: - name: Checkout uses: actions/checkout@v4.1.1 @@ -20,7 +36,7 @@ jobs: fetch-depth: 1 - name: Setup Node - uses: actions/setup-node@v4.0.2 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' @@ -29,6 +45,8 @@ jobs: run: npm ci - name: Run Tests + id: run_tests + continue-on-error: true run: | # Supress logging in tests LOG_LEVEL=100 npm run test:js:ci @@ -62,7 +80,17 @@ jobs: - name: SonarCloud Scan if: always() - uses: SonarSource/sonarcloud-github-action@v2.1.1 + uses: SonarSource/sonarcloud-github-action@v3.0.0 env: GITHUB_TOKEN: ${{ secrets.PAT }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + + notify: + name: slack notification on failure + needs: [get_workflow_url, coverage] + if: needs.coverage.outputs.tests_run_outcome == 'failure' || failure() + uses: ./.github/workflows/slack-notify.yml + with: + workflow_url: ${{ needs.get_workflow_url.outputs.url }} + should_notify: ${{startsWith(github.event.pull_request.head.ref, 'hotfix-release/')}} + secrets: inherit diff --git a/.github/workflows/prepare-for-dev-deploy.yml b/.github/workflows/prepare-for-dev-deploy.yml index 9eb705aa52..a1fdda8ccd 100644 --- a/.github/workflows/prepare-for-dev-deploy.yml +++ b/.github/workflows/prepare-for-dev-deploy.yml @@ -10,6 +10,10 @@ on: branches: - develop +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: report-coverage: name: Report Code Coverage @@ -56,6 +60,7 @@ jobs: dockerfile: Dockerfile load_target: development push_target: production + use_merge_sha: true secrets: DOCKERHUB_PROD_TOKEN: ${{ secrets.DOCKERHUB_PROD_TOKEN }} diff --git a/.github/workflows/prepare-for-prod-dt-deploy.yml b/.github/workflows/prepare-for-prod-dt-deploy.yml index fedbac8ba1..8e589f5b20 100644 --- a/.github/workflows/prepare-for-prod-dt-deploy.yml +++ b/.github/workflows/prepare-for-prod-dt-deploy.yml @@ -10,6 +10,10 @@ on: branches: - main +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: report-coverage: name: Report Code Coverage @@ -53,6 +57,8 @@ jobs: load_target: development push_target: production build_type: dt + use_merge_sha: true + skip_tests: ${{startsWith(github.event.pull_request.head.ref, 'hotfix-release/')}} secrets: DOCKERHUB_PROD_TOKEN: ${{ secrets.DOCKERHUB_PROD_TOKEN }} diff --git a/.github/workflows/prepare-for-prod-ut-deploy.yml b/.github/workflows/prepare-for-prod-ut-deploy.yml index a6f7271d9c..468307b94a 100644 --- a/.github/workflows/prepare-for-prod-ut-deploy.yml +++ b/.github/workflows/prepare-for-prod-ut-deploy.yml @@ -10,6 +10,10 @@ on: branches: - main +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: report-coverage: name: Report Code Coverage @@ -56,6 +60,8 @@ jobs: load_target: development push_target: production build_type: ut + use_merge_sha: true + skip_tests: ${{startsWith(github.event.pull_request.head.ref, 'hotfix-release/')}} secrets: DOCKERHUB_PROD_TOKEN: ${{ secrets.DOCKERHUB_PROD_TOKEN }} diff --git a/.github/workflows/prepare-for-staging-deploy.yml b/.github/workflows/prepare-for-staging-deploy.yml index 46cd731d19..60a6238aa8 100644 --- a/.github/workflows/prepare-for-staging-deploy.yml +++ b/.github/workflows/prepare-for-staging-deploy.yml @@ -9,6 +9,10 @@ on: branches: - main +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: generate-tag-names: runs-on: ubuntu-latest @@ -48,6 +52,7 @@ jobs: dockerfile: Dockerfile load_target: development push_target: production + use_merge_sha: true secrets: DOCKERHUB_PROD_TOKEN: ${{ secrets.DOCKERHUB_PROD_TOKEN }} diff --git a/.github/workflows/publish-new-release.yml b/.github/workflows/publish-new-release.yml index 15d7b20fd1..ee9f28e235 100644 --- a/.github/workflows/publish-new-release.yml +++ b/.github/workflows/publish-new-release.yml @@ -30,7 +30,7 @@ jobs: fetch-depth: 0 - name: Setup Node - uses: actions/setup-node@v4.0.2 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' @@ -89,7 +89,7 @@ jobs: - name: Notify Slack Channel id: slack - uses: slackapi/slack-github-action@v1.25.0 + uses: slackapi/slack-github-action@v1.27.0 continue-on-error: true env: SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} diff --git a/.github/workflows/slack-notify.yml b/.github/workflows/slack-notify.yml new file mode 100644 index 0000000000..1c5dbdbc06 --- /dev/null +++ b/.github/workflows/slack-notify.yml @@ -0,0 +1,51 @@ +name: Notify workflow failure + +on: + workflow_call: + inputs: + should_notify: + type: boolean + default: true + workflow_url: + type: string + required: true + +jobs: + notify: + runs-on: ubuntu-latest + if: ${{ inputs.should_notify }} + steps: + - name: Checkout + uses: actions/checkout@v4.1.1 + + - name: notify + uses: slackapi/slack-github-action@v1.27.0 + continue-on-error: true + env: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + PROJECT_NAME: 'Rudder Transformer' + with: + channel-id: ${{ secrets.SLACK_INTEGRATION_DEV_CHANNEL_ID }} + payload: | + { + "text": "**\nCC: ", + "blocks": [ + { + "type": "header", + "text": { + "type": "plain_text", + "text": ":siren2: prod release tests - Failed :siren2:" + } + }, + { + "type": "divider" + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "*<${{inputs.workflow_url}}|failed workflow>*\nCC: " + } + } + ] + } diff --git a/.github/workflows/ut-tests.yml b/.github/workflows/ut-tests.yml index 0a2ef8a390..b825bdb9d3 100644 --- a/.github/workflows/ut-tests.yml +++ b/.github/workflows/ut-tests.yml @@ -7,13 +7,17 @@ on: - reopened - synchronize +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: ut_tests: name: UT Tests runs-on: ubuntu-latest steps: - name: Setup Go - uses: actions/setup-go@v5.0.0 + uses: actions/setup-go@v5.0.2 with: go-version: 1.17 @@ -26,7 +30,7 @@ jobs: fetch-depth: 1 - name: Setup Node - uses: actions/setup-node@v4.0.2 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' @@ -62,6 +66,18 @@ jobs: --set gateway.image=rudderlabs/rudder-openfaas-gateway:0.25.2 \ --set faasnetes.image=rudderlabs/rudder-openfaas-faas-netes:0.15.4 + - name: Create regcred secret in openfaas + run: kubectl create secret docker-registry regcred --docker-server=https://index.docker.io/v1/ --docker-username=${{ secrets.DOCKERHUB_USERNAME }} --docker-password=${{ secrets.DOCKERHUB_TOKEN }} --docker-email=${{ secrets.DOCKERHUB_EMAIL }} -n openfaas + + - name: Create regcred secret in openfaas-fn + run: kubectl create secret docker-registry regcred --docker-server=https://index.docker.io/v1/ --docker-username=${{ secrets.DOCKERHUB_USERNAME }} --docker-password=${{ secrets.DOCKERHUB_TOKEN }} --docker-email=${{ secrets.DOCKERHUB_EMAIL }} -n openfaas-fn + + - name: Patch default service account in openfaas-fn + run: 'kubectl patch serviceaccount default -n openfaas-fn -p ''{"imagePullSecrets": [{"name": "regcred"}]}''' + + - name: Patch deployment "gateway" + run: 'kubectl patch deployment gateway -n openfaas -p ''{"spec": {"template": {"spec": {"imagePullSecrets": [{"name": "regcred"}]}}}}''' + - name: Wait for deployment "gateway" rollout run: kubectl rollout status deploy/gateway --timeout 120s -n openfaas diff --git a/.github/workflows/verify-server-start.yml b/.github/workflows/verify-server-start.yml index 6ac5b7be05..f87ed57eb8 100644 --- a/.github/workflows/verify-server-start.yml +++ b/.github/workflows/verify-server-start.yml @@ -4,6 +4,10 @@ on: pull_request: types: ['opened', 'reopened', 'synchronize'] +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: check-health: runs-on: ubuntu-latest @@ -15,7 +19,7 @@ jobs: fetch-depth: 1 - name: Setup Node - uses: actions/setup-node@v4.0.2 + uses: actions/setup-node@v4.0.3 with: node-version-file: '.nvmrc' cache: 'npm' diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml index 4caef8dd91..0d389f0e55 100644 --- a/.github/workflows/verify.yml +++ b/.github/workflows/verify.yml @@ -3,6 +3,10 @@ name: Verify on: pull_request: +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.sha }} + cancel-in-progress: true + jobs: formatting-lint: name: Check for formatting & lint errors @@ -16,7 +20,7 @@ jobs: ref: ${{ github.head_ref }} - name: Setup Node - uses: actions/setup-node@v3.7.0 + uses: actions/setup-node@v4.0.3 with: node-version-file: .nvmrc cache: 'npm' @@ -24,13 +28,29 @@ jobs: - name: Install Dependencies run: npm ci - - name: Run Lint Checks + - id: files + uses: Ana06/get-changed-files@v1.2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + + - name: Run format Checks + run: | + npx prettier ${{steps.files.outputs.added_modified}} --write + + - run: git diff --exit-code + + - name: Formatting Error message + if: ${{ failure() }} + run: | + echo 'prettier formatting failure. Ensure you run `npm run format` and commit the files.' + + - name: Run eslint Checks run: | - npm run lint + npx eslint ${{steps.files.outputs.added_modified}} --fix - run: git diff --exit-code - - name: Error message + - name: Eslint Error message if: ${{ failure() }} run: | - echo 'Eslint check is failing Ensure you have run `npm run lint` and committed the files locally.' + echo 'Eslint failure. Ensure you run `npm run lint:fix` and commit the files.' diff --git a/.husky/commit-msg b/.husky/commit-msg index 9db017095e..84dc58a421 100755 --- a/.husky/commit-msg +++ b/.husky/commit-msg @@ -1,4 +1,2 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" npm run commit-msg diff --git a/.husky/pre-commit b/.husky/pre-commit index d4a43dd13e..af964838e1 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,4 +1,2 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" npm run pre-commit diff --git a/.prettierignore b/.prettierignore index 99747b29bb..ac5f1fc409 100644 --- a/.prettierignore +++ b/.prettierignore @@ -8,3 +8,5 @@ test/**/*.js src/util/lodash-es-core.js src/util/url-search-params.min.js dist +.eslintignore +.prettierignore diff --git a/.vscode/settings.json b/.vscode/settings.json index 13c49c08f1..8d723306a9 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -13,6 +13,10 @@ "editor.defaultFormatter": "esbenp.prettier-vscode", "editor.formatOnSave": true }, + "[json]": { + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true + }, "[yaml]": { "editor.defaultFormatter": "esbenp.prettier-vscode", "editor.formatOnSave": true diff --git a/CHANGELOG.md b/CHANGELOG.md index 3b01182c27..0ec77cc89e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,145 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +### [1.76.1](https://github.com/rudderlabs/rudder-transformer/compare/v1.76.0...v1.76.1) (2024-08-29) + + +### Bug Fixes + +* reddit authorisation failed case handling ([#3690](https://github.com/rudderlabs/rudder-transformer/issues/3690)) ([f24759a](https://github.com/rudderlabs/rudder-transformer/commit/f24759aebbeb560f0de9d4920ae2ed0cdc7bfa3f)) + +## [1.76.0](https://github.com/rudderlabs/rudder-transformer/compare/v1.75.1...v1.76.0) (2024-08-20) + + +### Features + +* klaviyo onboard unsubscribe profile support ([#3646](https://github.com/rudderlabs/rudder-transformer/issues/3646)) ([474f2bd](https://github.com/rudderlabs/rudder-transformer/commit/474f2bddc58e1962206e39d92514827f29f84c83)) +* onboard sfmc with vdm for rETL ([#3655](https://github.com/rudderlabs/rudder-transformer/issues/3655)) ([d987d1f](https://github.com/rudderlabs/rudder-transformer/commit/d987d1fc9afb9e1dc7482b2fe1458573f0f2699e)) +* onboard smartly destination ([#3660](https://github.com/rudderlabs/rudder-transformer/issues/3660)) ([474a36e](https://github.com/rudderlabs/rudder-transformer/commit/474a36ec385abf9ff83596b062d4d8e4c24469b8)) +* add bloomreach retl support ([#3619](https://github.com/rudderlabs/rudder-transformer/issues/3619)) ([6b1a23a](https://github.com/rudderlabs/rudder-transformer/commit/6b1a23af845084d6f2f5fd14656e4a1d11a7e34b)) + + +### Bug Fixes + +* add alias support in case alias details are present ([#3579](https://github.com/rudderlabs/rudder-transformer/issues/3579)) ([cb67262](https://github.com/rudderlabs/rudder-transformer/commit/cb672628b312f20ea0fcc27a60ec8ab5692f8b06)) +* attentive tag bugsnag issue ([#3663](https://github.com/rudderlabs/rudder-transformer/issues/3663)) ([866dbf3](https://github.com/rudderlabs/rudder-transformer/commit/866dbf3e81754e71ff8ac08b258b359ec5cc6889)) +* fixing facebook utils ([#3664](https://github.com/rudderlabs/rudder-transformer/issues/3664)) ([1a61675](https://github.com/rudderlabs/rudder-transformer/commit/1a6167584a5780ab50beda13cc5ef6bf4e283e38)) +* reserved properties for braze ([#3573](https://github.com/rudderlabs/rudder-transformer/issues/3573)) ([413e9ce](https://github.com/rudderlabs/rudder-transformer/commit/413e9ce56f8f6569bbeb188bff4f43d400ea71b1)) +* source transformation integration test generation ([#3645](https://github.com/rudderlabs/rudder-transformer/issues/3645)) ([23196ec](https://github.com/rudderlabs/rudder-transformer/commit/23196ec42acf35f314e1953f339f6acbb72edd70)) + +### [1.75.1](https://github.com/rudderlabs/rudder-transformer/compare/v1.75.0...v1.75.1) (2024-08-14) + + +### Bug Fixes + +* add validation for concurrent_modification error ([#3654](https://github.com/rudderlabs/rudder-transformer/issues/3654)) ([62cdc46](https://github.com/rudderlabs/rudder-transformer/commit/62cdc4641d44d79e21949722660173df4c749f24)) +* clevertap bugsnag issue ([#3656](https://github.com/rudderlabs/rudder-transformer/issues/3656)) ([6c51487](https://github.com/rudderlabs/rudder-transformer/commit/6c51487183b6b0b755620aac6cd51c2ffc966102)) +* snapchat conversion bugsnag issue ([#3657](https://github.com/rudderlabs/rudder-transformer/issues/3657)) ([31b03fc](https://github.com/rudderlabs/rudder-transformer/commit/31b03fc022ace0cda8df798c50e4764a9703c23b)) +* validation for iterable object of HS ([#3653](https://github.com/rudderlabs/rudder-transformer/issues/3653)) ([1cb3f86](https://github.com/rudderlabs/rudder-transformer/commit/1cb3f86c894f30bdf04df870484c6df3a956f36e)) + +## [1.75.0](https://github.com/rudderlabs/rudder-transformer/compare/v1.74.1...v1.75.0) (2024-08-12) + + +### Features + +* move hubspot to transformer proxy to enable partial batch handling ([#3308](https://github.com/rudderlabs/rudder-transformer/issues/3308)) ([8450021](https://github.com/rudderlabs/rudder-transformer/commit/8450021672c51ac798ec0aeab422f5fceea5e53e)) + + +### Bug Fixes + +* handle attentive tag null, undefined properties ([#3647](https://github.com/rudderlabs/rudder-transformer/issues/3647)) ([9327925](https://github.com/rudderlabs/rudder-transformer/commit/932792561c98833baf9881a83ee36ae5000e37b4)) +* handle null values for braze dedupe ([#3638](https://github.com/rudderlabs/rudder-transformer/issues/3638)) ([0a9b681](https://github.com/rudderlabs/rudder-transformer/commit/0a9b68118241158623d45ee28896377296bafd91)) + +### [1.74.1](https://github.com/rudderlabs/rudder-transformer/compare/v1.74.0...v1.74.1) (2024-08-08) + + +### Bug Fixes + +* sendgrid read root traits ([#3642](https://github.com/rudderlabs/rudder-transformer/issues/3642)) ([5acad70](https://github.com/rudderlabs/rudder-transformer/commit/5acad707d3125f3d50380d886f5fecb1406836cd)) + +## [1.74.0](https://github.com/rudderlabs/rudder-transformer/compare/v1.73.1...v1.74.0) (2024-08-05) + + +### Features + +* detach user and company in intercom identify call ([#3580](https://github.com/rudderlabs/rudder-transformer/issues/3580)) ([286c44a](https://github.com/rudderlabs/rudder-transformer/commit/286c44a47e8451486bde281b8c938df59945cdfc)) +* onboard new api for klaviyo 15-06-2024 ([#3574](https://github.com/rudderlabs/rudder-transformer/issues/3574)) ([44baab9](https://github.com/rudderlabs/rudder-transformer/commit/44baab9298d171efe1209b3ec360d15e84a4190c)) +* supporting device token type using integrations object ([#3620](https://github.com/rudderlabs/rudder-transformer/issues/3620)) ([14e776e](https://github.com/rudderlabs/rudder-transformer/commit/14e776e659b745c814d31cd049fc4051c1e6735d)) +* updated examples for swagger ([#3526](https://github.com/rudderlabs/rudder-transformer/issues/3526)) ([5e22fa0](https://github.com/rudderlabs/rudder-transformer/commit/5e22fa0555b98e83ca1b11f16e87f367d1f85ca8)) + + +### Bug Fixes + +* customerio page undefined name ([#3613](https://github.com/rudderlabs/rudder-transformer/issues/3613)) ([adc2a4a](https://github.com/rudderlabs/rudder-transformer/commit/adc2a4a6650c9d9add26be51999f5b3078c59f15)) +* facebook conversion version upgrade ([#3607](https://github.com/rudderlabs/rudder-transformer/issues/3607)) ([9d06546](https://github.com/rudderlabs/rudder-transformer/commit/9d065467f376a047d1cebb095de0b33be6e32206)) +* fb custom audience version upgrade from v18 to v20 ([#3604](https://github.com/rudderlabs/rudder-transformer/issues/3604)) ([c2d7555](https://github.com/rudderlabs/rudder-transformer/commit/c2d7555dcea5e476f276eec5926d392f58dbd7fa)) +* fb pixel and fb app events version upgrade ([#3606](https://github.com/rudderlabs/rudder-transformer/issues/3606)) ([7caf476](https://github.com/rudderlabs/rudder-transformer/commit/7caf4762be2c527725a2bdfb090a626d40723c36)) +* rakuten for amount list ([#3612](https://github.com/rudderlabs/rudder-transformer/issues/3612)) ([2fb7e6b](https://github.com/rudderlabs/rudder-transformer/commit/2fb7e6b4bc2b7524f6fa86a54596f7c6550fa51a)) +* shopify: incorporate new shopify cart token format ([#3626](https://github.com/rudderlabs/rudder-transformer/issues/3626)) ([0d3c042](https://github.com/rudderlabs/rudder-transformer/commit/0d3c0426571f14e88b5b8a703065935713ce8198)) + +### [1.73.1](https://github.com/rudderlabs/rudder-transformer/compare/v1.73.0...v1.73.1) (2024-08-02) + + +### Bug Fixes + +* update getAuthErrCategory and update error message for garl ([#3629](https://github.com/rudderlabs/rudder-transformer/issues/3629)) ([feadfcf](https://github.com/rudderlabs/rudder-transformer/commit/feadfcf6009ccc9b972634347448ba9428696ebb)) + +## [1.73.0](https://github.com/rudderlabs/rudder-transformer/compare/v1.72.2...v1.73.0) (2024-07-31) + + +### Features + + +### Bug Fixes + + +### [1.72.4](https://github.com/rudderlabs/rudder-transformer/compare/v1.72.3...v1.72.4) (2024-07-25) + + +### Bug Fixes + +* added support for ga4 v2 hybrid mode ([#3586](https://github.com/rudderlabs/rudder-transformer/issues/3586)) ([dedca07](https://github.com/rudderlabs/rudder-transformer/commit/dedca0796ee12478d57e020ef3c254afabc6e105)) + +### [1.72.3](https://github.com/rudderlabs/rudder-transformer/compare/v1.72.2...v1.72.3) (2024-07-24) + + +### Bug Fixes + +* add validation for cordial destination ([#3599](https://github.com/rudderlabs/rudder-transformer/issues/3599)) ([b7860a5](https://github.com/rudderlabs/rudder-transformer/commit/b7860a5b2b87fb61aaff8c68a904ac996d63efd3)) +* update getConversionActionId function for gaoc ([#3594](https://github.com/rudderlabs/rudder-transformer/issues/3594)) ([68367f5](https://github.com/rudderlabs/rudder-transformer/commit/68367f5227c96f2700a773018b991b1e87a0774d)) + +### [1.72.2](https://github.com/rudderlabs/rudder-transformer/compare/v1.72.1...v1.72.2) (2024-07-23) + +### [1.72.1](https://github.com/rudderlabs/rudder-transformer/compare/v1.72.0...v1.72.1) (2024-07-23) + + +### Bug Fixes + +* garl get auth err category ([#3590](https://github.com/rudderlabs/rudder-transformer/issues/3590)) ([475ebc1](https://github.com/rudderlabs/rudder-transformer/commit/475ebc104c69a52eaa425a9ed564ea9aca1ecd9c)) + +## [1.72.0](https://github.com/rudderlabs/rudder-transformer/compare/v1.71.3...v1.72.0) (2024-07-22) + + +### Features + +* add support for subscribing for RETL flow ([#3195](https://github.com/rudderlabs/rudder-transformer/issues/3195)) ([cc56004](https://github.com/rudderlabs/rudder-transformer/commit/cc560044ceb769da1f0090da4f690933552b6347)) +* braze source event mapping ([#3527](https://github.com/rudderlabs/rudder-transformer/issues/3527)) ([e357141](https://github.com/rudderlabs/rudder-transformer/commit/e357141d22e5296b6d1cda2e763ac24abfcb66e6)) +* introduces new user fields in titkok ads ([#3575](https://github.com/rudderlabs/rudder-transformer/issues/3575)) ([6304abb](https://github.com/rudderlabs/rudder-transformer/commit/6304abb2346f331b78e927b73e7c2ca17e94f4cf)) +* onboard cordial destination ([#3581](https://github.com/rudderlabs/rudder-transformer/issues/3581)) ([fbcdcd6](https://github.com/rudderlabs/rudder-transformer/commit/fbcdcd609888150efa0da33eec60a4cc7b436d06)) +* onboarding new destination zoho ([#3555](https://github.com/rudderlabs/rudder-transformer/issues/3555)) ([20aa7f3](https://github.com/rudderlabs/rudder-transformer/commit/20aa7f35e13ad89e8a43fbbb743df73b0c103975)), closes [#3566](https://github.com/rudderlabs/rudder-transformer/issues/3566) +* update webhook destination to support all datatypes ([#3541](https://github.com/rudderlabs/rudder-transformer/issues/3541)) ([448f574](https://github.com/rudderlabs/rudder-transformer/commit/448f57484c57d4a55147e9566149c8b714a191c9)) + + +### Bug Fixes + +* add optional chaining to webengage page event ([#3570](https://github.com/rudderlabs/rudder-transformer/issues/3570)) ([20205d6](https://github.com/rudderlabs/rudder-transformer/commit/20205d66298f5633d3971888f0866db2c38a50e2)) +* add validation for type in google pubsub ([#3578](https://github.com/rudderlabs/rudder-transformer/issues/3578)) ([1bef212](https://github.com/rudderlabs/rudder-transformer/commit/1bef2126a75324598c2af0ecaffcf582f038af11)) +* adding readiness probe annotations for openfaas ([#3529](https://github.com/rudderlabs/rudder-transformer/issues/3529)) ([2eb92e3](https://github.com/rudderlabs/rudder-transformer/commit/2eb92e3332ef0e8b2f83621fe0130fbc1356fa91)) +* **gainsight:** replace myAxios utility with handleHttpRequest utility ([#3241](https://github.com/rudderlabs/rudder-transformer/issues/3241)) ([04be1aa](https://github.com/rudderlabs/rudder-transformer/commit/04be1aaf438f824ddf61fc2f4d13eb7d8a223a9d)) +* job ordering for hs ([#3319](https://github.com/rudderlabs/rudder-transformer/issues/3319)) ([f840d54](https://github.com/rudderlabs/rudder-transformer/commit/f840d54dcbdc011eeb716dce74f2ecb36e99d0e9)) +* update authErrorCategory for 2 step verification issue for google ads destinations ([#3552](https://github.com/rudderlabs/rudder-transformer/issues/3552)) ([5a0392e](https://github.com/rudderlabs/rudder-transformer/commit/5a0392ee24301486b7973531be28f8178ef03eab)) +* update python transformation fn ([#3491](https://github.com/rudderlabs/rudder-transformer/issues/3491)) ([f363f35](https://github.com/rudderlabs/rudder-transformer/commit/f363f3512f690e0745165f46587efdbe88f48683)) + ### [1.71.3](https://github.com/rudderlabs/rudder-transformer/compare/v1.71.2...v1.71.3) (2024-07-15) diff --git a/CODEOWNERS b/CODEOWNERS index 274166f613..702a461d92 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -7,5 +7,5 @@ src/features.json @rudderlabs/integrations constants/ @rudderlabs/integrations warehouse/ @rudderlabs/warehouse src/util/ @rudderlabs/integrations @rudderlabs/data-management -*/trackingPlan.ts @rudderlabs/data-management -*/userTransform.ts @rudderlabs/data-management +**/trackingPlan.ts @rudderlabs/data-management +**/userTransform.ts @rudderlabs/data-management diff --git a/go/.gitignore b/go/.gitignore new file mode 100644 index 0000000000..d1147c6492 --- /dev/null +++ b/go/.gitignore @@ -0,0 +1,2 @@ +go.work +go.work.sum \ No newline at end of file diff --git a/go/README.md b/go/README.md new file mode 100644 index 0000000000..5286119183 --- /dev/null +++ b/go/README.md @@ -0,0 +1,23 @@ +# GO libraries + +## webhook/testdata + +To generate the test files use: + +```bash +go generate ./... +``` + +Work against local rudder-server: + +```bash +go work init +go work use . +go work use ../../rudder-server +``` + +Then run the webhook tests: + +```bash +go test github.com/rudderlabs/rudder-server/gateway/webhook -count 1 -timeout 2m +``` diff --git a/go/go.mod b/go/go.mod new file mode 100644 index 0000000000..26ebf86140 --- /dev/null +++ b/go/go.mod @@ -0,0 +1,11 @@ +module github.com/rudderlabs/rudder-transformer/go + +go 1.22.4 + +require github.com/stretchr/testify v1.9.0 + +require ( + github.com/davecgh/go-spew v1.1.1 // indirect + github.com/pmezard/go-difflib v1.0.0 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect +) diff --git a/go/go.sum b/go/go.sum new file mode 100644 index 0000000000..60ce688a04 --- /dev/null +++ b/go/go.sum @@ -0,0 +1,10 @@ +github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/go/webhook/testcases/testcases.go b/go/webhook/testcases/testcases.go new file mode 100644 index 0000000000..1810fed7b8 --- /dev/null +++ b/go/webhook/testcases/testcases.go @@ -0,0 +1,99 @@ +package testcases + +import ( + "embed" + "encoding/json" + "io/fs" + "testing" + "time" + + "github.com/stretchr/testify/require" +) + +type Setup struct { + Context Context + Cases []Case +} + +type Context struct { + Now time.Time + RequestIP string `json:"request_ip"` +} + +type Case struct { + Name string + Description string + Skip string + Input Input + Output Output +} + +type Input struct { + Request Request +} +type Request struct { + Method string + RawQuery string `json:"query_parameters"` + Headers map[string]string + Body json.RawMessage +} + +type Output struct { + Response Response + Queue []json.RawMessage + ErrQueue []json.RawMessage `json:"errQueue"` +} + +type Response struct { + Body json.RawMessage + StatusCode int `json:"status"` +} + +//go:generate npx ts-node ../../../test/scripts/generateJson.ts sources ./testdata/testcases +//go:generate npx prettier --write ./testdata/**/*.json + +//go:embed testdata/context.json +var contextData []byte + +//go:embed testdata/testcases/**/*.json +var testdata embed.FS + +func Load(t *testing.T) Setup { + t.Helper() + + var tc Context + err := json.Unmarshal(contextData, &tc) + require.NoError(t, err) + + var tcs []Case + err = fs.WalkDir(testdata, ".", func(path string, d fs.DirEntry, err error) error { + if err != nil { + return err + } + + if d.IsDir() { + return nil + } + + f, err := testdata.Open(path) + if err != nil { + return err + } + defer f.Close() + + var tc Case + err = json.NewDecoder(f).Decode(&tc) + if err != nil { + return err + } + tcs = append(tcs, tc) + + return nil + }) + require.NoError(t, err) + + return Setup{ + Context: tc, + Cases: tcs, + } +} diff --git a/go/webhook/testcases/testdata/context.json b/go/webhook/testcases/testdata/context.json new file mode 100644 index 0000000000..1b1f135638 --- /dev/null +++ b/go/webhook/testcases/testdata/context.json @@ -0,0 +1,5 @@ +{ + "request_ip_comment": "192.0.2.x/24 - This block is assigned as \"TEST-NET\" for use in documentation and example code.", + "request_ip": "192.0.2.30", + "now": "2024-03-03T04:48:29.000Z" +} diff --git a/go/webhook/testcases/testdata/testcases/adjust/simple_track_call.json b/go/webhook/testcases/testdata/testcases/adjust/simple_track_call.json new file mode 100644 index 0000000000..1a2f5e7b6b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/adjust/simple_track_call.json @@ -0,0 +1,66 @@ +{ + "name": "adjust", + "description": "Simple track call", + "input": { + "request": { + "body": { + "id": "adjust", + "query_parameters": { + "gps_adid": ["38400000-8cf0-11bd-b23e-10b96e40000d"], + "adid": ["18546f6171f67e29d1cb983322ad1329"], + "tracker_token": ["abc"], + "custom": ["custom"], + "tracker_name": ["dummy"], + "created_at": ["1404214665"], + "event_name": ["Click"] + }, + "updated_at": "2023-02-10T12:16:07.251Z", + "created_at": "2023-02-10T12:05:04.402Z" + }, + "headers": { + "Content-Type": "application/json" + }, + "method": "GET" + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Adjust" + }, + "device": { + "id ": "18546f6171f67e29d1cb983322ad1329" + } + }, + "integrations": { + "Adjust": false + }, + "type": "track", + "event": "Click", + "originalTimestamp": "2014-07-01T11:37:45.000Z", + "timestamp": "2014-07-01T11:37:45.000Z", + "properties": { + "gps_adid": "38400000-8cf0-11bd-b23e-10b96e40000d", + "tracker_token": "abc", + "custom": "custom", + "tracker_name": "dummy" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/adjust/simple_track_call_with_no_query_parameters.json b/go/webhook/testcases/testdata/testcases/adjust/simple_track_call_with_no_query_parameters.json new file mode 100644 index 0000000000..e110978b65 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/adjust/simple_track_call_with_no_query_parameters.json @@ -0,0 +1,32 @@ +{ + "name": "adjust", + "description": "Simple track call with no query parameters", + "input": { + "request": { + "body": { + "id": "adjust", + "updated_at": "2023-02-10T12:16:07.251Z", + "created_at": "2023-02-10T12:05:04.402Z" + }, + "headers": { + "Content-Type": "application/json" + }, + "method": "GET" + } + }, + "output": { + "response": { + "status": 400, + "body": "Query_parameters is missing" + }, + "queue": [], + "errQueue": [ + { + "id": "adjust", + "updated_at": "2023-02-10T12:16:07.251Z", + "created_at": "2023-02-10T12:05:04.402Z" + } + ] + }, + "skip": "FIXME" +} diff --git a/go/webhook/testcases/testdata/testcases/appcenter/test_0.json b/go/webhook/testcases/testdata/testcases/appcenter/test_0.json new file mode 100644 index 0000000000..b458fcc149 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appcenter/test_0.json @@ -0,0 +1,28 @@ +{ + "name": "appcenter", + "description": "test-0", + "input": { + "request": { + "body": { + "text": "Hello from your abc-test app in App Center!", + "sent_at": "2023-01-02T07: 53: 28.3117824Z", + "url": "https://appcenter.ms/users/abc-rudderstack.com/apps/abc-test" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": { + "text": "Hello from your abc-test app in App Center!", + "sent_at": "2023-01-02T07: 53: 28.3117824Z", + "url": "https://appcenter.ms/users/abc-rudderstack.com/apps/abc-test" + } + }, + "queue": [], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appcenter/test_1.json b/go/webhook/testcases/testdata/testcases/appcenter/test_1.json new file mode 100644 index 0000000000..514c484294 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appcenter/test_1.json @@ -0,0 +1,82 @@ +{ + "name": "appcenter", + "description": "test-1", + "input": { + "request": { + "body": { + "app_name": "MSAppCenterTesting", + "branch": "master", + "build_status": "Succeeded", + "build_id": "1", + "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/1", + "build_reason": "manual", + "finish_time": "2021-03-02T16:41:29.891411Z", + "icon_link": null, + "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", + "os": "Android", + "start_time": "2021-03-02T16:34:13.9184874Z", + "source_version": "7ed5c7b279316f19e9a0c45bb0fb49c0655471af", + "sent_at": "2021-03-02T16:41:55.8819564Z" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "APPCENTER" + }, + "app": { + "name": "MSAppCenterTesting", + "build": "1" + }, + "device": { + "type": "Android" + }, + "os": { + "name": "Android" + } + }, + "integrations": { + "APPCENTER": false + }, + "properties": { + "app_name": "MSAppCenterTesting", + "branch": "master", + "build_status": "Succeeded", + "build_id": "1", + "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/1", + "build_reason": "manual", + "finish_time": "2021-03-02T16:41:29.891411Z", + "icon_link": null, + "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", + "os": "Android", + "start_time": "2021-03-02T16:34:13.9184874Z", + "source_version": "7ed5c7b279316f19e9a0c45bb0fb49c0655471af", + "sent_at": "2021-03-02T16:41:55.8819564Z" + }, + "type": "track", + "event": "Build Succeeded", + "originalTimeStamp": "2021-03-02T16:34:13.9184874Z", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "sentAt": "2021-03-02T16:41:55.8819564Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appcenter/test_2.json b/go/webhook/testcases/testdata/testcases/appcenter/test_2.json new file mode 100644 index 0000000000..c1ed71362f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appcenter/test_2.json @@ -0,0 +1,82 @@ +{ + "name": "appcenter", + "description": "test-2", + "input": { + "request": { + "body": { + "app_name": "MSAppCenterTesting", + "branch": "master", + "build_status": "Broken", + "build_id": "2", + "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/2", + "build_reason": "automatic", + "finish_time": "2021-03-02T16:52:04.2587506Z", + "icon_link": null, + "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", + "os": "Android", + "start_time": "2021-03-02T16:50:52.2584107Z", + "source_version": "0624e1e3e48eaf2371c37316208ff83bdd5c123b", + "sent_at": "2021-03-02T16:52:35.8848052Z" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "APPCENTER" + }, + "app": { + "name": "MSAppCenterTesting", + "build": "2" + }, + "device": { + "type": "Android" + }, + "os": { + "name": "Android" + } + }, + "integrations": { + "APPCENTER": false + }, + "properties": { + "app_name": "MSAppCenterTesting", + "branch": "master", + "build_status": "Broken", + "build_id": "2", + "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/2", + "build_reason": "automatic", + "finish_time": "2021-03-02T16:52:04.2587506Z", + "icon_link": null, + "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", + "os": "Android", + "start_time": "2021-03-02T16:50:52.2584107Z", + "source_version": "0624e1e3e48eaf2371c37316208ff83bdd5c123b", + "sent_at": "2021-03-02T16:52:35.8848052Z" + }, + "type": "track", + "event": "Build Failed", + "originalTimeStamp": "2021-03-02T16:50:52.2584107Z", + "sentAt": "2021-03-02T16:52:35.8848052Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appcenter/test_3.json b/go/webhook/testcases/testdata/testcases/appcenter/test_3.json new file mode 100644 index 0000000000..992f160f6e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appcenter/test_3.json @@ -0,0 +1,98 @@ +{ + "name": "appcenter", + "description": "test-3", + "input": { + "request": { + "body": { + "app_name": "MSAppCenterTesting", + "app_display_name": "MSAppCenterTesting", + "release_id": "1", + "platform": "Android", + "uploaded_at": "2021-03-02T17:49:35.463Z", + "fingerprint": "9cbdc86d96c5359d2af3972fdda46624", + "release_notes": "Degraded to 4.0.0", + "version": "1614707021", + "short_version": "1.0", + "min_os": "7.1", + "mandatory_update": true, + "size": 2919106, + "provisioning_profile_name": null, + "provisioning_profile_type": null, + "bundle_identifier": "tech.desusai.msappcentertesting", + "install_link": "https://install.appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/releases/1?source=email", + "icon_link": "https://appcenter-filemanagement-distrib2ede6f06e.azureedge.net/dbbd3d57-9c09-448b-9782-0d57200f7c9b/ic_launcher.png?sv=2019-02-02&sr=c&sig=BNzQcMcvTbwf4fv59ByGiYXsr%2BA9PYDFyGJCqsE2RO0%3D&se=2021-03-09T17%3A49%3A35Z&sp=r", + "distribution_group_id": "00000000-0000-0000-0000-000000000000", + "installable": true, + "sent_at": "2021-03-02T17:49:37.127635Z", + "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "APPCENTER" + }, + "app": { + "name": "MSAppCenterTesting", + "version": "1.0", + "namespace": "tech.desusai.msappcentertesting" + }, + "device": { + "type": "Android" + }, + "os": { + "name": "Android" + } + }, + "integrations": { + "APPCENTER": false + }, + "properties": { + "app_name": "MSAppCenterTesting", + "app_display_name": "MSAppCenterTesting", + "release_id": "1", + "platform": "Android", + "uploaded_at": "2021-03-02T17:49:35.463Z", + "fingerprint": "9cbdc86d96c5359d2af3972fdda46624", + "release_notes": "Degraded to 4.0.0", + "version": "1614707021", + "short_version": "1.0", + "min_os": "7.1", + "mandatory_update": true, + "size": 2919106, + "provisioning_profile_name": null, + "provisioning_profile_type": null, + "bundle_identifier": "tech.desusai.msappcentertesting", + "install_link": "https://install.appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/releases/1?source=email", + "icon_link": "https://appcenter-filemanagement-distrib2ede6f06e.azureedge.net/dbbd3d57-9c09-448b-9782-0d57200f7c9b/ic_launcher.png?sv=2019-02-02&sr=c&sig=BNzQcMcvTbwf4fv59ByGiYXsr%2BA9PYDFyGJCqsE2RO0%3D&se=2021-03-09T17%3A49%3A35Z&sp=r", + "distribution_group_id": "00000000-0000-0000-0000-000000000000", + "installable": true, + "sent_at": "2021-03-02T17:49:37.127635Z", + "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" + }, + "type": "track", + "event": "Released Version 1.0", + "sentAt": "2021-03-02T17:49:37.127635Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appcenter/test_4.json b/go/webhook/testcases/testdata/testcases/appcenter/test_4.json new file mode 100644 index 0000000000..456276a0dd --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appcenter/test_4.json @@ -0,0 +1,81 @@ +{ + "name": "appcenter", + "description": "test-4", + "input": { + "request": { + "body": { + "id": "1139624368u", + "name": "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25)", + "reason": "java.lang.ArithmeticException: divide by zero", + "file_name": null, + "line_number": null, + "url": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/crashes/errors/1139624368u", + "app_display_name": "MSAppCenterTesting", + "app_platform": "Java", + "app_version": "1.0(1)", + "stack_trace": [ + "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25);" + ], + "affected_users": 0, + "crash_count": 0, + "sent_at": "2021-03-02T18:14:33.9713246Z", + "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "APPCENTER" + }, + "app": { + "name": "MSAppCenterTesting", + "version": "1.0(1)" + } + }, + "integrations": { + "APPCENTER": false + }, + "properties": { + "id": "1139624368u", + "name": "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25)", + "reason": "java.lang.ArithmeticException: divide by zero", + "file_name": null, + "line_number": null, + "url": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/crashes/errors/1139624368u", + "app_display_name": "MSAppCenterTesting", + "app_platform": "Java", + "app_version": "1.0(1)", + "stack_trace": [ + "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25);" + ], + "affected_users": 0, + "crash_count": 0, + "sent_at": "2021-03-02T18:14:33.9713246Z", + "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" + }, + "type": "track", + "event": "App Crashed", + "sentAt": "2021-03-02T18:14:33.9713246Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_0.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_0.json new file mode 100644 index 0000000000..b75b4a6323 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_0.json @@ -0,0 +1,294 @@ +{ + "name": "appsflyer", + "description": "test-0", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "device_type": "iPhoneXR", + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "ios", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "model": "iPhoneXR", + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "ios", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + }, + "userId": "hi.from@appsflyer.example.com" + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "type": "track", + "event": "My Apps", + "userId": "hi.from@appsflyer.example.com", + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "ios", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_1.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_1.json new file mode 100644 index 0000000000..7487945395 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_1.json @@ -0,0 +1,294 @@ +{ + "name": "appsflyer", + "description": "test-1", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "device_type": "Nokia 5.3", + "idfa": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "android", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "model": "Nokia 5.3", + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "android", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + }, + "userId": "hi.from@appsflyer.example.com" + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "type": "track", + "event": "My Apps", + "userId": "hi.from@appsflyer.example.com", + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "android", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_2.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_2.json new file mode 100644 index 0000000000..80589c1e47 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_2.json @@ -0,0 +1,246 @@ +{ + "name": "appsflyer", + "description": "test-2", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "device_type": "iPhoneXR", + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "ios", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Unknwon event type from Appsflyer\n" + }, + "queue": [], + "errQueue": [ + { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "device_type": "iPhoneXR", + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "ios", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_3.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_3.json new file mode 100644 index 0000000000..d12cc9ec36 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_3.json @@ -0,0 +1,291 @@ +{ + "name": "appsflyer", + "description": "test-3", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "device_type": "iPhoneXR", + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "ios", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "model": "iPhoneXR", + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "ios", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "type": "track", + "event": "My Apps", + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "ios", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_4.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_4.json new file mode 100644 index 0000000000..ba4f20f690 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_4.json @@ -0,0 +1,292 @@ +{ + "name": "appsflyer", + "description": "test-4", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "ios", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "ios", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + }, + "userId": "hi.from@appsflyer.example.com" + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "type": "track", + "event": "My Apps", + "userId": "hi.from@appsflyer.example.com", + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "ios", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_5.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_5.json new file mode 100644 index 0000000000..b00c4a727e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_5.json @@ -0,0 +1,292 @@ +{ + "name": "appsflyer", + "description": "test-5", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "watchos", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "watchos", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + }, + "userId": "hi.from@appsflyer.example.com" + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "type": "track", + "event": "My Apps", + "userId": "hi.from@appsflyer.example.com", + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "watchos", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_6.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_6.json new file mode 100644 index 0000000000..1a451c988f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_6.json @@ -0,0 +1,292 @@ +{ + "name": "appsflyer", + "description": "test-6", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "ipados", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "ipados", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + }, + "userId": "hi.from@appsflyer.example.com" + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "type": "track", + "event": "My Apps", + "userId": "hi.from@appsflyer.example.com", + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "ipados", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/appsflyer/test_7.json b/go/webhook/testcases/testdata/testcases/appsflyer/test_7.json new file mode 100644 index 0000000000..f5f496aeba --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/appsflyer/test_7.json @@ -0,0 +1,292 @@ +{ + "name": "appsflyer", + "description": "test-7", + "input": { + "request": { + "body": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "customer_user_id": "hi.from@appsflyer.example.com", + "is_lat": null, + "contributor_2_af_prt": null, + "bundle_id": "com.appsflyer.AppsFlyer", + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "app_version": "1.4.1", + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "city": "Khu Pho Binh Hoa", + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "app_name": "AppsFlyer", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "postal_code": "823941", + "wifi": true, + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "country_code": "VN", + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "appsflyer_id": "1547985076649-5309999", + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "ip": "1.1.1.1", + "oaid": null, + "event_time": "2020-01-15 14:57:24.898", + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "android_id": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "carrier": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "os_version": "12.3.1", + "platform": "tvos", + "af_sub3": null, + "contributor_3_match_type": null, + "selected_timezone": "UTC", + "af_ad_id": null, + "contributor_3_touch_time": null, + "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "AF" + }, + "ip": "1.1.1.1", + "timezone": "UTC", + "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", + "app": { + "namespace": "com.appsflyer.AppsFlyer", + "version": "1.4.1", + "name": "AppsFlyer" + }, + "device": { + "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", + "adTrackingEnabled": true + }, + "network": { + "wifi": true + }, + "os": { + "name": "tvos", + "version": "12.3.1" + }, + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + }, + "userId": "hi.from@appsflyer.example.com" + }, + "externalId": [ + { + "type": "appsflyerExternalId", + "value": "1547985076649-5309999" + } + ] + }, + "integrations": { + "AF": false + }, + "properties": { + "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", + "device_category": "phone", + "af_sub1": null, + "is_lat": null, + "contributor_2_af_prt": null, + "gp_broadcast_referrer": "", + "contributor_2_touch_time": null, + "contributor_3_touch_type": null, + "event_source": "SDK", + "af_cost_value": null, + "contributor_1_match_type": null, + "contributor_3_af_prt": null, + "custom_data": null, + "contributor_2_touch_type": null, + "gp_install_begin": null, + "amazon_aid": null, + "gp_referrer": null, + "af_cost_model": null, + "af_c_id": null, + "attributed_touch_time_selected_timezone": null, + "selected_currency": "USD", + "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "install_time": "2019-01-20 04:51:16.000", + "operator": null, + "attributed_touch_type": null, + "af_attribution_lookback": null, + "campaign_type": null, + "keyword_match_type": null, + "af_adset_id": null, + "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", + "contributor_2_media_source": null, + "conversion_type": null, + "contributor_2_match_type": null, + "api_version": "2.0", + "attributed_touch_time": null, + "revenue_in_selected_currency": null, + "is_retargeting": false, + "gp_click_time": null, + "contributor_1_af_prt": null, + "match_type": null, + "dma": "None", + "http_referrer": null, + "af_sub5": null, + "af_prt": null, + "event_revenue_currency": "USD", + "store_reinstall": null, + "install_app_store": null, + "media_source": "organic", + "deeplink_url": null, + "campaign": null, + "af_keywords": null, + "region": "AS", + "cost_in_selected_currency": null, + "event_value": "{}", + "oaid": null, + "is_receipt_validated": null, + "contributor_1_campaign": null, + "af_sub4": null, + "imei": null, + "contributor_3_campaign": null, + "event_revenue_usd": null, + "af_sub2": null, + "original_url": null, + "contributor_2_campaign": null, + "contributor_3_media_source": null, + "af_adset": null, + "af_ad": null, + "state": "57", + "network_account_id": null, + "retargeting_conversion_type": null, + "af_channel": null, + "af_cost_currency": null, + "contributor_1_media_source": null, + "keyword_id": null, + "device_download_time": "2019-01-20 04:51:16.000", + "contributor_1_touch_type": null, + "af_reengagement_window": null, + "af_siteid": null, + "language": "en-US", + "app_id": "id1217828636", + "contributor_1_touch_time": null, + "event_revenue": null, + "af_ad_type": null, + "event_name": "My Apps", + "af_sub_siteid": null, + "advertising_id": null, + "af_sub3": null, + "contributor_3_match_type": null, + "af_ad_id": null, + "contributor_3_touch_time": null, + "is_primary_attribution": true, + "sdk_version": "v4.10.0", + "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" + }, + "type": "track", + "event": "My Apps", + "userId": "hi.from@appsflyer.example.com", + "timestamp": "2020-01-15 14:57:24.898", + "originalTimestamp": "2020-01-15 14:57:24.898", + "platform": "tvos", + "traits": { + "address": { + "city": "Khu Pho Binh Hoa", + "zip": "823941", + "country": "VN" + } + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/auth0/add_member_to_an_organization.json b/go/webhook/testcases/testdata/testcases/auth0/add_member_to_an_organization.json new file mode 100644 index 0000000000..27a230ae26 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/auth0/add_member_to_an_organization.json @@ -0,0 +1,125 @@ +{ + "name": "auth0", + "description": "add member to an organization", + "input": { + "request": { + "body": { + "log_id": "90020221031061004280169676882609459981150114445973782546", + "data": { + "date": "2022-10-31T06:09:59.135Z", + "type": "sapi", + "description": "Add members to an organization", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "ip": "35.167.74.121", + "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "details": { + "request": { + "ip": "35.167.74.121", + "auth": { + "user": { + "name": "rudder test", + "email": "test@rudderstack.com", + "user_id": "google-oauth2|123456" + }, + "strategy": "jwt", + "credentials": { + "jti": "571921bf7833a97efabf08d765a0ec8f" + } + }, + "body": { + "members": ["auth0|123456"] + }, + "path": "/api/v2/organizations/org_eoe8p2atZ7furBxg/members", + "query": {}, + "method": "post", + "channel": "https://manage.auth0.com/", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36" + }, + "response": { + "body": {}, + "statusCode": 204 + } + }, + "user_id": "google-oauth2|123456", + "log_id": "90020221031061004280169676882609459981150114445973782546" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "group", + "sentAt": "2022-10-31T06:09:59.135Z", + "userId": "google-oauth2|123456", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "userId": "google-oauth2|123456" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "request_ip": "35.167.74.121", + "integration": { + "name": "Auth0" + } + }, + "groupId": "org_eoe8p2atZ7furBxg", + "properties": { + "log_id": "90020221031061004280169676882609459981150114445973782546", + "details": { + "request": { + "ip": "35.167.74.121", + "auth": { + "user": { + "name": "rudder test", + "email": "test@rudderstack.com", + "user_id": "google-oauth2|123456" + }, + "strategy": "jwt", + "credentials": { + "jti": "571921bf7833a97efabf08d765a0ec8f" + } + }, + "body": { + "members": ["auth0|123456"] + }, + "path": "/api/v2/organizations/org_eoe8p2atZ7furBxg/members", + "query": {}, + "method": "post", + "channel": "https://manage.auth0.com/", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36" + }, + "response": { + "body": {}, + "statusCode": 204 + } + }, + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "description": "Add members to an organization", + "source_type": "sapi" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T06:09:59.135Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/auth0/empty_batch.json b/go/webhook/testcases/testdata/testcases/auth0/empty_batch.json new file mode 100644 index 0000000000..6d87cbb292 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/auth0/empty_batch.json @@ -0,0 +1,20 @@ +{ + "name": "auth0", + "description": "empty batch", + "input": { + "request": { + "body": [], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Empty batch payload\n" + }, + "queue": [], + "errQueue": [[]] + } +} diff --git a/go/webhook/testcases/testdata/testcases/auth0/missing_user_id.json b/go/webhook/testcases/testdata/testcases/auth0/missing_user_id.json new file mode 100644 index 0000000000..bed8064f97 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/auth0/missing_user_id.json @@ -0,0 +1,96 @@ +{ + "name": "auth0", + "description": "missing userId", + "input": { + "request": { + "body": { + "log_id": "90020221031055712103169676686005480714681762668315934738", + "data": { + "date": "2022-10-31T05:57:06.859Z", + "type": "ss", + "description": "", + "connection": "Username-Password-Authentication", + "connection_id": "con_djwCjiwyID0vZy1S", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "All Applications", + "ip": "35.166.202.113", + "user_agent": "unknown", + "details": { + "body": { + "email": "testRudderlabs+21@gmail.com", + "tenant": "dev-cu4jy2zgao6yx15x", + "password": "dummyPassword", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "connection": "Username-Password-Authentication" + } + }, + "user_id": "", + "user_name": "testRudderlabs+21@gmail.com", + "strategy": "auth0", + "strategy_type": "database", + "log_id": "90020221031055712103169676686005480714681762668315934738" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "identify", + "sentAt": "2022-10-31T05:57:06.859Z", + "traits": { + "connection": "Username-Password-Authentication", + "connection_id": "con_djwCjiwyID0vZy1S" + }, + "userId": "", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "traits": { + "userId": "", + "user_name": "testRudderlabs+21@gmail.com" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "userAgent": "unknown", + "request_ip": "35.166.202.113", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031055712103169676686005480714681762668315934738", + "details": { + "body": { + "email": "testRudderlabs+21@gmail.com", + "tenant": "dev-cu4jy2zgao6yx15x", + "password": "dummyPassword", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "connection": "Username-Password-Authentication" + } + }, + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "All Applications", + "description": "", + "source_type": "ss" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T05:57:06.859Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/auth0/missing_user_id_for_all_the_requests_in_a_batch.json b/go/webhook/testcases/testdata/testcases/auth0/missing_user_id_for_all_the_requests_in_a_batch.json new file mode 100644 index 0000000000..b9428c4cd2 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/auth0/missing_user_id_for_all_the_requests_in_a_batch.json @@ -0,0 +1,142 @@ +{ + "name": "auth0", + "description": "missing userId for all the requests in a batch", + "input": { + "request": { + "body": [ + { + "log_id": "90020221031055712103169676686005480714681762668315934738", + "data": { + "date": "2022-10-31T05:57:06.859Z", + "type": "ss", + "description": "", + "connection": "Username-Password-Authentication", + "connection_id": "con_djwCjiwyID0vZy1S", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "All Applications", + "ip": "35.166.202.113", + "user_agent": "unknown", + "details": { + "body": { + "email": "testRudderlabs+21@gmail.com", + "tenant": "dev-cu4jy2zgao6yx15x", + "password": "dummyPassword", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "connection": "Username-Password-Authentication" + } + }, + "user_id": "", + "user_name": "testRudderlabs+21@gmail.com", + "strategy": "auth0", + "strategy_type": "database", + "log_id": "90020221031055712103169676686005480714681762668315934738" + } + }, + { + "log_id": "90020221031055712103169676686007898566320991926665347090", + "data": { + "date": "2022-10-31T05:57:06.874Z", + "type": "sapi", + "description": "Create a User", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "ip": "35.166.202.113", + "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "log_id": "90020221031055712103169676686007898566320991926665347090" + } + } + ], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "identify", + "userId": "", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "sentAt": "2022-10-31T05:57:06.859Z", + "traits": { + "connection": "Username-Password-Authentication", + "connection_id": "con_djwCjiwyID0vZy1S" + }, + "context": { + "traits": { + "userId": "", + "user_name": "testRudderlabs+21@gmail.com" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "userAgent": "unknown", + "request_ip": "35.166.202.113", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031055712103169676686005480714681762668315934738", + "details": { + "body": { + "email": "testRudderlabs+21@gmail.com", + "tenant": "dev-cu4jy2zgao6yx15x", + "password": "dummyPassword", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "connection": "Username-Password-Authentication" + } + }, + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "All Applications", + "description": "", + "source_type": "ss" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T05:57:06.859Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "type": "track", + "event": "Success API Operation", + "sentAt": "2022-10-31T05:57:06.874Z", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "request_ip": "35.166.202.113", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031055712103169676686007898566320991926665347090", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "description": "Create a User", + "source_type": "sapi" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T05:57:06.874Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/auth0/successful_signup.json b/go/webhook/testcases/testdata/testcases/auth0/successful_signup.json new file mode 100644 index 0000000000..8f5bc96776 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/auth0/successful_signup.json @@ -0,0 +1,505 @@ +{ + "name": "auth0", + "description": "successful signup", + "input": { + "request": { + "body": [ + { + "log_id": "90020221031055712103169676686005480714681762668315934738", + "data": { + "date": "2022-10-31T05:57:06.859Z", + "type": "ss", + "description": "", + "connection": "Username-Password-Authentication", + "connection_id": "con_djwCjiwyID0vZy1S", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "All Applications", + "ip": "35.166.202.113", + "user_agent": "unknown", + "details": { + "body": { + "email": "testRudderlabs+21@gmail.com", + "tenant": "dev-cu4jy2zgao6yx15x", + "password": "dummyPassword", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "connection": "Username-Password-Authentication" + } + }, + "user_id": "auth0|dummyPassword", + "user_name": "testRudderlabs+21@gmail.com", + "strategy": "auth0", + "strategy_type": "database", + "log_id": "90020221031055712103169676686005480714681762668315934738" + } + }, + { + "log_id": "90020221031055712103169676686007898566320991926665347090", + "data": { + "date": "2022-10-31T05:57:06.874Z", + "type": "sapi", + "description": "Create a User", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "ip": "35.166.202.113", + "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "details": { + "request": { + "ip": "35.166.202.113", + "auth": { + "user": { + "name": "rudder test", + "email": "test@rudderstack.com", + "user_id": "auth0|dummyPassword" + }, + "strategy": "jwt", + "credentials": { + "jti": "571921bf7833a97efabf08d765a0ec8f", + "scopes": [ + "create:actions", + "create:actions_log_sessions", + "create:client_credentials", + "create:client_grants", + "create:clients", + "create:connections", + "create:custom_domains", + "create:email_provider", + "create:email_templates", + "create:guardian_enrollment_tickets", + "create:integrations", + "create:log_streams", + "create:organization_connections", + "create:organization_invitations", + "create:organization_member_roles", + "create:organization_members", + "create:organizations", + "create:requested_scopes", + "create:resource_servers", + "create:roles", + "create:rules", + "create:shields", + "create:signing_keys", + "create:tenant_invitations", + "create:test_email_dispatch", + "create:users", + "delete:actions", + "delete:anomaly_blocks", + "delete:branding", + "delete:client_credentials", + "delete:client_grants", + "delete:clients", + "delete:connections", + "delete:custom_domains", + "delete:device_credentials", + "delete:email_provider", + "delete:email_templates", + "delete:grants", + "delete:guardian_enrollments", + "delete:integrations", + "delete:log_streams", + "delete:organization_connections", + "delete:organization_invitations", + "delete:organization_member_roles", + "delete:organization_members", + "delete:organizations", + "delete:owners", + "delete:requested_scopes", + "delete:resource_servers", + "delete:roles", + "delete:rules", + "delete:rules_configs", + "delete:shields", + "delete:tenant_invitations", + "delete:tenant_members", + "delete:tenants", + "delete:users", + "read:actions", + "read:anomaly_blocks", + "read:attack_protection", + "read:branding", + "read:checks", + "read:client_credentials", + "read:client_grants", + "read:client_keys", + "read:clients", + "read:connections", + "read:custom_domains", + "read:device_credentials", + "read:email_provider", + "read:email_templates", + "read:email_triggers", + "read:entity_counts", + "read:grants", + "read:guardian_factors", + "read:insights", + "read:integrations", + "read:log_streams", + "read:logs", + "read:mfa_policies", + "read:organization_connections", + "read:organization_invitations", + "read:organization_member_roles", + "read:organization_members", + "read:organizations", + "read:prompts", + "read:requested_scopes", + "read:resource_servers", + "read:roles", + "read:rules", + "read:rules_configs", + "read:shields", + "read:signing_keys", + "read:stats", + "read:tenant_invitations", + "read:tenant_members", + "read:tenant_settings", + "read:triggers", + "read:users", + "run:checks", + "update:actions", + "update:attack_protection", + "update:branding", + "update:client_credentials", + "update:client_grants", + "update:client_keys", + "update:clients", + "update:connections", + "update:custom_domains", + "update:email_provider", + "update:email_templates", + "update:email_triggers", + "update:guardian_factors", + "update:integrations", + "update:log_streams", + "update:mfa_policies", + "update:organization_connections", + "update:organizations", + "update:prompts", + "update:requested_scopes", + "update:resource_servers", + "update:roles", + "update:rules", + "update:rules_configs", + "update:shields", + "update:signing_keys", + "update:tenant_members", + "update:tenant_settings", + "update:triggers", + "update:users" + ] + } + }, + "body": { + "email": "testRudderlabs+21@gmail.com", + "password": "dummyPassword", + "connection": "Username-Password-Authentication" + }, + "path": "/api/v2/users", + "query": {}, + "method": "post", + "channel": "https://manage.auth0.com/", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36" + }, + "response": { + "body": { + "name": "testRudderlabs+21@gmail.com", + "email": "testRudderlabs+21@gmail.com", + "picture": "https://s.gravatar.com/avatar/0902f9d02b92aed9f0ac59aaf9475b60?s=480&r=pg&d=https%3A%2F%2Fcdn.auth0.com%2Favatars%2Fbh.png", + "user_id": "auth0|dummyPassword", + "nickname": "testRudderlabs+21", + "created_at": "2022-10-31T05:57:06.864Z", + "identities": [ + { + "user_id": "auth0|dummyPassword", + "isSocial": false, + "provider": "auth0", + "connection": "Username-Password-Authentication" + } + ], + "updated_at": "2022-10-31T05:57:06.864Z", + "email_verified": false + }, + "statusCode": 201 + } + }, + "user_id": "auth0|dummyPassword", + "log_id": "90020221031055712103169676686007898566320991926665347090" + } + } + ], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "identify", + "sentAt": "2022-10-31T05:57:06.859Z", + "traits": { + "connection": "Username-Password-Authentication", + "connection_id": "con_djwCjiwyID0vZy1S" + }, + "userId": "auth0|dummyPassword", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "traits": { + "userId": "auth0|dummyPassword", + "user_name": "testRudderlabs+21@gmail.com" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "userAgent": "unknown", + "request_ip": "35.166.202.113", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031055712103169676686005480714681762668315934738", + "details": { + "body": { + "email": "testRudderlabs+21@gmail.com", + "tenant": "dev-cu4jy2zgao6yx15x", + "password": "dummyPassword", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "connection": "Username-Password-Authentication" + } + }, + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "All Applications", + "description": "", + "source_type": "ss" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T05:57:06.859Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "type": "track", + "event": "Success API Operation", + "sentAt": "2022-10-31T05:57:06.874Z", + "userId": "auth0|dummyPassword", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "userId": "auth0|dummyPassword" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "request_ip": "35.166.202.113", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031055712103169676686007898566320991926665347090", + "details": { + "request": { + "ip": "35.166.202.113", + "auth": { + "user": { + "name": "rudder test", + "email": "test@rudderstack.com", + "user_id": "auth0|dummyPassword" + }, + "strategy": "jwt", + "credentials": { + "jti": "571921bf7833a97efabf08d765a0ec8f", + "scopes": [ + "create:actions", + "create:actions_log_sessions", + "create:client_credentials", + "create:client_grants", + "create:clients", + "create:connections", + "create:custom_domains", + "create:email_provider", + "create:email_templates", + "create:guardian_enrollment_tickets", + "create:integrations", + "create:log_streams", + "create:organization_connections", + "create:organization_invitations", + "create:organization_member_roles", + "create:organization_members", + "create:organizations", + "create:requested_scopes", + "create:resource_servers", + "create:roles", + "create:rules", + "create:shields", + "create:signing_keys", + "create:tenant_invitations", + "create:test_email_dispatch", + "create:users", + "delete:actions", + "delete:anomaly_blocks", + "delete:branding", + "delete:client_credentials", + "delete:client_grants", + "delete:clients", + "delete:connections", + "delete:custom_domains", + "delete:device_credentials", + "delete:email_provider", + "delete:email_templates", + "delete:grants", + "delete:guardian_enrollments", + "delete:integrations", + "delete:log_streams", + "delete:organization_connections", + "delete:organization_invitations", + "delete:organization_member_roles", + "delete:organization_members", + "delete:organizations", + "delete:owners", + "delete:requested_scopes", + "delete:resource_servers", + "delete:roles", + "delete:rules", + "delete:rules_configs", + "delete:shields", + "delete:tenant_invitations", + "delete:tenant_members", + "delete:tenants", + "delete:users", + "read:actions", + "read:anomaly_blocks", + "read:attack_protection", + "read:branding", + "read:checks", + "read:client_credentials", + "read:client_grants", + "read:client_keys", + "read:clients", + "read:connections", + "read:custom_domains", + "read:device_credentials", + "read:email_provider", + "read:email_templates", + "read:email_triggers", + "read:entity_counts", + "read:grants", + "read:guardian_factors", + "read:insights", + "read:integrations", + "read:log_streams", + "read:logs", + "read:mfa_policies", + "read:organization_connections", + "read:organization_invitations", + "read:organization_member_roles", + "read:organization_members", + "read:organizations", + "read:prompts", + "read:requested_scopes", + "read:resource_servers", + "read:roles", + "read:rules", + "read:rules_configs", + "read:shields", + "read:signing_keys", + "read:stats", + "read:tenant_invitations", + "read:tenant_members", + "read:tenant_settings", + "read:triggers", + "read:users", + "run:checks", + "update:actions", + "update:attack_protection", + "update:branding", + "update:client_credentials", + "update:client_grants", + "update:client_keys", + "update:clients", + "update:connections", + "update:custom_domains", + "update:email_provider", + "update:email_templates", + "update:email_triggers", + "update:guardian_factors", + "update:integrations", + "update:log_streams", + "update:mfa_policies", + "update:organization_connections", + "update:organizations", + "update:prompts", + "update:requested_scopes", + "update:resource_servers", + "update:roles", + "update:rules", + "update:rules_configs", + "update:shields", + "update:signing_keys", + "update:tenant_members", + "update:tenant_settings", + "update:triggers", + "update:users" + ] + } + }, + "body": { + "email": "testRudderlabs+21@gmail.com", + "password": "dummyPassword", + "connection": "Username-Password-Authentication" + }, + "path": "/api/v2/users", + "query": {}, + "method": "post", + "channel": "https://manage.auth0.com/", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36" + }, + "response": { + "body": { + "name": "testRudderlabs+21@gmail.com", + "email": "testRudderlabs+21@gmail.com", + "picture": "https://s.gravatar.com/avatar/0902f9d02b92aed9f0ac59aaf9475b60?s=480&r=pg&d=https%3A%2F%2Fcdn.auth0.com%2Favatars%2Fbh.png", + "user_id": "auth0|dummyPassword", + "nickname": "testRudderlabs+21", + "created_at": "2022-10-31T05:57:06.864Z", + "identities": [ + { + "user_id": "auth0|dummyPassword", + "isSocial": false, + "provider": "auth0", + "connection": "Username-Password-Authentication" + } + ], + "updated_at": "2022-10-31T05:57:06.864Z", + "email_verified": false + }, + "statusCode": 201 + } + }, + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "description": "Create a User", + "source_type": "sapi" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T05:57:06.874Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/auth0/update_tenant_settings.json b/go/webhook/testcases/testdata/testcases/auth0/update_tenant_settings.json new file mode 100644 index 0000000000..139d68d69d --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/auth0/update_tenant_settings.json @@ -0,0 +1,556 @@ +{ + "name": "auth0", + "description": "update tenant settings", + "input": { + "request": { + "body": [ + { + "log_id": "90020221031061527239169676960191065529099349299958906898", + "data": { + "date": "2022-10-31T06:15:25.201Z", + "type": "sapi", + "description": "Update tenant settings", + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "ip": "35.160.3.103", + "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "details": { + "request": { + "ip": "35.160.3.103", + "auth": { + "user": { + "name": "rudder test", + "email": "test@rudderstack.com", + "user_id": "google-oauth2|123456" + }, + "strategy": "jwt", + "credentials": { + "jti": "571921bf7833a97efabf08d765a0ec8f", + "scopes": [ + "create:actions", + "create:actions_log_sessions", + "create:client_credentials", + "create:client_grants", + "create:clients", + "create:connections", + "create:custom_domains", + "create:email_provider", + "create:email_templates", + "create:guardian_enrollment_tickets", + "create:integrations", + "create:log_streams", + "create:organization_connections", + "create:organization_invitations", + "create:organization_member_roles", + "create:organization_members", + "create:organizations", + "create:requested_scopes", + "create:resource_servers", + "create:roles", + "create:rules", + "create:shields", + "create:signing_keys", + "create:tenant_invitations", + "create:test_email_dispatch", + "create:users", + "delete:actions", + "delete:anomaly_blocks", + "delete:branding", + "delete:client_credentials", + "delete:client_grants", + "delete:clients", + "delete:connections", + "delete:custom_domains", + "delete:device_credentials", + "delete:email_provider", + "delete:email_templates", + "delete:grants", + "delete:guardian_enrollments", + "delete:integrations", + "delete:log_streams", + "delete:organization_connections", + "delete:organization_invitations", + "delete:organization_member_roles", + "delete:organization_members", + "delete:organizations", + "delete:owners", + "delete:requested_scopes", + "delete:resource_servers", + "delete:roles", + "delete:rules", + "delete:rules_configs", + "delete:shields", + "delete:tenant_invitations", + "delete:tenant_members", + "delete:tenants", + "delete:users", + "read:actions", + "read:anomaly_blocks", + "read:attack_protection", + "read:branding", + "read:checks", + "read:client_credentials", + "read:client_grants", + "read:client_keys", + "read:clients", + "read:connections", + "read:custom_domains", + "read:device_credentials", + "read:email_provider", + "read:email_templates", + "read:email_triggers", + "read:entity_counts", + "read:grants", + "read:guardian_factors", + "read:insights", + "read:integrations", + "read:log_streams", + "read:logs", + "read:mfa_policies", + "read:organization_connections", + "read:organization_invitations", + "read:organization_member_roles", + "read:organization_members", + "read:organizations", + "read:prompts", + "read:requested_scopes", + "read:resource_servers", + "read:roles", + "read:rules", + "read:rules_configs", + "read:shields", + "read:signing_keys", + "read:stats", + "read:tenant_invitations", + "read:tenant_members", + "read:tenant_settings", + "read:triggers", + "read:users", + "run:checks", + "update:actions", + "update:attack_protection", + "update:branding", + "update:client_credentials", + "update:client_grants", + "update:client_keys", + "update:clients", + "update:connections", + "update:custom_domains", + "update:email_provider", + "update:email_templates", + "update:email_triggers", + "update:guardian_factors", + "update:integrations", + "update:log_streams", + "update:mfa_policies", + "update:organization_connections", + "update:organizations", + "update:prompts", + "update:requested_scopes", + "update:resource_servers", + "update:roles", + "update:rules", + "update:rules_configs", + "update:shields", + "update:signing_keys", + "update:tenant_members", + "update:tenant_settings", + "update:triggers", + "update:users" + ] + } + }, + "body": { + "picture_url": "", + "support_url": "", + "friendly_name": "mecro-action", + "support_email": "support@test.com" + }, + "path": "/api/v2/tenants/settings", + "query": {}, + "method": "patch", + "channel": "https://manage.auth0.com/", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36" + }, + "response": { + "body": { + "flags": { + "enable_sso": true, + "universal_login": true, + "disable_impersonation": true, + "allow_changing_enable_sso": false, + "revoke_refresh_token_grant": false, + "disable_clickjack_protection_headers": false, + "new_universal_login_experience_enabled": true, + "enforce_client_authentication_on_passwordless_start": true, + "cannot_change_enforce_client_authentication_on_passwordless_start": true + }, + "picture_url": "", + "support_url": "", + "friendly_name": "mecro-action", + "support_email": "support@test.com", + "enabled_locales": ["en"], + "sandbox_version": "16", + "universal_login": {} + }, + "statusCode": 200 + } + }, + "user_id": "google-oauth2|123456", + "log_id": "90020221031061527239169676960191065529099349299958906898" + } + }, + { + "log_id": "90020221031061530247169676961198100736838335677367058450", + "data": { + "date": "2022-10-31T06:15:25.196Z", + "type": "gd_tenant_update", + "description": "Guardian - Updates tenant settings", + "ip": "35.160.3.103", + "details": { + "request": { + "ip": "35.160.3.103", + "auth": { + "scopes": [ + "read:authenticators", + "remove:authenticators", + "update:authenticators", + "create:authenticators", + "read:enrollments", + "delete:enrollments", + "read:factors", + "update:factors", + "update:tenant_settings", + "update:users", + "create:enrollment_tickets", + "create:users" + ], + "subject": "google-oauth2|123456", + "strategy": "jwt_api2_internal_token" + }, + "body": { + "picture_url": "[REDACTED]", + "friendly_name": "[REDACTED]" + }, + "path": "/api/tenants/settings", + "query": {}, + "method": "PATCH" + }, + "response": { + "body": { + "name": "dev-cu4jy2zgao6yx15x", + "picture_url": "[REDACTED]", + "friendly_name": "[REDACTED]", + "guardian_mfa_page": "[REDACTED]" + }, + "statusCode": 200 + } + }, + "user_id": "google-oauth2|123456", + "log_id": "90020221031061530247169676961198100736838335677367058450" + } + } + ], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Success API Operation", + "sentAt": "2022-10-31T06:15:25.201Z", + "userId": "google-oauth2|123456", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "userId": "google-oauth2|123456" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", + "request_ip": "35.160.3.103", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031061527239169676960191065529099349299958906898", + "details": { + "request": { + "ip": "35.160.3.103", + "auth": { + "user": { + "name": "rudder test", + "email": "test@rudderstack.com", + "user_id": "google-oauth2|123456" + }, + "strategy": "jwt", + "credentials": { + "jti": "571921bf7833a97efabf08d765a0ec8f", + "scopes": [ + "create:actions", + "create:actions_log_sessions", + "create:client_credentials", + "create:client_grants", + "create:clients", + "create:connections", + "create:custom_domains", + "create:email_provider", + "create:email_templates", + "create:guardian_enrollment_tickets", + "create:integrations", + "create:log_streams", + "create:organization_connections", + "create:organization_invitations", + "create:organization_member_roles", + "create:organization_members", + "create:organizations", + "create:requested_scopes", + "create:resource_servers", + "create:roles", + "create:rules", + "create:shields", + "create:signing_keys", + "create:tenant_invitations", + "create:test_email_dispatch", + "create:users", + "delete:actions", + "delete:anomaly_blocks", + "delete:branding", + "delete:client_credentials", + "delete:client_grants", + "delete:clients", + "delete:connections", + "delete:custom_domains", + "delete:device_credentials", + "delete:email_provider", + "delete:email_templates", + "delete:grants", + "delete:guardian_enrollments", + "delete:integrations", + "delete:log_streams", + "delete:organization_connections", + "delete:organization_invitations", + "delete:organization_member_roles", + "delete:organization_members", + "delete:organizations", + "delete:owners", + "delete:requested_scopes", + "delete:resource_servers", + "delete:roles", + "delete:rules", + "delete:rules_configs", + "delete:shields", + "delete:tenant_invitations", + "delete:tenant_members", + "delete:tenants", + "delete:users", + "read:actions", + "read:anomaly_blocks", + "read:attack_protection", + "read:branding", + "read:checks", + "read:client_credentials", + "read:client_grants", + "read:client_keys", + "read:clients", + "read:connections", + "read:custom_domains", + "read:device_credentials", + "read:email_provider", + "read:email_templates", + "read:email_triggers", + "read:entity_counts", + "read:grants", + "read:guardian_factors", + "read:insights", + "read:integrations", + "read:log_streams", + "read:logs", + "read:mfa_policies", + "read:organization_connections", + "read:organization_invitations", + "read:organization_member_roles", + "read:organization_members", + "read:organizations", + "read:prompts", + "read:requested_scopes", + "read:resource_servers", + "read:roles", + "read:rules", + "read:rules_configs", + "read:shields", + "read:signing_keys", + "read:stats", + "read:tenant_invitations", + "read:tenant_members", + "read:tenant_settings", + "read:triggers", + "read:users", + "run:checks", + "update:actions", + "update:attack_protection", + "update:branding", + "update:client_credentials", + "update:client_grants", + "update:client_keys", + "update:clients", + "update:connections", + "update:custom_domains", + "update:email_provider", + "update:email_templates", + "update:email_triggers", + "update:guardian_factors", + "update:integrations", + "update:log_streams", + "update:mfa_policies", + "update:organization_connections", + "update:organizations", + "update:prompts", + "update:requested_scopes", + "update:resource_servers", + "update:roles", + "update:rules", + "update:rules_configs", + "update:shields", + "update:signing_keys", + "update:tenant_members", + "update:tenant_settings", + "update:triggers", + "update:users" + ] + } + }, + "body": { + "picture_url": "", + "support_url": "", + "friendly_name": "mecro-action", + "support_email": "support@test.com" + }, + "path": "/api/v2/tenants/settings", + "query": {}, + "method": "patch", + "channel": "https://manage.auth0.com/", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36" + }, + "response": { + "body": { + "flags": { + "enable_sso": true, + "universal_login": true, + "disable_impersonation": true, + "allow_changing_enable_sso": false, + "revoke_refresh_token_grant": false, + "disable_clickjack_protection_headers": false, + "new_universal_login_experience_enabled": true, + "enforce_client_authentication_on_passwordless_start": true, + "cannot_change_enforce_client_authentication_on_passwordless_start": true + }, + "picture_url": "", + "support_url": "", + "friendly_name": "mecro-action", + "support_email": "support@test.com", + "enabled_locales": ["en"], + "sandbox_version": "16", + "universal_login": {} + }, + "statusCode": 200 + } + }, + "client_id": "vQcJNDTxsM1W72eHFonRJdzyOvawlwIt", + "client_name": "", + "description": "Update tenant settings", + "source_type": "sapi" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T06:15:25.201Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "type": "track", + "event": "Guardian tenant update", + "sentAt": "2022-10-31T06:15:25.196Z", + "userId": "google-oauth2|123456", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "userId": "google-oauth2|123456" + }, + "request_ip": "35.160.3.103", + "integration": { + "name": "Auth0" + } + }, + "properties": { + "log_id": "90020221031061530247169676961198100736838335677367058450", + "details": { + "request": { + "ip": "35.160.3.103", + "auth": { + "scopes": [ + "read:authenticators", + "remove:authenticators", + "update:authenticators", + "create:authenticators", + "read:enrollments", + "delete:enrollments", + "read:factors", + "update:factors", + "update:tenant_settings", + "update:users", + "create:enrollment_tickets", + "create:users" + ], + "subject": "google-oauth2|123456", + "strategy": "jwt_api2_internal_token" + }, + "body": { + "picture_url": "[REDACTED]", + "friendly_name": "[REDACTED]" + }, + "path": "/api/tenants/settings", + "query": {}, + "method": "PATCH" + }, + "response": { + "body": { + "name": "dev-cu4jy2zgao6yx15x", + "picture_url": "[REDACTED]", + "friendly_name": "[REDACTED]", + "guardian_mfa_page": "[REDACTED]" + }, + "statusCode": 200 + } + }, + "description": "Guardian - Updates tenant settings", + "source_type": "gd_tenant_update" + }, + "integrations": { + "Auth0": false + }, + "originalTimestamp": "2022-10-31T06:15:25.196Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/event_mapping_done_in_ui.json b/go/webhook/testcases/testdata/testcases/braze/event_mapping_done_in_ui.json new file mode 100644 index 0000000000..99260d1b34 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/event_mapping_done_in_ui.json @@ -0,0 +1,97 @@ +{ + "name": "braze", + "description": "event mapping done in UI", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.inappmessage.Click", + "properties": { + "device_model": "samsung" + }, + "user": { + "user_id": "user_id", + "external_user_id": "externalUserId" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "users.messages.inappmessage.Click", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "user_id", + "context": { + "device": { + "model": "samsung" + }, + "integration": { + "name": "Braze" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "In-App Message Clicked", + "integrations": { + "Braze": false + }, + "type": "track", + "userId": "externalUserId", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + }, + "skip": "Custom source config" +} diff --git a/go/webhook/testcases/testdata/testcases/braze/the_event_is_not_mapped_in_the_ui.json b/go/webhook/testcases/testdata/testcases/braze/the_event_is_not_mapped_in_the_ui.json new file mode 100644 index 0000000000..1c0c57d24e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/the_event_is_not_mapped_in_the_ui.json @@ -0,0 +1,96 @@ +{ + "name": "braze", + "description": "The event is not mapped in the UI", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.inappmessage.Click", + "properties": { + "device_model": "samsung" + }, + "user": { + "user_id": "user_id", + "external_user_id": "externalUserId" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "user_id", + "context": { + "device": { + "model": "samsung" + }, + "integration": { + "name": "Braze" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "users.messages.inappmessage.Click", + "integrations": { + "Braze": false + }, + "type": "track", + "userId": "externalUserId", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_behaviors_app_session_start_event.json b/go/webhook/testcases/testdata/testcases/braze/users_behaviors_app_session_start_event.json new file mode 100644 index 0000000000..6bece93f98 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_behaviors_app_session_start_event.json @@ -0,0 +1,113 @@ +{ + "name": "braze", + "description": "users.behaviors.app.SessionStart event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.behaviors.app.SessionStart", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "device_id": "fedcba87-6543-210f-edc-ba9876543210" + }, + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "platform": "ios", + "os_version": "iOS10.3.1", + "device_model": "iPhone7Plus", + "session_id": "b1234567-89ab-cdef-0123-456789abcdef" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Braze" + }, + "device": { + "id": "fedcba87-6543-210f-edc-ba9876543210", + "model": "iPhone7Plus" + }, + "os": { + "version": "iOS10.3.1", + "name": "ios" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.behaviors.app.SessionStart", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "session_id": "b1234567-89ab-cdef-0123-456789abcdef" + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_behaviors_custom_event_any_custom_event.json b/go/webhook/testcases/testdata/testcases/braze/users_behaviors_custom_event_any_custom_event.json new file mode 100644 index 0000000000..0e91adba2f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_behaviors_custom_event_any_custom_event.json @@ -0,0 +1,131 @@ +{ + "name": "braze", + "description": "users.behaviors.CustomEvent any custom event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.behaviors.CustomEvent", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "device_id": "fedcba87-6543-210f-edc-ba9876543210", + "timezone": "America/Chicago" + }, + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "platform": "ios", + "os_version": "iOS10.3.1", + "device_model": "iPhone7Plus", + "name": "customeventname", + "ad_id": "01234567-89ab-cdef-0123-456789abcdef", + "ad_id_type": "roku_ad_id", + "ad_tracking_enabled": true, + "custom_properties": { + "stringpropertyname": "a", + "numberpropertyname": 1, + "listpropertyname": ["a", "b"] + } + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Braze" + }, + "device": { + "id": "fedcba87-6543-210f-edc-ba9876543210", + "model": "iPhone7Plus", + "advertisingId": "01234567-89ab-cdef-0123-456789abcdef", + "adTrackingEnabled": true + }, + "timezone": "America/Chicago", + "os": { + "version": "iOS10.3.1", + "name": "ios" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.behaviors.CustomEvent", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "name": "customeventname", + "ad_id_type": "roku_ad_id", + "custom_properties": { + "stringpropertyname": "a", + "numberpropertyname": 1, + "listpropertyname": ["a", "b"] + } + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_behaviors_purchase_event.json b/go/webhook/testcases/testdata/testcases/braze/users_behaviors_purchase_event.json new file mode 100644 index 0000000000..a361aecdd0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_behaviors_purchase_event.json @@ -0,0 +1,135 @@ +{ + "name": "braze", + "description": "users.behaviors.Purchase event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.behaviors.Purchase", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "device_id": "fedcba87-6543-210f-edc-ba9876543210", + "timezone": "America/Chicago" + }, + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "platform": "ios", + "os_version": "iOS10.3.1", + "device_model": "iPhone7Plus", + "product_id": "1234", + "price": 12.34, + "currency": "AED", + "ad_id": "01234567-89ab-cdef-0123-456789abcdef", + "ad_id_type": "roku_ad_id", + "ad_tracking_enabled": true, + "purchase_properties": { + "stringpropertyname": "a", + "numberpropertyname": 1, + "listpropertyname": ["a", "b"] + } + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Braze" + }, + "device": { + "id": "fedcba87-6543-210f-edc-ba9876543210", + "model": "iPhone7Plus", + "advertisingId": "01234567-89ab-cdef-0123-456789abcdef", + "adTrackingEnabled": true + }, + "timezone": "America/Chicago", + "os": { + "version": "iOS10.3.1", + "name": "ios" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.behaviors.Purchase", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "product_id": "1234", + "price": 12.34, + "currency": "AED", + "ad_id_type": "roku_ad_id", + "purchase_properties": { + "stringpropertyname": "a", + "numberpropertyname": 1, + "listpropertyname": ["a", "b"] + } + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_messages_email_open_event.json b/go/webhook/testcases/testdata/testcases/braze/users_messages_email_open_event.json new file mode 100644 index 0000000000..f66795c51b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_messages_email_open_event.json @@ -0,0 +1,117 @@ +{ + "name": "braze", + "description": "users.messages.email.Open event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.email.Open", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "timezone": "America/Chicago" + }, + "properties": { + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "My Cool Canvas", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "dispatch_id": "12345qwert", + "email_address": "test@test.com", + "send_id": "f123456789abcdef01234567", + "user_agent": "Mozilla/5.0(Macintosh;IntelMacOSX10_13_5)AppleWebKit/537.36(KHTML,likeGecko)Chrome/67.0.3396.99Safari/537.36" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Braze" + }, + "timezone": "America/Chicago", + "userAgent": "Mozilla/5.0(Macintosh;IntelMacOSX10_13_5)AppleWebKit/537.36(KHTML,likeGecko)Chrome/67.0.3396.99Safari/537.36" + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.messages.email.Open", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "traits": { + "email": "test@test.com" + }, + "properties": { + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "My Cool Canvas", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "dispatch_id": "12345qwert", + "send_id": "f123456789abcdef01234567" + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_messages_inappmessage_click_event.json b/go/webhook/testcases/testdata/testcases/braze/users_messages_inappmessage_click_event.json new file mode 100644 index 0000000000..51f9655cdf --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_messages_inappmessage_click_event.json @@ -0,0 +1,125 @@ +{ + "name": "braze", + "description": "users.messages.inappmessage.Click event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.inappmessage.Click", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "device_id": "fedcba87-6543-210f-edc-ba9876543210", + "timezone": "America/Chicago" + }, + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "My Cool Campaign", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "platform": "android", + "os_version": "Android (N)", + "device_model": "Nexus 5X", + "button_id": "0", + "send_id": "f123456789abcdef01234567" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Braze" + }, + "device": { + "id": "fedcba87-6543-210f-edc-ba9876543210", + "model": "Nexus 5X" + }, + "timezone": "America/Chicago", + "os": { + "version": "Android (N)", + "name": "android" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.messages.inappmessage.Click", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "My Cool Campaign", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "button_id": "0", + "send_id": "f123456789abcdef01234567" + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_messages_pushnotification_send_event.json b/go/webhook/testcases/testdata/testcases/braze/users_messages_pushnotification_send_event.json new file mode 100644 index 0000000000..f2b5ed982e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_messages_pushnotification_send_event.json @@ -0,0 +1,121 @@ +{ + "name": "braze", + "description": "users.messages.pushnotification.Send event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.pushnotification.Send", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "device_id": "fedcba87-6543-210f-edc-ba9876543210", + "timezone": "America/Chicago" + }, + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "platform": "ios", + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "My Cool Campaign", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "send_id": "f123456789abcdef01234567", + "dispatch_id": "01234567-89ab-cdef-0123-456789abcdef" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Braze" + }, + "device": { + "id": "fedcba87-6543-210f-edc-ba9876543210" + }, + "timezone": "America/Chicago", + "os": { + "name": "ios" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.messages.pushnotification.Send", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "properties": { + "app_id": "01234567-89ab-cdef-0123-456789abcdef", + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "My Cool Campaign", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "send_id": "f123456789abcdef01234567", + "dispatch_id": "01234567-89ab-cdef-0123-456789abcdef" + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_messages_sms_delivery_event.json b/go/webhook/testcases/testdata/testcases/braze/users_messages_sms_delivery_event.json new file mode 100644 index 0000000000..f6fb446f9f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_messages_sms_delivery_event.json @@ -0,0 +1,117 @@ +{ + "name": "braze", + "description": "users.messages.sms.Delivery event", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.sms.Delivery", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "timezone": "America/Chicago" + }, + "properties": { + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "MyCoolCanvas", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "dispatch_id": "12345qwert", + "to_phone_number": "+16462345678", + "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", + "from_phone_number": "+12123470922" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "timezone": "America/Chicago", + "integration": { + "name": "Braze" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.messages.sms.Delivery", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "traits": { + "phone": "+16462345678" + }, + "properties": { + "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", + "canvas_name": "MyCoolCanvas", + "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", + "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", + "dispatch_id": "12345qwert", + "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", + "from_phone_number": "+12123470922" + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/braze/users_messages_sms_delivery_send.json b/go/webhook/testcases/testdata/testcases/braze/users_messages_sms_delivery_send.json new file mode 100644 index 0000000000..1700cfaf29 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/braze/users_messages_sms_delivery_send.json @@ -0,0 +1,115 @@ +{ + "name": "braze", + "description": "users.messages.sms.Delivery send", + "input": { + "request": { + "body": { + "events": [ + { + "event_type": "users.messages.sms.Delivery", + "id": "a1234567-89ab-cdef-0123-456789abcdef", + "time": 1477502783, + "user": { + "user_id": "0123456789abcdef01234567", + "external_user_id": "user_id", + "timezone": "America/Chicago" + }, + "properties": { + "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", + "campaign_name": "Test Campaign", + "dispatch_id": "12345qwert", + "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", + "to_phone_number": "+16462345678", + "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", + "from_phone_number": "+12123470922" + } + } + ], + "source": { + "ID": "2hgvYyU5TYaFvVzBge6tF2UKoeG", + "OriginalID": "", + "Name": "Braze source", + "SourceDefinition": { + "ID": "1lh9senY3vrBg4JQXswWzyYBTOO", + "Name": "Braze", + "Category": "webhook", + "Type": "cloud" + }, + "Config": { + "customMapping": [ + { + "from": "randomEvent", + "to": "In-App Message Clicked" + } + ] + }, + "Enabled": true, + "WorkspaceID": "2hSS1hZ8kuCpUZAAYsQucAFdob9", + "Destinations": null, + "WriteKey": "2hgvYykpvMaE5Eg47Au8RWC9Yza", + "DgSourceTrackingPlanConfig": { + "sourceId": "", + "version": 0, + "config": null, + "mergedConfig": null, + "deleted": false, + "trackingPlan": { + "id": "", + "version": 0 + } + }, + "Transient": false, + "GeoEnrichment": { + "Enabled": false + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "timezone": "America/Chicago", + "integration": { + "name": "Braze" + } + }, + "integrations": { + "Braze": false + }, + "type": "track", + "event": "users.messages.sms.Delivery", + "messageId": "a1234567-89ab-cdef-0123-456789abcdef", + "anonymousId": "0123456789abcdef01234567", + "userId": "user_id", + "traits": { + "phone": "+16462345678" + }, + "properties": { + "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", + "campaign_name": "Test Campaign", + "dispatch_id": "12345qwert", + "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", + "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", + "from_phone_number": "+12123470922" + }, + "timestamp": "2016-10-26T17:26:23.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_0.json b/go/webhook/testcases/testdata/testcases/canny/test_0.json new file mode 100644 index 0000000000..889b38a350 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_0.json @@ -0,0 +1,137 @@ +{ + "name": "canny", + "description": "test-0", + "input": { + "request": { + "body": { + "created": "2022-07-28T10:52:46.294Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 13, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-28T10:52:46.172Z", + "customFields": [ + { + "id": "62e13820d7949d44b92d3876", + "name": "abc", + "value": "123" + } + ], + "details": "Array of images", + "eta": null, + "id": "62e26a7e1d4ea13c124337bd", + "imageURLs": [ + "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", + "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" + ], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Custom Fields Testing", + "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" + }, + "objectType": "post", + "type": "post.created" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "post.created", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-28T10:52:46.294Z", + "originalTimestamp": "2022-07-28T10:52:46.294Z", + "type": "track", + "properties": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 13, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-28T10:52:46.172Z", + "customFields": [ + { + "id": "62e13820d7949d44b92d3876", + "name": "abc", + "value": "123" + } + ], + "details": "Array of images", + "eta": null, + "id": "62e26a7e1d4ea13c124337bd", + "imageURLs": [ + "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", + "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" + ], + "objectType": "post", + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Custom Fields Testing", + "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_1.json b/go/webhook/testcases/testdata/testcases/canny/test_1.json new file mode 100644 index 0000000000..caac99d3d8 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_1.json @@ -0,0 +1,135 @@ +{ + "name": "canny", + "description": "test-1", + "input": { + "request": { + "body": { + "created": "2022-07-26T10:35:16.390Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 10, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-26T08:18:52.459Z", + "deletedBy": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "details": "This is the post's details", + "eta": null, + "id": "62dfa36c9950e94655320fe7", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" + }, + "objectType": "post", + "type": "post.deleted" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "post.deleted", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T10:35:16.390Z", + "originalTimestamp": "2022-07-26T10:35:16.390Z", + "type": "track", + "properties": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 10, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-26T08:18:52.459Z", + "deletedBy": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "details": "This is the post's details", + "eta": null, + "id": "62dfa36c9950e94655320fe7", + "imageURLs": [], + "objectType": "post", + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_10.json b/go/webhook/testcases/testdata/testcases/canny/test_10.json new file mode 100644 index 0000000000..4189302961 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_10.json @@ -0,0 +1,149 @@ +{ + "name": "canny", + "description": "test-10", + "input": { + "request": { + "body": { + "created": "2022-07-26T11:32:31.378Z", + "object": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T11:32:31.263Z", + "id": "62dfd0cfb2870d468c9618f5", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 0, + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "score": 1, + "voter": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": "123" + } + }, + "objectType": "vote", + "type": "vote.created" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "123", + "event": "vote.created", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T11:32:31.378Z", + "originalTimestamp": "2022-07-26T11:32:31.378Z", + "type": "track", + "properties": { + "objectType": "vote", + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T11:32:31.263Z", + "id": "62dfd0cfb2870d468c9618f5", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 0, + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "score": 1 + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_11.json b/go/webhook/testcases/testdata/testcases/canny/test_11.json new file mode 100644 index 0000000000..45112e7ea4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_11.json @@ -0,0 +1,140 @@ +{ + "name": "canny", + "description": "test-11", + "input": { + "request": { + "body": { + "created": "2022-07-26T18:09:27.358Z", + "object": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T08:22:31.109Z", + "id": "62dfa4479950e9465532a338", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 1, + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "planned", + "tags": [ + { + "id": "62e02db67ad24c46bc175f56", + "name": "abc-tag", + "postCount": 1, + "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" + } + ], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "score": 0, + "voter": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": null, + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + } + }, + "objectType": "vote", + "type": "vote.deleted" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Missing essential fields from Canny. Error: (TypeError [ERR_INVALID_ARG_TYPE]: The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received null)\n" + }, + "queue": [], + "errQueue": [ + { + "created": "2022-07-26T18:09:27.358Z", + "object": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T08:22:31.109Z", + "id": "62dfa4479950e9465532a338", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 1, + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "planned", + "tags": [ + { + "id": "62e02db67ad24c46bc175f56", + "name": "abc-tag", + "postCount": 1, + "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" + } + ], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "score": 0, + "voter": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": null, + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + } + }, + "objectType": "vote", + "type": "vote.deleted" + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_12.json b/go/webhook/testcases/testdata/testcases/canny/test_12.json new file mode 100644 index 0000000000..73340ab335 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_12.json @@ -0,0 +1,108 @@ +{ + "name": "canny", + "description": "test-12", + "input": { + "request": { + "body": { + "created": "2022-07-26T10:35:16.390Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 10, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-26T08:18:52.459Z", + "deletedBy": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "details": "This is the post's details", + "eta": null, + "id": "62dfa36c9950e94655320fe7", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" + }, + "objectType": "post" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Missing essential fields from Canny\n" + }, + "queue": [], + "errQueue": [ + { + "created": "2022-07-26T10:35:16.390Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 10, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-26T08:18:52.459Z", + "deletedBy": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "details": "This is the post's details", + "eta": null, + "id": "62dfa36c9950e94655320fe7", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" + }, + "objectType": "post" + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_2.json b/go/webhook/testcases/testdata/testcases/canny/test_2.json new file mode 100644 index 0000000000..28050f11ed --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_2.json @@ -0,0 +1,133 @@ +{ + "name": "canny", + "description": "test-2", + "input": { + "request": { + "body": { + "created": "2022-07-26T18:32:28.337Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "category": null, + "commentCount": 0, + "created": "2022-07-26T10:43:43.752Z", + "details": "This is the post's details", + "eta": null, + "id": "62dfc55ffe7f6f465b9b4568", + "imageURLs": [], + "issue": { + "description": "This is the post's details\n\nhttps://rudder.canny.io/admin/board/features/p/post-title-8", + "id": "10001", + "key": "TES-2", + "status": "To Do", + "summary": "Canny Source Testing", + "url": "https://rudderstack-user.atlassian.net/browse/TES-2" + }, + "owner": null, + "score": 2, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-8" + }, + "objectType": "post", + "type": "post.jira_issue_linked" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "post.jira_issue_linked", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T18:32:28.337Z", + "originalTimestamp": "2022-07-26T18:32:28.337Z", + "type": "track", + "properties": { + "by": null, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "category": null, + "commentCount": 0, + "created": "2022-07-26T10:43:43.752Z", + "details": "This is the post's details", + "eta": null, + "id": "62dfc55ffe7f6f465b9b4568", + "imageURLs": [], + "issue": { + "description": "This is the post's details\n\nhttps://rudder.canny.io/admin/board/features/p/post-title-8", + "id": "10001", + "key": "TES-2", + "status": "To Do", + "summary": "Canny Source Testing", + "url": "https://rudderstack-user.atlassian.net/browse/TES-2" + }, + "objectType": "post", + "owner": null, + "score": 2, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-8" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_3.json b/go/webhook/testcases/testdata/testcases/canny/test_3.json new file mode 100644 index 0000000000..526340e90e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_3.json @@ -0,0 +1,133 @@ +{ + "name": "canny", + "description": "test-3", + "input": { + "request": { + "body": { + "created": "2022-07-27T04:08:24.377Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "category": null, + "commentCount": 0, + "created": "2022-07-26T11:32:31.228Z", + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "issue": { + "description": "Array of images\n\nhttps://rudder.canny.io/admin/board/features/p/images-testing-2", + "id": "10002", + "key": "TES-3", + "status": "To Do", + "summary": "Images testing", + "url": "https://rudderstack-user.atlassian.net/browse/TES-3" + }, + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "objectType": "post", + "type": "post.jira_issue_unlinked" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "post.jira_issue_unlinked", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-27T04:08:24.377Z", + "originalTimestamp": "2022-07-27T04:08:24.377Z", + "type": "track", + "properties": { + "objectType": "post", + "by": null, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "category": null, + "commentCount": 0, + "created": "2022-07-26T11:32:31.228Z", + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "issue": { + "description": "Array of images\n\nhttps://rudder.canny.io/admin/board/features/p/images-testing-2", + "id": "10002", + "key": "TES-3", + "status": "To Do", + "summary": "Images testing", + "url": "https://rudderstack-user.atlassian.net/browse/TES-3" + }, + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_4.json b/go/webhook/testcases/testdata/testcases/canny/test_4.json new file mode 100644 index 0000000000..3af2ad99fc --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_4.json @@ -0,0 +1,157 @@ +{ + "name": "canny", + "description": "test-4", + "input": { + "request": { + "body": { + "created": "2022-07-26T18:07:03.143Z", + "object": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "changeComment": { + "imageURLs": ["https://canny.io/images/0a4b1c6a967ad9fc17f0c71dc11d1de2.webp"], + "value": "" + }, + "changedAt": "2022-07-26T18:07:03.143Z", + "changer": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "commentCount": 1, + "created": "2022-07-26T08:22:31.089Z", + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "jira": { + "linkedIssues": [], + "linkedIssueIDs": [] + }, + "owner": null, + "score": 2, + "status": "planned", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "objectType": "post", + "type": "post.status_changed" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "post.status_changed", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T18:07:03.143Z", + "originalTimestamp": "2022-07-26T18:07:03.143Z", + "type": "track", + "properties": { + "objectType": "post", + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "changeComment": { + "imageURLs": ["https://canny.io/images/0a4b1c6a967ad9fc17f0c71dc11d1de2.webp"], + "value": "" + }, + "changedAt": "2022-07-26T18:07:03.143Z", + "changer": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "commentCount": 1, + "created": "2022-07-26T08:22:31.089Z", + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "jira": { + "linkedIssues": [], + "linkedIssueIDs": [] + }, + "owner": null, + "score": 2, + "status": "planned", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_5.json b/go/webhook/testcases/testdata/testcases/canny/test_5.json new file mode 100644 index 0000000000..6efb211c58 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_5.json @@ -0,0 +1,153 @@ +{ + "name": "canny", + "description": "test-5", + "input": { + "request": { + "body": { + "created": "2022-07-26T10:52:17.712Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 11, + "url": "https://rudder.canny.io/admin/board/features" + }, + "created": "2022-07-26T10:52:17.618Z", + "id": "62dfc761af6e2b467381b103", + "imageURLs": ["https://canny.io/images/59ef1b731f87d1c84bbdc078d0b9221e.webp"], + "internal": true, + "mentions": [], + "parentID": null, + "post": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 1, + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "owner": null, + "score": 2, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "private": false, + "value": "webhook-test" + }, + "objectType": "comment", + "type": "comment.created" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "comment.created", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T10:52:17.712Z", + "originalTimestamp": "2022-07-26T10:52:17.712Z", + "type": "track", + "properties": { + "objectType": "comment", + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 11, + "url": "https://rudder.canny.io/admin/board/features" + }, + "created": "2022-07-26T10:52:17.618Z", + "id": "62dfc761af6e2b467381b103", + "imageURLs": ["https://canny.io/images/59ef1b731f87d1c84bbdc078d0b9221e.webp"], + "internal": true, + "mentions": [], + "parentID": null, + "post": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 1, + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "owner": null, + "score": 2, + "status": "open", + "tags": [], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "private": false, + "value": "webhook-test" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_6.json b/go/webhook/testcases/testdata/testcases/canny/test_6.json new file mode 100644 index 0000000000..0cd90c97b4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_6.json @@ -0,0 +1,149 @@ +{ + "name": "canny", + "description": "test-6", + "input": { + "request": { + "body": { + "created": "2022-07-27T04:12:09.290Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "created": "2022-07-27T04:11:59.942Z", + "id": "62e0bb0faf6e2b467328b133", + "imageURLs": [], + "parentID": null, + "post": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 0, + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "private": false, + "value": "good" + }, + "objectType": "comment", + "type": "comment.deleted" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "comment.deleted", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-27T04:12:09.290Z", + "originalTimestamp": "2022-07-27T04:12:09.290Z", + "type": "track", + "properties": { + "objectType": "comment", + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "created": "2022-07-27T04:11:59.942Z", + "id": "62e0bb0faf6e2b467328b133", + "imageURLs": [], + "parentID": null, + "post": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 0, + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "private": false, + "value": "good" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_7.json b/go/webhook/testcases/testdata/testcases/canny/test_7.json new file mode 100644 index 0000000000..fd525def22 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_7.json @@ -0,0 +1,149 @@ +{ + "name": "canny", + "description": "test-7", + "input": { + "request": { + "body": { + "created": "2022-07-26T11:32:31.378Z", + "object": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T11:32:31.263Z", + "id": "62dfd0cfb2870d468c9618f5", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 0, + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "score": 1, + "voter": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + } + }, + "objectType": "vote", + "type": "vote.created" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "vote.created", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T11:32:31.378Z", + "originalTimestamp": "2022-07-26T11:32:31.378Z", + "type": "track", + "properties": { + "objectType": "vote", + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T11:32:31.263Z", + "id": "62dfd0cfb2870d468c9618f5", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 0, + "details": "Array of images", + "eta": null, + "id": "62dfd0cfb2870d468c9618dd", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Images testing", + "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" + }, + "score": 1 + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_8.json b/go/webhook/testcases/testdata/testcases/canny/test_8.json new file mode 100644 index 0000000000..13f1153196 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_8.json @@ -0,0 +1,163 @@ +{ + "name": "canny", + "description": "test-8", + "input": { + "request": { + "body": { + "created": "2022-07-26T18:09:27.358Z", + "object": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T08:22:31.109Z", + "id": "62dfa4479950e9465532a338", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 1, + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "planned", + "tags": [ + { + "id": "62e02db67ad24c46bc175f56", + "name": "abc-tag", + "postCount": 1, + "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" + } + ], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "score": 0, + "voter": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + } + }, + "objectType": "vote", + "type": "vote.deleted" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "event": "vote.deleted", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-26T18:09:27.358Z", + "originalTimestamp": "2022-07-26T18:09:27.358Z", + "type": "track", + "properties": { + "objectType": "vote", + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 12, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "created": "2022-07-26T08:22:31.109Z", + "id": "62dfa4479950e9465532a338", + "post": { + "author": { + "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": null + }, + "by": null, + "category": null, + "commentCount": 1, + "details": "This is the post's details", + "eta": null, + "id": "62dfa4479950e9465532a31e", + "imageURLs": [], + "owner": null, + "score": 1, + "status": "planned", + "tags": [ + { + "id": "62e02db67ad24c46bc175f56", + "name": "abc-tag", + "postCount": 1, + "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" + } + ], + "title": "Post Title", + "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" + }, + "score": 0 + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/canny/test_9.json b/go/webhook/testcases/testdata/testcases/canny/test_9.json new file mode 100644 index 0000000000..e36cffb52b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/canny/test_9.json @@ -0,0 +1,137 @@ +{ + "name": "canny", + "description": "test-9", + "input": { + "request": { + "body": { + "created": "2022-07-28T10:52:46.294Z", + "object": { + "author": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "id": "62d14c90fff7c80d0ec08375", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser", + "userID": "sampleuserId" + }, + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 13, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-28T10:52:46.172Z", + "customFields": [ + { + "id": "62e13820d7949d44b92d3876", + "name": "abc", + "value": "123" + } + ], + "details": "Array of images", + "eta": null, + "id": "62e26a7e1d4ea13c124337bd", + "imageURLs": [ + "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", + "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" + ], + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Custom Fields Testing", + "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" + }, + "objectType": "post", + "type": "post.created" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "sampleuserId", + "event": "post.created", + "integrations": { + "Canny": false + }, + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Canny", + "version": "1.0.0" + }, + "traits": { + "created": "2022-07-15T11:16:32.648Z", + "email": "test@rudderstack.com", + "isAdmin": true, + "name": "Rudder Test", + "url": "https://rudder.canny.io/admin/users/dummyUser" + }, + "externalId": [ + { + "type": "cannyUserId", + "id": "62d14c90fff7c80d0ec08375" + } + ] + }, + "timestamp": "2022-07-28T10:52:46.294Z", + "originalTimestamp": "2022-07-28T10:52:46.294Z", + "type": "track", + "properties": { + "board": { + "created": "2022-07-25T12:11:19.895Z", + "id": "62de88676bc28b44aaaf25cc", + "name": "features", + "postCount": 13, + "url": "https://rudder.canny.io/admin/board/features" + }, + "by": null, + "category": null, + "commentCount": 0, + "created": "2022-07-28T10:52:46.172Z", + "customFields": [ + { + "id": "62e13820d7949d44b92d3876", + "name": "abc", + "value": "123" + } + ], + "details": "Array of images", + "eta": null, + "id": "62e26a7e1d4ea13c124337bd", + "imageURLs": [ + "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", + "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" + ], + "objectType": "post", + "owner": null, + "score": 1, + "status": "open", + "tags": [], + "title": "Custom Fields Testing", + "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/close_crm/group_creation.json b/go/webhook/testcases/testdata/testcases/close_crm/group_creation.json new file mode 100644 index 0000000000..24bb4546b4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/close_crm/group_creation.json @@ -0,0 +1,100 @@ +{ + "name": "close_crm", + "description": "group creation", + "input": { + "request": { + "body": { + "subscription_id": "whsub_123", + "event": { + "id": "ev_123", + "date_created": "2024-06-13T03:53:33.917000", + "date_updated": "2024-06-13T03:53:33.917000", + "organization_id": "orga_123", + "user_id": "user_123", + "request_id": "req_123", + "api_key_id": null, + "oauth_client_id": null, + "oauth_scope": null, + "object_type": "group", + "object_id": "group_123", + "lead_id": null, + "action": "created", + "changed_fields": [], + "meta": { + "request_path": "/api/v1/graphql/", + "request_method": "POST" + }, + "data": { + "id": "group_123", + "name": "Test group", + "members": [ + { + "user_id": "user_123" + } + ] + }, + "previous_data": {} + }, + "source": {} + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "context": { + "integration": { + "name": "CloseCRM" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "group created", + "integrations": { + "CloseCRM": false + }, + "messageId": "ev_123", + "originalTimestamp": "2024-06-ThT03:53:33.917+00:00", + "properties": { + "action": "created", + "data": { + "id": "group_123", + "members": [ + { + "user_id": "user_123" + } + ], + "name": "Test group" + }, + "date_created": "2024-06-13T03:53:33.917000", + "date_updated": "2024-06-13T03:53:33.917000", + "id": "ev_123", + "meta": { + "request_method": "POST", + "request_path": "/api/v1/graphql/" + }, + "object_id": "group_123", + "object_type": "group", + "organization_id": "orga_123", + "request_id": "req_123", + "subscription_id": "whsub_123", + "user_id": "user_123" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/close_crm/lead_deletion.json b/go/webhook/testcases/testdata/testcases/close_crm/lead_deletion.json new file mode 100644 index 0000000000..3b8a2ce578 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/close_crm/lead_deletion.json @@ -0,0 +1,103 @@ +{ + "name": "close_crm", + "description": "lead deletion", + "input": { + "request": { + "body": { + "subscription_id": "whsub_123", + "event": { + "id": "ev_123", + "date_created": "2024-06-14T05:16:04.138000", + "date_updated": "2024-06-14T05:16:04.138000", + "organization_id": "orga_123", + "user_id": "user_123", + "request_id": "req_123", + "api_key_id": "api_123", + "oauth_client_id": null, + "oauth_scope": null, + "object_type": "lead", + "object_id": "lead_123", + "lead_id": "lead_123", + "action": "deleted", + "changed_fields": [], + "meta": { + "request_path": "/api/v1/lead/lead_123/", + "request_method": "DELETE" + }, + "data": {}, + "previous_data": { + "created_by_name": "Rudder User", + "addresses": [], + "description": "", + "url": null, + "date_created": "2024-06-14T05:13:42.239000+00:00", + "status_id": "stat_123", + "contact_ids": ["cont_123"], + "id": "lead_12", + "date_updated": "2024-06-14T05:13:42.262000+00:00", + "updated_by_name": "Rudder User", + "status_label": "Potential", + "name": "test name", + "display_name": "test name", + "organization_id": "orga_123", + "updated_by": "user_123", + "created_by": "user_123" + } + }, + "source": {} + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "CloseCRM" + } + }, + "integrations": { + "CloseCRM": false + }, + "type": "track", + "event": "lead deleted", + "userId": "lead_123", + "messageId": "ev_123", + "originalTimestamp": "2024-06-FrT05:16:04.138+00:00", + "properties": { + "id": "ev_123", + "date_created": "2024-06-14T05:16:04.138000", + "date_updated": "2024-06-14T05:16:04.138000", + "organization_id": "orga_123", + "user_id": "user_123", + "request_id": "req_123", + "api_key_id": "api_123", + "object_type": "lead", + "object_id": "lead_123", + "lead_id": "lead_123", + "action": "deleted", + "meta": { + "request_path": "/api/v1/lead/lead_123/", + "request_method": "DELETE" + }, + "data": {}, + "subscription_id": "whsub_123" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/close_crm/lead_update.json b/go/webhook/testcases/testdata/testcases/close_crm/lead_update.json new file mode 100644 index 0000000000..99cdfe061c --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/close_crm/lead_update.json @@ -0,0 +1,145 @@ +{ + "name": "close_crm", + "description": "lead update", + "input": { + "request": { + "body": { + "event": { + "date_created": "2019-01-15T12:48:23.395000", + "meta": { + "request_method": "PUT", + "request_path": "/api/v1/opportunity/object_id/" + }, + "id": "ev_123", + "action": "updated", + "date_updated": "2019-01-15T12:48:23.395000", + "changed_fields": [ + "confidence", + "date_updated", + "status_id", + "status_label", + "status_type" + ], + "previous_data": { + "status_type": "active", + "confidence": 70, + "date_updated": "2019-01-15T12:47:39.873000+00:00", + "status_id": "stat_123", + "status_label": "Active" + }, + "organization_id": "orga_123", + "data": { + "contact_name": "Mr. Jones", + "user_name": "Joe Kemp", + "value_period": "one_time", + "updated_by_name": "Joe Kemp", + "date_created": "2019-01-15T12:41:24.496000+00:00", + "user_id": "user_123", + "updated_by": "user_123", + "value_currency": "USD", + "organization_id": "orga_123", + "status_label": "Won", + "contact_id": "cont_123", + "status_type": "won", + "created_by_name": "Joe Kemp", + "id": "id_12", + "lead_name": "KLine", + "date_lost": null, + "note": "", + "date_updated": "2019-01-15T12:48:23.392000+00:00", + "status_id": "stat_12", + "value": 100000, + "created_by": "user_123", + "value_formatted": "$1,000", + "date_won": "2019-01-15", + "lead_id": "lead_123", + "confidence": 100 + }, + "request_id": "req_123", + "object_id": "object_id", + "user_id": "user_123", + "object_type": "opportunity", + "lead_id": "lead_123" + }, + "subscription_id": "whsub_123", + "source": {} + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "CloseCRM" + } + }, + "integrations": { + "CloseCRM": false + }, + "type": "track", + "event": "opportunity updated", + "messageId": "ev_123", + "userId": "lead_123", + "originalTimestamp": "2019-01-TuT12:48:23.395+00:00", + "properties": { + "date_created": "2019-01-15T12:48:23.395000", + "meta": { + "request_method": "PUT", + "request_path": "/api/v1/opportunity/object_id/" + }, + "id": "ev_123", + "action": "updated", + "date_updated": "2019-01-15T12:48:23.395000", + "organization_id": "orga_123", + "data": { + "contact_name": "Mr. Jones", + "user_name": "Joe Kemp", + "value_period": "one_time", + "updated_by_name": "Joe Kemp", + "date_created": "2019-01-15T12:41:24.496000+00:00", + "user_id": "user_123", + "updated_by": "user_123", + "value_currency": "USD", + "organization_id": "orga_123", + "status_label": "Won", + "contact_id": "cont_123", + "status_type": "won", + "created_by_name": "Joe Kemp", + "id": "id_12", + "lead_name": "KLine", + "note": "", + "date_updated": "2019-01-15T12:48:23.392000+00:00", + "status_id": "stat_12", + "value": 100000, + "created_by": "user_123", + "value_formatted": "$1,000", + "date_won": "2019-01-15", + "lead_id": "lead_123", + "confidence": 100 + }, + "request_id": "req_123", + "object_id": "object_id", + "user_id": "user_123", + "object_type": "opportunity", + "lead_id": "lead_123", + "subscription_id": "whsub_123" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/cordial/multiple_object_input_event_with_batched_payload.json b/go/webhook/testcases/testdata/testcases/cordial/multiple_object_input_event_with_batched_payload.json new file mode 100644 index 0000000000..1217608454 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/cordial/multiple_object_input_event_with_batched_payload.json @@ -0,0 +1,326 @@ +{ + "name": "cordial", + "description": "Multiple object Input event with batched payload", + "input": { + "request": { + "body": [ + { + "contact": { + "_id": "633b2fd70a12be027e0b0xxx", + "lang_locale": "EN-US", + "channels": { + "email": { + "address": "johndoe@example.com", + "subscribeStatus": "none" + } + }, + "createdAt": "2022-10-03T18:54:15+0000", + "email_sha256_hash": "f959bdf883831ebb96612eb9xxxx1e0c9481780adf5f70xxx862155531bf61df", + "first_name": "john", + "last_name": "doe", + "lastUpdateSource": "cordial", + "lastModified": "2024-07-24T07:52:46+0000", + "cID": "633b2fd70a12be027e0b0xxx" + }, + "event": { + "_id": "66a0b2ce5344b55fxxxc5a64", + "cID": "633b2fd70a12be027e0b0xxx", + "ts": "2024-07-24T07:52:46+00:00", + "ats": "2024-07-24T07:52:39+0000", + "g": { + "countryISO": "PL", + "country": "Poland", + "state": "MZ", + "city": "Warszawa", + "postalCode": "00-686", + "geoLoc": { + "lat": 52.22744369506836, + "lon": 21.009017944335938 + }, + "tz": "Europe/Warsaw" + }, + "d": { + "type": "computer", + "device": "Macintosh", + "platform": "OS X", + "browser": "Chrome", + "robot": false + }, + "a": "browse", + "UID": "471af949fffe749c2ebfxxx950ea73c", + "sp": { + "bid": "cf6de7f1-cce5-40xx-ac9c-7c82a2xxc09e" + }, + "tzo": -7, + "rl": "6", + "time": "2024-07-24T07:52:39+0000", + "action": "browse", + "bmID": "", + "first": 0, + "properties": { + "url": "https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart", + "product_item_group_id": ["1094269"], + "product_category": ["allproducts"], + "product_name": ["wtp ab"], + "product_group": ["women"] + } + }, + "source": {} + }, + { + "contact": { + "_id": "633b2fd12312be027e0b0xxx", + "lang_locale": "EN-US", + "channels": { + "email": { + "address": "johndoe1@example.com", + "subscribeStatus": "none" + } + }, + "createdAt": "2022-10-03T18:54:15+0000", + "email_sha256_hash": "f95912b883831eab11612eb9xxxx1e0c9481780ad45770xxx862155531bf61df", + "first_name": "john", + "last_name": "doe", + "lastUpdateSource": "cordial", + "lastModified": "2024-07-24T07:52:46+0000", + "cID": "633b2fd12312be027e0b0xxx" + }, + "event": { + "_id": "66aku0b2ce527b55fx1xc5a64", + "cID": "633b2fd12312be027e0b0xxx", + "ts": "2024-07-24T07:52:46+00:00", + "ats": "2024-07-24T07:52:39+0000", + "g": { + "countryISO": "PL", + "country": "Poland", + "state": "MZ", + "city": "Warszawa", + "postalCode": "00-686", + "geoLoc": { + "lat": 52.22744369506836, + "lon": 21.009017944335938 + }, + "tz": "Europe/Warsaw" + }, + "d": { + "type": "computer", + "device": "Macintosh", + "platform": "OS X", + "browser": "Chrome", + "robot": false + }, + "a": "browse", + "UID": "471af949fffe74sdh382ebfxxx950ea73c", + "sp": { + "bid": "cf6de7f1-123ce5-20xx-ac9c-7c82a2xxc09e" + }, + "tzo": -7, + "rl": "6", + "time": "2024-07-24T07:52:39+0000", + "action": "browse", + "bmID": "", + "first": 0, + "properties": { + "url": "https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart", + "product_item_group_id": ["1094269"], + "product_category": ["allproducts"], + "product_name": ["wtp ab"], + "product_group": ["women"] + } + }, + "source": {} + } + ], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Cordial" + }, + "traits": { + "userId": "633b2fd70a12be027e0b0xxx", + "email": "johndoe@example.com", + "_id": "633b2fd70a12be027e0b0xxx", + "lang_locale": "EN-US", + "channels": { + "email": { + "address": "johndoe@example.com", + "subscribeStatus": "none" + } + }, + "createdAt": "2022-10-03T18:54:15+0000", + "email_sha256_hash": "f959bdf883831ebb96612eb9xxxx1e0c9481780adf5f70xxx862155531bf61df", + "first_name": "john", + "last_name": "doe", + "lastUpdateSource": "cordial", + "lastModified": "2024-07-24T07:52:46+0000", + "cID": "633b2fd70a12be027e0b0xxx" + }, + "device": { + "type": "computer", + "device": "Macintosh", + "platform": "OS X", + "browser": "Chrome", + "robot": false + }, + "externalId": [ + { + "id": "633b2fd70a12be027e0b0xxx", + "type": "cordialContactId" + } + ] + }, + "integrations": { + "Cordial": false + }, + "type": "track", + "event": "browse", + "properties": { + "event_id": "66a0b2ce5344b55fxxxc5a64", + "url": "https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart", + "product_item_group_id": ["1094269"], + "product_category": ["allproducts"], + "product_name": ["wtp ab"], + "product_group": ["women"], + "cID": "633b2fd70a12be027e0b0xxx", + "ts": "2024-07-24T07:52:46+00:00", + "ats": "2024-07-24T07:52:39+0000", + "g": { + "countryISO": "PL", + "country": "Poland", + "state": "MZ", + "city": "Warszawa", + "postalCode": "00-686", + "geoLoc": { + "lat": 52.22744369506836, + "lon": 21.009017944335938 + }, + "tz": "Europe/Warsaw" + }, + "a": "browse", + "UID": "471af949fffe749c2ebfxxx950ea73c", + "sp": { + "bid": "cf6de7f1-cce5-40xx-ac9c-7c82a2xxc09e" + }, + "tzo": -7, + "rl": "6", + "time": "2024-07-24T07:52:39+0000", + "action": "browse", + "bmID": "", + "first": 0 + }, + "userId": "633b2fd70a12be027e0b0xxx", + "timestamp": "2024-07-24T07:52:46+00:00", + "sentAt": "2024-07-24T07:52:46+00:00", + "originalTimestamp": "2024-07-24T07:52:46+00:00", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Cordial" + }, + "traits": { + "userId": "633b2fd12312be027e0b0xxx", + "email": "johndoe1@example.com", + "_id": "633b2fd12312be027e0b0xxx", + "lang_locale": "EN-US", + "channels": { + "email": { + "address": "johndoe1@example.com", + "subscribeStatus": "none" + } + }, + "createdAt": "2022-10-03T18:54:15+0000", + "email_sha256_hash": "f95912b883831eab11612eb9xxxx1e0c9481780ad45770xxx862155531bf61df", + "first_name": "john", + "last_name": "doe", + "lastUpdateSource": "cordial", + "lastModified": "2024-07-24T07:52:46+0000", + "cID": "633b2fd12312be027e0b0xxx" + }, + "device": { + "type": "computer", + "device": "Macintosh", + "platform": "OS X", + "browser": "Chrome", + "robot": false + }, + "externalId": [ + { + "id": "633b2fd12312be027e0b0xxx", + "type": "cordialContactId" + } + ] + }, + "integrations": { + "Cordial": false + }, + "type": "track", + "event": "browse", + "properties": { + "event_id": "66aku0b2ce527b55fx1xc5a64", + "url": "https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart", + "product_item_group_id": ["1094269"], + "product_category": ["allproducts"], + "product_name": ["wtp ab"], + "product_group": ["women"], + "cID": "633b2fd12312be027e0b0xxx", + "ts": "2024-07-24T07:52:46+00:00", + "ats": "2024-07-24T07:52:39+0000", + "g": { + "countryISO": "PL", + "country": "Poland", + "state": "MZ", + "city": "Warszawa", + "postalCode": "00-686", + "geoLoc": { + "lat": 52.22744369506836, + "lon": 21.009017944335938 + }, + "tz": "Europe/Warsaw" + }, + "a": "browse", + "UID": "471af949fffe74sdh382ebfxxx950ea73c", + "sp": { + "bid": "cf6de7f1-123ce5-20xx-ac9c-7c82a2xxc09e" + }, + "tzo": -7, + "rl": "6", + "time": "2024-07-24T07:52:39+0000", + "action": "browse", + "bmID": "", + "first": 0 + }, + "userId": "633b2fd12312be027e0b0xxx", + "timestamp": "2024-07-24T07:52:46+00:00", + "sentAt": "2024-07-24T07:52:46+00:00", + "originalTimestamp": "2024-07-24T07:52:46+00:00", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/cordial/simple_single_object_input_event_with_no_cid.json b/go/webhook/testcases/testdata/testcases/cordial/simple_single_object_input_event_with_no_cid.json new file mode 100644 index 0000000000..5b7f898cb3 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/cordial/simple_single_object_input_event_with_no_cid.json @@ -0,0 +1,139 @@ +{ + "name": "cordial", + "description": "Simple Single object Input event with no CId", + "input": { + "request": { + "body": { + "contact": { + "_id": "6690fe3655e334xx028xx1", + "channels": { + "email": { + "address": "jondoe@example.com", + "subscribeStatus": "subscribed", + "subscribedAt": "2024-07-12T09:58:14+0000" + } + }, + "createdAt": "2024-07-12T09:58:14+0000", + "address": { + "city": "San Miego" + }, + "first_name": "John", + "last_name": "Doe", + "lastUpdateSource": "api", + "lastModified": "2024-07-12T13:00:49+0000" + }, + "event": { + "_id": "669141857b8cxxx1ba0da2x1", + "ts": "2024-07-12T14:45:25+00:00", + "ats": "2024-07-12T14:45:25+0000", + "d": { + "type": "computer", + "device": false, + "platform": false, + "browser": false, + "robot": true + }, + "a": "browse", + "tzo": -7, + "rl": "a", + "UID": "4934ee07197xx3f74d5xxxx7b0076", + "time": "2024-07-12T14:45:25+0000", + "action": "browse", + "bmID": "", + "first": 0, + "properties": { + "category": "Shirts", + "url": "http://example.com/shirts", + "description": "A really cool khaki shirt.", + "price": 9.99, + "title": "Khaki Shirt", + "test_key": "value" + } + }, + "source": {} + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Cordial" + }, + "traits": { + "userId": "6690fe3655e334xx028xx1", + "email": "jondoe@example.com", + "_id": "6690fe3655e334xx028xx1", + "channels": { + "email": { + "address": "jondoe@example.com", + "subscribeStatus": "subscribed", + "subscribedAt": "2024-07-12T09:58:14+0000" + } + }, + "createdAt": "2024-07-12T09:58:14+0000", + "address": { + "city": "San Miego" + }, + "first_name": "John", + "last_name": "Doe", + "lastUpdateSource": "api", + "lastModified": "2024-07-12T13:00:49+0000" + }, + "device": { + "type": "computer", + "device": false, + "platform": false, + "browser": false, + "robot": true + }, + "externalId": [] + }, + "integrations": { + "Cordial": false + }, + "type": "track", + "event": "browse", + "originalTimestamp": "2024-07-12T14:45:25+00:00", + "properties": { + "event_id": "669141857b8cxxx1ba0da2x1", + "category": "Shirts", + "url": "http://example.com/shirts", + "description": "A really cool khaki shirt.", + "price": 9.99, + "title": "Khaki Shirt", + "test_key": "value", + "ts": "2024-07-12T14:45:25+00:00", + "ats": "2024-07-12T14:45:25+0000", + "a": "browse", + "tzo": -7, + "rl": "a", + "UID": "4934ee07197xx3f74d5xxxx7b0076", + "time": "2024-07-12T14:45:25+0000", + "action": "browse", + "bmID": "", + "first": 0 + }, + "userId": "6690fe3655e334xx028xx1", + "timestamp": "2024-07-12T14:45:25+00:00", + "sentAt": "2024-07-12T14:45:25+00:00", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/cordial/simple_single_object_input_event_with_normal_channel_and_action.json b/go/webhook/testcases/testdata/testcases/cordial/simple_single_object_input_event_with_normal_channel_and_action.json new file mode 100644 index 0000000000..72c76816ec --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/cordial/simple_single_object_input_event_with_normal_channel_and_action.json @@ -0,0 +1,134 @@ +{ + "name": "cordial", + "description": "Simple Single object Input event with normal channel and action", + "input": { + "request": { + "body": { + "contact": { + "_id": "6690fe3655e334xx028xxx", + "channels": { + "email": { + "address": "jondoe@example.com", + "subscribeStatus": "subscribed", + "subscribedAt": "2024-07-12T09:58:14+0000" + } + }, + "createdAt": "2024-07-12T09:58:14+0000", + "address": { + "city": "San Miego" + }, + "first_name": "John", + "last_name": "Doe", + "lastUpdateSource": "api", + "lastModified": "2024-07-12T13:00:49+0000", + "cID": "6690fe3655e334xx028xxx" + }, + "event": { + "_id": "669141857b8cxxx1ba0da2xx", + "cID": "6690fe3655e334xx028xxx", + "ts": "2024-07-12T14:45:25+00:00", + "ats": "2024-07-12T14:45:25+0000", + "a": "browse", + "tzo": -7, + "rl": "a", + "UID": "4934ee07118197xx3f74d5xxxx7b0076", + "time": "2024-07-12T14:45:25+0000", + "action": "browse", + "bmID": "", + "first": 0, + "properties": { + "category": "Shirts", + "url": "http://example.com/shirts", + "description": "A really cool khaki shirt.", + "price": 9.99, + "title": "Khaki Shirt", + "test_key": "value" + } + }, + "source": {} + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Cordial" + }, + "traits": { + "userId": "6690fe3655e334xx028xxx", + "email": "jondoe@example.com", + "_id": "6690fe3655e334xx028xxx", + "channels": { + "email": { + "address": "jondoe@example.com", + "subscribeStatus": "subscribed", + "subscribedAt": "2024-07-12T09:58:14+0000" + } + }, + "createdAt": "2024-07-12T09:58:14+0000", + "address": { + "city": "San Miego" + }, + "first_name": "John", + "last_name": "Doe", + "lastUpdateSource": "api", + "lastModified": "2024-07-12T13:00:49+0000", + "cID": "6690fe3655e334xx028xxx" + }, + "externalId": [ + { + "id": "6690fe3655e334xx028xxx", + "type": "cordialContactId" + } + ] + }, + "integrations": { + "Cordial": false + }, + "type": "track", + "event": "browse", + "originalTimestamp": "2024-07-12T14:45:25+00:00", + "properties": { + "event_id": "669141857b8cxxx1ba0da2xx", + "category": "Shirts", + "url": "http://example.com/shirts", + "description": "A really cool khaki shirt.", + "price": 9.99, + "title": "Khaki Shirt", + "test_key": "value", + "cID": "6690fe3655e334xx028xxx", + "ts": "2024-07-12T14:45:25+00:00", + "ats": "2024-07-12T14:45:25+0000", + "a": "browse", + "tzo": -7, + "rl": "a", + "UID": "4934ee07118197xx3f74d5xxxx7b0076", + "time": "2024-07-12T14:45:25+0000", + "action": "browse", + "bmID": "", + "first": 0 + }, + "userId": "6690fe3655e334xx028xxx", + "timestamp": "2024-07-12T14:45:25+00:00", + "sentAt": "2024-07-12T14:45:25+00:00", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_0.json b/go/webhook/testcases/testdata/testcases/customerio/test_0.json new file mode 100644 index 0000000000..3f308c34f0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_0.json @@ -0,0 +1,59 @@ +{ + "name": "customerio", + "description": "test-0", + "input": { + "request": { + "body": { + "data": { + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "email_address": "test@example.com" + }, + "event_id": "01E4C4CT6YDC7Y5M7FE1GWWPQJ", + "object_type": "customer", + "metric": "subscribed", + "timestamp": "abc" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Customer Subscribed", + "properties": { + "eventId": "01E4C4CT6YDC7Y5M7FE1GWWPQJ" + }, + "userId": "0200102", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_1.json b/go/webhook/testcases/testdata/testcases/customerio/test_1.json new file mode 100644 index 0000000000..aef99f3dac --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_1.json @@ -0,0 +1,59 @@ +{ + "name": "customerio", + "description": "test-1", + "input": { + "request": { + "body": { + "data": { + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "email_address": "test@example.com" + }, + "event_id": "01E4C4CT6YDC7Y5M7FE1GWWPQJ", + "object_type": "customer", + "metric": "subscribed", + "timestamp": "1585250199" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Customer Subscribed", + "properties": { + "eventId": "01E4C4CT6YDC7Y5M7FE1GWWPQJ" + }, + "userId": "0200102", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_10.json b/go/webhook/testcases/testdata/testcases/customerio/test_10.json new file mode 100644 index 0000000000..4bcba90c80 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_10.json @@ -0,0 +1,75 @@ +{ + "name": "customerio", + "description": "test-10", + "input": { + "request": { + "body": { + "data": { + "action_id": 37, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", + "recipients": [ + { + "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof", + "device_platform": "android" + } + ] + }, + "event_id": "01E4C4HDQ7P1X9KTKF0ZX7PWHE", + "object_type": "push", + "metric": "sent", + "timestamp": 1585250350 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Push Sent", + "properties": { + "eventId": "01E4C4HDQ7P1X9KTKF0ZX7PWHE", + "deliveryId": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", + "actionId": 37, + "broadcastId": 9, + "recipients": [ + { + "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof", + "device_platform": "android" + } + ] + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:19:10.000Z", + "sentAt": "2020-03-26T19:19:10.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_11.json b/go/webhook/testcases/testdata/testcases/customerio/test_11.json new file mode 100644 index 0000000000..e6b025578d --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_11.json @@ -0,0 +1,79 @@ +{ + "name": "customerio", + "description": "test-11", + "input": { + "request": { + "body": { + "data": { + "action_id": 37, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", + "href": "ciosas://product/2", + "link_id": 1, + "recipients": [ + { + "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" + } + ] + }, + "event_id": "01E4V2SBHYK4TNTG8WKMP39G9R", + "object_type": "push", + "metric": "clicked", + "timestamp": 1585751829 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Push Link Clicked", + "properties": { + "eventId": "01E4V2SBHYK4TNTG8WKMP39G9R", + "deliveryId": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", + "actionId": 37, + "broadcastId": 9, + "link": { + "url": "ciosas://product/2", + "id": 1 + }, + "recipients": [ + { + "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" + } + ] + }, + "userId": "0200102", + "originalTimestamp": "2020-04-01T14:37:09.000Z", + "sentAt": "2020-04-01T14:37:09.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_12.json b/go/webhook/testcases/testdata/testcases/customerio/test_12.json new file mode 100644 index 0000000000..883df1feb9 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_12.json @@ -0,0 +1,65 @@ +{ + "name": "customerio", + "description": "test-12", + "input": { + "request": { + "body": { + "data": { + "action_id": 41, + "campaign_id": 7, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "ROk1AAIBcR4iT6mueuxiDtzO8HXv", + "failure_message": "Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309." + }, + "event_id": "01E4F3DCS83P8HT7R3E6DWQN1X", + "object_type": "sms", + "metric": "attempted", + "timestamp": 1234567890 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "SMS Attempted", + "properties": { + "eventId": "01E4F3DCS83P8HT7R3E6DWQN1X", + "deliveryId": "ROk1AAIBcR4iT6mueuxiDtzO8HXv", + "actionId": 41, + "reason": "Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309.", + "campaignId": 7 + }, + "userId": "0200102", + "originalTimestamp": "2009-02-13T23:31:30.000Z", + "sentAt": "2009-02-13T23:31:30.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_13.json b/go/webhook/testcases/testdata/testcases/customerio/test_13.json new file mode 100644 index 0000000000..f50ab7bb95 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_13.json @@ -0,0 +1,73 @@ +{ + "name": "customerio", + "description": "test-13", + "input": { + "request": { + "body": { + "data": { + "action_id": 38, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgIBcRh6qzHz-8gKvscP2UZa", + "href": "https://app.com/verify", + "link_id": 1, + "recipient": "+18008675309" + }, + "event_id": "01E4XXPN42JDF4B1ATQKTZ8WHV", + "object_type": "sms", + "metric": "clicked", + "timestamp": 1585847161 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "+18008675309" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "SMS Link Clicked", + "properties": { + "eventId": "01E4XXPN42JDF4B1ATQKTZ8WHV", + "deliveryId": "RPILAgIBcRh6qzHz-8gKvscP2UZa", + "actionId": 38, + "broadcastId": 9, + "link": { + "url": "https://app.com/verify", + "id": 1 + } + }, + "userId": "0200102", + "originalTimestamp": "2020-04-02T17:06:01.000Z", + "sentAt": "2020-04-02T17:06:01.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_14.json b/go/webhook/testcases/testdata/testcases/customerio/test_14.json new file mode 100644 index 0000000000..f123414e90 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_14.json @@ -0,0 +1,67 @@ +{ + "name": "customerio", + "description": "test-14", + "input": { + "request": { + "body": { + "data": { + "action_id": 39, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgQBcRhNAufb0s30bmz5HD7Y", + "recipient": "#signups" + }, + "event_id": "01E4C4TQKD6KJ274870J5DE2HB", + "object_type": "slack", + "metric": "sent", + "timestamp": 1585250655 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "#signups" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Slack Message Sent", + "properties": { + "eventId": "01E4C4TQKD6KJ274870J5DE2HB", + "deliveryId": "RPILAgQBcRhNAufb0s30bmz5HD7Y", + "actionId": 39, + "broadcastId": 9 + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:24:15.000Z", + "sentAt": "2020-03-26T19:24:15.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_15.json b/go/webhook/testcases/testdata/testcases/customerio/test_15.json new file mode 100644 index 0000000000..192cfe8f97 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_15.json @@ -0,0 +1,73 @@ +{ + "name": "customerio", + "description": "test-15", + "input": { + "request": { + "body": { + "data": { + "action_id": 39, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgQBcRhocpCJE3mFfwvRzNe6", + "href": "http://bing.com", + "link_id": 1, + "recipient": "#signups" + }, + "event_id": "01E4C6HJTBNDX18XC4B88M3Y2G", + "object_type": "slack", + "metric": "clicked", + "timestamp": 1585252451 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "#signups" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Slack Message Link Clicked", + "properties": { + "eventId": "01E4C6HJTBNDX18XC4B88M3Y2G", + "deliveryId": "RPILAgQBcRhocpCJE3mFfwvRzNe6", + "actionId": 39, + "broadcastId": 9, + "link": { + "url": "http://bing.com", + "id": 1 + } + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:54:11.000Z", + "sentAt": "2020-03-26T19:54:11.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_16.json b/go/webhook/testcases/testdata/testcases/customerio/test_16.json new file mode 100644 index 0000000000..c62604cab1 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_16.json @@ -0,0 +1,65 @@ +{ + "name": "customerio", + "description": "test-16", + "input": { + "request": { + "body": { + "data": { + "action_id": 39, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgQBcRhIBqRiZAc0fyQiLvkC", + "failure_message": "value passed for channel was invalid" + }, + "event_id": "01E4C4HDQ77BCN0X23Z3WBE764", + "object_type": "slack", + "metric": "failed", + "timestamp": 1585250350 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Slack Message Failed", + "properties": { + "eventId": "01E4C4HDQ77BCN0X23Z3WBE764", + "deliveryId": "RPILAgQBcRhIBqRiZAc0fyQiLvkC", + "actionId": 39, + "broadcastId": 9, + "reason": "value passed for channel was invalid" + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:19:10.000Z", + "sentAt": "2020-03-26T19:19:10.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_17.json b/go/webhook/testcases/testdata/testcases/customerio/test_17.json new file mode 100644 index 0000000000..3cad7de575 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_17.json @@ -0,0 +1,63 @@ +{ + "name": "customerio", + "description": "test-17", + "input": { + "request": { + "body": { + "data": { + "action_id": 40, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgEBcRhIBqSrYcXDr2ks6Pj9" + }, + "event_id": "01E4C4G1S04QCV1NASF4NWMQNR", + "object_type": "webhook", + "metric": "drafted", + "timestamp": 1585250305 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Webhook Message Drafted", + "properties": { + "eventId": "01E4C4G1S04QCV1NASF4NWMQNR", + "deliveryId": "RPILAgEBcRhIBqSrYcXDr2ks6Pj9", + "actionId": 40, + "broadcastId": 9 + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:18:25.000Z", + "sentAt": "2020-03-26T19:18:25.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_18.json b/go/webhook/testcases/testdata/testcases/customerio/test_18.json new file mode 100644 index 0000000000..b61e3ef31e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_18.json @@ -0,0 +1,65 @@ +{ + "name": "customerio", + "description": "test-18", + "input": { + "request": { + "body": { + "data": { + "action_id": 38, + "broadcast_id": 6, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RAECAQFxNeUBx6LqgjqrN1j-BJc=", + "failure_message": "Variable 'customer.test' is missing" + }, + "event_id": "01E4TYA2KA9T0XGHCRJ784B774", + "object_type": "webhook", + "metric": "attempted", + "timestamp": 1585747134 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Webhook Message Attempted", + "properties": { + "eventId": "01E4TYA2KA9T0XGHCRJ784B774", + "deliveryId": "RAECAQFxNeUBx6LqgjqrN1j-BJc=", + "actionId": 38, + "broadcastId": 6, + "reason": "Variable 'customer.test' is missing" + }, + "userId": "0200102", + "originalTimestamp": "2020-04-01T13:18:54.000Z", + "sentAt": "2020-04-01T13:18:54.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_19.json b/go/webhook/testcases/testdata/testcases/customerio/test_19.json new file mode 100644 index 0000000000..6a5dead233 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_19.json @@ -0,0 +1,67 @@ +{ + "name": "customerio", + "description": "test-19", + "input": { + "request": { + "body": { + "data": { + "action_id": 40, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgEBcRhNAufr2aU82jtDZEh6", + "recipient": "https://test.example.com/process" + }, + "event_id": "01E4C6EP0HCKRHKFARMZ5XEH7A", + "object_type": "webhook", + "metric": "sent", + "timestamp": 1585252357 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "https://test.example.com/process" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Webhook Message Sent", + "properties": { + "eventId": "01E4C6EP0HCKRHKFARMZ5XEH7A", + "deliveryId": "RPILAgEBcRhNAufr2aU82jtDZEh6", + "actionId": 40, + "broadcastId": 9 + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:52:37.000Z", + "sentAt": "2020-03-26T19:52:37.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_2.json b/go/webhook/testcases/testdata/testcases/customerio/test_2.json new file mode 100644 index 0000000000..16bfc11a86 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_2.json @@ -0,0 +1,61 @@ +{ + "name": "customerio", + "description": "test-2", + "input": { + "request": { + "body": { + "data": { + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "email_address": "test@example.com" + }, + "event_id": "01E4C4CT6YDC7Y5M7FE1GWWPQJ", + "object_type": "customer", + "metric": "subscribed", + "timestamp": 1585250199 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Customer Subscribed", + "properties": { + "eventId": "01E4C4CT6YDC7Y5M7FE1GWWPQJ" + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:16:39.000Z", + "sentAt": "2020-03-26T19:16:39.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_20.json b/go/webhook/testcases/testdata/testcases/customerio/test_20.json new file mode 100644 index 0000000000..45e346c553 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_20.json @@ -0,0 +1,73 @@ +{ + "name": "customerio", + "description": "test-20", + "input": { + "request": { + "body": { + "data": { + "action_id": 40, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgEBcRhNAufr2aU82jtDZEh6", + "href": "http://bing.com", + "link_id": 1, + "recipient": "https://test.example.com/process" + }, + "event_id": "01E4C6F5N1Y54TVGJTN64Y1ZS9", + "object_type": "webhook", + "metric": "clicked", + "timestamp": 1585252373 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "https://test.example.com/process" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Webhook Message Link Clicked", + "properties": { + "eventId": "01E4C6F5N1Y54TVGJTN64Y1ZS9", + "deliveryId": "RPILAgEBcRhNAufr2aU82jtDZEh6", + "actionId": 40, + "broadcastId": 9, + "link": { + "url": "http://bing.com", + "id": 1 + } + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:52:53.000Z", + "sentAt": "2020-03-26T19:52:53.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_21.json b/go/webhook/testcases/testdata/testcases/customerio/test_21.json new file mode 100644 index 0000000000..0d7ab767cf --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_21.json @@ -0,0 +1,65 @@ +{ + "name": "customerio", + "description": "test-21", + "input": { + "request": { + "body": { + "data": { + "action_id": 38, + "broadcast_id": 6, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RAECAQFxNeK3bC4SYqhQqFGBQrQ=", + "failure_message": "HTTP 404 Not Found []" + }, + "event_id": "01E4TY5FVB0ZQ4KVDKRME0XSYZ", + "object_type": "webhook", + "metric": "failed", + "timestamp": 1585746984 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Webhook Message Failed", + "properties": { + "eventId": "01E4TY5FVB0ZQ4KVDKRME0XSYZ", + "deliveryId": "RAECAQFxNeK3bC4SYqhQqFGBQrQ=", + "actionId": 38, + "broadcastId": 6, + "reason": "HTTP 404 Not Found []" + }, + "userId": "0200102", + "originalTimestamp": "2020-04-01T13:16:24.000Z", + "sentAt": "2020-04-01T13:16:24.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_22.json b/go/webhook/testcases/testdata/testcases/customerio/test_22.json new file mode 100644 index 0000000000..d68071ef4c --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_22.json @@ -0,0 +1,79 @@ +{ + "name": "customerio", + "description": "test-22", + "input": { + "request": { + "body": { + "data": { + "action_id": 37, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", + "href": "ciosas://product/2", + "link_id": 1, + "recipients": [ + { + "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" + } + ] + }, + "event_id": "01E4V2SBHYK4TNTG8WKMP39G9S", + "object_type": "push", + "metric": "delivered", + "timestamp": 1585751830 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Push Delivered", + "properties": { + "eventId": "01E4V2SBHYK4TNTG8WKMP39G9S", + "deliveryId": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", + "actionId": 37, + "broadcastId": 9, + "link": { + "url": "ciosas://product/2", + "id": 1 + }, + "recipients": [ + { + "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" + } + ] + }, + "userId": "0200102", + "originalTimestamp": "2020-04-01T14:37:10.000Z", + "sentAt": "2020-04-01T14:37:10.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_3.json b/go/webhook/testcases/testdata/testcases/customerio/test_3.json new file mode 100644 index 0000000000..680ab4e55e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_3.json @@ -0,0 +1,61 @@ +{ + "name": "customerio", + "description": "test-3", + "input": { + "request": { + "body": { + "data": { + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "email_address": "test@example.com" + }, + "event_id": "01E4C4C6P79C12J5A6KPE6XNFD", + "object_type": "customer", + "metric": "unsubscribed", + "timestamp": 1585250179 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Customer Unsubscribed", + "properties": { + "eventId": "01E4C4C6P79C12J5A6KPE6XNFD" + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:16:19.000Z", + "sentAt": "2020-03-26T19:16:19.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_4.json b/go/webhook/testcases/testdata/testcases/customerio/test_4.json new file mode 100644 index 0000000000..bc152b34fd --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_4.json @@ -0,0 +1,63 @@ +{ + "name": "customerio", + "description": "test-4", + "input": { + "request": { + "body": { + "data": { + "action_id": 36, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgABcRhIBqSp7kiPekGBIeVh" + }, + "event_id": "01E4C4G1S0AMNG0XVF2M7RPH5S", + "object_type": "email", + "metric": "drafted", + "timestamp": 1585250305 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Email Drafted", + "properties": { + "eventId": "01E4C4G1S0AMNG0XVF2M7RPH5S", + "deliveryId": "RPILAgABcRhIBqSp7kiPekGBIeVh", + "actionId": 36, + "broadcastId": 9 + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T19:18:25.000Z", + "sentAt": "2020-03-26T19:18:25.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_5.json b/go/webhook/testcases/testdata/testcases/customerio/test_5.json new file mode 100644 index 0000000000..c8a0aa084e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_5.json @@ -0,0 +1,71 @@ +{ + "name": "customerio", + "description": "test-5", + "input": { + "request": { + "body": { + "data": { + "content_id": 1146, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=", + "failure_message": "550 5.5.0 Requested action not taken: mailbox unavailable", + "newsletter_id": 736, + "recipient": "test@example.com", + "subject": "Thanks for joining!" + }, + "event_id": "12ASDG7S9P6MAZPTJ78DAND9GDC", + "object_type": "email", + "metric": "bounced", + "timestamp": 1234567890 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Email Bounced", + "properties": { + "eventId": "12ASDG7S9P6MAZPTJ78DAND9GDC", + "deliveryId": "RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=", + "contentId": 1146, + "emailSubject": "Thanks for joining!", + "reason": "550 5.5.0 Requested action not taken: mailbox unavailable", + "newsletterId": 736 + }, + "userId": "0200102", + "originalTimestamp": "2009-02-13T23:31:30.000Z", + "sentAt": "2009-02-13T23:31:30.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_6.json b/go/webhook/testcases/testdata/testcases/customerio/test_6.json new file mode 100644 index 0000000000..0d8ab9190b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_6.json @@ -0,0 +1,75 @@ +{ + "name": "customerio", + "description": "test-6", + "input": { + "request": { + "body": { + "data": { + "action_id": 36, + "broadcast_id": 9, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RPILAgABcRhIBqSp7kiPekGBIeVh", + "href": "http://google.com", + "link_id": 1, + "recipient": "test@example.com", + "subject": "hello" + }, + "event_id": "01E4C8BES5XT87ZWRJFTB35YJ3", + "object_type": "email", + "metric": "clicked", + "timestamp": 1585254348 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Email Link Clicked", + "properties": { + "eventId": "01E4C8BES5XT87ZWRJFTB35YJ3", + "deliveryId": "RPILAgABcRhIBqSp7kiPekGBIeVh", + "actionId": 36, + "broadcastId": 9, + "emailSubject": "hello", + "link": { + "url": "http://google.com", + "id": 1 + } + }, + "userId": "0200102", + "originalTimestamp": "2020-03-26T20:25:48.000Z", + "sentAt": "2020-03-26T20:25:48.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_7.json b/go/webhook/testcases/testdata/testcases/customerio/test_7.json new file mode 100644 index 0000000000..870810f187 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_7.json @@ -0,0 +1,74 @@ +{ + "name": "customerio", + "description": "test-7", + "input": { + "request": { + "body": { + "data": { + "action_id": 42, + "campaign_id": 23, + "content": "Welcome to the club, we are with you.", + "customer_id": "user-123", + "delivery_id": "RAECAAFwnUSneIa0ZXkmq8EdkAM==", + "headers": { + "Custom-Header": ["custom-value"] + }, + "identifiers": { + "id": "user-123" + }, + "recipient": "test@example.com", + "subject": "Thanks for signing up" + }, + "event_id": "01E2EMRMM6TZ12TF9WGZN0WJQT", + "metric": "sent", + "object_type": "email", + "timestamp": 1644227937 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Email Sent", + "properties": { + "eventId": "01E2EMRMM6TZ12TF9WGZN0WJQT", + "deliveryId": "RAECAAFwnUSneIa0ZXkmq8EdkAM==", + "actionId": 42, + "content": "Welcome to the club, we are with you.", + "emailSubject": "Thanks for signing up", + "campaignId": 23 + }, + "userId": "user-123", + "originalTimestamp": "2022-02-07T09:58:57.000Z", + "sentAt": "2022-02-07T09:58:57.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_8.json b/go/webhook/testcases/testdata/testcases/customerio/test_8.json new file mode 100644 index 0000000000..bad7038c6d --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_8.json @@ -0,0 +1,69 @@ +{ + "name": "customerio", + "description": "test-8", + "input": { + "request": { + "body": { + "data": { + "customer_id": "user-123", + "delivery_id": "REAC4wUAAYYJgQgkyRqwwEPeOA6Nfv==", + "identifiers": { + "cio_id": "7ef807109981", + "id": "user-123" + }, + "recipient": "test@example.com", + "subject": "Thanks for signing up", + "transactional_message_id": 2 + }, + "event_id": "01ER4R5WB62QWCNREKFB4DYXGR", + "metric": "delivered", + "object_type": "email", + "timestamp": 1675196819 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + }, + "traits": { + "cioId": "7ef807109981", + "email": "test@example.com" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Email Delivered", + "properties": { + "eventId": "01ER4R5WB62QWCNREKFB4DYXGR", + "deliveryId": "REAC4wUAAYYJgQgkyRqwwEPeOA6Nfv==", + "emailSubject": "Thanks for signing up", + "transactionalMessageId": 2 + }, + "userId": "user-123", + "originalTimestamp": "2023-01-31T20:26:59.000Z", + "sentAt": "2023-01-31T20:26:59.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/customerio/test_9.json b/go/webhook/testcases/testdata/testcases/customerio/test_9.json new file mode 100644 index 0000000000..0685f3fd3e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/customerio/test_9.json @@ -0,0 +1,65 @@ +{ + "name": "customerio", + "description": "test-9", + "input": { + "request": { + "body": { + "data": { + "action_id": 38, + "campaign_id": 6, + "customer_id": "0200102", + "identifiers": { + "id": "0200102" + }, + "delivery_id": "RAEABQFxN56fWzydfV4_EGvfobI=", + "failure_message": "NoDevicesSynced" + }, + "event_id": "01E4VSX8SZ0T9AQMH4Q16NRB89", + "object_type": "push", + "metric": "attempted", + "timestamp": 1585776075 + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Customer.io" + } + }, + "integrations": { + "Customer.io": false + }, + "type": "track", + "event": "Push Attempted", + "properties": { + "eventId": "01E4VSX8SZ0T9AQMH4Q16NRB89", + "deliveryId": "RAEABQFxN56fWzydfV4_EGvfobI=", + "actionId": 38, + "reason": "NoDevicesSynced", + "campaignId": 6 + }, + "userId": "0200102", + "originalTimestamp": "2020-04-01T21:21:15.000Z", + "sentAt": "2020-04-01T21:21:15.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/formsort/when_we_receive_finalized_as_false.json b/go/webhook/testcases/testdata/testcases/formsort/when_we_receive_finalized_as_false.json new file mode 100644 index 0000000000..77a14c0b74 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/formsort/when_we_receive_finalized_as_false.json @@ -0,0 +1,66 @@ +{ + "name": "formsort", + "description": "when we receive finalized as false", + "input": { + "request": { + "body": { + "answers": { + "yes": true, + "enter_email": "test@user.com", + "enter_name": "2022-11-17", + "yes_or_no": false + }, + "responder_uuid": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", + "flow_label": "new-flow-2022-11-25", + "variant_label": "main", + "variant_uuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea", + "finalized": false, + "created_at": "2022-11-25T14:41:22+00:00" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Formsort" + }, + "page": { + "title": "new-flow-2022-11-25" + }, + "variantLabel": "main", + "variantUuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea" + }, + "integrations": { + "Formsort": false + }, + "type": "track", + "userId": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", + "originalTimestamp": "2022-11-25T14:41:22+00:00", + "properties": { + "yes": true, + "enter_email": "test@user.com", + "enter_name": "2022-11-17", + "yes_or_no": false + }, + "event": "FlowLoaded", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/formsort/when_we_receive_finalized_as_true.json b/go/webhook/testcases/testdata/testcases/formsort/when_we_receive_finalized_as_true.json new file mode 100644 index 0000000000..63fe193698 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/formsort/when_we_receive_finalized_as_true.json @@ -0,0 +1,66 @@ +{ + "name": "formsort", + "description": "when we receive finalized as true", + "input": { + "request": { + "body": { + "answers": { + "yes": true, + "enter_email": "test@user.com", + "enter_name": "2022-11-17", + "yes_or_no": false + }, + "responder_uuid": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", + "flow_label": "new-flow-2022-11-25", + "variant_label": "main", + "variant_uuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea", + "finalized": true, + "created_at": "2022-11-25T14:41:22+00:00" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Formsort" + }, + "page": { + "title": "new-flow-2022-11-25" + }, + "variantLabel": "main", + "variantUuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea" + }, + "integrations": { + "Formsort": false + }, + "type": "track", + "userId": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", + "originalTimestamp": "2022-11-25T14:41:22+00:00", + "properties": { + "yes": true, + "enter_email": "test@user.com", + "enter_name": "2022-11-17", + "yes_or_no": false + }, + "event": "FlowFinalized", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/custom_track_call_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/custom_track_call_.json new file mode 100644 index 0000000000..049e995900 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/custom_track_call_.json @@ -0,0 +1,182 @@ +{ + "name": "gainsightpx", + "description": "Custom Track Call ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "CUSTOM", + "eventId": "df58cbd6-2736-4f8a-ad26-6049eac2e150", + "propertyKey": "AP-EOXPSEZGC5LA-2-1", + "date": 1665656881448, + "sessionId": "AP-EOXPSEZGC5LA-2-1665656622955-48127533", + "globalContext": {}, + "userType": "USER", + "eventName": "Product Clicked", + "attributes": { + "Audience Size": 5000, + "name": "TESTing TRACK CALL FIRST", + "Launched date": 1520532660000, + "Launched": true + }, + "url": "http://127.0.0.1:5501/GPXTEST2.html", + "referrer": "", + "remoteHost": "122.161.66.140" + }, + "configId": "32f07727-d231-4c9d-881e-fb50b80bad63" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "ip": "122.161.66.140", + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-EOXPSEZGC5LA-2-1", + "Audience Size": 5000, + "name": "TESTing TRACK CALL FIRST", + "Launched date": 1520532660000, + "Launched": true, + "ip": "122.161.66.140", + "url": "http://127.0.0.1:5501/GPXTEST2.html" + }, + "userId": "New!", + "category": "CUSTOM", + "event": "Product Clicked", + "sentAt": "2022-10-13T10:28:01.448Z", + "originalTimestamp": "2022-10-13T10:28:01.448Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/engagement_track_call_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/engagement_track_call_.json new file mode 100644 index 0000000000..986c261281 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/engagement_track_call_.json @@ -0,0 +1,186 @@ +{ + "name": "gainsightpx", + "description": "Engagement Track Call ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "ENGAGEMENT", + "eventId": "6494e73a-976b-4ee5-b8a8-de9effff7e80", + "propertyKey": "AP-N6SV00EVMR1E-2-1", + "date": 1605262539389, + "sessionId": "AP-N6SV00EVMR1E-2-1605262502068-24197555", + "globalContext": { + "role": "Admin" + }, + "userType": "EMPTY_USER_TYPE", + "contentType": "IN_APP_DIALOG", + "engagementId": "83c30d4e-88c3-4054-a0fa-33451a6ea7fc", + "engagementType": "Dialog", + "engagementName": "Release Announcement", + "interaction": "VIEWED", + "stepNumber": 1, + "activation": "Auto", + "executionId": "b633945f-d4a5-404a-ae39-5ced5b542240", + "executionDate": 1605262539389 + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-N6SV00EVMR1E-2-1", + "engagementId": "83c30d4e-88c3-4054-a0fa-33451a6ea7fc", + "contentType": "IN_APP_DIALOG", + "engagementType": "Dialog", + "interaction": "VIEWED", + "globalContext": { + "role": "Admin" + }, + "engagement": { + "stepNumber": 1, + "activation": "Auto" + } + }, + "userId": "New!", + "category": "ENGAGEMENT", + "event": "Release Announcement", + "sentAt": "2020-11-13T10:15:39.389Z", + "originalTimestamp": "2020-11-13T10:15:39.389Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/feature_match_track_call_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/feature_match_track_call_.json new file mode 100644 index 0000000000..a0c5c0dac0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/feature_match_track_call_.json @@ -0,0 +1,172 @@ +{ + "name": "gainsightpx", + "description": "Feature Match Track Call ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "FEATURE_MATCH", + "eventId": "ae1e5538-1736-4088-86d1-e90a10ffe901-05951b40-944f-4052-9a4a-51c74683f658", + "propertyKey": "AP-8MF5LPSWUBFW-2-1", + "date": 1665582808376, + "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", + "globalContext": { + "role": "Admin" + }, + "userType": "USER", + "featureId": "05951b40-944f-4052-9a4a-51c74683f658", + "featureName": "Charts" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-8MF5LPSWUBFW-2-1", + "globalContext": { + "role": "Admin" + }, + "featureId": "05951b40-944f-4052-9a4a-51c74683f658" + }, + "userId": "New!", + "category": "FEATURE_MATCH", + "event": "Charts", + "sentAt": "2022-10-12T13:53:28.376Z", + "originalTimestamp": "2022-10-12T13:53:28.376Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/feedback_track_call_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/feedback_track_call_.json new file mode 100644 index 0000000000..e79d0da018 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/feedback_track_call_.json @@ -0,0 +1,179 @@ +{ + "name": "gainsightpx", + "description": "Feedback Track Call ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "FEEDBACK", + "eventId": "d007bd76-decb-4a77-8456-d84fb15c6a83", + "propertyKey": "AP-E9VUBBLZ6BIS-2-1", + "date": 1665415753621, + "sessionId": "AP-E9VUBBLZ6BIS-2-1665415678379-45445457", + "globalContext": null, + "userType": "USER", + "subject": "feedback title", + "category": "Labels test", + "description": "feedback body", + "labels": ["492120f5-3573-11ec-bef0-42010a800545"], + "remoteHost": "122.161.66.140", + "source": "Knowledge Center Bot" + }, + "configId": "32f07727-d231-4c9d-881e-fb50b80bad63" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ], + "ip": "122.161.66.140" + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-E9VUBBLZ6BIS-2-1", + "feedback": { + "labels": ["492120f5-3573-11ec-bef0-42010a800545"], + "description": "feedback body", + "subject": "feedback title", + "source": "Knowledge Center Bot" + }, + "ip": "122.161.66.140" + }, + "userId": "New!", + "category": "FEEDBACK", + "event": "Labels test", + "sentAt": "2022-10-10T15:29:13.621Z", + "originalTimestamp": "2022-10-10T15:29:13.621Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/identify_call.json b/go/webhook/testcases/testdata/testcases/gainsightpx/identify_call.json new file mode 100644 index 0000000000..661ec98ba4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/identify_call.json @@ -0,0 +1,160 @@ +{ + "name": "gainsightpx", + "description": "Identify Call", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "SIGN_UP", + "eventId": "1283c08b-f290-4bc4-9deb-75c7867d69ee", + "propertyKey": "AP-EOXPSEZGC5LA-2-1", + "date": 1665582808376, + "sessionId": "AP-EOXPSEZGC5LA-2-1665582441084-16821368", + "globalContext": {}, + "userType": "USER" + }, + "configId": "32f07727-d231-4c9d-881e-fb50b80bad63" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "identify", + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "score": 0, + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "id": "New!", + "country": "India", + "account": { + "id": "IBM", + "name": "International Business Machine", + "numberOfEmployees": 0, + "numberOfUsers": 0 + } + }, + "userId": "New!", + "createdAt": "2022-10-12T13:53:11.753Z", + "originalTimestamp": "2022-10-12T13:53:11.753Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/no_match_track_call_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/no_match_track_call_.json new file mode 100644 index 0000000000..a86f4d886c --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/no_match_track_call_.json @@ -0,0 +1,50 @@ +{ + "name": "gainsightpx", + "description": "No Match Track Call ", + "input": { + "request": { + "body": { + "event": { + "eventType": "Unavailable", + "eventId": "ddb9ca94-beb1-449c-bdcd-b53190f8e784", + "propertyKey": "AP-8MF5LPSWUBFW-2-1", + "date": 1601303075964, + "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", + "globalContext": { + "role": "Admin" + }, + "userType": "USER", + "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845", + "segmentName": "Linux User" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Event type Unavailable not supported\n" + }, + "queue": [], + "errQueue": [ + { + "event": { + "eventType": "Unavailable", + "eventId": "ddb9ca94-beb1-449c-bdcd-b53190f8e784", + "propertyKey": "AP-8MF5LPSWUBFW-2-1", + "date": 1601303075964, + "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", + "globalContext": { + "role": "Admin" + }, + "userType": "USER", + "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845", + "segmentName": "Linux User" + } + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/segment_io_s2_s_track_call_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/segment_io_s2_s_track_call_.json new file mode 100644 index 0000000000..bc08b7ab52 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/segment_io_s2_s_track_call_.json @@ -0,0 +1,222 @@ +{ + "name": "gainsightpx", + "description": "SegmentIO S2S Track Call ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "SEGMENT_IO", + "eventId": "ajs-next-69810a17571dc115ccead5281cc3fb7d", + "propertyKey": "AP-EOXPSEZGC5LA-2-1", + "date": 1666687235178, + "sessionId": "31a524fa-1490-48db-9600-adfb1fa95333", + "globalContext": {}, + "userType": "USER", + "segmentIOEvent": { + "pxPropertyKey": "AP-EOXPSEZGC5LA-2", + "type": "group", + "userId": "1001", + "anonymousId": "a4303a13-eb10-46d8-8935-d787daf1cfbd", + "context": { + "ip": "122.161.67.121", + "library": { + "name": "analytics.js", + "version": "next-1.45.0" + }, + "locale": "en-GB", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36", + "page": { + "path": "/abc.html", + "title": "Engage Testing", + "url": "http://127.0.0.1:5501/abc.html" + } + }, + "messageId": "ajs-next-69810a17571dc115ccead5281cc3fb7d", + "receivedAt": "2022-10-25T08:40:35.184Z", + "sentAt": "2022-10-25T08:40:34.809Z", + "timestamp": "2022-10-25T08:40:35.178Z", + "traits": { + "name": "International Business Machine" + }, + "version": 2, + "channel": "client", + "groupId": "IBM" + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-EOXPSEZGC5LA-2-1", + "pxPropertyKey": "AP-EOXPSEZGC5LA-2", + "type": "group", + "userId": "1001", + "anonymousId": "a4303a13-eb10-46d8-8935-d787daf1cfbd", + "context": { + "ip": "122.161.67.121", + "library": { + "name": "analytics.js", + "version": "next-1.45.0" + }, + "locale": "en-GB", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36", + "page": { + "path": "/abc.html", + "title": "Engage Testing", + "url": "http://127.0.0.1:5501/abc.html" + } + }, + "messageId": "ajs-next-69810a17571dc115ccead5281cc3fb7d", + "receivedAt": "2022-10-25T08:40:35.184Z", + "sentAt": "2022-10-25T08:40:34.809Z", + "timestamp": "2022-10-25T08:40:35.178Z", + "traits": { + "name": "International Business Machine" + }, + "version": 2, + "channel": "client", + "groupId": "IBM" + }, + "userId": "New!", + "category": "SEGMENT_IO", + "event": "SegmentIO Cloud Server", + "sentAt": "2022-10-25T08:40:35.178Z", + "originalTimestamp": "2022-10-25T08:40:35.178Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/segment_match_track_call_and_no_user_id_and_yes_anonymous_id_as_event_session_id.json b/go/webhook/testcases/testdata/testcases/gainsightpx/segment_match_track_call_and_no_user_id_and_yes_anonymous_id_as_event_session_id.json new file mode 100644 index 0000000000..ad2eb03584 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/segment_match_track_call_and_no_user_id_and_yes_anonymous_id_as_event_session_id.json @@ -0,0 +1,171 @@ +{ + "name": "gainsightpx", + "description": "Segment Match Track Call and no userId and yes anonymousId as event.sessionId", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "SEGMENT", + "eventId": "ddb9ca94-beb1-449c-bdcd-b53190f8e784", + "propertyKey": "AP-8MF5LPSWUBFW-2-1", + "date": 1665582808376, + "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", + "globalContext": { + "role": "Admin" + }, + "userType": "USER", + "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845", + "segmentName": "Linux User" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-8MF5LPSWUBFW-2-1", + "globalContext": { + "role": "Admin" + }, + "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845" + }, + "category": "SEGMENT", + "event": "Linux User", + "sentAt": "2022-10-12T13:53:28.376Z", + "originalTimestamp": "2022-10-12T13:53:28.376Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/survey_track_call____multi_question_survey_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/survey_track_call____multi_question_survey_.json new file mode 100644 index 0000000000..20612bd56f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/survey_track_call____multi_question_survey_.json @@ -0,0 +1,208 @@ +{ + "name": "gainsightpx", + "description": "Survey Track Call -> Multi Question Survey ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "SURVEY", + "eventId": "c9883e3b-05d4-4f96-8b9c-e2ce10430493", + "propertyKey": "AP-N6SV00EVMR1E-2-1", + "date": 1601303075964, + "sessionId": "AP-N6SV00EVMR1E-2-1605265939566-23853426", + "globalContext": { + "role": "Admin" + }, + "userType": "EMPTY_USER_TYPE", + "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", + "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", + "engagementName": "Quarterly Survey", + "surveyType": "Multi Question", + "interaction": "SINGLE_STEP_SURVEY_RESPONDED", + "score": 0, + "activation": "Auto", + "executionId": "1ad2d383-d1fa-425d-84f0-2a531e17a5d9", + "executionDate": 1605265939965, + "questionType": "Multi choice", + "questionId": "de9e6bf1-351c-46ec-907d-c985bd420c2b", + "questionHtml": "
Favorite travel destinations
", + "questionText": "Favorite travel destinations", + "answers": [ + { + "answerId": "563e2103-2906-4088-869f-bcccd185f288", + "answerHtml": "
Europe
", + "answerText": "Europe" + } + ] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-N6SV00EVMR1E-2-1", + "globalContext": { + "role": "Admin" + }, + "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", + "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", + "surveyType": "Multi Question", + "interaction": "SINGLE_STEP_SURVEY_RESPONDED", + "survey": { + "activation": "Auto", + "questionType": "Multi choice", + "score": 0, + "questionId": "de9e6bf1-351c-46ec-907d-c985bd420c2b", + "questionHtml": "
Favorite travel destinations
", + "questionText": "Favorite travel destinations", + "answers": [ + { + "answerId": "563e2103-2906-4088-869f-bcccd185f288", + "answerHtml": "
Europe
", + "answerText": "Europe" + } + ] + } + }, + "userId": "New!", + "category": "SURVEY", + "event": "Quarterly Survey", + "sentAt": "2020-09-28T14:24:35.964Z", + "originalTimestamp": "2020-09-28T14:24:35.964Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/gainsightpx/survey_track_call____nps_.json b/go/webhook/testcases/testdata/testcases/gainsightpx/survey_track_call____nps_.json new file mode 100644 index 0000000000..8482f26cdc --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/gainsightpx/survey_track_call____nps_.json @@ -0,0 +1,196 @@ +{ + "name": "gainsightpx", + "description": "Survey Track Call -> NPS ", + "input": { + "request": { + "body": { + "user": { + "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", + "identifyId": "New!", + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "lastSeenDate": 1665582808669, + "signUpDate": 1665582791753, + "firstVisitDate": 1665582791753, + "title": "Mr.", + "phone": "", + "score": 0, + "role": "", + "subscriptionId": "", + "accountId": "IBM", + "numberOfVisits": 1, + "location": { + "countryName": "India", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665582808376, + "lastModifiedDate": 1665582808717, + "customAttributes": null, + "globalUnsubscribe": false, + "sfdcContactId": "", + "lastVisitedUserAgentData": null, + "id": "New!", + "lastInferredLocation": null + }, + "account": { + "id": "IBM", + "name": "International Business Machine", + "trackedSubscriptionId": "", + "sfdcId": "", + "lastSeenDate": 1665582808669, + "dunsNumber": "", + "industry": "", + "numberOfEmployees": 0, + "sicCode": "", + "website": "", + "naicsCode": "", + "plan": "", + "location": { + "countryName": "", + "countryCode": "", + "stateName": "", + "stateCode": "", + "city": "", + "street": "", + "postalCode": "", + "continent": "", + "regionName": "", + "timeZone": "", + "coordinates": { + "latitude": 0, + "longitude": 0 + } + }, + "numberOfUsers": 0, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "createDate": 1665578567565, + "lastModifiedDate": 1665582808669, + "customAttributes": null, + "parentGroupId": "" + }, + "event": { + "eventType": "SURVEY", + "eventId": "c9883e3b-05d4-4f96-8b9c-e2ce10430493", + "propertyKey": "AP-N6SV00EVMR1E-2-1", + "date": 1601303075964, + "sessionId": "AP-N6SV00EVMR1E-2-1605265939566-23853426", + "globalContext": { + "role": "Admin" + }, + "userType": "EMPTY_USER_TYPE", + "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", + "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", + "engagementName": "Quarterly Survey", + "surveyType": "Multi Question", + "interaction": "SINGLE_STEP_SURVEY_RESPONDED", + "score": 0, + "scoreType": null, + "stepNumber": null, + "userInput": "I like new features", + "activation": "Auto", + "executionId": "1ad2d383-d1fa-425d-84f0-2a531e17a5d9", + "executionDate": 1605265939965, + "questionType": "Open text question", + "questionHtml": "
\n
\n How was your experience?\n
\n
\n", + "questionText": "How was your experience?" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "GAINSIGHTPX" + }, + "traits": { + "type": "USER", + "gender": "EMPTY_GENDER", + "email": "userEmail@address.com", + "firstName": "test", + "lastName": "rudderlabs", + "title": "Mr.", + "globalUnsubscribe": false, + "accountId": "IBM", + "numberOfVisits": 1, + "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], + "score": 0, + "id": "New!", + "country": "India", + "account": { + "numberOfEmployees": 0, + "numberOfUsers": 0, + "id": "IBM", + "name": "International Business Machine" + } + }, + "externalId": [ + { + "type": "gainsightpxAptrinsicId", + "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" + } + ] + }, + "integrations": { + "GAINSIGHTPX": false + }, + "type": "track", + "properties": { + "propertyKey": "AP-N6SV00EVMR1E-2-1", + "globalContext": { + "role": "Admin" + }, + "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", + "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", + "surveyType": "Multi Question", + "interaction": "SINGLE_STEP_SURVEY_RESPONDED", + "survey": { + "activation": "Auto", + "userInput": "I like new features", + "questionType": "Open text question", + "score": 0, + "questionHtml": "
\n
\n How was your experience?\n
\n
\n", + "questionText": "How was your experience?" + } + }, + "userId": "New!", + "category": "SURVEY", + "event": "Quarterly Survey", + "sentAt": "2020-09-28T14:24:35.964Z", + "originalTimestamp": "2020-09-28T14:24:35.964Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_0.json b/go/webhook/testcases/testdata/testcases/iterable/test_0.json new file mode 100644 index 0000000000..5d0f8813ed --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_0.json @@ -0,0 +1,68 @@ +{ + "name": "iterable", + "description": "test-0", + "input": { + "request": { + "body": { + "email": "test@rudderstack.com", + "eventName": "emailSubscribe", + "dataFields": { + "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", + "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", + "signupSource": "WebForm", + "email": "test@rudderstack.com", + "createdAt": "2022-04-19 03:33:50 +00:00", + "messageTypeIds": [], + "emailListIds": [1589748], + "channelIds": [] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "test@rudderstack.com" + } + }, + "event": "emailSubscribe", + "integrations": { + "Iterable": false + }, + "properties": { + "channelIds": [], + "createdAt": "2022-04-19 03:33:50 +00:00", + "emailListIds": [1589748], + "messageTypeIds": [], + "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", + "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", + "signupSource": "WebForm" + }, + "receivedAt": "2022-04-19T03:33:50.000Z", + "timestamp": "2022-04-19T03:33:50.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_1.json b/go/webhook/testcases/testdata/testcases/iterable/test_1.json new file mode 100644 index 0000000000..64ad1c7bd4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_1.json @@ -0,0 +1,46 @@ +{ + "name": "iterable", + "description": "test-1", + "input": { + "request": { + "body": { + "eventName": "emailSubscribe", + "dataFields": { + "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", + "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", + "signupSource": "WebForm", + "email": "test@abcd.com", + "createdAt": "2022-04-19 03:33:50 +00:00", + "messageTypeIds": [], + "emailListIds": [1589748], + "channelIds": [] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Unknwon event type from Iterable\n" + }, + "queue": [], + "errQueue": [ + { + "eventName": "emailSubscribe", + "dataFields": { + "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", + "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", + "signupSource": "WebForm", + "email": "test@abcd.com", + "createdAt": "2022-04-19 03:33:50 +00:00", + "messageTypeIds": [], + "emailListIds": [1589748], + "channelIds": [] + } + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_10.json b/go/webhook/testcases/testdata/testcases/iterable/test_10.json new file mode 100644 index 0000000000..fd5e4d68c8 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_10.json @@ -0,0 +1,68 @@ +{ + "name": "iterable", + "description": "test-10", + "input": { + "request": { + "body": { + "email": "test@rudderstack.com", + "eventName": "emailSubscribe", + "dataFields": { + "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", + "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", + "signupSource": "WebForm", + "email": "test@abcd.com", + "createdAt": "2022-04-19 03:33:50 +00:00", + "messageTypeIds": [], + "emailListIds": [1589748], + "channelIds": [] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "test@rudderstack.com" + } + }, + "event": "emailSubscribe", + "integrations": { + "Iterable": false + }, + "properties": { + "channelIds": [], + "createdAt": "2022-04-19 03:33:50 +00:00", + "emailListIds": [1589748], + "messageTypeIds": [], + "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", + "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", + "signupSource": "WebForm" + }, + "receivedAt": "2022-04-19T03:33:50.000Z", + "timestamp": "2022-04-19T03:33:50.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_11.json b/go/webhook/testcases/testdata/testcases/iterable/test_11.json new file mode 100644 index 0000000000..7406688269 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_11.json @@ -0,0 +1,92 @@ +{ + "name": "iterable", + "description": "test-11", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "emailUnSubscribe", + "dataFields": { + "campaignId": 1089024, + "messageId": "bf008db8ab194b65816398c05bf30f99", + "emailId": "c1089024:t1526112:docs@iterable.com", + "workflowName": "My test workflow", + "messageTypeIds": [], + "locale": null, + "templateId": 1526112, + "emailSubject": "Upcoming events!", + "labels": [], + "unsubSource": "EmailLink", + "createdAt": "2020-03-20 23:34:15 +00:00", + "templateName": "My test template", + "emailListIds": [], + "messageTypeId": 31082, + "experimentId": null, + "channelIds": [27447], + "campaignName": "My test campaign", + "workflowId": 76786, + "email": "docs@iterable.com", + "channelId": 27447 + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "emailUnSubscribe", + "integrations": { + "Iterable": false + }, + "properties": { + "campaignId": 1089024, + "messageId": "bf008db8ab194b65816398c05bf30f99", + "emailId": "c1089024:t1526112:docs@iterable.com", + "workflowName": "My test workflow", + "messageTypeIds": [], + "locale": null, + "templateId": 1526112, + "emailSubject": "Upcoming events!", + "labels": [], + "unsubSource": "EmailLink", + "createdAt": "2020-03-20 23:34:15 +00:00", + "templateName": "My test template", + "emailListIds": [], + "messageTypeId": 31082, + "experimentId": null, + "channelIds": [27447], + "campaignName": "My test campaign", + "workflowId": 76786, + "channelId": 27447 + }, + "receivedAt": "2020-03-20T23:34:15.000Z", + "timestamp": "2020-03-20T23:34:15.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_12.json b/go/webhook/testcases/testdata/testcases/iterable/test_12.json new file mode 100644 index 0000000000..faf0aa1c2b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_12.json @@ -0,0 +1,99 @@ +{ + "name": "iterable", + "description": "test-12", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "userId": "1", + "eventName": "hostedUnsubscribeClick", + "dataFields": { + "country": "United States", + "city": "San Jose", + "campaignId": 1074721, + "ip": "192.168.0.1", + "userAgentDevice": "Mac", + "messageId": "ceb3d4d929fc406ca93b28a0ef1efff1", + "emailId": "c1074721:t1506266:docs@iterable.com", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36", + "workflowName": "My workflow", + "locale": null, + "templateId": 1506266, + "emailSubject": "My email subject", + "url": "https://iterable.com", + "labels": [], + "createdAt": "2020-03-21 00:24:08 +00:00", + "templateName": "My email template", + "messageTypeId": 13406, + "experimentId": null, + "region": "CA", + "campaignName": "My email campaign", + "workflowId": 60102, + "email": "docs@iterable.com", + "channelId": 12466 + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "1", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "hostedUnsubscribeClick", + "integrations": { + "Iterable": false + }, + "properties": { + "country": "United States", + "city": "San Jose", + "campaignId": 1074721, + "ip": "192.168.0.1", + "userAgentDevice": "Mac", + "messageId": "ceb3d4d929fc406ca93b28a0ef1efff1", + "emailId": "c1074721:t1506266:docs@iterable.com", + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36", + "workflowName": "My workflow", + "locale": null, + "templateId": 1506266, + "emailSubject": "My email subject", + "url": "https://iterable.com", + "labels": [], + "createdAt": "2020-03-21 00:24:08 +00:00", + "templateName": "My email template", + "messageTypeId": 13406, + "experimentId": null, + "region": "CA", + "campaignName": "My email campaign", + "workflowId": 60102, + "channelId": 12466 + }, + "receivedAt": "2020-03-21T00:24:08.000Z", + "timestamp": "2020-03-21T00:24:08.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_13.json b/go/webhook/testcases/testdata/testcases/iterable/test_13.json new file mode 100644 index 0000000000..1ea97852e1 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_13.json @@ -0,0 +1,58 @@ +{ + "name": "iterable", + "description": "test-13", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "inAppClick", + "dataFields": { + "email": "docs@iterable.com", + "createdAt": "2018-03-27 00:44:40 +00:00", + "campaignId": 269450 + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "inAppClick", + "integrations": { + "Iterable": false + }, + "properties": { + "createdAt": "2018-03-27 00:44:40 +00:00", + "campaignId": 269450 + }, + "receivedAt": "2018-03-27T00:44:40.000Z", + "timestamp": "2018-03-27T00:44:40.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_14.json b/go/webhook/testcases/testdata/testcases/iterable/test_14.json new file mode 100644 index 0000000000..1cda4ea9e8 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_14.json @@ -0,0 +1,58 @@ +{ + "name": "iterable", + "description": "test-14", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "inAppOpen", + "dataFields": { + "email": "docs@iterable.com", + "createdAt": "2018-03-27 00:44:30 +00:00", + "campaignId": 269450 + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "inAppOpen", + "integrations": { + "Iterable": false + }, + "properties": { + "createdAt": "2018-03-27 00:44:30 +00:00", + "campaignId": 269450 + }, + "receivedAt": "2018-03-27T00:44:30.000Z", + "timestamp": "2018-03-27T00:44:30.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_15.json b/go/webhook/testcases/testdata/testcases/iterable/test_15.json new file mode 100644 index 0000000000..34ea6dcd74 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_15.json @@ -0,0 +1,96 @@ +{ + "name": "iterable", + "description": "test-15", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "inAppSend", + "dataFields": { + "messageContext": { + "saveToInbox": false, + "trigger": "immediate" + }, + "campaignId": 732678, + "contentId": 18997, + "messageId": "vA16d48VVi4LQ5hMuZuquKzL0BXTdQJJUMJRjKnL1", + "workflowName": null, + "emailId": "c732678:t1032729:docs@iterable.com", + "locale": null, + "templateId": 1032729, + "inAppBody": "", + "email": "docs@iterable.com", + "createdAt": "2016-12-10 01:00:38 +00:00", + "campaignId": 74768, + "templateId": 113554, + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2203, + "messageTypeId": 2439, + "experimentId": null, + "payload": { + "path": "yourpath/subpath" + }, + "sound": "", + "badge": null, + "contentAvailable": false, + "deeplink": null, + "locale": null + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "pushBounce", + "integrations": { + "Iterable": false + }, + "properties": { + "platformEndpoint": "", + "createdAt": "2016-12-10 01:00:38 +00:00", + "campaignId": 74768, + "templateId": 113554, + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2203, + "messageTypeId": 2439, + "experimentId": null, + "payload": { + "path": "yourpath/subpath" + }, + "sound": "", + "badge": null, + "contentAvailable": false, + "deeplink": null, + "locale": null + }, + "receivedAt": "2016-12-10T01:00:38.000Z", + "timestamp": "2016-12-10T01:00:38.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_18.json b/go/webhook/testcases/testdata/testcases/iterable/test_18.json new file mode 100644 index 0000000000..f407de768b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_18.json @@ -0,0 +1,94 @@ +{ + "name": "iterable", + "description": "test-18", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "pushOpen", + "dataFields": { + "appAlreadyRunning": false, + "email": "docs@iterable.com", + "createdAt": "2016-12-08 01:25:22 +00:00", + "campaignId": 74768, + "templateId": 113554, + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2203, + "messageTypeId": 2439, + "experimentId": null, + "payload": { + "path": "shop_home" + }, + "sound": null, + "badge": null, + "contentAvailable": false, + "deeplink": null, + "locale": null + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "pushOpen", + "integrations": { + "Iterable": false + }, + "properties": { + "appAlreadyRunning": false, + "createdAt": "2016-12-08 01:25:22 +00:00", + "campaignId": 74768, + "templateId": 113554, + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2203, + "messageTypeId": 2439, + "experimentId": null, + "payload": { + "path": "shop_home" + }, + "sound": null, + "badge": null, + "contentAvailable": false, + "deeplink": null, + "locale": null + }, + "receivedAt": "2016-12-08T01:25:22.000Z", + "timestamp": "2016-12-08T01:25:22.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_19.json b/go/webhook/testcases/testdata/testcases/iterable/test_19.json new file mode 100644 index 0000000000..f55268e5fc --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_19.json @@ -0,0 +1,98 @@ +{ + "name": "iterable", + "description": "test-19", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "pushSend", + "dataFields": { + "contentId": 6724, + "platformEndpoint": "", + "email": "docs@iterable.com", + "createdAt": "2016-12-08 00:53:11 +00:00", + "campaignId": 74758, + "templateId": 113541, + "messageId": "73f2d3f13cd04db0b56c6143b179adc5", + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 1744, + "messageTypeId": 1759, + "experimentId": null, + "payload": { + "a": "2" + }, + "sound": "", + "badge": "", + "contentAvailable": false, + "deeplink": null, + "locale": null + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "pushSend", + "integrations": { + "Iterable": false + }, + "properties": { + "contentId": 6724, + "platformEndpoint": "", + "createdAt": "2016-12-08 00:53:11 +00:00", + "campaignId": 74758, + "templateId": 113541, + "messageId": "73f2d3f13cd04db0b56c6143b179adc5", + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 1744, + "messageTypeId": 1759, + "experimentId": null, + "payload": { + "a": "2" + }, + "sound": "", + "badge": "", + "contentAvailable": false, + "deeplink": null, + "locale": null + }, + "receivedAt": "2016-12-08T00:53:11.000Z", + "timestamp": "2016-12-08T00:53:11.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_2.json b/go/webhook/testcases/testdata/testcases/iterable/test_2.json new file mode 100644 index 0000000000..55ab1f9abe --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_2.json @@ -0,0 +1,42 @@ +{ + "name": "iterable", + "description": "test-2", + "input": { + "request": { + "body": { + "email": "test@ruddstack.com", + "eventTitle": "smsReceived", + "dataFields": { + "fromPhoneNumber": "+16503926753", + "toPhoneNumber": "+14155824541", + "smsMessage": "Message text", + "email": "docs@iterable.com", + "createdAt": "2016-12-05 22:51:25 +00:00" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Unknwon event type from Iterable\n" + }, + "queue": [], + "errQueue": [ + { + "email": "test@ruddstack.com", + "eventTitle": "smsReceived", + "dataFields": { + "fromPhoneNumber": "+16503926753", + "toPhoneNumber": "+14155824541", + "smsMessage": "Message text", + "email": "docs@iterable.com", + "createdAt": "2016-12-05 22:51:25 +00:00" + } + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_20.json b/go/webhook/testcases/testdata/testcases/iterable/test_20.json new file mode 100644 index 0000000000..6b323852bc --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_20.json @@ -0,0 +1,62 @@ +{ + "name": "iterable", + "description": "test-20", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "pushSendSkip", + "dataFields": { + "createdAt": "2019-08-07 22:28:51 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 732667, + "messageId": "8306ae0c74324635b7554947c5ec0e56", + "email": "docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "pushSendSkip", + "integrations": { + "Iterable": false + }, + "properties": { + "createdAt": "2019-08-07 22:28:51 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 732667, + "messageId": "8306ae0c74324635b7554947c5ec0e56" + }, + "receivedAt": "2019-08-07T22:28:51.000Z", + "timestamp": "2019-08-07T22:28:51.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_21.json b/go/webhook/testcases/testdata/testcases/iterable/test_21.json new file mode 100644 index 0000000000..8dee1d695a --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_21.json @@ -0,0 +1,98 @@ +{ + "name": "iterable", + "description": "test-21", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "pushUninstall", + "dataFields": { + "isGhostPush": false, + "platformEndpoint": "", + "email": "docs@iterable.com", + "createdAt": "2016-12-09 20:50:54 +00:00", + "campaignId": 74768, + "templateId": 113554, + "messageId": "73f2d3f13cd04db0b56c6143b179adc5", + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2203, + "messageTypeId": 2439, + "experimentId": null, + "payload": { + "path": "your_folder/30" + }, + "sound": "", + "badge": null, + "contentAvailable": false, + "deeplink": null, + "locale": null + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "pushUninstall", + "integrations": { + "Iterable": false + }, + "properties": { + "isGhostPush": false, + "platformEndpoint": "", + "createdAt": "2016-12-09 20:50:54 +00:00", + "campaignId": 74768, + "templateId": 113554, + "messageId": "73f2d3f13cd04db0b56c6143b179adc5", + "pushMessage": "Push message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2203, + "messageTypeId": 2439, + "experimentId": null, + "payload": { + "path": "your_folder/30" + }, + "sound": "", + "badge": null, + "contentAvailable": false, + "deeplink": null, + "locale": null + }, + "receivedAt": "2016-12-09T20:50:54.000Z", + "timestamp": "2016-12-09T20:50:54.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_22.json b/go/webhook/testcases/testdata/testcases/iterable/test_22.json new file mode 100644 index 0000000000..7e517aadcb --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_22.json @@ -0,0 +1,96 @@ +{ + "name": "iterable", + "description": "test-22", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "smsBounce", + "dataFields": { + "smsProviderResponse": { + "status": 404, + "message": "The requested resource /2010-04-01/Accounts/ACCOUNT_NUMBER/Messages.json was not found", + "code": 20404, + "more_info": "https://www.twilio.com/docs/errors/20404" + }, + "email": "docs@iterable.com", + "createdAt": "2016-12-05 22:43:24 +00:00", + "campaignId": 74003, + "templateId": 112561, + "smsMessage": "Here is example message, please respond with 'received'", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 4270, + "messageTypeId": 4769, + "experimentId": null, + "fromPhoneNumberId": 268, + "imageUrl": null, + "locale": null, + "emailId": "c74003:t112561:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "smsBounce", + "integrations": { + "Iterable": false + }, + "properties": { + "smsProviderResponse": { + "status": 404, + "message": "The requested resource /2010-04-01/Accounts/ACCOUNT_NUMBER/Messages.json was not found", + "code": 20404, + "more_info": "https://www.twilio.com/docs/errors/20404" + }, + "createdAt": "2016-12-05 22:43:24 +00:00", + "campaignId": 74003, + "templateId": 112561, + "smsMessage": "Here is example message, please respond with 'received'", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 4270, + "messageTypeId": 4769, + "experimentId": null, + "fromPhoneNumberId": 268, + "imageUrl": null, + "locale": null, + "emailId": "c74003:t112561:docs@iterable.com" + }, + "receivedAt": "2016-12-05T22:43:24.000Z", + "timestamp": "2016-12-05T22:43:24.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_23.json b/go/webhook/testcases/testdata/testcases/iterable/test_23.json new file mode 100644 index 0000000000..760c3cb3e0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_23.json @@ -0,0 +1,90 @@ +{ + "name": "iterable", + "description": "test-23", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "smsClick", + "dataFields": { + "campaignId": 1234567, + "campaignName": "My test campaign", + "workflowId": null, + "workflowName": null, + "templateName": "My template", + "locale": null, + "channelId": 98765, + "messageTypeId": 43210, + "experimentId": null, + "labels": [], + "smsMessage": "Test SMS! https://www.example.com", + "fromPhoneNumberId": 1234, + "imageUrl": null, + "clickedUrl": "https://www.example.com", + "email": "docs@iterable.com", + "createdAt": "2022-03-10 05:00:14 +00:00", + "templateId": 1112222, + "messageId": "ebd8f3cfc1f74353b423c5e0f3dd8b39", + "emailId": "c1234567:t9876543:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "smsClick", + "integrations": { + "Iterable": false + }, + "properties": { + "campaignId": 1234567, + "campaignName": "My test campaign", + "workflowId": null, + "workflowName": null, + "templateName": "My template", + "locale": null, + "channelId": 98765, + "messageTypeId": 43210, + "experimentId": null, + "labels": [], + "smsMessage": "Test SMS! https://www.example.com", + "fromPhoneNumberId": 1234, + "imageUrl": null, + "clickedUrl": "https://www.example.com", + "createdAt": "2022-03-10 05:00:14 +00:00", + "templateId": 1112222, + "messageId": "ebd8f3cfc1f74353b423c5e0f3dd8b39", + "emailId": "c1234567:t9876543:docs@iterable.com" + }, + "receivedAt": "2022-03-10T05:00:14.000Z", + "timestamp": "2022-03-10T05:00:14.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_24.json b/go/webhook/testcases/testdata/testcases/iterable/test_24.json new file mode 100644 index 0000000000..635ac0fd4f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_24.json @@ -0,0 +1,62 @@ +{ + "name": "iterable", + "description": "test-24", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "smsReceived", + "dataFields": { + "fromPhoneNumber": "+16503926753", + "toPhoneNumber": "+14155824541", + "smsMessage": "Message text", + "email": "docs@iterable.com", + "createdAt": "2016-12-05 22:51:25 +00:00" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "smsReceived", + "integrations": { + "Iterable": false + }, + "properties": { + "fromPhoneNumber": "+16503926753", + "toPhoneNumber": "+14155824541", + "smsMessage": "Message text", + "createdAt": "2016-12-05 22:51:25 +00:00" + }, + "receivedAt": "2016-12-05T22:51:25.000Z", + "timestamp": "2016-12-05T22:51:25.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_25.json b/go/webhook/testcases/testdata/testcases/iterable/test_25.json new file mode 100644 index 0000000000..ce7bec52e5 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_25.json @@ -0,0 +1,90 @@ +{ + "name": "iterable", + "description": "test-25", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "smsSend", + "dataFields": { + "toPhoneNumber": "+16503926753", + "fromSMSSenderId": 258, + "contentId": 2086, + "email": "docs@iterable.com", + "createdAt": "2016-12-05 21:50:32 +00:00", + "campaignId": 73974, + "templateId": 112523, + "smsMessage": "Message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 4270, + "messageTypeId": 4769, + "experimentId": null, + "fromPhoneNumberId": 258, + "imageUrl": null, + "locale": null, + "emailId": "c73974:t112523:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "smsSend", + "integrations": { + "Iterable": false + }, + "properties": { + "toPhoneNumber": "+16503926753", + "fromSMSSenderId": 258, + "contentId": 2086, + "createdAt": "2016-12-05 21:50:32 +00:00", + "campaignId": 73974, + "templateId": 112523, + "smsMessage": "Message text", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 4270, + "messageTypeId": 4769, + "experimentId": null, + "fromPhoneNumberId": 258, + "imageUrl": null, + "locale": null, + "emailId": "c73974:t112523:docs@iterable.com" + }, + "receivedAt": "2016-12-05T21:50:32.000Z", + "timestamp": "2016-12-05T21:50:32.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_26.json b/go/webhook/testcases/testdata/testcases/iterable/test_26.json new file mode 100644 index 0000000000..0089d3ecf2 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_26.json @@ -0,0 +1,62 @@ +{ + "name": "iterable", + "description": "test-26", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "smsSendSkip", + "dataFields": { + "createdAt": "2019-08-07 18:49:48 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 729390, + "messageId": "2c780bf42f26485db0fc6571d2e0f6a0", + "email": "docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "smsSendSkip", + "integrations": { + "Iterable": false + }, + "properties": { + "createdAt": "2019-08-07 18:49:48 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 729390, + "messageId": "2c780bf42f26485db0fc6571d2e0f6a0" + }, + "receivedAt": "2019-08-07T18:49:48.000Z", + "timestamp": "2019-08-07T18:49:48.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_27.json b/go/webhook/testcases/testdata/testcases/iterable/test_27.json new file mode 100644 index 0000000000..1b9b8b8d7f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_27.json @@ -0,0 +1,88 @@ +{ + "name": "iterable", + "description": "test-27", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "emailSend", + "dataFields": { + "contentId": 274222, + "email": "docs@iterable.com", + "createdAt": "2016-12-02 18:51:40 +00:00", + "campaignId": 49313, + "transactionalData": { + "__comment": "transactionalData lists the fields contained in the dataFields property of the API call or event used to trigger the email, campaign, or workflow. transactionalData must contain no more than 12k characters in total." + }, + "templateId": 79190, + "messageId": "210badf49fe54f2591d64ad0d055f4fb", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c49313:t79190:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "emailSend", + "integrations": { + "Iterable": false + }, + "properties": { + "contentId": 274222, + "createdAt": "2016-12-02 18:51:40 +00:00", + "campaignId": 49313, + "transactionalData": { + "__comment": "transactionalData lists the fields contained in the dataFields property of the API call or event used to trigger the email, campaign, or workflow. transactionalData must contain no more than 12k characters in total." + }, + "templateId": 79190, + "messageId": "210badf49fe54f2591d64ad0d055f4fb", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c49313:t79190:docs@iterable.com" + }, + "receivedAt": "2016-12-02T18:51:40.000Z", + "timestamp": "2016-12-02T18:51:40.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_28.json b/go/webhook/testcases/testdata/testcases/iterable/test_28.json new file mode 100644 index 0000000000..b66f76aec3 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_28.json @@ -0,0 +1,94 @@ +{ + "name": "iterable", + "description": "test-28", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "webPushSend", + "dataFields": { + "campaignId": 723636, + "browserToken": "cZn_inqLGPk:APA91bHsn5jo0-4V55RB38eCeLHj8ZXVJYciU7k6Kipbit3lrRlEe2Dt6bNzR4lSf6r2YNVdWY8l90hV0jmb_Y7y5ufcJ68xNI7wbsH6Q2jbEghA_Qo4kWbtu6A4NZN4gxc1xsEbyh7b", + "contentId": 3681, + "messageId": "af4c726ae76b48c7871b6d0d7760d47c", + "workflowName": "My workflow name", + "emailId": "c723636:t1020396:docs@iterable.com", + "locale": null, + "webPushIcon": null, + "templateId": 1020396, + "labels": [], + "createdAt": "2019-08-07 23:43:02 +00:00", + "templateName": "My template name", + "webPushMessage": "", + "messageTypeId": 9106, + "webPushBody": null, + "experimentId": null, + "webPushClickAction": null, + "campaignName": "My campaign name", + "workflowId": 53505, + "channelId": 8539, + "email": "docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "webPushSend", + "integrations": { + "Iterable": false + }, + "properties": { + "campaignId": 723636, + "browserToken": "cZn_inqLGPk:APA91bHsn5jo0-4V55RB38eCeLHj8ZXVJYciU7k6Kipbit3lrRlEe2Dt6bNzR4lSf6r2YNVdWY8l90hV0jmb_Y7y5ufcJ68xNI7wbsH6Q2jbEghA_Qo4kWbtu6A4NZN4gxc1xsEbyh7b", + "contentId": 3681, + "messageId": "af4c726ae76b48c7871b6d0d7760d47c", + "workflowName": "My workflow name", + "emailId": "c723636:t1020396:docs@iterable.com", + "locale": null, + "webPushIcon": null, + "templateId": 1020396, + "labels": [], + "createdAt": "2019-08-07 23:43:02 +00:00", + "templateName": "My template name", + "webPushMessage": "", + "messageTypeId": 9106, + "webPushBody": null, + "experimentId": null, + "webPushClickAction": null, + "campaignName": "My campaign name", + "workflowId": 53505, + "channelId": 8539 + }, + "receivedAt": "2019-08-07T23:43:02.000Z", + "timestamp": "2019-08-07T23:43:02.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_29.json b/go/webhook/testcases/testdata/testcases/iterable/test_29.json new file mode 100644 index 0000000000..e8f0b2498d --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_29.json @@ -0,0 +1,62 @@ +{ + "name": "iterable", + "description": "test-29", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "webPushSendSkip", + "dataFields": { + "createdAt": "2019-08-07 23:43:48 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 723636, + "messageId": "4238c918b20a41dfbe9a910275b76f12", + "email": "docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "webPushSendSkip", + "integrations": { + "Iterable": false + }, + "properties": { + "createdAt": "2019-08-07 23:43:48 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 723636, + "messageId": "4238c918b20a41dfbe9a910275b76f12" + }, + "receivedAt": "2019-08-07T23:43:48.000Z", + "timestamp": "2019-08-07T23:43:48.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_3.json b/go/webhook/testcases/testdata/testcases/iterable/test_3.json new file mode 100644 index 0000000000..b575206541 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_3.json @@ -0,0 +1,48 @@ +{ + "name": "iterable", + "description": "test-3", + "input": { + "request": { + "body": { + "email": "test@rudderstack.com", + "eventName": "inAppSendSkip" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "test@rudderstack.com" + } + }, + "event": "inAppSendSkip", + "integrations": { + "Iterable": false + }, + "type": "track", + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_4.json b/go/webhook/testcases/testdata/testcases/iterable/test_4.json new file mode 100644 index 0000000000..bf99d104d0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_4.json @@ -0,0 +1,82 @@ +{ + "name": "iterable", + "description": "test-4", + "input": { + "request": { + "body": { + "email": "test@rudderstack.com", + "eventName": "emailSend", + "dataFields": { + "contentId": 331201, + "email": "test@rudderstack.com", + "createdAt": "2016-12-02 20:21:04 +00:00", + "campaignId": 59667, + "templateId": 93849, + "messageId": "d0aa7801f91f4824997a631f3ed583c3", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c59667:t93849:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "test@rudderstack.com" + } + }, + "event": "emailSend", + "integrations": { + "Iterable": false + }, + "properties": { + "contentId": 331201, + "createdAt": "2016-12-02 20:21:04 +00:00", + "campaignId": 59667, + "templateId": 93849, + "messageId": "d0aa7801f91f4824997a631f3ed583c3", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c59667:t93849:docs@iterable.com" + }, + "receivedAt": "2016-12-02T20:21:04.000Z", + "timestamp": "2016-12-02T20:21:04.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_5.json b/go/webhook/testcases/testdata/testcases/iterable/test_5.json new file mode 100644 index 0000000000..71396c46be --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_5.json @@ -0,0 +1,82 @@ +{ + "name": "iterable", + "description": "test-5", + "input": { + "request": { + "body": { + "email": "invalid_email@iterable.com", + "eventName": "emailBounce", + "dataFields": { + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2598, + "messageTypeId": 2870, + "experimentId": null, + "recipientState": "HardBounce", + "templateId": 167484, + "email": "invalid_email@iterable.com", + "createdAt": "2017-05-15 23:59:47 +00:00", + "campaignId": 114746, + "messageId": "d0aa7801f91f4824997a631f3ed583c3", + "emailId": "c114746:t167484:invalid_email@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "b053765f5d0d23b0d5e4dd960be9513f", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "invalid_email@iterable.com" + } + }, + "event": "emailBounce", + "integrations": { + "Iterable": false + }, + "properties": { + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 2598, + "messageTypeId": 2870, + "experimentId": null, + "recipientState": "HardBounce", + "templateId": 167484, + "createdAt": "2017-05-15 23:59:47 +00:00", + "campaignId": 114746, + "messageId": "d0aa7801f91f4824997a631f3ed583c3", + "emailId": "c114746:t167484:invalid_email@iterable.com" + }, + "receivedAt": "2017-05-15T23:59:47.000Z", + "timestamp": "2017-05-15T23:59:47.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_6.json b/go/webhook/testcases/testdata/testcases/iterable/test_6.json new file mode 100644 index 0000000000..a676b2c342 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_6.json @@ -0,0 +1,98 @@ +{ + "name": "iterable", + "description": "test-6", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "emailClick", + "dataFields": { + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36", + "ip": "162.245.22.184", + "templateId": 93849, + "userAgentDevice": "Mac", + "url": "https://www.iterable.com", + "canonicalUrlId": "3145668988", + "city": "San Francisco", + "region": "CA", + "email": "docs@iterable.com", + "createdAt": "2016-12-02 20:31:39 +00:00", + "campaignId": 59667, + "messageId": "d0aa7801f91f4824997a631f3ed583c3", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "linkUrl": "https://www.iterable.com", + "linkId": "3145668988", + "emailId": "c59667:t93849:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "emailClick", + "integrations": { + "Iterable": false + }, + "properties": { + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36", + "ip": "162.245.22.184", + "templateId": 93849, + "userAgentDevice": "Mac", + "url": "https://www.iterable.com", + "canonicalUrlId": "3145668988", + "city": "San Francisco", + "region": "CA", + "createdAt": "2016-12-02 20:31:39 +00:00", + "campaignId": 59667, + "messageId": "d0aa7801f91f4824997a631f3ed583c3", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "linkUrl": "https://www.iterable.com", + "linkId": "3145668988", + "emailId": "c59667:t93849:docs@iterable.com" + }, + "receivedAt": "2016-12-02T20:31:39.000Z", + "timestamp": "2016-12-02T20:31:39.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_7.json b/go/webhook/testcases/testdata/testcases/iterable/test_7.json new file mode 100644 index 0000000000..b07112dcee --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_7.json @@ -0,0 +1,82 @@ +{ + "name": "iterable", + "description": "test-7", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "emailComplaint", + "dataFields": { + "recipientState": "Complaint", + "templateId": 79190, + "email": "docs@iterable.com", + "createdAt": "2016-12-09 18:52:19 +00:00", + "campaignId": 49313, + "messageId": "d3c44d47b4994306b4db8d16a94db025", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "test template", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c49313:t79190:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "emailComplaint", + "integrations": { + "Iterable": false + }, + "properties": { + "recipientState": "Complaint", + "templateId": 79190, + "createdAt": "2016-12-09 18:52:19 +00:00", + "campaignId": 49313, + "messageId": "d3c44d47b4994306b4db8d16a94db025", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "test template", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c49313:t79190:docs@iterable.com" + }, + "receivedAt": "2016-12-09T18:52:19.000Z", + "timestamp": "2016-12-09T18:52:19.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_8.json b/go/webhook/testcases/testdata/testcases/iterable/test_8.json new file mode 100644 index 0000000000..11f700b740 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_8.json @@ -0,0 +1,88 @@ +{ + "name": "iterable", + "description": "test-8", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "emailOpen", + "dataFields": { + "userAgent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", + "proxySource": "Gmail", + "ip": "66.249.84.204", + "templateId": 79190, + "device": "Gmail", + "email": "docs@iterable.com", + "createdAt": "2016-12-02 18:51:45 +00:00", + "campaignId": 49313, + "messageId": "210badf49fe54f2591d64ad0d055f4fb", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c49313:t79190:docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "emailOpen", + "integrations": { + "Iterable": false + }, + "properties": { + "userAgent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", + "proxySource": "Gmail", + "ip": "66.249.84.204", + "templateId": 79190, + "device": "Gmail", + "createdAt": "2016-12-02 18:51:45 +00:00", + "campaignId": 49313, + "messageId": "210badf49fe54f2591d64ad0d055f4fb", + "emailSubject": "My subject", + "campaignName": "My campaign name", + "workflowId": null, + "workflowName": null, + "templateName": "My template name", + "channelId": 3420, + "messageTypeId": 3866, + "experimentId": null, + "emailId": "c49313:t79190:docs@iterable.com" + }, + "receivedAt": "2016-12-02T18:51:45.000Z", + "timestamp": "2016-12-02T18:51:45.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/iterable/test_9.json b/go/webhook/testcases/testdata/testcases/iterable/test_9.json new file mode 100644 index 0000000000..5a9331cbe7 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/iterable/test_9.json @@ -0,0 +1,62 @@ +{ + "name": "iterable", + "description": "test-9", + "input": { + "request": { + "body": { + "email": "docs@iterable.com", + "eventName": "emailSendSkip", + "dataFields": { + "createdAt": "2019-08-07 18:56:10 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 721398, + "messageId": "98430abe1b9842c991ce221010121553", + "email": "docs@iterable.com" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "0e13848b1c7e27eb5d88c5d35b70783e", + "context": { + "integration": { + "name": "Iterable", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "docs@iterable.com" + } + }, + "event": "emailSendSkip", + "integrations": { + "Iterable": false + }, + "properties": { + "createdAt": "2019-08-07 18:56:10 +00:00", + "reason": "DuplicateMarketingMessage", + "campaignId": 721398, + "messageId": "98430abe1b9842c991ce221010121553" + }, + "receivedAt": "2019-08-07T18:56:10.000Z", + "timestamp": "2019-08-07T18:56:10.000Z", + "type": "track", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_bounce_event.json b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_bounce_event.json new file mode 100644 index 0000000000..81c569e82b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_bounce_event.json @@ -0,0 +1,68 @@ +{ + "name": "mailjet", + "description": "MailJet email bounce event", + "input": { + "request": { + "body": { + "event": "bounce", + "time": 1664444170, + "MessageID": 56013522696710744, + "Message_GUID": "dbe4f0a3-4a5a-4784-a724-a9794d3c0444", + "email": "test@rudderstack.com", + "mj_campaign_id": 108892, + "mj_contact_id": 373142182, + "customcampaign": "mj.nl=58486", + "blocked": false, + "hard_bounce": false, + "error_related_to": "system", + "error": "connection issue" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "MailJet" + }, + "traits": { + "email": "test@rudderstack.com" + }, + "externalId": [ + { + "type": "mailjetContactId", + "id": 373142182 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "bounce", + "properties": { + "customcampaign": "mj.nl=58486", + "mj_campaign_id": 108892 + }, + "originalTimestamp": "2022-09-29T09:36:10.000Z", + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_bounce_event_where_input_event_is_of_type_.json b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_bounce_event_where_input_event_is_of_type_.json new file mode 100644 index 0000000000..95e9781a8b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_bounce_event_where_input_event_is_of_type_.json @@ -0,0 +1,68 @@ +{ + "name": "mailjet", + "description": "MailJet email bounce event where input event is of type ", + "input": { + "request": { + "body": { + "event": "bounce", + "time": 1664444171, + "MessageID": 55169098999352350, + "Message_GUID": "447d7eab-3335-4aba-9a51-09454bc14b81", + "email": "test@rudderstack.com", + "mj_campaign_id": 108892, + "mj_contact_id": 373142816, + "customcampaign": "mj.nl=58486", + "blocked": false, + "hard_bounce": false, + "error_related_to": "system", + "error": "connection issue" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "MailJet" + }, + "traits": { + "email": "test@rudderstack.com" + }, + "externalId": [ + { + "type": "mailjetContactId", + "id": 373142816 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "bounce", + "properties": { + "customcampaign": "mj.nl=58486", + "mj_campaign_id": 108892 + }, + "originalTimestamp": "2022-09-29T09:36:11.000Z", + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_open_event.json b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_open_event.json new file mode 100644 index 0000000000..41a6e76edc --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_open_event.json @@ -0,0 +1,73 @@ +{ + "name": "mailjet", + "description": "MailJet email open event", + "input": { + "request": { + "body": { + "event": "open", + "time": 1664443614, + "MessageID": 94857068804950690, + "Message_GUID": "54d6cdec-f659-4547-8926-13d9c4126b82", + "email": "test@rudderstack.com", + "mj_campaign_id": 108760, + "mj_contact_id": 399962859, + "customcampaign": "mj.nl=58424", + "ip": "66.249.84.231", + "geo": "US", + "agent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", + "CustomID": "", + "Payload": "" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "MailJet" + }, + "traits": { + "email": "test@rudderstack.com" + }, + "ip": "66.249.84.231", + "userAgent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", + "externalId": [ + { + "type": "mailjetContactId", + "id": 399962859 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "open", + "properties": { + "ip": "66.249.84.231", + "customcampaign": "mj.nl=58424", + "mj_campaign_id": 108760, + "Payload": "" + }, + "originalTimestamp": "2022-09-29T09:26:54.000Z", + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_sent_event.json b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_sent_event.json new file mode 100644 index 0000000000..af2fc8dea1 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_email_sent_event.json @@ -0,0 +1,65 @@ +{ + "name": "mailjet", + "description": "MailJet email sent event", + "input": { + "request": { + "body": { + "event": "sent", + "time": 1664444171, + "MessageID": 92886743924596480, + "Message_GUID": "0230c73a-2b77-4aea-8ef2-ed15d0edc5fd", + "email": "test@rudderstack.com", + "mj_campaign_id": 108892, + "mj_contact_id": 372651182, + "customcampaign": "mj.nl=58486", + "smtp_reply": "250 2.0.0 OK DMARC:Quarantine 1664444171 u17-20020adfdd51000000b0022cc3f2bf13si3225188wrm.271 - gsmtp" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "MailJet" + }, + "traits": { + "email": "test@rudderstack.com" + }, + "externalId": [ + { + "type": "mailjetContactId", + "id": 372651182 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "sent", + "properties": { + "customcampaign": "mj.nl=58486", + "mj_campaign_id": 108892 + }, + "originalTimestamp": "2022-09-29T09:36:11.000Z", + "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_multiple_payloads_in_single_request.json b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_multiple_payloads_in_single_request.json new file mode 100644 index 0000000000..f7b8993e32 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_multiple_payloads_in_single_request.json @@ -0,0 +1,132 @@ +{ + "name": "mailjet", + "description": "MailJet Multiple payloads in single request", + "input": { + "request": { + "body": [ + { + "event": "open", + "time": 1704458040, + "MessageID": 987654, + "Message_GUID": "876r-oihugyf-7tfygh", + "email": "abc@r.com", + "mj_campaign_id": 321, + "mj_contact_id": 123, + "customcampaign": "test_campaign", + "url": "https://www.example.com/", + "ip": "ip_info", + "geo": "some geo info", + "agent": "mailjet api test" + }, + { + "event": "click", + "time": 1704458041, + "MessageID": 12345234567, + "Message_GUID": "12345-kjhgfd-2efv", + "email": "abc@r.com", + "mj_campaign_id": 12, + "mj_contact_id": 32532, + "customcampaign": "test_campaign", + "url": "https://www.example.com/", + "ip": "ip_info", + "geo": "some geo info", + "agent": "mailjet api test" + } + ], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "ip": "ip_info", + "integration": { + "name": "MailJet" + }, + "traits": { + "email": "abc@r.com" + }, + "page": { + "url": "https://www.example.com/" + }, + "userAgent": "mailjet api test", + "externalId": [ + { + "type": "mailjetContactId", + "id": 123 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "open", + "properties": { + "customcampaign": "test_campaign", + "mj_campaign_id": 321, + "ip": "ip_info", + "url": "https://www.example.com/" + }, + "userId": "593a5aff0b445b3b77a6d9676b7ec86e", + "originalTimestamp": "2024-01-05T12:34:00.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "page": { + "url": "https://www.example.com/" + }, + "integration": { + "name": "MailJet" + }, + "traits": { + "email": "abc@r.com" + }, + "userAgent": "mailjet api test", + "ip": "ip_info", + "externalId": [ + { + "type": "mailjetContactId", + "id": 32532 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "click", + "properties": { + "customcampaign": "test_campaign", + "mj_campaign_id": 12, + "ip": "ip_info", + "url": "https://www.example.com/" + }, + "userId": "593a5aff0b445b3b77a6d9676b7ec86e", + "originalTimestamp": "2024-01-05T12:34:01.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_when_no_email_is_present.json b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_when_no_email_is_present.json new file mode 100644 index 0000000000..67935f116f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailjet/mail_jet_when_no_email_is_present.json @@ -0,0 +1,64 @@ +{ + "name": "mailjet", + "description": "MailJet when no email is present", + "input": { + "request": { + "body": { + "event": "bounce", + "time": 1664444170, + "MessageID": 56013522696710744, + "Message_GUID": "dbe4f0a3-4a5a-4784-a724-a9794d3c0444", + "mj_campaign_id": 108892, + "mj_contact_id": 373142182, + "customcampaign": "mj.nl=58486", + "blocked": false, + "hard_bounce": false, + "error_related_to": "system", + "error": "connection issue" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "MailJet" + }, + "externalId": [ + { + "type": "mailjetContactId", + "id": 373142182 + } + ] + }, + "integrations": { + "MailJet": false + }, + "type": "track", + "event": "bounce", + "properties": { + "customcampaign": "mj.nl=58486", + "mj_campaign_id": 108892 + }, + "originalTimestamp": "2022-09-29T09:36:10.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + }, + "skip": "FIXME" +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_0.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_0.json new file mode 100644 index 0000000000..cfc80d1a59 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_0.json @@ -0,0 +1,66 @@ +{ + "name": "mailmodo", + "description": "test-0", + "input": { + "request": { + "body": { + "triggerData": { + "data": {}, + "triggerSource": "CsvList", + "email": "gouhgc@mailmodo.com", + "triggerDetails": "file:1a69df39hfbfg4e0b-8b5c-73776157aa37/7647792f-4ebc-4f9d-ac79-05fb0356137e", + "userId": "d3775892hvh4f2f-b9d5-e49810eb2cae", + "journeyId": "1a69df39hgvh4e0b-8b5c-73776157aa37", + "eventProperty": {} + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "f43848cce166e51b097cbed2851adc16ed9d4c341928f1c790215c50cefb59b0", + "context": { + "externalId": [ + { + "id": "d3775892hvh4f2f-b9d5-e49810eb2cae", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gouhgc@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "CsvList", + "integrations": { + "Mailmodo": false + }, + "properties": { + "triggerData.triggerSource": "CsvList", + "triggerData.triggerDetails": "file:1a69df39hfbfg4e0b-8b5c-73776157aa37/7647792f-4ebc-4f9d-ac79-05fb0356137e", + "triggerData.journeyId": "1a69df39hgvh4e0b-8b5c-73776157aa37" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_1.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_1.json new file mode 100644 index 0000000000..969f657e54 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_1.json @@ -0,0 +1,87 @@ +{ + "name": "mailmodo", + "description": "test-1", + "input": { + "request": { + "body": { + "fuuid": "27905", + "next-step-id": "success", + "total-steps": "3", + "responseId": "b9a5d224-cc5a-4e64-9800-5a3db9515fdf", + "recipientEmail": "test.rudderlabs21997@gmail.com", + "formId": "formosztd5", + "recordedAt": { + "ts": 1662695704, + "date": "2022-09-09", + "hour": 9, + "minute": 25 + }, + "submissionSource": "amp", + "elementjbtz42": "Everything ", + "element8jzo13": ["Reliable", "High Quality", "Useful"], + "recipientData": { + "email": "test.rudderlabs21997@gmail.com" + }, + "recommend": "9", + "liking": "upvote", + "satisfaction": "4", + "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", + "campaignName": "Campaign-testing" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "a80b34ec43ca959c7b8e5116ac626c3cf8561f62616e000a01729a8a900cc0a0", + "context": { + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "test.rudderlabs21997@gmail.com" + } + }, + "event": "Form Submitted", + "integrations": { + "Mailmodo": false + }, + "originalTimestamp": "2022-09-09T03:55:04.000Z", + "properties": { + "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", + "campaignName": "Campaign-testing", + "element8jzo13[0]": "Reliable", + "element8jzo13[1]": "High Quality", + "element8jzo13[2]": "Useful", + "elementjbtz42": "Everything ", + "formId": "formosztd5", + "fuuid": "27905", + "liking": "upvote", + "next-step-id": "success", + "recommend": "9", + "responseId": "b9a5d224-cc5a-4e64-9800-5a3db9515fdf", + "satisfaction": "4", + "submissionSource": "amp", + "total-steps": "3" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_2.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_2.json new file mode 100644 index 0000000000..67a40cc4b4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_2.json @@ -0,0 +1,64 @@ +{ + "name": "mailmodo", + "description": "test-2", + "input": { + "request": { + "body": { + "triggerData": { + "data": {}, + "triggerSource": "Manual Add To List", + "email": "gou****@mailmodo.com", + "userId": "d3775892-****-4f2f-b9d5-e49810eb2cae", + "journeyId": "349e986e-f56c-****-bc3b-b5f13c3e34da", + "eventProperty": {} + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", + "context": { + "externalId": [ + { + "id": "d3775892-****-4f2f-b9d5-e49810eb2cae", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gou****@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "Manual Add To List", + "integrations": { + "Mailmodo": false + }, + "properties": { + "triggerData.triggerSource": "Manual Add To List", + "triggerData.journeyId": "349e986e-f56c-****-bc3b-b5f13c3e34da" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_3.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_3.json new file mode 100644 index 0000000000..c8fc230de0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_3.json @@ -0,0 +1,64 @@ +{ + "name": "mailmodo", + "description": "test-3", + "input": { + "request": { + "body": { + "triggerData": { + "data": {}, + "triggerSource": "Dashboard-change in property: first_name", + "email": "gou****@mailmodo.com", + "userId": "cc56708d-****-****-8c07-a4bfa5a7b79b", + "journeyId": "a78d7221-de34-47d8-81c6-5ad70cf4ee38", + "eventProperty": {} + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", + "context": { + "externalId": [ + { + "id": "cc56708d-****-****-8c07-a4bfa5a7b79b", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gou****@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "Dashboard-change in property: first_name", + "integrations": { + "Mailmodo": false + }, + "properties": { + "triggerData.triggerSource": "Dashboard-change in property: first_name", + "triggerData.journeyId": "a78d7221-de34-47d8-81c6-5ad70cf4ee38" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_4.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_4.json new file mode 100644 index 0000000000..588e7c6da8 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_4.json @@ -0,0 +1,90 @@ +{ + "name": "mailmodo", + "description": "test-4", + "input": { + "request": { + "body": { + "triggerData": { + "data": {}, + "formSubmissionData": { + "element6ehxt3": "Te**", + "element6jkcy4": "Bang****", + "fuuid": "47949", + "next-step-id": "step7tr7n2", + "total-steps": "3", + "responseId": "4a8bfda7-****-4a8c-9cd1-a30d30a6dab9", + "recipientEmail": "gou****@mailmodo.com", + "formId": "formmqxnu2", + "recordedAt": { + "ts": 1657097786, + "date": "2022-07-06", + "hour": 14, + "minute": 26 + }, + "submissionSource": "amp" + }, + "email": "gou****@mailmodo.com", + "triggerSource": "form submission", + "userId": "11bff3e8-****-4e93-a533-fd8f9defc768", + "journeyId": "03664747-****-412e-8790-de9e9abe96a5", + "eventProperty": {} + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", + "context": { + "externalId": [ + { + "id": "11bff3e8-****-4e93-a533-fd8f9defc768", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gou****@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "form submission", + "integrations": { + "Mailmodo": false + }, + "originalTimestamp": "2022-07-06T08:56:26.000Z", + "properties": { + "triggerData.triggerSource": "form submission", + "triggerData.formSubmissionData.element6ehxt3": "Te**", + "triggerData.formSubmissionData.element6jkcy4": "Bang****", + "triggerData.formSubmissionData.formId": "formmqxnu2", + "triggerData.formSubmissionData.fuuid": "47949", + "triggerData.formSubmissionData.next-step-id": "step7tr7n2", + "triggerData.formSubmissionData.responseId": "4a8bfda7-****-4a8c-9cd1-a30d30a6dab9", + "triggerData.formSubmissionData.submissionSource": "amp", + "triggerData.formSubmissionData.total-steps": "3", + "triggerData.journeyId": "03664747-****-412e-8790-de9e9abe96a5" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_5.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_5.json new file mode 100644 index 0000000000..8c4abcc945 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_5.json @@ -0,0 +1,75 @@ +{ + "name": "mailmodo", + "description": "test-5", + "input": { + "request": { + "body": { + "triggerData": { + "data": {}, + "eventProperty": { + "Name": "APPLE iPhone 13 (Blue, 128 GB)", + "Category": "Mobiles", + "Is Purchased": "false", + "Price": "829", + "Currency": "USD" + }, + "triggerSource": "New Custom Event Trigger - Product Viewed", + "email": "gou****@mailmodo.com", + "userId": "d3775892-****-4f2f-b9d5-e49810eb2cae", + "journeyId": "3f135bf7-****-4e31-b265-f61cfe1bd423" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", + "context": { + "externalId": [ + { + "id": "d3775892-****-4f2f-b9d5-e49810eb2cae", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gou****@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "New Custom Event Trigger - Product Viewed", + "integrations": { + "Mailmodo": false + }, + "properties": { + "triggerData.eventProperty.Category": "Mobiles", + "triggerData.eventProperty.Currency": "USD", + "triggerData.eventProperty.Is Purchased": "false", + "triggerData.eventProperty.Name": "APPLE iPhone 13 (Blue, 128 GB)", + "triggerData.eventProperty.Price": "829", + "triggerData.journeyId": "3f135bf7-****-4e31-b265-f61cfe1bd423", + "triggerData.triggerSource": "New Custom Event Trigger - Product Viewed" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_6.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_6.json new file mode 100644 index 0000000000..e256cd683e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_6.json @@ -0,0 +1,64 @@ +{ + "name": "mailmodo", + "description": "test-6", + "input": { + "request": { + "body": { + "triggerData": { + "email": "gou****@mailmodo.com", + "data": {}, + "userId": "d3775892-****-4f2f-b9d5-e49810eb2cae", + "journeyId": "b1ee6bf6-****-4b5a-b7b5-0637853cd8c3", + "triggerSource": "Api", + "eventProperty": {} + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", + "context": { + "externalId": [ + { + "id": "d3775892-****-4f2f-b9d5-e49810eb2cae", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gou****@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "Api", + "integrations": { + "Mailmodo": false + }, + "properties": { + "triggerData.triggerSource": "Api", + "triggerData.journeyId": "b1ee6bf6-****-4b5a-b7b5-0637853cd8c3" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_7.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_7.json new file mode 100644 index 0000000000..ccba1a0884 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_7.json @@ -0,0 +1,74 @@ +{ + "name": "mailmodo", + "description": "test-7", + "input": { + "request": { + "body": { + "eventData": { + "type": "html" + }, + "triggerData": { + "data": {}, + "triggerSource": "CsvList", + "email": "gou****@mailmodo.com", + "triggerDetails": "file:5d31c2b4-****-4a84-acd3-834cae80231b/5a61e0b8-b6f6-4d7d-abf2-90357d6638af", + "userId": "cc56708d-****-4fea-8c07-a4bfa5a7b79b", + "journeyId": "5d31c2b4-****-4a84-acd3-834cae80231b", + "eventProperty": {} + }, + "lastCampaignEmailRef": "064c76e7-****-4780-a001-226c066aaa12", + "lastCampaignId": "31422f76-****-4a72-a630-dd6f9f615bc3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", + "context": { + "externalId": [ + { + "id": "cc56708d-****-4fea-8c07-a4bfa5a7b79b", + "type": "mailmodoUserId" + } + ], + "traits": { + "email": "gou****@mailmodo.com" + }, + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "event": "CsvList", + "integrations": { + "Mailmodo": false + }, + "properties": { + "eventData.type": "html", + "lastCampaignEmailRef": "064c76e7-****-4780-a001-226c066aaa12", + "lastCampaignId": "31422f76-****-4a72-a630-dd6f9f615bc3", + "triggerData.journeyId": "5d31c2b4-****-4a84-acd3-834cae80231b", + "triggerData.triggerDetails": "file:5d31c2b4-****-4a84-acd3-834cae80231b/5a61e0b8-b6f6-4d7d-abf2-90357d6638af", + "triggerData.triggerSource": "CsvList" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/mailmodo/test_8.json b/go/webhook/testcases/testdata/testcases/mailmodo/test_8.json new file mode 100644 index 0000000000..b71b22a708 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/mailmodo/test_8.json @@ -0,0 +1,87 @@ +{ + "name": "mailmodo", + "description": "test-8", + "input": { + "request": { + "body": { + "fuuid": "98255", + "next-step-id": "success", + "total-steps": "3", + "responseId": "ad20a980-4fce-44b6-887d-2236df514a76", + "recipientEmail": "test@rudderstack.com", + "formId": "formosztd5", + "recordedAt": { + "ts": 1662695887, + "date": "2022-09-09", + "hour": 9, + "minute": 28 + }, + "submissionSource": "amp", + "elementjbtz42": "peace", + "element8jzo13": ["Useful"], + "recipientData": { + "email": "test@rudderstack.com", + "first_name": "abcda" + }, + "recommend": "1", + "liking": "downvote", + "satisfaction": "1", + "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", + "campaignName": "Campaign-testing" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", + "context": { + "integration": { + "name": "Mailmodo", + "version": "1.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "email": "test@rudderstack.com", + "first_name": "abcda" + } + }, + "event": "Form Submitted", + "integrations": { + "Mailmodo": false + }, + "originalTimestamp": "2022-09-09T03:58:07.000Z", + "properties": { + "fuuid": "98255", + "next-step-id": "success", + "total-steps": "3", + "responseId": "ad20a980-4fce-44b6-887d-2236df514a76", + "formId": "formosztd5", + "submissionSource": "amp", + "elementjbtz42": "peace", + "element8jzo13[0]": "Useful", + "recommend": "1", + "liking": "downvote", + "satisfaction": "1", + "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", + "campaignName": "Campaign-testing" + }, + "type": "track", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/moengage/batch_of_events.json b/go/webhook/testcases/testdata/testcases/moengage/batch_of_events.json new file mode 100644 index 0000000000..58d4513db2 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/moengage/batch_of_events.json @@ -0,0 +1,389 @@ +{ + "name": "moengage", + "description": "Batch of events", + "input": { + "request": { + "body": { + "batch": [ + { + "type": "page", + "event": "home", + "sentAt": "2020-11-12T21:12:54.117Z", + "userId": "sajal", + "channel": "mobile", + "context": { + "traits": {}, + "library": { + "name": "rudder-sdk-ruby-sync", + "version": "1.0.7" + }, + "page": { + "path": "/Rectified.html", + "referrer": "http://localhost:1112/", + "search": "", + "title": "", + "url": "http://localhost:1112/Rectified.html" + }, + "userAgent": "Dalvik/2.1.0 (Linux; U; Android 10; Redmi K20 Pro MIUI/V12.0.3.0.QFKINXM)" + }, + "rudderId": "asdfasdfsadf", + "properties": { + "name": "asdfsadf" + }, + "timestamp": "2020-11-12T21:12:41.320Z", + "anonymousId": "123123123123" + }, + { + "anonymousId": "4eb021e9-a2af-4926-ae82-fe996d12f3c5", + "channel": "web", + "context": { + "timezone": "Asia/Tokyo", + "app": { + "build": "1.0.0", + "name": "RudderLabs JavaScript SDK", + "namespace": "com.rudderlabs.javascript", + "version": "1.1.6" + }, + "library": { + "name": "RudderLabs JavaScript SDK", + "version": "1.1.6" + }, + "locale": "en-GB", + "os": { + "name": "", + "version": "" + }, + "page": { + "path": "/testing/script-test.html", + "referrer": "", + "search": "", + "title": "", + "url": "http://localhost:3243/testing/script-test.html" + }, + "screen": { + "density": 2 + }, + "traits": { + "company": { + "id": "abc123" + }, + "createdAt": "Thu Mar 24 2016 17:46:45 GMT+0000 (UTC)", + "email": "rudderTest@gmail.com", + "name": "Rudder Test", + "plan": "Enterprise" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.80 Safari/537.36" + }, + "event": "Order Completed", + "integrations": { + "All": true + }, + "messageId": "a0adfab9-baf7-4e09-a2ce-bbe2844c324a", + "originalTimestamp": "2020-10-16T08:10:12.782Z", + "properties": { + "checkout_id": "what is checkout id here??", + "coupon": "APPARELSALE", + "currency": "GBP", + "order_id": "transactionId", + "category": "some category", + "originalArray": [ + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + } + ], + "products": [ + { + "brand": "", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/bacon-jam.jpg", + "name": "Food/Drink", + "position": 1, + "price": 3, + "product_id": "product-bacon-jam", + "quantity": 2, + "sku": "sku-1", + "typeOfProduct": "Food", + "url": "https://www.example.com/product/bacon-jam", + "value": 6, + "variant": "Extra topped" + }, + { + "brand": "Levis", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/t-shirt.jpg", + "name": "T-Shirt", + "position": 2, + "price": 12.99, + "product_id": "product-t-shirt", + "quantity": 1, + "sku": "sku-2", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/t-shirt", + "value": 12.99, + "variant": "White" + }, + { + "brand": "Levis", + "category": "Merch", + "coupon": "APPARELSALE", + "currency": "GBP", + "image_url": "https://www.example.com/product/offer-t-shirt.jpg", + "name": "T-Shirt-on-offer", + "position": 1, + "price": 12.99, + "product_id": "offer-t-shirt", + "quantity": 1, + "sku": "sku-3", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/offer-t-shirt", + "value": 12.99, + "variant": "Black" + } + ], + "revenue": 31.98, + "shipping": 4, + "value": 31.98 + }, + "receivedAt": "2020-10-16T13:40:12.792+05:30", + "request_ip": "[::1]", + "sentAt": "2020-10-16T08:10:12.783Z", + "timestamp": "2020-10-16T13:40:12.791+05:30", + "type": "track", + "userId": "rudder123" + } + ] + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "page", + "event": "home", + "sentAt": "2020-11-12T21:12:54.117Z", + "userId": "sajal", + "channel": "mobile", + "context": { + "traits": {}, + "library": { + "name": "rudder-sdk-ruby-sync", + "version": "1.0.7" + }, + "page": { + "path": "/Rectified.html", + "referrer": "http://localhost:1112/", + "search": "", + "title": "", + "url": "http://localhost:1112/Rectified.html" + }, + "userAgent": "Dalvik/2.1.0 (Linux; U; Android 10; Redmi K20 Pro MIUI/V12.0.3.0.QFKINXM)" + }, + "rudderId": "asdfasdfsadf", + "properties": { + "name": "asdfsadf" + }, + "timestamp": "2020-11-12T21:12:41.320Z", + "anonymousId": "123123123123", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "anonymousId": "4eb021e9-a2af-4926-ae82-fe996d12f3c5", + "channel": "web", + "context": { + "timezone": "Asia/Tokyo", + "app": { + "build": "1.0.0", + "name": "RudderLabs JavaScript SDK", + "namespace": "com.rudderlabs.javascript", + "version": "1.1.6" + }, + "library": { + "name": "RudderLabs JavaScript SDK", + "version": "1.1.6" + }, + "locale": "en-GB", + "os": { + "name": "", + "version": "" + }, + "page": { + "path": "/testing/script-test.html", + "referrer": "", + "search": "", + "title": "", + "url": "http://localhost:3243/testing/script-test.html" + }, + "screen": { + "density": 2 + }, + "traits": { + "company": { + "id": "abc123" + }, + "createdAt": "Thu Mar 24 2016 17:46:45 GMT+0000 (UTC)", + "email": "rudderTest@gmail.com", + "name": "Rudder Test", + "plan": "Enterprise" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.80 Safari/537.36" + }, + "event": "Order Completed", + "integrations": { + "All": true + }, + "messageId": "a0adfab9-baf7-4e09-a2ce-bbe2844c324a", + "originalTimestamp": "2020-10-16T08:10:12.782Z", + "properties": { + "checkout_id": "what is checkout id here??", + "coupon": "APPARELSALE", + "currency": "GBP", + "order_id": "transactionId", + "category": "some category", + "originalArray": [ + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + }, + { + "nested_field": "nested value", + "tags": ["tag_1", "tag_2", "tag_3"] + } + ], + "products": [ + { + "brand": "", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/bacon-jam.jpg", + "name": "Food/Drink", + "position": 1, + "price": 3, + "product_id": "product-bacon-jam", + "quantity": 2, + "sku": "sku-1", + "typeOfProduct": "Food", + "url": "https://www.example.com/product/bacon-jam", + "value": 6, + "variant": "Extra topped" + }, + { + "brand": "Levis", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/t-shirt.jpg", + "name": "T-Shirt", + "position": 2, + "price": 12.99, + "product_id": "product-t-shirt", + "quantity": 1, + "sku": "sku-2", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/t-shirt", + "value": 12.99, + "variant": "White" + }, + { + "brand": "Levis", + "category": "Merch", + "coupon": "APPARELSALE", + "currency": "GBP", + "image_url": "https://www.example.com/product/offer-t-shirt.jpg", + "name": "T-Shirt-on-offer", + "position": 1, + "price": 12.99, + "product_id": "offer-t-shirt", + "quantity": 1, + "sku": "sku-3", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/offer-t-shirt", + "value": 12.99, + "variant": "Black" + } + ], + "revenue": 31.98, + "shipping": 4, + "value": 31.98 + }, + "receivedAt": "2020-10-16T13:40:12.792+05:30", + "request_ip": "[::1]", + "sentAt": "2020-10-16T08:10:12.783Z", + "timestamp": "2020-10-16T13:40:12.791+05:30", + "type": "track", + "userId": "rudder123" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/moengage/simple_track_call.json b/go/webhook/testcases/testdata/testcases/moengage/simple_track_call.json new file mode 100644 index 0000000000..f9b11bffb4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/moengage/simple_track_call.json @@ -0,0 +1,246 @@ +{ + "name": "moengage", + "description": "Simple track call", + "input": { + "request": { + "body": { + "anonymousId": "4eb021e9-a2af-4926-ae82-fe996d12f3c5", + "channel": "web", + "context": { + "timezone": "Wrong/Timezone", + "app": { + "build": "1.0.0", + "name": "RudderLabs JavaScript SDK", + "namespace": "com.rudderlabs.javascript", + "version": "1.1.6" + }, + "library": { + "name": "RudderLabs JavaScript SDK", + "version": "1.1.6" + }, + "locale": "en-GB", + "os": { + "name": "", + "version": "" + }, + "page": { + "path": "/testing/script-test.html", + "referrer": "", + "search": "", + "title": "", + "url": "http://localhost:3243/testing/script-test.html" + }, + "screen": { + "density": 2 + }, + "traits": { + "company": { + "id": "abc123" + }, + "createdAt": "Thu Mar 24 2016 17:46:45 GMT+0000 (UTC)", + "email": "rudderTest@gmail.com", + "name": "Rudder Test", + "plan": "Enterprise" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.80 Safari/537.36" + }, + "event": "Order Completed", + "integrations": { + "All": true + }, + "messageId": "a0adfab9-baf7-4e09-a2ce-bbe2844c324a", + "originalTimestamp": "2020-10-16T08:10:12.782Z", + "properties": { + "checkout_id": "what is checkout id here??", + "coupon": "APPARELSALE", + "currency": "GBP", + "order_id": "transactionId", + "products": [ + { + "brand": "", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/bacon-jam.jpg", + "name": "Food/Drink", + "position": 1, + "price": 3, + "product_id": "product-bacon-jam", + "quantity": 2, + "sku": "sku-1", + "typeOfProduct": "Food", + "url": "https://www.example.com/product/bacon-jam", + "value": 6, + "variant": "Extra topped" + }, + { + "brand": "Levis", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/t-shirt.jpg", + "name": "T-Shirt", + "position": 2, + "price": 12.99, + "product_id": "product-t-shirt", + "quantity": 1, + "sku": "sku-2", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/t-shirt", + "value": 12.99, + "variant": "White" + }, + { + "brand": "Levis", + "category": "Merch", + "coupon": "APPARELSALE", + "currency": "GBP", + "image_url": "https://www.example.com/product/offer-t-shirt.jpg", + "name": "T-Shirt-on-offer", + "position": 1, + "price": 12.99, + "product_id": "offer-t-shirt", + "quantity": 1, + "sku": "sku-3", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/offer-t-shirt", + "value": 12.99, + "variant": "Black" + } + ], + "revenue": 31.98, + "shipping": 4, + "value": 31.98 + }, + "sentAt": "2020-10-16T08:10:12.783Z", + "timestamp": "2020-10-16T13:40:12.791+05:30", + "type": "track", + "userId": "rudder123" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "4eb021e9-a2af-4926-ae82-fe996d12f3c5", + "channel": "web", + "context": { + "timezone": "Wrong/Timezone", + "app": { + "build": "1.0.0", + "name": "RudderLabs JavaScript SDK", + "namespace": "com.rudderlabs.javascript", + "version": "1.1.6" + }, + "library": { + "name": "RudderLabs JavaScript SDK", + "version": "1.1.6" + }, + "locale": "en-GB", + "os": { + "name": "", + "version": "" + }, + "page": { + "path": "/testing/script-test.html", + "referrer": "", + "search": "", + "title": "", + "url": "http://localhost:3243/testing/script-test.html" + }, + "screen": { + "density": 2 + }, + "traits": { + "company": { + "id": "abc123" + }, + "createdAt": "Thu Mar 24 2016 17:46:45 GMT+0000 (UTC)", + "email": "rudderTest@gmail.com", + "name": "Rudder Test", + "plan": "Enterprise" + }, + "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.80 Safari/537.36" + }, + "event": "Order Completed", + "integrations": { + "All": true + }, + "messageId": "a0adfab9-baf7-4e09-a2ce-bbe2844c324a", + "originalTimestamp": "2020-10-16T08:10:12.782Z", + "properties": { + "checkout_id": "what is checkout id here??", + "coupon": "APPARELSALE", + "currency": "GBP", + "order_id": "transactionId", + "products": [ + { + "brand": "", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/bacon-jam.jpg", + "name": "Food/Drink", + "position": 1, + "price": 3, + "product_id": "product-bacon-jam", + "quantity": 2, + "sku": "sku-1", + "typeOfProduct": "Food", + "url": "https://www.example.com/product/bacon-jam", + "value": 6, + "variant": "Extra topped" + }, + { + "brand": "Levis", + "category": "Merch", + "currency": "GBP", + "image_url": "https://www.example.com/product/t-shirt.jpg", + "name": "T-Shirt", + "position": 2, + "price": 12.99, + "product_id": "product-t-shirt", + "quantity": 1, + "sku": "sku-2", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/t-shirt", + "value": 12.99, + "variant": "White" + }, + { + "brand": "Levis", + "category": "Merch", + "coupon": "APPARELSALE", + "currency": "GBP", + "image_url": "https://www.example.com/product/offer-t-shirt.jpg", + "name": "T-Shirt-on-offer", + "position": 1, + "price": 12.99, + "product_id": "offer-t-shirt", + "quantity": 1, + "sku": "sku-3", + "typeOfProduct": "Shirt", + "url": "https://www.example.com/product/offer-t-shirt", + "value": 12.99, + "variant": "Black" + } + ], + "revenue": 31.98, + "shipping": 4, + "value": 31.98 + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "sentAt": "2020-10-16T08:10:12.783Z", + "timestamp": "2020-10-16T13:40:12.791+05:30", + "type": "track", + "userId": "rudder123" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/monday/test_0.json b/go/webhook/testcases/testdata/testcases/monday/test_0.json new file mode 100644 index 0000000000..91087521ba --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/monday/test_0.json @@ -0,0 +1,82 @@ +{ + "name": "monday", + "description": "test-0", + "input": { + "request": { + "body": { + "event": { + "userId": 33556506, + "originalTriggerUuid": null, + "boardId": 3139815405, + "pulseId": 3160188786, + "pulseName": "New Sprint Item", + "groupId": "topics", + "groupName": "Group Title", + "groupColor": "#579bfc", + "isTopGroup": true, + "columnValues": {}, + "app": "monday", + "type": "create_pulse", + "triggerTime": "2022-08-30T09:02:39.191Z", + "subscriptionId": 150881106, + "triggerUuid": "049869226bf6711705c62e301a2c3eee" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Create Pulse", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "externalId": [ + { + "id": 33556506, + "type": "mondayUserId" + } + ], + "integration": { + "name": "MONDAY" + } + }, + "timestamp": "2022-08-30T09:02:39.191Z", + "properties": { + "app": "monday", + "type": "create_pulse", + "boardId": 3139815405, + "groupId": "topics", + "pulseId": 3160188786, + "groupName": "Group Title", + "pulseName": "New Sprint Item", + "groupColor": "#579bfc", + "isTopGroup": true, + "triggerUuid": "049869226bf6711705c62e301a2c3eee", + "columnValues": {}, + "subscriptionId": 150881106, + "originalTriggerUuid": null + }, + "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", + "integrations": { + "MONDAY": false + }, + "originalTimestamp": "2022-08-30T09:02:39.191Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/monday/test_1.json b/go/webhook/testcases/testdata/testcases/monday/test_1.json new file mode 100644 index 0000000000..6ecba956cf --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/monday/test_1.json @@ -0,0 +1,72 @@ +{ + "name": "monday", + "description": "test-1", + "input": { + "request": { + "body": { + "event": { + "userId": 33556506, + "originalTriggerUuid": null, + "boardId": 3139815405, + "itemId": 3160188786, + "itemName": "New Sprint Item", + "app": "monday", + "type": "delete_pulse", + "triggerTime": "2022-08-30T09:06:09.176Z", + "subscriptionId": 150882006, + "triggerUuid": "4e4f87c8255c4ba4ba2f5e9934cb6d40" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Delete Pulse", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "externalId": [ + { + "id": 33556506, + "type": "mondayUserId" + } + ], + "integration": { + "name": "MONDAY" + } + }, + "timestamp": "2022-08-30T09:06:09.176Z", + "properties": { + "app": "monday", + "type": "delete_pulse", + "itemId": 3160188786, + "boardId": 3139815405, + "itemName": "New Sprint Item", + "triggerUuid": "4e4f87c8255c4ba4ba2f5e9934cb6d40", + "subscriptionId": 150882006, + "originalTriggerUuid": null + }, + "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", + "integrations": { + "MONDAY": false + }, + "originalTimestamp": "2022-08-30T09:06:09.176Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/monday/test_2.json b/go/webhook/testcases/testdata/testcases/monday/test_2.json new file mode 100644 index 0000000000..fbd8618b3c --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/monday/test_2.json @@ -0,0 +1,112 @@ +{ + "name": "monday", + "description": "test-2", + "input": { + "request": { + "body": { + "event": { + "userId": 33556506, + "originalTriggerUuid": null, + "boardId": 3139815405, + "groupId": "topics", + "pulseId": 3160181387, + "pulseName": "New Sprint Item", + "columnId": "status", + "columnType": "color", + "columnTitle": "Status", + "value": { + "label": { + "index": 1, + "text": "Done", + "style": { + "color": "#00c875", + "border": "#00B461", + "var_name": "green-shadow" + }, + "is_done": true + }, + "post_id": null + }, + "previousValue": null, + "changedAt": 1661859406.8970098, + "isTopGroup": true, + "app": "monday", + "type": "update_column_value", + "triggerTime": "2022-08-30T11:36:47.406Z", + "subscriptionId": 150894742, + "triggerUuid": "51730730740a9d00ec45203bd392a9bd" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Update Column Value", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "externalId": [ + { + "id": 33556506, + "type": "mondayUserId" + } + ], + "integration": { + "name": "MONDAY" + } + }, + "timestamp": "2022-08-30T11:36:47.406Z", + "properties": { + "app": "monday", + "type": "update_column_value", + "value": { + "label": { + "text": "Done", + "index": 1, + "style": { + "color": "#00c875", + "border": "#00B461", + "var_name": "green-shadow" + }, + "is_done": true + }, + "post_id": null + }, + "boardId": 3139815405, + "groupId": "topics", + "pulseId": 3160181387, + "columnId": "status", + "changedAt": 1661859406.8970098, + "pulseName": "New Sprint Item", + "columnType": "color", + "isTopGroup": true, + "columnTitle": "Status", + "triggerUuid": "51730730740a9d00ec45203bd392a9bd", + "previousValue": null, + "subscriptionId": 150894742, + "originalTriggerUuid": null + }, + "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", + "integrations": { + "MONDAY": false + }, + "originalTimestamp": "2022-08-30T11:36:47.406Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/monday/test_3.json b/go/webhook/testcases/testdata/testcases/monday/test_3.json new file mode 100644 index 0000000000..b73fbf0ca4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/monday/test_3.json @@ -0,0 +1,84 @@ +{ + "name": "monday", + "description": "test-3", + "input": { + "request": { + "body": { + "event": { + "userId": 33556506, + "originalTriggerUuid": null, + "boardId": 3139815405, + "groupId": "topics", + "pulseId": 3160181387, + "value": { + "name": "New Sprint Item renamed" + }, + "previousValue": { + "name": "New Sprint Item" + }, + "app": "monday", + "type": "update_name", + "triggerTime": "2022-08-30T11:40:17.351Z", + "subscriptionId": 150910867, + "triggerUuid": "05ce13d32d0256c4fb7dd5de25b1a1ba" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Update Name", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "externalId": [ + { + "id": 33556506, + "type": "mondayUserId" + } + ], + "integration": { + "name": "MONDAY" + } + }, + "timestamp": "2022-08-30T11:40:17.351Z", + "properties": { + "app": "monday", + "type": "update_name", + "value": { + "name": "New Sprint Item renamed" + }, + "boardId": 3139815405, + "groupId": "topics", + "pulseId": 3160181387, + "triggerUuid": "05ce13d32d0256c4fb7dd5de25b1a1ba", + "previousValue": { + "name": "New Sprint Item" + }, + "subscriptionId": 150910867, + "originalTriggerUuid": null + }, + "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", + "integrations": { + "MONDAY": false + }, + "originalTimestamp": "2022-08-30T11:40:17.351Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/monday/test_4.json b/go/webhook/testcases/testdata/testcases/monday/test_4.json new file mode 100644 index 0000000000..6e0c11ca26 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/monday/test_4.json @@ -0,0 +1,88 @@ +{ + "name": "monday", + "description": "test-4", + "input": { + "request": { + "body": { + "event": { + "userId": 33556506, + "originalTriggerUuid": null, + "boardId": 3160805239, + "pulseId": 3161163765, + "pulseName": "new subitem", + "groupId": "topics", + "groupName": "Subitems", + "groupColor": "#579bfc", + "isTopGroup": true, + "columnValues": {}, + "app": "monday", + "type": "create_pulse", + "triggerTime": "2022-08-30T12:56:27.281Z", + "subscriptionId": 150911592, + "triggerUuid": "70a2219427804e47a508a91b5c244543", + "parentItemId": "3160181387", + "parentItemBoardId": "3139815405", + "itemId": 3161163765 + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Create Pulse", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "externalId": [ + { + "id": 33556506, + "type": "mondayUserId" + } + ], + "integration": { + "name": "MONDAY" + } + }, + "timestamp": "2022-08-30T12:56:27.281Z", + "properties": { + "app": "monday", + "type": "create_pulse", + "itemId": 3161163765, + "boardId": 3160805239, + "groupId": "topics", + "pulseId": 3161163765, + "groupName": "Subitems", + "pulseName": "new subitem", + "groupColor": "#579bfc", + "isTopGroup": true, + "triggerUuid": "70a2219427804e47a508a91b5c244543", + "columnValues": {}, + "parentItemId": "3160181387", + "subscriptionId": 150911592, + "parentItemBoardId": "3139815405", + "originalTriggerUuid": null + }, + "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", + "integrations": { + "MONDAY": false + }, + "originalTimestamp": "2022-08-30T12:56:27.281Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/monday/test_5.json b/go/webhook/testcases/testdata/testcases/monday/test_5.json new file mode 100644 index 0000000000..0c41c845dd --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/monday/test_5.json @@ -0,0 +1,72 @@ +{ + "name": "monday", + "description": "test-5", + "input": { + "request": { + "body": { + "event": { + "userId": 33556506, + "originalTriggerUuid": null, + "boardId": 3139815405, + "itemId": 3160181387, + "itemName": "New Sprint Item renamed", + "app": "monday", + "type": "archive_pulse", + "triggerTime": "2022-08-30T12:58:15.844Z", + "subscriptionId": 150925947, + "triggerUuid": "aa8bd5dbb6fd592aedd57322dd776379" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Archive Pulse", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "externalId": [ + { + "id": 33556506, + "type": "mondayUserId" + } + ], + "integration": { + "name": "MONDAY" + } + }, + "timestamp": "2022-08-30T12:58:15.844Z", + "properties": { + "app": "monday", + "type": "archive_pulse", + "itemId": 3160181387, + "boardId": 3139815405, + "itemName": "New Sprint Item renamed", + "triggerUuid": "aa8bd5dbb6fd592aedd57322dd776379", + "subscriptionId": 150925947, + "originalTriggerUuid": null + }, + "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", + "integrations": { + "MONDAY": false + }, + "originalTimestamp": "2022-08-30T12:58:15.844Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/olark/olark_webhook_response.json b/go/webhook/testcases/testdata/testcases/olark/olark_webhook_response.json new file mode 100644 index 0000000000..031940996c --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/olark/olark_webhook_response.json @@ -0,0 +1,122 @@ +{ + "name": "olark", + "description": "Olark webhook response", + "input": { + "request": { + "body": { + "kind": "Conversation", + "id": "ho6HrHxoabmm6q0G103JU0JFaor0BobA", + "manuallySubmitted": false, + "items": [ + { + "kind": "OfflineMessage", + "timestamp": "1669288532.567071", + "body": "name: test rudderstack\nemail: rudder14@gmail.com\nMessage: veavv" + } + ], + "tags": [], + "groups": [ + { + "kind": "Group", + "id": "ca77f4296fb7568909ad864aebf48201", + "name": "Group 1" + } + ], + "visitor": { + "kind": "Visitor", + "id": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", + "fullName": "test rudderstack", + "emailAddress": "rudder14@gmail.com", + "ip": "", + "country": "India", + "countryCode": "IN", + "browser": "Chrome 105.0.0.0", + "operatingSystem": "Macintosh", + "conversationBeginPage": "http://localhost:5503/" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Conversation", + "traits": {}, + "userId": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", + "context": { + "os": { + "name": "Macintosh" + }, + "page": { + "url": "http://localhost:5503/" + }, + "traits": { + "name": "test rudderstack", + "email": "rudder14@gmail.com", + "country": "India" + }, + "browser": { + "name": "Chrome", + "version": "105.0.0.0" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Olark" + } + }, + "properties": { + "tags": [], + "items": [ + { + "body": "name: test rudderstack\nemail: rudder14@gmail.com\nMessage: veavv", + "kind": "OfflineMessage", + "timestamp": "1669288532.567071" + } + ] + }, + "integrations": { + "Olark": false + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "name": "Group 1", + "type": "group", + "traits": { + "kind": "Group" + }, + "userId": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Olark" + } + }, + "groupId": "ca77f4296fb7568909ad864aebf48201", + "integrations": { + "Olark": false + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/ortto/simple_track_call.json b/go/webhook/testcases/testdata/testcases/ortto/simple_track_call.json new file mode 100644 index 0000000000..81e7241355 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/ortto/simple_track_call.json @@ -0,0 +1,108 @@ +{ + "name": "ortto", + "description": "Simple track call", + "input": { + "request": { + "body": { + "activity": { + "id": "00651b946bfef7e80478efee", + "field_id": "act::s-all", + "created": "2023-10-03T04:11:23Z", + "attr": { + "str::is": "API", + "str::s-ctx": "Subscribed via API" + } + }, + "contact": { + "external_id": "user_x", + "city": { + "name": "Kolkata", + "id": 0, + "lat": 37751000, + "lng": -97822000 + }, + "country": { + "name": "United States", + "id": 6252001, + "lat": 0, + "lng": 0 + }, + "email": "xyz@email.com", + "first_name": "Ujjwal", + "last_name": "Ujjwal", + "birthday": { + "year": 1980, + "month": 12, + "day": 11, + "timezone": "Australia/Sydney" + }, + "phone_number": { + "c": "91", + "n": "401234567" + } + }, + "id": "00651b946cef87c7af64f4f3", + "time": "2023-10-03T04:11:24.25726779Z", + "webhook_id": "651b8aec8002153e16319fd3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "user_x", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "ortto" + }, + "traits": { + "email": "xyz@email.com", + "birthday": "1980-12-11", + "firstName": "Ujjwal", + "lastName": "Ujjwal", + "phone": "91401234567", + "address": { + "city": "Kolkata", + "country": "United States" + } + } + }, + "event": "Resubscribe globally", + "integrations": { + "ortto": false + }, + "type": "track", + "messageId": "00651b946cef87c7af64f4f3", + "originalTimestamp": "2023-10-03T04:11:24.000Z", + "properties": { + "activity.id": "00651b946bfef7e80478efee", + "activity.created": "2023-10-03T04:11:23Z", + "activity.attr.str::is": "API", + "activity.attr.str::s-ctx": "Subscribed via API", + "contact.birthday.timezone": "Australia/Sydney", + "contact.city.id": 0, + "contact.city.lat": 37751000, + "contact.city.lng": -97822000, + "contact.country.id": 6252001, + "contact.country.lat": 0, + "contact.country.lng": 0, + "webhook_id": "651b8aec8002153e16319fd3" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/ortto/simple_track_call_with_unknown_field_id.json b/go/webhook/testcases/testdata/testcases/ortto/simple_track_call_with_unknown_field_id.json new file mode 100644 index 0000000000..6ee5ab4237 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/ortto/simple_track_call_with_unknown_field_id.json @@ -0,0 +1,104 @@ +{ + "name": "ortto", + "description": "Simple track call with unknown field id", + "input": { + "request": { + "body": { + "activity": { + "id": "00651b946bfef7e80478efee", + "field_id": "act::test_webhook", + "created": "2023-10-03T04:11:23Z", + "attr": { + "str::is": "API", + "str::s-ctx": "Subscribed via API" + } + }, + "contact": { + "external_id": "user_x", + "city": { + "name": "Kolkata", + "id": 0, + "lat": 37751000, + "lng": -97822000 + }, + "contact_id": "006524f0b8d370050056e400", + "country": { + "name": "United States", + "id": 6252001, + "lat": 0, + "lng": 0 + }, + "email": "xyz@email.com", + "first_name": "Ujjwal", + "last_name": "Ujjwal", + "birthday": { + "year": 1980, + "month": 3, + "day": 4, + "timezone": "Australia/Sydney" + }, + "phone_number": { + "c": "91", + "n": "401234567" + } + }, + "id": "00651b946cef87c7af64f4f3", + "time": "2023-10-03T04:11:24.25726779Z", + "webhook_id": "651b8aec8002153e16319fd3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": { + "activity": { + "id": "00651b946bfef7e80478efee", + "field_id": "act::test_webhook", + "created": "2023-10-03T04:11:23Z", + "attr": { + "str::is": "API", + "str::s-ctx": "Subscribed via API" + } + }, + "contact": { + "external_id": "user_x", + "city": { + "name": "Kolkata", + "id": 0, + "lat": 37751000, + "lng": -97822000 + }, + "contact_id": "006524f0b8d370050056e400", + "country": { + "name": "United States", + "id": 6252001, + "lat": 0, + "lng": 0 + }, + "email": "xyz@email.com", + "first_name": "Ujjwal", + "last_name": "Ujjwal", + "birthday": { + "year": 1980, + "month": 3, + "day": 4, + "timezone": "Australia/Sydney" + }, + "phone_number": { + "c": "91", + "n": "401234567" + } + }, + "id": "00651b946cef87c7af64f4f3", + "time": "2023-10-03T04:11:24.25726779Z", + "webhook_id": "651b8aec8002153e16319fd3" + } + }, + "queue": [], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pagerduty/incident_escalated.json b/go/webhook/testcases/testdata/testcases/pagerduty/incident_escalated.json new file mode 100644 index 0000000000..eb7c31251b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pagerduty/incident_escalated.json @@ -0,0 +1,157 @@ +{ + "name": "pagerduty", + "description": "Incident Escalated", + "input": { + "request": { + "body": { + "event": { + "id": "01DFU77KTKK9UUYX779UX0N1ZP", + "event_type": "incident.escalated", + "resource_type": "incident", + "occurred_at": "2022-12-20T11:49:35.385Z", + "agent": { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + }, + "client": null, + "data": { + "id": "Q1KRTY75EUMGM0", + "type": "incident", + "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "number": 7, + "status": "triggered", + "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", + "created_at": "2022-12-20T11:37:19Z", + "title": "Event Stream Failure", + "service": { + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "summary": "Database", + "type": "service_reference" + }, + "assignees": [ + { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + } + ], + "escalation_policy": { + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "summary": "Default", + "type": "escalation_policy_reference" + }, + "teams": [], + "priority": { + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", + "id": "PPMNDVQ", + "self": "https://api.pagerduty.com/priorities/PPMNDVQ", + "summary": "P1", + "type": "priority_reference" + }, + "urgency": "high", + "conference_bridge": null, + "resolve_reason": null + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Incident Escalated", + "userId": "PXZZD2E", + "context": { + "traits": { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "PagerDuty" + } + }, + "messageId": "01DFU77KTKK9UUYX779UX0N1ZP", + "properties": { + "data": { + "id": "Q1KRTY75EUMGM0", + "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "type": "incident", + "teams": [], + "title": "Event Stream Failure", + "number": 7, + "status": "triggered", + "service": { + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "type": "service_reference", + "summary": "Database", + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" + }, + "urgency": "high", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "priority": { + "id": "PPMNDVQ", + "self": "https://api.pagerduty.com/priorities/PPMNDVQ", + "type": "priority_reference", + "summary": "P1", + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" + }, + "assignees": [ + { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + } + ], + "created_at": "2022-12-20T11:37:19Z", + "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", + "resolve_reason": null, + "conference_bridge": null, + "escalation_policy": { + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "type": "escalation_policy_reference", + "summary": "Default", + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" + } + }, + "resourceType": "incident" + }, + "integrations": { + "PagerDuty": false + }, + "originalTimestamp": "2022-12-20T11:49:35.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pagerduty/incident_priority_updated.json b/go/webhook/testcases/testdata/testcases/pagerduty/incident_priority_updated.json new file mode 100644 index 0000000000..846efe5749 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pagerduty/incident_priority_updated.json @@ -0,0 +1,157 @@ +{ + "name": "pagerduty", + "description": "Incident Priority Updated", + "input": { + "request": { + "body": { + "event": { + "id": "01DFU6P4VDDZCIHVQ5Q0ME99OE", + "event_type": "incident.priority_updated", + "resource_type": "incident", + "occurred_at": "2022-12-20T11:43:24.342Z", + "agent": { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + }, + "client": null, + "data": { + "id": "Q1KRTY75EUMGM0", + "type": "incident", + "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "number": 7, + "status": "acknowledged", + "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", + "created_at": "2022-12-20T11:37:19Z", + "title": "Event Stream Failure", + "service": { + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "summary": "Database", + "type": "service_reference" + }, + "assignees": [ + { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + } + ], + "escalation_policy": { + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "summary": "Default", + "type": "escalation_policy_reference" + }, + "teams": [], + "priority": { + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", + "id": "PPMNDVQ", + "self": "https://api.pagerduty.com/priorities/PPMNDVQ", + "summary": "P1", + "type": "priority_reference" + }, + "urgency": "high", + "conference_bridge": null, + "resolve_reason": null + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Incident Priority Updated", + "userId": "PXZZD2E", + "context": { + "traits": { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "PagerDuty" + } + }, + "messageId": "01DFU6P4VDDZCIHVQ5Q0ME99OE", + "properties": { + "data": { + "id": "Q1KRTY75EUMGM0", + "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "type": "incident", + "teams": [], + "title": "Event Stream Failure", + "number": 7, + "status": "acknowledged", + "service": { + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "type": "service_reference", + "summary": "Database", + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" + }, + "urgency": "high", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "priority": { + "id": "PPMNDVQ", + "self": "https://api.pagerduty.com/priorities/PPMNDVQ", + "type": "priority_reference", + "summary": "P1", + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" + }, + "assignees": [ + { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + } + ], + "created_at": "2022-12-20T11:37:19Z", + "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", + "resolve_reason": null, + "conference_bridge": null, + "escalation_policy": { + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "type": "escalation_policy_reference", + "summary": "Default", + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" + } + }, + "resourceType": "incident" + }, + "integrations": { + "PagerDuty": false + }, + "originalTimestamp": "2022-12-20T11:43:24.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pagerduty/incident_resolved.json b/go/webhook/testcases/testdata/testcases/pagerduty/incident_resolved.json new file mode 100644 index 0000000000..c4766e3722 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pagerduty/incident_resolved.json @@ -0,0 +1,147 @@ +{ + "name": "pagerduty", + "description": "Incident Resolved", + "input": { + "request": { + "body": { + "event": { + "id": "01DEN1HNLBC1VITK192ETJ1MPJ", + "event_type": "incident.resolved", + "resource_type": "incident", + "occurred_at": "2022-12-07T11:04:27.459Z", + "agent": { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + }, + "client": null, + "data": { + "id": "Q3S7IX2U5KTCOY", + "type": "incident", + "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "number": 2, + "status": "resolved", + "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", + "created_at": "2022-12-07T10:56:52Z", + "title": "Server Crashed", + "service": { + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "summary": "Database", + "type": "service_reference" + }, + "assignees": [], + "escalation_policy": { + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "summary": "Default", + "type": "escalation_policy_reference" + }, + "teams": [], + "priority": { + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", + "id": "P5DBC3A", + "self": "https://api.pagerduty.com/priorities/P5DBC3A", + "summary": "P3", + "type": "priority_reference" + }, + "urgency": "high", + "conference_bridge": { + "conference_number": "", + "conference_url": "" + }, + "resolve_reason": null + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Incident Resolved", + "userId": "PXZZD2E", + "context": { + "traits": { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "PagerDuty" + } + }, + "messageId": "01DEN1HNLBC1VITK192ETJ1MPJ", + "properties": { + "data": { + "id": "Q3S7IX2U5KTCOY", + "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "type": "incident", + "teams": [], + "title": "Server Crashed", + "number": 2, + "status": "resolved", + "service": { + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "type": "service_reference", + "summary": "Database", + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" + }, + "urgency": "high", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "priority": { + "id": "P5DBC3A", + "self": "https://api.pagerduty.com/priorities/P5DBC3A", + "type": "priority_reference", + "summary": "P3", + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" + }, + "assignees": [], + "created_at": "2022-12-07T10:56:52Z", + "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", + "resolve_reason": null, + "conference_bridge": { + "conference_url": "", + "conference_number": "" + }, + "escalation_policy": { + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "type": "escalation_policy_reference", + "summary": "Default", + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" + } + }, + "resourceType": "incident" + }, + "integrations": { + "PagerDuty": false + }, + "originalTimestamp": "2022-12-07T11:04:27.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pagerduty/incident_responder_added.json b/go/webhook/testcases/testdata/testcases/pagerduty/incident_responder_added.json new file mode 100644 index 0000000000..b78369162b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pagerduty/incident_responder_added.json @@ -0,0 +1,107 @@ +{ + "name": "pagerduty", + "description": "Incident Responder Added", + "input": { + "request": { + "body": { + "event": { + "id": "01DFU6Z1ZCLMV9SEK3X5JZ5WLW", + "event_type": "incident.responder.added", + "resource_type": "incident", + "occurred_at": "2022-12-20T11:46:44.213Z", + "agent": { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + }, + "client": null, + "data": { + "incident": { + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "id": "Q1KRTY75EUMGM0", + "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "summary": "Event Stream Failure", + "type": "incident_reference" + }, + "user": { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + }, + "escalation_policy": null, + "message": "Please help with \"Event Stream Failure\"", + "state": "pending", + "type": "incident_responder" + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Incident Responder Added", + "userId": "PXZZD2E", + "context": { + "traits": { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "PagerDuty" + } + }, + "messageId": "01DFU6Z1ZCLMV9SEK3X5JZ5WLW", + "properties": { + "data": { + "type": "incident_responder", + "user": { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + }, + "state": "pending", + "message": "Please help with \"Event Stream Failure\"", + "incident": { + "id": "Q1KRTY75EUMGM0", + "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", + "type": "incident_reference", + "summary": "Event Stream Failure", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0" + }, + "escalation_policy": null + }, + "resourceType": "incident" + }, + "integrations": { + "PagerDuty": false + }, + "originalTimestamp": "2022-12-20T11:46:44.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pagerduty/incident_triggered.json b/go/webhook/testcases/testdata/testcases/pagerduty/incident_triggered.json new file mode 100644 index 0000000000..bfb4c1e86f --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pagerduty/incident_triggered.json @@ -0,0 +1,164 @@ +{ + "name": "pagerduty", + "description": "Incident Triggered", + "input": { + "request": { + "body": { + "event": { + "id": "01DEN0V2VIFEN5871PQGX72URP", + "event_type": "incident.triggered", + "resource_type": "incident", + "occurred_at": "2022-12-07T10:56:52.337Z", + "agent": { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + }, + "client": { + "name": "Monitoring Service", + "url": "https://monitoring.service.com" + }, + "data": { + "id": "Q3S7IX2U5KTCOY", + "type": "incident", + "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "number": 2, + "status": "triggered", + "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", + "created_at": "2022-12-07T10:56:52Z", + "title": "Server Crashed", + "service": { + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "summary": "Database", + "type": "service_reference" + }, + "assignees": [ + { + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "summary": "rudder test", + "type": "user_reference" + } + ], + "escalation_policy": { + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "summary": "Default", + "type": "escalation_policy_reference" + }, + "teams": [], + "priority": { + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", + "id": "PPMNDVQ", + "self": "https://api.pagerduty.com/priorities/PPMNDVQ", + "summary": "P1", + "type": "priority_reference" + }, + "urgency": "high", + "conference_bridge": null, + "resolve_reason": null + } + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "track", + "event": "Incident Triggered", + "userId": "PXZZD2E", + "context": { + "traits": { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "PagerDuty" + } + }, + "messageId": "01DEN0V2VIFEN5871PQGX72URP", + "properties": { + "data": { + "id": "Q3S7IX2U5KTCOY", + "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "type": "incident", + "teams": [], + "title": "Server Crashed", + "number": 2, + "status": "triggered", + "service": { + "id": "PAJBUTT", + "self": "https://api.pagerduty.com/services/PAJBUTT", + "type": "service_reference", + "summary": "Database", + "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" + }, + "urgency": "high", + "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", + "priority": { + "id": "PPMNDVQ", + "self": "https://api.pagerduty.com/priorities/PPMNDVQ", + "type": "priority_reference", + "summary": "P1", + "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" + }, + "assignees": [ + { + "id": "PXZZD2E", + "self": "https://api.pagerduty.com/users/user@1", + "type": "user_reference", + "summary": "rudder test", + "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" + } + ], + "created_at": "2022-12-07T10:56:52Z", + "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", + "resolve_reason": null, + "conference_bridge": null, + "escalation_policy": { + "id": "PB7HKU4", + "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", + "type": "escalation_policy_reference", + "summary": "Default", + "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" + } + }, + "client": { + "url": "https://monitoring.service.com", + "name": "Monitoring Service" + }, + "resourceType": "incident" + }, + "integrations": { + "PagerDuty": false + }, + "originalTimestamp": "2022-12-07T10:56:52.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/alias_type____type_and_user_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/alias_type____type_and_user_id_is_given.json new file mode 100644 index 0000000000..d28c468cb7 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/alias_type____type_and_user_id_is_given.json @@ -0,0 +1,33 @@ +{ + "name": "pipedream", + "description": "Alias type -> type and userId is given", + "input": { + "request": { + "body": { + "type": "alias", + "previousId": "name@surname.com", + "userId": "12345" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "alias", + "previousId": "name@surname.com", + "userId": "12345", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/group_type____type_and_user_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/group_type____type_and_user_id_is_given.json new file mode 100644 index 0000000000..9f65d0a516 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/group_type____type_and_user_id_is_given.json @@ -0,0 +1,41 @@ +{ + "name": "pipedream", + "description": "Group type -> type and userId is given", + "input": { + "request": { + "body": { + "userId": "user123", + "groupId": "17", + "context": {}, + "traits": { + "operation": "add" + }, + "type": "group" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "user123", + "groupId": "17", + "context": {}, + "traits": { + "operation": "add" + }, + "type": "group", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/identify_type____type_and_user_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/identify_type____type_and_user_id_is_given.json new file mode 100644 index 0000000000..a8ddaecf11 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/identify_type____type_and_user_id_is_given.json @@ -0,0 +1,67 @@ +{ + "name": "pipedream", + "description": "Identify type -> type and userId is given", + "input": { + "request": { + "body": { + "userId": "1", + "originalTimestamp": "2020-09-28T19:53:31.900Z", + "traits": { + "firstName": "John", + "lastName": "doe", + "email": "John@r.com", + "hasPurchased": "yes", + "address": { + "Home": { + "city": "iudcb" + }, + "Office": { + "abc": "jbc" + } + }, + "state": "Delhi", + "title": "Mr" + }, + "timestamp": "2020-09-29T14:50:29.907+05:30", + "type": "identify" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "userId": "1", + "originalTimestamp": "2020-09-28T19:53:31.900Z", + "traits": { + "firstName": "John", + "lastName": "doe", + "email": "John@r.com", + "hasPurchased": "yes", + "address": { + "Home": { + "city": "iudcb" + }, + "Office": { + "abc": "jbc" + } + }, + "state": "Delhi", + "title": "Mr" + }, + "timestamp": "2020-09-29T14:50:29.907+05:30", + "type": "identify", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/no_type_or_anonymous_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/no_type_or_anonymous_id_is_given.json new file mode 100644 index 0000000000..2933fe5d0a --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/no_type_or_anonymous_id_is_given.json @@ -0,0 +1,52 @@ +{ + "name": "pipedream", + "description": "No type or anonymousId is given", + "input": { + "request": { + "body": { + "userId": "12", + "artist": "Gautam", + "genre": "Jazz", + "song": "Take Five" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "event": "pipedream_source_event", + "anonymousId": "12", + "context": { + "integration": { + "name": "PIPEDREAM" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "integrations": { + "PIPEDREAM": false + }, + "type": "track", + "properties": { + "userId": "12", + "artist": "Gautam", + "genre": "Jazz", + "song": "Take Five" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/no_type_or_user_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/no_type_or_user_id_is_given.json new file mode 100644 index 0000000000..1c66c40795 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/no_type_or_user_id_is_given.json @@ -0,0 +1,52 @@ +{ + "name": "pipedream", + "description": "No type or userId is given", + "input": { + "request": { + "body": { + "anonymousId": "63767499ca6fb1b7c988d5bb", + "artist": "Gautam", + "genre": "Jazz", + "song": "Take Five" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "event": "pipedream_source_event", + "anonymousId": "63767499ca6fb1b7c988d5bb", + "context": { + "integration": { + "name": "PIPEDREAM" + }, + "library": { + "name": "unknown", + "version": "unknown" + } + }, + "integrations": { + "PIPEDREAM": false + }, + "type": "track", + "properties": { + "anonymousId": "63767499ca6fb1b7c988d5bb", + "artist": "Gautam", + "genre": "Jazz", + "song": "Take Five" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/page_type____type_and_user_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/page_type____type_and_user_id_is_given.json new file mode 100644 index 0000000000..62cf4d27a2 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/page_type____type_and_user_id_is_given.json @@ -0,0 +1,65 @@ +{ + "name": "pipedream", + "description": "Page type -> type and userId is given", + "input": { + "request": { + "body": { + "anonymousId": "21e13f4bc7ceddad", + "channel": "mobile", + "context": { + "os": { + "name": "Android", + "version": "9" + }, + "timezone": "Asia/Kolkata", + "traits": { + "customProp": "customValue" + }, + "userAgent": "Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)" + }, + "name": "Home", + "properties": { + "title": "Home | RudderStack", + "url": "http://www.rudderstack.com" + }, + "type": "page" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "anonymousId": "21e13f4bc7ceddad", + "channel": "mobile", + "context": { + "os": { + "name": "Android", + "version": "9" + }, + "timezone": "Asia/Kolkata", + "traits": { + "customProp": "customValue" + }, + "userAgent": "Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)" + }, + "name": "Home", + "properties": { + "title": "Home | RudderStack", + "url": "http://www.rudderstack.com" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "type": "page", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/pipedream/track_call____type_and_user_id_is_given.json b/go/webhook/testcases/testdata/testcases/pipedream/track_call____type_and_user_id_is_given.json new file mode 100644 index 0000000000..7da284c456 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/pipedream/track_call____type_and_user_id_is_given.json @@ -0,0 +1,101 @@ +{ + "name": "pipedream", + "description": "Track Call -> type and userId is given", + "input": { + "request": { + "body": { + "event": "Song Played", + "userId": "R1234", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe", + "userDeleted": false + }, + "locale": "en", + "location": { + "country": "IN", + "countryName": "India", + "short": "India", + "long": "India" + }, + "device": { + "os": "macOS", + "type": "desktop" + }, + "page": { + "referrer": "http://127.0.0.1:5500/testSm.html" + } + }, + "type": "track", + "properties": { + "artist": "John", + "Album": "ABCD" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "event": "Song Played", + "userId": "R1234", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe", + "userDeleted": false + }, + "locale": "en", + "location": { + "country": "IN", + "countryName": "India", + "short": "India", + "long": "India" + }, + "device": { + "os": "macOS", + "type": "desktop" + }, + "page": { + "referrer": "http://127.0.0.1:5500/testSm.html" + } + }, + "type": "track", + "properties": { + "artist": "John", + "Album": "ABCD" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/refiner/refiner_webhook_response.json b/go/webhook/testcases/testdata/testcases/refiner/refiner_webhook_response.json new file mode 100644 index 0000000000..e6d72fa7c4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/refiner/refiner_webhook_response.json @@ -0,0 +1,211 @@ +{ + "name": "refiner", + "description": "Refiner webhook response", + "input": { + "request": { + "body": { + "uuid": "69b83e20-4ea2-11ed-941c-e1cb6c7a3870", + "cookie_uuid": "2f9b7e6a-9ba8-1c68-d474-48d719d92a60", + "project_uuid": "0d8759d0-401c-11ed-8ded-9757c4929b55", + "remote_id": "sdk@30", + "email": "sdk30@gmail.com", + "display_name": "", + "first_seen_at": "2022-10-18T05:04:58.000000Z", + "last_seen_at": "2022-10-18T05:04:58.000000Z", + "attributes": { + "address": null, + "address_city": null, + "address_state": null, + "age": null, + "another_attribute": null, + "city": null, + "country": null, + "created_at": null, + "email": "sdk30@gmail.com", + "event": null, + "first_name": null, + "first_seen_at": "2022-10-18T05:04:58.000000Z", + "form_submissions_count": "1", + "form_views_count": "1", + "gender": null, + "last_form_submission_at": "2022-10-18T05:05:45.000000Z", + "last_form_view_at": "2022-10-18T05:05:29.000000Z", + "last_name": null, + "last_seen_at": "2022-10-18T05:04:58.000000Z", + "name": null, + "phone": null, + "some_attribute": null, + "status": null, + "student": null, + "tag": null, + "trait1": null, + "trait2": null, + "trait3": null, + "url": null, + "user_address_city": null, + "user_address_state": null, + "user_country": null, + "user_id": null, + "username": null, + "useroccupation": null, + "why_did_you_cancel_your_subscription": "Missing features" + }, + "segments": [ + { + "uuid": "0d91d7a0-401c-11ed-8898-bb1ee0c23ae5", + "name": "All Users", + "created_at": "2022-10-18T05:04:58.000000Z", + "updated_at": "2022-10-18T05:04:58.000000Z" + }, + { + "uuid": "f71ad940-455c-11ed-85e0-bf25f168b224", + "name": "test-segment", + "created_at": "2022-10-18T05:04:58.000000Z", + "updated_at": "2022-10-18T05:04:58.000000Z" + } + ], + "account": { + "uuid": "69ba2030-4ea2-11ed-adfc-595e70c7ab07", + "remote_id": null, + "domain": null, + "display_name": "", + "first_seen_at": "2022-10-18T05:04:58.000000Z", + "last_seen_at": "2022-10-18T05:04:58.000000Z", + "attributes": { + "1": null, + "2": null, + "3": null, + "4": null, + "a_date_at": null, + "business_email": null, + "company": null, + "email": null, + "isfunded": null, + "location": null, + "name": null, + "revenue": null, + "some_account_data": null, + "trait1": null, + "trait2": null, + "trait3": null, + "user_id": null + } + }, + "triggered_event": "Completed Survey", + "form": { + "uuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", + "name": "Customer Churn Survey" + }, + "response": { + "uuid": "7c508c60-4ea2-11ed-9302-57708fe11d26", + "first_shown_at": "2022-10-18T05:05:29.000000Z", + "last_shown_at": "2022-10-18T05:05:29.000000Z", + "show_counter": null, + "first_data_reception_at": "2022-10-18T05:05:45.000000Z", + "last_data_reception_at": "2022-10-18T05:05:45.000000Z", + "completed_at": "2022-10-18T05:05:45.000000Z", + "dismissed_at": null, + "received_at": "2022-10-18T05:05:45.000000Z", + "data": { + "why_did_you_cancel_your_subscription": "Missing features" + }, + "tags": [] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "type": "identify", + "traits": { + "why_did_you_cancel_your_subscription": "Missing features" + }, + "userId": "sdk@30", + "context": { + "traits": { + "email": "sdk30@gmail.com", + "segments": [ + { + "name": "All Users", + "uuid": "0d91d7a0-401c-11ed-8898-bb1ee0c23ae5", + "created_at": "2022-10-18T05:04:58.000000Z", + "updated_at": "2022-10-18T05:04:58.000000Z" + }, + { + "name": "test-segment", + "uuid": "f71ad940-455c-11ed-85e0-bf25f168b224", + "created_at": "2022-10-18T05:04:58.000000Z", + "updated_at": "2022-10-18T05:04:58.000000Z" + } + ] + }, + "library": { + "name": "unknown", + "version": "unknown" + }, + "formName": "Customer Churn Survey", + "formUuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", + "integration": { + "name": "Refiner" + } + }, + "integrations": { + "Refiner": false + }, + "originalTimestamp": "2022-10-18T05:05:45.000000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "type": "track", + "event": "Completed Survey", + "userId": "sdk@30", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "formName": "Customer Churn Survey", + "formUuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", + "integration": { + "name": "Refiner" + } + }, + "properties": { + "response": { + "data": { + "why_did_you_cancel_your_subscription": "Missing features" + }, + "tags": [], + "uuid": "7c508c60-4ea2-11ed-9302-57708fe11d26", + "received_at": "2022-10-18T05:05:45.000000Z", + "completed_at": "2022-10-18T05:05:45.000000Z", + "last_shown_at": "2022-10-18T05:05:29.000000Z", + "first_shown_at": "2022-10-18T05:05:29.000000Z", + "last_data_reception_at": "2022-10-18T05:05:45.000000Z", + "first_data_reception_at": "2022-10-18T05:05:45.000000Z" + }, + "refiner_form_name": "Customer Churn Survey", + "refiner_form_uuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae" + }, + "integrations": { + "Refiner": false + }, + "originalTimestamp": "2022-10-18T05:05:45.000000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/revenuecat/initial_purchase_event.json b/go/webhook/testcases/testdata/testcases/revenuecat/initial_purchase_event.json new file mode 100644 index 0000000000..6dbcbd6622 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/revenuecat/initial_purchase_event.json @@ -0,0 +1,121 @@ +{ + "name": "revenuecat", + "description": "Initial purchase event", + "input": { + "request": { + "body": { + "api_version": "1.0", + "event": { + "aliases": ["yourCustomerAliasedID", "yourCustomerAliasedID"], + "app_id": "yourAppID", + "app_user_id": "yourCustomerAppUserID", + "commission_percentage": 0.3, + "country_code": "US", + "currency": "USD", + "entitlement_id": "pro_cat", + "entitlement_ids": ["pro_cat"], + "environment": "PRODUCTION", + "event_timestamp_ms": 1591121855319, + "expiration_at_ms": 1591726653000, + "id": "UniqueIdentifierOfEvent", + "is_family_share": false, + "offer_code": "free_month", + "original_app_user_id": "OriginalAppUserID", + "original_transaction_id": "1530648507000", + "period_type": "NORMAL", + "presented_offering_id": "OfferingID", + "price": 2.49, + "price_in_purchased_currency": 2.49, + "product_id": "onemonth_no_trial", + "purchased_at_ms": 1591121853000, + "store": "APP_STORE", + "subscriber_attributes": { + "$Favorite Cat": { + "updated_at_ms": 1581121853000, + "value": "Garfield" + } + }, + "takehome_percentage": 0.7, + "tax_percentage": 0.3, + "transaction_id": "170000869511114", + "type": "INITIAL_PURCHASE" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "RevenueCat" + }, + "externalId": [ + { + "type": "revenuecatAppUserId", + "id": "yourCustomerAppUserID" + } + ] + }, + "integrations": { + "RevenueCat": false + }, + "type": "track", + "properties": { + "aliases": ["yourCustomerAliasedID", "yourCustomerAliasedID"], + "appId": "yourAppID", + "appUserId": "yourCustomerAppUserID", + "commissionPercentage": 0.3, + "countryCode": "US", + "currency": "USD", + "entitlementId": "pro_cat", + "entitlementIds": ["pro_cat"], + "environment": "PRODUCTION", + "eventTimestampMs": 1591121855319, + "expirationAtMs": 1591726653000, + "id": "UniqueIdentifierOfEvent", + "isFamilyShare": false, + "offerCode": "free_month", + "originalAppUserId": "OriginalAppUserID", + "originalTransactionId": "1530648507000", + "periodType": "NORMAL", + "presentedOfferingId": "OfferingID", + "price": 2.49, + "priceInPurchasedCurrency": 2.49, + "productId": "onemonth_no_trial", + "purchasedAtMs": 1591121853000, + "store": "APP_STORE", + "subscriberAttributes": { + "$Favorite Cat": { + "updated_at_ms": 1581121853000, + "value": "Garfield" + } + }, + "takehomePercentage": 0.7, + "taxPercentage": 0.3, + "transactionId": "170000869511114", + "type": "INITIAL_PURCHASE" + }, + "event": "INITIAL_PURCHASE", + "userId": "yourCustomerAppUserID", + "messageId": "UniqueIdentifierOfEvent", + "originalTimestamp": "2020-06-02T18:17:35.319Z", + "sentAt": "2020-06-02T18:17:35.319Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/revenuecat/purchase_event_with_anonymous_user.json b/go/webhook/testcases/testdata/testcases/revenuecat/purchase_event_with_anonymous_user.json new file mode 100644 index 0000000000..12e2f4ba11 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/revenuecat/purchase_event_with_anonymous_user.json @@ -0,0 +1,112 @@ +{ + "name": "revenuecat", + "description": "Purchase event with anonymous user", + "input": { + "request": { + "body": { + "api_version": "1.0", + "event": { + "aliases": ["yourCustomerAliasedID", "yourCustomerAliasedID"], + "app_id": "yourAppID", + "commission_percentage": 0.3, + "country_code": "US", + "currency": "USD", + "entitlement_id": "pro_cat", + "entitlement_ids": ["pro_cat"], + "environment": "PRODUCTION", + "event_timestamp_ms": 1591121855319, + "expiration_at_ms": 1591726653000, + "id": "UniqueIdentifierOfEvent", + "is_family_share": false, + "offer_code": "free_month", + "original_transaction_id": "1530648507000", + "period_type": "NORMAL", + "presented_offering_id": "OfferingID", + "price": 2.49, + "price_in_purchased_currency": 2.49, + "product_id": "onemonth_no_trial", + "purchased_at_ms": 1591121853000, + "store": "APP_STORE", + "subscriber_attributes": { + "$Favorite Cat": { + "updated_at_ms": 1581121853000, + "value": "Garfield" + } + }, + "takehome_percentage": 0.7, + "tax_percentage": 0.3, + "transaction_id": "170000869511114", + "type": "INITIAL_PURCHASE" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "RevenueCat" + } + }, + "integrations": { + "RevenueCat": false + }, + "type": "track", + "properties": { + "aliases": ["yourCustomerAliasedID", "yourCustomerAliasedID"], + "appId": "yourAppID", + "commissionPercentage": 0.3, + "countryCode": "US", + "currency": "USD", + "entitlementId": "pro_cat", + "entitlementIds": ["pro_cat"], + "environment": "PRODUCTION", + "eventTimestampMs": 1591121855319, + "expirationAtMs": 1591726653000, + "id": "UniqueIdentifierOfEvent", + "isFamilyShare": false, + "offerCode": "free_month", + "originalTransactionId": "1530648507000", + "periodType": "NORMAL", + "presentedOfferingId": "OfferingID", + "price": 2.49, + "priceInPurchasedCurrency": 2.49, + "productId": "onemonth_no_trial", + "purchasedAtMs": 1591121853000, + "store": "APP_STORE", + "subscriberAttributes": { + "$Favorite Cat": { + "updated_at_ms": 1581121853000, + "value": "Garfield" + } + }, + "takehomePercentage": 0.7, + "taxPercentage": 0.3, + "transactionId": "170000869511114", + "type": "INITIAL_PURCHASE" + }, + "event": "INITIAL_PURCHASE", + "userId": "", + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "messageId": "UniqueIdentifierOfEvent", + "originalTimestamp": "2020-06-02T18:17:35.319Z", + "sentAt": "2020-06-02T18:17:35.319Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/revenuecat/simple_track_call.json b/go/webhook/testcases/testdata/testcases/revenuecat/simple_track_call.json new file mode 100644 index 0000000000..851537141b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/revenuecat/simple_track_call.json @@ -0,0 +1,149 @@ +{ + "name": "revenuecat", + "description": "Simple track call", + "input": { + "request": { + "body": { + "api_version": "1.0", + "event": { + "aliases": [ + "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "389ad6dd-bb40-4c03-9471-1353da2d55ec" + ], + "app_user_id": "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "commission_percentage": null, + "country_code": "US", + "currency": null, + "entitlement_id": null, + "entitlement_ids": null, + "environment": "SANDBOX", + "event_timestamp_ms": 1698617217232, + "expiration_at_ms": 1698624417232, + "id": "8CF0CD6C-CAF3-41FB-968A-661938235AF0", + "is_family_share": null, + "offer_code": null, + "original_app_user_id": "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "original_transaction_id": null, + "period_type": "NORMAL", + "presented_offering_id": null, + "price": null, + "price_in_purchased_currency": null, + "product_id": "test_product", + "purchased_at_ms": 1698617217232, + "store": "APP_STORE", + "subscriber_attributes": { + "$displayName": { + "updated_at_ms": 1698617217232, + "value": "Mister Mistoffelees" + }, + "$email": { + "updated_at_ms": 1698617217232, + "value": "tuxedo@revenuecat.com" + }, + "$phoneNumber": { + "updated_at_ms": 1698617217232, + "value": "+19795551234" + }, + "my_custom_attribute_1": { + "updated_at_ms": 1698617217232, + "value": "catnip" + } + }, + "takehome_percentage": null, + "tax_percentage": null, + "transaction_id": null, + "type": "TEST" + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "RevenueCat" + }, + "externalId": [ + { + "type": "revenuecatAppUserId", + "id": "f8e14f51-0c76-49ba-8d67-c229f1875dd9" + } + ] + }, + "integrations": { + "RevenueCat": false + }, + "type": "track", + "properties": { + "aliases": [ + "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "389ad6dd-bb40-4c03-9471-1353da2d55ec" + ], + "appUserId": "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "commissionPercentage": null, + "countryCode": "US", + "currency": null, + "entitlementId": null, + "entitlementIds": null, + "environment": "SANDBOX", + "eventTimestampMs": 1698617217232, + "expirationAtMs": 1698624417232, + "id": "8CF0CD6C-CAF3-41FB-968A-661938235AF0", + "isFamilyShare": null, + "offerCode": null, + "originalAppUserId": "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "originalTransactionId": null, + "periodType": "NORMAL", + "presentedOfferingId": null, + "price": null, + "priceInPurchasedCurrency": null, + "productId": "test_product", + "purchasedAtMs": 1698617217232, + "store": "APP_STORE", + "subscriberAttributes": { + "$displayName": { + "updated_at_ms": 1698617217232, + "value": "Mister Mistoffelees" + }, + "$email": { + "updated_at_ms": 1698617217232, + "value": "tuxedo@revenuecat.com" + }, + "$phoneNumber": { + "updated_at_ms": 1698617217232, + "value": "+19795551234" + }, + "my_custom_attribute_1": { + "updated_at_ms": 1698617217232, + "value": "catnip" + } + }, + "takehomePercentage": null, + "taxPercentage": null, + "transactionId": null, + "type": "TEST" + }, + "event": "TEST", + "userId": "f8e14f51-0c76-49ba-8d67-c229f1875dd9", + "messageId": "8CF0CD6C-CAF3-41FB-968A-661938235AF0", + "originalTimestamp": "2023-10-29T22:06:57.232Z", + "sentAt": "2023-10-29T22:06:57.232Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/satismeter/all_fields_check_with_event_as_completed.json b/go/webhook/testcases/testdata/testcases/satismeter/all_fields_check_with_event_as_completed.json new file mode 100644 index 0000000000..ed8ad4e0da --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/satismeter/all_fields_check_with_event_as_completed.json @@ -0,0 +1,244 @@ +{ + "name": "satismeter", + "description": " All fields Check with event as completed", + "input": { + "request": { + "body": { + "response": { + "id": "63767499ca6fb1b7c988d5bb", + "created": "2022-11-17T17:51:21.764Z", + "rating": 5, + "feedback": "Many things to imporve\n", + "dismissed": false, + "pending": false, + "answers": [ + { + "label": "How likely are you to recommend us to your friends and colleagues?", + "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", + "value": 5, + "name": "SM_rating", + "type": "scale", + "metric": "nps" + }, + { + "label": "What could we do to improve?", + "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", + "value": "Many things to imporve\n", + "name": "SM_comment", + "type": "long-text" + }, + { + "label": "The company made it easy for me to handle my issue.", + "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "scale", + "metric": "ces" + }, + { + "label": "How satisfied were you with the service you received?", + "id": "24c5b290-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "smiley", + "metric": "csat" + }, + { + "label": "How you like to rate the surevy?", + "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", + "value": 4, + "type": "scale" + }, + { + "label": "Your Name (Single Answer)", + "id": "37a8c000-66a0-11ed-856c-6f39711bf041", + "value": "a", + "type": "single-choice" + }, + { + "label": "Your Name (Multiple Answer)", + "id": "4b435da0-66a0-11ed-856c-6f39711bf041", + "value": ["a1", "b1"], + "type": "multiple-choice" + } + ], + "category": "detractor", + "score": -100, + "user": { + "id": "63766fbb7ac7b72676145338", + "name": "John Doe", + "email": "john@doe.com", + "userId": "No response", + "deleted": false, + "groups": { + "group1": "grooupId" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe" + } + }, + "device": { + "os": "macOS", + "type": "desktop" + }, + "location": { + "country": "IN", + "countryName": "India", + "region": "", + "city": "", + "short": "India", + "long": "India" + }, + "referrer": "http://127.0.0.1:5500/testSm.html", + "method": "In-app", + "language": "en", + "project": "6372247a764986ebee62bf66", + "campaign": "6373271b764986ebee62bfca" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe" + }, + "campaign": { + "id": "6373271b764986ebee62bfca", + "name": "NPS Survey" + }, + "event": "completed" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "event": "Survey completed", + "anonymousId": "63766fbb7ac7b72676145338", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe", + "userDeleted": false + }, + "locale": "en", + "campaign": { + "id": "6373271b764986ebee62bfca", + "name": "NPS Survey" + }, + "integration": { + "name": "SATISMETER" + }, + "location": { + "country": "IN", + "countryName": "India", + "short": "India", + "long": "India" + }, + "device": { + "os": "macOS", + "type": "desktop" + }, + "page": { + "referrer": "http://127.0.0.1:5500/testSm.html" + } + }, + "integrations": { + "SATISMETER": false + }, + "type": "track", + "traits": { + "groups": { + "group1": "grooupId" + } + }, + "userId": "No response", + "properties": { + "category": "detractor", + "answers": [ + { + "label": "How likely are you to recommend us to your friends and colleagues?", + "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", + "value": 5, + "name": "SM_rating", + "type": "scale", + "metric": "nps" + }, + { + "label": "What could we do to improve?", + "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", + "value": "Many things to imporve\n", + "name": "SM_comment", + "type": "long-text" + }, + { + "label": "The company made it easy for me to handle my issue.", + "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "scale", + "metric": "ces" + }, + { + "label": "How satisfied were you with the service you received?", + "id": "24c5b290-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "smiley", + "metric": "csat" + }, + { + "label": "How you like to rate the surevy?", + "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", + "value": 4, + "type": "scale" + }, + { + "label": "Your Name (Single Answer)", + "id": "37a8c000-66a0-11ed-856c-6f39711bf041", + "value": "a", + "type": "single-choice" + }, + { + "label": "Your Name (Multiple Answer)", + "id": "4b435da0-66a0-11ed-856c-6f39711bf041", + "value": ["a1", "b1"], + "type": "multiple-choice" + } + ], + "surveyDismissed": false, + "surveyPending": false, + "receivedAt": "2022-11-17T17:51:21.764Z" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/satismeter/neither_reponse_user_id_or_response_user_user_id_is_provided_in_payload_then_mapping_response_id_to_anonymous_id.json b/go/webhook/testcases/testdata/testcases/satismeter/neither_reponse_user_id_or_response_user_user_id_is_provided_in_payload_then_mapping_response_id_to_anonymous_id.json new file mode 100644 index 0000000000..9906523298 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/satismeter/neither_reponse_user_id_or_response_user_user_id_is_provided_in_payload_then_mapping_response_id_to_anonymous_id.json @@ -0,0 +1,241 @@ +{ + "name": "satismeter", + "description": " Neither reponse.user.id or response.user.userId is provided in payload then mapping response.id to anonymousId", + "input": { + "request": { + "body": { + "response": { + "id": "63767499ca6fb1b7c988d5bb", + "created": "2022-11-17T17:51:21.764Z", + "rating": 5, + "feedback": "Many things to imporve\n", + "dismissed": false, + "pending": false, + "answers": [ + { + "label": "How likely are you to recommend us to your friends and colleagues?", + "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", + "value": 5, + "name": "SM_rating", + "type": "scale", + "metric": "nps" + }, + { + "label": "What could we do to improve?", + "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", + "value": "Many things to imporve\n", + "name": "SM_comment", + "type": "long-text" + }, + { + "label": "The company made it easy for me to handle my issue.", + "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "scale", + "metric": "ces" + }, + { + "label": "How satisfied were you with the service you received?", + "id": "24c5b290-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "smiley", + "metric": "csat" + }, + { + "label": "How you like to rate the surevy?", + "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", + "value": 4, + "type": "scale" + }, + { + "label": "Your Name (Single Answer)", + "id": "37a8c000-66a0-11ed-856c-6f39711bf041", + "value": "a", + "type": "single-choice" + }, + { + "label": "Your Name (Multiple Answer)", + "id": "4b435da0-66a0-11ed-856c-6f39711bf041", + "value": ["a1", "b1"], + "type": "multiple-choice" + } + ], + "category": "detractor", + "score": -100, + "user": { + "name": "John Doe", + "email": "john@doe.com", + "deleted": false, + "groups": { + "group1": "grooupId" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe" + } + }, + "device": { + "os": "macOS", + "type": "desktop" + }, + "location": { + "country": "IN", + "countryName": "India", + "region": "", + "city": "", + "short": "India", + "long": "India" + }, + "referrer": "http://127.0.0.1:5500/testSm.html", + "method": "In-app", + "language": "en", + "project": "6372247a764986ebee62bf66", + "campaign": "6373271b764986ebee62bfca" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe" + }, + "campaign": { + "id": "6373271b764986ebee62bfca", + "name": "NPS Survey" + }, + "event": "completed" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "event": "Survey completed", + "anonymousId": "63767499ca6fb1b7c988d5bb", + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "traits": { + "createdAt": "2022-10-15T05:41:06.016Z", + "custom": { + "key1": "v1", + "key2": "V2" + }, + "email": "john@doe.com", + "name": "John Doe", + "userDeleted": false + }, + "locale": "en", + "campaign": { + "id": "6373271b764986ebee62bfca", + "name": "NPS Survey" + }, + "integration": { + "name": "SATISMETER" + }, + "location": { + "country": "IN", + "countryName": "India", + "short": "India", + "long": "India" + }, + "device": { + "os": "macOS", + "type": "desktop" + }, + "page": { + "referrer": "http://127.0.0.1:5500/testSm.html" + } + }, + "integrations": { + "SATISMETER": false + }, + "type": "track", + "traits": { + "groups": { + "group1": "grooupId" + } + }, + "properties": { + "category": "detractor", + "answers": [ + { + "label": "How likely are you to recommend us to your friends and colleagues?", + "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", + "value": 5, + "name": "SM_rating", + "type": "scale", + "metric": "nps" + }, + { + "label": "What could we do to improve?", + "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", + "value": "Many things to imporve\n", + "name": "SM_comment", + "type": "long-text" + }, + { + "label": "The company made it easy for me to handle my issue.", + "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "scale", + "metric": "ces" + }, + { + "label": "How satisfied were you with the service you received?", + "id": "24c5b290-66a0-11ed-856c-6f39711bf041", + "value": 4, + "name": null, + "type": "smiley", + "metric": "csat" + }, + { + "label": "How you like to rate the surevy?", + "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", + "value": 4, + "type": "scale" + }, + { + "label": "Your Name (Single Answer)", + "id": "37a8c000-66a0-11ed-856c-6f39711bf041", + "value": "a", + "type": "single-choice" + }, + { + "label": "Your Name (Multiple Answer)", + "id": "4b435da0-66a0-11ed-856c-6f39711bf041", + "value": ["a1", "b1"], + "type": "multiple-choice" + } + ], + "surveyDismissed": false, + "surveyPending": false, + "receivedAt": "2022-11-17T17:51:21.764Z" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/segment/test_0.json b/go/webhook/testcases/testdata/testcases/segment/test_0.json new file mode 100644 index 0000000000..868300e20e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/segment/test_0.json @@ -0,0 +1,251 @@ +{ + "name": "segment", + "description": "test-0", + "input": { + "request": { + "body": [ + { + "date": "2020-07-10T07:43:07.766Z", + "type": "s", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", + "details": { + "prompts": [], + "completedAt": 1594366987765, + "elapsedTime": null, + "session_id": "**************_***************" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": true + }, + { + "date": "2020-07-10T07:43:09.620Z", + "type": "seacft", + "description": "", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "okhttp 2.7.5 / Other 0.0.0", + "details": { + "code": "*************Xst" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": false + }, + { + "date": "2020-07-10T07:43:07.766Z", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", + "details": { + "prompts": [], + "completedAt": 1594366987765, + "elapsedTime": null, + "session_id": "**************_***************" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": true + }, + { + "type": "s", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", + "details": { + "prompts": [], + "completedAt": 1594366987765, + "elapsedTime": null, + "session_id": "**************_***************" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": true + } + ], + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "date": "2020-07-10T07:43:07.766Z", + "type": "s", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", + "details": { + "prompts": [], + "completedAt": 1594366987765, + "elapsedTime": null, + "session_id": "**************_***************" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": true, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "date": "2020-07-10T07:43:09.620Z", + "type": "seacft", + "description": "", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "okhttp 2.7.5 / Other 0.0.0", + "details": { + "code": "*************Xst" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": false, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "date": "2020-07-10T07:43:07.766Z", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", + "details": { + "prompts": [], + "completedAt": 1594366987765, + "elapsedTime": null, + "session_id": "**************_***************" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": true, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + }, + { + "type": "s", + "connection_id": "", + "client_id": "********************************", + "client_name": "My App", + "ip": "47.15.6.58", + "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", + "details": { + "prompts": [], + "completedAt": 1594366987765, + "elapsedTime": null, + "session_id": "**************_***************" + }, + "hostname": "************.us.auth0.com", + "user_id": "auth0|************************", + "user_name": "example@test.com", + "auth0_client": { + "name": "Auth0.Android", + "env": { + "android": "28" + }, + "version": "1.23.0" + }, + "log_id": "********************************************************", + "_id": "********************************************************", + "isMobile": true, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + }, + "skip": "NoAnonID error" +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/identify_call_for_customers_create_event.json b/go/webhook/testcases/testdata/testcases/shopify/identify_call_for_customers_create_event.json new file mode 100644 index 0000000000..821748094e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/identify_call_for_customers_create_event.json @@ -0,0 +1,181 @@ +{ + "name": "shopify", + "description": "Identify Call for customers create event", + "input": { + "request": { + "body": { + "query_parameters": { + "topic": ["customers_create"], + "signature": ["rudderstack"], + "writeKey": ["sample-write-key"] + }, + "id": 5747017285820, + "email": "anuraj@rudderstack.com", + "accepts_marketing": false, + "created_at": "2021-12-29T15:15:19+05:30", + "updated_at": "2021-12-29T15:15:20+05:30", + "first_name": "Anuraj", + "last_name": "Guha", + "orders_count": 0, + "state": "disabled", + "total_spent": "0.00", + "last_order_id": null, + "note": "", + "verified_email": true, + "multipass_identifier": null, + "tax_exempt": false, + "phone": "+919876543210", + "tags": "", + "last_order_name": null, + "currency": "INR", + "addresses": [ + { + "id": 6947581821116, + "customer_id": 5747017285820, + "first_name": "Anuraj", + "last_name": "Guha", + "company": "Rudderstack", + "address1": "Home", + "address2": "Apartment", + "city": "Kolkata", + "province": "West Bengal", + "country": "India", + "zip": "708091", + "phone": "+919876543210", + "name": "Anuraj Guha", + "province_code": "WB", + "country_code": "IN", + "country_name": "India", + "default": true + } + ], + "accepts_marketing_updated_at": "2021-12-29T15:15:20+05:30", + "marketing_opt_in_level": null, + "tax_exemptions": [], + "sms_marketing_consent": { + "state": "not_subscribed", + "opt_in_level": "single_opt_in", + "consent_updated_at": null, + "consent_collected_from": "SHOPIFY" + }, + "admin_graphql_api_id": "gid://shopify/Customer/5747017285820", + "default_address": { + "id": 6947581821116, + "customer_id": 5747017285820, + "first_name": "Anuraj", + "last_name": "Guha", + "company": "Rudderstack", + "address1": "Home", + "address2": "Apartment", + "city": "Kolkata", + "province": "West Bengal", + "country": "India", + "zip": "708091", + "phone": "+919876543210", + "name": "Anuraj Guha", + "province_code": "WB", + "country_code": "IN", + "country_name": "India", + "default": true + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "RudderStack Shopify Cloud", + "version": "1.0.0" + }, + "integration": { + "name": "SHOPIFY" + }, + "topic": "customers_create" + }, + "integrations": { + "SHOPIFY": true + }, + "type": "identify", + "userId": "5747017285820", + "traits": { + "email": "anuraj@rudderstack.com", + "firstName": "Anuraj", + "lastName": "Guha", + "phone": "+919876543210", + "addressList": [ + { + "id": 6947581821116, + "customer_id": 5747017285820, + "first_name": "Anuraj", + "last_name": "Guha", + "company": "Rudderstack", + "address1": "Home", + "address2": "Apartment", + "city": "Kolkata", + "province": "West Bengal", + "country": "India", + "zip": "708091", + "phone": "+919876543210", + "name": "Anuraj Guha", + "province_code": "WB", + "country_code": "IN", + "country_name": "India", + "default": true + } + ], + "address": { + "id": 6947581821116, + "customer_id": 5747017285820, + "first_name": "Anuraj", + "last_name": "Guha", + "company": "Rudderstack", + "address1": "Home", + "address2": "Apartment", + "city": "Kolkata", + "province": "West Bengal", + "country": "India", + "zip": "708091", + "phone": "+919876543210", + "name": "Anuraj Guha", + "province_code": "WB", + "country_code": "IN", + "country_name": "India", + "default": true + }, + "acceptsMarketing": false, + "orderCount": 0, + "state": "disabled", + "totalSpent": "0.00", + "note": "", + "verifiedEmail": true, + "taxExempt": false, + "tags": "", + "currency": "INR", + "taxExemptions": [], + "smsMarketingConsent": { + "state": "not_subscribed", + "opt_in_level": "single_opt_in", + "consent_updated_at": null, + "consent_collected_from": "SHOPIFY" + }, + "adminGraphqlApiId": "gid://shopify/Customer/5747017285820", + "acceptsMarketingUpdatedAt": "2021-12-29T15:15:20+05:30" + }, + "timestamp": "2021-12-29T09:45:20.000Z", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/invalid_topic.json b/go/webhook/testcases/testdata/testcases/shopify/invalid_topic.json new file mode 100644 index 0000000000..8439ce36e0 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/invalid_topic.json @@ -0,0 +1,32 @@ +{ + "name": "shopify", + "description": "Invalid topic", + "input": { + "request": { + "body": { + "query_parameters": { + "signature": ["rudderstack"], + "writeKey": ["sample-write-key"] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Invalid topic in query_parameters\n" + }, + "queue": [], + "errQueue": [ + { + "query_parameters": { + "signature": ["rudderstack"], + "writeKey": ["sample-write-key"] + } + } + ] + } +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/no_query_parameters.json b/go/webhook/testcases/testdata/testcases/shopify/no_query_parameters.json new file mode 100644 index 0000000000..1c69d854fd --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/no_query_parameters.json @@ -0,0 +1,21 @@ +{ + "name": "shopify", + "description": "No Query Parameters", + "input": { + "request": { + "body": {}, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Query_parameters is missing\n" + }, + "queue": [], + "errQueue": [{}] + }, + "skip": "not possible" +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/topic_not_found.json b/go/webhook/testcases/testdata/testcases/shopify/topic_not_found.json new file mode 100644 index 0000000000..5b97996d17 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/topic_not_found.json @@ -0,0 +1,35 @@ +{ + "name": "shopify", + "description": "Topic Not found", + "input": { + "request": { + "body": { + "query_parameters": { + "topic": [], + "signature": ["rudderstack"], + "writeKey": ["sample-write-key"] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 400, + "body": "Topic not found\n" + }, + "queue": [], + "errQueue": [ + { + "query_parameters": { + "topic": [], + "signature": ["rudderstack"], + "writeKey": ["sample-write-key"] + } + } + ] + }, + "skip": "not possible" +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/track_call____carts_create_.json b/go/webhook/testcases/testdata/testcases/shopify/track_call____carts_create_.json new file mode 100644 index 0000000000..4c7237db1b --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/track_call____carts_create_.json @@ -0,0 +1,30 @@ +{ + "name": "shopify", + "description": "Track Call -> carts_create ", + "input": { + "request": { + "body": { + "id": "shopify_test3", + "query_parameters": { + "topic": ["carts_create"] + }, + "token": "shopify_test3", + "line_items": [], + "note": null, + "updated_at": "2023-02-10T12:16:07.251Z", + "created_at": "2023-02-10T12:05:04.402Z" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/track_call____fullfillments_updated_event.json b/go/webhook/testcases/testdata/testcases/shopify/track_call____fullfillments_updated_event.json new file mode 100644 index 0000000000..81fb98322e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/track_call____fullfillments_updated_event.json @@ -0,0 +1,257 @@ +{ + "name": "shopify", + "description": "Track Call -> Fullfillments updated event", + "input": { + "request": { + "body": { + "query_parameters": { + "topic": ["fulfillments_update"], + "writeKey": ["sample-write-key"], + "signature": ["rudderstack"] + }, + "shipping_address": { + "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" + }, + "billing_address": { + "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" + }, + "admin_graphql_api_id": "gid://shopify/Fulfillment/4124667937024", + "created_at": "2022-01-05T18:13:02+05:30", + "destination": null, + "email": "test_person@email.com", + "id": 4124667937024, + "line_items": [ + { + "admin_graphql_api_id": "gid://shopify/LineItem/11896203149568", + "discount_allocations": [], + "duties": [], + "fulfillable_quantity": 0, + "fulfillment_service": "manual", + "fulfillment_status": "fulfilled", + "gift_card": false, + "grams": 0, + "id": 11896203149568, + "name": "p1", + "origin_location": { + "address1": "74 CC/7, Anupama Housing Estate - II", + "address2": "", + "city": "Kolkatta", + "country_code": "IN", + "id": 3373642219776, + "name": "74 CC/7, Anupama Housing Estate - II", + "province_code": "WB", + "zip": "700052" + }, + "price": "5000.00", + "price_set": { + "presentment_money": { + "amount": "5000.00", + "currency_code": "INR" + }, + "shop_money": { + "amount": "5000.00", + "currency_code": "INR" + } + }, + "product_exists": true, + "product_id": 7510929801472, + "properties": [], + "quantity": 1, + "requires_shipping": true, + "sku": "15", + "tax_lines": [ + { + "channel_liable": false, + "price": "900.00", + "price_set": { + "presentment_money": { + "amount": "900.00", + "currency_code": "INR" + }, + "shop_money": { + "amount": "900.00", + "currency_code": "INR" + } + }, + "rate": 0.18, + "title": "IGST" + } + ], + "taxable": true, + "title": "p1", + "total_discount": "0.00", + "total_discount_set": { + "presentment_money": { + "amount": "0.00", + "currency_code": "INR" + }, + "shop_money": { + "amount": "0.00", + "currency_code": "INR" + } + }, + "variant_id": 42211160228096, + "variant_inventory_management": "shopify", + "variant_title": "", + "vendor": "rudderstack-store" + } + ], + "location_id": 66855371008, + "name": "#1002.1", + "order_id": 4617255092480, + "origin_address": null, + "receipt": {}, + "service": "manual", + "shipment_status": null, + "status": "success", + "tracking_company": "Amazon Logistics UK", + "tracking_number": "Sample001test", + "tracking_numbers": ["Sample001test"], + "tracking_url": "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530", + "tracking_urls": [ + "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530" + ], + "updated_at": "2022-01-05T18:16:48+05:30" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "RudderStack Shopify Cloud", + "version": "1.0.0" + }, + "integration": { + "name": "SHOPIFY" + }, + "topic": "fulfillments_update" + }, + "integrations": { + "SHOPIFY": true + }, + "type": "track", + "userId": "shopify-admin", + "event": "Fulfillments Update", + "properties": { + "admin_graphql_api_id": "gid://shopify/Fulfillment/4124667937024", + "created_at": "2022-01-05T18:13:02+05:30", + "destination": null, + "email": "test_person@email.com", + "id": 4124667937024, + "location_id": 66855371008, + "name": "#1002.1", + "order_id": 4617255092480, + "origin_address": null, + "receipt": {}, + "service": "manual", + "shipment_status": null, + "status": "success", + "tracking_company": "Amazon Logistics UK", + "tracking_number": "Sample001test", + "tracking_numbers": ["Sample001test"], + "tracking_url": "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530", + "tracking_urls": [ + "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530" + ], + "updated_at": "2022-01-05T18:16:48+05:30", + "products": [ + { + "product_id": 7510929801472, + "sku": "15", + "title": "p1", + "price": "5000.00", + "brand": "rudderstack-store", + "quantity": 1, + "admin_graphql_api_id": "gid://shopify/LineItem/11896203149568", + "discount_allocations": [], + "duties": [], + "fulfillable_quantity": 0, + "fulfillment_service": "manual", + "fulfillment_status": "fulfilled", + "gift_card": false, + "grams": 0, + "id": 11896203149568, + "origin_location": { + "address1": "74 CC/7, Anupama Housing Estate - II", + "address2": "", + "city": "Kolkatta", + "country_code": "IN", + "id": 3373642219776, + "name": "74 CC/7, Anupama Housing Estate - II", + "province_code": "WB", + "zip": "700052" + }, + "price_set": { + "presentment_money": { + "amount": "5000.00", + "currency_code": "INR" + }, + "shop_money": { + "amount": "5000.00", + "currency_code": "INR" + } + }, + "product_exists": true, + "properties": [], + "requires_shipping": true, + "tax_lines": [ + { + "channel_liable": false, + "price": "900.00", + "price_set": { + "presentment_money": { + "amount": "900.00", + "currency_code": "INR" + }, + "shop_money": { + "amount": "900.00", + "currency_code": "INR" + } + }, + "rate": 0.18, + "title": "IGST" + } + ], + "taxable": true, + "total_discount": "0.00", + "total_discount_set": { + "presentment_money": { + "amount": "0.00", + "currency_code": "INR" + }, + "shop_money": { + "amount": "0.00", + "currency_code": "INR" + } + }, + "variant_inventory_management": "shopify", + "variant": "42211160228096 " + } + ] + }, + "traits": { + "shippingAddress": { + "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" + }, + "billingAddress": { + "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" + }, + "email": "test_person@email.com" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/unsupported_checkout_event.json b/go/webhook/testcases/testdata/testcases/shopify/unsupported_checkout_event.json new file mode 100644 index 0000000000..37ec9c03dc --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/unsupported_checkout_event.json @@ -0,0 +1,58 @@ +{ + "name": "shopify", + "description": "Unsupported checkout event", + "input": { + "request": { + "body": { + "query_parameters": { + "topic": ["checkout_delete"], + "writeKey": ["sample-write-key"], + "signature": ["rudderstack"] + }, + "admin_graphql_api_id": "gid://shopify/Fulfillment/4124667937024", + "created_at": "2022-01-05T18:13:02+05:30", + "destination": null, + "id": 4124667937024, + "line_items": [], + "customer": { + "email": "test_person@email.com", + "first_name": "Test", + "last_name": "Person" + }, + "billing_address": { + "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" + }, + "shipping_address": { + "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" + }, + "location_id": 66855371008, + "name": "#1002.1", + "order_id": 4617255092480, + "origin_address": null, + "receipt": {}, + "service": "manual", + "shipment_status": null, + "status": "success", + "tracking_company": "Amazon Logistics UK", + "tracking_number": "Sample001test", + "tracking_numbers": ["Sample001test"], + "tracking_url": "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530", + "tracking_urls": [ + "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530" + ], + "updated_at": "2022-01-05T18:16:48+05:30" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/shopify/unsupported_event_type.json b/go/webhook/testcases/testdata/testcases/shopify/unsupported_event_type.json new file mode 100644 index 0000000000..c2dfe7f584 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/shopify/unsupported_event_type.json @@ -0,0 +1,26 @@ +{ + "name": "shopify", + "description": "Unsupported Event Type", + "input": { + "request": { + "body": { + "query_parameters": { + "topic": ["random_event"], + "signature": ["rudderstack"], + "writeKey": ["sample-write-key"] + } + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_0.json b/go/webhook/testcases/testdata/testcases/signl4/test_0.json new file mode 100644 index 0000000000..aedf7026d3 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_0.json @@ -0,0 +1,63 @@ +{ + "name": "signl4", + "description": "test-0", + "input": { + "request": { + "body": { + "eventType": 200, + "eventRaisedUtc": "2017-09-01T08:11:37.4815663Z", + "subscription": { + "id": "0acf8014-22f2-4503-88d7-f7d05b46744f" + }, + "alert": { + "statusCode": 1, + "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "externalEventId": "INC091210", + "id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" + }, + "id": "dd209a2d-e037-41ee-b37d-f605cc0a39fb" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "dd209a2d-e037-41ee-b37d-f605cc0a39fb", + "originalTimestamp": "2017-09-01T08:11:37.000Z", + "event": "New Alert Created", + "properties": { + "eventType": 200, + "subscription.id": "0acf8014-22f2-4503-88d7-f7d05b46744f", + "alert.statusCode": 1, + "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "alert.externalEventId": "INC091210", + "alert.id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_1.json b/go/webhook/testcases/testdata/testcases/signl4/test_1.json new file mode 100644 index 0000000000..5959deb4e1 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_1.json @@ -0,0 +1,80 @@ +{ + "name": "signl4", + "description": "test-1", + "input": { + "request": { + "body": { + "eventType": 201, + "eventRaisedUtc": "2017-09-01T08:11:37.4815663Z", + "subscription": { + "id": "0acf8014-22f2-4503-88d7-f7d05b46744f" + }, + "user": { + "username": "Rene", + "mailaddress": "rene@signl4.com", + "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" + }, + "alert": { + "statusCode": 2, + "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "externalEventId": "Content you passed in the X-S4-ExternalID parameter", + "acknowledgedUserIds": ["f0bd5063-9588-51cf-b3d9-94e5647dedc5"], + "id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" + }, + "id": "dd209a2d-e037-41ee-b37d-f605cc0a39fb" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + }, + "externalId": [ + { + "type": "signl4UserId", + "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" + } + ], + "traits": { + "email": "rene@signl4.com", + "name": "Rene" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "dd209a2d-e037-41ee-b37d-f605cc0a39fb", + "originalTimestamp": "2017-09-01T08:11:37.000Z", + "event": "Alert Confirmed", + "properties": { + "eventType": 201, + "subscription.id": "0acf8014-22f2-4503-88d7-f7d05b46744f", + "alert.statusCode": 2, + "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "alert.externalEventId": "Content you passed in the X-S4-ExternalID parameter", + "alert.acknowledgedUserIds[0]": "f0bd5063-9588-51cf-b3d9-94e5647dedc5", + "alert.id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_2.json b/go/webhook/testcases/testdata/testcases/signl4/test_2.json new file mode 100644 index 0000000000..ac16f256e7 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_2.json @@ -0,0 +1,80 @@ +{ + "name": "signl4", + "description": "test-2", + "input": { + "request": { + "body": { + "eventType": 201, + "eventRaisedUtc": "2017-09-01T08:11:37.4815663Z", + "subscription": { + "id": "0acf8014-22f2-4503-88d7-f7d05b46744f" + }, + "user": { + "username": "Rene", + "mailaddress": "rene@signl4.com", + "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" + }, + "alert": { + "statusCode": 4, + "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "externalEventId": "Content you passed in the X-S4-ExternalID parameter", + "acknowledgedUserIds": ["f0bd5063-9588-51cf-b3d9-94e5647dedc5"], + "id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" + }, + "id": "dd209a2d-e037-41ee-b37d-f605cc0a39fb" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + }, + "externalId": [ + { + "type": "signl4UserId", + "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" + } + ], + "traits": { + "email": "rene@signl4.com", + "name": "Rene" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "dd209a2d-e037-41ee-b37d-f605cc0a39fb", + "originalTimestamp": "2017-09-01T08:11:37.000Z", + "event": "Alert Resolved", + "properties": { + "eventType": 201, + "subscription.id": "0acf8014-22f2-4503-88d7-f7d05b46744f", + "alert.statusCode": 4, + "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "alert.externalEventId": "Content you passed in the X-S4-ExternalID parameter", + "alert.acknowledgedUserIds[0]": "f0bd5063-9588-51cf-b3d9-94e5647dedc5", + "alert.id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_3.json b/go/webhook/testcases/testdata/testcases/signl4/test_3.json new file mode 100644 index 0000000000..e77d3ecf67 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_3.json @@ -0,0 +1,69 @@ +{ + "name": "signl4", + "description": "test-3", + "input": { + "request": { + "body": { + "eventType": 202, + "eventRaisedUtc": "2020-01-10T12:27:19Z", + "subscription": { + "id": "b8fdd850-e2ad-45ff-924d-9c332a063200" + }, + "team": { + "id": "0e8979f7-0c6a-472d-8918-ecfd339252f8" + }, + "alert": { + "statusCode": 1, + "eventId": "2518236416806594587_0e67b746-6c88-4ddf-8872-99690b0457d9", + "externalEventId": "INC091210", + "acknowledgedUserIds": [], + "id": "2518236416804564453_12ea0f6f-948c-43d0-9034-f9565d7b6bd2" + }, + "id": "27283793-47c8-4da2-9767-d37be224338d" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "27283793-47c8-4da2-9767-d37be224338d", + "originalTimestamp": "2020-01-10T12:27:19.000Z", + "event": "Alert Escalated", + "properties": { + "eventType": 202, + "subscription.id": "b8fdd850-e2ad-45ff-924d-9c332a063200", + "team.id": "0e8979f7-0c6a-472d-8918-ecfd339252f8", + "alert.statusCode": 1, + "alert.eventId": "2518236416806594587_0e67b746-6c88-4ddf-8872-99690b0457d9", + "alert.externalEventId": "INC091210", + "alert.id": "2518236416804564453_12ea0f6f-948c-43d0-9034-f9565d7b6bd2", + "alert.acknowledgedUserIds": [] + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_4.json b/go/webhook/testcases/testdata/testcases/signl4/test_4.json new file mode 100644 index 0000000000..47cde8a6e6 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_4.json @@ -0,0 +1,84 @@ +{ + "name": "signl4", + "description": "test-4", + "input": { + "request": { + "body": { + "eventType": 203, + "eventRaisedUtc": "2018-04-17T15:00:32Z", + "subscription": { + "id": "1578ebd9-0a27-44ab-bc8e-52cd7d32e81d" + }, + "user": { + "username": "Rene", + "mailaddress": "rene@signl4.com", + "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" + }, + "alert": { + "statusCode": 0, + "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "externalEventId": "Content you passed in the X-S4-ExternalID parameter", + "id": "2518783235958846071_4e2dfab2-4717-42bc-8d37-8682402309c2" + }, + "annotation": { + "message": "OK, I'll take care about it.", + "id": "2518783235661483318_99ebffe0-1b90-40ef-990a-fbd842484761" + }, + "id": "141c0f88-7831-4d5e-b055-f6e83c269770" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + }, + "externalId": [ + { + "type": "signl4UserId", + "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" + } + ], + "traits": { + "email": "rene@signl4.com", + "name": "Rene" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "141c0f88-7831-4d5e-b055-f6e83c269770", + "originalTimestamp": "2018-04-17T15:00:32.000Z", + "event": "Alert Annotated", + "properties": { + "eventType": 203, + "subscription.id": "1578ebd9-0a27-44ab-bc8e-52cd7d32e81d", + "alert.statusCode": 0, + "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", + "alert.externalEventId": "Content you passed in the X-S4-ExternalID parameter", + "alert.id": "2518783235958846071_4e2dfab2-4717-42bc-8d37-8682402309c2", + "annotation.message": "OK, I'll take care about it.", + "annotation.id": "2518783235661483318_99ebffe0-1b90-40ef-990a-fbd842484761" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_5.json b/go/webhook/testcases/testdata/testcases/signl4/test_5.json new file mode 100644 index 0000000000..af7bbd19b1 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_5.json @@ -0,0 +1,53 @@ +{ + "name": "signl4", + "description": "test-5", + "input": { + "request": { + "body": { + "eventType": 300, + "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", + "team": { + "id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", + "originalTimestamp": "2017-09-01T09:16:17.000Z", + "event": "Duty Period Started", + "properties": { + "eventType": 300, + "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_6.json b/go/webhook/testcases/testdata/testcases/signl4/test_6.json new file mode 100644 index 0000000000..21bf9c94e4 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_6.json @@ -0,0 +1,53 @@ +{ + "name": "signl4", + "description": "test-6", + "input": { + "request": { + "body": { + "eventType": 301, + "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", + "team": { + "id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + } + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", + "originalTimestamp": "2017-09-01T09:16:17.000Z", + "event": "Duty Period Ended", + "properties": { + "eventType": 301, + "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_7.json b/go/webhook/testcases/testdata/testcases/signl4/test_7.json new file mode 100644 index 0000000000..942da4b48e --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_7.json @@ -0,0 +1,62 @@ +{ + "name": "signl4", + "description": "test-7", + "input": { + "request": { + "body": { + "eventType": 302, + "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", + "team": { + "id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "user": { + "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" + }, + "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + }, + "externalId": [ + { + "type": "signl4UserId", + "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" + } + ] + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", + "originalTimestamp": "2017-09-01T09:16:17.000Z", + "event": "Somebody Punched-In", + "properties": { + "eventType": 302, + "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/signl4/test_8.json b/go/webhook/testcases/testdata/testcases/signl4/test_8.json new file mode 100644 index 0000000000..a746a28862 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/signl4/test_8.json @@ -0,0 +1,62 @@ +{ + "name": "signl4", + "description": "test-8", + "input": { + "request": { + "body": { + "eventType": 303, + "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", + "team": { + "id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "user": { + "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" + }, + "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "Signl4" + }, + "externalId": [ + { + "type": "signl4UserId", + "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" + } + ] + }, + "integrations": { + "Signl4": false + }, + "type": "track", + "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", + "originalTimestamp": "2017-09-01T09:16:17.000Z", + "event": "Somebody Punched-Out", + "properties": { + "eventType": 303, + "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" + }, + "anonymousId": "97fcd7b2-cc24-47d7-b776-057b7b199513", + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/slack/message_event.json b/go/webhook/testcases/testdata/testcases/slack/message_event.json new file mode 100644 index 0000000000..744170beec --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/slack/message_event.json @@ -0,0 +1,145 @@ +{ + "name": "slack", + "description": "Message event", + "input": { + "request": { + "body": { + "event": { + "user": "U04G7H550", + "type": "message", + "ts": "1709441309.308399", + "client_msg_id": "834r664e-ec75-445d-t5c6-b873a07y9c81", + "text": "What is the pricing of product X", + "team": "T0GFJL5J7", + "thread_ts": "1709407304.839329", + "parent_user_id": "U06P6LQTPV", + "blocks": [ + { + "type": "rich_text", + "block_id": "xGKJl", + "elements": [ + { + "type": "rich_text_section", + "elements": [ + { + "type": "text", + "text": "What is the pricing of product X" + }, + { + "type": "channel", + "channel_id": "C03CDQTPI65" + }, + { + "type": "text", + "text": " to do this" + } + ] + } + ] + } + ], + "channel": "C03CDQTPI65", + "event_ts": "1709441309.308399", + "channel_type": "channel" + }, + "type": "event_callback", + "event_id": "EvY5JTJ0NG5", + "event_time": 1709441309, + "token": "REm2987dqtpi72Lq", + "team_id": "T0GFJL5J7", + "context_team_id": "T01gqtPIL5J7", + "context_enterprise_id": null, + "api_app_id": "A04QTPIHRR", + "authorizations": [ + { + "enterprise_id": null, + "team_id": "T0GFJL5J7", + "user_id": "W012CDE", + "is_bot": true, + "is_enterprise_install": false + } + ], + "is_ext_shared_channel": false, + "event_context": "4-wd6joiQfdgTRQTpIzdfifQ" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "SLACK" + }, + "externalId": [ + { + "type": "slackUserId", + "id": "U04G7H550" + } + ] + }, + "integrations": { + "SLACK": false + }, + "type": "track", + "event": "Message", + "anonymousId": "7509c04f547b05afb6838aa742f4910263d6", + "originalTimestamp": "2024-03-03T04:48:29.308Z", + "sentAt": "2024-03-03T04:48:29.000Z", + "properties": { + "user": "U04G7H550", + "type": "message", + "ts": "1709441309.308399", + "client_msg_id": "834r664e-ec75-445d-t5c6-b873a07y9c81", + "text": "What is the pricing of product X", + "team": "T0GFJL5J7", + "thread_ts": "1709407304.839329", + "parent_user_id": "U06P6LQTPV", + "blocks": [ + { + "type": "rich_text", + "block_id": "xGKJl", + "elements": [ + { + "type": "rich_text_section", + "elements": [ + { + "type": "text", + "text": "What is the pricing of product X" + }, + { + "type": "channel", + "channel_id": "C03CDQTPI65" + }, + { + "type": "text", + "text": " to do this" + } + ] + } + ] + } + ], + "channel": "C03CDQTPI65", + "event_ts": "1709441309.308399", + "channel_type": "channel" + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/slack/team_joined_event.json b/go/webhook/testcases/testdata/testcases/slack/team_joined_event.json new file mode 100644 index 0000000000..8b0c547f69 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/slack/team_joined_event.json @@ -0,0 +1,85 @@ +{ + "name": "slack", + "description": "Team joined event", + "input": { + "request": { + "body": { + "event": { + "type": "team_join", + "user": { + "id": "W012CDE", + "name": "johnd", + "real_name": "John Doe" + } + }, + "type": "event_callback", + "event_id": "Ev06TJ0NG5", + "event_time": 1709441309, + "token": "REm276ggfh72Lq", + "team_id": "T0GFJL5J7", + "context_team_id": "T0GFJL5J7", + "context_enterprise_id": null, + "api_app_id": "B02SJMHRR", + "authorizations": [ + { + "enterprise_id": null, + "team_id": "T0GFJL5J7", + "user_id": "U04G7H550", + "is_bot": true, + "is_enterprise_install": false + } + ], + "is_ext_shared_channel": false, + "event_context": "eJldCI65436EUEpMSFhgfhg76joiQzAxRTRQTEIxMzUifQ" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": "OK" + }, + "queue": [ + { + "context": { + "library": { + "name": "unknown", + "version": "unknown" + }, + "integration": { + "name": "SLACK" + }, + "externalId": [ + { + "type": "slackUserId", + "id": "W012CDE" + } + ] + }, + "integrations": { + "SLACK": false + }, + "type": "identify", + "event": "Team Join", + "anonymousId": "2bc5ae2825a712d3d154cbdacb86ac16c278", + "originalTimestamp": "2024-03-03T04:48:29.000Z", + "sentAt": "2024-03-03T04:48:29.000Z", + "properties": { + "type": "team_join", + "user": { + "id": "W012CDE", + "name": "johnd", + "real_name": "John Doe" + } + }, + "receivedAt": "2024-03-03T04:48:29.000Z", + "request_ip": "192.0.2.30", + "messageId": "00000000-0000-0000-0000-000000000000" + } + ], + "errQueue": [] + } +} diff --git a/go/webhook/testcases/testdata/testcases/slack/webhook_url_verificatin_event.json b/go/webhook/testcases/testdata/testcases/slack/webhook_url_verificatin_event.json new file mode 100644 index 0000000000..0be33d2c58 --- /dev/null +++ b/go/webhook/testcases/testdata/testcases/slack/webhook_url_verificatin_event.json @@ -0,0 +1,26 @@ +{ + "name": "slack", + "description": "Webhook url verificatin event", + "input": { + "request": { + "body": { + "token": "Jhj5dZrVaK7ZwHHjRyZWjbDl", + "challenge": "3eZbrw1aB10FEMAGAZd4FyFQ", + "type": "url_verification" + }, + "headers": { + "Content-Type": "application/json" + } + } + }, + "output": { + "response": { + "status": 200, + "body": { + "challenge": "3eZbrw1aB10FEMAGAZd4FyFQ" + } + }, + "queue": [], + "errQueue": [] + } +} diff --git a/package-lock.json b/package-lock.json index 63d845c165..1ef33ae074 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,16 +1,16 @@ { "name": "rudder-transformer", - "version": "1.71.3", + "version": "1.76.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "rudder-transformer", - "version": "1.71.3", + "version": "1.76.1", "license": "ISC", "dependencies": { "@amplitude/ua-parser-js": "0.7.24", - "@aws-sdk/client-personalize": "^3.470.0", + "@aws-sdk/client-personalize": "^3.616.0", "@aws-sdk/client-s3": "^3.474.0", "@aws-sdk/credential-providers": "^3.391.0", "@aws-sdk/lib-storage": "^3.600.0", @@ -20,13 +20,13 @@ "@ndhoule/extend": "^2.0.0", "@pyroscope/nodejs": "^0.2.9", "@rudderstack/integrations-lib": "^0.2.10", - "@rudderstack/json-template-engine": "^0.17.1", - "@rudderstack/workflow-engine": "^0.8.12", + "@rudderstack/json-template-engine": "^0.18.0", + "@rudderstack/workflow-engine": "^0.8.13", "@shopify/jest-koa-mocks": "^5.1.1", "ajv": "^8.12.0", "ajv-draft-04": "^1.0.0", "ajv-formats": "^2.1.1", - "axios": "^1.6.4", + "axios": "^1.7.3", "btoa": "^1.2.1", "component-each": "^0.2.6", "crypto-js": "^4.2.0", @@ -45,6 +45,7 @@ "json-diff": "^1.0.3", "json-size": "^1.0.0", "jsontoxml": "^1.0.1", + "jstoxml": "^5.0.2", "koa": "^2.14.1", "koa-bodyparser": "^4.4.0", "koa2-swagger-ui": "^5.7.0", @@ -63,7 +64,6 @@ "prom-client": "^14.2.0", "qs": "^6.11.1", "rs-jsonpath": "^1.1.2", - "rudder-transformer-cdk": "^1.4.11", "set-value": "^4.1.0", "sha256": "^0.2.0", "sqlstring": "^2.3.3", @@ -105,7 +105,7 @@ "eslint-plugin-unicorn": "^46.0.1", "glob": "^10.3.3", "http-terminator": "^3.2.0", - "husky": "^8.0.3", + "husky": "^9.1.1", "jest": "^29.5.0", "jest-sonar": "^0.2.16", "jest-when": "^3.5.2", @@ -122,91 +122,24 @@ "typescript": "^5.0.4" } }, - "../jsonpath": { - "name": "rs-jsonpath", - "version": "1.1.2", - "extraneous": true, - "license": "MIT", - "dependencies": { - "esprima": "1.2.2", - "static-eval": "2.0.2", - "underscore": "1.12.1" - }, - "devDependencies": { - "grunt": "0.4.5", - "grunt-browserify": "3.8.0", - "grunt-cli": "0.1.13", - "grunt-contrib-uglify": "0.9.1", - "jison": "0.4.13", - "jscs": "1.10.0", - "jshint": "2.6.0", - "mocha": "2.1.0" - } - }, - "../rudder-integrations-lib": { - "name": "@rudderstack/integrations-lib", - "version": "0.2.9", - "extraneous": true, - "license": "MIT", - "dependencies": { - "axios": "^1.4.0", - "axios-mock-adapter": "^1.22.0", - "crypto": "^1.0.1", - "eslint-config-airbnb-base": "^15.0.0", - "eslint-config-airbnb-typescript": "^17.1.0", - "get-value": "^3.0.1", - "handlebars": "^4.7.8", - "lodash": "^4.17.21", - "moment": "^2.29.4", - "moment-timezone": "^0.5.43", - "set-value": "^4.1.0", - "sha256": "^0.2.0", - "tslib": "^2.4.0", - "winston": "^3.11.0" - }, - "devDependencies": { - "@commitlint/config-conventional": "^18.5.0", - "@types/get-value": "^3.0.3", - "@types/jest": "^29.5.4", - "@types/lodash": "^4.14.195", - "@types/node": "^20.3.3", - "@types/set-value": "^4.0.1", - "@types/sha256": "^0.2.0", - "@typescript-eslint/eslint-plugin": "^6.20.0", - "@typescript-eslint/parser": "^6.20.0", - "commitlint": "^18.6.0", - "eslint": "^8.56.0", - "eslint-config-prettier": "^9.1.0", - "husky": "^8.0.0", - "jest": "^29.4.3", - "pre-commit": "^1.2.2", - "prettier": "^2.8.4", - "ts-jest": "^29.0.5", - "ts-node": "^10.9.1", - "typescript": "^5.1.6" - } - }, "node_modules/@aashutoshrathi/word-wrap": { "version": "1.2.6", - "resolved": "https://registry.npmjs.org/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz", - "integrity": "sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/@amplitude/ua-parser-js": { "version": "0.7.24", - "resolved": "https://registry.npmjs.org/@amplitude/ua-parser-js/-/ua-parser-js-0.7.24.tgz", - "integrity": "sha512-VbQuJymJ20WEw0HtI2np7EdC3NJGUWi8+Xdbc7uk8WfMIF308T0howpzkQ3JFMN7ejnrcSM/OyNGveeE3TP3TA==", + "license": "MIT", "engines": { "node": "*" } }, "node_modules/@ampproject/remapping": { "version": "2.2.1", - "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.1.tgz", - "integrity": "sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==", "dev": true, + "license": "Apache-2.0", "dependencies": { "@jridgewell/gen-mapping": "^0.3.0", "@jridgewell/trace-mapping": "^0.3.9" @@ -217,9 +150,8 @@ }, "node_modules/@apidevtools/json-schema-ref-parser": { "version": "9.0.6", - "resolved": "https://registry.npmjs.org/@apidevtools/json-schema-ref-parser/-/json-schema-ref-parser-9.0.6.tgz", - "integrity": "sha512-M3YgsLjI0lZxvrpeGVk9Ap032W6TPQkH6pRAZz81Ac3WUNF79VQooAFnp8umjvVzUmD93NkogxEwbSce7qMsUg==", "dev": true, + "license": "MIT", "dependencies": { "@jsdevtools/ono": "^7.1.3", "call-me-maybe": "^1.0.1", @@ -228,18 +160,16 @@ }, "node_modules/@apidevtools/json-schema-ref-parser/node_modules/argparse": { "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, + "license": "MIT", "dependencies": { "sprintf-js": "~1.0.2" } }, "node_modules/@apidevtools/json-schema-ref-parser/node_modules/js-yaml": { "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", "dev": true, + "license": "MIT", "dependencies": { "argparse": "^1.0.7", "esprima": "^4.0.0" @@ -250,19 +180,16 @@ }, "node_modules/@apidevtools/openapi-schemas": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@apidevtools/openapi-schemas/-/openapi-schemas-2.1.0.tgz", - "integrity": "sha512-Zc1AlqrJlX3SlpupFGpiLi2EbteyP7fXmUOGup6/DnkRgjP9bgMM/ag+n91rsv0U1Gpz0H3VILA/o3bW7Ua6BQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" } }, "node_modules/@apidevtools/swagger-cli": { "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@apidevtools/swagger-cli/-/swagger-cli-4.0.4.tgz", - "integrity": "sha512-hdDT3B6GLVovCsRZYDi3+wMcB1HfetTU20l2DC8zD3iFRNMC6QNAZG5fo/6PYeHWBEv7ri4MvnlKodhNB0nt7g==", - "deprecated": "This package has been abandoned. Please switch to using the actively maintained @redocly/cli", "dev": true, + "license": "MIT", "dependencies": { "@apidevtools/swagger-parser": "^10.0.1", "chalk": "^4.1.0", @@ -278,9 +205,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -293,27 +219,24 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/argparse": { "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, + "license": "MIT", "dependencies": { "sprintf-js": "~1.0.2" } }, "node_modules/@apidevtools/swagger-cli/node_modules/camelcase": { "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/@apidevtools/swagger-cli/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -327,9 +250,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/cliui": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", - "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==", "dev": true, + "license": "ISC", "dependencies": { "string-width": "^4.2.0", "strip-ansi": "^6.0.0", @@ -338,9 +260,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -350,15 +271,13 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@apidevtools/swagger-cli/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -369,18 +288,16 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@apidevtools/swagger-cli/node_modules/js-yaml": { "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", "dev": true, + "license": "MIT", "dependencies": { "argparse": "^1.0.7", "esprima": "^4.0.0" @@ -391,9 +308,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -403,9 +319,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -418,9 +333,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -430,9 +344,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -442,9 +355,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/wrap-ansi": { "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", @@ -456,15 +368,13 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/y18n": { "version": "4.0.3", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", - "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/@apidevtools/swagger-cli/node_modules/yargs": { "version": "15.4.1", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", - "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==", "dev": true, + "license": "MIT", "dependencies": { "cliui": "^6.0.0", "decamelize": "^1.2.0", @@ -484,9 +394,8 @@ }, "node_modules/@apidevtools/swagger-cli/node_modules/yargs-parser": { "version": "18.1.3", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", - "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", "dev": true, + "license": "ISC", "dependencies": { "camelcase": "^5.0.0", "decamelize": "^1.2.0" @@ -497,15 +406,13 @@ }, "node_modules/@apidevtools/swagger-methods": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@apidevtools/swagger-methods/-/swagger-methods-3.0.2.tgz", - "integrity": "sha512-QAkD5kK2b1WfjDS/UQn/qQkbwF31uqRjPTrsCs5ZG9BQGAkjwvqGFjjPqAuzac/IYzpPtRzjCP1WrTuAIjMrXg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@apidevtools/swagger-parser": { "version": "10.1.0", - "resolved": "https://registry.npmjs.org/@apidevtools/swagger-parser/-/swagger-parser-10.1.0.tgz", - "integrity": "sha512-9Kt7EuS/7WbMAUv2gSziqjvxwDbFSg3Xeyfuj5laUODX8o/k/CpsAKiQ8W7/R88eXFTMbJYg6+7uAmOWNKmwnw==", "dev": true, + "license": "MIT", "dependencies": { "@apidevtools/json-schema-ref-parser": "9.0.6", "@apidevtools/openapi-schemas": "^2.1.0", @@ -520,59 +427,28 @@ } }, "node_modules/@aws-crypto/crc32": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/crc32/-/crc32-3.0.0.tgz", - "integrity": "sha512-IzSgsrxUcsrejQbPVilIKy16kAT52EwB6zSaI+M3xxIhKh5+aldEyvI+z6erM7TCLB2BJsFrtHjp6/4/sr+3dA==", - "dependencies": { - "@aws-crypto/util": "^3.0.0", - "@aws-sdk/types": "^3.222.0", - "tslib": "^1.11.1" - } - }, - "node_modules/@aws-crypto/crc32/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, - "node_modules/@aws-crypto/crc32c": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/crc32c/-/crc32c-5.2.0.tgz", - "integrity": "sha512-+iWb8qaHLYKrNvGRbiYRHSdKRWhto5XlZUEBwDjYNf+ly5SVYG6zEoYIdxvf5R3zyeP16w4PLBn3rH1xc74Rag==", "license": "Apache-2.0", "dependencies": { "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@aws-crypto/crc32c/node_modules/@aws-crypto/util": { + "node_modules/@aws-crypto/crc32c": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", - "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", "license": "Apache-2.0", "dependencies": { + "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", - "@smithy/util-utf8": "^2.0.0", "tslib": "^2.6.2" } }, - "node_modules/@aws-crypto/ie11-detection": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/ie11-detection/-/ie11-detection-3.0.0.tgz", - "integrity": "sha512-341lBBkiY1DfDNKai/wXM3aujNBkXR7tq1URPQDL9wi3AUbI80NR74uF1TXHMm7po1AcnFk8iu2S2IeU/+/A+Q==", - "dependencies": { - "tslib": "^1.11.1" - } - }, - "node_modules/@aws-crypto/ie11-detection/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/@aws-crypto/sha1-browser": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha1-browser/-/sha1-browser-5.2.0.tgz", - "integrity": "sha512-OH6lveCFfcDjX4dbAvCFSYUjJZjDr/3XJ3xHtjn3Oj5b9RjojQo8npoLeA/bNwkOkrSQ0wgrHzXk4tDRxGKJeg==", "license": "Apache-2.0", "dependencies": { "@aws-crypto/supports-web-crypto": "^5.2.0", @@ -583,472 +459,347 @@ "tslib": "^2.6.2" } }, - "node_modules/@aws-crypto/sha1-browser/node_modules/@aws-crypto/supports-web-crypto": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/supports-web-crypto/-/supports-web-crypto-5.2.0.tgz", - "integrity": "sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-crypto/sha1-browser/node_modules/@aws-crypto/util": { + "node_modules/@aws-crypto/sha256-browser": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", - "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", "license": "Apache-2.0", "dependencies": { + "@aws-crypto/sha256-js": "^5.2.0", + "@aws-crypto/supports-web-crypto": "^5.2.0", + "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", + "@aws-sdk/util-locate-window": "^3.0.0", "@smithy/util-utf8": "^2.0.0", "tslib": "^2.6.2" } }, - "node_modules/@aws-crypto/sha256-browser": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-browser/-/sha256-browser-3.0.0.tgz", - "integrity": "sha512-8VLmW2B+gjFbU5uMeqtQM6Nj0/F1bro80xQXCW6CQBWgosFWXTx77aeOF5CAIAmbOK64SdMBJdNr6J41yP5mvQ==", - "dependencies": { - "@aws-crypto/ie11-detection": "^3.0.0", - "@aws-crypto/sha256-js": "^3.0.0", - "@aws-crypto/supports-web-crypto": "^3.0.0", - "@aws-crypto/util": "^3.0.0", - "@aws-sdk/types": "^3.222.0", - "@aws-sdk/util-locate-window": "^3.0.0", - "@aws-sdk/util-utf8-browser": "^3.0.0", - "tslib": "^1.11.1" - } - }, - "node_modules/@aws-crypto/sha256-browser/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/@aws-crypto/sha256-js": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-js/-/sha256-js-3.0.0.tgz", - "integrity": "sha512-PnNN7os0+yd1XvXAy23CFOmTbMaDxgxXtTKHybrJ39Y8kGzBATgBFibWJKH6BhytLI/Zyszs87xCOBNyBig6vQ==", + "version": "5.2.0", + "license": "Apache-2.0", "dependencies": { - "@aws-crypto/util": "^3.0.0", + "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", - "tslib": "^1.11.1" + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@aws-crypto/sha256-js/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/@aws-crypto/supports-web-crypto": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/supports-web-crypto/-/supports-web-crypto-3.0.0.tgz", - "integrity": "sha512-06hBdMwUAb2WFTuGG73LSC0wfPu93xWwo5vL2et9eymgmu3Id5vFAHBbajVWiGhPO37qcsdCap/FqXvJGJWPIg==", + "version": "5.2.0", + "license": "Apache-2.0", "dependencies": { - "tslib": "^1.11.1" + "tslib": "^2.6.2" } }, - "node_modules/@aws-crypto/supports-web-crypto/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/@aws-crypto/util": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-3.0.0.tgz", - "integrity": "sha512-2OJlpeJpCR48CC8r+uKVChzs9Iungj9wkZrl8Z041DWEWvyIHILYKCPNzJghKsivj+S3mLo6BVc7mBNzdxA46w==", + "version": "5.2.0", + "license": "Apache-2.0", "dependencies": { "@aws-sdk/types": "^3.222.0", - "@aws-sdk/util-utf8-browser": "^3.0.0", - "tslib": "^1.11.1" + "@smithy/util-utf8": "^2.0.0", + "tslib": "^2.6.2" } }, - "node_modules/@aws-crypto/util/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/@aws-sdk/client-cognito-identity": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-cognito-identity/-/client-cognito-identity-3.485.0.tgz", - "integrity": "sha512-1SYhvRu/dNqQ5HcIgm7wIpyn1FsthbgG04o6QyVAnfOxmawFt4nqCEtNCwsmlX7o1ZCTYY+qNrozb7XZy+GKSQ==", - "dependencies": { - "@aws-crypto/sha256-browser": "3.0.0", - "@aws-crypto/sha256-js": "3.0.0", - "@aws-sdk/client-sts": "3.485.0", - "@aws-sdk/core": "3.485.0", - "@aws-sdk/credential-provider-node": "3.485.0", - "@aws-sdk/middleware-host-header": "3.485.0", - "@aws-sdk/middleware-logger": "3.485.0", - "@aws-sdk/middleware-recursion-detection": "3.485.0", - "@aws-sdk/middleware-signing": "3.485.0", - "@aws-sdk/middleware-user-agent": "3.485.0", - "@aws-sdk/region-config-resolver": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@aws-sdk/util-endpoints": "3.485.0", - "@aws-sdk/util-user-agent-browser": "3.485.0", - "@aws-sdk/util-user-agent-node": "3.485.0", - "@smithy/config-resolver": "^2.0.23", - "@smithy/core": "^1.2.2", - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/hash-node": "^2.0.18", - "@smithy/invalid-dependency": "^2.0.16", - "@smithy/middleware-content-length": "^2.0.18", - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-retry": "^2.0.26", - "@smithy/middleware-serde": "^2.0.16", - "@smithy/middleware-stack": "^2.0.10", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/protocol-http": "^3.0.12", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "@smithy/util-base64": "^2.0.1", - "@smithy/util-body-length-browser": "^2.0.1", - "@smithy/util-body-length-node": "^2.1.0", - "@smithy/util-defaults-mode-browser": "^2.0.24", - "@smithy/util-defaults-mode-node": "^2.0.32", - "@smithy/util-endpoints": "^1.0.8", - "@smithy/util-retry": "^2.0.9", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/client-personalize": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-personalize/-/client-personalize-3.485.0.tgz", - "integrity": "sha512-HWv+HAKtbfje8QH8jE3B+nvjDDsc8E7hhc16128lX4tc1M9sPfC2qfw4R2hZ9YZxAYSEWryRuOMcp8YQylwpzg==", - "dependencies": { - "@aws-crypto/sha256-browser": "3.0.0", - "@aws-crypto/sha256-js": "3.0.0", - "@aws-sdk/client-sts": "3.485.0", - "@aws-sdk/core": "3.485.0", - "@aws-sdk/credential-provider-node": "3.485.0", - "@aws-sdk/middleware-host-header": "3.485.0", - "@aws-sdk/middleware-logger": "3.485.0", - "@aws-sdk/middleware-recursion-detection": "3.485.0", - "@aws-sdk/middleware-signing": "3.485.0", - "@aws-sdk/middleware-user-agent": "3.485.0", - "@aws-sdk/region-config-resolver": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@aws-sdk/util-endpoints": "3.485.0", - "@aws-sdk/util-user-agent-browser": "3.485.0", - "@aws-sdk/util-user-agent-node": "3.485.0", - "@smithy/config-resolver": "^2.0.23", - "@smithy/core": "^1.2.2", - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/hash-node": "^2.0.18", - "@smithy/invalid-dependency": "^2.0.16", - "@smithy/middleware-content-length": "^2.0.18", - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-retry": "^2.0.26", - "@smithy/middleware-serde": "^2.0.16", - "@smithy/middleware-stack": "^2.0.10", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/protocol-http": "^3.0.12", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "@smithy/util-base64": "^2.0.1", - "@smithy/util-body-length-browser": "^2.0.1", - "@smithy/util-body-length-node": "^2.1.0", - "@smithy/util-defaults-mode-browser": "^2.0.24", - "@smithy/util-defaults-mode-node": "^2.0.32", - "@smithy/util-endpoints": "^1.0.8", - "@smithy/util-retry": "^2.0.9", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/client-s3": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-s3/-/client-s3-3.614.0.tgz", - "integrity": "sha512-9BlhfeBegvyjOqHtcr9kvrT80wiy7EVUiqYyTFiiDv/hJIcG88XHQCZdLU7658XBkQ7aFrr5b8rF2HRD1oroxw==", + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { - "@aws-crypto/sha1-browser": "5.2.0", "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/client-sso-oidc": "3.614.0", - "@aws-sdk/client-sts": "3.614.0", - "@aws-sdk/core": "3.614.0", - "@aws-sdk/credential-provider-node": "3.614.0", - "@aws-sdk/middleware-bucket-endpoint": "3.614.0", - "@aws-sdk/middleware-expect-continue": "3.609.0", - "@aws-sdk/middleware-flexible-checksums": "3.614.0", - "@aws-sdk/middleware-host-header": "3.609.0", - "@aws-sdk/middleware-location-constraint": "3.609.0", + "@aws-sdk/client-sso-oidc": "3.637.0", + "@aws-sdk/client-sts": "3.637.0", + "@aws-sdk/core": "3.635.0", + "@aws-sdk/credential-provider-node": "3.637.0", + "@aws-sdk/middleware-host-header": "3.620.0", "@aws-sdk/middleware-logger": "3.609.0", - "@aws-sdk/middleware-recursion-detection": "3.609.0", - "@aws-sdk/middleware-sdk-s3": "3.614.0", - "@aws-sdk/middleware-signing": "3.609.0", - "@aws-sdk/middleware-ssec": "3.609.0", - "@aws-sdk/middleware-user-agent": "3.614.0", + "@aws-sdk/middleware-recursion-detection": "3.620.0", + "@aws-sdk/middleware-user-agent": "3.637.0", "@aws-sdk/region-config-resolver": "3.614.0", - "@aws-sdk/signature-v4-multi-region": "3.614.0", "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-endpoints": "3.614.0", + "@aws-sdk/util-endpoints": "3.637.0", "@aws-sdk/util-user-agent-browser": "3.609.0", "@aws-sdk/util-user-agent-node": "3.614.0", - "@aws-sdk/xml-builder": "3.609.0", "@smithy/config-resolver": "^3.0.5", - "@smithy/core": "^2.2.6", - "@smithy/eventstream-serde-browser": "^3.0.4", - "@smithy/eventstream-serde-config-resolver": "^3.0.3", - "@smithy/eventstream-serde-node": "^3.0.4", - "@smithy/fetch-http-handler": "^3.2.1", - "@smithy/hash-blob-browser": "^3.1.2", + "@smithy/core": "^2.4.0", + "@smithy/fetch-http-handler": "^3.2.4", "@smithy/hash-node": "^3.0.3", - "@smithy/hash-stream-node": "^3.1.2", "@smithy/invalid-dependency": "^3.0.3", - "@smithy/md5-js": "^3.0.3", - "@smithy/middleware-content-length": "^3.0.3", - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-retry": "^3.0.9", + "@smithy/middleware-content-length": "^3.0.5", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", "@smithy/middleware-serde": "^3.0.3", "@smithy/middleware-stack": "^3.0.3", "@smithy/node-config-provider": "^3.1.4", - "@smithy/node-http-handler": "^3.1.2", - "@smithy/protocol-http": "^4.0.3", - "@smithy/smithy-client": "^3.1.7", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", "@smithy/url-parser": "^3.0.3", "@smithy/util-base64": "^3.0.0", "@smithy/util-body-length-browser": "^3.0.0", "@smithy/util-body-length-node": "^3.0.0", - "@smithy/util-defaults-mode-browser": "^3.0.9", - "@smithy/util-defaults-mode-node": "^3.0.9", + "@smithy/util-defaults-mode-browser": "^3.0.15", + "@smithy/util-defaults-mode-node": "^3.0.15", "@smithy/util-endpoints": "^2.0.5", + "@smithy/util-middleware": "^3.0.3", "@smithy/util-retry": "^3.0.3", - "@smithy/util-stream": "^3.0.6", "@smithy/util-utf8": "^3.0.0", - "@smithy/util-waiter": "^3.1.2", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/sha256-browser": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-browser/-/sha256-browser-5.2.0.tgz", - "integrity": "sha512-AXfN/lGotSQwu6HNcEsIASo7kWXZ5HYWvfOmSNKDsEqC4OashTp8alTmaz+F7TC2L083SFv5RdB+qU3Vs1kZqw==", - "license": "Apache-2.0", - "dependencies": { - "@aws-crypto/sha256-js": "^5.2.0", - "@aws-crypto/supports-web-crypto": "^5.2.0", - "@aws-crypto/util": "^5.2.0", - "@aws-sdk/types": "^3.222.0", - "@aws-sdk/util-locate-window": "^3.0.0", - "@smithy/util-utf8": "^2.0.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/is-array-buffer": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-2.2.0.tgz", - "integrity": "sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==", + "node_modules/@aws-sdk/client-cognito-identity/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/util-buffer-from": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-2.2.0.tgz", - "integrity": "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==", + "node_modules/@aws-sdk/client-cognito-identity/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/is-array-buffer": "^2.2.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/util-utf8": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-2.3.0.tgz", - "integrity": "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==", + "node_modules/@aws-sdk/client-cognito-identity/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/util-buffer-from": "^2.2.0", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/sha256-js": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-js/-/sha256-js-5.2.0.tgz", - "integrity": "sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA==", + "node_modules/@aws-sdk/client-personalize": { + "version": "3.642.0", "license": "Apache-2.0", "dependencies": { - "@aws-crypto/util": "^5.2.0", - "@aws-sdk/types": "^3.222.0", + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/client-sso-oidc": "3.637.0", + "@aws-sdk/client-sts": "3.637.0", + "@aws-sdk/core": "3.635.0", + "@aws-sdk/credential-provider-node": "3.637.0", + "@aws-sdk/middleware-host-header": "3.620.0", + "@aws-sdk/middleware-logger": "3.609.0", + "@aws-sdk/middleware-recursion-detection": "3.620.0", + "@aws-sdk/middleware-user-agent": "3.637.0", + "@aws-sdk/region-config-resolver": "3.614.0", + "@aws-sdk/types": "3.609.0", + "@aws-sdk/util-endpoints": "3.637.0", + "@aws-sdk/util-user-agent-browser": "3.609.0", + "@aws-sdk/util-user-agent-node": "3.614.0", + "@smithy/config-resolver": "^3.0.5", + "@smithy/core": "^2.4.0", + "@smithy/fetch-http-handler": "^3.2.4", + "@smithy/hash-node": "^3.0.3", + "@smithy/invalid-dependency": "^3.0.3", + "@smithy/middleware-content-length": "^3.0.5", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", + "@smithy/middleware-serde": "^3.0.3", + "@smithy/middleware-stack": "^3.0.3", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", + "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.15", + "@smithy/util-defaults-mode-node": "^3.0.15", + "@smithy/util-endpoints": "^2.0.5", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-retry": "^3.0.3", + "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/supports-web-crypto": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/supports-web-crypto/-/supports-web-crypto-5.2.0.tgz", - "integrity": "sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/util": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", - "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "^3.222.0", - "@smithy/util-utf8": "^2.0.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/util/node_modules/@smithy/is-array-buffer": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-2.2.0.tgz", - "integrity": "sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==", + "node_modules/@aws-sdk/client-personalize/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/util/node_modules/@smithy/util-buffer-from": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-2.2.0.tgz", - "integrity": "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==", + "node_modules/@aws-sdk/client-personalize/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/is-array-buffer": "^2.2.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-crypto/util/node_modules/@smithy/util-utf8": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-2.3.0.tgz", - "integrity": "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==", + "node_modules/@aws-sdk/client-personalize/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/util-buffer-from": "^2.2.0", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/client-sso": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso/-/client-sso-3.614.0.tgz", - "integrity": "sha512-p5pyYaxRzBttjBkqfc8i3K7DzBdTg3ECdVgBo6INIUxfvDy0J8QUE8vNtCgvFIkq+uPw/8M+Eo4zzln7anuO0Q==", + "node_modules/@aws-sdk/client-s3": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-crypto/sha1-browser": "5.2.0", "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.614.0", - "@aws-sdk/middleware-host-header": "3.609.0", + "@aws-sdk/client-sso-oidc": "3.637.0", + "@aws-sdk/client-sts": "3.637.0", + "@aws-sdk/core": "3.635.0", + "@aws-sdk/credential-provider-node": "3.637.0", + "@aws-sdk/middleware-bucket-endpoint": "3.620.0", + "@aws-sdk/middleware-expect-continue": "3.620.0", + "@aws-sdk/middleware-flexible-checksums": "3.620.0", + "@aws-sdk/middleware-host-header": "3.620.0", + "@aws-sdk/middleware-location-constraint": "3.609.0", "@aws-sdk/middleware-logger": "3.609.0", - "@aws-sdk/middleware-recursion-detection": "3.609.0", - "@aws-sdk/middleware-user-agent": "3.614.0", + "@aws-sdk/middleware-recursion-detection": "3.620.0", + "@aws-sdk/middleware-sdk-s3": "3.635.0", + "@aws-sdk/middleware-ssec": "3.609.0", + "@aws-sdk/middleware-user-agent": "3.637.0", "@aws-sdk/region-config-resolver": "3.614.0", + "@aws-sdk/signature-v4-multi-region": "3.635.0", "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-endpoints": "3.614.0", + "@aws-sdk/util-endpoints": "3.637.0", "@aws-sdk/util-user-agent-browser": "3.609.0", "@aws-sdk/util-user-agent-node": "3.614.0", + "@aws-sdk/xml-builder": "3.609.0", "@smithy/config-resolver": "^3.0.5", - "@smithy/core": "^2.2.6", - "@smithy/fetch-http-handler": "^3.2.1", + "@smithy/core": "^2.4.0", + "@smithy/eventstream-serde-browser": "^3.0.6", + "@smithy/eventstream-serde-config-resolver": "^3.0.3", + "@smithy/eventstream-serde-node": "^3.0.5", + "@smithy/fetch-http-handler": "^3.2.4", + "@smithy/hash-blob-browser": "^3.1.2", "@smithy/hash-node": "^3.0.3", + "@smithy/hash-stream-node": "^3.1.2", "@smithy/invalid-dependency": "^3.0.3", - "@smithy/middleware-content-length": "^3.0.3", - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-retry": "^3.0.9", + "@smithy/md5-js": "^3.0.3", + "@smithy/middleware-content-length": "^3.0.5", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", "@smithy/middleware-serde": "^3.0.3", "@smithy/middleware-stack": "^3.0.3", "@smithy/node-config-provider": "^3.1.4", - "@smithy/node-http-handler": "^3.1.2", - "@smithy/protocol-http": "^4.0.3", - "@smithy/smithy-client": "^3.1.7", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", "@smithy/url-parser": "^3.0.3", "@smithy/util-base64": "^3.0.0", "@smithy/util-body-length-browser": "^3.0.0", "@smithy/util-body-length-node": "^3.0.0", - "@smithy/util-defaults-mode-browser": "^3.0.9", - "@smithy/util-defaults-mode-node": "^3.0.9", + "@smithy/util-defaults-mode-browser": "^3.0.15", + "@smithy/util-defaults-mode-node": "^3.0.15", "@smithy/util-endpoints": "^2.0.5", "@smithy/util-middleware": "^3.0.3", "@smithy/util-retry": "^3.0.3", + "@smithy/util-stream": "^3.1.3", "@smithy/util-utf8": "^3.0.0", + "@smithy/util-waiter": "^3.1.2", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/client-sso-oidc": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso-oidc/-/client-sso-oidc-3.614.0.tgz", - "integrity": "sha512-BI1NWcpppbHg/28zbUg54dZeckork8BItZIcjls12vxasy+p3iEzrJVG60jcbUTTsk3Qc1tyxNfrdcVqx0y7Ww==", + "node_modules/@aws-sdk/client-s3/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-crypto/sha256-browser": "5.2.0", - "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.614.0", - "@aws-sdk/credential-provider-node": "3.614.0", - "@aws-sdk/middleware-host-header": "3.609.0", - "@aws-sdk/middleware-logger": "3.609.0", - "@aws-sdk/middleware-recursion-detection": "3.609.0", - "@aws-sdk/middleware-user-agent": "3.614.0", - "@aws-sdk/region-config-resolver": "3.614.0", - "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-endpoints": "3.614.0", - "@aws-sdk/util-user-agent-browser": "3.609.0", - "@aws-sdk/util-user-agent-node": "3.614.0", - "@smithy/config-resolver": "^3.0.5", - "@smithy/core": "^2.2.6", - "@smithy/fetch-http-handler": "^3.2.1", - "@smithy/hash-node": "^3.0.3", - "@smithy/invalid-dependency": "^3.0.3", - "@smithy/middleware-content-length": "^3.0.3", - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-retry": "^3.0.9", - "@smithy/middleware-serde": "^3.0.3", - "@smithy/middleware-stack": "^3.0.3", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/node-http-handler": "^3.1.2", - "@smithy/protocol-http": "^4.0.3", - "@smithy/smithy-client": "^3.1.7", - "@smithy/types": "^3.3.0", - "@smithy/url-parser": "^3.0.3", - "@smithy/util-base64": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", + "license": "Apache-2.0", + "dependencies": { + "@smithy/is-array-buffer": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-utf8": { + "version": "3.0.0", + "license": "Apache-2.0", + "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/client-sso": { + "version": "3.637.0", + "license": "Apache-2.0", + "dependencies": { + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/core": "3.635.0", + "@aws-sdk/middleware-host-header": "3.620.0", + "@aws-sdk/middleware-logger": "3.609.0", + "@aws-sdk/middleware-recursion-detection": "3.620.0", + "@aws-sdk/middleware-user-agent": "3.637.0", + "@aws-sdk/region-config-resolver": "3.614.0", + "@aws-sdk/types": "3.609.0", + "@aws-sdk/util-endpoints": "3.637.0", + "@aws-sdk/util-user-agent-browser": "3.609.0", + "@aws-sdk/util-user-agent-node": "3.614.0", + "@smithy/config-resolver": "^3.0.5", + "@smithy/core": "^2.4.0", + "@smithy/fetch-http-handler": "^3.2.4", + "@smithy/hash-node": "^3.0.3", + "@smithy/invalid-dependency": "^3.0.3", + "@smithy/middleware-content-length": "^3.0.5", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", + "@smithy/middleware-serde": "^3.0.3", + "@smithy/middleware-stack": "^3.0.3", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", + "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", + "@smithy/util-base64": "^3.0.0", "@smithy/util-body-length-browser": "^3.0.0", "@smithy/util-body-length-node": "^3.0.0", - "@smithy/util-defaults-mode-browser": "^3.0.9", - "@smithy/util-defaults-mode-node": "^3.0.9", + "@smithy/util-defaults-mode-browser": "^3.0.15", + "@smithy/util-defaults-mode-node": "^3.0.15", "@smithy/util-endpoints": "^2.0.5", "@smithy/util-middleware": "^3.0.3", "@smithy/util-retry": "^3.0.3", @@ -1057,52 +808,46 @@ }, "engines": { "node": ">=16.0.0" - }, - "peerDependencies": { - "@aws-sdk/client-sts": "^3.614.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/client-sts": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sts/-/client-sts-3.614.0.tgz", - "integrity": "sha512-i6QmaVA1KHHYNnI2VYQy/sc31rLm4+jSp8b/YbQpFnD0w3aXsrEEHHlxek45uSkHb4Nrj1omFBVy/xp1WVYx2Q==", + "node_modules/@aws-sdk/client-sso-oidc": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/client-sso-oidc": "3.614.0", - "@aws-sdk/core": "3.614.0", - "@aws-sdk/credential-provider-node": "3.614.0", - "@aws-sdk/middleware-host-header": "3.609.0", + "@aws-sdk/core": "3.635.0", + "@aws-sdk/credential-provider-node": "3.637.0", + "@aws-sdk/middleware-host-header": "3.620.0", "@aws-sdk/middleware-logger": "3.609.0", - "@aws-sdk/middleware-recursion-detection": "3.609.0", - "@aws-sdk/middleware-user-agent": "3.614.0", + "@aws-sdk/middleware-recursion-detection": "3.620.0", + "@aws-sdk/middleware-user-agent": "3.637.0", "@aws-sdk/region-config-resolver": "3.614.0", "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-endpoints": "3.614.0", + "@aws-sdk/util-endpoints": "3.637.0", "@aws-sdk/util-user-agent-browser": "3.609.0", "@aws-sdk/util-user-agent-node": "3.614.0", "@smithy/config-resolver": "^3.0.5", - "@smithy/core": "^2.2.6", - "@smithy/fetch-http-handler": "^3.2.1", + "@smithy/core": "^2.4.0", + "@smithy/fetch-http-handler": "^3.2.4", "@smithy/hash-node": "^3.0.3", "@smithy/invalid-dependency": "^3.0.3", - "@smithy/middleware-content-length": "^3.0.3", - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-retry": "^3.0.9", + "@smithy/middleware-content-length": "^3.0.5", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", "@smithy/middleware-serde": "^3.0.3", "@smithy/middleware-stack": "^3.0.3", "@smithy/node-config-provider": "^3.1.4", - "@smithy/node-http-handler": "^3.1.2", - "@smithy/protocol-http": "^4.0.3", - "@smithy/smithy-client": "^3.1.7", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", "@smithy/url-parser": "^3.0.3", "@smithy/util-base64": "^3.0.0", "@smithy/util-body-length-browser": "^3.0.0", "@smithy/util-body-length-node": "^3.0.0", - "@smithy/util-defaults-mode-browser": "^3.0.9", - "@smithy/util-defaults-mode-node": "^3.0.9", + "@smithy/util-defaults-mode-browser": "^3.0.15", + "@smithy/util-defaults-mode-node": "^3.0.15", "@smithy/util-endpoints": "^2.0.5", "@smithy/util-middleware": "^3.0.3", "@smithy/util-retry": "^3.0.3", @@ -1111,232 +856,195 @@ }, "engines": { "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-sts": "^3.637.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/core": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.614.0.tgz", - "integrity": "sha512-BUuS5/1YkgmKc4J0bg83XEtMyDHVyqG2QDzfmhYe8gbOIZabUl1FlrFVwhCAthtrrI6MPGTQcERB4BtJKUSplw==", + "node_modules/@aws-sdk/client-sso-oidc/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/core": "^2.2.6", - "@smithy/protocol-http": "^4.0.3", - "@smithy/signature-v4": "^3.1.2", - "@smithy/smithy-client": "^3.1.7", - "@smithy/types": "^3.3.0", - "fast-xml-parser": "4.2.5", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-env": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.609.0.tgz", - "integrity": "sha512-v69ZCWcec2iuV9vLVJMa6fAb5xwkzN4jYIT8yjo2c4Ia/j976Q+TPf35Pnz5My48Xr94EFcaBazrWedF+kwfuQ==", + "node_modules/@aws-sdk/client-sso-oidc/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/property-provider": "^3.1.3", - "@smithy/types": "^3.3.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-http": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.614.0.tgz", - "integrity": "sha512-YIEjlNUKb3Vo/iTnGAPdsiDC3FUUnNoex2OwU8LmR7AkYZiWdB8nx99DfgkkY+OFMUpw7nKD2PCOtuFONelfGA==", + "node_modules/@aws-sdk/client-sso-oidc/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/fetch-http-handler": "^3.2.1", - "@smithy/node-http-handler": "^3.1.2", - "@smithy/property-provider": "^3.1.3", - "@smithy/protocol-http": "^4.0.3", - "@smithy/smithy-client": "^3.1.7", - "@smithy/types": "^3.3.0", - "@smithy/util-stream": "^3.0.6", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-ini": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.614.0.tgz", - "integrity": "sha512-KfLuLFGwlvFSZ2MuzYwWGPb1y5TeiwX5okIDe0aQ1h10oD3924FXbN+mabOnUHQ8EFcGAtCaWbrC86mI7ktC6A==", + "node_modules/@aws-sdk/client-sso/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/credential-provider-env": "3.609.0", - "@aws-sdk/credential-provider-http": "3.614.0", - "@aws-sdk/credential-provider-process": "3.614.0", - "@aws-sdk/credential-provider-sso": "3.614.0", - "@aws-sdk/credential-provider-web-identity": "3.609.0", - "@aws-sdk/types": "3.609.0", - "@smithy/credential-provider-imds": "^3.1.4", - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" - }, - "peerDependencies": { - "@aws-sdk/client-sts": "^3.614.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-node": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.614.0.tgz", - "integrity": "sha512-4J6gPEuFZP0mkWq5E//oMS1vrmMM88iNNcv7TEljYnsc6JTAlKejCyFwx6CN+nkIhmIZsl06SXIhBemzBdBPfg==", + "node_modules/@aws-sdk/client-sso/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/credential-provider-env": "3.609.0", - "@aws-sdk/credential-provider-http": "3.614.0", - "@aws-sdk/credential-provider-ini": "3.614.0", - "@aws-sdk/credential-provider-process": "3.614.0", - "@aws-sdk/credential-provider-sso": "3.614.0", - "@aws-sdk/credential-provider-web-identity": "3.609.0", - "@aws-sdk/types": "3.609.0", - "@smithy/credential-provider-imds": "^3.1.4", - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-process": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.614.0.tgz", - "integrity": "sha512-Q0SI0sTRwi8iNODLs5+bbv8vgz8Qy2QdxbCHnPk/6Cx6LMf7i3dqmWquFbspqFRd8QiqxStrblwxrUYZi09tkA==", + "node_modules/@aws-sdk/client-sso/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-sso": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.614.0.tgz", - "integrity": "sha512-55+gp0JY4451cWI1qXmVMFM0GQaBKiQpXv2P0xmd9P3qLDyeFUSEW8XPh0d2lb1ICr6x4s47ynXVdGCIv2mXMg==", + "node_modules/@aws-sdk/client-sts": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/client-sso": "3.614.0", - "@aws-sdk/token-providers": "3.614.0", + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/client-sso-oidc": "3.637.0", + "@aws-sdk/core": "3.635.0", + "@aws-sdk/credential-provider-node": "3.637.0", + "@aws-sdk/middleware-host-header": "3.620.0", + "@aws-sdk/middleware-logger": "3.609.0", + "@aws-sdk/middleware-recursion-detection": "3.620.0", + "@aws-sdk/middleware-user-agent": "3.637.0", + "@aws-sdk/region-config-resolver": "3.614.0", "@aws-sdk/types": "3.609.0", - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", + "@aws-sdk/util-endpoints": "3.637.0", + "@aws-sdk/util-user-agent-browser": "3.609.0", + "@aws-sdk/util-user-agent-node": "3.614.0", + "@smithy/config-resolver": "^3.0.5", + "@smithy/core": "^2.4.0", + "@smithy/fetch-http-handler": "^3.2.4", + "@smithy/hash-node": "^3.0.3", + "@smithy/invalid-dependency": "^3.0.3", + "@smithy/middleware-content-length": "^3.0.5", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", + "@smithy/middleware-serde": "^3.0.3", + "@smithy/middleware-stack": "^3.0.3", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.15", + "@smithy/util-defaults-mode-node": "^3.0.15", + "@smithy/util-endpoints": "^2.0.5", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-retry": "^3.0.3", + "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/credential-provider-web-identity": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.609.0.tgz", - "integrity": "sha512-U+PG8NhlYYF45zbr1km3ROtBMYqyyj/oK8NRp++UHHeuavgrP+4wJ4wQnlEaKvJBjevfo3+dlIBcaeQ7NYejWg==", + "node_modules/@aws-sdk/client-sts/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/property-provider": "^3.1.3", - "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" - }, - "peerDependencies": { - "@aws-sdk/client-sts": "^3.609.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/middleware-host-header": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-host-header/-/middleware-host-header-3.609.0.tgz", - "integrity": "sha512-iTKfo158lc4jLDfYeZmYMIBHsn8m6zX+XB6birCSNZ/rrlzAkPbGE43CNdKfvjyWdqgLMRXF+B+OcZRvqhMXPQ==", + "node_modules/@aws-sdk/client-sts/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/protocol-http": "^4.0.3", - "@smithy/types": "^3.3.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/middleware-logger": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-logger/-/middleware-logger-3.609.0.tgz", - "integrity": "sha512-S62U2dy4jMDhDFDK5gZ4VxFdWzCtLzwbYyFZx2uvPYTECkepLUfzLic2BHg2Qvtu4QjX+oGE3P/7fwaGIsGNuQ==", + "node_modules/@aws-sdk/client-sts/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/types": "^3.3.0", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/middleware-recursion-detection": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-recursion-detection/-/middleware-recursion-detection-3.609.0.tgz", - "integrity": "sha512-6sewsYB7/o/nbUfA99Aa/LokM+a/u4Wpm/X2o0RxOsDtSB795ObebLJe2BxY5UssbGaWkn7LswyfvrdZNXNj1w==", + "node_modules/@aws-sdk/core": { + "version": "3.635.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/protocol-http": "^4.0.3", + "@smithy/core": "^2.4.0", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/property-provider": "^3.1.3", + "@smithy/protocol-http": "^4.1.0", + "@smithy/signature-v4": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", + "@smithy/util-middleware": "^3.0.3", + "fast-xml-parser": "4.4.1", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/middleware-signing": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-signing/-/middleware-signing-3.609.0.tgz", - "integrity": "sha512-2w3dBLjQVKIajYzokO4hduq8/0hSMUYHHmIo1Kdl+MSY8uwRBt12bLL6pyreobTcRMxizvn2ph/CQ9I1ST/WGQ==", + "node_modules/@aws-sdk/credential-provider-cognito-identity": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/client-cognito-identity": "3.637.0", "@aws-sdk/types": "3.609.0", "@smithy/property-provider": "^3.1.3", - "@smithy/protocol-http": "^4.0.3", - "@smithy/signature-v4": "^3.1.2", "@smithy/types": "^3.3.0", - "@smithy/util-middleware": "^3.0.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/middleware-user-agent": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-user-agent/-/middleware-user-agent-3.614.0.tgz", - "integrity": "sha512-xUxh0UPQiMTG6E31Yvu6zVYlikrIcFDKljM11CaatInzvZubGTGiX0DjpqRlfGzUNsuPc/zNrKwRP2+wypgqIw==", + "node_modules/@aws-sdk/credential-provider-env": { + "version": "3.620.1", "license": "Apache-2.0", "dependencies": { "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-endpoints": "3.614.0", - "@smithy/protocol-http": "^4.0.3", + "@smithy/property-provider": "^3.1.3", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1344,30 +1052,35 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/region-config-resolver": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/region-config-resolver/-/region-config-resolver-3.614.0.tgz", - "integrity": "sha512-vDCeMXvic/LU0KFIUjpC3RiSTIkkvESsEfbVHiHH0YINfl8HnEqR5rj+L8+phsCeVg2+LmYwYxd5NRz4PHxt5g==", + "node_modules/@aws-sdk/credential-provider-http": { + "version": "3.635.0", "license": "Apache-2.0", "dependencies": { "@aws-sdk/types": "3.609.0", - "@smithy/node-config-provider": "^3.1.4", + "@smithy/fetch-http-handler": "^3.2.4", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/property-provider": "^3.1.3", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", - "@smithy/util-config-provider": "^3.0.0", - "@smithy/util-middleware": "^3.0.3", + "@smithy/util-stream": "^3.1.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/token-providers": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.614.0.tgz", - "integrity": "sha512-okItqyY6L9IHdxqs+Z116y5/nda7rHxLvROxtAJdLavWTYDydxrZstImNgGWTeVdmc0xX2gJCI77UYUTQWnhRw==", + "node_modules/@aws-sdk/credential-provider-ini": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/credential-provider-env": "3.620.1", + "@aws-sdk/credential-provider-http": "3.635.0", + "@aws-sdk/credential-provider-process": "3.620.1", + "@aws-sdk/credential-provider-sso": "3.637.0", + "@aws-sdk/credential-provider-web-identity": "3.621.0", "@aws-sdk/types": "3.609.0", + "@smithy/credential-provider-imds": "^3.2.0", "@smithy/property-provider": "^3.1.3", "@smithy/shared-ini-file-loader": "^3.1.4", "@smithy/types": "^3.3.0", @@ -1377,15 +1090,23 @@ "node": ">=16.0.0" }, "peerDependencies": { - "@aws-sdk/client-sso-oidc": "^3.614.0" + "@aws-sdk/client-sts": "^3.637.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", + "node_modules/@aws-sdk/credential-provider-node": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/credential-provider-env": "3.620.1", + "@aws-sdk/credential-provider-http": "3.635.0", + "@aws-sdk/credential-provider-ini": "3.637.0", + "@aws-sdk/credential-provider-process": "3.620.1", + "@aws-sdk/credential-provider-sso": "3.637.0", + "@aws-sdk/credential-provider-web-identity": "3.621.0", + "@aws-sdk/types": "3.609.0", + "@smithy/credential-provider-imds": "^3.2.0", + "@smithy/property-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.4", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1393,41 +1114,42 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/util-endpoints": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-endpoints/-/util-endpoints-3.614.0.tgz", - "integrity": "sha512-wK2cdrXHH4oz4IomV/yrGkftU9A+ITB6nFL+rxxyO78is2ifHJpFdV4aqk4LSkXYPi6CXWNru/Dqc7yiKXgJPw==", + "node_modules/@aws-sdk/credential-provider-process": { + "version": "3.620.1", "license": "Apache-2.0", "dependencies": { "@aws-sdk/types": "3.609.0", + "@smithy/property-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.4", "@smithy/types": "^3.3.0", - "@smithy/util-endpoints": "^2.0.5", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/util-user-agent-browser": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-browser/-/util-user-agent-browser-3.609.0.tgz", - "integrity": "sha512-fojPU+mNahzQ0YHYBsx0ZIhmMA96H+ZIZ665ObU9tl+SGdbLneVZVikGve+NmHTQwHzwkFsZYYnVKAkreJLAtA==", + "node_modules/@aws-sdk/credential-provider-sso": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/client-sso": "3.637.0", + "@aws-sdk/token-providers": "3.614.0", "@aws-sdk/types": "3.609.0", + "@smithy/property-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.4", "@smithy/types": "^3.3.0", - "bowser": "^2.11.0", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@aws-sdk/util-user-agent-node": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-node/-/util-user-agent-node-3.614.0.tgz", - "integrity": "sha512-15ElZT88peoHnq5TEoEtZwoXTXRxNrk60TZNdpl/TUBJ5oNJ9Dqb5Z4ryb8ofN6nm9aFf59GVAerFDz8iUoHBA==", + "node_modules/@aws-sdk/credential-provider-web-identity": { + "version": "3.621.0", "license": "Apache-2.0", "dependencies": { "@aws-sdk/types": "3.609.0", - "@smithy/node-config-provider": "^3.1.4", + "@smithy/property-provider": "^3.1.3", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1435,20 +1157,27 @@ "node": ">=16.0.0" }, "peerDependencies": { - "aws-crt": ">=1.0.0" - }, - "peerDependenciesMeta": { - "aws-crt": { - "optional": true - } + "@aws-sdk/client-sts": "^3.621.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/abort-controller": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.1.tgz", - "integrity": "sha512-MBJBiidoe+0cTFhyxT8g+9g7CeVccLM0IOKKUMCNQ1CNMJ/eIfoo0RTfVrXOONEI1UCN1W+zkiHSbzUNE9dZtQ==", + "node_modules/@aws-sdk/credential-providers": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/client-cognito-identity": "3.637.0", + "@aws-sdk/client-sso": "3.637.0", + "@aws-sdk/client-sts": "3.637.0", + "@aws-sdk/credential-provider-cognito-identity": "3.637.0", + "@aws-sdk/credential-provider-env": "3.620.1", + "@aws-sdk/credential-provider-http": "3.635.0", + "@aws-sdk/credential-provider-ini": "3.637.0", + "@aws-sdk/credential-provider-node": "3.637.0", + "@aws-sdk/credential-provider-process": "3.620.1", + "@aws-sdk/credential-provider-sso": "3.637.0", + "@aws-sdk/credential-provider-web-identity": "3.621.0", + "@aws-sdk/types": "3.609.0", + "@smithy/credential-provider-imds": "^3.2.0", + "@smithy/property-provider": "^3.1.3", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1456,114 +1185,110 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/config-resolver": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@smithy/config-resolver/-/config-resolver-3.0.5.tgz", - "integrity": "sha512-SkW5LxfkSI1bUC74OtfBbdz+grQXYiPYolyu8VfpLIjEoN/sHVBlLeGXMQ1vX4ejkgfv6sxVbQJ32yF2cl1veA==", - "license": "Apache-2.0", + "node_modules/@aws-sdk/lib-storage": { + "version": "3.637.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/lib-storage/-/lib-storage-3.637.0.tgz", + "integrity": "sha512-HiNGOP4a1QrCWwO1joKw4mCp19nLXoF9K52PislBaYDI35IlHC3DP6MeOg5zmElwtL1GtEHFBy5olfPWPsLyLg==", "dependencies": { - "@smithy/node-config-provider": "^3.1.4", - "@smithy/types": "^3.3.0", - "@smithy/util-config-provider": "^3.0.0", - "@smithy/util-middleware": "^3.0.3", + "@smithy/abort-controller": "^3.1.1", + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/smithy-client": "^3.2.0", + "buffer": "5.6.0", + "events": "3.3.0", + "stream-browserify": "3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-s3": "^3.637.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/core": { - "version": "2.2.7", - "resolved": "https://registry.npmjs.org/@smithy/core/-/core-2.2.7.tgz", - "integrity": "sha512-Wwd9QWKaYdR+n/oIqJbuwSr9lHuv7sa1e3Zu4wIToZl0sS7xapTYYqQtXP1hKKtIWz0jl8AhvOfNwkfT5jjV0w==", + "node_modules/@aws-sdk/middleware-bucket-endpoint": { + "version": "3.620.0", "license": "Apache-2.0", "dependencies": { - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-retry": "^3.0.10", - "@smithy/middleware-serde": "^3.0.3", - "@smithy/protocol-http": "^4.0.4", - "@smithy/smithy-client": "^3.1.8", + "@aws-sdk/types": "3.609.0", + "@aws-sdk/util-arn-parser": "3.568.0", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", "@smithy/types": "^3.3.0", - "@smithy/util-middleware": "^3.0.3", + "@smithy/util-config-provider": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/credential-provider-imds": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/credential-provider-imds/-/credential-provider-imds-3.1.4.tgz", - "integrity": "sha512-NKyH01m97Xa5xf3pB2QOF3lnuE8RIK0hTVNU5zvZAwZU8uspYO4DHQVlK+Y5gwSrujTfHvbfd1D9UFJAc0iYKQ==", + "node_modules/@aws-sdk/middleware-expect-continue": { + "version": "3.620.0", "license": "Apache-2.0", "dependencies": { - "@smithy/node-config-provider": "^3.1.4", - "@smithy/property-provider": "^3.1.3", + "@aws-sdk/types": "3.609.0", + "@smithy/protocol-http": "^4.1.0", "@smithy/types": "^3.3.0", - "@smithy/url-parser": "^3.0.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/fetch-http-handler": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-3.2.2.tgz", - "integrity": "sha512-3LaWlBZObyGrOOd7e5MlacnAKEwFBmAeiW/TOj2eR9475Vnq30uS2510+tnKbxrGjROfNdOhQqGo5j3sqLT6bA==", + "node_modules/@aws-sdk/middleware-flexible-checksums": { + "version": "3.620.0", "license": "Apache-2.0", "dependencies": { - "@smithy/protocol-http": "^4.0.4", - "@smithy/querystring-builder": "^3.0.3", + "@aws-crypto/crc32": "5.2.0", + "@aws-crypto/crc32c": "5.2.0", + "@aws-sdk/types": "3.609.0", + "@smithy/is-array-buffer": "^3.0.0", + "@smithy/protocol-http": "^4.1.0", "@smithy/types": "^3.3.0", - "@smithy/util-base64": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/hash-node": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/hash-node/-/hash-node-3.0.3.tgz", - "integrity": "sha512-2ctBXpPMG+B3BtWSGNnKELJ7SH9e4TNefJS0cd2eSkOOROeBnnVBnAy9LtJ8tY4vUEoe55N4CNPxzbWvR39iBw==", + "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^3.3.0", - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/invalid-dependency": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/invalid-dependency/-/invalid-dependency-3.0.3.tgz", - "integrity": "sha512-ID1eL/zpDULmHJbflb864k72/SNOZCADRc9i7Exq3RUNJw6raWUSlFEQ+3PX3EYs++bTxZB2dE9mEHTQLv61tw==", + "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^3.3.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/is-array-buffer": { + "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/util-utf8": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", "license": "Apache-2.0", "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/middleware-content-length": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@smithy/middleware-content-length/-/middleware-content-length-3.0.4.tgz", - "integrity": "sha512-wySGje/KfhsnF8YSh9hP16pZcl3C+X6zRsvSfItQGvCyte92LliilU3SD0nR7kTlxnAJwxY8vE/k4Eoezj847Q==", + "node_modules/@aws-sdk/middleware-host-header": { + "version": "3.620.0", "license": "Apache-2.0", "dependencies": { - "@smithy/protocol-http": "^4.0.4", + "@aws-sdk/types": "3.609.0", + "@smithy/protocol-http": "^4.1.0", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1571,50 +1296,36 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/middleware-endpoint": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-3.0.5.tgz", - "integrity": "sha512-V4acqqrh5tDxUEGVTOgf2lYMZqPQsoGntCrjrJZEeBzEzDry2d2vcI1QCXhGltXPPY+BMc6eksZMguA9fIY8vA==", + "node_modules/@aws-sdk/middleware-location-constraint": { + "version": "3.609.0", "license": "Apache-2.0", "dependencies": { - "@smithy/middleware-serde": "^3.0.3", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/shared-ini-file-loader": "^3.1.4", + "@aws-sdk/types": "3.609.0", "@smithy/types": "^3.3.0", - "@smithy/url-parser": "^3.0.3", - "@smithy/util-middleware": "^3.0.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/middleware-retry": { - "version": "3.0.10", - "resolved": "https://registry.npmjs.org/@smithy/middleware-retry/-/middleware-retry-3.0.10.tgz", - "integrity": "sha512-+6ibpv6jpkTNJS6yErQSEjbxCWf1/jMeUSlpSlUiTYf73LGR9riSRlIrL1+JEW0eEpb6MelQ04BIc38aj8GtxQ==", + "node_modules/@aws-sdk/middleware-logger": { + "version": "3.609.0", "license": "Apache-2.0", "dependencies": { - "@smithy/node-config-provider": "^3.1.4", - "@smithy/protocol-http": "^4.0.4", - "@smithy/service-error-classification": "^3.0.3", - "@smithy/smithy-client": "^3.1.8", + "@aws-sdk/types": "3.609.0", "@smithy/types": "^3.3.0", - "@smithy/util-middleware": "^3.0.3", - "@smithy/util-retry": "^3.0.3", - "tslib": "^2.6.2", - "uuid": "^9.0.1" + "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/middleware-serde": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-3.0.3.tgz", - "integrity": "sha512-puUbyJQBcg9eSErFXjKNiGILJGtiqmuuNKEYNYfUD57fUl4i9+mfmThtQhvFXU0hCVG0iEJhvQUipUf+/SsFdA==", + "node_modules/@aws-sdk/middleware-recursion-detection": { + "version": "3.620.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/types": "3.609.0", + "@smithy/protocol-http": "^4.1.0", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1622,69 +1333,66 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/middleware-stack": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-3.0.3.tgz", - "integrity": "sha512-r4klY9nFudB0r9UdSMaGSyjyQK5adUyPnQN/ZM6M75phTxOdnc/AhpvGD1fQUvgmqjQEBGCwpnPbDm8pH5PapA==", + "node_modules/@aws-sdk/middleware-sdk-s3": { + "version": "3.635.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/core": "3.635.0", + "@aws-sdk/types": "3.609.0", + "@aws-sdk/util-arn-parser": "3.568.0", + "@smithy/core": "^2.4.0", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/signature-v4": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", + "@smithy/util-config-provider": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-stream": "^3.1.3", + "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/node-config-provider": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-3.1.4.tgz", - "integrity": "sha512-YvnElQy8HR4vDcAjoy7Xkx9YT8xZP4cBXcbJSgm/kxmiQu08DwUwj8rkGnyoJTpfl/3xYHH+d8zE+eHqoDCSdQ==", + "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/node-http-handler": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-3.1.3.tgz", - "integrity": "sha512-UiKZm8KHb/JeOPzHZtRUfyaRDO1KPKPpsd7iplhiwVGOeVdkiVJ5bVe7+NhWREMOKomrDIDdSZyglvMothLg0Q==", + "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/abort-controller": "^3.1.1", - "@smithy/protocol-http": "^4.0.4", - "@smithy/querystring-builder": "^3.0.3", - "@smithy/types": "^3.3.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/property-provider": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-3.1.3.tgz", - "integrity": "sha512-zahyOVR9Q4PEoguJ/NrFP4O7SMAfYO1HLhB18M+q+Z4KFd4V2obiMnlVoUFzFLSPeVt1POyNWneHHrZaTMoc/g==", + "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^3.3.0", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", + "node_modules/@aws-sdk/middleware-ssec": { + "version": "3.609.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/types": "3.609.0", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1692,51 +1400,43 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/querystring-builder": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-3.0.3.tgz", - "integrity": "sha512-vyWckeUeesFKzCDaRwWLUA1Xym9McaA6XpFfAK5qI9DKJ4M33ooQGqvM4J+LalH4u/Dq9nFiC8U6Qn1qi0+9zw==", + "node_modules/@aws-sdk/middleware-user-agent": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/types": "3.609.0", + "@aws-sdk/util-endpoints": "3.637.0", + "@smithy/protocol-http": "^4.1.0", "@smithy/types": "^3.3.0", - "@smithy/util-uri-escape": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/querystring-parser": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-3.0.3.tgz", - "integrity": "sha512-zahM1lQv2YjmznnfQsWbYojFe55l0SLG/988brlLv1i8z3dubloLF+75ATRsqPBboUXsW6I9CPGE5rQgLfY0vQ==", + "node_modules/@aws-sdk/region-config-resolver": { + "version": "3.614.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/types": "3.609.0", + "@smithy/node-config-provider": "^3.1.4", "@smithy/types": "^3.3.0", + "@smithy/util-config-provider": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/service-error-classification": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/service-error-classification/-/service-error-classification-3.0.3.tgz", - "integrity": "sha512-Jn39sSl8cim/VlkLsUhRFq/dKDnRUFlfRkvhOJaUbLBXUsLRLNf9WaxDv/z9BjuQ3A6k/qE8af1lsqcwm7+DaQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/shared-ini-file-loader": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-3.1.4.tgz", - "integrity": "sha512-qMxS4hBGB8FY2GQqshcRUy1K6k8aBWP5vwm8qKkCT3A9K2dawUwOIJfqh9Yste/Bl0J2lzosVyrXDj68kLcHXQ==", + "node_modules/@aws-sdk/signature-v4-multi-region": { + "version": "3.635.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/middleware-sdk-s3": "3.635.0", + "@aws-sdk/types": "3.609.0", + "@smithy/protocol-http": "^4.1.0", + "@smithy/signature-v4": "^4.1.0", "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, @@ -1744,45 +1444,36 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/signature-v4": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-3.1.2.tgz", - "integrity": "sha512-3BcPylEsYtD0esM4Hoyml/+s7WP2LFhcM3J2AGdcL2vx9O60TtfpDOL72gjb4lU8NeRPeKAwR77YNyyGvMbuEA==", + "node_modules/@aws-sdk/token-providers": { + "version": "3.614.0", "license": "Apache-2.0", "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", + "@aws-sdk/types": "3.609.0", + "@smithy/property-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.4", "@smithy/types": "^3.3.0", - "@smithy/util-hex-encoding": "^3.0.0", - "@smithy/util-middleware": "^3.0.3", - "@smithy/util-uri-escape": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-sso-oidc": "^3.614.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/smithy-client": { - "version": "3.1.8", - "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-3.1.8.tgz", - "integrity": "sha512-nUNGCa0NgvtD0eM45732EBp1H9JQITChMBegGtPRhJD00v3hiFF6tibiOihcYwP5mbp9Kui+sOCl86rDT/Ew2w==", + "node_modules/@aws-sdk/types": { + "version": "3.609.0", "license": "Apache-2.0", "dependencies": { - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-stack": "^3.0.3", - "@smithy/protocol-http": "^4.0.4", "@smithy/types": "^3.3.0", - "@smithy/util-stream": "^3.1.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@aws-sdk/util-arn-parser": { + "version": "3.568.0", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" @@ -1791,2117 +1482,187 @@ "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/url-parser": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-3.0.3.tgz", - "integrity": "sha512-pw3VtZtX2rg+s6HMs6/+u9+hu6oY6U7IohGhVNnjbgKy86wcIsSZwgHrFR+t67Uyxvp4Xz3p3kGXXIpTNisq8A==", + "node_modules/@aws-sdk/util-endpoints": { + "version": "3.637.0", "license": "Apache-2.0", "dependencies": { - "@smithy/querystring-parser": "^3.0.3", + "@aws-sdk/types": "3.609.0", "@smithy/types": "^3.3.0", + "@smithy/util-endpoints": "^2.0.5", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-base64": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-3.0.0.tgz", - "integrity": "sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==", + "node_modules/@aws-sdk/util-locate-window": { + "version": "3.568.0", "license": "Apache-2.0", "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-body-length-browser": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-body-length-browser/-/util-body-length-browser-3.0.0.tgz", - "integrity": "sha512-cbjJs2A1mLYmqmyVl80uoLTJhAcfzMOyPgjwAYusWKMdLeNtzmMz9YxNl3/jRLoxSS3wkqkf0jwNdtXWtyEBaQ==", + "node_modules/@aws-sdk/util-user-agent-browser": { + "version": "3.609.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/types": "3.609.0", + "@smithy/types": "^3.3.0", + "bowser": "^2.11.0", "tslib": "^2.6.2" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-body-length-node": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-body-length-node/-/util-body-length-node-3.0.0.tgz", - "integrity": "sha512-Tj7pZ4bUloNUP6PzwhN7K386tmSmEET9QtQg0TgdNOnxhZvCssHji+oZTUIuzxECRfG8rdm2PMw2WCFs6eIYkA==", + "node_modules/@aws-sdk/util-user-agent-node": { + "version": "3.614.0", "license": "Apache-2.0", "dependencies": { + "@aws-sdk/types": "3.609.0", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" + }, + "peerDependencies": { + "aws-crt": ">=1.0.0" + }, + "peerDependenciesMeta": { + "aws-crt": { + "optional": true + } } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-buffer-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", + "node_modules/@aws-sdk/xml-builder": { + "version": "3.609.0", "license": "Apache-2.0", "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-config-provider": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-config-provider/-/util-config-provider-3.0.0.tgz", - "integrity": "sha512-pbjk4s0fwq3Di/ANL+rCvJMKM5bzAQdE5S/6RL5NXgMExFAi6UgQMPOm5yPaIWPpr+EOXKXRonJ3FoxKf4mCJQ==", - "license": "Apache-2.0", + "node_modules/@babel/code-frame": { + "version": "7.23.5", + "license": "MIT", "dependencies": { - "tslib": "^2.6.2" + "@babel/highlight": "^7.23.4", + "chalk": "^2.4.2" }, "engines": { - "node": ">=16.0.0" + "node": ">=6.9.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-defaults-mode-browser": { - "version": "3.0.10", - "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-browser/-/util-defaults-mode-browser-3.0.10.tgz", - "integrity": "sha512-WgaNxh33md2zvlD+1TSceVmM7DIy7qYMtuhOat+HYoTntsg0QTbNvoB/5DRxEwSpN84zKf9O34yqzRRtxJZgFg==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/property-provider": "^3.1.3", - "@smithy/smithy-client": "^3.1.8", - "@smithy/types": "^3.3.0", - "bowser": "^2.11.0", - "tslib": "^2.6.2" - }, + "node_modules/@babel/compat-data": { + "version": "7.23.5", + "dev": true, + "license": "MIT", "engines": { - "node": ">= 10.0.0" + "node": ">=6.9.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-defaults-mode-node": { - "version": "3.0.10", - "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-node/-/util-defaults-mode-node-3.0.10.tgz", - "integrity": "sha512-3x/pcNIFyaAEQqXc3qnQsCFLlTz/Mwsfl9ciEPU56/Dk/g1kTFjkzyLbUNJaeOo5HT01VrpJBKrBuN94qbPm9A==", - "license": "Apache-2.0", + "node_modules/@babel/core": { + "version": "7.23.7", + "dev": true, + "license": "MIT", "dependencies": { - "@smithy/config-resolver": "^3.0.5", - "@smithy/credential-provider-imds": "^3.1.4", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/property-provider": "^3.1.3", - "@smithy/smithy-client": "^3.1.8", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" + "@ampproject/remapping": "^2.2.0", + "@babel/code-frame": "^7.23.5", + "@babel/generator": "^7.23.6", + "@babel/helper-compilation-targets": "^7.23.6", + "@babel/helper-module-transforms": "^7.23.3", + "@babel/helpers": "^7.23.7", + "@babel/parser": "^7.23.6", + "@babel/template": "^7.22.15", + "@babel/traverse": "^7.23.7", + "@babel/types": "^7.23.6", + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" }, "engines": { - "node": ">= 10.0.0" + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-endpoints": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@smithy/util-endpoints/-/util-endpoints-2.0.5.tgz", - "integrity": "sha512-ReQP0BWihIE68OAblC/WQmDD40Gx+QY1Ez8mTdFMXpmjfxSyz2fVQu3A4zXRfQU9sZXtewk3GmhfOHswvX+eNg==", - "license": "Apache-2.0", + "node_modules/@babel/core/node_modules/semver": { + "version": "6.3.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/@babel/generator": { + "version": "7.23.6", + "dev": true, + "license": "MIT", "dependencies": { - "@smithy/node-config-provider": "^3.1.4", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" + "@babel/types": "^7.23.6", + "@jridgewell/gen-mapping": "^0.3.2", + "@jridgewell/trace-mapping": "^0.3.17", + "jsesc": "^2.5.1" }, "engines": { - "node": ">=16.0.0" + "node": ">=6.9.0" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-hex-encoding": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", - "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" + "node_modules/@babel/generator/node_modules/jsesc": { + "version": "2.5.2", + "dev": true, + "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" }, "engines": { - "node": ">=16.0.0" + "node": ">=4" } }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-middleware": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-3.0.3.tgz", - "integrity": "sha512-l+StyYYK/eO3DlVPbU+4Bi06Jjal+PFLSMmlWM1BEwyLxZ3aKkf1ROnoIakfaA7mC6uw3ny7JBkau4Yc+5zfWw==", - "license": "Apache-2.0", + "node_modules/@babel/helper-compilation-targets": { + "version": "7.23.6", + "dev": true, + "license": "MIT", "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" + "@babel/compat-data": "^7.23.5", + "@babel/helper-validator-option": "^7.23.5", + "browserslist": "^4.22.2", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" }, "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-retry": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/util-retry/-/util-retry-3.0.3.tgz", - "integrity": "sha512-AFw+hjpbtVApzpNDhbjNG5NA3kyoMs7vx0gsgmlJF4s+yz1Zlepde7J58zpIRIsdjc+emhpAITxA88qLkPF26w==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/service-error-classification": "^3.0.3", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-stream": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-3.1.0.tgz", - "integrity": "sha512-QEMvyv58QIptWA8cpQPbHagJOAlrbCt3ueB9EShwdFfVMYAviXdVtksszQQq+o+dv5dalUMWUbUHUDSJgkF9xg==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/fetch-http-handler": "^3.2.2", - "@smithy/node-http-handler": "^3.1.3", - "@smithy/types": "^3.3.0", - "@smithy/util-base64": "^3.0.0", - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-hex-encoding": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-uri-escape": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-3.0.0.tgz", - "integrity": "sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/client-s3/node_modules/@smithy/util-utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/client-sso": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso/-/client-sso-3.485.0.tgz", - "integrity": "sha512-apN2bEn0PZs0jD4jAfvwO3dlWqw9YIQJ6TAudM1bd3S5vzWqlBBcLfQpK6taHoQaI+WqgUWXLuOf7gRFbGXKPg==", - "dependencies": { - "@aws-crypto/sha256-browser": "3.0.0", - "@aws-crypto/sha256-js": "3.0.0", - "@aws-sdk/core": "3.485.0", - "@aws-sdk/middleware-host-header": "3.485.0", - "@aws-sdk/middleware-logger": "3.485.0", - "@aws-sdk/middleware-recursion-detection": "3.485.0", - "@aws-sdk/middleware-user-agent": "3.485.0", - "@aws-sdk/region-config-resolver": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@aws-sdk/util-endpoints": "3.485.0", - "@aws-sdk/util-user-agent-browser": "3.485.0", - "@aws-sdk/util-user-agent-node": "3.485.0", - "@smithy/config-resolver": "^2.0.23", - "@smithy/core": "^1.2.2", - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/hash-node": "^2.0.18", - "@smithy/invalid-dependency": "^2.0.16", - "@smithy/middleware-content-length": "^2.0.18", - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-retry": "^2.0.26", - "@smithy/middleware-serde": "^2.0.16", - "@smithy/middleware-stack": "^2.0.10", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/protocol-http": "^3.0.12", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "@smithy/util-base64": "^2.0.1", - "@smithy/util-body-length-browser": "^2.0.1", - "@smithy/util-body-length-node": "^2.1.0", - "@smithy/util-defaults-mode-browser": "^2.0.24", - "@smithy/util-defaults-mode-node": "^2.0.32", - "@smithy/util-endpoints": "^1.0.8", - "@smithy/util-retry": "^2.0.9", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/client-sts": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sts/-/client-sts-3.485.0.tgz", - "integrity": "sha512-PI4q36kVF0fpIPZyeQhrwwJZ6SRkOGvU3rX5Qn4b5UY5X+Ct1aLhqSX8/OB372UZIcnh6eSvERu8POHleDO7Jw==", - "dependencies": { - "@aws-crypto/sha256-browser": "3.0.0", - "@aws-crypto/sha256-js": "3.0.0", - "@aws-sdk/core": "3.485.0", - "@aws-sdk/credential-provider-node": "3.485.0", - "@aws-sdk/middleware-host-header": "3.485.0", - "@aws-sdk/middleware-logger": "3.485.0", - "@aws-sdk/middleware-recursion-detection": "3.485.0", - "@aws-sdk/middleware-user-agent": "3.485.0", - "@aws-sdk/region-config-resolver": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@aws-sdk/util-endpoints": "3.485.0", - "@aws-sdk/util-user-agent-browser": "3.485.0", - "@aws-sdk/util-user-agent-node": "3.485.0", - "@smithy/config-resolver": "^2.0.23", - "@smithy/core": "^1.2.2", - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/hash-node": "^2.0.18", - "@smithy/invalid-dependency": "^2.0.16", - "@smithy/middleware-content-length": "^2.0.18", - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-retry": "^2.0.26", - "@smithy/middleware-serde": "^2.0.16", - "@smithy/middleware-stack": "^2.0.10", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/protocol-http": "^3.0.12", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "@smithy/util-base64": "^2.0.1", - "@smithy/util-body-length-browser": "^2.0.1", - "@smithy/util-body-length-node": "^2.1.0", - "@smithy/util-defaults-mode-browser": "^2.0.24", - "@smithy/util-defaults-mode-node": "^2.0.32", - "@smithy/util-endpoints": "^1.0.8", - "@smithy/util-middleware": "^2.0.9", - "@smithy/util-retry": "^2.0.9", - "@smithy/util-utf8": "^2.0.2", - "fast-xml-parser": "4.2.5", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/core": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.485.0.tgz", - "integrity": "sha512-Yvi80DQcbjkYCft471ClE3HuetuNVqntCs6eFOomDcrJaqdOFrXv2kJAxky84MRA/xb7bGlDGAPbTuj1ICputg==", - "dependencies": { - "@smithy/core": "^1.2.2", - "@smithy/protocol-http": "^3.0.12", - "@smithy/signature-v4": "^2.0.0", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-cognito-identity": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-cognito-identity/-/credential-provider-cognito-identity-3.485.0.tgz", - "integrity": "sha512-XIy5h1AcDiY3V286X7KrLA5HAxLfzLGrUGBPFY+GTJGYetDhlJwFz12q6BOkIfeAhUbT2Umb4ptujX9eqpZJHQ==", - "dependencies": { - "@aws-sdk/client-cognito-identity": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-env": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.485.0.tgz", - "integrity": "sha512-3XkFgwVU1XOB33dV7t9BKJ/ptdl2iS+0dxE7ecq8aqT2/gsfKmLCae1G17P8WmdD3z0kMDTvnqM2aWgUnSOkmg==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-http": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.485.0.tgz", - "integrity": "sha512-2/2Y3Z7cpKf8vbQ+FzoBPxRyb0hGJZB1YrnH7hptVi5gSVe1NiwV5ZtsDnv4cwUfOBqEu97nMXw5IrRO26S0DA==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/property-provider": "^2.0.0", - "@smithy/protocol-http": "^3.0.12", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/util-stream": "^2.0.24", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-ini": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.485.0.tgz", - "integrity": "sha512-cFYF/Bdw7EnT4viSxYpNIv3IBkri/Yb+JpQXl8uDq7bfVJfAN5qZmK07vRkg08xL6TC4F41wshhMSAucGdTwIw==", - "dependencies": { - "@aws-sdk/credential-provider-env": "3.485.0", - "@aws-sdk/credential-provider-process": "3.485.0", - "@aws-sdk/credential-provider-sso": "3.485.0", - "@aws-sdk/credential-provider-web-identity": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@smithy/credential-provider-imds": "^2.0.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/shared-ini-file-loader": "^2.0.6", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-node": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.485.0.tgz", - "integrity": "sha512-2DwzO2azkSzngifKDT61W/DL0tSzewuaFHiLJWdfc8Et3mdAQJ9x3KAj8u7XFpjIcGNqk7FiKjN+zeGUuNiEhA==", - "dependencies": { - "@aws-sdk/credential-provider-env": "3.485.0", - "@aws-sdk/credential-provider-ini": "3.485.0", - "@aws-sdk/credential-provider-process": "3.485.0", - "@aws-sdk/credential-provider-sso": "3.485.0", - "@aws-sdk/credential-provider-web-identity": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@smithy/credential-provider-imds": "^2.0.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/shared-ini-file-loader": "^2.0.6", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-process": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.485.0.tgz", - "integrity": "sha512-X9qS6ZO/rDKYDgWqD1YmSX7sAUUHax9HbXlgGiTTdtfhZvQh1ZmnH6wiPu5WNliafHZFtZT2W07kgrDLPld/Ug==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/shared-ini-file-loader": "^2.0.6", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-sso": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.485.0.tgz", - "integrity": "sha512-l0oC8GTrWh+LFQQfSmG1Jai1PX7Mhj9arb/CaS1/tmeZE0hgIXW++tvljYs/Dds4LGXUlaWG+P7BrObf6OyIXA==", - "dependencies": { - "@aws-sdk/client-sso": "3.485.0", - "@aws-sdk/token-providers": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/shared-ini-file-loader": "^2.0.6", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-provider-web-identity": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.485.0.tgz", - "integrity": "sha512-WpBFZFE0iXtnibH5POMEKITj/hR0YV5l2n9p8BEvKjdJ63s3Xke1RN20ZdIyKDaRDwj8adnKDgNPEnAKdS4kLw==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/credential-providers": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-providers/-/credential-providers-3.485.0.tgz", - "integrity": "sha512-SpGEmiVr+C9Dtc5tZFfFYXSNxbl1jShLlyZPWERHBn4QwGvdXcgPB96I0yvUuitBKrM0winHsCWH7CR/z24kmg==", - "dependencies": { - "@aws-sdk/client-cognito-identity": "3.485.0", - "@aws-sdk/client-sso": "3.485.0", - "@aws-sdk/client-sts": "3.485.0", - "@aws-sdk/credential-provider-cognito-identity": "3.485.0", - "@aws-sdk/credential-provider-env": "3.485.0", - "@aws-sdk/credential-provider-http": "3.485.0", - "@aws-sdk/credential-provider-ini": "3.485.0", - "@aws-sdk/credential-provider-node": "3.485.0", - "@aws-sdk/credential-provider-process": "3.485.0", - "@aws-sdk/credential-provider-sso": "3.485.0", - "@aws-sdk/credential-provider-web-identity": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@smithy/credential-provider-imds": "^2.0.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage": { - "version": "3.600.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/lib-storage/-/lib-storage-3.600.0.tgz", - "integrity": "sha512-jjgGMmFykXBAs8YO3ghgnVSjM/uf99jvVQqKJfDjwXUCLPrsZqk14v2WcDCWAXzeAroDvIOVQO1V/RR8fK18Pw==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/abort-controller": "^3.0.1", - "@smithy/middleware-endpoint": "^3.0.2", - "@smithy/smithy-client": "^3.1.2", - "buffer": "5.6.0", - "events": "3.3.0", - "stream-browserify": "3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - }, - "peerDependencies": { - "@aws-sdk/client-s3": "^3.600.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/abort-controller": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.1.tgz", - "integrity": "sha512-MBJBiidoe+0cTFhyxT8g+9g7CeVccLM0IOKKUMCNQ1CNMJ/eIfoo0RTfVrXOONEI1UCN1W+zkiHSbzUNE9dZtQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/fetch-http-handler": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-3.2.2.tgz", - "integrity": "sha512-3LaWlBZObyGrOOd7e5MlacnAKEwFBmAeiW/TOj2eR9475Vnq30uS2510+tnKbxrGjROfNdOhQqGo5j3sqLT6bA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/protocol-http": "^4.0.4", - "@smithy/querystring-builder": "^3.0.3", - "@smithy/types": "^3.3.0", - "@smithy/util-base64": "^3.0.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/is-array-buffer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/middleware-endpoint": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-3.0.5.tgz", - "integrity": "sha512-V4acqqrh5tDxUEGVTOgf2lYMZqPQsoGntCrjrJZEeBzEzDry2d2vcI1QCXhGltXPPY+BMc6eksZMguA9fIY8vA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/middleware-serde": "^3.0.3", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", - "@smithy/url-parser": "^3.0.3", - "@smithy/util-middleware": "^3.0.3", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/middleware-serde": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-3.0.3.tgz", - "integrity": "sha512-puUbyJQBcg9eSErFXjKNiGILJGtiqmuuNKEYNYfUD57fUl4i9+mfmThtQhvFXU0hCVG0iEJhvQUipUf+/SsFdA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/middleware-stack": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-3.0.3.tgz", - "integrity": "sha512-r4klY9nFudB0r9UdSMaGSyjyQK5adUyPnQN/ZM6M75phTxOdnc/AhpvGD1fQUvgmqjQEBGCwpnPbDm8pH5PapA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/node-config-provider": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-3.1.4.tgz", - "integrity": "sha512-YvnElQy8HR4vDcAjoy7Xkx9YT8xZP4cBXcbJSgm/kxmiQu08DwUwj8rkGnyoJTpfl/3xYHH+d8zE+eHqoDCSdQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/node-http-handler": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-3.1.3.tgz", - "integrity": "sha512-UiKZm8KHb/JeOPzHZtRUfyaRDO1KPKPpsd7iplhiwVGOeVdkiVJ5bVe7+NhWREMOKomrDIDdSZyglvMothLg0Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/abort-controller": "^3.1.1", - "@smithy/protocol-http": "^4.0.4", - "@smithy/querystring-builder": "^3.0.3", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/property-provider": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-3.1.3.tgz", - "integrity": "sha512-zahyOVR9Q4PEoguJ/NrFP4O7SMAfYO1HLhB18M+q+Z4KFd4V2obiMnlVoUFzFLSPeVt1POyNWneHHrZaTMoc/g==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/querystring-builder": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-3.0.3.tgz", - "integrity": "sha512-vyWckeUeesFKzCDaRwWLUA1Xym9McaA6XpFfAK5qI9DKJ4M33ooQGqvM4J+LalH4u/Dq9nFiC8U6Qn1qi0+9zw==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "@smithy/util-uri-escape": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/querystring-parser": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-3.0.3.tgz", - "integrity": "sha512-zahM1lQv2YjmznnfQsWbYojFe55l0SLG/988brlLv1i8z3dubloLF+75ATRsqPBboUXsW6I9CPGE5rQgLfY0vQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/shared-ini-file-loader": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-3.1.4.tgz", - "integrity": "sha512-qMxS4hBGB8FY2GQqshcRUy1K6k8aBWP5vwm8qKkCT3A9K2dawUwOIJfqh9Yste/Bl0J2lzosVyrXDj68kLcHXQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/smithy-client": { - "version": "3.1.8", - "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-3.1.8.tgz", - "integrity": "sha512-nUNGCa0NgvtD0eM45732EBp1H9JQITChMBegGtPRhJD00v3hiFF6tibiOihcYwP5mbp9Kui+sOCl86rDT/Ew2w==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-stack": "^3.0.3", - "@smithy/protocol-http": "^4.0.4", - "@smithy/types": "^3.3.0", - "@smithy/util-stream": "^3.1.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/url-parser": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-3.0.3.tgz", - "integrity": "sha512-pw3VtZtX2rg+s6HMs6/+u9+hu6oY6U7IohGhVNnjbgKy86wcIsSZwgHrFR+t67Uyxvp4Xz3p3kGXXIpTNisq8A==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/querystring-parser": "^3.0.3", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-base64": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-3.0.0.tgz", - "integrity": "sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-buffer-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-hex-encoding": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", - "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-middleware": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-3.0.3.tgz", - "integrity": "sha512-l+StyYYK/eO3DlVPbU+4Bi06Jjal+PFLSMmlWM1BEwyLxZ3aKkf1ROnoIakfaA7mC6uw3ny7JBkau4Yc+5zfWw==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-stream": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-3.1.0.tgz", - "integrity": "sha512-QEMvyv58QIptWA8cpQPbHagJOAlrbCt3ueB9EShwdFfVMYAviXdVtksszQQq+o+dv5dalUMWUbUHUDSJgkF9xg==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/fetch-http-handler": "^3.2.2", - "@smithy/node-http-handler": "^3.1.3", - "@smithy/types": "^3.3.0", - "@smithy/util-base64": "^3.0.0", - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-hex-encoding": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-uri-escape": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-3.0.0.tgz", - "integrity": "sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/lib-storage/node_modules/@smithy/util-utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-bucket-endpoint/-/middleware-bucket-endpoint-3.614.0.tgz", - "integrity": "sha512-TqEY8KcZeZ0LIxXaqG9RSSNnDHvD8RAFP4Xenwsxqnyad0Yn7LgCoFwRByelJ0t54ROYL1/ETJleWE4U4TOXdg==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-arn-parser": "3.568.0", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/protocol-http": "^4.0.3", - "@smithy/types": "^3.3.0", - "@smithy/util-config-provider": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@smithy/node-config-provider": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-3.1.4.tgz", - "integrity": "sha512-YvnElQy8HR4vDcAjoy7Xkx9YT8xZP4cBXcbJSgm/kxmiQu08DwUwj8rkGnyoJTpfl/3xYHH+d8zE+eHqoDCSdQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@smithy/property-provider": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-3.1.3.tgz", - "integrity": "sha512-zahyOVR9Q4PEoguJ/NrFP4O7SMAfYO1HLhB18M+q+Z4KFd4V2obiMnlVoUFzFLSPeVt1POyNWneHHrZaTMoc/g==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@smithy/shared-ini-file-loader": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-3.1.4.tgz", - "integrity": "sha512-qMxS4hBGB8FY2GQqshcRUy1K6k8aBWP5vwm8qKkCT3A9K2dawUwOIJfqh9Yste/Bl0J2lzosVyrXDj68kLcHXQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/@smithy/util-config-provider": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-config-provider/-/util-config-provider-3.0.0.tgz", - "integrity": "sha512-pbjk4s0fwq3Di/ANL+rCvJMKM5bzAQdE5S/6RL5NXgMExFAi6UgQMPOm5yPaIWPpr+EOXKXRonJ3FoxKf4mCJQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-expect-continue": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-expect-continue/-/middleware-expect-continue-3.609.0.tgz", - "integrity": "sha512-+zeg//mSer4JZRxOB/4mUOMUJyuYPwATnIC5moBB8P8Xe+mJaVRFy8qlCtzYNj2TycnlsBPzTK0j7P1yvDh97w==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/protocol-http": "^4.0.3", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-expect-continue/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-expect-continue/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-expect-continue/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-flexible-checksums/-/middleware-flexible-checksums-3.614.0.tgz", - "integrity": "sha512-ZLpxVXMboDeMT7p2Kdp5m1uLVKOktkZoMgLvvbe3zbrU4Ji5IU5xVE0aa4X7H28BtuODCs6SLESnPs19bhMKlA==", - "license": "Apache-2.0", - "dependencies": { - "@aws-crypto/crc32": "5.2.0", - "@aws-crypto/crc32c": "5.2.0", - "@aws-sdk/types": "3.609.0", - "@smithy/is-array-buffer": "^3.0.0", - "@smithy/protocol-http": "^4.0.3", - "@smithy/types": "^3.3.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@aws-crypto/crc32": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/crc32/-/crc32-5.2.0.tgz", - "integrity": "sha512-nLbCWqQNgUiwwtFsen1AdzAtvuLRsQS8rYgMuxCrdKf9kOssamGLuPwyTY9wyYblNr9+1XM8v6zoDTPPSIeANg==", - "license": "Apache-2.0", - "dependencies": { - "@aws-crypto/util": "^5.2.0", - "@aws-sdk/types": "^3.222.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@aws-crypto/util": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", - "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "^3.222.0", - "@smithy/util-utf8": "^2.0.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@aws-crypto/util/node_modules/@smithy/is-array-buffer": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-2.2.0.tgz", - "integrity": "sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@aws-crypto/util/node_modules/@smithy/util-buffer-from": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-2.2.0.tgz", - "integrity": "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^2.2.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@aws-crypto/util/node_modules/@smithy/util-utf8": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-2.3.0.tgz", - "integrity": "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^2.2.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/is-array-buffer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/util-buffer-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-flexible-checksums/node_modules/@smithy/util-utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-host-header": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-host-header/-/middleware-host-header-3.485.0.tgz", - "integrity": "sha512-1mAUX9dQNGo2RIKseVj7SI/D5abQJQ/Os8hQ0NyVAyyVYF+Yjx5PphKgfhM5yoBwuwZUl6q71XPYEGNx7be6SA==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/protocol-http": "^3.0.12", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-location-constraint": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-location-constraint/-/middleware-location-constraint-3.609.0.tgz", - "integrity": "sha512-xzsdoTkszGVqGVPjUmgoP7TORiByLueMHieI1fhQL888WPdqctwAx3ES6d/bA9Q/i8jnc6hs+Fjhy8UvBTkE9A==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-location-constraint/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-location-constraint/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-logger": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-logger/-/middleware-logger-3.485.0.tgz", - "integrity": "sha512-O8IgJ0LHi5wTs5GlpI7nqmmSSagkVdd1shpGgQWY2h0kMSCII8CJZHBG97dlFFpGTvx5EDlhPNek7rl/6F4dRw==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-recursion-detection": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-recursion-detection/-/middleware-recursion-detection-3.485.0.tgz", - "integrity": "sha512-ZeVNATGNFcqkWDut3luVszROTUzkU5u+rJpB/xmeMoenlDAjPRiHt/ca3WkI5wAnIJ1VSNGpD2sOFLMCH+EWag==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/protocol-http": "^3.0.12", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-sdk-s3/-/middleware-sdk-s3-3.614.0.tgz", - "integrity": "sha512-9fJTaiuuOfFV4FqmUEhPYzrtv7JOfYpB7q65oG3uayVH4ngWHIJkjnnX79zRhNZKdPGta+XIsnZzjEghg82ngA==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "3.609.0", - "@aws-sdk/util-arn-parser": "3.568.0", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/protocol-http": "^4.0.3", - "@smithy/signature-v4": "^3.1.2", - "@smithy/smithy-client": "^3.1.7", - "@smithy/types": "^3.3.0", - "@smithy/util-config-provider": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/abort-controller": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.1.tgz", - "integrity": "sha512-MBJBiidoe+0cTFhyxT8g+9g7CeVccLM0IOKKUMCNQ1CNMJ/eIfoo0RTfVrXOONEI1UCN1W+zkiHSbzUNE9dZtQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/fetch-http-handler": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-3.2.2.tgz", - "integrity": "sha512-3LaWlBZObyGrOOd7e5MlacnAKEwFBmAeiW/TOj2eR9475Vnq30uS2510+tnKbxrGjROfNdOhQqGo5j3sqLT6bA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/protocol-http": "^4.0.4", - "@smithy/querystring-builder": "^3.0.3", - "@smithy/types": "^3.3.0", - "@smithy/util-base64": "^3.0.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/is-array-buffer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/middleware-endpoint": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-3.0.5.tgz", - "integrity": "sha512-V4acqqrh5tDxUEGVTOgf2lYMZqPQsoGntCrjrJZEeBzEzDry2d2vcI1QCXhGltXPPY+BMc6eksZMguA9fIY8vA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/middleware-serde": "^3.0.3", - "@smithy/node-config-provider": "^3.1.4", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", - "@smithy/url-parser": "^3.0.3", - "@smithy/util-middleware": "^3.0.3", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/middleware-serde": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-3.0.3.tgz", - "integrity": "sha512-puUbyJQBcg9eSErFXjKNiGILJGtiqmuuNKEYNYfUD57fUl4i9+mfmThtQhvFXU0hCVG0iEJhvQUipUf+/SsFdA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/middleware-stack": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-3.0.3.tgz", - "integrity": "sha512-r4klY9nFudB0r9UdSMaGSyjyQK5adUyPnQN/ZM6M75phTxOdnc/AhpvGD1fQUvgmqjQEBGCwpnPbDm8pH5PapA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/node-config-provider": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-3.1.4.tgz", - "integrity": "sha512-YvnElQy8HR4vDcAjoy7Xkx9YT8xZP4cBXcbJSgm/kxmiQu08DwUwj8rkGnyoJTpfl/3xYHH+d8zE+eHqoDCSdQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/property-provider": "^3.1.3", - "@smithy/shared-ini-file-loader": "^3.1.4", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/node-http-handler": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-3.1.3.tgz", - "integrity": "sha512-UiKZm8KHb/JeOPzHZtRUfyaRDO1KPKPpsd7iplhiwVGOeVdkiVJ5bVe7+NhWREMOKomrDIDdSZyglvMothLg0Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/abort-controller": "^3.1.1", - "@smithy/protocol-http": "^4.0.4", - "@smithy/querystring-builder": "^3.0.3", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/property-provider": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-3.1.3.tgz", - "integrity": "sha512-zahyOVR9Q4PEoguJ/NrFP4O7SMAfYO1HLhB18M+q+Z4KFd4V2obiMnlVoUFzFLSPeVt1POyNWneHHrZaTMoc/g==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/querystring-builder": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-3.0.3.tgz", - "integrity": "sha512-vyWckeUeesFKzCDaRwWLUA1Xym9McaA6XpFfAK5qI9DKJ4M33ooQGqvM4J+LalH4u/Dq9nFiC8U6Qn1qi0+9zw==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "@smithy/util-uri-escape": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/querystring-parser": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-3.0.3.tgz", - "integrity": "sha512-zahM1lQv2YjmznnfQsWbYojFe55l0SLG/988brlLv1i8z3dubloLF+75ATRsqPBboUXsW6I9CPGE5rQgLfY0vQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/shared-ini-file-loader": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-3.1.4.tgz", - "integrity": "sha512-qMxS4hBGB8FY2GQqshcRUy1K6k8aBWP5vwm8qKkCT3A9K2dawUwOIJfqh9Yste/Bl0J2lzosVyrXDj68kLcHXQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/signature-v4": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-3.1.2.tgz", - "integrity": "sha512-3BcPylEsYtD0esM4Hoyml/+s7WP2LFhcM3J2AGdcL2vx9O60TtfpDOL72gjb4lU8NeRPeKAwR77YNyyGvMbuEA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", - "@smithy/types": "^3.3.0", - "@smithy/util-hex-encoding": "^3.0.0", - "@smithy/util-middleware": "^3.0.3", - "@smithy/util-uri-escape": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/smithy-client": { - "version": "3.1.8", - "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-3.1.8.tgz", - "integrity": "sha512-nUNGCa0NgvtD0eM45732EBp1H9JQITChMBegGtPRhJD00v3hiFF6tibiOihcYwP5mbp9Kui+sOCl86rDT/Ew2w==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/middleware-endpoint": "^3.0.5", - "@smithy/middleware-stack": "^3.0.3", - "@smithy/protocol-http": "^4.0.4", - "@smithy/types": "^3.3.0", - "@smithy/util-stream": "^3.1.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/url-parser": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-3.0.3.tgz", - "integrity": "sha512-pw3VtZtX2rg+s6HMs6/+u9+hu6oY6U7IohGhVNnjbgKy86wcIsSZwgHrFR+t67Uyxvp4Xz3p3kGXXIpTNisq8A==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/querystring-parser": "^3.0.3", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-base64": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-3.0.0.tgz", - "integrity": "sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-buffer-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-config-provider": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-config-provider/-/util-config-provider-3.0.0.tgz", - "integrity": "sha512-pbjk4s0fwq3Di/ANL+rCvJMKM5bzAQdE5S/6RL5NXgMExFAi6UgQMPOm5yPaIWPpr+EOXKXRonJ3FoxKf4mCJQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-hex-encoding": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", - "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-middleware": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-3.0.3.tgz", - "integrity": "sha512-l+StyYYK/eO3DlVPbU+4Bi06Jjal+PFLSMmlWM1BEwyLxZ3aKkf1ROnoIakfaA7mC6uw3ny7JBkau4Yc+5zfWw==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-stream": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-3.1.0.tgz", - "integrity": "sha512-QEMvyv58QIptWA8cpQPbHagJOAlrbCt3ueB9EShwdFfVMYAviXdVtksszQQq+o+dv5dalUMWUbUHUDSJgkF9xg==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/fetch-http-handler": "^3.2.2", - "@smithy/node-http-handler": "^3.1.3", - "@smithy/types": "^3.3.0", - "@smithy/util-base64": "^3.0.0", - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-hex-encoding": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-uri-escape": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-3.0.0.tgz", - "integrity": "sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-sdk-s3/node_modules/@smithy/util-utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-signing": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-signing/-/middleware-signing-3.485.0.tgz", - "integrity": "sha512-41xzT2p1sOibhsLkdE5rwPJkNbBtKD8Gp36/ySfu0KE415wfXKacElSVxAaBw39/j7iSWDYqqybeEYbAzk+3GQ==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/property-provider": "^2.0.0", - "@smithy/protocol-http": "^3.0.12", - "@smithy/signature-v4": "^2.0.0", - "@smithy/types": "^2.8.0", - "@smithy/util-middleware": "^2.0.9", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/middleware-ssec": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-ssec/-/middleware-ssec-3.609.0.tgz", - "integrity": "sha512-GZSD1s7+JswWOTamVap79QiDaIV7byJFssBW68GYjyRS5EBjNfwA/8s+6uE6g39R3ojyTbYOmvcANoZEhSULXg==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/types": "3.609.0", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-ssec/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-ssec/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/middleware-user-agent": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-user-agent/-/middleware-user-agent-3.485.0.tgz", - "integrity": "sha512-CddCVOn+OPQ0CcchketIg+WF6v+MDLAf3GOYTR2htUxxIm7HABuRd6R3kvQ5Jny9CV8gMt22G1UZITsFexSJlQ==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@aws-sdk/util-endpoints": "3.485.0", - "@smithy/protocol-http": "^3.0.12", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/region-config-resolver": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/region-config-resolver/-/region-config-resolver-3.485.0.tgz", - "integrity": "sha512-2FB2EQ0sIE+YgFqGtkE1lDIMIL6nYe6MkOHBwBM7bommadKIrbbr2L22bPZGs3ReTsxiJabjzxbuCAVhrpHmhg==", - "dependencies": { - "@smithy/node-config-provider": "^2.1.9", - "@smithy/types": "^2.8.0", - "@smithy/util-config-provider": "^2.1.0", - "@smithy/util-middleware": "^2.0.9", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region": { - "version": "3.614.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/signature-v4-multi-region/-/signature-v4-multi-region-3.614.0.tgz", - "integrity": "sha512-6mW3ONW4oLzxrePznYhz7sNT9ji9Am9ufLeV722tbOVS5lArBOZ6E1oPz0uYBhisUPznWKhcLRMggt7vIJWMng==", - "license": "Apache-2.0", - "dependencies": { - "@aws-sdk/middleware-sdk-s3": "3.614.0", - "@aws-sdk/types": "3.609.0", - "@smithy/protocol-http": "^4.0.3", - "@smithy/signature-v4": "^3.1.2", - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@aws-sdk/types": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.609.0.tgz", - "integrity": "sha512-+Tqnh9w0h2LcrUsdXyT1F8mNhXz+tVYBtP19LpeEGntmvHwa2XzvLUCWpoIAIVsHp5+HdB2X9Sn0KAtmbFXc2Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/is-array-buffer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/protocol-http": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.4.tgz", - "integrity": "sha512-fAA2O4EFyNRyYdFLVIv5xMMeRb+3fRKc/Rt2flh5k831vLvUmNFXcydeg7V3UeEhGURJI4c1asmGJBjvmF6j8Q==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/signature-v4": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-3.1.2.tgz", - "integrity": "sha512-3BcPylEsYtD0esM4Hoyml/+s7WP2LFhcM3J2AGdcL2vx9O60TtfpDOL72gjb4lU8NeRPeKAwR77YNyyGvMbuEA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", - "@smithy/types": "^3.3.0", - "@smithy/util-hex-encoding": "^3.0.0", - "@smithy/util-middleware": "^3.0.3", - "@smithy/util-uri-escape": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/util-buffer-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/util-hex-encoding": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", - "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/util-middleware": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-3.0.3.tgz", - "integrity": "sha512-l+StyYYK/eO3DlVPbU+4Bi06Jjal+PFLSMmlWM1BEwyLxZ3aKkf1ROnoIakfaA7mC6uw3ny7JBkau4Yc+5zfWw==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/util-uri-escape": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-3.0.0.tgz", - "integrity": "sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/signature-v4-multi-region/node_modules/@smithy/util-utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/token-providers": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.485.0.tgz", - "integrity": "sha512-kOXA1WKIVIFNRqHL8ynVZ3hCKLsgnEmGr2iDR6agDNw5fYIlCO/6N2xR6QdGcLTvUUbwOlz4OvKLUQnWMKAnnA==", - "dependencies": { - "@aws-crypto/sha256-browser": "3.0.0", - "@aws-crypto/sha256-js": "3.0.0", - "@aws-sdk/middleware-host-header": "3.485.0", - "@aws-sdk/middleware-logger": "3.485.0", - "@aws-sdk/middleware-recursion-detection": "3.485.0", - "@aws-sdk/middleware-user-agent": "3.485.0", - "@aws-sdk/region-config-resolver": "3.485.0", - "@aws-sdk/types": "3.485.0", - "@aws-sdk/util-endpoints": "3.485.0", - "@aws-sdk/util-user-agent-browser": "3.485.0", - "@aws-sdk/util-user-agent-node": "3.485.0", - "@smithy/config-resolver": "^2.0.23", - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/hash-node": "^2.0.18", - "@smithy/invalid-dependency": "^2.0.16", - "@smithy/middleware-content-length": "^2.0.18", - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-retry": "^2.0.26", - "@smithy/middleware-serde": "^2.0.16", - "@smithy/middleware-stack": "^2.0.10", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/property-provider": "^2.0.0", - "@smithy/protocol-http": "^3.0.12", - "@smithy/shared-ini-file-loader": "^2.0.6", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "@smithy/util-base64": "^2.0.1", - "@smithy/util-body-length-browser": "^2.0.1", - "@smithy/util-body-length-node": "^2.1.0", - "@smithy/util-defaults-mode-browser": "^2.0.24", - "@smithy/util-defaults-mode-node": "^2.0.32", - "@smithy/util-endpoints": "^1.0.8", - "@smithy/util-retry": "^2.0.9", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/types": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.485.0.tgz", - "integrity": "sha512-+QW32YQdvZRDOwrAQPo/qCyXoSjgXB6RwJwCwkd8ebJXRXw6tmGKIHaZqYHt/LtBymvnaBgBBADNa4+qFvlOFw==", - "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/util-arn-parser": { - "version": "3.568.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-arn-parser/-/util-arn-parser-3.568.0.tgz", - "integrity": "sha512-XUKJWWo+KOB7fbnPP0+g/o5Ulku/X53t7i/h+sPHr5xxYTJJ9CYnbToo95mzxe7xWvkLrsNtJ8L+MnNn9INs2w==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/util-endpoints": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-endpoints/-/util-endpoints-3.485.0.tgz", - "integrity": "sha512-dTd642F7nJisApF8YjniqQ6U59CP/DCtar11fXf1nG9YNBCBsNNVw5ZfZb5nSNzaIdy27mQioWTCV18JEj1mxg==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/util-endpoints": "^1.0.8", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/util-locate-window": { - "version": "3.465.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-locate-window/-/util-locate-window-3.465.0.tgz", - "integrity": "sha512-f+QNcWGswredzC1ExNAB/QzODlxwaTdXkNT5cvke2RLX8SFU5pYk6h4uCtWC0vWPELzOfMfloBrJefBzlarhsw==", - "dependencies": { - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@aws-sdk/util-user-agent-browser": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-browser/-/util-user-agent-browser-3.485.0.tgz", - "integrity": "sha512-QliWbjg0uOhGTcWgWTKPMY0SBi07g253DjwrCINT1auqDrdQPxa10xozpZExBYjAK2KuhYDNUzni127ae6MHOw==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/types": "^2.8.0", - "bowser": "^2.11.0", - "tslib": "^2.5.0" - } - }, - "node_modules/@aws-sdk/util-user-agent-node": { - "version": "3.485.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-node/-/util-user-agent-node-3.485.0.tgz", - "integrity": "sha512-QF+aQ9jnDlPUlFBxBRqOylPf86xQuD3aEPpOErR+50qJawVvKa94uiAFdvtI9jv6hnRZmuFsTj2rsyytnbAYBA==", - "dependencies": { - "@aws-sdk/types": "3.485.0", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "aws-crt": ">=1.0.0" - }, - "peerDependenciesMeta": { - "aws-crt": { - "optional": true - } - } - }, - "node_modules/@aws-sdk/util-utf8-browser": { - "version": "3.259.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-utf8-browser/-/util-utf8-browser-3.259.0.tgz", - "integrity": "sha512-UvFa/vR+e19XookZF8RzFZBrw2EUkQWxiBW0yYQAhvk3C+QVGl0H3ouca8LDBlBfQKXwmW3huo/59H8rwb1wJw==", - "dependencies": { - "tslib": "^2.3.1" - } - }, - "node_modules/@aws-sdk/xml-builder": { - "version": "3.609.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/xml-builder/-/xml-builder-3.609.0.tgz", - "integrity": "sha512-l9XxNcA4HX98rwCC2/KoiWcmEiRfZe4G+mYwDbCFT87JIMj6GBhLDkAzr/W8KAaA2IDr8Vc6J8fZPgVulxxfMA==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@aws-sdk/xml-builder/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@babel/code-frame": { - "version": "7.23.5", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.23.5.tgz", - "integrity": "sha512-CgH3s1a96LipHCmSUmYFPwY7MNx8C3avkq7i4Wl3cfa662ldtUe4VM1TPXX70pfmrlWTb6jLqTYrZyT2ZTJBgA==", - "dependencies": { - "@babel/highlight": "^7.23.4", - "chalk": "^2.4.2" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/compat-data": { - "version": "7.23.5", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.23.5.tgz", - "integrity": "sha512-uU27kfDRlhfKl+w1U6vp16IuvSLtjAxdArVXPa9BvLkrr7CYIsxH5adpHObeAGY/41+syctUWOZ140a2Rvkgjw==", - "dev": true, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/core": { - "version": "7.23.7", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.23.7.tgz", - "integrity": "sha512-+UpDgowcmqe36d4NwqvKsyPMlOLNGMsfMmQ5WGCu+siCe3t3dfe9njrzGfdN4qq+bcNUt0+Vw6haRxBOycs4dw==", - "dev": true, - "dependencies": { - "@ampproject/remapping": "^2.2.0", - "@babel/code-frame": "^7.23.5", - "@babel/generator": "^7.23.6", - "@babel/helper-compilation-targets": "^7.23.6", - "@babel/helper-module-transforms": "^7.23.3", - "@babel/helpers": "^7.23.7", - "@babel/parser": "^7.23.6", - "@babel/template": "^7.22.15", - "@babel/traverse": "^7.23.7", - "@babel/types": "^7.23.6", - "convert-source-map": "^2.0.0", - "debug": "^4.1.0", - "gensync": "^1.0.0-beta.2", - "json5": "^2.2.3", - "semver": "^6.3.1" - }, - "engines": { - "node": ">=6.9.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/babel" - } - }, - "node_modules/@babel/core/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "bin": { - "semver": "bin/semver.js" - } - }, - "node_modules/@babel/generator": { - "version": "7.23.6", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.6.tgz", - "integrity": "sha512-qrSfCYxYQB5owCmGLbl8XRpX1ytXlpueOb0N0UmQwA073KZxejgQTzAmJezxvpwQD9uGtK2shHdi55QT+MbjIw==", - "dev": true, - "dependencies": { - "@babel/types": "^7.23.6", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", - "jsesc": "^2.5.1" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/generator/node_modules/jsesc": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "dev": true, - "bin": { - "jsesc": "bin/jsesc" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/helper-compilation-targets": { - "version": "7.23.6", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.23.6.tgz", - "integrity": "sha512-9JB548GZoQVmzrFgp8o7KxdgkTGm6xs9DW0o/Pim72UDjzr5ObUQ6ZzYPqA+g9OTS2bBQoctLJrky0RDCAWRgQ==", - "dev": true, - "dependencies": { - "@babel/compat-data": "^7.23.5", - "@babel/helper-validator-option": "^7.23.5", - "browserslist": "^4.22.2", - "lru-cache": "^5.1.1", - "semver": "^6.3.1" - }, - "engines": { - "node": ">=6.9.0" + "node": ">=6.9.0" } }, "node_modules/@babel/helper-compilation-targets/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/@babel/helper-environment-visitor": { "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz", - "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-function-name": { "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz", - "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/template": "^7.22.15", "@babel/types": "^7.23.0" @@ -3912,9 +1673,8 @@ }, "node_modules/@babel/helper-hoist-variables": { "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", - "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.22.5" }, @@ -3924,9 +1684,8 @@ }, "node_modules/@babel/helper-module-imports": { "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.22.15.tgz", - "integrity": "sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.22.15" }, @@ -3936,9 +1695,8 @@ }, "node_modules/@babel/helper-module-transforms": { "version": "7.23.3", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.23.3.tgz", - "integrity": "sha512-7bBs4ED9OmswdfDzpz4MpWgSrV7FXlc3zIagvLFjS5H+Mk7Snr21vQ6QwrsoCGMfNC4e4LQPdoULEt4ykz0SRQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-environment-visitor": "^7.22.20", "@babel/helper-module-imports": "^7.22.15", @@ -3955,18 +1713,16 @@ }, "node_modules/@babel/helper-plugin-utils": { "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.22.5.tgz", - "integrity": "sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-simple-access": { "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.22.5.tgz", - "integrity": "sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.22.5" }, @@ -3976,9 +1732,8 @@ }, "node_modules/@babel/helper-split-export-declaration": { "version": "7.22.6", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz", - "integrity": "sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.22.5" }, @@ -3988,35 +1743,31 @@ }, "node_modules/@babel/helper-string-parser": { "version": "7.23.4", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.23.4.tgz", - "integrity": "sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-identifier": { "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz", - "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==", + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-option": { "version": "7.23.5", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.23.5.tgz", - "integrity": "sha512-85ttAOMLsr53VgXkTbkx8oA6YTfT4q7/HzXSLEYmjcSTJPMPQtvq1BD79Byep5xMUYbGRzEpDsjUf3dyp54IKw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helpers": { "version": "7.23.8", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.23.8.tgz", - "integrity": "sha512-KDqYz4PiOWvDFrdHLPhKtCThtIcKVy6avWD2oG4GEvyQ+XDZwHD4YQd+H2vNMnq2rkdxsDkU82T+Vk8U/WXHRQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/template": "^7.22.15", "@babel/traverse": "^7.23.7", @@ -4028,8 +1779,7 @@ }, "node_modules/@babel/highlight": { "version": "7.23.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.23.4.tgz", - "integrity": "sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A==", + "license": "MIT", "dependencies": { "@babel/helper-validator-identifier": "^7.22.20", "chalk": "^2.4.2", @@ -4041,9 +1791,8 @@ }, "node_modules/@babel/parser": { "version": "7.23.6", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.6.tgz", - "integrity": "sha512-Z2uID7YJ7oNvAI20O9X0bblw7Qqs8Q2hFy0R9tAfnfLkp5MW0UH9eUvnDSnFwKZ0AvgS1ucqR4KzvVHgnke1VQ==", "dev": true, + "license": "MIT", "bin": { "parser": "bin/babel-parser.js" }, @@ -4053,9 +1802,8 @@ }, "node_modules/@babel/plugin-syntax-async-generators": { "version": "7.8.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", - "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4065,9 +1813,8 @@ }, "node_modules/@babel/plugin-syntax-bigint": { "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz", - "integrity": "sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4077,9 +1824,8 @@ }, "node_modules/@babel/plugin-syntax-class-properties": { "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", - "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.12.13" }, @@ -4089,9 +1835,8 @@ }, "node_modules/@babel/plugin-syntax-import-meta": { "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", - "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.10.4" }, @@ -4101,9 +1846,8 @@ }, "node_modules/@babel/plugin-syntax-json-strings": { "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", - "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4113,9 +1857,8 @@ }, "node_modules/@babel/plugin-syntax-jsx": { "version": "7.23.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.23.3.tgz", - "integrity": "sha512-EB2MELswq55OHUoRZLGg/zC7QWUKfNLpE57m/S2yr1uEneIgsTgrSzXP3NXEsMkVn76OlaVVnzN+ugObuYGwhg==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.22.5" }, @@ -4128,9 +1871,8 @@ }, "node_modules/@babel/plugin-syntax-logical-assignment-operators": { "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", - "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.10.4" }, @@ -4140,9 +1882,8 @@ }, "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", - "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4152,9 +1893,8 @@ }, "node_modules/@babel/plugin-syntax-numeric-separator": { "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", - "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.10.4" }, @@ -4164,9 +1904,8 @@ }, "node_modules/@babel/plugin-syntax-object-rest-spread": { "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", - "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4176,9 +1915,8 @@ }, "node_modules/@babel/plugin-syntax-optional-catch-binding": { "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", - "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4188,9 +1926,8 @@ }, "node_modules/@babel/plugin-syntax-optional-chaining": { "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", - "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" }, @@ -4200,9 +1937,8 @@ }, "node_modules/@babel/plugin-syntax-top-level-await": { "version": "7.14.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", - "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.14.5" }, @@ -4215,9 +1951,8 @@ }, "node_modules/@babel/plugin-syntax-typescript": { "version": "7.23.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.23.3.tgz", - "integrity": "sha512-9EiNjVJOMwCO+43TqoTrgQ8jMwcAd0sWyXi9RPfIsLTj4R2MADDDQXELhffaUx/uJv2AYcxBgPwH6j4TIA4ytQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.22.5" }, @@ -4230,9 +1965,8 @@ }, "node_modules/@babel/template": { "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.15.tgz", - "integrity": "sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==", "dev": true, + "license": "MIT", "dependencies": { "@babel/code-frame": "^7.22.13", "@babel/parser": "^7.22.15", @@ -4244,9 +1978,8 @@ }, "node_modules/@babel/traverse": { "version": "7.23.7", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.7.tgz", - "integrity": "sha512-tY3mM8rH9jM0YHFGyfC0/xf+SB5eKUu7HPj7/k3fpi9dAlsMc5YbQvDi0Sh2QTPXqMhyaAtzAr807TIyfQrmyg==", "dev": true, + "license": "MIT", "dependencies": { "@babel/code-frame": "^7.23.5", "@babel/generator": "^7.23.6", @@ -4265,18 +1998,16 @@ }, "node_modules/@babel/traverse/node_modules/globals": { "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/@babel/types": { "version": "7.23.6", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.6.tgz", - "integrity": "sha512-+uarb83brBzPKN38NX1MkB6vb6+mwvR6amUulqAE7ccQw1pEl+bCia9TbdG1lsnFP7lZySvUn37CHyXQdfTwzg==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-string-parser": "^7.23.4", "@babel/helper-validator-identifier": "^7.22.20", @@ -4288,22 +2019,19 @@ }, "node_modules/@bcoe/v8-coverage": { "version": "0.2.3", - "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz", - "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@bugsnag/browser": { "version": "7.22.3", - "resolved": "https://registry.npmjs.org/@bugsnag/browser/-/browser-7.22.3.tgz", - "integrity": "sha512-TWQSdsCqzxEVmaKzbtmqoBLWF58yjXi/ScC+6L5VNgSj+62jkIQuw5Evjs+7kLQX8WCnaG6XLiDmUJmPx6ZUrA==", + "license": "MIT", "dependencies": { "@bugsnag/core": "^7.19.0" } }, "node_modules/@bugsnag/core": { "version": "7.19.0", - "resolved": "https://registry.npmjs.org/@bugsnag/core/-/core-7.19.0.tgz", - "integrity": "sha512-2KGwdaLD9PhR7Wk7xPi3jGuGsKTatc/28U4TOZIDU3CgC2QhGjubwiXSECel5gwxhZ3jACKcMKSV2ovHhv1NrA==", + "license": "MIT", "dependencies": { "@bugsnag/cuid": "^3.0.0", "@bugsnag/safe-json-stringify": "^6.0.0", @@ -4314,13 +2042,11 @@ }, "node_modules/@bugsnag/cuid": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@bugsnag/cuid/-/cuid-3.0.2.tgz", - "integrity": "sha512-cIwzC93r3PQ/INeuwtZwkZIG2K8WWN0rRLZQhu+mr48Ay+i6sEki4GYfTsflse7hZ1BeDWrNb/Q9vgY3B31xHQ==" + "license": "MIT" }, "node_modules/@bugsnag/js": { "version": "7.22.3", - "resolved": "https://registry.npmjs.org/@bugsnag/js/-/js-7.22.3.tgz", - "integrity": "sha512-SAZEElVlmQgZBPLbTdMAyFD2Pp1mP4t3bv+GmDVGSgBi4W6doKQVk0J/K9f5+JGw8fEh9AJHRlyub3XnlGI6Zw==", + "license": "MIT", "dependencies": { "@bugsnag/browser": "^7.22.3", "@bugsnag/node": "^7.22.3" @@ -4328,8 +2054,7 @@ }, "node_modules/@bugsnag/node": { "version": "7.22.3", - "resolved": "https://registry.npmjs.org/@bugsnag/node/-/node-7.22.3.tgz", - "integrity": "sha512-vDXu0mrduonyCjUkTp+zKSh1WHAtA2VjB49xK5s1f/HnTASiJvzUOQBRXrkqaj37sndYHUSMxUCPvLawyc75nA==", + "license": "MIT", "dependencies": { "@bugsnag/core": "^7.19.0", "byline": "^5.0.0", @@ -4341,22 +2066,19 @@ }, "node_modules/@bugsnag/safe-json-stringify": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/@bugsnag/safe-json-stringify/-/safe-json-stringify-6.0.0.tgz", - "integrity": "sha512-htzFO1Zc57S8kgdRK9mLcPVTW1BY2ijfH7Dk2CeZmspTWKdKqSo1iwmqrq2WtRjFlo8aRZYgLX0wFrDXF/9DLA==" + "license": "MIT" }, "node_modules/@colors/colors": { "version": "1.6.0", - "resolved": "https://registry.npmjs.org/@colors/colors/-/colors-1.6.0.tgz", - "integrity": "sha512-Ir+AOibqzrIsL6ajt3Rz3LskB7OiMVHqltZmspbW/TJuTVuyOMirVqAkjfY6JISiLHgyNqicAC8AyHHGzNd/dA==", + "license": "MIT", "engines": { "node": ">=0.1.90" } }, "node_modules/@commitlint/cli": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/cli/-/cli-17.8.1.tgz", - "integrity": "sha512-ay+WbzQesE0Rv4EQKfNbSMiJJ12KdKTDzIt0tcK4k11FdsWmtwP0Kp1NWMOUswfIWo6Eb7p7Ln721Nx9FLNBjg==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/format": "^17.8.1", "@commitlint/lint": "^17.8.1", @@ -4378,9 +2100,8 @@ }, "node_modules/@commitlint/cli/node_modules/@commitlint/config-validator": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/config-validator/-/config-validator-17.8.1.tgz", - "integrity": "sha512-UUgUC+sNiiMwkyiuIFR7JG2cfd9t/7MV8VB4TZ+q02ZFkHoduUS4tJGsCBWvBOGD9Btev6IecPMvlWUfJorkEA==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/types": "^17.8.1", "ajv": "^8.11.0" @@ -4391,18 +2112,16 @@ }, "node_modules/@commitlint/cli/node_modules/@commitlint/execute-rule": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/execute-rule/-/execute-rule-17.8.1.tgz", - "integrity": "sha512-JHVupQeSdNI6xzA9SqMF+p/JjrHTcrJdI02PwesQIDCIGUrv04hicJgCcws5nzaoZbROapPs0s6zeVHoxpMwFQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=v14" } }, "node_modules/@commitlint/cli/node_modules/@commitlint/load": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/load/-/load-17.8.1.tgz", - "integrity": "sha512-iF4CL7KDFstP1kpVUkT8K2Wl17h2yx9VaR1ztTc8vzByWWcbO/WaKwxsnCOqow9tVAlzPfo1ywk9m2oJ9ucMqA==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/config-validator": "^17.8.1", "@commitlint/execute-rule": "^17.8.1", @@ -4425,9 +2144,8 @@ }, "node_modules/@commitlint/cli/node_modules/@commitlint/resolve-extends": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/resolve-extends/-/resolve-extends-17.8.1.tgz", - "integrity": "sha512-W/ryRoQ0TSVXqJrx5SGkaYuAaE/BUontL1j1HsKckvM6e5ZaG0M9126zcwL6peKSuIetJi7E87PRQF8O86EW0Q==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/config-validator": "^17.8.1", "@commitlint/types": "^17.8.1", @@ -4442,9 +2160,8 @@ }, "node_modules/@commitlint/cli/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -4454,15 +2171,13 @@ }, "node_modules/@commitlint/cli/node_modules/@types/node": { "version": "20.5.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.5.1.tgz", - "integrity": "sha512-4tT2UrL5LBqDwoed9wZ6N3umC4Yhz3W3FloMmiiG4JwmUJWpie0c7lcnUNd4gtMKuDEO4wRVS8B6Xa0uMRsMKg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/cli/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -4475,9 +2190,8 @@ }, "node_modules/@commitlint/cli/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -4491,9 +2205,8 @@ }, "node_modules/@commitlint/cli/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -4503,15 +2216,13 @@ }, "node_modules/@commitlint/cli/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/cli/node_modules/cosmiconfig-typescript-loader": { "version": "4.4.0", - "resolved": "https://registry.npmjs.org/cosmiconfig-typescript-loader/-/cosmiconfig-typescript-loader-4.4.0.tgz", - "integrity": "sha512-BabizFdC3wBHhbI4kJh0VkQP9GkBfoHPydD0COMce1nJ1kJAB3F2TmJ/I7diULBKtmEWSwEbuN/KDtgnmUUVmw==", "dev": true, + "license": "MIT", "engines": { "node": ">=v14.21.3" }, @@ -4524,18 +2235,16 @@ }, "node_modules/@commitlint/cli/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/cli/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -4545,9 +2254,8 @@ }, "node_modules/@commitlint/config-conventional": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/config-conventional/-/config-conventional-17.8.1.tgz", - "integrity": "sha512-NxCOHx1kgneig3VLauWJcDWS40DVjg7nKOpBEEK9E5fjJpQqLCilcnKkIIjdBH98kEO1q3NpE5NSrZ2kl/QGJg==", "dev": true, + "license": "MIT", "dependencies": { "conventional-changelog-conventionalcommits": "^6.1.0" }, @@ -4557,9 +2265,8 @@ }, "node_modules/@commitlint/config-validator": { "version": "18.4.4", - "resolved": "https://registry.npmjs.org/@commitlint/config-validator/-/config-validator-18.4.4.tgz", - "integrity": "sha512-/QI8KIg/h7O0Eus36fPcEcO3QPBcdXuGfZeCF5m15k0EB2bcU8s6pHNTNEa6xz9PrAefHCL+yzRJj7w20T6Mow==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "@commitlint/types": "^18.4.4", @@ -4571,9 +2278,8 @@ }, "node_modules/@commitlint/ensure": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/ensure/-/ensure-17.8.1.tgz", - "integrity": "sha512-xjafwKxid8s1K23NFpL8JNo6JnY/ysetKo8kegVM7c8vs+kWLP8VrQq+NbhgVlmCojhEDbzQKp4eRXSjVOGsow==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/types": "^17.8.1", "lodash.camelcase": "^4.3.0", @@ -4588,9 +2294,8 @@ }, "node_modules/@commitlint/ensure/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -4600,9 +2305,8 @@ }, "node_modules/@commitlint/ensure/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -4615,9 +2319,8 @@ }, "node_modules/@commitlint/ensure/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -4631,9 +2334,8 @@ }, "node_modules/@commitlint/ensure/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -4643,24 +2345,21 @@ }, "node_modules/@commitlint/ensure/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/ensure/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/ensure/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -4670,9 +2369,8 @@ }, "node_modules/@commitlint/execute-rule": { "version": "18.4.4", - "resolved": "https://registry.npmjs.org/@commitlint/execute-rule/-/execute-rule-18.4.4.tgz", - "integrity": "sha512-a37Nd3bDQydtg9PCLLWM9ZC+GO7X5i4zJvrggJv5jBhaHsXeQ9ZWdO6ODYR+f0LxBXXNYK3geYXJrCWUCP8JEg==", "dev": true, + "license": "MIT", "optional": true, "engines": { "node": ">=v18" @@ -4680,9 +2378,8 @@ }, "node_modules/@commitlint/format": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/format/-/format-17.8.1.tgz", - "integrity": "sha512-f3oMTyZ84M9ht7fb93wbCKmWxO5/kKSbwuYvS867duVomoOsgrgljkGGIztmT/srZnaiGbaK8+Wf8Ik2tSr5eg==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/types": "^17.8.1", "chalk": "^4.1.0" @@ -4693,9 +2390,8 @@ }, "node_modules/@commitlint/format/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -4705,9 +2401,8 @@ }, "node_modules/@commitlint/format/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -4720,9 +2415,8 @@ }, "node_modules/@commitlint/format/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -4736,9 +2430,8 @@ }, "node_modules/@commitlint/format/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -4748,24 +2441,21 @@ }, "node_modules/@commitlint/format/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/format/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/format/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -4775,9 +2465,8 @@ }, "node_modules/@commitlint/is-ignored": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/is-ignored/-/is-ignored-17.8.1.tgz", - "integrity": "sha512-UshMi4Ltb4ZlNn4F7WtSEugFDZmctzFpmbqvpyxD3la510J+PLcnyhf9chs7EryaRFJMdAKwsEKfNK0jL/QM4g==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/types": "^17.8.1", "semver": "7.5.4" @@ -4788,9 +2477,8 @@ }, "node_modules/@commitlint/is-ignored/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -4800,9 +2488,8 @@ }, "node_modules/@commitlint/is-ignored/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -4815,9 +2502,8 @@ }, "node_modules/@commitlint/is-ignored/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -4831,9 +2517,8 @@ }, "node_modules/@commitlint/is-ignored/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -4843,24 +2528,21 @@ }, "node_modules/@commitlint/is-ignored/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/is-ignored/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/is-ignored/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -4870,9 +2552,8 @@ }, "node_modules/@commitlint/lint": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/lint/-/lint-17.8.1.tgz", - "integrity": "sha512-aQUlwIR1/VMv2D4GXSk7PfL5hIaFSfy6hSHV94O8Y27T5q+DlDEgd/cZ4KmVI+MWKzFfCTiTuWqjfRSfdRllCA==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/is-ignored": "^17.8.1", "@commitlint/parse": "^17.8.1", @@ -4885,9 +2566,8 @@ }, "node_modules/@commitlint/lint/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -4897,9 +2577,8 @@ }, "node_modules/@commitlint/lint/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -4912,9 +2591,8 @@ }, "node_modules/@commitlint/lint/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -4928,9 +2606,8 @@ }, "node_modules/@commitlint/lint/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -4940,24 +2617,21 @@ }, "node_modules/@commitlint/lint/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/lint/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/lint/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -4967,9 +2641,8 @@ }, "node_modules/@commitlint/load": { "version": "18.4.4", - "resolved": "https://registry.npmjs.org/@commitlint/load/-/load-18.4.4.tgz", - "integrity": "sha512-RaDIa9qwOw2xRJ3Jr2DBXd14rmnHJIX2XdZF4kmoF1rgsg/+7cvrExLSUNAkQUNimyjCn1b/bKX2Omm+GdY0XQ==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "@commitlint/config-validator": "^18.4.4", @@ -4990,9 +2663,8 @@ }, "node_modules/@commitlint/load/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "color-convert": "^2.0.1" @@ -5006,9 +2678,8 @@ }, "node_modules/@commitlint/load/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "ansi-styles": "^4.1.0", @@ -5023,9 +2694,8 @@ }, "node_modules/@commitlint/load/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "color-name": "~1.1.4" @@ -5036,16 +2706,14 @@ }, "node_modules/@commitlint/load/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true, + "license": "MIT", "optional": true }, "node_modules/@commitlint/load/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "optional": true, "engines": { "node": ">=8" @@ -5053,9 +2721,8 @@ }, "node_modules/@commitlint/load/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "has-flag": "^4.0.0" @@ -5066,18 +2733,16 @@ }, "node_modules/@commitlint/message": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/message/-/message-17.8.1.tgz", - "integrity": "sha512-6bYL1GUQsD6bLhTH3QQty8pVFoETfFQlMn2Nzmz3AOLqRVfNNtXBaSY0dhZ0dM6A2MEq4+2d7L/2LP8TjqGRkA==", "dev": true, + "license": "MIT", "engines": { "node": ">=v14" } }, "node_modules/@commitlint/parse": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/parse/-/parse-17.8.1.tgz", - "integrity": "sha512-/wLUickTo0rNpQgWwLPavTm7WbwkZoBy3X8PpkUmlSmQJyWQTj0m6bDjiykMaDt41qcUbfeFfaCvXfiR4EGnfw==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/types": "^17.8.1", "conventional-changelog-angular": "^6.0.0", @@ -5089,9 +2754,8 @@ }, "node_modules/@commitlint/parse/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -5101,9 +2765,8 @@ }, "node_modules/@commitlint/parse/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -5116,9 +2779,8 @@ }, "node_modules/@commitlint/parse/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -5132,9 +2794,8 @@ }, "node_modules/@commitlint/parse/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -5144,24 +2805,21 @@ }, "node_modules/@commitlint/parse/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/parse/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/parse/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -5171,9 +2829,8 @@ }, "node_modules/@commitlint/read": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/read/-/read-17.8.1.tgz", - "integrity": "sha512-Fd55Oaz9irzBESPCdMd8vWWgxsW3OWR99wOntBDHgf9h7Y6OOHjWEdS9Xzen1GFndqgyoaFplQS5y7KZe0kO2w==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/top-level": "^17.8.1", "@commitlint/types": "^17.8.1", @@ -5187,9 +2844,8 @@ }, "node_modules/@commitlint/read/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -5199,9 +2855,8 @@ }, "node_modules/@commitlint/read/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -5214,9 +2869,8 @@ }, "node_modules/@commitlint/read/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -5230,9 +2884,8 @@ }, "node_modules/@commitlint/read/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -5242,15 +2895,13 @@ }, "node_modules/@commitlint/read/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/read/node_modules/fs-extra": { "version": "11.2.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.2.0.tgz", - "integrity": "sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw==", "dev": true, + "license": "MIT", "dependencies": { "graceful-fs": "^4.2.0", "jsonfile": "^6.0.1", @@ -5262,18 +2913,16 @@ }, "node_modules/@commitlint/read/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/read/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -5283,9 +2932,8 @@ }, "node_modules/@commitlint/resolve-extends": { "version": "18.4.4", - "resolved": "https://registry.npmjs.org/@commitlint/resolve-extends/-/resolve-extends-18.4.4.tgz", - "integrity": "sha512-RRpIHSbRnFvmGifVk21Gqazf1QF/yeP+Kkg/e3PlkegcOKd/FGOXp/Kx9cvSO2K7ucSn4GD/oBvgasFoy+NCAw==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "@commitlint/config-validator": "^18.4.4", @@ -5301,9 +2949,8 @@ }, "node_modules/@commitlint/rules": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/rules/-/rules-17.8.1.tgz", - "integrity": "sha512-2b7OdVbN7MTAt9U0vKOYKCDsOvESVXxQmrvuVUZ0rGFMCrCPJWWP1GJ7f0lAypbDAhaGb8zqtdOr47192LBrIA==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/ensure": "^17.8.1", "@commitlint/message": "^17.8.1", @@ -5317,9 +2964,8 @@ }, "node_modules/@commitlint/rules/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -5329,9 +2975,8 @@ }, "node_modules/@commitlint/rules/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -5344,9 +2989,8 @@ }, "node_modules/@commitlint/rules/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -5360,9 +3004,8 @@ }, "node_modules/@commitlint/rules/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -5372,24 +3015,21 @@ }, "node_modules/@commitlint/rules/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@commitlint/rules/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@commitlint/rules/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -5399,18 +3039,16 @@ }, "node_modules/@commitlint/to-lines": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/to-lines/-/to-lines-17.8.1.tgz", - "integrity": "sha512-LE0jb8CuR/mj6xJyrIk8VLz03OEzXFgLdivBytoooKO5xLt5yalc8Ma5guTWobw998sbR3ogDd+2jed03CFmJA==", "dev": true, + "license": "MIT", "engines": { "node": ">=v14" } }, "node_modules/@commitlint/top-level": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/top-level/-/top-level-17.8.1.tgz", - "integrity": "sha512-l6+Z6rrNf5p333SHfEte6r+WkOxGlWK4bLuZKbtf/2TXRN+qhrvn1XE63VhD8Oe9oIHQ7F7W1nG2k/TJFhx2yA==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^5.0.0" }, @@ -5420,9 +3058,8 @@ }, "node_modules/@commitlint/types": { "version": "18.4.4", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-18.4.4.tgz", - "integrity": "sha512-/FykLtodD8gKs3+VNkAUwofu4LBHankclj+I8fB2jTRvG6PV7k/OUt4P+VbM7ip853qS4F0g7Z6hLNa6JeMcAQ==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "chalk": "^4.1.0" @@ -5433,9 +3070,8 @@ }, "node_modules/@commitlint/types/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "color-convert": "^2.0.1" @@ -5449,9 +3085,8 @@ }, "node_modules/@commitlint/types/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "ansi-styles": "^4.1.0", @@ -5466,9 +3101,8 @@ }, "node_modules/@commitlint/types/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "color-name": "~1.1.4" @@ -5479,16 +3113,14 @@ }, "node_modules/@commitlint/types/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true, + "license": "MIT", "optional": true }, "node_modules/@commitlint/types/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "optional": true, "engines": { "node": ">=8" @@ -5496,9 +3128,8 @@ }, "node_modules/@commitlint/types/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "has-flag": "^4.0.0" @@ -5509,9 +3140,8 @@ }, "node_modules/@cspotcode/source-map-support": { "version": "0.8.1", - "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", - "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/trace-mapping": "0.3.9" }, @@ -5521,9 +3151,8 @@ }, "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { "version": "0.3.9", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", - "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/resolve-uri": "^3.0.3", "@jridgewell/sourcemap-codec": "^1.4.10" @@ -5531,8 +3160,7 @@ }, "node_modules/@dabh/diagnostics": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@dabh/diagnostics/-/diagnostics-2.0.3.tgz", - "integrity": "sha512-hrlQOIi7hAfzsMqlGSFyVucrx38O+j6wiGOf//H2ecvIEqYN4ADBSS2iLMh5UFyDunCNniUIPk/q3riFv45xRA==", + "license": "MIT", "dependencies": { "colorspace": "1.1.x", "enabled": "2.0.x", @@ -5541,9 +3169,8 @@ }, "node_modules/@datadog/pprof": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/@datadog/pprof/-/pprof-3.2.0.tgz", - "integrity": "sha512-kOhWHCWB80djnMCr5KNKBAy1Ih/jK/PIj6yqnZwL1Wqni/h6IBPRUMhtIxcYJMRgsZVYrFXUV20AVXTZCzFokw==", "hasInstallScript": true, + "license": "Apache-2.0", "dependencies": { "delay": "^5.0.0", "node-gyp-build": "<4.0", @@ -5557,9 +3184,8 @@ }, "node_modules/@dependents/detective-less": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@dependents/detective-less/-/detective-less-3.0.2.tgz", - "integrity": "sha512-1YUvQ+e0eeTWAHoN8Uz2x2U37jZs6IGutiIE5LXId7cxfUGhtZjzxE06FdUiuiRrW+UE0vNCdSNPH2lY4dQCOQ==", "dev": true, + "license": "MIT", "dependencies": { "gonzales-pe": "^4.3.0", "node-source-walk": "^5.0.1" @@ -5570,9 +3196,8 @@ }, "node_modules/@digitalroute/cz-conventional-changelog-for-jira": { "version": "8.0.1", - "resolved": "https://registry.npmjs.org/@digitalroute/cz-conventional-changelog-for-jira/-/cz-conventional-changelog-for-jira-8.0.1.tgz", - "integrity": "sha512-I7uNQ2R5LnDYVhQ01sfNvaxqe1PutXyDl8Kltj4L8uDa1LTYqQgWWp3yEj3XYDNjhUjsAheHW0lsmF1oiAjWVg==", "dev": true, + "license": "MIT", "dependencies": { "boxen": "^5.1.2", "chalk": "^2.4.1", @@ -5593,8 +3218,7 @@ }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", - "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==", + "license": "MIT", "dependencies": { "eslint-visitor-keys": "^3.3.0" }, @@ -5607,16 +3231,14 @@ }, "node_modules/@eslint-community/regexpp": { "version": "4.10.0", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.10.0.tgz", - "integrity": "sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA==", + "license": "MIT", "engines": { "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, "node_modules/@eslint/eslintrc": { "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.4.tgz", - "integrity": "sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==", + "license": "MIT", "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", @@ -5637,8 +3259,7 @@ }, "node_modules/@eslint/eslintrc/node_modules/ajv": { "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", + "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.1", "fast-json-stable-stringify": "^2.0.0", @@ -5652,42 +3273,24 @@ }, "node_modules/@eslint/eslintrc/node_modules/json-schema-traverse": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==" + "license": "MIT" }, "node_modules/@eslint/js": { "version": "8.56.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.56.0.tgz", - "integrity": "sha512-gMsVel9D7f2HLkBma9VbtzZRehRogVRfbr++f06nL2vnCGCNlzOD+/MUov/F4p8myyAHspEhVobgjpX64q5m6A==", + "license": "MIT", "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, "node_modules/@ewoudenberg/difflib": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/@ewoudenberg/difflib/-/difflib-0.1.0.tgz", - "integrity": "sha512-OU5P5mJyD3OoWYMWY+yIgwvgNS9cFAU10f+DDuvtogcWQOoJIsQ4Hy2McSfUfhKjq8L0FuWVb4Rt7kgA+XK86A==", "dependencies": { "heap": ">= 0.2.0" } }, - "node_modules/@hapi/hoek": { - "version": "9.3.0", - "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", - "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" - }, - "node_modules/@hapi/topo": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", - "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", - "dependencies": { - "@hapi/hoek": "^9.0.0" - } - }, "node_modules/@humanwhocodes/config-array": { "version": "0.11.13", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.13.tgz", - "integrity": "sha512-JSBDMiDKSzQVngfRjOdFXgFfklaXI4K9nLF49Auh21lmBWRLIK3+xTErTWD4KU54pb6coM6ESE7Awz/FNU3zgQ==", + "license": "Apache-2.0", "dependencies": { "@humanwhocodes/object-schema": "^2.0.1", "debug": "^4.1.1", @@ -5699,8 +3302,7 @@ }, "node_modules/@humanwhocodes/module-importer": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", - "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", + "license": "Apache-2.0", "engines": { "node": ">=12.22" }, @@ -5711,28 +3313,24 @@ }, "node_modules/@humanwhocodes/object-schema": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-2.0.1.tgz", - "integrity": "sha512-dvuCeX5fC9dXgJn9t+X5atfmgQAzUOWqS1254Gh0m6i8wKd10ebXkfNKiRK+1GWi/yTvvLDHpoxLr0xxxeslWw==" + "license": "BSD-3-Clause" }, "node_modules/@hutson/parse-repository-url": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@hutson/parse-repository-url/-/parse-repository-url-3.0.2.tgz", - "integrity": "sha512-H9XAx3hc0BQHY6l+IFSWHDySypcXsvsuLhgYLUGywmJ5pswRVQJUHpOsobnLYp2ZUaUlKiKDrgWWhosOwAEM8Q==", "dev": true, + "license": "Apache-2.0", "engines": { "node": ">=6.9.0" } }, "node_modules/@ioredis/commands": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@ioredis/commands/-/commands-1.2.0.tgz", - "integrity": "sha512-Sx1pU8EM64o2BrqNpEO1CNLtKQwyhuXuqyfH7oGKCk+1a33d2r5saW8zNwm3j6BTExtjrv2BxTgzzkMwts6vGg==" + "license": "MIT" }, "node_modules/@isaacs/cliui": { "version": "8.0.2", - "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", - "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", "dev": true, + "license": "ISC", "dependencies": { "string-width": "^5.1.2", "string-width-cjs": "npm:string-width@^4.2.0", @@ -5747,9 +3345,8 @@ }, "node_modules/@isaacs/cliui/node_modules/ansi-regex": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", - "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -5759,9 +3356,8 @@ }, "node_modules/@isaacs/cliui/node_modules/ansi-styles": { "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", - "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -5771,15 +3367,13 @@ }, "node_modules/@isaacs/cliui/node_modules/emoji-regex": { "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@isaacs/cliui/node_modules/string-width": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", - "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", "dev": true, + "license": "MIT", "dependencies": { "eastasianwidth": "^0.2.0", "emoji-regex": "^9.2.2", @@ -5794,9 +3388,8 @@ }, "node_modules/@isaacs/cliui/node_modules/strip-ansi": { "version": "7.1.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", - "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-regex": "^6.0.1" }, @@ -5809,9 +3402,8 @@ }, "node_modules/@isaacs/cliui/node_modules/wrap-ansi": { "version": "8.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", - "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^6.1.0", "string-width": "^5.0.1", @@ -5826,9 +3418,8 @@ }, "node_modules/@istanbuljs/load-nyc-config": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz", - "integrity": "sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==", "dev": true, + "license": "ISC", "dependencies": { "camelcase": "^5.3.1", "find-up": "^4.1.0", @@ -5842,27 +3433,24 @@ }, "node_modules/@istanbuljs/load-nyc-config/node_modules/argparse": { "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, + "license": "MIT", "dependencies": { "sprintf-js": "~1.0.2" } }, "node_modules/@istanbuljs/load-nyc-config/node_modules/camelcase": { "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/@istanbuljs/load-nyc-config/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -5873,9 +3461,8 @@ }, "node_modules/@istanbuljs/load-nyc-config/node_modules/js-yaml": { "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", "dev": true, + "license": "MIT", "dependencies": { "argparse": "^1.0.7", "esprima": "^4.0.0" @@ -5886,9 +3473,8 @@ }, "node_modules/@istanbuljs/load-nyc-config/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -5898,9 +3484,8 @@ }, "node_modules/@istanbuljs/load-nyc-config/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -5913,9 +3498,8 @@ }, "node_modules/@istanbuljs/load-nyc-config/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -5925,18 +3509,16 @@ }, "node_modules/@istanbuljs/schema": { "version": "0.1.3", - "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", - "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@jest/console": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/console/-/console-29.7.0.tgz", - "integrity": "sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "@types/node": "*", @@ -5951,9 +3533,8 @@ }, "node_modules/@jest/console/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -5966,9 +3547,8 @@ }, "node_modules/@jest/console/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -5982,9 +3562,8 @@ }, "node_modules/@jest/console/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -5994,24 +3573,21 @@ }, "node_modules/@jest/console/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jest/console/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@jest/console/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -6021,9 +3597,8 @@ }, "node_modules/@jest/core": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.7.0.tgz", - "integrity": "sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg==", "dev": true, + "license": "MIT", "dependencies": { "@jest/console": "^29.7.0", "@jest/reporters": "^29.7.0", @@ -6068,9 +3643,8 @@ }, "node_modules/@jest/core/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -6083,9 +3657,8 @@ }, "node_modules/@jest/core/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -6099,9 +3672,8 @@ }, "node_modules/@jest/core/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -6111,24 +3683,21 @@ }, "node_modules/@jest/core/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jest/core/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@jest/core/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -6138,9 +3707,8 @@ }, "node_modules/@jest/environment": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.7.0.tgz", - "integrity": "sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/fake-timers": "^29.7.0", "@jest/types": "^29.6.3", @@ -6153,9 +3721,8 @@ }, "node_modules/@jest/expect": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.7.0.tgz", - "integrity": "sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ==", "dev": true, + "license": "MIT", "dependencies": { "expect": "^29.7.0", "jest-snapshot": "^29.7.0" @@ -6166,9 +3733,8 @@ }, "node_modules/@jest/expect-utils": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.7.0.tgz", - "integrity": "sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==", "dev": true, + "license": "MIT", "dependencies": { "jest-get-type": "^29.6.3" }, @@ -6178,9 +3744,8 @@ }, "node_modules/@jest/fake-timers": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.7.0.tgz", - "integrity": "sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "@sinonjs/fake-timers": "^10.0.2", @@ -6195,9 +3760,8 @@ }, "node_modules/@jest/globals": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/globals/-/globals-29.7.0.tgz", - "integrity": "sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ==", "dev": true, + "license": "MIT", "dependencies": { "@jest/environment": "^29.7.0", "@jest/expect": "^29.7.0", @@ -6210,9 +3774,8 @@ }, "node_modules/@jest/reporters": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.7.0.tgz", - "integrity": "sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg==", "dev": true, + "license": "MIT", "dependencies": { "@bcoe/v8-coverage": "^0.2.3", "@jest/console": "^29.7.0", @@ -6253,9 +3816,8 @@ }, "node_modules/@jest/reporters/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -6268,9 +3830,8 @@ }, "node_modules/@jest/reporters/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -6284,9 +3845,8 @@ }, "node_modules/@jest/reporters/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -6296,15 +3856,13 @@ }, "node_modules/@jest/reporters/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jest/reporters/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -6322,18 +3880,16 @@ }, "node_modules/@jest/reporters/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@jest/reporters/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -6343,9 +3899,8 @@ }, "node_modules/@jest/schemas": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", - "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", "dev": true, + "license": "MIT", "dependencies": { "@sinclair/typebox": "^0.27.8" }, @@ -6355,9 +3910,8 @@ }, "node_modules/@jest/source-map": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-29.6.3.tgz", - "integrity": "sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/trace-mapping": "^0.3.18", "callsites": "^3.0.0", @@ -6369,9 +3923,8 @@ }, "node_modules/@jest/test-result": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-29.7.0.tgz", - "integrity": "sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA==", "dev": true, + "license": "MIT", "dependencies": { "@jest/console": "^29.7.0", "@jest/types": "^29.6.3", @@ -6384,9 +3937,8 @@ }, "node_modules/@jest/test-sequencer": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz", - "integrity": "sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/test-result": "^29.7.0", "graceful-fs": "^4.2.9", @@ -6399,9 +3951,8 @@ }, "node_modules/@jest/transform": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-29.7.0.tgz", - "integrity": "sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/core": "^7.11.6", "@jest/types": "^29.6.3", @@ -6425,9 +3976,8 @@ }, "node_modules/@jest/transform/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -6440,9 +3990,8 @@ }, "node_modules/@jest/transform/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -6456,9 +4005,8 @@ }, "node_modules/@jest/transform/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -6468,24 +4016,21 @@ }, "node_modules/@jest/transform/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jest/transform/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@jest/transform/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -6495,9 +4040,8 @@ }, "node_modules/@jest/types": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", - "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/schemas": "^29.6.3", "@types/istanbul-lib-coverage": "^2.0.0", @@ -6512,9 +4056,8 @@ }, "node_modules/@jest/types/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -6527,9 +4070,8 @@ }, "node_modules/@jest/types/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -6543,9 +4085,8 @@ }, "node_modules/@jest/types/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -6555,24 +4096,21 @@ }, "node_modules/@jest/types/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jest/types/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/@jest/types/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -6582,9 +4120,8 @@ }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", - "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/set-array": "^1.0.1", "@jridgewell/sourcemap-codec": "^1.4.10", @@ -6596,33 +4133,29 @@ }, "node_modules/@jridgewell/resolve-uri": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz", - "integrity": "sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/set-array": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/sourcemap-codec": { "version": "1.4.15", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", - "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jridgewell/trace-mapping": { "version": "0.3.20", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.20.tgz", - "integrity": "sha512-R8LcPeWZol2zR8mmH3JeKQ6QRCFb7XgUhV9ZlGhHLGyg4wpPiPZNQOOWhFZhxKw8u//yTbNGI42Bx/3paXEQ+Q==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" @@ -6630,14 +4163,12 @@ }, "node_modules/@jsdevtools/ono": { "version": "7.1.3", - "resolved": "https://registry.npmjs.org/@jsdevtools/ono/-/ono-7.1.3.tgz", - "integrity": "sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@koa/router": { "version": "12.0.1", - "resolved": "https://registry.npmjs.org/@koa/router/-/router-12.0.1.tgz", - "integrity": "sha512-ribfPYfHb+Uw3b27Eiw6NPqjhIhTpVFzEWLwyc/1Xp+DCdwRRyIlAUODX+9bPARF6aQtUu1+/PHzdNvRzcs/+Q==", + "license": "MIT", "dependencies": { "debug": "^4.3.4", "http-errors": "^2.0.0", @@ -6651,8 +4182,7 @@ }, "node_modules/@mapbox/node-pre-gyp": { "version": "1.0.11", - "resolved": "https://registry.npmjs.org/@mapbox/node-pre-gyp/-/node-pre-gyp-1.0.11.tgz", - "integrity": "sha512-Yhlar6v9WQgUp/He7BdgzOz8lqMQ8sU+jkCq7Wx8Myc5YFJLbEe7lgui/V7G1qB1DJykHSGwreceSaD60Y0PUQ==", + "license": "BSD-3-Clause", "dependencies": { "detect-libc": "^2.0.0", "https-proxy-agent": "^5.0.0", @@ -6670,8 +4200,7 @@ }, "node_modules/@mapbox/node-pre-gyp/node_modules/make-dir": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", - "integrity": "sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw==", + "license": "MIT", "dependencies": { "semver": "^6.0.0" }, @@ -6684,21 +4213,18 @@ }, "node_modules/@mapbox/node-pre-gyp/node_modules/make-dir/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/@ndhoule/extend": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@ndhoule/extend/-/extend-2.0.0.tgz", - "integrity": "sha512-xb77tVVGDGwjy25a6RmBiiBQ9uvxhkG0OEpVkQ74oNFsy9u+4PGp5BIIblmJZmJBMgXiKxZtkr4GcmHCNVubBQ==" + "license": "MIT" }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", - "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "license": "MIT", "dependencies": { "@nodelib/fs.stat": "2.0.5", "run-parallel": "^1.1.9" @@ -6709,16 +4235,14 @@ }, "node_modules/@nodelib/fs.stat": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", - "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "license": "MIT", "engines": { "node": ">= 8" } }, "node_modules/@nodelib/fs.walk": { "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", - "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "license": "MIT", "dependencies": { "@nodelib/fs.scandir": "2.1.5", "fastq": "^1.6.0" @@ -6729,9 +4253,8 @@ }, "node_modules/@pkgjs/parseargs": { "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", - "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", "dev": true, + "license": "MIT", "optional": true, "engines": { "node": ">=14" @@ -6739,9 +4262,8 @@ }, "node_modules/@pkgr/core": { "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.1.1.tgz", - "integrity": "sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA==", "dev": true, + "license": "MIT", "engines": { "node": "^12.20.0 || ^14.18.0 || >=16.0.0" }, @@ -6751,28 +4273,23 @@ }, "node_modules/@protobufjs/aspromise": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz", - "integrity": "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/base64": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/base64/-/base64-1.1.2.tgz", - "integrity": "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/codegen": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@protobufjs/codegen/-/codegen-2.0.4.tgz", - "integrity": "sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/eventemitter": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz", - "integrity": "sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/fetch": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/fetch/-/fetch-1.1.0.tgz", - "integrity": "sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==", + "license": "BSD-3-Clause", "dependencies": { "@protobufjs/aspromise": "^1.1.1", "@protobufjs/inquire": "^1.1.0" @@ -6780,33 +4297,27 @@ }, "node_modules/@protobufjs/float": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@protobufjs/float/-/float-1.0.2.tgz", - "integrity": "sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/inquire": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/inquire/-/inquire-1.1.0.tgz", - "integrity": "sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/path": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/path/-/path-1.1.2.tgz", - "integrity": "sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/pool": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/pool/-/pool-1.1.0.tgz", - "integrity": "sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/utf8": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.0.tgz", - "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==" + "license": "BSD-3-Clause" }, "node_modules/@pyroscope/nodejs": { "version": "0.2.9", - "resolved": "https://registry.npmjs.org/@pyroscope/nodejs/-/nodejs-0.2.9.tgz", - "integrity": "sha512-pIw4pIqcNZTZxTUuV0OUI18UZEmx9lT2GaT75ny6FKVe2L1gxAwTCf5TKk8VsnUGY66buUkyaTHcTm7fy0BP/Q==", + "license": "Apache-2.0", "dependencies": { "axios": "^0.28.0", "debug": "^4.3.3", @@ -6821,8 +4332,7 @@ }, "node_modules/@pyroscope/nodejs/node_modules/axios": { "version": "0.28.1", - "resolved": "https://registry.npmjs.org/axios/-/axios-0.28.1.tgz", - "integrity": "sha512-iUcGA5a7p0mVb4Gm/sy+FSECNkPFT4y7wt6OM/CDpO/OnNCvSs3PoMG8ibrC9jRoGYU0gUK5pXVC4NPXq6lHRQ==", + "license": "MIT", "dependencies": { "follow-redirects": "^1.15.0", "form-data": "^4.0.0", @@ -6831,8 +4341,7 @@ }, "node_modules/@rudderstack/integrations-lib": { "version": "0.2.10", - "resolved": "https://registry.npmjs.org/@rudderstack/integrations-lib/-/integrations-lib-0.2.10.tgz", - "integrity": "sha512-PVlRIxO9PVYpR+UNm1qQt85wo0wO9oX0PvoC9XqzYO+C0PfRvkMqac8ghA5ytqeCYNfSIye7DtidaII5ZoCQCA==", + "license": "MIT", "dependencies": { "axios": "^1.4.0", "axios-mock-adapter": "^1.22.0", @@ -6851,14 +4360,12 @@ } }, "node_modules/@rudderstack/json-template-engine": { - "version": "0.17.1", - "resolved": "https://registry.npmjs.org/@rudderstack/json-template-engine/-/json-template-engine-0.17.1.tgz", - "integrity": "sha512-i8kSHSwkZenx2TX0rZtUcrxpebSrYSMQruW2YnxfoBk4ElAW6jGCopOPQlZ1+mqyv4J5h2mcdQyP/UzLGxvfDw==" + "version": "0.18.0", + "license": "MIT" }, "node_modules/@rudderstack/workflow-engine": { - "version": "0.8.12", - "resolved": "https://registry.npmjs.org/@rudderstack/workflow-engine/-/workflow-engine-0.8.12.tgz", - "integrity": "sha512-OgnJCWHcOQn6qQZEkCFsgacu+zOYp2OlzidWYmU+pUi8br9ukunoGRcqb0OJhJJI5imh7myhyrHdY3DKZWG12w==", + "version": "0.8.13", + "license": "MIT", "dependencies": { "@aws-crypto/sha256-js": "^5.2.0", "@rudderstack/json-template-engine": "^0.17.1", @@ -6868,33 +4375,13 @@ "yaml": "^2.4.3" } }, - "node_modules/@rudderstack/workflow-engine/node_modules/@aws-crypto/sha256-js": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-js/-/sha256-js-5.2.0.tgz", - "integrity": "sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA==", - "dependencies": { - "@aws-crypto/util": "^5.2.0", - "@aws-sdk/types": "^3.222.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@rudderstack/workflow-engine/node_modules/@aws-crypto/util": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", - "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", - "dependencies": { - "@aws-sdk/types": "^3.222.0", - "@smithy/util-utf8": "^2.0.0", - "tslib": "^2.6.2" - } + "node_modules/@rudderstack/workflow-engine/node_modules/@rudderstack/json-template-engine": { + "version": "0.17.1", + "license": "MIT" }, "node_modules/@shopify/jest-koa-mocks": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/@shopify/jest-koa-mocks/-/jest-koa-mocks-5.1.1.tgz", - "integrity": "sha512-H1dRznXIK03ph1l/VDBQ5ef+A9kkEn3ikNfk70zwm9auW15MfHfY9gekE99VecxUSekws7sbFte0i8ltWCS4/g==", + "license": "MIT", "dependencies": { "koa": "^2.13.4", "node-mocks-http": "^1.11.0" @@ -6903,242 +4390,97 @@ "node": "^14.17.0 || >=16.0.0" } }, - "node_modules/@sideway/address": { - "version": "4.1.4", - "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", - "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", - "dependencies": { - "@hapi/hoek": "^9.0.0" - } - }, - "node_modules/@sideway/formula": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", - "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" - }, - "node_modules/@sideway/pinpoint": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", - "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" - }, "node_modules/@sinclair/typebox": { "version": "0.27.8", - "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", - "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@sindresorhus/is": { "version": "0.7.0", - "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-0.7.0.tgz", - "integrity": "sha512-ONhaKPIufzzrlNbqtWFFd+jlnemX6lJAgq9ZeiZtS7I1PIf/la7CW4m83rTXRnVnsMbW2k56pGYu7AUFJD9Pow==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/@sinonjs/commons": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.0.tgz", - "integrity": "sha512-jXBtWAF4vmdNmZgD5FoKsVLv3rPgDnLgPbU84LIJ3otV44vJlDRokVng5v8NFJdCf/da9legHcKaRuZs4L7faA==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "type-detect": "4.0.8" } }, "node_modules/@sinonjs/fake-timers": { "version": "10.3.0", - "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz", - "integrity": "sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "@sinonjs/commons": "^3.0.0" } }, "node_modules/@smithy/abort-controller": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-2.0.16.tgz", - "integrity": "sha512-4foO7738k8kM9flMHu3VLabqu7nPgvIj8TB909S0CnKx0YZz/dcDH3pZ/4JHdatfxlZdKF1JWOYCw9+v3HVVsw==", - "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@smithy/chunked-blob-reader": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/chunked-blob-reader/-/chunked-blob-reader-3.0.0.tgz", - "integrity": "sha512-sbnURCwjF0gSToGlsBiAmd1lRCmSn72nu9axfJu5lIx6RUEgHu6GwTMbqCdhQSi0Pumcm5vFxsi9XWXb2mTaoA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - } - }, - "node_modules/@smithy/chunked-blob-reader-native": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/chunked-blob-reader-native/-/chunked-blob-reader-native-3.0.0.tgz", - "integrity": "sha512-VDkpCYW+peSuM4zJip5WDfqvg2Mo/e8yxOv3VF1m11y7B8KKMKVFtmZWDe36Fvk8rGuWrPZHHXZ7rR7uM5yWyg==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-base64": "^3.0.0", - "tslib": "^2.6.2" - } - }, - "node_modules/@smithy/chunked-blob-reader-native/node_modules/@smithy/is-array-buffer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@smithy/chunked-blob-reader-native/node_modules/@smithy/util-base64": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-3.0.0.tgz", - "integrity": "sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", - "@smithy/util-utf8": "^3.0.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@smithy/chunked-blob-reader-native/node_modules/@smithy/util-buffer-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", - "license": "Apache-2.0", + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.1.tgz", + "integrity": "sha512-MBJBiidoe+0cTFhyxT8g+9g7CeVccLM0IOKKUMCNQ1CNMJ/eIfoo0RTfVrXOONEI1UCN1W+zkiHSbzUNE9dZtQ==", "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/chunked-blob-reader-native/node_modules/@smithy/util-utf8": { + "node_modules/@smithy/chunked-blob-reader": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", "license": "Apache-2.0", "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@smithy/config-resolver": { - "version": "2.0.23", - "resolved": "https://registry.npmjs.org/@smithy/config-resolver/-/config-resolver-2.0.23.tgz", - "integrity": "sha512-XakUqgtP2YY8Mi+Nlif5BiqJgWdvfxJafSpOSQeCOMizu+PUhE4fBQSy6xFcR+eInrwVadaABNxoJyGUMn15ew==", - "dependencies": { - "@smithy/node-config-provider": "^2.1.9", - "@smithy/types": "^2.8.0", - "@smithy/util-config-provider": "^2.1.0", - "@smithy/util-middleware": "^2.0.9", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@smithy/core": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/@smithy/core/-/core-1.2.2.tgz", - "integrity": "sha512-uLjrskLT+mWb0emTR5QaiAIxVEU7ndpptDaVDrTwwhD+RjvHhjIiGQ3YL5jKk1a5VSDQUA2RGkXvJ6XKRcz6Dg==", - "dependencies": { - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-retry": "^2.0.26", - "@smithy/middleware-serde": "^2.0.16", - "@smithy/protocol-http": "^3.0.12", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/util-middleware": "^2.0.9", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@smithy/credential-provider-imds": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@smithy/credential-provider-imds/-/credential-provider-imds-2.1.5.tgz", - "integrity": "sha512-VfvE6Wg1MUWwpTZFBnUD7zxvPhLY8jlHCzu6bCjlIYoWgXCDzZAML76IlZUEf45nib3rjehnFgg0s1rgsuN/bg==", - "dependencies": { - "@smithy/node-config-provider": "^2.1.9", - "@smithy/property-provider": "^2.0.17", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@smithy/eventstream-codec": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-codec/-/eventstream-codec-2.0.16.tgz", - "integrity": "sha512-umYh5pdCE9GHgiMAH49zu9wXWZKNHHdKPm/lK22WYISTjqu29SepmpWNmPiBLy/yUu4HFEGJHIFrDWhbDlApaw==", - "dependencies": { - "@aws-crypto/crc32": "3.0.0", - "@smithy/types": "^2.8.0", - "@smithy/util-hex-encoding": "^2.0.0", - "tslib": "^2.5.0" } }, - "node_modules/@smithy/eventstream-serde-browser": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-browser/-/eventstream-serde-browser-3.0.4.tgz", - "integrity": "sha512-Eo4anLZX6ltGJTZ5yJMc80gZPYYwBn44g0h7oFq6et+TYr5dUsTpIcDbz2evsOKIZhZ7zBoFWHtBXQ4QQeb5xA==", + "node_modules/@smithy/chunked-blob-reader-native": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/eventstream-serde-universal": "^3.0.4", - "@smithy/types": "^3.3.0", + "@smithy/util-base64": "^3.0.0", "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-browser/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/config-resolver": { + "version": "3.0.5", "license": "Apache-2.0", "dependencies": { + "@smithy/node-config-provider": "^3.1.4", + "@smithy/types": "^3.3.0", + "@smithy/util-config-provider": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-config-resolver": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-config-resolver/-/eventstream-serde-config-resolver-3.0.3.tgz", - "integrity": "sha512-NVTYjOuYpGfrN/VbRQgn31x73KDLfCXCsFdad8DiIc3IcdxL+dYA9zEQPyOP7Fy2QL8CPy2WE4WCUD+ZsLNfaQ==", + "node_modules/@smithy/core": { + "version": "2.4.0", "license": "Apache-2.0", "dependencies": { + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-retry": "^3.0.15", + "@smithy/middleware-serde": "^3.0.3", + "@smithy/protocol-http": "^4.1.0", + "@smithy/smithy-client": "^3.2.0", "@smithy/types": "^3.3.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-config-resolver/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/core/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" @@ -7147,101 +4489,93 @@ "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-node": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-node/-/eventstream-serde-node-3.0.4.tgz", - "integrity": "sha512-mjlG0OzGAYuUpdUpflfb9zyLrBGgmQmrobNT8b42ZTsGv/J03+t24uhhtVEKG/b2jFtPIHF74Bq+VUtbzEKOKg==", + "node_modules/@smithy/core/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/eventstream-serde-universal": "^3.0.4", - "@smithy/types": "^3.3.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-node/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/core/node_modules/@smithy/util-utf8": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-universal": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-universal/-/eventstream-serde-universal-3.0.4.tgz", - "integrity": "sha512-Od9dv8zh3PgOD7Vj4T3HSuox16n0VG8jJIM2gvKASL6aCtcS8CfHZDWe1Ik3ZXW6xBouU+45Q5wgoliWDZiJ0A==", + "node_modules/@smithy/credential-provider-imds": { + "version": "3.2.0", "license": "Apache-2.0", "dependencies": { - "@smithy/eventstream-codec": "^3.1.2", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/property-provider": "^3.1.3", "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-universal/node_modules/@aws-crypto/crc32": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/crc32/-/crc32-5.2.0.tgz", - "integrity": "sha512-nLbCWqQNgUiwwtFsen1AdzAtvuLRsQS8rYgMuxCrdKf9kOssamGLuPwyTY9wyYblNr9+1XM8v6zoDTPPSIeANg==", + "node_modules/@smithy/eventstream-codec": { + "version": "3.1.2", "license": "Apache-2.0", "dependencies": { - "@aws-crypto/util": "^5.2.0", - "@aws-sdk/types": "^3.222.0", + "@aws-crypto/crc32": "5.2.0", + "@smithy/types": "^3.3.0", + "@smithy/util-hex-encoding": "^3.0.0", "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-universal/node_modules/@aws-crypto/util": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", - "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", + "node_modules/@smithy/eventstream-serde-browser": { + "version": "3.0.6", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "^3.222.0", - "@smithy/util-utf8": "^2.0.0", + "@smithy/eventstream-serde-universal": "^3.0.5", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-universal/node_modules/@smithy/eventstream-codec": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-codec/-/eventstream-codec-3.1.2.tgz", - "integrity": "sha512-0mBcu49JWt4MXhrhRAlxASNy0IjDRFU+aWNDRal9OtUJvJNiwDuyKMUONSOjLjSCeGwZaE0wOErdqULer8r7yw==", + "node_modules/@smithy/eventstream-serde-config-resolver": { + "version": "3.0.3", "license": "Apache-2.0", "dependencies": { - "@aws-crypto/crc32": "5.2.0", "@smithy/types": "^3.3.0", - "@smithy/util-hex-encoding": "^3.0.0", "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-universal/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/eventstream-serde-node": { + "version": "3.0.5", "license": "Apache-2.0", "dependencies": { + "@smithy/eventstream-serde-universal": "^3.0.5", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/eventstream-serde-universal/node_modules/@smithy/util-hex-encoding": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", - "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", + "node_modules/@smithy/eventstream-serde-universal": { + "version": "3.0.5", "license": "Apache-2.0", "dependencies": { + "@smithy/eventstream-codec": "^3.1.2", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { @@ -7249,21 +4583,19 @@ } }, "node_modules/@smithy/fetch-http-handler": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-2.3.2.tgz", - "integrity": "sha512-O9R/OlnAOTsnysuSDjt0v2q6DcSvCz5cCFC/CFAWWcLyBwJDeFyGTCTszgpQTb19+Fi8uRwZE5/3ziAQBFeDMQ==", - "dependencies": { - "@smithy/protocol-http": "^3.0.12", - "@smithy/querystring-builder": "^2.0.16", - "@smithy/types": "^2.8.0", - "@smithy/util-base64": "^2.0.1", - "tslib": "^2.5.0" + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-3.2.4.tgz", + "integrity": "sha512-kBprh5Gs5h7ug4nBWZi1FZthdqSM+T7zMmsZxx0IBvWUn7dK3diz2SHn7Bs4dQGFDk8plDv375gzenDoNwrXjg==", + "dependencies": { + "@smithy/protocol-http": "^4.1.0", + "@smithy/querystring-builder": "^3.0.3", + "@smithy/types": "^3.3.0", + "@smithy/util-base64": "^3.0.0", + "tslib": "^2.6.2" } }, "node_modules/@smithy/hash-blob-browser": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/hash-blob-browser/-/hash-blob-browser-3.1.2.tgz", - "integrity": "sha512-hAbfqN2UbISltakCC2TP0kx4LqXBttEv2MqSPE98gVuDFMf05lU+TpC41QtqGP3Ff5A3GwZMPfKnEy0VmEUpmg==", "license": "Apache-2.0", "dependencies": { "@smithy/chunked-blob-reader": "^3.0.0", @@ -7272,62 +4604,65 @@ "tslib": "^2.6.2" } }, - "node_modules/@smithy/hash-blob-browser/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/hash-node": { + "version": "3.0.3", "license": "Apache-2.0", "dependencies": { + "@smithy/types": "^3.3.0", + "@smithy/util-buffer-from": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/hash-node": { - "version": "2.0.18", - "resolved": "https://registry.npmjs.org/@smithy/hash-node/-/hash-node-2.0.18.tgz", - "integrity": "sha512-gN2JFvAgnZCyDN9rJgcejfpK0uPPJrSortVVVVWsru9whS7eQey6+gj2eM5ln2i6rHNntIXzal1Fm9XOPuoaKA==", + "node_modules/@smithy/hash-node/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^2.8.0", - "@smithy/util-buffer-from": "^2.0.0", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/hash-stream-node": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/hash-stream-node/-/hash-stream-node-3.1.2.tgz", - "integrity": "sha512-PBgDMeEdDzi6JxKwbfBtwQG9eT9cVwsf0dZzLXoJF4sHKHs5HEo/3lJWpn6jibfJwT34I1EBXpBnZE8AxAft6g==", + "node_modules/@smithy/hash-node/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^3.3.0", - "@smithy/util-utf8": "^3.0.0", + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/hash-stream-node/node_modules/@smithy/is-array-buffer": { + "node_modules/@smithy/hash-node/node_modules/@smithy/util-utf8": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", "license": "Apache-2.0", "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/hash-stream-node/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/hash-stream-node": { + "version": "3.1.2", + "license": "Apache-2.0", + "dependencies": { + "@smithy/types": "^3.3.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/hash-stream-node/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" @@ -7338,8 +4673,6 @@ }, "node_modules/@smithy/hash-stream-node/node_modules/@smithy/util-buffer-from": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", "license": "Apache-2.0", "dependencies": { "@smithy/is-array-buffer": "^3.0.0", @@ -7351,8 +4684,6 @@ }, "node_modules/@smithy/hash-stream-node/node_modules/@smithy/util-utf8": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", "license": "Apache-2.0", "dependencies": { "@smithy/util-buffer-from": "^3.0.0", @@ -7363,18 +4694,16 @@ } }, "node_modules/@smithy/invalid-dependency": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/invalid-dependency/-/invalid-dependency-2.0.16.tgz", - "integrity": "sha512-apEHakT/kmpNo1VFHP4W/cjfeP9U0x5qvfsLJubgp7UM/gq4qYp0GbqdE7QhsjUaYvEnrftRqs7+YrtWreV0wA==", + "version": "3.0.3", + "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" } }, "node_modules/@smithy/is-array-buffer": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-2.0.0.tgz", - "integrity": "sha512-z3PjFjMyZNI98JFRJi/U0nGoLWMSJlDjAW4QUX2WNZLas5C0CmVV6LJ01JI0k90l7FvpmixjWxPFmENSClQ7ug==", + "license": "Apache-2.0", "dependencies": { "tslib": "^2.5.0" }, @@ -7384,8 +4713,6 @@ }, "node_modules/@smithy/md5-js": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@smithy/md5-js/-/md5-js-3.0.3.tgz", - "integrity": "sha512-O/SAkGVwpWmelpj/8yDtsaVe6sINHLB1q8YE/+ZQbDxIw3SRLbTZuRaI10K12sVoENdnHqzPp5i3/H+BcZ3m3Q==", "license": "Apache-2.0", "dependencies": { "@smithy/types": "^3.3.0", @@ -7395,8 +4722,6 @@ }, "node_modules/@smithy/md5-js/node_modules/@smithy/is-array-buffer": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", - "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" @@ -7405,316 +4730,353 @@ "node": ">=16.0.0" } }, - "node_modules/@smithy/md5-js/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "node_modules/@smithy/md5-js/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", "license": "Apache-2.0", "dependencies": { + "@smithy/is-array-buffer": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/md5-js/node_modules/@smithy/util-buffer-from": { + "node_modules/@smithy/md5-js/node_modules/@smithy/util-utf8": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", - "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", "license": "Apache-2.0", "dependencies": { - "@smithy/is-array-buffer": "^3.0.0", + "@smithy/util-buffer-from": "^3.0.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/md5-js/node_modules/@smithy/util-utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", - "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", + "node_modules/@smithy/middleware-content-length": { + "version": "3.0.5", "license": "Apache-2.0", "dependencies": { - "@smithy/util-buffer-from": "^3.0.0", + "@smithy/protocol-http": "^4.1.0", + "@smithy/types": "^3.3.0", "tslib": "^2.6.2" }, "engines": { "node": ">=16.0.0" } }, - "node_modules/@smithy/middleware-content-length": { - "version": "2.0.18", - "resolved": "https://registry.npmjs.org/@smithy/middleware-content-length/-/middleware-content-length-2.0.18.tgz", - "integrity": "sha512-ZJ9uKPTfxYheTKSKYB+GCvcj+izw9WGzRLhjn8n254q0jWLojUzn7Vw0l4R/Gq7Wdpf/qmk/ptD+6CCXHNVCaw==", + "node_modules/@smithy/middleware-endpoint": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-3.1.0.tgz", + "integrity": "sha512-5y5aiKCEwg9TDPB4yFE7H6tYvGFf1OJHNczeY10/EFF8Ir8jZbNntQJxMWNfeQjC1mxPsaQ6mR9cvQbf+0YeMw==", "dependencies": { - "@smithy/protocol-http": "^3.0.12", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/middleware-serde": "^3.0.3", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/shared-ini-file-loader": "^3.1.4", + "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", + "@smithy/util-middleware": "^3.0.3", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/middleware-endpoint": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-2.3.0.tgz", - "integrity": "sha512-VsOAG2YQ8ykjSmKO+CIXdJBIWFo6AAvG6Iw95BakBTqk66/4BI7XyqLevoNSq/lZ6NgZv24sLmrcIN+fLDWBCg==", - "dependencies": { - "@smithy/middleware-serde": "^2.0.16", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/shared-ini-file-loader": "^2.2.8", - "@smithy/types": "^2.8.0", - "@smithy/url-parser": "^2.0.16", - "@smithy/util-middleware": "^2.0.9", - "tslib": "^2.5.0" + "node_modules/@smithy/middleware-retry": { + "version": "3.0.15", + "license": "Apache-2.0", + "dependencies": { + "@smithy/node-config-provider": "^3.1.4", + "@smithy/protocol-http": "^4.1.0", + "@smithy/service-error-classification": "^3.0.3", + "@smithy/smithy-client": "^3.2.0", + "@smithy/types": "^3.3.0", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-retry": "^3.0.3", + "tslib": "^2.6.2", + "uuid": "^9.0.1" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-serde": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-3.0.3.tgz", + "integrity": "sha512-puUbyJQBcg9eSErFXjKNiGILJGtiqmuuNKEYNYfUD57fUl4i9+mfmThtQhvFXU0hCVG0iEJhvQUipUf+/SsFdA==", + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-stack": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-3.0.3.tgz", + "integrity": "sha512-r4klY9nFudB0r9UdSMaGSyjyQK5adUyPnQN/ZM6M75phTxOdnc/AhpvGD1fQUvgmqjQEBGCwpnPbDm8pH5PapA==", + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/node-config-provider": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-3.1.4.tgz", + "integrity": "sha512-YvnElQy8HR4vDcAjoy7Xkx9YT8xZP4cBXcbJSgm/kxmiQu08DwUwj8rkGnyoJTpfl/3xYHH+d8zE+eHqoDCSdQ==", + "dependencies": { + "@smithy/property-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.4", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/node-http-handler": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-3.1.4.tgz", + "integrity": "sha512-+UmxgixgOr/yLsUxcEKGH0fMNVteJFGkmRltYFHnBMlogyFdpzn2CwqWmxOrfJELhV34v0WSlaqG1UtE1uXlJg==", + "dependencies": { + "@smithy/abort-controller": "^3.1.1", + "@smithy/protocol-http": "^4.1.0", + "@smithy/querystring-builder": "^3.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/property-provider": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-3.1.3.tgz", + "integrity": "sha512-zahyOVR9Q4PEoguJ/NrFP4O7SMAfYO1HLhB18M+q+Z4KFd4V2obiMnlVoUFzFLSPeVt1POyNWneHHrZaTMoc/g==", + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/middleware-retry": { - "version": "2.0.26", - "resolved": "https://registry.npmjs.org/@smithy/middleware-retry/-/middleware-retry-2.0.26.tgz", - "integrity": "sha512-Qzpxo0U5jfNiq9iD38U3e2bheXwvTEX4eue9xruIvEgh+UKq6dKuGqcB66oBDV7TD/mfoJi9Q/VmaiqwWbEp7A==", + "node_modules/@smithy/protocol-http": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.1.0.tgz", + "integrity": "sha512-dPVoHYQ2wcHooGXg3LQisa1hH0e4y0pAddPMeeUPipI1tEOqL6A4N0/G7abeq+K8wrwSgjk4C0wnD1XZpJm5aA==", "dependencies": { - "@smithy/node-config-provider": "^2.1.9", - "@smithy/protocol-http": "^3.0.12", - "@smithy/service-error-classification": "^2.0.9", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "@smithy/util-middleware": "^2.0.9", - "@smithy/util-retry": "^2.0.9", - "tslib": "^2.5.0", - "uuid": "^8.3.2" + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@smithy/middleware-retry/node_modules/uuid": { - "version": "8.3.2", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", - "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", - "bin": { - "uuid": "dist/bin/uuid" + "node": ">=16.0.0" } }, - "node_modules/@smithy/middleware-serde": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-2.0.16.tgz", - "integrity": "sha512-5EAd4t30pcc4M8TSSGq7q/x5IKrxfXR5+SrU4bgxNy7RPHQo2PSWBUco9C+D9Tfqp/JZvprRpK42dnupZafk2g==", + "node_modules/@smithy/querystring-builder": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-3.0.3.tgz", + "integrity": "sha512-vyWckeUeesFKzCDaRwWLUA1Xym9McaA6XpFfAK5qI9DKJ4M33ooQGqvM4J+LalH4u/Dq9nFiC8U6Qn1qi0+9zw==", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/types": "^3.3.0", + "@smithy/util-uri-escape": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/middleware-stack": { - "version": "2.0.10", - "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-2.0.10.tgz", - "integrity": "sha512-I2rbxctNq9FAPPEcuA1ntZxkTKOPQFy7YBPOaD/MLg1zCvzv21CoNxR0py6J8ZVC35l4qE4nhxB0f7TF5/+Ldw==", + "node_modules/@smithy/querystring-parser": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-3.0.3.tgz", + "integrity": "sha512-zahM1lQv2YjmznnfQsWbYojFe55l0SLG/988brlLv1i8z3dubloLF+75ATRsqPBboUXsW6I9CPGE5rQgLfY0vQ==", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/node-config-provider": { - "version": "2.1.9", - "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-2.1.9.tgz", - "integrity": "sha512-tUyW/9xrRy+s7RXkmQhgYkAPMpTIF8izK4orhHjNFEKR3QZiOCbWB546Y8iB/Fpbm3O9+q0Af9rpywLKJOwtaQ==", + "node_modules/@smithy/service-error-classification": { + "version": "3.0.3", + "license": "Apache-2.0", "dependencies": { - "@smithy/property-provider": "^2.0.17", - "@smithy/shared-ini-file-loader": "^2.2.8", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/types": "^3.3.0" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/node-http-handler": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-2.2.2.tgz", - "integrity": "sha512-XO58TO/Eul/IBQKFKaaBtXJi0ItEQQCT+NI4IiKHCY/4KtqaUT6y/wC1EvDqlA9cP7Dyjdj7FdPs4DyynH3u7g==", + "node_modules/@smithy/shared-ini-file-loader": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-3.1.4.tgz", + "integrity": "sha512-qMxS4hBGB8FY2GQqshcRUy1K6k8aBWP5vwm8qKkCT3A9K2dawUwOIJfqh9Yste/Bl0J2lzosVyrXDj68kLcHXQ==", "dependencies": { - "@smithy/abort-controller": "^2.0.16", - "@smithy/protocol-http": "^3.0.12", - "@smithy/querystring-builder": "^2.0.16", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/property-provider": { - "version": "2.0.17", - "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-2.0.17.tgz", - "integrity": "sha512-+VkeZbVu7qtQ2DjI48Qwaf9fPOr3gZIwxQpuLJgRRSkWsdSvmaTCxI3gzRFKePB63Ts9r4yjn4HkxSCSkdWmcQ==", + "node_modules/@smithy/signature-v4": { + "version": "4.1.0", + "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/is-array-buffer": "^3.0.0", + "@smithy/protocol-http": "^4.1.0", + "@smithy/types": "^3.3.0", + "@smithy/util-hex-encoding": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-uri-escape": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/protocol-http": { - "version": "3.0.12", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-3.0.12.tgz", - "integrity": "sha512-Xz4iaqLiaBfbQpB9Hgi3VcZYbP7xRDXYhd8XWChh4v94uw7qwmvlxdU5yxzfm6ACJM66phHrTbS5TVvj5uQ72w==", + "node_modules/@smithy/signature-v4/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/querystring-builder": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-2.0.16.tgz", - "integrity": "sha512-Q/GsJT0C0mijXMRs7YhZLLCP5FcuC4797lYjKQkME5CZohnLC4bEhylAd2QcD3gbMKNjCw8+T2I27WKiV/wToA==", + "node_modules/@smithy/signature-v4/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^2.8.0", - "@smithy/util-uri-escape": "^2.0.0", - "tslib": "^2.5.0" + "@smithy/is-array-buffer": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/querystring-parser": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-2.0.16.tgz", - "integrity": "sha512-c4ueAuL6BDYKWpkubjrQthZKoC3L5kql5O++ovekNxiexRXTlLIVlCR4q3KziOktLIw66EU9SQljPXd/oN6Okg==", + "node_modules/@smithy/signature-v4/node_modules/@smithy/util-utf8": { + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/util-buffer-from": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/service-error-classification": { - "version": "2.0.9", - "resolved": "https://registry.npmjs.org/@smithy/service-error-classification/-/service-error-classification-2.0.9.tgz", - "integrity": "sha512-0K+8GvtwI7VkGmmInPydM2XZyBfIqLIbfR7mDQ+oPiz8mIinuHbV6sxOLdvX1Jv/myk7XTK9orgt3tuEpBu/zg==", + "node_modules/@smithy/smithy-client": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-3.2.0.tgz", + "integrity": "sha512-pDbtxs8WOhJLJSeaF/eAbPgXg4VVYFlRcL/zoNYA5WbG3wBL06CHtBSg53ppkttDpAJ/hdiede+xApip1CwSLw==", "dependencies": { - "@smithy/types": "^2.8.0" + "@smithy/middleware-endpoint": "^3.1.0", + "@smithy/middleware-stack": "^3.0.3", + "@smithy/protocol-http": "^4.1.0", + "@smithy/types": "^3.3.0", + "@smithy/util-stream": "^3.1.3", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/shared-ini-file-loader": { - "version": "2.2.8", - "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-2.2.8.tgz", - "integrity": "sha512-E62byatbwSWrtq9RJ7xN40tqrRKDGrEL4EluyNpaIDvfvet06a/QC58oHw2FgVaEgkj0tXZPjZaKrhPfpoU0qw==", + "node_modules/@smithy/types": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", + "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/signature-v4": { - "version": "2.0.19", - "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-2.0.19.tgz", - "integrity": "sha512-nwc3JihdM+kcJjtORv/n7qRHN2Kfh7S2RJI2qr8pz9UcY5TD8rSCRGQ0g81HgyS3jZ5X9U/L4p014P3FonBPhg==", + "node_modules/@smithy/url-parser": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-3.0.3.tgz", + "integrity": "sha512-pw3VtZtX2rg+s6HMs6/+u9+hu6oY6U7IohGhVNnjbgKy86wcIsSZwgHrFR+t67Uyxvp4Xz3p3kGXXIpTNisq8A==", "dependencies": { - "@smithy/eventstream-codec": "^2.0.16", - "@smithy/is-array-buffer": "^2.0.0", - "@smithy/types": "^2.8.0", - "@smithy/util-hex-encoding": "^2.0.0", - "@smithy/util-middleware": "^2.0.9", - "@smithy/util-uri-escape": "^2.0.0", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" - }, - "engines": { - "node": ">=14.0.0" + "@smithy/querystring-parser": "^3.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" } }, - "node_modules/@smithy/smithy-client": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-2.2.1.tgz", - "integrity": "sha512-SpD7FLK92XV2fon2hMotaNDa2w5VAy5/uVjP9WFmjGSgWM8pTPVkHcDl1yFs5Z8LYbij0FSz+DbCBK6i+uXXUA==", - "dependencies": { - "@smithy/middleware-endpoint": "^2.3.0", - "@smithy/middleware-stack": "^2.0.10", - "@smithy/protocol-http": "^3.0.12", - "@smithy/types": "^2.8.0", - "@smithy/util-stream": "^2.0.24", - "tslib": "^2.5.0" + "node_modules/@smithy/util-base64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-3.0.0.tgz", + "integrity": "sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==", + "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/types": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-2.8.0.tgz", - "integrity": "sha512-h9sz24cFgt/W1Re22OlhQKmUZkNh244ApgRsUDYinqF8R+QgcsBIX344u2j61TPshsTz3CvL6HYU1DnQdsSrHA==", + "node_modules/@smithy/util-base64/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", + "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", "dependencies": { - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/url-parser": { - "version": "2.0.16", - "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-2.0.16.tgz", - "integrity": "sha512-Wfz5WqAoRT91TjRy1JeLR0fXtkIXHGsMbgzKFTx7E68SrZ55TB8xoG+vm11Ru4gheFTMXjAjwAxv1jQdC+pAQA==", + "node_modules/@smithy/util-base64/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", + "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", "dependencies": { - "@smithy/querystring-parser": "^2.0.16", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/is-array-buffer": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" } }, - "node_modules/@smithy/util-base64": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-2.0.1.tgz", - "integrity": "sha512-DlI6XFYDMsIVN+GH9JtcRp3j02JEVuWIn/QOZisVzpIAprdsxGveFed0bjbMRCqmIFe8uetn5rxzNrBtIGrPIQ==", + "node_modules/@smithy/util-base64/node_modules/@smithy/util-utf8": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", + "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", "dependencies": { - "@smithy/util-buffer-from": "^2.0.0", - "tslib": "^2.5.0" + "@smithy/util-buffer-from": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-body-length-browser": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@smithy/util-body-length-browser/-/util-body-length-browser-2.0.1.tgz", - "integrity": "sha512-NXYp3ttgUlwkaug4bjBzJ5+yIbUbUx8VsSLuHZROQpoik+gRkIBeEG9MPVYfvPNpuXb/puqodeeUXcKFe7BLOQ==", + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "tslib": "^2.5.0" + "tslib": "^2.6.2" } }, "node_modules/@smithy/util-body-length-node": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@smithy/util-body-length-node/-/util-body-length-node-2.1.0.tgz", - "integrity": "sha512-/li0/kj/y3fQ3vyzn36NTLGmUwAICb7Jbe/CsWCktW363gh1MOcpEcSO3mJ344Gv2dqz8YJCLQpb6hju/0qOWw==", + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-buffer-from": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-2.0.0.tgz", - "integrity": "sha512-/YNnLoHsR+4W4Vf2wL5lGv0ksg8Bmk3GEGxn2vEQt52AQaPSCuaO5PM5VM7lP1K9qHRKHwrPGktqVoAHKWHxzw==", + "license": "Apache-2.0", "dependencies": { "@smithy/is-array-buffer": "^2.0.0", "tslib": "^2.5.0" @@ -7724,130 +5086,159 @@ } }, "node_modules/@smithy/util-config-provider": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@smithy/util-config-provider/-/util-config-provider-2.1.0.tgz", - "integrity": "sha512-S6V0JvvhQgFSGLcJeT1CBsaTR03MM8qTuxMH9WPCCddlSo2W0V5jIHimHtIQALMLEDPGQ0ROSRr/dU0O+mxiQg==", + "version": "3.0.0", + "license": "Apache-2.0", "dependencies": { - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-defaults-mode-browser": { - "version": "2.0.24", - "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-browser/-/util-defaults-mode-browser-2.0.24.tgz", - "integrity": "sha512-TsP5mBuLgO2C21+laNG2nHYZEyUdkbGURv2tHvSuQQxLz952MegX95uwdxOY2jR2H4GoKuVRfdJq7w4eIjGYeg==", + "version": "3.0.15", + "license": "Apache-2.0", "dependencies": { - "@smithy/property-provider": "^2.0.17", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", + "@smithy/property-provider": "^3.1.3", + "@smithy/smithy-client": "^3.2.0", + "@smithy/types": "^3.3.0", "bowser": "^2.11.0", - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { "node": ">= 10.0.0" } }, "node_modules/@smithy/util-defaults-mode-node": { - "version": "2.0.32", - "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-node/-/util-defaults-mode-node-2.0.32.tgz", - "integrity": "sha512-d0S33dXA2cq1NyorVMroMrEtqKMr3MlyLITcfTBf9pXiigYiPMOtbSI7czHIfDbuVuM89Cg0urAgpt73QV9mPQ==", - "dependencies": { - "@smithy/config-resolver": "^2.0.23", - "@smithy/credential-provider-imds": "^2.1.5", - "@smithy/node-config-provider": "^2.1.9", - "@smithy/property-provider": "^2.0.17", - "@smithy/smithy-client": "^2.2.1", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "version": "3.0.15", + "license": "Apache-2.0", + "dependencies": { + "@smithy/config-resolver": "^3.0.5", + "@smithy/credential-provider-imds": "^3.2.0", + "@smithy/node-config-provider": "^3.1.4", + "@smithy/property-provider": "^3.1.3", + "@smithy/smithy-client": "^3.2.0", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" }, "engines": { "node": ">= 10.0.0" } }, "node_modules/@smithy/util-endpoints": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/@smithy/util-endpoints/-/util-endpoints-1.0.8.tgz", - "integrity": "sha512-l8zVuyZZ61IzZBYp5NWvsAhbaAjYkt0xg9R4xUASkg5SEeTT2meHOJwJHctKMFUXe4QZbn9fR2MaBYjP2119+w==", + "version": "2.0.5", + "license": "Apache-2.0", "dependencies": { - "@smithy/node-config-provider": "^2.1.9", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/node-config-provider": "^3.1.4", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">= 14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-hex-encoding": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-2.0.0.tgz", - "integrity": "sha512-c5xY+NUnFqG6d7HFh1IFfrm3mGl29lC+vF+geHv4ToiuJCBmIfzx6IeHLg+OgRdPFKDXIw6pvi+p3CsscaMcMA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", + "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", "dependencies": { - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-middleware": { - "version": "2.0.9", - "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-2.0.9.tgz", - "integrity": "sha512-PnCnBJ07noMX1lMDTEefmxSlusWJUiLfrme++MfK5TD0xz8NYmakgoXy5zkF/16zKGmiwOeKAztWT/Vjk1KRIQ==", + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-3.0.3.tgz", + "integrity": "sha512-l+StyYYK/eO3DlVPbU+4Bi06Jjal+PFLSMmlWM1BEwyLxZ3aKkf1ROnoIakfaA7mC6uw3ny7JBkau4Yc+5zfWw==", + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-retry": { + "version": "3.0.3", + "license": "Apache-2.0", + "dependencies": { + "@smithy/service-error-classification": "^3.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-stream": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-3.1.3.tgz", + "integrity": "sha512-FIv/bRhIlAxC0U7xM1BCnF2aDRPq0UaelqBHkM2lsCp26mcBbgI0tCVTv+jGdsQLUmAMybua/bjDsSu8RQHbmw==", + "dependencies": { + "@smithy/fetch-http-handler": "^3.2.4", + "@smithy/node-http-handler": "^3.1.4", + "@smithy/types": "^3.3.0", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-buffer-from": "^3.0.0", + "@smithy/util-hex-encoding": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-stream/node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", + "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", "dependencies": { - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/util-retry": { - "version": "2.0.9", - "resolved": "https://registry.npmjs.org/@smithy/util-retry/-/util-retry-2.0.9.tgz", - "integrity": "sha512-46BFWe9RqB6g7f4mxm3W3HlqknqQQmWHKlhoqSFZuGNuiDU5KqmpebMbvC3tjTlUkqn4xa2Z7s3Hwb0HNs5scw==", + "node_modules/@smithy/util-stream/node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", + "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", "dependencies": { - "@smithy/service-error-classification": "^2.0.9", - "@smithy/types": "^2.8.0", - "tslib": "^2.5.0" + "@smithy/is-array-buffer": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">= 14.0.0" + "node": ">=16.0.0" } }, - "node_modules/@smithy/util-stream": { - "version": "2.0.24", - "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-2.0.24.tgz", - "integrity": "sha512-hRpbcRrOxDriMVmbya+Mv77VZVupxRAsfxVDKS54XuiURhdiwCUXJP0X1iJhHinuUf6n8pBF0MkG9C8VooMnWw==", - "dependencies": { - "@smithy/fetch-http-handler": "^2.3.2", - "@smithy/node-http-handler": "^2.2.2", - "@smithy/types": "^2.8.0", - "@smithy/util-base64": "^2.0.1", - "@smithy/util-buffer-from": "^2.0.0", - "@smithy/util-hex-encoding": "^2.0.0", - "@smithy/util-utf8": "^2.0.2", - "tslib": "^2.5.0" + "node_modules/@smithy/util-stream/node_modules/@smithy/util-utf8": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", + "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", + "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-uri-escape": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-2.0.0.tgz", - "integrity": "sha512-ebkxsqinSdEooQduuk9CbKcI+wheijxEb3utGXkCoYQkJnwTnLbH1JXGimJtUkQwNQbsbuYwG2+aFVyZf5TLaw==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-3.0.0.tgz", + "integrity": "sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==", "dependencies": { - "tslib": "^2.5.0" + "tslib": "^2.6.2" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@smithy/util-utf8": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-2.0.2.tgz", - "integrity": "sha512-qOiVORSPm6Ce4/Yu6hbSgNHABLP2VMv8QOC3tTDNHHlWY19pPyc++fBTbZPtx6egPXi4HQxKDnMxVxpbtX2GoA==", + "license": "Apache-2.0", "dependencies": { "@smithy/util-buffer-from": "^2.0.0", "tslib": "^2.5.0" @@ -7858,8 +5249,6 @@ }, "node_modules/@smithy/util-waiter": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@smithy/util-waiter/-/util-waiter-3.1.2.tgz", - "integrity": "sha512-4pP0EV3iTsexDx+8PPGAKCQpd/6hsQBaQhqWzU4hqKPHN5epPsxKbvUTIiYIHTxaKt6/kEaqPBpu/ufvfbrRzw==", "license": "Apache-2.0", "dependencies": { "@smithy/abort-controller": "^3.1.1", @@ -7870,68 +5259,37 @@ "node": ">=16.0.0" } }, - "node_modules/@smithy/util-waiter/node_modules/@smithy/abort-controller": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.1.tgz", - "integrity": "sha512-MBJBiidoe+0cTFhyxT8g+9g7CeVccLM0IOKKUMCNQ1CNMJ/eIfoo0RTfVrXOONEI1UCN1W+zkiHSbzUNE9dZtQ==", - "license": "Apache-2.0", - "dependencies": { - "@smithy/types": "^3.3.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@smithy/util-waiter/node_modules/@smithy/types": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", - "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16.0.0" - } - }, "node_modules/@tsconfig/node10": { "version": "1.0.9", - "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", - "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@tsconfig/node12": { "version": "1.0.11", - "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", - "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@tsconfig/node14": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", - "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@tsconfig/node16": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz", - "integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/accepts": { "version": "1.3.7", - "resolved": "https://registry.npmjs.org/@types/accepts/-/accepts-1.3.7.tgz", - "integrity": "sha512-Pay9fq2lM2wXPWbteBsRAGiWH2hig4ZE2asK+mm7kUzlxRTfL961rj89I6zV/E3PcIkDqyuBEcMxFT7rccugeQ==", + "license": "MIT", "dependencies": { "@types/node": "*" } }, "node_modules/@types/babel__core": { "version": "7.20.5", - "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", - "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.20.7", "@babel/types": "^7.20.7", @@ -7942,18 +5300,16 @@ }, "node_modules/@types/babel__generator": { "version": "7.6.8", - "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.8.tgz", - "integrity": "sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.0.0" } }, "node_modules/@types/babel__template": { "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", - "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.1.0", "@babel/types": "^7.0.0" @@ -7961,17 +5317,15 @@ }, "node_modules/@types/babel__traverse": { "version": "7.20.5", - "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.20.5.tgz", - "integrity": "sha512-WXCyOcRtH37HAUkpXhUduaxdm82b4GSlyTqajXviN4EfiuPgNYR109xMCKvpl6zPIpua0DGlMEDCq+g8EdoheQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.20.7" } }, "node_modules/@types/body-parser": { "version": "1.19.5", - "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.5.tgz", - "integrity": "sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==", + "license": "MIT", "dependencies": { "@types/connect": "*", "@types/node": "*" @@ -7979,21 +5333,18 @@ }, "node_modules/@types/connect": { "version": "3.4.38", - "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.38.tgz", - "integrity": "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==", + "license": "MIT", "dependencies": { "@types/node": "*" } }, "node_modules/@types/content-disposition": { "version": "0.5.8", - "resolved": "https://registry.npmjs.org/@types/content-disposition/-/content-disposition-0.5.8.tgz", - "integrity": "sha512-QVSSvno3dE0MgO76pJhmv4Qyi/j0Yk9pBp0Y7TJ2Tlj+KCgJWY6qX7nnxCOLkZ3VYRSIk1WTxCvwUSdx6CCLdg==" + "license": "MIT" }, "node_modules/@types/cookies": { "version": "0.7.10", - "resolved": "https://registry.npmjs.org/@types/cookies/-/cookies-0.7.10.tgz", - "integrity": "sha512-hmUCjAk2fwZVPPkkPBcI7jGLIR5mg4OVoNMBwU6aVsMm/iNPY7z9/R+x2fSwLt/ZXoGua6C5Zy2k5xOo9jUyhQ==", + "license": "MIT", "dependencies": { "@types/connect": "*", "@types/express": "*", @@ -8003,8 +5354,7 @@ }, "node_modules/@types/express": { "version": "4.17.21", - "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.21.tgz", - "integrity": "sha512-ejlPM315qwLpaQlQDTjPdsUFSc6ZsP4AN6AlWnogPjQ7CVi7PYF3YVz+CY3jE2pwYf7E/7HlDAN0rV2GxTG0HQ==", + "license": "MIT", "dependencies": { "@types/body-parser": "*", "@types/express-serve-static-core": "^4.17.33", @@ -8014,8 +5364,7 @@ }, "node_modules/@types/express-serve-static-core": { "version": "4.17.41", - "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.17.41.tgz", - "integrity": "sha512-OaJ7XLaelTgrvlZD8/aa0vvvxZdUmlCn6MtWeB7TkiKW70BQLc9XEPpDLPdbo52ZhXUCrznlWdCHWxJWtdyajA==", + "license": "MIT", "dependencies": { "@types/node": "*", "@types/qs": "*", @@ -8025,62 +5374,53 @@ }, "node_modules/@types/fast-json-stable-stringify": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@types/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-IyNhGHu71jH1jCXTHmafuoAAdsbBON3kDh7u/UUhLmjYgN5TYB54e1R8ckTCiIevl2UuZaCsi9XRxineY5yUjw==", - "deprecated": "This is a stub types definition. fast-json-stable-stringify provides its own type definitions, so you do not need this installed.", "dev": true, + "license": "MIT", "dependencies": { "fast-json-stable-stringify": "*" } }, "node_modules/@types/graceful-fs": { "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@types/graceful-fs/-/graceful-fs-4.1.9.tgz", - "integrity": "sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/node": "*" } }, "node_modules/@types/http-assert": { "version": "1.5.5", - "resolved": "https://registry.npmjs.org/@types/http-assert/-/http-assert-1.5.5.tgz", - "integrity": "sha512-4+tE/lwdAahgZT1g30Jkdm9PzFRde0xwxBNUyRsCitRvCQB90iuA2uJYdUnhnANRcqGXaWOGY4FEoxeElNAK2g==" + "license": "MIT" }, "node_modules/@types/http-errors": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.4.tgz", - "integrity": "sha512-D0CFMMtydbJAegzOyHjtiKPLlvnm3iTZyZRSZoLq2mRhDdmLfIWOCYPfQJ4cu2erKghU++QvjcUjp/5h7hESpA==" + "license": "MIT" }, "node_modules/@types/istanbul-lib-coverage": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", - "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/istanbul-lib-report": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", - "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", "dev": true, + "license": "MIT", "dependencies": { "@types/istanbul-lib-coverage": "*" } }, "node_modules/@types/istanbul-reports": { "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", - "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/istanbul-lib-report": "*" } }, "node_modules/@types/jest": { "version": "29.5.11", - "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.11.tgz", - "integrity": "sha512-S2mHmYIVe13vrm6q4kN6fLYYAka15ALQki/vgDC3mIukEOx8WJlv0kQPM+d4w8Gp6u0uSdKND04IlTXBv0rwnQ==", "dev": true, + "license": "MIT", "dependencies": { "expect": "^29.0.0", "pretty-format": "^29.0.0" @@ -8088,29 +5428,24 @@ }, "node_modules/@types/json-schema": { "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==" + "license": "MIT" }, "node_modules/@types/json5": { "version": "0.0.29", - "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", - "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==" + "license": "MIT" }, "node_modules/@types/jsonpath": { "version": "0.2.4", - "resolved": "https://registry.npmjs.org/@types/jsonpath/-/jsonpath-0.2.4.tgz", - "integrity": "sha512-K3hxB8Blw0qgW6ExKgMbXQv2UPZBoE2GqLpVY+yr7nMD2Pq86lsuIzyAaiQ7eMqFL5B6di6pxSkogLJEyEHoGA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/keygrip": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/@types/keygrip/-/keygrip-1.0.6.tgz", - "integrity": "sha512-lZuNAY9xeJt7Bx4t4dx0rYCDqGPW8RXhQZK1td7d4H6E9zYbLoOtjBvfwdTKpsyxQI/2jv+armjX/RW+ZNpXOQ==" + "license": "MIT" }, "node_modules/@types/koa": { "version": "2.13.12", - "resolved": "https://registry.npmjs.org/@types/koa/-/koa-2.13.12.tgz", - "integrity": "sha512-vAo1KuDSYWFDB4Cs80CHvfmzSQWeUb909aQib0C0aFx4sw0K9UZFz2m5jaEP+b3X1+yr904iQiruS0hXi31jbw==", + "license": "MIT", "dependencies": { "@types/accepts": "*", "@types/content-disposition": "*", @@ -8124,70 +5459,59 @@ }, "node_modules/@types/koa-bodyparser": { "version": "4.3.12", - "resolved": "https://registry.npmjs.org/@types/koa-bodyparser/-/koa-bodyparser-4.3.12.tgz", - "integrity": "sha512-hKMmRMVP889gPIdLZmmtou/BijaU1tHPyMNmcK7FAHAdATnRcGQQy78EqTTxLH1D4FTsrxIzklAQCso9oGoebQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/koa": "*" } }, "node_modules/@types/koa-compose": { "version": "3.2.8", - "resolved": "https://registry.npmjs.org/@types/koa-compose/-/koa-compose-3.2.8.tgz", - "integrity": "sha512-4Olc63RY+MKvxMwVknCUDhRQX1pFQoBZ/lXcRLP69PQkEpze/0cr8LNqJQe5NFb/b19DWi2a5bTi2VAlQzhJuA==", + "license": "MIT", "dependencies": { "@types/koa": "*" } }, "node_modules/@types/lodash": { "version": "4.14.202", - "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.202.tgz", - "integrity": "sha512-OvlIYQK9tNneDlS0VN54LLd5uiPCBOp7gS5Z0f1mjoJYBrtStzgmJBxONW3U6OZqdtNzZPmn9BS/7WI7BFFcFQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/mime": { "version": "1.3.5", - "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.5.tgz", - "integrity": "sha512-/pyBZWSLD2n0dcHE3hq8s8ZvcETHtEuF+3E7XVt0Ig2nvsVQXdghHVcEkIWjy9A0wKfTn97a/PSDYohKIlnP/w==" + "license": "MIT" }, "node_modules/@types/minimist": { "version": "1.2.5", - "resolved": "https://registry.npmjs.org/@types/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-hov8bUuiLiyFPGyFPE1lwWhmzYbirOXQNNo40+y3zow8aFVTeyn3VWL0VFFfdNddA8S4Vf0Tc062rzyNr7Paag==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/node": { "version": "20.10.7", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.10.7.tgz", - "integrity": "sha512-fRbIKb8C/Y2lXxB5eVMj4IU7xpdox0Lh8bUPEdtLysaylsml1hOOx1+STloRs/B9nf7C6kPRmmg/V7aQW7usNg==", + "license": "MIT", "dependencies": { "undici-types": "~5.26.4" } }, "node_modules/@types/normalize-package-data": { "version": "2.4.4", - "resolved": "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.4.tgz", - "integrity": "sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==" + "license": "MIT" }, "node_modules/@types/qs": { "version": "6.9.11", - "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.11.tgz", - "integrity": "sha512-oGk0gmhnEJK4Yyk+oI7EfXsLayXatCWPHary1MtcmbAifkobT9cM9yutG/hZKIseOU0MqbIwQ/u2nn/Gb+ltuQ==" + "license": "MIT" }, "node_modules/@types/range-parser": { "version": "1.2.7", - "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.7.tgz", - "integrity": "sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==" + "license": "MIT" }, "node_modules/@types/semver": { "version": "7.5.6", - "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.6.tgz", - "integrity": "sha512-dn1l8LaMea/IjDoHNd9J52uBbInB796CDffS6VdIxvqYCPSG0V0DzHp76GpaWnlhg88uYyPbXCDIowa86ybd5A==" + "license": "MIT" }, "node_modules/@types/send": { "version": "0.17.4", - "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.4.tgz", - "integrity": "sha512-x2EM6TJOybec7c52BX0ZspPodMsQUd5L6PRwOunVyVUhXiBSKf3AezDL8Dgvgt5o0UfKNfuA0eMLr2wLT4AiBA==", + "license": "MIT", "dependencies": { "@types/mime": "^1", "@types/node": "*" @@ -8195,8 +5519,7 @@ }, "node_modules/@types/serve-static": { "version": "1.15.5", - "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.5.tgz", - "integrity": "sha512-PDRk21MnK70hja/YF8AHfC7yIsiQHn1rcXx7ijCFBX/k+XQJhQT/gw3xekXKJvx+5SXaMMS8oqQy09Mzvz2TuQ==", + "license": "MIT", "dependencies": { "@types/http-errors": "*", "@types/mime": "*", @@ -8205,34 +5528,29 @@ }, "node_modules/@types/stack-utils": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", - "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/triple-beam": { "version": "1.3.5", - "resolved": "https://registry.npmjs.org/@types/triple-beam/-/triple-beam-1.3.5.tgz", - "integrity": "sha512-6WaYesThRMCl19iryMYP7/x2OVgCtbIVflDGFpWnb9irXI3UjYE4AzmYuiUKY1AJstGijoY+MgUszMgRxIYTYw==" + "license": "MIT" }, "node_modules/@types/yargs": { "version": "17.0.32", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.32.tgz", - "integrity": "sha512-xQ67Yc/laOG5uMfX/093MRlGGCIBzZMarVa+gfNKJxWAIgykYpVGkBdbqEzGDDfCrVUj6Hiff4mTZ5BA6TmAog==", "dev": true, + "license": "MIT", "dependencies": { "@types/yargs-parser": "*" } }, "node_modules/@types/yargs-parser": { "version": "21.0.3", - "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", - "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@typescript-eslint/eslint-plugin": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.62.0.tgz", - "integrity": "sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==", + "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.4.0", "@typescript-eslint/scope-manager": "5.62.0", @@ -8264,8 +5582,7 @@ }, "node_modules/@typescript-eslint/parser": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.62.0.tgz", - "integrity": "sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==", + "license": "BSD-2-Clause", "dependencies": { "@typescript-eslint/scope-manager": "5.62.0", "@typescript-eslint/types": "5.62.0", @@ -8290,8 +5607,7 @@ }, "node_modules/@typescript-eslint/scope-manager": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.62.0.tgz", - "integrity": "sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w==", + "license": "MIT", "dependencies": { "@typescript-eslint/types": "5.62.0", "@typescript-eslint/visitor-keys": "5.62.0" @@ -8306,8 +5622,7 @@ }, "node_modules/@typescript-eslint/type-utils": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.62.0.tgz", - "integrity": "sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==", + "license": "MIT", "dependencies": { "@typescript-eslint/typescript-estree": "5.62.0", "@typescript-eslint/utils": "5.62.0", @@ -8332,8 +5647,7 @@ }, "node_modules/@typescript-eslint/types": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.62.0.tgz", - "integrity": "sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ==", + "license": "MIT", "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, @@ -8344,8 +5658,7 @@ }, "node_modules/@typescript-eslint/typescript-estree": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.62.0.tgz", - "integrity": "sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==", + "license": "BSD-2-Clause", "dependencies": { "@typescript-eslint/types": "5.62.0", "@typescript-eslint/visitor-keys": "5.62.0", @@ -8370,8 +5683,7 @@ }, "node_modules/@typescript-eslint/utils": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.62.0.tgz", - "integrity": "sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==", + "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", "@types/json-schema": "^7.0.9", @@ -8395,8 +5707,7 @@ }, "node_modules/@typescript-eslint/visitor-keys": { "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.62.0.tgz", - "integrity": "sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw==", + "license": "MIT", "dependencies": { "@typescript-eslint/types": "5.62.0", "eslint-visitor-keys": "^3.3.0" @@ -8411,18 +5722,15 @@ }, "node_modules/@ungap/structured-clone": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", - "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==" + "license": "ISC" }, "node_modules/abbrev": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" + "license": "ISC" }, "node_modules/accepts": { "version": "1.3.8", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", - "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", + "license": "MIT", "dependencies": { "mime-types": "~2.1.34", "negotiator": "0.6.3" @@ -8433,8 +5741,7 @@ }, "node_modules/acorn": { "version": "8.11.3", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz", - "integrity": "sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==", + "license": "MIT", "bin": { "acorn": "bin/acorn" }, @@ -8444,31 +5751,27 @@ }, "node_modules/acorn-jsx": { "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", + "license": "MIT", "peerDependencies": { "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, "node_modules/acorn-walk": { "version": "8.3.1", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.1.tgz", - "integrity": "sha512-TgUZgYvqZprrl7YldZNoa9OciCAyZR+Ejm9eXzKCmjsF5IKp/wgQ7Z/ZpjpGTIUPwrHQIcYeI8qDh4PsEwxMbw==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.4.0" } }, "node_modules/add-stream": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/add-stream/-/add-stream-1.0.0.tgz", - "integrity": "sha512-qQLMr+8o0WC4FZGQTcJiKBVC59JylcPSrTtk6usvmIDFUOCKegapy1VHQwRbFMOFyb/inzUVqHs+eMYKDM1YeQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/agent-base": { "version": "6.0.2", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", - "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", + "license": "MIT", "dependencies": { "debug": "4" }, @@ -8478,8 +5781,7 @@ }, "node_modules/ajv": { "version": "8.12.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz", - "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==", + "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.1", "json-schema-traverse": "^1.0.0", @@ -8493,8 +5795,7 @@ }, "node_modules/ajv-draft-04": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/ajv-draft-04/-/ajv-draft-04-1.0.0.tgz", - "integrity": "sha512-mv00Te6nmYbRp5DCwclxtt7yV/joXJPGS7nM+97GdxvuttCOfgI3K4U25zboyeX0O+myI8ERluxQe5wljMmVIw==", + "license": "MIT", "peerDependencies": { "ajv": "^8.5.0" }, @@ -8506,8 +5807,7 @@ }, "node_modules/ajv-formats": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz", - "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==", + "license": "MIT", "dependencies": { "ajv": "^8.0.0" }, @@ -8522,18 +5822,16 @@ }, "node_modules/ansi-align": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ansi-align/-/ansi-align-3.0.1.tgz", - "integrity": "sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==", "dev": true, + "license": "ISC", "dependencies": { "string-width": "^4.1.0" } }, "node_modules/ansi-escapes": { "version": "4.3.2", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", - "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", "dev": true, + "license": "MIT", "dependencies": { "type-fest": "^0.21.3" }, @@ -8546,9 +5844,8 @@ }, "node_modules/ansi-escapes/node_modules/type-fest": { "version": "0.21.3", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", - "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=10" }, @@ -8558,16 +5855,14 @@ }, "node_modules/ansi-regex": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/ansi-styles": { "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "license": "MIT", "dependencies": { "color-convert": "^1.9.0" }, @@ -8577,15 +5872,13 @@ }, "node_modules/any-promise": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", - "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/anymatch": { "version": "3.1.3", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", - "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", "dev": true, + "license": "ISC", "dependencies": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" @@ -8596,19 +5889,16 @@ }, "node_modules/app-module-path": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/app-module-path/-/app-module-path-2.2.0.tgz", - "integrity": "sha512-gkco+qxENJV+8vFcDiiFhuoSvRXb2a/QPqpSoWhVz829VNJfOTnELbBmPmNKFxf3xdNnw4DWCkzkDaavcX/1YQ==", - "dev": true + "dev": true, + "license": "BSD-2-Clause" }, "node_modules/aproba": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", - "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==" + "license": "ISC" }, "node_modules/are-we-there-yet": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-2.0.0.tgz", - "integrity": "sha512-Ci/qENmwHnsYo9xKIcUJN5LeDKdJ6R1Z1j9V/J5wyq8nh/mYPEpIKJbBZXtZjG04HiK7zV/p6Vs9952MrMeUIw==", + "license": "ISC", "dependencies": { "delegates": "^1.0.0", "readable-stream": "^3.6.0" @@ -8619,8 +5909,7 @@ }, "node_modules/are-we-there-yet/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -8632,19 +5921,16 @@ }, "node_modules/arg": { "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/argparse": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==" + "license": "Python-2.0" }, "node_modules/array-buffer-byte-length": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", - "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "is-array-buffer": "^3.0.1" @@ -8655,23 +5941,20 @@ }, "node_modules/array-find-index": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz", - "integrity": "sha512-M1HQyIXcBGtVywBt8WVdim+lrNaK7VHp99Qt5pSNziXznKHViIBbXWtfRTpEFpF/c4FdfxNAsCCwPp5phBYJtw==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/array-ify": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/array-ify/-/array-ify-1.0.0.tgz", - "integrity": "sha512-c5AMf34bKdvPhQ7tBGhqkgKNUzMr4WUs+WDtC2ZUGOUncbxKMTvqxYctiseW3+L4bA8ec+GcZ6/A/FW4m8ukng==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/array-includes": { "version": "3.1.7", - "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.7.tgz", - "integrity": "sha512-dlcsNBIiWhPkHdOEEKnehA+RNUWDc4UqFtnIXU4uuYDPtA4LDkr7qip2p0VvFAEXNDr0yWZ9PJyIRiGjRLQzwQ==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -8688,16 +5971,14 @@ }, "node_modules/array-union": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", - "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/array.prototype.findlastindex": { "version": "1.2.3", - "resolved": "https://registry.npmjs.org/array.prototype.findlastindex/-/array.prototype.findlastindex-1.2.3.tgz", - "integrity": "sha512-LzLoiOMAxvy+Gd3BAq3B7VeIgPdo+Q8hthvKtXybMvRV0jrXfJM/t8mw7nNlpEcVlVUnCnM2KSX4XU5HmpodOA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -8714,8 +5995,7 @@ }, "node_modules/array.prototype.flat": { "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.2.tgz", - "integrity": "sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -8731,8 +6011,7 @@ }, "node_modules/array.prototype.flatmap": { "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.2.tgz", - "integrity": "sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -8748,8 +6027,7 @@ }, "node_modules/arraybuffer.prototype.slice": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", - "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "license": "MIT", "dependencies": { "array-buffer-byte-length": "^1.0.0", "call-bind": "^1.0.2", @@ -8768,51 +6046,44 @@ }, "node_modules/arrify": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", - "integrity": "sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/asap": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", - "integrity": "sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/ast-module-types": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/ast-module-types/-/ast-module-types-4.0.0.tgz", - "integrity": "sha512-Kd0o8r6CDazJGCRzs8Ivpn0xj19oNKrULhoJFzhGjRsLpekF2zyZs9Ukz+JvZhWD6smszfepakTFhAaYpsI12g==", "dev": true, + "license": "MIT", "engines": { "node": ">=12.0" } }, "node_modules/async": { "version": "3.2.5", - "resolved": "https://registry.npmjs.org/async/-/async-3.2.5.tgz", - "integrity": "sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg==" + "license": "MIT" }, "node_modules/asynckit": { "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + "license": "MIT" }, "node_modules/at-least-node": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", - "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", "dev": true, + "license": "ISC", "engines": { "node": ">= 4.0.0" } }, "node_modules/available-typed-arrays": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", - "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -8822,23 +6093,20 @@ }, "node_modules/await-handler": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/await-handler/-/await-handler-1.1.2.tgz", - "integrity": "sha512-dihteGhwbJpT89kVbacWiyKeAZr+En0YGK6pAKQJLR0En9ZxSH2H4TTvfG4bBjzFq9gDAma4y9BrpDns6j5UiQ==" + "license": "MIT" }, "node_modules/axios": { - "version": "1.6.5", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.5.tgz", - "integrity": "sha512-Ii012v05KEVuUoFWmMW/UQv9aRIc3ZwkWDcM+h5Il8izZCtRVpDUfwpoFf7eOtajT3QiGR4yDUx7lPqHJULgbg==", + "version": "1.7.5", + "license": "MIT", "dependencies": { - "follow-redirects": "^1.15.4", + "follow-redirects": "^1.15.6", "form-data": "^4.0.0", "proxy-from-env": "^1.1.0" } }, "node_modules/axios-mock-adapter": { "version": "1.22.0", - "resolved": "https://registry.npmjs.org/axios-mock-adapter/-/axios-mock-adapter-1.22.0.tgz", - "integrity": "sha512-dmI0KbkyAhntUR05YY96qg2H6gg0XMl2+qTW0xmYg6Up+BFBAJYRLROMXRdDEL06/Wqwa0TJThAYvFtSFdRCZw==", + "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.3", "is-buffer": "^2.0.5" @@ -8849,9 +6117,8 @@ }, "node_modules/babel-jest": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.7.0.tgz", - "integrity": "sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg==", "dev": true, + "license": "MIT", "dependencies": { "@jest/transform": "^29.7.0", "@types/babel__core": "^7.1.14", @@ -8870,9 +6137,8 @@ }, "node_modules/babel-jest/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -8885,9 +6151,8 @@ }, "node_modules/babel-jest/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -8901,9 +6166,8 @@ }, "node_modules/babel-jest/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -8913,24 +6177,21 @@ }, "node_modules/babel-jest/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/babel-jest/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/babel-jest/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -8940,9 +6201,8 @@ }, "node_modules/babel-plugin-istanbul": { "version": "6.1.1", - "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", - "integrity": "sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "@babel/helper-plugin-utils": "^7.0.0", "@istanbuljs/load-nyc-config": "^1.0.0", @@ -8956,9 +6216,8 @@ }, "node_modules/babel-plugin-istanbul/node_modules/istanbul-lib-instrument": { "version": "5.2.1", - "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz", - "integrity": "sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "@babel/core": "^7.12.3", "@babel/parser": "^7.14.7", @@ -8972,18 +6231,16 @@ }, "node_modules/babel-plugin-istanbul/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/babel-plugin-jest-hoist": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz", - "integrity": "sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg==", "dev": true, + "license": "MIT", "dependencies": { "@babel/template": "^7.3.3", "@babel/types": "^7.3.3", @@ -8996,9 +6253,8 @@ }, "node_modules/babel-preset-current-node-syntax": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz", - "integrity": "sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/plugin-syntax-async-generators": "^7.8.4", "@babel/plugin-syntax-bigint": "^7.8.3", @@ -9019,9 +6275,8 @@ }, "node_modules/babel-preset-jest": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz", - "integrity": "sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA==", "dev": true, + "license": "MIT", "dependencies": { "babel-plugin-jest-hoist": "^29.6.3", "babel-preset-current-node-syntax": "^1.0.0" @@ -9035,13 +6290,10 @@ }, "node_modules/balanced-match": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + "license": "MIT" }, "node_modules/base64-js": { "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", "funding": [ { "type": "github", @@ -9055,13 +6307,13 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "license": "MIT" }, "node_modules/benchmark-suite": { "version": "0.1.8", - "resolved": "https://registry.npmjs.org/benchmark-suite/-/benchmark-suite-0.1.8.tgz", - "integrity": "sha512-UDfWBQfeq/lXcsjuGAanOrX6AhP6HQSsutGS7CfStcbE1loLge7aQr5DT6n8r/4bUoiK+5RYwnogNu5UuTBMNg==", "dev": true, + "license": "MIT", "dependencies": { "eventemitter3": "^4.0.7", "expose-gc": "^1.0.0", @@ -9075,22 +6327,19 @@ }, "node_modules/bindings": { "version": "1.5.0", - "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", - "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "license": "MIT", "dependencies": { "file-uri-to-path": "1.0.0" } }, "node_modules/bintrees": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bintrees/-/bintrees-1.0.2.tgz", - "integrity": "sha512-VOMgTMwjAaUG580SXn3LacVgjurrbMme7ZZNYGSSV7mmtY6QQRh0Eg3pwIcntQ77DErK1L0NxkbetjcoXzVwKw==" + "license": "MIT" }, "node_modules/bl": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", - "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", "dev": true, + "license": "MIT", "dependencies": { "buffer": "^5.5.0", "inherits": "^2.0.4", @@ -9099,9 +6348,8 @@ }, "node_modules/bl/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -9113,20 +6361,17 @@ }, "node_modules/boolean": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/boolean/-/boolean-3.2.0.tgz", - "integrity": "sha512-d0II/GO9uf9lfUHH2BQsjxzRJZBdsjgsBiW4BvhWk/3qoKwQFjIDVN19PfX8F2D/r9PCMTtLWjYVCFrpeYUzsw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/bowser": { "version": "2.11.0", - "resolved": "https://registry.npmjs.org/bowser/-/bowser-2.11.0.tgz", - "integrity": "sha512-AlcaJBi/pqqJBIQ8U9Mcpc9i8Aqxn88Skv5d+xBX006BY5u8N3mGLHa5Lgppa7L/HfwgwLgZ6NYs+Ag6uUmJRA==" + "license": "MIT" }, "node_modules/boxen": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/boxen/-/boxen-5.1.2.tgz", - "integrity": "sha512-9gYgQKXx+1nP8mP7CzFyaUARhg7D3n1dF/FnErWmu9l6JvGpNUN278h0aSb+QjoiKSWG+iZ3uHrcqk0qrY9RQQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-align": "^3.0.0", "camelcase": "^6.2.0", @@ -9146,9 +6391,8 @@ }, "node_modules/boxen/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -9161,9 +6405,8 @@ }, "node_modules/boxen/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -9177,9 +6420,8 @@ }, "node_modules/boxen/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -9189,24 +6431,21 @@ }, "node_modules/boxen/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/boxen/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/boxen/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -9216,8 +6455,7 @@ }, "node_modules/brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -9225,8 +6463,7 @@ }, "node_modules/braces": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "license": "MIT", "dependencies": { "fill-range": "^7.1.1" }, @@ -9236,8 +6473,6 @@ }, "node_modules/browserslist": { "version": "4.22.2", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.22.2.tgz", - "integrity": "sha512-0UgcrvQmBDvZHFGdYUehrCNIazki7/lUP3kkoi/r3YB2amZbFM9J43ZRkJTXBUZK4gmx56+Sqk9+Vs9mwZx9+A==", "dev": true, "funding": [ { @@ -9253,6 +6488,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "dependencies": { "caniuse-lite": "^1.0.30001565", "electron-to-chromium": "^1.4.601", @@ -9268,9 +6504,8 @@ }, "node_modules/bs-logger": { "version": "0.2.6", - "resolved": "https://registry.npmjs.org/bs-logger/-/bs-logger-0.2.6.tgz", - "integrity": "sha512-pd8DCoxmbgc7hyPKOvxtqNcjYoOsABPQdcCUjGp3d42VR2CX1ORhk2A87oqqu5R1kk+76nsxZupkmyd+MVtCog==", "dev": true, + "license": "MIT", "dependencies": { "fast-json-stable-stringify": "2.x" }, @@ -9280,17 +6515,15 @@ }, "node_modules/bser": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", - "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", "dev": true, + "license": "Apache-2.0", "dependencies": { "node-int64": "^0.4.0" } }, "node_modules/btoa": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/btoa/-/btoa-1.2.1.tgz", - "integrity": "sha512-SB4/MIGlsiVkMcHmT+pSmIPoNDoHg+7cMzmt3Uxt628MTz2487DKSqK/fuhFBrkuqrYv5UCEnACpF4dTFNKc/g==", + "license": "(MIT OR Apache-2.0)", "bin": { "btoa": "bin/btoa.js" }, @@ -9300,8 +6533,7 @@ }, "node_modules/buffer": { "version": "5.6.0", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.6.0.tgz", - "integrity": "sha512-/gDYp/UtU0eA1ys8bOs9J6a+E/KWIY+DZ+Q2WESNUA0jFRsJOc0SNUO6xJ5SGA1xueg3NL65W6s+NY5l9cunuw==", + "license": "MIT", "dependencies": { "base64-js": "^1.0.2", "ieee754": "^1.1.4" @@ -9309,15 +6541,13 @@ }, "node_modules/buffer-from": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", - "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/builtin-modules": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.3.0.tgz", - "integrity": "sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" }, @@ -9327,24 +6557,21 @@ }, "node_modules/byline": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/byline/-/byline-5.0.0.tgz", - "integrity": "sha512-s6webAy+R4SR8XVuJWt2V2rGvhnrhxN+9S15GNuTK3wKPOXFF6RNc+8ug2XhH+2s4f+uudG4kUVYmYOQWL2g0Q==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/bytes": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", - "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/cache-content-type": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/cache-content-type/-/cache-content-type-1.0.1.tgz", - "integrity": "sha512-IKufZ1o4Ut42YUrZSo8+qnMTrFuKkvyoLXUywKz9GJ5BrhOFGhLdkx9sG4KAnVvbY6kEcSFjLQul+DVmBm2bgA==", + "license": "MIT", "dependencies": { "mime-types": "^2.1.18", "ylru": "^1.2.0" @@ -9355,9 +6582,8 @@ }, "node_modules/cacheable-request": { "version": "2.1.4", - "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-2.1.4.tgz", - "integrity": "sha512-vag0O2LKZ/najSoUwDbVlnlCFvhBE/7mGTY2B5FgCBDcRD+oVV1HYTOwM6JZfMg/hIcM6IwnTZ1uQQL5/X3xIQ==", "dev": true, + "license": "MIT", "dependencies": { "clone-response": "1.0.2", "get-stream": "3.0.0", @@ -9370,50 +6596,44 @@ }, "node_modules/cacheable-request/node_modules/get-stream": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz", - "integrity": "sha512-GlhdIUuVakc8SJ6kK0zAFbiGzRFzNnY4jUuEbV9UROo4Y+0Ny4fjvcZFVTeDA4odpFyOQzaw6hXukJSq/f28sQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/cacheable-request/node_modules/json-buffer": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.0.tgz", - "integrity": "sha512-CuUqjv0FUZIdXkHPI8MezCnFCdaTAacej1TZYulLoAg1h/PhwkdXFN4V/gzY4g+fMBCOV2xF+rp7t2XD2ns/NQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cacheable-request/node_modules/keyv": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-3.0.0.tgz", - "integrity": "sha512-eguHnq22OE3uVoSYG0LVWNP+4ppamWr9+zWBe1bsNcovIMy6huUJFPgy4mGwCd/rnl3vOLGW1MTlu4c57CT1xA==", "dev": true, + "license": "MIT", "dependencies": { "json-buffer": "3.0.0" } }, "node_modules/cacheable-request/node_modules/lowercase-keys": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-1.0.0.tgz", - "integrity": "sha512-RPlX0+PHuvxVDZ7xX+EBVAp4RsVxP/TdDSN2mJYdiq1Lc4Hz7EUSjUI7RZrKKlmrIzVhf6Jo2stj7++gVarS0A==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/cachedir": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/cachedir/-/cachedir-2.3.0.tgz", - "integrity": "sha512-A+Fezp4zxnit6FanDmv9EqXNAi3vt9DWp51/71UEhXukb7QUuvtv9344h91dyAxuTLoSYJFU299qzR3tzwPAhw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/call-bind": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.5.tgz", - "integrity": "sha512-C3nQxfFZxFRVoJoGKKI8y3MOEo129NQ+FgQ08iye+Mk4zNZZGdjfs06bVTr+DBSlA66Q2VEcMki/cUCP4SercQ==", + "license": "MIT", "dependencies": { "function-bind": "^1.1.2", "get-intrinsic": "^1.2.1", @@ -9425,23 +6645,20 @@ }, "node_modules/call-me-maybe": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-me-maybe/-/call-me-maybe-1.0.2.tgz", - "integrity": "sha512-HpX65o1Hnr9HH25ojC1YGs7HCQLq0GCOibSaWER0eNpgJ/Z1MZv2mTc7+xh6WOPxbRVcmgbv4hGU+uSQ/2xFZQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/callsites": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/camelcase": { "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -9451,9 +6668,8 @@ }, "node_modules/camelcase-keys": { "version": "6.2.2", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-6.2.2.tgz", - "integrity": "sha512-YrwaA0vEKazPBkn0ipTiMpSajYDSe+KjQfrjhcBMxJt/znbvlHd8Pw/Vamaz5EB4Wfhs3SUR3Z9mwRu/P3s3Yg==", "dev": true, + "license": "MIT", "dependencies": { "camelcase": "^5.3.1", "map-obj": "^4.0.0", @@ -9468,17 +6684,14 @@ }, "node_modules/camelcase-keys/node_modules/camelcase": { "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/caniuse-lite": { "version": "1.0.30001576", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001576.tgz", - "integrity": "sha512-ff5BdakGe2P3SQsMsiqmt1Lc8221NR1VzHj5jXN5vBny9A6fpze94HiVV/n7XRosOlsShJcvMv5mdnpjOGCEgg==", "dev": true, "funding": [ { @@ -9493,12 +6706,12 @@ "type": "github", "url": "https://github.com/sponsors/ai" } - ] + ], + "license": "CC-BY-4.0" }, "node_modules/chalk": { "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "license": "MIT", "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", @@ -9510,48 +6723,41 @@ }, "node_modules/char-regex": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", - "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" } }, "node_modules/chardet": { "version": "0.7.0", - "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", - "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/charenc": { "version": "0.0.2", - "resolved": "https://registry.npmjs.org/charenc/-/charenc-0.0.2.tgz", - "integrity": "sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA==", + "license": "BSD-3-Clause", "engines": { "node": "*" } }, "node_modules/check-more-types": { "version": "2.24.0", - "resolved": "https://registry.npmjs.org/check-more-types/-/check-more-types-2.24.0.tgz", - "integrity": "sha512-Pj779qHxV2tuapviy1bSZNEL1maXr13bPYpsvSDB68HlYcYuhlDrmGd63i0JHMCLKzc7rUSNIrpdJlhVlNwrxA==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.8.0" } }, "node_modules/chownr": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", + "license": "ISC", "engines": { "node": ">=10" } }, "node_modules/ci-info": { "version": "3.9.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", - "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", "dev": true, "funding": [ { @@ -9559,21 +6765,20 @@ "url": "https://github.com/sponsors/sibiraj-s" } ], + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/cjs-module-lexer": { "version": "1.2.3", - "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-1.2.3.tgz", - "integrity": "sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/clean-regexp": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/clean-regexp/-/clean-regexp-1.0.0.tgz", - "integrity": "sha512-GfisEZEJvzKrmGWkvfhgzcz/BllN1USeqD2V6tg14OAOgaCD2Z/PUEuxnAZ/nPvmaHRG7a8y77p1T/IRQ4D1Hw==", "dev": true, + "license": "MIT", "dependencies": { "escape-string-regexp": "^1.0.5" }, @@ -9583,9 +6788,8 @@ }, "node_modules/cli-boxes": { "version": "2.2.1", - "resolved": "https://registry.npmjs.org/cli-boxes/-/cli-boxes-2.2.1.tgz", - "integrity": "sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" }, @@ -9595,9 +6799,8 @@ }, "node_modules/cli-cursor": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", - "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", "dev": true, + "license": "MIT", "dependencies": { "restore-cursor": "^3.1.0" }, @@ -9607,9 +6810,8 @@ }, "node_modules/cli-spinners": { "version": "2.9.2", - "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz", - "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" }, @@ -9619,9 +6821,8 @@ }, "node_modules/cli-truncate": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-3.1.0.tgz", - "integrity": "sha512-wfOBkjXteqSnI59oPcJkcPl/ZmwvMMOj340qUIY1SKZCv0B9Cf4D4fAucRkIKQmsIuYK3x1rrgU7MeGRruiuiA==", "dev": true, + "license": "MIT", "dependencies": { "slice-ansi": "^5.0.0", "string-width": "^5.0.0" @@ -9635,9 +6836,8 @@ }, "node_modules/cli-truncate/node_modules/ansi-regex": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", - "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -9647,15 +6847,13 @@ }, "node_modules/cli-truncate/node_modules/emoji-regex": { "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cli-truncate/node_modules/string-width": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", - "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", "dev": true, + "license": "MIT", "dependencies": { "eastasianwidth": "^0.2.0", "emoji-regex": "^9.2.2", @@ -9670,9 +6868,8 @@ }, "node_modules/cli-truncate/node_modules/strip-ansi": { "version": "7.1.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", - "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-regex": "^6.0.1" }, @@ -9685,18 +6882,16 @@ }, "node_modules/cli-width": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-3.0.0.tgz", - "integrity": "sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw==", "dev": true, + "license": "ISC", "engines": { "node": ">= 10" } }, "node_modules/cliui": { "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", "dev": true, + "license": "ISC", "dependencies": { "string-width": "^4.2.0", "strip-ansi": "^6.0.1", @@ -9708,33 +6903,29 @@ }, "node_modules/clone": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz", - "integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==", + "license": "MIT", "engines": { "node": ">=0.8" } }, "node_modules/clone-response": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.2.tgz", - "integrity": "sha512-yjLXh88P599UOyPTFX0POsd7WxnbsVsGohcwzHOLspIhhpalPw1BcqED8NblyZLKcGrL8dTgMlcaZxV2jAD41Q==", "dev": true, + "license": "MIT", "dependencies": { "mimic-response": "^1.0.0" } }, "node_modules/cluster-key-slot": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/cluster-key-slot/-/cluster-key-slot-1.1.2.tgz", - "integrity": "sha512-RMr0FhtfXemyinomL4hrWcYJxmX6deFdCxpJzhDttxgO1+bcCnkk+9drydLVDmAMG7NE6aN/fl4F7ucU/90gAA==", + "license": "Apache-2.0", "engines": { "node": ">=0.10.0" } }, "node_modules/co": { "version": "4.6.0", - "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", - "integrity": "sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==", + "license": "MIT", "engines": { "iojs": ">= 1.0.0", "node": ">= 0.12.0" @@ -9742,8 +6933,7 @@ }, "node_modules/co-body": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/co-body/-/co-body-6.1.0.tgz", - "integrity": "sha512-m7pOT6CdLN7FuXUcpuz/8lfQ/L77x8SchHCF4G0RBTJO20Wzmhn5Sp4/5WsKy8OSpifBSUrmg83qEqaDHdyFuQ==", + "license": "MIT", "dependencies": { "inflation": "^2.0.0", "qs": "^6.5.2", @@ -9753,14 +6943,12 @@ }, "node_modules/collect-v8-coverage": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/collect-v8-coverage/-/collect-v8-coverage-1.0.2.tgz", - "integrity": "sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/color": { "version": "3.2.1", - "resolved": "https://registry.npmjs.org/color/-/color-3.2.1.tgz", - "integrity": "sha512-aBl7dZI9ENN6fUGC7mWpMTPNHmWUSNan9tuWN6ahh5ZLNk9baLJOnSMlrQkHcrfFgz2/RigjUVAjdx36VcemKA==", + "license": "MIT", "dependencies": { "color-convert": "^1.9.3", "color-string": "^1.6.0" @@ -9768,21 +6956,18 @@ }, "node_modules/color-convert": { "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "license": "MIT", "dependencies": { "color-name": "1.1.3" } }, "node_modules/color-name": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" + "license": "MIT" }, "node_modules/color-string": { "version": "1.9.1", - "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.9.1.tgz", - "integrity": "sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==", + "license": "MIT", "dependencies": { "color-name": "^1.0.0", "simple-swizzle": "^0.2.2" @@ -9790,30 +6975,26 @@ }, "node_modules/color-support": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", + "license": "ISC", "bin": { "color-support": "bin.js" } }, "node_modules/colorette": { "version": "2.0.20", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", - "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/colors": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", - "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==", + "license": "MIT", "engines": { "node": ">=0.1.90" } }, "node_modules/colorspace": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/colorspace/-/colorspace-1.1.4.tgz", - "integrity": "sha512-BgvKJiuVu1igBUF2kEjRCZXol6wiiGbY5ipL/oVPwm0BL9sIpMIzM8IK7vwuxIIzOXMV3Ey5w+vxhm0rR/TN8w==", + "license": "MIT", "dependencies": { "color": "^3.1.3", "text-hex": "1.0.x" @@ -9821,8 +7002,7 @@ }, "node_modules/combined-stream": { "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "license": "MIT", "dependencies": { "delayed-stream": "~1.0.0" }, @@ -9832,18 +7012,16 @@ }, "node_modules/commander": { "version": "10.0.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz", - "integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==", "dev": true, + "license": "MIT", "engines": { "node": ">=14" } }, "node_modules/commitizen": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/commitizen/-/commitizen-4.3.0.tgz", - "integrity": "sha512-H0iNtClNEhT0fotHvGV3E9tDejDeS04sN1veIebsKYGMuGscFaswRoYJKmT3eW85eIJAs0F28bG2+a/9wCOfPw==", "dev": true, + "license": "MIT", "dependencies": { "cachedir": "2.3.0", "cz-conventional-changelog": "3.3.0", @@ -9871,9 +7049,8 @@ }, "node_modules/commitizen/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -9886,9 +7063,8 @@ }, "node_modules/commitizen/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -9902,9 +7078,8 @@ }, "node_modules/commitizen/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -9914,15 +7089,13 @@ }, "node_modules/commitizen/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/commitizen/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -9940,18 +7113,16 @@ }, "node_modules/commitizen/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/commitizen/node_modules/inquirer": { "version": "8.2.5", - "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-8.2.5.tgz", - "integrity": "sha512-QAgPDQMEgrDssk1XiwwHoOGYF9BAbUcc1+j+FhEvaOt8/cKRqyLn0U5qA6F74fGhTMGxf92pOvPBeh29jQJDTQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-escapes": "^4.2.1", "chalk": "^4.1.1", @@ -9975,9 +7146,8 @@ }, "node_modules/commitizen/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -9987,9 +7157,8 @@ }, "node_modules/commitlint": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/commitlint/-/commitlint-17.8.1.tgz", - "integrity": "sha512-X+VPJwZsQDeGj/DG1NsxhZEl+oMHKNC+1myZ/zauNDoo+7OuLHfTOUU1C1a4CjKW4b6T7NuoFcYfK0kRCjCtbA==", "dev": true, + "license": "MIT", "dependencies": { "@commitlint/cli": "^17.8.1", "@commitlint/types": "^17.8.1" @@ -10003,9 +7172,8 @@ }, "node_modules/commitlint/node_modules/@commitlint/types": { "version": "17.8.1", - "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.8.1.tgz", - "integrity": "sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0" }, @@ -10015,9 +7183,8 @@ }, "node_modules/commitlint/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -10030,9 +7197,8 @@ }, "node_modules/commitlint/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -10046,9 +7212,8 @@ }, "node_modules/commitlint/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -10058,24 +7223,21 @@ }, "node_modules/commitlint/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/commitlint/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/commitlint/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -10085,15 +7247,13 @@ }, "node_modules/commondir": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/compare-func": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/compare-func/-/compare-func-2.0.0.tgz", - "integrity": "sha512-zHig5N+tPWARooBnb0Zx1MFcdfpyJrfTJ3Y5L+IFvUm8rM74hHz66z0gw0x4tijh5CorKkKUCnW82R2vmpeCRA==", "dev": true, + "license": "MIT", "dependencies": { "array-ify": "^1.0.0", "dot-prop": "^5.1.0" @@ -10101,8 +7261,6 @@ }, "node_modules/component-each": { "version": "0.2.6", - "resolved": "https://registry.npmjs.org/component-each/-/component-each-0.2.6.tgz", - "integrity": "sha512-IOXG+HZmbgaBS8Rqy+tAMrwsPdEY1BWcPcp0xI2ZOzKQhHvSVGrL7iCnoDU37TEKOCfaf4ywsR6GwAr0JivPjg==", "dependencies": { "component-type": "1.0.0", "to-function": "2.0.6" @@ -10110,36 +7268,29 @@ }, "node_modules/component-emitter": { "version": "1.3.1", - "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.1.tgz", - "integrity": "sha512-T0+barUSQRTUQASh8bx02dl+DhF54GtIDY13Y3m9oWTklKbb3Wv974meRpeZ3lp1JpLVECWWNHC4vaG2XHXouQ==", "dev": true, + "license": "MIT", "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/component-props": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/component-props/-/component-props-1.1.1.tgz", - "integrity": "sha512-69pIRJs9fCCHRqCz3390YF2LV1Lu6iEMZ5zuVqqUn+G20V9BNXlMs0cWawWeW9g4Ynmg29JmkG6R7/lUJoGd1Q==" + "version": "1.1.1" }, "node_modules/component-type": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/component-type/-/component-type-1.0.0.tgz", - "integrity": "sha512-qzUg4SGDH6KFYlcklmeZwucbtosh/XGwuIffqXAhC1dZyjO7Xu1UuaxwKRY29EncuBj/DH+h6Zot3AdZS6xdFw==" + "version": "1.0.0" }, "node_modules/concat-map": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + "license": "MIT" }, "node_modules/concat-stream": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-2.0.0.tgz", - "integrity": "sha512-MWufYdFw53ccGjCA+Ol7XJYpAlW6/prSMzuPOTRnJGcGzuhLn4Scrz7qf6o8bROZ514ltazcIFJZevcfbo0x7A==", "dev": true, "engines": [ "node >= 6.0" ], + "license": "MIT", "dependencies": { "buffer-from": "^1.0.0", "inherits": "^2.0.3", @@ -10149,9 +7300,8 @@ }, "node_modules/concat-stream/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -10163,18 +7313,15 @@ }, "node_modules/confusing-browser-globals": { "version": "1.0.11", - "resolved": "https://registry.npmjs.org/confusing-browser-globals/-/confusing-browser-globals-1.0.11.tgz", - "integrity": "sha512-JsPKdmh8ZkmnHxDk55FZ1TqVLvEQTvoByJZRN9jzI0UjxK/QgAmsphz7PGtqgPieQZ/CQcHWXCR7ATDNhGe+YA==" + "license": "MIT" }, "node_modules/console-control-strings": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", - "integrity": "sha512-ty/fTekppD2fIwRvnZAVdeOiGd1c7YXEixbgJTNzqcxJWKQnjJ/V1bNEEE6hygpM3WjwHFUVK6HTjWSzV4a8sQ==" + "license": "ISC" }, "node_modules/content-disposition": { "version": "0.5.4", - "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", - "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", + "license": "MIT", "dependencies": { "safe-buffer": "5.2.1" }, @@ -10184,17 +7331,15 @@ }, "node_modules/content-type": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", - "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/conventional-changelog": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/conventional-changelog/-/conventional-changelog-2.0.3.tgz", - "integrity": "sha512-4bcII9cJHSKb2qi9e8qGF6aJHLf/AB0dokhyR+X6QILTMl77s4l163vK+reXhajvfOYbbHQvsrWybr5+PKZwNA==", "dev": true, + "license": "MIT", "dependencies": { "conventional-changelog-angular": "^1.6.6", "conventional-changelog-atom": "^2.0.0", @@ -10214,9 +7359,8 @@ }, "node_modules/conventional-changelog-angular": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-angular/-/conventional-changelog-angular-6.0.0.tgz", - "integrity": "sha512-6qLgrBF4gueoC7AFVHu51nHL9pF9FRjXrH+ceVf7WmAfH3gs+gEYOkvxhjMPjZu57I4AGUGoNTY8V7Hrgf1uqg==", "dev": true, + "license": "ISC", "dependencies": { "compare-func": "^2.0.0" }, @@ -10226,9 +7370,8 @@ }, "node_modules/conventional-changelog-atom": { "version": "2.0.8", - "resolved": "https://registry.npmjs.org/conventional-changelog-atom/-/conventional-changelog-atom-2.0.8.tgz", - "integrity": "sha512-xo6v46icsFTK3bb7dY/8m2qvc8sZemRgdqLb/bjpBsH2UyOS8rKNTgcb5025Hri6IpANPApbXMg15QLb1LJpBw==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.5.1" }, @@ -10238,9 +7381,8 @@ }, "node_modules/conventional-changelog-codemirror": { "version": "2.0.8", - "resolved": "https://registry.npmjs.org/conventional-changelog-codemirror/-/conventional-changelog-codemirror-2.0.8.tgz", - "integrity": "sha512-z5DAsn3uj1Vfp7po3gpt2Boc+Bdwmw2++ZHa5Ak9k0UKsYAO5mH1UBTN0qSCuJZREIhX6WU4E1p3IW2oRCNzQw==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.5.1" }, @@ -10250,15 +7392,13 @@ }, "node_modules/conventional-changelog-config-spec": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-config-spec/-/conventional-changelog-config-spec-2.1.0.tgz", - "integrity": "sha512-IpVePh16EbbB02V+UA+HQnnPIohgXvJRxHcS5+Uwk4AT5LjzCZJm5sp/yqs5C6KZJ1jMsV4paEV13BN1pvDuxQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/conventional-changelog-conventionalcommits": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-conventionalcommits/-/conventional-changelog-conventionalcommits-6.1.0.tgz", - "integrity": "sha512-3cS3GEtR78zTfMzk0AizXKKIdN4OvSh7ibNz6/DPbhWWQu7LqE/8+/GqSodV+sywUR2gpJAdP/1JFf4XtN7Zpw==", "dev": true, + "license": "ISC", "dependencies": { "compare-func": "^2.0.0" }, @@ -10268,9 +7408,8 @@ }, "node_modules/conventional-changelog-core": { "version": "3.2.3", - "resolved": "https://registry.npmjs.org/conventional-changelog-core/-/conventional-changelog-core-3.2.3.tgz", - "integrity": "sha512-LMMX1JlxPIq/Ez5aYAYS5CpuwbOk6QFp8O4HLAcZxe3vxoCtABkhfjetk8IYdRB9CDQGwJFLR3Dr55Za6XKgUQ==", "dev": true, + "license": "MIT", "dependencies": { "conventional-changelog-writer": "^4.0.6", "conventional-commits-parser": "^3.0.3", @@ -10292,18 +7431,16 @@ }, "node_modules/conventional-changelog-core/node_modules/camelcase": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz", - "integrity": "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/conventional-changelog-core/node_modules/camelcase-keys": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-4.2.0.tgz", - "integrity": "sha512-Ej37YKYbFUI8QiYlvj9YHb6/Z60dZyPJW0Cs8sFilMbd2lP0bw3ylAq9yJkK4lcTA2dID5fG8LjmJYbO7kWb7Q==", "dev": true, + "license": "MIT", "dependencies": { "camelcase": "^4.1.0", "map-obj": "^2.0.0", @@ -10315,9 +7452,8 @@ }, "node_modules/conventional-changelog-core/node_modules/conventional-commits-parser": { "version": "3.2.4", - "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-3.2.4.tgz", - "integrity": "sha512-nK7sAtfi+QXbxHCYfhpZsfRtaitZLIA6889kFIouLvz6repszQDgxBu7wf2WbU+Dco7sAnNCJYERCwt54WPC2Q==", "dev": true, + "license": "MIT", "dependencies": { "is-text-path": "^1.0.1", "JSONStream": "^1.0.4", @@ -10335,9 +7471,8 @@ }, "node_modules/conventional-changelog-core/node_modules/conventional-commits-parser/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -10349,18 +7484,16 @@ }, "node_modules/conventional-changelog-core/node_modules/conventional-commits-parser/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/conventional-changelog-core/node_modules/dargs": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/dargs/-/dargs-4.1.0.tgz", - "integrity": "sha512-jyweV/k0rbv2WK4r9KLayuBrSh2Py0tNmV7LBoSMH4hMQyrG8OPyIOWB2VEx4DJKXWmK4lopYMVvORlDt2S8Aw==", "dev": true, + "license": "MIT", "dependencies": { "number-is-nan": "^1.0.0" }, @@ -10370,9 +7503,8 @@ }, "node_modules/conventional-changelog-core/node_modules/git-raw-commits": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/git-raw-commits/-/git-raw-commits-2.0.0.tgz", - "integrity": "sha512-w4jFEJFgKXMQJ0H0ikBk2S+4KP2VEjhCvLCNqbNRQC8BgGWgLKNCO7a9K9LI+TVT7Gfoloje502sEnctibffgg==", "dev": true, + "license": "MIT", "dependencies": { "dargs": "^4.0.1", "lodash.template": "^4.0.2", @@ -10389,9 +7521,8 @@ }, "node_modules/conventional-changelog-core/node_modules/git-raw-commits/node_modules/meow": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/meow/-/meow-4.0.1.tgz", - "integrity": "sha512-xcSBHD5Z86zaOc+781KrupuHAzeGXSLtiAOmBsiLDiPSaYSB6hdew2ng9EBAnZ62jagG9MHAOdxpDi/lWBFJ/A==", "dev": true, + "license": "MIT", "dependencies": { "camelcase-keys": "^4.0.0", "decamelize-keys": "^1.0.0", @@ -10409,18 +7540,16 @@ }, "node_modules/conventional-changelog-core/node_modules/git-raw-commits/node_modules/split2": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/split2/-/split2-2.2.0.tgz", - "integrity": "sha512-RAb22TG39LhI31MbreBgIuKiIKhVsawfTgEGqKHTK87aG+ul/PB8Sqoi3I7kVdRWiCfrKxK3uo4/YUkpNvhPbw==", "dev": true, + "license": "ISC", "dependencies": { "through2": "^2.0.2" } }, "node_modules/conventional-changelog-core/node_modules/git-raw-commits/node_modules/through2": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", - "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "~2.3.6", "xtend": "~4.0.1" @@ -10428,27 +7557,24 @@ }, "node_modules/conventional-changelog-core/node_modules/indent-string": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-3.2.0.tgz", - "integrity": "sha512-BYqTHXTGUIvg7t1r4sJNKcbDZkL92nkXA8YtRpbjFHRHGDL/NtUeiBJMeE60kIFN/Mg8ESaWQvftaYMGJzQZCQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/conventional-changelog-core/node_modules/map-obj": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-2.0.0.tgz", - "integrity": "sha512-TzQSV2DiMYgoF5RycneKVUzIa9bQsj/B3tTgsE3dOGqlzHnGIDaC7XBE7grnA+8kZPnfqSGFe95VHc2oc0VFUQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/conventional-changelog-core/node_modules/minimist-options": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/minimist-options/-/minimist-options-3.0.2.tgz", - "integrity": "sha512-FyBrT/d0d4+uiZRbqznPXqw3IpZZG3gl3wKWiX784FycUKVwBt0uLBFkQrtE4tZOrgo78nZp2jnKz3L65T5LdQ==", "dev": true, + "license": "MIT", "dependencies": { "arrify": "^1.0.1", "is-plain-obj": "^1.1.0" @@ -10459,18 +7585,16 @@ }, "node_modules/conventional-changelog-core/node_modules/quick-lru": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-1.1.0.tgz", - "integrity": "sha512-tRS7sTgyxMXtLum8L65daJnHUhfDUgboRdcWW2bR9vBfrj2+O5HSMbQOJfJJjIVSPFqbBCF37FpwWXGitDc5tA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/conventional-changelog-core/node_modules/redent": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-2.0.0.tgz", - "integrity": "sha512-XNwrTx77JQCEMXTeb8movBKuK75MgH0RZkujNuDKCezemx/voapl9i2gCSi8WWm8+ox5ycJi1gxF22fR7c0Ciw==", "dev": true, + "license": "MIT", "dependencies": { "indent-string": "^3.0.0", "strip-indent": "^2.0.0" @@ -10481,18 +7605,16 @@ }, "node_modules/conventional-changelog-core/node_modules/strip-indent": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-2.0.0.tgz", - "integrity": "sha512-RsSNPLpq6YUL7QYy44RnPVTn/lcVZtb48Uof3X5JLbF4zD/Gs7ZFDv2HWol+leoQN2mT86LAzSshGfkTlSOpsA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/conventional-changelog-core/node_modules/through2": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-3.0.2.tgz", - "integrity": "sha512-enaDQ4MUyP2W6ZyT6EsMzqBPZaM/avg8iuo+l2d3QCs0J+6RaqkHV/2/lOwDTueBHeJ/2LG9lrLW3d5rWPucuQ==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.4", "readable-stream": "2 || 3" @@ -10500,9 +7622,8 @@ }, "node_modules/conventional-changelog-ember": { "version": "2.0.9", - "resolved": "https://registry.npmjs.org/conventional-changelog-ember/-/conventional-changelog-ember-2.0.9.tgz", - "integrity": "sha512-ulzIReoZEvZCBDhcNYfDIsLTHzYHc7awh+eI44ZtV5cx6LVxLlVtEmcO+2/kGIHGtw+qVabJYjdI5cJOQgXh1A==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.5.1" }, @@ -10512,9 +7633,8 @@ }, "node_modules/conventional-changelog-eslint": { "version": "3.0.9", - "resolved": "https://registry.npmjs.org/conventional-changelog-eslint/-/conventional-changelog-eslint-3.0.9.tgz", - "integrity": "sha512-6NpUCMgU8qmWmyAMSZO5NrRd7rTgErjrm4VASam2u5jrZS0n38V7Y9CzTtLT2qwz5xEChDR4BduoWIr8TfwvXA==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.5.1" }, @@ -10524,9 +7644,8 @@ }, "node_modules/conventional-changelog-express": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/conventional-changelog-express/-/conventional-changelog-express-2.0.6.tgz", - "integrity": "sha512-SDez2f3iVJw6V563O3pRtNwXtQaSmEfTCaTBPCqn0oG0mfkq0rX4hHBq5P7De2MncoRixrALj3u3oQsNK+Q0pQ==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.5.1" }, @@ -10536,27 +7655,24 @@ }, "node_modules/conventional-changelog-jquery": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-jquery/-/conventional-changelog-jquery-0.1.0.tgz", - "integrity": "sha512-wbz5vVcvu/SPZTDFB21fF/xo5zFq6NQR42jhtUfOrrP1N/ZjNshhGb3expCGqHYdnUHzPevHeUafsVrdxVD5Og==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.4.1" } }, "node_modules/conventional-changelog-jscs": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-jscs/-/conventional-changelog-jscs-0.1.0.tgz", - "integrity": "sha512-V8sey4tE0nJUlWGi2PZKDMfawYLf/+F165xhhDjcIoTEJDxssVV5PMVzTQzjS6U/dEX85fWkur+bs6imOqkIng==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.4.1" } }, "node_modules/conventional-changelog-jshint": { "version": "2.0.9", - "resolved": "https://registry.npmjs.org/conventional-changelog-jshint/-/conventional-changelog-jshint-2.0.9.tgz", - "integrity": "sha512-wMLdaIzq6TNnMHMy31hql02OEQ8nCQfExw1SE0hYL5KvU+JCTuPaDO+7JiogGT2gJAxiUGATdtYYfh+nT+6riA==", "dev": true, + "license": "ISC", "dependencies": { "compare-func": "^2.0.0", "q": "^1.5.1" @@ -10567,18 +7683,16 @@ }, "node_modules/conventional-changelog-preset-loader": { "version": "2.3.4", - "resolved": "https://registry.npmjs.org/conventional-changelog-preset-loader/-/conventional-changelog-preset-loader-2.3.4.tgz", - "integrity": "sha512-GEKRWkrSAZeTq5+YjUZOYxdHq+ci4dNwHvpaBC3+ENalzFWuCWa9EZXSuZBpkr72sMdKB+1fyDV4takK1Lf58g==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" } }, "node_modules/conventional-changelog-writer": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-4.1.0.tgz", - "integrity": "sha512-WwKcUp7WyXYGQmkLsX4QmU42AZ1lqlvRW9mqoyiQzdD+rJWbTepdWoKJuwXTS+yq79XKnQNa93/roViPQrAQgw==", "dev": true, + "license": "MIT", "dependencies": { "compare-func": "^2.0.0", "conventional-commits-filter": "^2.0.7", @@ -10600,9 +7714,8 @@ }, "node_modules/conventional-changelog-writer/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -10614,27 +7727,24 @@ }, "node_modules/conventional-changelog-writer/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/conventional-changelog-writer/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/conventional-changelog/node_modules/compare-func": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/compare-func/-/compare-func-1.3.4.tgz", - "integrity": "sha512-sq2sWtrqKPkEXAC8tEJA1+BqAH9GbFkGBtUOqrUX57VSfwp8xyktctk+uLoRy5eccTdxzDcVIztlYDpKs3Jv1Q==", "dev": true, + "license": "MIT", "dependencies": { "array-ify": "^1.0.0", "dot-prop": "^3.0.0" @@ -10642,9 +7752,8 @@ }, "node_modules/conventional-changelog/node_modules/conventional-changelog-angular": { "version": "1.6.6", - "resolved": "https://registry.npmjs.org/conventional-changelog-angular/-/conventional-changelog-angular-1.6.6.tgz", - "integrity": "sha512-suQnFSqCxRwyBxY68pYTsFkG0taIdinHLNEAX5ivtw8bCRnIgnpvcHmlR/yjUyZIrNPYAoXlY1WiEKWgSE4BNg==", "dev": true, + "license": "ISC", "dependencies": { "compare-func": "^1.3.1", "q": "^1.5.1" @@ -10652,15 +7761,13 @@ }, "node_modules/conventional-commit-types": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/conventional-commit-types/-/conventional-commit-types-3.0.0.tgz", - "integrity": "sha512-SmmCYnOniSsAa9GqWOeLqc179lfr5TRu5b4QFDkbsrJ5TZjPJx85wtOr3zn+1dbeNiXDKGPbZ72IKbPhLXh/Lg==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/conventional-commits-filter": { "version": "2.0.7", - "resolved": "https://registry.npmjs.org/conventional-commits-filter/-/conventional-commits-filter-2.0.7.tgz", - "integrity": "sha512-ASS9SamOP4TbCClsRHxIHXRfcGCnIoQqkvAzCSbZzTFLfcTqJVugB0agRgsEELsqaeWgsXv513eS116wnlSSPA==", "dev": true, + "license": "MIT", "dependencies": { "lodash.ismatch": "^4.4.0", "modify-values": "^1.0.0" @@ -10671,9 +7778,8 @@ }, "node_modules/conventional-commits-parser": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-4.0.0.tgz", - "integrity": "sha512-WRv5j1FsVM5FISJkoYMR6tPk07fkKT0UodruX4je86V4owk451yjXAKzKAPOs9l7y59E2viHUS9eQ+dfUA9NSg==", "dev": true, + "license": "MIT", "dependencies": { "is-text-path": "^1.0.1", "JSONStream": "^1.3.5", @@ -10689,9 +7795,8 @@ }, "node_modules/conventional-github-releaser": { "version": "3.1.5", - "resolved": "https://registry.npmjs.org/conventional-github-releaser/-/conventional-github-releaser-3.1.5.tgz", - "integrity": "sha512-VhPKbdN92b2ygnQLkuwHIfUaPAVrVfJVuQdxbmmVPkN927LDP98HthLWFVShh4pxqLK0nE66v78RERGJVeCzbg==", "dev": true, + "license": "MIT", "dependencies": { "conventional-changelog": "^2.0.0", "dateformat": "^3.0.0", @@ -10715,27 +7820,24 @@ }, "node_modules/conventional-github-releaser/node_modules/camelcase": { "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/conventional-github-releaser/node_modules/debug": { "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", "dev": true, + "license": "MIT", "dependencies": { "ms": "^2.1.1" } }, "node_modules/conventional-github-releaser/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -10746,9 +7848,8 @@ }, "node_modules/conventional-github-releaser/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -10758,9 +7859,8 @@ }, "node_modules/conventional-github-releaser/node_modules/meow": { "version": "7.1.1", - "resolved": "https://registry.npmjs.org/meow/-/meow-7.1.1.tgz", - "integrity": "sha512-GWHvA5QOcS412WCo8vwKDlTelGLsCGBVevQB5Kva961rmNfun0PCbv5+xta2kUMFJyR8/oWnn7ddeKdosbAPbA==", "dev": true, + "license": "MIT", "dependencies": { "@types/minimist": "^1.2.0", "camelcase-keys": "^6.2.2", @@ -10783,9 +7883,8 @@ }, "node_modules/conventional-github-releaser/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -10798,9 +7897,8 @@ }, "node_modules/conventional-github-releaser/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -10810,9 +7908,8 @@ }, "node_modules/conventional-github-releaser/node_modules/read-pkg": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", - "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", "dev": true, + "license": "MIT", "dependencies": { "@types/normalize-package-data": "^2.4.0", "normalize-package-data": "^2.5.0", @@ -10825,9 +7922,8 @@ }, "node_modules/conventional-github-releaser/node_modules/read-pkg-up": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", - "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^4.1.0", "read-pkg": "^5.2.0", @@ -10842,36 +7938,32 @@ }, "node_modules/conventional-github-releaser/node_modules/read-pkg-up/node_modules/type-fest": { "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/conventional-github-releaser/node_modules/read-pkg/node_modules/type-fest": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", - "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/conventional-github-releaser/node_modules/semver": { "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver" } }, "node_modules/conventional-github-releaser/node_modules/type-fest": { "version": "0.13.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz", - "integrity": "sha512-34R7HTnG0XIJcBSn5XhDd7nNFPRcXYRZrBB2O2jdKqYODldSzBAqzsWoZYYvduky73toYS/ESqxPvkDf/F0XMg==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=10" }, @@ -10881,9 +7973,8 @@ }, "node_modules/conventional-github-releaser/node_modules/yargs-parser": { "version": "18.1.3", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", - "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", "dev": true, + "license": "ISC", "dependencies": { "camelcase": "^5.0.0", "decamelize": "^1.2.0" @@ -10894,9 +7985,8 @@ }, "node_modules/conventional-recommended-bump": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/conventional-recommended-bump/-/conventional-recommended-bump-6.1.0.tgz", - "integrity": "sha512-uiApbSiNGM/kkdL9GTOLAqC4hbptObFo4wW2QRyHsKciGAfQuLU1ShZ1BIVI/+K2BE/W1AWYQMCXAsv4dyKPaw==", "dev": true, + "license": "MIT", "dependencies": { "concat-stream": "^2.0.0", "conventional-changelog-preset-loader": "^2.3.4", @@ -10916,9 +8006,8 @@ }, "node_modules/conventional-recommended-bump/node_modules/conventional-commits-parser": { "version": "3.2.4", - "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-3.2.4.tgz", - "integrity": "sha512-nK7sAtfi+QXbxHCYfhpZsfRtaitZLIA6889kFIouLvz6repszQDgxBu7wf2WbU+Dco7sAnNCJYERCwt54WPC2Q==", "dev": true, + "license": "MIT", "dependencies": { "is-text-path": "^1.0.1", "JSONStream": "^1.0.4", @@ -10936,9 +8025,8 @@ }, "node_modules/conventional-recommended-bump/node_modules/git-semver-tags": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/git-semver-tags/-/git-semver-tags-4.1.1.tgz", - "integrity": "sha512-OWyMt5zBe7xFs8vglMmhM9lRQzCWL3WjHtxNNfJTMngGym7pC1kh8sP6jevfydJ6LP3ZvGxfb6ABYgPUM0mtsA==", "dev": true, + "license": "MIT", "dependencies": { "meow": "^8.0.0", "semver": "^6.0.0" @@ -10952,9 +8040,8 @@ }, "node_modules/conventional-recommended-bump/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -10966,48 +8053,39 @@ }, "node_modules/conventional-recommended-bump/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/conventional-recommended-bump/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/convert-hex": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/convert-hex/-/convert-hex-0.1.0.tgz", - "integrity": "sha512-w20BOb1PiR/sEJdS6wNrUjF5CSfscZFUp7R9NSlXH8h2wynzXVEPFPJECAnkNylZ+cvf3p7TyRUHggDmrwXT9A==" + "version": "0.1.0" }, "node_modules/convert-source-map": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", - "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/convert-string": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/convert-string/-/convert-string-0.1.0.tgz", - "integrity": "sha512-1KX9ESmtl8xpT2LN2tFnKSbV4NiarbVi8DVb39ZriijvtTklyrT+4dT1wsGMHKD3CJUjXgvJzstm9qL9ICojGA==" + "version": "0.1.0" }, "node_modules/cookiejar": { "version": "2.1.4", - "resolved": "https://registry.npmjs.org/cookiejar/-/cookiejar-2.1.4.tgz", - "integrity": "sha512-LDx6oHrK+PhzLKJU9j5S7/Y3jM/mUHvD/DeI1WQmJn652iPC5Y4TBzC9l+5OMOXlyTTA+SmVUPm0HQUwpD5Jqw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cookies": { "version": "0.9.1", - "resolved": "https://registry.npmjs.org/cookies/-/cookies-0.9.1.tgz", - "integrity": "sha512-TG2hpqe4ELx54QER/S3HQ9SRVnQnGBtKUz5bLQWtYAQ+o6GpgMs6sYUvaiJjVxb+UXwhRhAEP3m7LbsIZ77Hmw==", + "license": "MIT", "dependencies": { "depd": "~2.0.0", "keygrip": "~1.1.0" @@ -11018,20 +8096,17 @@ }, "node_modules/copy-to": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/copy-to/-/copy-to-2.0.1.tgz", - "integrity": "sha512-3DdaFaU/Zf1AnpLiFDeNCD4TOWe3Zl2RZaTzUvWiIk5ERzcCodOE20Vqq4fzCbNoHURFHT4/us/Lfq+S2zyY4w==" + "license": "MIT" }, "node_modules/core-util-is": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", - "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cosmiconfig": { "version": "8.3.6", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz", - "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==", "dev": true, + "license": "MIT", "dependencies": { "import-fresh": "^3.3.0", "js-yaml": "^4.1.0", @@ -11055,9 +8130,8 @@ }, "node_modules/cosmiconfig-typescript-loader": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cosmiconfig-typescript-loader/-/cosmiconfig-typescript-loader-5.0.0.tgz", - "integrity": "sha512-+8cK7jRAReYkMwMiG+bxhcNKiHJDM6bR9FD/nGBXOWdMLuYawjF5cGrtLilJ+LGd3ZjCXnJjR5DkfWPoIVlqJA==", "dev": true, + "license": "MIT", "optional": true, "dependencies": { "jiti": "^1.19.1" @@ -11073,9 +8147,8 @@ }, "node_modules/create-jest": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/create-jest/-/create-jest-29.7.0.tgz", - "integrity": "sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "chalk": "^4.0.0", @@ -11094,9 +8167,8 @@ }, "node_modules/create-jest/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -11109,9 +8181,8 @@ }, "node_modules/create-jest/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -11125,9 +8196,8 @@ }, "node_modules/create-jest/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -11137,24 +8207,21 @@ }, "node_modules/create-jest/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/create-jest/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/create-jest/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -11164,14 +8231,12 @@ }, "node_modules/create-require": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cross-spawn": { "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "license": "MIT", "dependencies": { "path-key": "^3.1.0", "shebang-command": "^2.0.0", @@ -11183,28 +8248,23 @@ }, "node_modules/crypt": { "version": "0.0.2", - "resolved": "https://registry.npmjs.org/crypt/-/crypt-0.0.2.tgz", - "integrity": "sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow==", + "license": "BSD-3-Clause", "engines": { "node": "*" } }, "node_modules/crypto": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/crypto/-/crypto-1.0.1.tgz", - "integrity": "sha512-VxBKmeNcqQdiUQUW2Tzq0t377b54N2bMtXO/qiLa+6eRRmmC4qT3D4OnTGoT/U6O9aklQ/jTwbOtRMTTY8G0Ig==", - "deprecated": "This package is no longer supported. It's now a built-in Node module. If you've depended on crypto, you should switch to the one that's built-in." + "license": "ISC" }, "node_modules/crypto-js": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.2.0.tgz", - "integrity": "sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==" + "license": "MIT" }, "node_modules/currently-unhandled": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/currently-unhandled/-/currently-unhandled-0.4.1.tgz", - "integrity": "sha512-/fITjgjGU50vjQ4FH6eUoYu+iUoUKIXws2hL15JJpIR+BbTxaXQsMuuyjtNh2WqsSBS5nsaZHFsFecyw5CCAng==", "dev": true, + "license": "MIT", "dependencies": { "array-find-index": "^1.0.1" }, @@ -11214,9 +8274,8 @@ }, "node_modules/cz-conventional-changelog": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/cz-conventional-changelog/-/cz-conventional-changelog-3.3.0.tgz", - "integrity": "sha512-U466fIzU5U22eES5lTNiNbZ+d8dfcHcssH4o7QsdWaCcRs/feIPCxKYSWkYBNs5mny7MvEfwpTLWjvbm94hecw==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^2.4.1", "commitizen": "^4.0.3", @@ -11234,26 +8293,23 @@ }, "node_modules/dargs": { "version": "7.0.0", - "resolved": "https://registry.npmjs.org/dargs/-/dargs-7.0.0.tgz", - "integrity": "sha512-2iy1EkLdlBzQGvbweYRFxmFath8+K7+AKB0TlhHWkNuH+TmovaMH/Wp7V7R4u7f4SnX3OgLsU9t1NI9ioDnUpg==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/dateformat": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", - "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==", "dev": true, + "license": "MIT", "engines": { "node": "*" } }, "node_modules/debug": { "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "license": "MIT", "dependencies": { "ms": "2.1.2" }, @@ -11268,18 +8324,16 @@ }, "node_modules/decamelize": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/decamelize-keys": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/decamelize-keys/-/decamelize-keys-1.1.1.tgz", - "integrity": "sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==", "dev": true, + "license": "MIT", "dependencies": { "decamelize": "^1.1.0", "map-obj": "^1.0.0" @@ -11293,27 +8347,24 @@ }, "node_modules/decamelize-keys/node_modules/map-obj": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", - "integrity": "sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/decode-uri-component": { "version": "0.2.2", - "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", - "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10" } }, "node_modules/decompress-response": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-3.3.0.tgz", - "integrity": "sha512-BzRPQuY1ip+qDonAOz42gRm/pg9F768C+npV/4JOsxRC2sq+Rlk+Q4ZCAsOhnIaMrgarILY+RMUIvMmmX1qAEA==", "dev": true, + "license": "MIT", "dependencies": { "mimic-response": "^1.0.0" }, @@ -11323,42 +8374,36 @@ }, "node_modules/dedent": { "version": "0.7.0", - "resolved": "https://registry.npmjs.org/dedent/-/dedent-0.7.0.tgz", - "integrity": "sha512-Q6fKUPqnAHAyhiUgFU7BUzLiv0kd8saH9al7tnu5Q/okj6dnupxyTgFIBjVzJATdfIAm9NAsvXNzjaKa+bxVyA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/deep-equal": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-1.0.1.tgz", - "integrity": "sha512-bHtC0iYvWhyaTzvV3CZgPeZQqCOBGyGsVV7v4eevpdkLHfiSrXUdBG+qAuSz4RI70sszvjQ1QSZ98An1yNwpSw==" + "license": "MIT" }, "node_modules/deep-extend": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", - "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4.0.0" } }, "node_modules/deep-is": { "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==" + "license": "MIT" }, "node_modules/deepmerge": { "version": "4.3.1", - "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", - "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/defaults": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz", - "integrity": "sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==", + "license": "MIT", "dependencies": { "clone": "^1.0.2" }, @@ -11368,16 +8413,14 @@ }, "node_modules/defaults/node_modules/clone": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==", + "license": "MIT", "engines": { "node": ">=0.8" } }, "node_modules/define-data-property": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.1.tgz", - "integrity": "sha512-E7uGkTzkk1d0ByLeSc6ZsFS79Axg+m1P/VsgYsxHgiuc3tFSj+MjMIwe90FC4lOAZzNBdY7kkO2P2wKdsQ1vgQ==", + "license": "MIT", "dependencies": { "get-intrinsic": "^1.2.1", "gopd": "^1.0.1", @@ -11389,8 +8432,7 @@ }, "node_modules/define-properties": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", - "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "license": "MIT", "dependencies": { "define-data-property": "^1.0.1", "has-property-descriptors": "^1.0.0", @@ -11405,8 +8447,7 @@ }, "node_modules/delay": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/delay/-/delay-5.0.0.tgz", - "integrity": "sha512-ReEBKkIfe4ya47wlPYf/gu5ib6yUG0/Aez0JQZQz94kiWtRQvZIQbTiehsnwHvLSWJnQdhVeqYue7Id1dKr0qw==", + "license": "MIT", "engines": { "node": ">=10" }, @@ -11416,38 +8457,33 @@ }, "node_modules/delayed-stream": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "license": "MIT", "engines": { "node": ">=0.4.0" } }, "node_modules/delegates": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", - "integrity": "sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ==" + "license": "MIT" }, "node_modules/denque": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/denque/-/denque-2.1.0.tgz", - "integrity": "sha512-HVQE3AAb/pxF8fQAoiqpvg9i3evqug3hoiwakOyZAwJm+6vZehbkYXZ0l4JxS+I3QxM97v5aaRNhj8v5oBhekw==", + "license": "Apache-2.0", "engines": { "node": ">=0.10" } }, "node_modules/depd": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", - "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/dependency-tree": { "version": "9.0.0", - "resolved": "https://registry.npmjs.org/dependency-tree/-/dependency-tree-9.0.0.tgz", - "integrity": "sha512-osYHZJ1fBSon3lNLw70amAXsQ+RGzXsPvk9HbBgTLbp/bQBmpH5mOmsUvqXU+YEWVU0ZLewsmzOET/8jWswjDQ==", "dev": true, + "license": "MIT", "dependencies": { "commander": "^2.20.3", "debug": "^4.3.1", @@ -11464,24 +8500,21 @@ }, "node_modules/dependency-tree/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/dependency-tree/node_modules/detective-stylus": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/detective-stylus/-/detective-stylus-3.0.0.tgz", - "integrity": "sha512-1xYTzbrduExqMYmte7Qk99IRA3Aa6oV7PYzd+3yDcQXkmENvyGF/arripri6lxRDdNYEb4fZFuHtNRAXbz3iAA==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" } }, "node_modules/dependency-tree/node_modules/module-definition": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/module-definition/-/module-definition-4.1.0.tgz", - "integrity": "sha512-rHXi/DpMcD2qcKbPCTklDbX9lBKJrUSl971TW5l6nMpqKCIlzJqmQ8cfEF5M923h2OOLHPDVlh5pJxNyV+AJlw==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^4.0.0", "node-source-walk": "^5.0.1" @@ -11495,9 +8528,8 @@ }, "node_modules/dependency-tree/node_modules/precinct": { "version": "9.2.1", - "resolved": "https://registry.npmjs.org/precinct/-/precinct-9.2.1.tgz", - "integrity": "sha512-uzKHaTyiVejWW7VJtHInb9KBUq9yl9ojxXGujhjhDmPon2wgZPBKQIKR+6csGqSlUeGXAA4MEFnU6DesxZib+A==", "dev": true, + "license": "MIT", "dependencies": { "@dependents/detective-less": "^3.0.1", "commander": "^9.5.0", @@ -11521,18 +8553,16 @@ }, "node_modules/dependency-tree/node_modules/precinct/node_modules/commander": { "version": "9.5.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz", - "integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==", "dev": true, + "license": "MIT", "engines": { "node": "^12.20.0 || >=14" } }, "node_modules/dependency-tree/node_modules/typescript": { "version": "4.9.5", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.5.tgz", - "integrity": "sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==", "dev": true, + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -11543,8 +8573,7 @@ }, "node_modules/destroy": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", - "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", + "license": "MIT", "engines": { "node": ">= 0.8", "npm": "1.2.8000 || >= 1.4.16" @@ -11552,44 +8581,39 @@ }, "node_modules/detect-file": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/detect-file/-/detect-file-1.0.0.tgz", - "integrity": "sha512-DtCOLG98P007x7wiiOmfI0fi3eIKyWiLTGJ2MDnVi/E04lWGbf+JzrRHMm0rgIIZJGtHpKpbVgLWHrv8xXpc3Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/detect-indent": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-6.1.0.tgz", - "integrity": "sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/detect-libc": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.3.tgz", - "integrity": "sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw==", + "license": "Apache-2.0", "engines": { "node": ">=8" } }, "node_modules/detect-newline": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", - "integrity": "sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/detective-amd": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/detective-amd/-/detective-amd-4.2.0.tgz", - "integrity": "sha512-RbuEJHz78A8nW7CklkqTzd8lDCN42En53dgEIsya0DilpkwslamSZDasLg8dJyxbw46OxhSQeY+C2btdSkCvQQ==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^4.0.0", "escodegen": "^2.0.0", @@ -11605,9 +8629,8 @@ }, "node_modules/detective-cjs": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/detective-cjs/-/detective-cjs-4.1.0.tgz", - "integrity": "sha512-QxzMwt5MfPLwS7mG30zvnmOvHLx5vyVvjsAV6gQOyuMoBR5G1DhS1eJZ4P10AlH+HSnk93mTcrg3l39+24XCtg==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^4.0.0", "node-source-walk": "^5.0.1" @@ -11618,9 +8641,8 @@ }, "node_modules/detective-es6": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/detective-es6/-/detective-es6-3.0.1.tgz", - "integrity": "sha512-evPeYIEdK1jK3Oji5p0hX4sPV/1vK+o4ihcWZkMQE6voypSW/cIBiynOLxQk5KOOQbdP8oOAsYqouMTYO5l1sw==", "dev": true, + "license": "MIT", "dependencies": { "node-source-walk": "^5.0.0" }, @@ -11630,9 +8652,8 @@ }, "node_modules/detective-less": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/detective-less/-/detective-less-1.0.2.tgz", - "integrity": "sha512-Rps1xDkEEBSq3kLdsdnHZL1x2S4NGDcbrjmd4q+PykK5aJwDdP5MBgrJw1Xo+kyUHuv3JEzPqxr+Dj9ryeDRTA==", "dev": true, + "license": "MIT", "dependencies": { "debug": "^4.0.0", "gonzales-pe": "^4.2.3", @@ -11644,9 +8665,8 @@ }, "node_modules/detective-less/node_modules/node-source-walk": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/node-source-walk/-/node-source-walk-4.3.0.tgz", - "integrity": "sha512-8Q1hXew6ETzqKRAs3jjLioSxNfT1cx74ooiF8RlAONwVMcfq+UdzLC2eB5qcPldUxaE5w3ytLkrmV1TGddhZTA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.0.0" }, @@ -11656,9 +8676,8 @@ }, "node_modules/detective-postcss": { "version": "6.1.3", - "resolved": "https://registry.npmjs.org/detective-postcss/-/detective-postcss-6.1.3.tgz", - "integrity": "sha512-7BRVvE5pPEvk2ukUWNQ+H2XOq43xENWbH0LcdCE14mwgTBEAMoAx+Fc1rdp76SmyZ4Sp48HlV7VedUnP6GA1Tw==", "dev": true, + "license": "MIT", "dependencies": { "is-url": "^1.2.4", "postcss": "^8.4.23", @@ -11670,9 +8689,8 @@ }, "node_modules/detective-sass": { "version": "4.1.3", - "resolved": "https://registry.npmjs.org/detective-sass/-/detective-sass-4.1.3.tgz", - "integrity": "sha512-xGRbwGaGte57gvEqM8B9GDiURY3El/H49vA6g9wFkxq9zalmTlTAuqWu+BsH0iwonGPruLt55tZZDEZqPc6lag==", "dev": true, + "license": "MIT", "dependencies": { "gonzales-pe": "^4.3.0", "node-source-walk": "^5.0.1" @@ -11683,9 +8701,8 @@ }, "node_modules/detective-scss": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/detective-scss/-/detective-scss-3.1.1.tgz", - "integrity": "sha512-FWkfru1jZBhUeuBsOeGKXKAVDrzYFSQFK2o2tuG/nCCFQ0U/EcXC157MNAcR5mmj+mCeneZzlkBOFJTesDjrww==", "dev": true, + "license": "MIT", "dependencies": { "gonzales-pe": "^4.3.0", "node-source-walk": "^5.0.1" @@ -11696,18 +8713,16 @@ }, "node_modules/detective-stylus": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/detective-stylus/-/detective-stylus-2.0.1.tgz", - "integrity": "sha512-/Tvs1pWLg8eYwwV6kZQY5IslGaYqc/GACxjcaGudiNtN5nKCH6o2WnJK3j0gA3huCnoQcbv8X7oz/c1lnvE3zQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0" } }, "node_modules/detective-typescript": { "version": "9.1.1", - "resolved": "https://registry.npmjs.org/detective-typescript/-/detective-typescript-9.1.1.tgz", - "integrity": "sha512-Uc1yVutTF0RRm1YJ3g//i1Cn2vx1kwHj15cnzQP6ff5koNzQ0idc1zAC73ryaWEulA0ElRXFTq6wOqe8vUQ3MA==", "dev": true, + "license": "MIT", "dependencies": { "@typescript-eslint/typescript-estree": "^5.55.0", "ast-module-types": "^4.0.0", @@ -11720,9 +8735,8 @@ }, "node_modules/detective-typescript/node_modules/typescript": { "version": "4.9.5", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.5.tgz", - "integrity": "sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==", "dev": true, + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -11733,9 +8747,8 @@ }, "node_modules/dezalgo": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/dezalgo/-/dezalgo-1.0.4.tgz", - "integrity": "sha512-rXSP0bf+5n0Qonsb+SVVfNfIsimO4HEtmnIpPHY8Q1UCzKlQrDMfdobr8nJOOsRgWCyMRqeSBQzmWUMq7zvVig==", "dev": true, + "license": "ISC", "dependencies": { "asap": "^2.0.0", "wrappy": "1" @@ -11743,26 +8756,23 @@ }, "node_modules/diff": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.3.1" } }, "node_modules/diff-sequences": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-29.6.3.tgz", - "integrity": "sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==", "dev": true, + "license": "MIT", "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/dir-glob": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", - "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", + "license": "MIT", "dependencies": { "path-type": "^4.0.0" }, @@ -11772,8 +8782,7 @@ }, "node_modules/doctrine": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", - "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", + "license": "Apache-2.0", "dependencies": { "esutils": "^2.0.2" }, @@ -11783,9 +8792,8 @@ }, "node_modules/dot-prop": { "version": "4.2.1", - "resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-4.2.1.tgz", - "integrity": "sha512-l0p4+mIuJIua0mhxGoh4a+iNL9bmeK5DvnSVQa6T0OhrVmaEa1XScX5Etc673FePCJOArq/4Pa2cLGODUWTPOQ==", "dev": true, + "license": "MIT", "dependencies": { "is-obj": "^1.0.0" }, @@ -11795,8 +8803,7 @@ }, "node_modules/dotenv": { "version": "16.3.1", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.3.1.tgz", - "integrity": "sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==", + "license": "BSD-2-Clause", "engines": { "node": ">=12" }, @@ -11806,9 +8813,8 @@ }, "node_modules/dotgitignore": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/dotgitignore/-/dotgitignore-2.1.0.tgz", - "integrity": "sha512-sCm11ak2oY6DglEPpCB8TixLjWAxd3kJTs6UIcSasNYxXdFPV+YKlye92c8H4kKFqV5qYMIh7d+cYecEg0dIkA==", "dev": true, + "license": "ISC", "dependencies": { "find-up": "^3.0.0", "minimatch": "^3.0.4" @@ -11819,9 +8825,8 @@ }, "node_modules/dotgitignore/node_modules/find-up": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^3.0.0" }, @@ -11831,9 +8836,8 @@ }, "node_modules/dotgitignore/node_modules/locate-path": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^3.0.0", "path-exists": "^3.0.0" @@ -11844,9 +8848,8 @@ }, "node_modules/dotgitignore/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -11859,9 +8862,8 @@ }, "node_modules/dotgitignore/node_modules/p-locate": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.0.0" }, @@ -11871,17 +8873,14 @@ }, "node_modules/dotgitignore/node_modules/path-exists": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/dreamopt": { "version": "0.8.0", - "resolved": "https://registry.npmjs.org/dreamopt/-/dreamopt-0.8.0.tgz", - "integrity": "sha512-vyJTp8+mC+G+5dfgsY+r3ckxlz+QMX40VjPQsZc5gxVAxLmi64TBoVkP54A/pRAXMXsbu2GMMBrZPxNv23waMg==", "dependencies": { "wordwrap": ">=0.0.2" }, @@ -11891,32 +8890,27 @@ }, "node_modules/duplexer3": { "version": "0.1.5", - "resolved": "https://registry.npmjs.org/duplexer3/-/duplexer3-0.1.5.tgz", - "integrity": "sha512-1A8za6ws41LQgv9HrE/66jyC5yuSjQ3L/KOpFtoBilsAK2iA2wuS5rTt1OCzIvtS2V7nVmedsUU+DGRcjBmOYA==", - "dev": true + "dev": true, + "license": "BSD-3-Clause" }, "node_modules/eastasianwidth": { "version": "0.2.0", - "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", - "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/ee-first": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", - "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==" + "license": "MIT" }, "node_modules/electron-to-chromium": { "version": "1.4.625", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.625.tgz", - "integrity": "sha512-DENMhh3MFgaPDoXWrVIqSPInQoLImywfCwrSmVl3cf9QHzoZSiutHwGaB/Ql3VkqcQV30rzgdM+BjKqBAJxo5Q==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/emittery": { "version": "0.13.1", - "resolved": "https://registry.npmjs.org/emittery/-/emittery-0.13.1.tgz", - "integrity": "sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -11926,43 +8920,37 @@ }, "node_modules/emoji-regex": { "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + "license": "MIT" }, "node_modules/empty-dir": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/empty-dir/-/empty-dir-1.0.0.tgz", - "integrity": "sha512-97qcDM6mUA1jAeX6cktw7akc5awIGA+VIkA5MygKOKA+c2Vseo/xwKN0JNJTUhZUtPwZboKVD2p1xu+sV/F4xA==", + "license": "MIT", "engines": { "node": ">= 0.8.0" } }, "node_modules/enabled": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/enabled/-/enabled-2.0.0.tgz", - "integrity": "sha512-AKrN98kuwOzMIdAizXGI86UFBoo26CL21UM763y1h/GMSJ4/OHU9k2YlsmBpyScFo/wbLzWQJBMCW4+IO3/+OQ==" + "license": "MIT" }, "node_modules/encodeurl": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/end-of-stream": { "version": "1.4.4", - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", - "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "license": "MIT", "dependencies": { "once": "^1.4.0" } }, "node_modules/enhanced-resolve": { "version": "5.15.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz", - "integrity": "sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==", "dev": true, + "license": "MIT", "dependencies": { "graceful-fs": "^4.2.4", "tapable": "^2.2.0" @@ -11973,9 +8961,8 @@ }, "node_modules/entities": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.3.0.tgz", - "integrity": "sha512-/iP1rZrSEJ0DTlPiX+jbzlA3eVkY/e8L8SozroF395fIqE3TYF/Nz7YOMAawta+vLmyJ/hkGNNPcSbMADCCXbg==", "dev": true, + "license": "BSD-2-Clause", "engines": { "node": ">=0.12" }, @@ -11985,24 +8972,21 @@ }, "node_modules/error-ex": { "version": "1.3.2", - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "license": "MIT", "dependencies": { "is-arrayish": "^0.2.1" } }, "node_modules/error-stack-parser": { "version": "2.1.4", - "resolved": "https://registry.npmjs.org/error-stack-parser/-/error-stack-parser-2.1.4.tgz", - "integrity": "sha512-Sk5V6wVazPhq5MhpO+AUxJn5x7XSXGl1R93Vn7i+zS15KDVxQijejNCrz8340/2bgLBjR9GtEG8ZVKONDjcqGQ==", + "license": "MIT", "dependencies": { "stackframe": "^1.3.4" } }, "node_modules/es-abstract": { "version": "1.22.3", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.3.tgz", - "integrity": "sha512-eiiY8HQeYfYH2Con2berK+To6GrK2RxbPawDkGq4UiCQQfZHb6wX9qQqkbpPqaxQFcl8d9QzZqo0tGE0VcrdwA==", + "license": "MIT", "dependencies": { "array-buffer-byte-length": "^1.0.0", "arraybuffer.prototype.slice": "^1.0.2", @@ -12053,8 +9037,7 @@ }, "node_modules/es-set-tostringtag": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.2.tgz", - "integrity": "sha512-BuDyupZt65P9D2D2vA/zqcI3G5xRsklm5N3xCwuiy+/vKy8i0ifdsQP1sLgO4tZDSCaQUSnmC48khknGMV3D2Q==", + "license": "MIT", "dependencies": { "get-intrinsic": "^1.2.2", "has-tostringtag": "^1.0.0", @@ -12066,16 +9049,14 @@ }, "node_modules/es-shim-unscopables": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.2.tgz", - "integrity": "sha512-J3yBRXCzDu4ULnQwxyToo/OjdMx6akgVC7K6few0a7F/0wLtmKKN7I73AH5T2836UuXRqN7Qg+IIUw/+YJksRw==", + "license": "MIT", "dependencies": { "hasown": "^2.0.0" } }, "node_modules/es-to-primitive": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "license": "MIT", "dependencies": { "is-callable": "^1.1.4", "is-date-object": "^1.0.1", @@ -12090,36 +9071,31 @@ }, "node_modules/es6-promise": { "version": "3.3.1", - "resolved": "https://registry.npmjs.org/es6-promise/-/es6-promise-3.3.1.tgz", - "integrity": "sha512-SOp9Phqvqn7jtEUxPWdWfWoLmyt2VaJ6MpvP9Comy1MceMXqE6bxvaTu4iaxpYYPzhny28Lc+M87/c2cPK6lDg==" + "license": "MIT" }, "node_modules/escalade": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", - "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/escape-html": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", - "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==" + "license": "MIT" }, "node_modules/escape-string-regexp": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "license": "MIT", "engines": { "node": ">=0.8.0" } }, "node_modules/escodegen": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.1.0.tgz", - "integrity": "sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "esprima": "^4.0.1", "estraverse": "^5.2.0", @@ -12138,18 +9114,16 @@ }, "node_modules/escodegen/node_modules/estraverse": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", "dev": true, + "license": "BSD-2-Clause", "engines": { "node": ">=4.0" } }, "node_modules/escodegen/node_modules/source-map": { "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, + "license": "BSD-3-Clause", "optional": true, "engines": { "node": ">=0.10.0" @@ -12157,8 +9131,7 @@ }, "node_modules/eslint": { "version": "8.56.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.56.0.tgz", - "integrity": "sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ==", + "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", "@eslint-community/regexpp": "^4.6.1", @@ -12211,8 +9184,7 @@ }, "node_modules/eslint-config-airbnb-base": { "version": "15.0.0", - "resolved": "https://registry.npmjs.org/eslint-config-airbnb-base/-/eslint-config-airbnb-base-15.0.0.tgz", - "integrity": "sha512-xaX3z4ZZIcFLvh2oUNvcX5oEofXda7giYmuplVxoOg5A7EXJMrUyqRgR+mhDhPK8LZ4PttFOBvCYDbX3sUoUig==", + "license": "MIT", "dependencies": { "confusing-browser-globals": "^1.0.10", "object.assign": "^4.1.2", @@ -12229,16 +9201,14 @@ }, "node_modules/eslint-config-airbnb-base/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/eslint-config-airbnb-typescript": { "version": "17.1.0", - "resolved": "https://registry.npmjs.org/eslint-config-airbnb-typescript/-/eslint-config-airbnb-typescript-17.1.0.tgz", - "integrity": "sha512-GPxI5URre6dDpJ0CtcthSZVBAfI+Uw7un5OYNVxP2EYi3H81Jw701yFP7AU+/vCE7xBtFmjge7kfhhk4+RAiig==", + "license": "MIT", "dependencies": { "eslint-config-airbnb-base": "^15.0.0" }, @@ -12251,9 +9221,8 @@ }, "node_modules/eslint-config-prettier": { "version": "8.10.0", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.10.0.tgz", - "integrity": "sha512-SM8AMJdeQqRYT9O9zguiruQZaN7+z+E4eAP9oiLNGKMtomwaB1E9dcgUD6ZAn/eQAb52USbvezbiljfZUhbJcg==", "dev": true, + "license": "MIT", "bin": { "eslint-config-prettier": "bin/cli.js" }, @@ -12263,8 +9232,7 @@ }, "node_modules/eslint-import-resolver-node": { "version": "0.3.9", - "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.9.tgz", - "integrity": "sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==", + "license": "MIT", "dependencies": { "debug": "^3.2.7", "is-core-module": "^2.13.0", @@ -12273,16 +9241,14 @@ }, "node_modules/eslint-import-resolver-node/node_modules/debug": { "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "license": "MIT", "dependencies": { "ms": "^2.1.1" } }, "node_modules/eslint-module-utils": { "version": "2.8.0", - "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.0.tgz", - "integrity": "sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==", + "license": "MIT", "dependencies": { "debug": "^3.2.7" }, @@ -12297,16 +9263,14 @@ }, "node_modules/eslint-module-utils/node_modules/debug": { "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "license": "MIT", "dependencies": { "ms": "^2.1.1" } }, "node_modules/eslint-plugin-import": { "version": "2.29.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.29.1.tgz", - "integrity": "sha512-BbPC0cuExzhiMo4Ff1BTVwHpjjv28C5R+btTOGaCRC7UEz801up0JadwkeSk5Ued6TG34uaczuVuH6qyy5YUxw==", + "license": "MIT", "dependencies": { "array-includes": "^3.1.7", "array.prototype.findlastindex": "^1.2.3", @@ -12335,16 +9299,14 @@ }, "node_modules/eslint-plugin-import/node_modules/debug": { "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "license": "MIT", "dependencies": { "ms": "^2.1.1" } }, "node_modules/eslint-plugin-import/node_modules/doctrine": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", - "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "license": "Apache-2.0", "dependencies": { "esutils": "^2.0.2" }, @@ -12354,17 +9316,15 @@ }, "node_modules/eslint-plugin-import/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/eslint-plugin-json": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-json/-/eslint-plugin-json-3.1.0.tgz", - "integrity": "sha512-MrlG2ynFEHe7wDGwbUuFPsaT2b1uhuEFhJ+W1f1u+1C2EkXmTYJp4B1aAdQQ8M+CC3t//N/oRKiIVw14L2HR1g==", "dev": true, + "license": "MIT", "dependencies": { "lodash": "^4.17.21", "vscode-json-languageservice": "^4.1.6" @@ -12375,9 +9335,8 @@ }, "node_modules/eslint-plugin-prettier": { "version": "5.1.3", - "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.1.3.tgz", - "integrity": "sha512-C9GCVAs4Eq7ZC/XFQHITLiHJxQngdtraXaM+LoUFoFp/lHNl2Zn8f3WQbe9HvTBBQ9YnKFB0/2Ajdqwo5D1EAw==", "dev": true, + "license": "MIT", "dependencies": { "prettier-linter-helpers": "^1.0.0", "synckit": "^0.8.6" @@ -12405,9 +9364,8 @@ }, "node_modules/eslint-plugin-sonarjs": { "version": "0.19.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-sonarjs/-/eslint-plugin-sonarjs-0.19.0.tgz", - "integrity": "sha512-6+s5oNk5TFtVlbRxqZN7FIGmjdPCYQKaTzFPmqieCmsU1kBYDzndTeQav0xtQNwZJWu5awWfTGe8Srq9xFOGnw==", "dev": true, + "license": "LGPL-3.0", "engines": { "node": ">=14" }, @@ -12417,9 +9375,8 @@ }, "node_modules/eslint-plugin-unicorn": { "version": "46.0.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-unicorn/-/eslint-plugin-unicorn-46.0.1.tgz", - "integrity": "sha512-setGhMTiLAddg1asdwjZ3hekIN5zLznNa5zll7pBPwFOka6greCKDQydfqy4fqyUhndi74wpDzClSQMEcmOaew==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-validator-identifier": "^7.19.1", "@eslint-community/eslint-utils": "^4.1.2", @@ -12450,9 +9407,8 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -12463,9 +9419,8 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -12475,9 +9430,8 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -12490,9 +9444,8 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -12502,9 +9455,8 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/read-pkg": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", - "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", "dev": true, + "license": "MIT", "dependencies": { "@types/normalize-package-data": "^2.4.0", "normalize-package-data": "^2.5.0", @@ -12517,9 +9469,8 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/read-pkg-up": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", - "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^4.1.0", "read-pkg": "^5.2.0", @@ -12534,26 +9485,23 @@ }, "node_modules/eslint-plugin-unicorn/node_modules/read-pkg/node_modules/type-fest": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", - "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/eslint-plugin-unicorn/node_modules/type-fest": { "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/eslint-scope": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", - "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", + "license": "BSD-2-Clause", "dependencies": { "esrecurse": "^4.3.0", "estraverse": "^4.1.1" @@ -12564,8 +9512,7 @@ }, "node_modules/eslint-visitor-keys": { "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", + "license": "Apache-2.0", "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, @@ -12575,8 +9522,7 @@ }, "node_modules/eslint/node_modules/ajv": { "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", + "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.1", "fast-json-stable-stringify": "^2.0.0", @@ -12590,8 +9536,7 @@ }, "node_modules/eslint/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -12604,8 +9549,7 @@ }, "node_modules/eslint/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -12619,8 +9563,7 @@ }, "node_modules/eslint/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -12630,13 +9573,11 @@ }, "node_modules/eslint/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + "license": "MIT" }, "node_modules/eslint/node_modules/escape-string-regexp": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "license": "MIT", "engines": { "node": ">=10" }, @@ -12646,8 +9587,7 @@ }, "node_modules/eslint/node_modules/eslint-scope": { "version": "7.2.2", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", - "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==", + "license": "BSD-2-Clause", "dependencies": { "esrecurse": "^4.3.0", "estraverse": "^5.2.0" @@ -12661,29 +9601,25 @@ }, "node_modules/eslint/node_modules/estraverse": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "license": "BSD-2-Clause", "engines": { "node": ">=4.0" } }, "node_modules/eslint/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/eslint/node_modules/json-schema-traverse": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==" + "license": "MIT" }, "node_modules/eslint/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -12693,8 +9629,7 @@ }, "node_modules/espree": { "version": "9.6.1", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz", - "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==", + "license": "BSD-2-Clause", "dependencies": { "acorn": "^8.9.0", "acorn-jsx": "^5.3.2", @@ -12709,8 +9644,7 @@ }, "node_modules/esprima": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "license": "BSD-2-Clause", "bin": { "esparse": "bin/esparse.js", "esvalidate": "bin/esvalidate.js" @@ -12721,8 +9655,7 @@ }, "node_modules/esquery": { "version": "1.5.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", - "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==", + "license": "BSD-3-Clause", "dependencies": { "estraverse": "^5.1.0" }, @@ -12732,16 +9665,14 @@ }, "node_modules/esquery/node_modules/estraverse": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "license": "BSD-2-Clause", "engines": { "node": ">=4.0" } }, "node_modules/esrecurse": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", + "license": "BSD-2-Clause", "dependencies": { "estraverse": "^5.2.0" }, @@ -12751,47 +9682,41 @@ }, "node_modules/esrecurse/node_modules/estraverse": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "license": "BSD-2-Clause", "engines": { "node": ">=4.0" } }, "node_modules/estraverse": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", - "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", + "license": "BSD-2-Clause", "engines": { "node": ">=4.0" } }, "node_modules/esutils": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "license": "BSD-2-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/eventemitter3": { "version": "4.0.7", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", - "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/events": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz", - "integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==", + "license": "MIT", "engines": { "node": ">=0.8.x" } }, "node_modules/execa": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", "dev": true, + "license": "MIT", "dependencies": { "cross-spawn": "^7.0.3", "get-stream": "^6.0.0", @@ -12812,8 +9737,6 @@ }, "node_modules/exit": { "version": "0.1.2", - "resolved": "https://registry.npmjs.org/exit/-/exit-0.1.2.tgz", - "integrity": "sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ==", "dev": true, "engines": { "node": ">= 0.8.0" @@ -12821,9 +9744,8 @@ }, "node_modules/expand-tilde": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/expand-tilde/-/expand-tilde-2.0.2.tgz", - "integrity": "sha512-A5EmesHW6rfnZ9ysHQjPdJRni0SRar0tjtG5MNtm9n5TUvsYU8oozprtRD4AqHxcZWWlVuAmQo2nWKfN9oyjTw==", "dev": true, + "license": "MIT", "dependencies": { "homedir-polyfill": "^1.0.1" }, @@ -12833,9 +9755,8 @@ }, "node_modules/expect": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/expect/-/expect-29.7.0.tgz", - "integrity": "sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/expect-utils": "^29.7.0", "jest-get-type": "^29.6.3", @@ -12849,18 +9770,16 @@ }, "node_modules/expose-gc": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/expose-gc/-/expose-gc-1.0.0.tgz", - "integrity": "sha512-ecOHrdm+zyOCGIwX18/1RHkUWgxDqGGRiGhaNC+42jReTtudbm2ID/DMa/wpaHwqy5YQHPZvsDqRM2F2iZ0uVA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/external-editor": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", - "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", "dev": true, + "license": "MIT", "dependencies": { "chardet": "^0.7.0", "iconv-lite": "^0.4.24", @@ -12872,19 +9791,16 @@ }, "node_modules/fast-deep-equal": { "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==" + "license": "MIT" }, "node_modules/fast-diff": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz", - "integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==", - "dev": true + "dev": true, + "license": "Apache-2.0" }, "node_modules/fast-glob": { "version": "3.3.2", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.2.tgz", - "integrity": "sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==", + "license": "MIT", "dependencies": { "@nodelib/fs.stat": "^2.0.2", "@nodelib/fs.walk": "^1.2.3", @@ -12898,8 +9814,7 @@ }, "node_modules/fast-glob/node_modules/glob-parent": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "license": "ISC", "dependencies": { "is-glob": "^4.0.1" }, @@ -12909,19 +9824,16 @@ }, "node_modules/fast-json-stable-stringify": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==" + "license": "MIT" }, "node_modules/fast-levenshtein": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==" + "license": "MIT" }, "node_modules/fast-printf": { "version": "1.6.9", - "resolved": "https://registry.npmjs.org/fast-printf/-/fast-printf-1.6.9.tgz", - "integrity": "sha512-FChq8hbz65WMj4rstcQsFB0O7Cy++nmbNfLYnD9cYv2cRn8EG6k/MGn9kO/tjO66t09DLDugj3yL+V2o6Qftrg==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "boolean": "^3.1.4" }, @@ -12931,24 +9843,22 @@ }, "node_modules/fast-safe-stringify": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz", - "integrity": "sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fast-xml-parser": { - "version": "4.2.5", - "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-4.2.5.tgz", - "integrity": "sha512-B9/wizE4WngqQftFPmdaMYlXoJlJOYxGQOanC77fq9k8+Z0v5dDSVh+3glErdIROP//s/jgb7ZuxKfB8nVyo0g==", + "version": "4.4.1", "funding": [ - { - "type": "paypal", - "url": "https://paypal.me/naturalintelligence" - }, { "type": "github", "url": "https://github.com/sponsors/NaturalIntelligence" + }, + { + "type": "paypal", + "url": "https://paypal.me/naturalintelligence" } ], + "license": "MIT", "dependencies": { "strnum": "^1.0.5" }, @@ -12958,31 +9868,27 @@ }, "node_modules/fastq": { "version": "1.16.0", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.16.0.tgz", - "integrity": "sha512-ifCoaXsDrsdkWTtiNJX5uzHDsrck5TzfKKDcuFFTIrrc/BS076qgEIfoIy1VeZqViznfKiysPYTh/QeHtnIsYA==", + "license": "ISC", "dependencies": { "reusify": "^1.0.4" } }, "node_modules/fb-watchman": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", - "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", "dev": true, + "license": "Apache-2.0", "dependencies": { "bser": "2.1.1" } }, "node_modules/fecha": { "version": "4.2.3", - "resolved": "https://registry.npmjs.org/fecha/-/fecha-4.2.3.tgz", - "integrity": "sha512-OP2IUU6HeYKJi3i0z4A19kHMQoLVs4Hc+DPqqxI2h/DPZHTm/vjsfC6P0b4jCMy14XizLBqvndQ+UilD7707Jw==" + "license": "MIT" }, "node_modules/figures": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", - "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", "dev": true, + "license": "MIT", "dependencies": { "escape-string-regexp": "^1.0.5" }, @@ -12995,8 +9901,7 @@ }, "node_modules/file-entry-cache": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", - "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", + "license": "MIT", "dependencies": { "flat-cache": "^3.0.4" }, @@ -13006,14 +9911,12 @@ }, "node_modules/file-uri-to-path": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", - "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==" + "license": "MIT" }, "node_modules/filing-cabinet": { "version": "3.3.1", - "resolved": "https://registry.npmjs.org/filing-cabinet/-/filing-cabinet-3.3.1.tgz", - "integrity": "sha512-renEK4Hh6DUl9Vl22Y3cxBq1yh8oNvbAdXnhih0wVpmea+uyKjC9K4QeRjUaybIiIewdzfum+Fg15ZqJ/GyCaA==", "dev": true, + "license": "MIT", "dependencies": { "app-module-path": "^2.2.0", "commander": "^2.20.3", @@ -13038,15 +9941,13 @@ }, "node_modules/filing-cabinet/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/filing-cabinet/node_modules/typescript": { "version": "3.9.10", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", - "integrity": "sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==", "dev": true, + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -13057,8 +9958,7 @@ }, "node_modules/fill-range": { "version": "7.1.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", - "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "license": "MIT", "dependencies": { "to-regex-range": "^5.0.1" }, @@ -13068,9 +9968,8 @@ }, "node_modules/find-node-modules": { "version": "2.1.3", - "resolved": "https://registry.npmjs.org/find-node-modules/-/find-node-modules-2.1.3.tgz", - "integrity": "sha512-UC2I2+nx1ZuOBclWVNdcnbDR5dlrOdVb7xNjmT/lHE+LsgztWks3dG7boJ37yTS/venXw84B/mAW9uHVoC5QRg==", "dev": true, + "license": "MIT", "dependencies": { "findup-sync": "^4.0.0", "merge": "^2.1.1" @@ -13078,14 +9977,12 @@ }, "node_modules/find-root": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/find-root/-/find-root-1.1.0.tgz", - "integrity": "sha512-NKfW6bec6GfKc0SGx1e07QZY9PE99u0Bft/0rzSD5k3sO/vwkVUpDUKVm5Gpp5Ue3YfShPFTX2070tDs5kB9Ng==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/find-up": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "license": "MIT", "dependencies": { "locate-path": "^6.0.0", "path-exists": "^4.0.0" @@ -13099,17 +9996,15 @@ }, "node_modules/findit2": { "version": "2.2.3", - "resolved": "https://registry.npmjs.org/findit2/-/findit2-2.2.3.tgz", - "integrity": "sha512-lg/Moejf4qXovVutL0Lz4IsaPoNYMuxt4PA0nGqFxnJ1CTTGGlEO2wKgoDpwknhvZ8k4Q2F+eesgkLbG2Mxfog==", + "license": "MIT", "engines": { "node": ">=0.8.22" } }, "node_modules/findup-sync": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/findup-sync/-/findup-sync-4.0.0.tgz", - "integrity": "sha512-6jvvn/12IC4quLBL1KNokxC7wWTvYncaVUYSoxWw7YykPLuRrnv4qdHcSOywOI5RpkOVGeQRtWM8/q+G6W6qfQ==", "dev": true, + "license": "MIT", "dependencies": { "detect-file": "^1.0.0", "is-glob": "^4.0.0", @@ -13122,16 +10017,14 @@ }, "node_modules/flat": { "version": "5.0.2", - "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", - "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", + "license": "BSD-3-Clause", "bin": { "flat": "cli.js" } }, "node_modules/flat-cache": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", - "integrity": "sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==", + "license": "MIT", "dependencies": { "flatted": "^3.2.9", "keyv": "^4.5.3", @@ -13143,31 +10036,26 @@ }, "node_modules/flatted": { "version": "3.2.9", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.9.tgz", - "integrity": "sha512-36yxDn5H7OFZQla0/jFJmbIKTdZAQHngCedGxiMmpNfEZM0sdEeT+WczLQrjK6D7o2aiyLYDnkw0R3JK0Qv1RQ==" + "license": "ISC" }, "node_modules/flatten": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/flatten/-/flatten-1.0.3.tgz", - "integrity": "sha512-dVsPA/UwQ8+2uoFe5GHtiBMu48dWLTdsuEd7CKGlZlD78r1TTWBvDuFaFGKCo/ZfEr95Uk56vZoX86OsHkUeIg==", - "deprecated": "flatten is deprecated in favor of utility frameworks such as lodash.", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fn.name": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fn.name/-/fn.name-1.1.0.tgz", - "integrity": "sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw==" + "license": "MIT" }, "node_modules/follow-redirects": { "version": "1.15.6", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", - "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==", "funding": [ { "type": "individual", "url": "https://github.com/sponsors/RubenVerborgh" } ], + "license": "MIT", "engines": { "node": ">=4.0" }, @@ -13179,17 +10067,15 @@ }, "node_modules/for-each": { "version": "0.3.3", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", - "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "license": "MIT", "dependencies": { "is-callable": "^1.1.3" } }, "node_modules/foreground-child": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.1.1.tgz", - "integrity": "sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg==", "dev": true, + "license": "ISC", "dependencies": { "cross-spawn": "^7.0.0", "signal-exit": "^4.0.1" @@ -13203,9 +10089,8 @@ }, "node_modules/foreground-child/node_modules/signal-exit": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", - "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true, + "license": "ISC", "engines": { "node": ">=14" }, @@ -13215,8 +10100,7 @@ }, "node_modules/form-data": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", - "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "license": "MIT", "dependencies": { "asynckit": "^0.4.0", "combined-stream": "^1.0.8", @@ -13228,9 +10112,8 @@ }, "node_modules/formidable": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/formidable/-/formidable-2.1.2.tgz", - "integrity": "sha512-CM3GuJ57US06mlpQ47YcunuUZ9jpm8Vx+P2CGt2j7HpgkKZO/DJYQ0Bobim8G6PFQmK5lOqOOdUXboU+h73A4g==", "dev": true, + "license": "MIT", "dependencies": { "dezalgo": "^1.0.4", "hexoid": "^1.0.0", @@ -13243,17 +10126,15 @@ }, "node_modules/fresh": { "version": "0.5.2", - "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", - "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/from2": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/from2/-/from2-2.3.0.tgz", - "integrity": "sha512-OMcX/4IC/uqEPVgGeyfN22LJk6AZrMkRZHxcHBMBvHScDGgwTm2GT2Wkgtocyd3JfZffjj2kYUDXXII0Fk9W0g==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.1", "readable-stream": "^2.0.0" @@ -13261,9 +10142,8 @@ }, "node_modules/fs-extra": { "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", "dev": true, + "license": "MIT", "dependencies": { "at-least-node": "^1.0.0", "graceful-fs": "^4.2.0", @@ -13276,8 +10156,7 @@ }, "node_modules/fs-minipass": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", + "license": "ISC", "dependencies": { "minipass": "^3.0.0" }, @@ -13287,8 +10166,7 @@ }, "node_modules/fs-minipass/node_modules/minipass": { "version": "3.3.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", - "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "license": "ISC", "dependencies": { "yallist": "^4.0.0" }, @@ -13298,20 +10176,16 @@ }, "node_modules/fs-minipass/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + "license": "ISC" }, "node_modules/fs.realpath": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + "license": "ISC" }, "node_modules/fsevents": { "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, - "hasInstallScript": true, + "license": "MIT", "optional": true, "os": [ "darwin" @@ -13322,16 +10196,14 @@ }, "node_modules/function-bind": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/function.prototype.name": { "version": "1.1.6", - "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", - "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -13347,16 +10219,14 @@ }, "node_modules/functions-have-names": { "version": "1.2.3", - "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", - "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/gauge": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-3.0.2.tgz", - "integrity": "sha512-+5J6MS/5XksCuXq++uFRsnUd7Ovu1XenbeuIuNRJxYWjgQbPuFhT14lAvsWfqfAmnwluf1OwMjz39HjfLPci0Q==", + "license": "ISC", "dependencies": { "aproba": "^1.0.3 || ^2.0.0", "color-support": "^1.1.2", @@ -13374,18 +10244,16 @@ }, "node_modules/gensync": { "version": "1.0.0-beta.2", - "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", - "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/get-amd-module-type": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/get-amd-module-type/-/get-amd-module-type-4.1.0.tgz", - "integrity": "sha512-0e/eK6vTGCnSfQ6eYs3wtH05KotJYIP7ZIZEueP/KlA+0dIAEs8bYFvOd/U56w1vfjhJqBagUxVMyy9Tr/cViQ==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^4.0.0", "node-source-walk": "^5.0.1" @@ -13396,17 +10264,15 @@ }, "node_modules/get-caller-file": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", "dev": true, + "license": "ISC", "engines": { "node": "6.* || 8.* || >= 10.*" } }, "node_modules/get-intrinsic": { "version": "1.2.2", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.2.tgz", - "integrity": "sha512-0gSo4ml/0j98Y3lngkFEot/zhiCeWsbYIlZ+uZOVgzLyLaUw7wxUL+nCTP0XJvJg1AXulJRI3UJi8GsbDuxdGA==", + "license": "MIT", "dependencies": { "function-bind": "^1.1.2", "has-proto": "^1.0.1", @@ -13419,24 +10285,21 @@ }, "node_modules/get-own-enumerable-property-symbols": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.2.tgz", - "integrity": "sha512-I0UBV/XOz1XkIJHEUDMZAbzCThU/H8DxmSfmdGcKPnVhu2VfFqr34jr9777IyaTYvxjedWhqVIilEDsCdP5G6g==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/get-package-type": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", - "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=8.0.0" } }, "node_modules/get-pkg-repo": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/get-pkg-repo/-/get-pkg-repo-1.4.0.tgz", - "integrity": "sha512-xPCyvcEOxCJDxhBfXDNH+zA7mIRGb2aY1gIUJWsZkpJbp1BLHl+/Sycg26Dv+ZbZAJkO61tzbBtqHUi30NGBvg==", "dev": true, + "license": "MIT", "dependencies": { "hosted-git-info": "^2.1.4", "meow": "^3.3.0", @@ -13450,18 +10313,16 @@ }, "node_modules/get-pkg-repo/node_modules/camelcase": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-2.1.1.tgz", - "integrity": "sha512-DLIsRzJVBQu72meAKPkWQOLcujdXT32hwdfnkI1frSiSRMK1MofjKHf+MEx0SB6fjEFXL8fBDv1dKymBlOp4Qw==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/get-pkg-repo/node_modules/camelcase-keys": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-2.1.0.tgz", - "integrity": "sha512-bA/Z/DERHKqoEOrp+qeGKw1QlvEQkGZSc0XaY6VnTxZr+Kv1G5zFwttpjv8qxZ/sBPT4nthwZaAcsAZTJlSKXQ==", "dev": true, + "license": "MIT", "dependencies": { "camelcase": "^2.0.0", "map-obj": "^1.0.0" @@ -13472,9 +10333,8 @@ }, "node_modules/get-pkg-repo/node_modules/find-up": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", - "integrity": "sha512-jvElSjyuo4EMQGoTwo1uJU5pQMwTW5lS1x05zzfJuTIyLR3zwO27LYrxNg+dlvKpGOuGy/MzBdXh80g0ve5+HA==", "dev": true, + "license": "MIT", "dependencies": { "path-exists": "^2.0.0", "pinkie-promise": "^2.0.0" @@ -13485,9 +10345,8 @@ }, "node_modules/get-pkg-repo/node_modules/indent-string": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-2.1.0.tgz", - "integrity": "sha512-aqwDFWSgSgfRaEwao5lg5KEcVd/2a+D1rvoG7NdilmYz0NwRk6StWpWdz/Hpk34MKPpx7s8XxUqimfcQK6gGlg==", "dev": true, + "license": "MIT", "dependencies": { "repeating": "^2.0.0" }, @@ -13497,9 +10356,8 @@ }, "node_modules/get-pkg-repo/node_modules/load-json-file": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", - "integrity": "sha512-cy7ZdNRXdablkXYNI049pthVeXFurRyb9+hA/dZzerZ0pGTx42z+y+ssxBaVV2l70t1muq5IdKhn4UtcoGUY9A==", "dev": true, + "license": "MIT", "dependencies": { "graceful-fs": "^4.1.2", "parse-json": "^2.2.0", @@ -13513,18 +10371,16 @@ }, "node_modules/get-pkg-repo/node_modules/map-obj": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", - "integrity": "sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/get-pkg-repo/node_modules/meow": { "version": "3.7.0", - "resolved": "https://registry.npmjs.org/meow/-/meow-3.7.0.tgz", - "integrity": "sha512-TNdwZs0skRlpPpCUK25StC4VH+tP5GgeY1HQOOGP+lQ2xtdkN2VtT/5tiX9k3IWpkBPV9b3LsAWXn4GGi/PrSA==", "dev": true, + "license": "MIT", "dependencies": { "camelcase-keys": "^2.0.0", "decamelize": "^1.1.2", @@ -13543,9 +10399,8 @@ }, "node_modules/get-pkg-repo/node_modules/parse-json": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-2.2.0.tgz", - "integrity": "sha512-QR/GGaKCkhwk1ePQNYDRKYZ3mwU9ypsKhB0XyFnLQdomyEqk3e8wpW3V5Jp88zbxK4n5ST1nqo+g9juTpownhQ==", "dev": true, + "license": "MIT", "dependencies": { "error-ex": "^1.2.0" }, @@ -13555,9 +10410,8 @@ }, "node_modules/get-pkg-repo/node_modules/path-exists": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", - "integrity": "sha512-yTltuKuhtNeFJKa1PiRzfLAU5182q1y4Eb4XCJ3PBqyzEDkAZRzBrKKBct682ls9reBVHf9udYLN5Nd+K1B9BQ==", "dev": true, + "license": "MIT", "dependencies": { "pinkie-promise": "^2.0.0" }, @@ -13567,9 +10421,8 @@ }, "node_modules/get-pkg-repo/node_modules/path-type": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-1.1.0.tgz", - "integrity": "sha512-S4eENJz1pkiQn9Znv33Q+deTOKmbl+jj1Fl+qiP/vYezj+S8x+J3Uo0ISrx/QoEvIlOaDWJhPaRd1flJ9HXZqg==", "dev": true, + "license": "MIT", "dependencies": { "graceful-fs": "^4.1.2", "pify": "^2.0.0", @@ -13581,9 +10434,8 @@ }, "node_modules/get-pkg-repo/node_modules/read-pkg": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-1.1.0.tgz", - "integrity": "sha512-7BGwRHqt4s/uVbuyoeejRn4YmFnYZiFl4AuaeXHlgZf3sONF0SOGlxs2Pw8g6hCKupo08RafIO5YXFNOKTfwsQ==", "dev": true, + "license": "MIT", "dependencies": { "load-json-file": "^1.0.0", "normalize-package-data": "^2.3.2", @@ -13595,9 +10447,8 @@ }, "node_modules/get-pkg-repo/node_modules/read-pkg-up": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-1.0.1.tgz", - "integrity": "sha512-WD9MTlNtI55IwYUS27iHh9tK3YoIVhxis8yKhLpTqWtml739uXc9NWTpxoHkfZf3+DkCCsXox94/VWZniuZm6A==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^1.0.0", "read-pkg": "^1.0.0" @@ -13608,9 +10459,8 @@ }, "node_modules/get-pkg-repo/node_modules/redent": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-1.0.0.tgz", - "integrity": "sha512-qtW5hKzGQZqKoh6JNSD+4lfitfPKGz42e6QwiRmPM5mmKtR0N41AbJRYu0xJi7nhOJ4WDgRkKvAk6tw4WIwR4g==", "dev": true, + "license": "MIT", "dependencies": { "indent-string": "^2.1.0", "strip-indent": "^1.0.1" @@ -13621,9 +10471,8 @@ }, "node_modules/get-pkg-repo/node_modules/strip-bom": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-2.0.0.tgz", - "integrity": "sha512-kwrX1y7czp1E69n2ajbG65mIo9dqvJ+8aBQXOGVxqwvNbsXdFM6Lq37dLAY3mknUwru8CfcCbfOLL/gMo+fi3g==", "dev": true, + "license": "MIT", "dependencies": { "is-utf8": "^0.2.0" }, @@ -13633,9 +10482,8 @@ }, "node_modules/get-pkg-repo/node_modules/strip-indent": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-1.0.1.tgz", - "integrity": "sha512-I5iQq6aFMM62fBEAIB/hXzwJD6EEZ0xEGCX2t7oXqaKPIRgt4WruAQ285BISgdkP+HLGWyeGmNJcpIwFeRYRUA==", "dev": true, + "license": "MIT", "dependencies": { "get-stdin": "^4.0.1" }, @@ -13648,18 +10496,16 @@ }, "node_modules/get-stdin": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-4.0.1.tgz", - "integrity": "sha512-F5aQMywwJ2n85s4hJPTT9RPxGmubonuB10MNYo17/xph174n2MIR33HRguhzVag10O/npM7SPk73LMZNP+FaWw==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/get-stream": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -13669,8 +10515,7 @@ }, "node_modules/get-symbol-description": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", - "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "get-intrinsic": "^1.1.1" @@ -13684,8 +10529,7 @@ }, "node_modules/get-value": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/get-value/-/get-value-3.0.1.tgz", - "integrity": "sha512-mKZj9JLQrwMBtj5wxi6MH8Z5eSKaERpAwjg43dPtlGI1ZVEgH/qC7T8/6R2OBSUA+zzHBZgICsVJaEIV2tKTDA==", + "license": "MIT", "dependencies": { "isobject": "^3.0.1" }, @@ -13695,9 +10539,8 @@ }, "node_modules/gh-got": { "version": "7.1.0", - "resolved": "https://registry.npmjs.org/gh-got/-/gh-got-7.1.0.tgz", - "integrity": "sha512-KeWkkhresa7sbpzQLYzITMgez5rMigUsijhmSAHcLDORIMUbdlkdoZyaN1wQvIjmUZnyb/wkAPaXb4MQKX0mdQ==", "dev": true, + "license": "MIT", "dependencies": { "got": "^8.0.0", "is-plain-obj": "^1.1.0" @@ -13708,9 +10551,8 @@ }, "node_modules/git-raw-commits": { "version": "2.0.11", - "resolved": "https://registry.npmjs.org/git-raw-commits/-/git-raw-commits-2.0.11.tgz", - "integrity": "sha512-VnctFhw+xfj8Va1xtfEqCUD2XDrbAPSJx+hSrE5K7fGdjZruW7XV+QOrN7LF/RJyvspRiD2I0asWsxFp0ya26A==", "dev": true, + "license": "MIT", "dependencies": { "dargs": "^7.0.0", "lodash": "^4.17.15", @@ -13727,9 +10569,8 @@ }, "node_modules/git-raw-commits/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -13741,18 +10582,16 @@ }, "node_modules/git-raw-commits/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/git-remote-origin-url": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/git-remote-origin-url/-/git-remote-origin-url-2.0.0.tgz", - "integrity": "sha512-eU+GGrZgccNJcsDH5LkXR3PB9M958hxc7sbA8DFJjrv9j4L2P/eZfKhM+QD6wyzpiv+b1BpK0XrYCxkovtjSLw==", "dev": true, + "license": "MIT", "dependencies": { "gitconfiglocal": "^1.0.0", "pify": "^2.3.0" @@ -13763,9 +10602,8 @@ }, "node_modules/git-semver-tags": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/git-semver-tags/-/git-semver-tags-2.0.3.tgz", - "integrity": "sha512-tj4FD4ww2RX2ae//jSrXZzrocla9db5h0V7ikPl1P/WwoZar9epdUhwR7XHXSgc+ZkNq72BEEerqQuicoEQfzA==", "dev": true, + "license": "MIT", "dependencies": { "meow": "^4.0.0", "semver": "^6.0.0" @@ -13779,18 +10617,16 @@ }, "node_modules/git-semver-tags/node_modules/camelcase": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz", - "integrity": "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/git-semver-tags/node_modules/camelcase-keys": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-4.2.0.tgz", - "integrity": "sha512-Ej37YKYbFUI8QiYlvj9YHb6/Z60dZyPJW0Cs8sFilMbd2lP0bw3ylAq9yJkK4lcTA2dID5fG8LjmJYbO7kWb7Q==", "dev": true, + "license": "MIT", "dependencies": { "camelcase": "^4.1.0", "map-obj": "^2.0.0", @@ -13802,27 +10638,24 @@ }, "node_modules/git-semver-tags/node_modules/indent-string": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-3.2.0.tgz", - "integrity": "sha512-BYqTHXTGUIvg7t1r4sJNKcbDZkL92nkXA8YtRpbjFHRHGDL/NtUeiBJMeE60kIFN/Mg8ESaWQvftaYMGJzQZCQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/git-semver-tags/node_modules/map-obj": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-2.0.0.tgz", - "integrity": "sha512-TzQSV2DiMYgoF5RycneKVUzIa9bQsj/B3tTgsE3dOGqlzHnGIDaC7XBE7grnA+8kZPnfqSGFe95VHc2oc0VFUQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/git-semver-tags/node_modules/meow": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/meow/-/meow-4.0.1.tgz", - "integrity": "sha512-xcSBHD5Z86zaOc+781KrupuHAzeGXSLtiAOmBsiLDiPSaYSB6hdew2ng9EBAnZ62jagG9MHAOdxpDi/lWBFJ/A==", "dev": true, + "license": "MIT", "dependencies": { "camelcase-keys": "^4.0.0", "decamelize-keys": "^1.0.0", @@ -13840,9 +10673,8 @@ }, "node_modules/git-semver-tags/node_modules/minimist-options": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/minimist-options/-/minimist-options-3.0.2.tgz", - "integrity": "sha512-FyBrT/d0d4+uiZRbqznPXqw3IpZZG3gl3wKWiX784FycUKVwBt0uLBFkQrtE4tZOrgo78nZp2jnKz3L65T5LdQ==", "dev": true, + "license": "MIT", "dependencies": { "arrify": "^1.0.1", "is-plain-obj": "^1.1.0" @@ -13853,18 +10685,16 @@ }, "node_modules/git-semver-tags/node_modules/quick-lru": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-1.1.0.tgz", - "integrity": "sha512-tRS7sTgyxMXtLum8L65daJnHUhfDUgboRdcWW2bR9vBfrj2+O5HSMbQOJfJJjIVSPFqbBCF37FpwWXGitDc5tA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/git-semver-tags/node_modules/redent": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-2.0.0.tgz", - "integrity": "sha512-XNwrTx77JQCEMXTeb8movBKuK75MgH0RZkujNuDKCezemx/voapl9i2gCSi8WWm8+ox5ycJi1gxF22fR7c0Ciw==", "dev": true, + "license": "MIT", "dependencies": { "indent-string": "^3.0.0", "strip-indent": "^2.0.0" @@ -13875,36 +10705,32 @@ }, "node_modules/git-semver-tags/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/git-semver-tags/node_modules/strip-indent": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-2.0.0.tgz", - "integrity": "sha512-RsSNPLpq6YUL7QYy44RnPVTn/lcVZtb48Uof3X5JLbF4zD/Gs7ZFDv2HWol+leoQN2mT86LAzSshGfkTlSOpsA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/gitconfiglocal": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/gitconfiglocal/-/gitconfiglocal-1.0.0.tgz", - "integrity": "sha512-spLUXeTAVHxDtKsJc8FkFVgFtMdEN9qPGpL23VfSHx4fP4+Ds097IXLvymbnDH8FnmxX5Nr9bPw3A+AQ6mWEaQ==", "dev": true, + "license": "BSD", "dependencies": { "ini": "^1.3.2" } }, "node_modules/glob": { "version": "10.3.10", - "resolved": "https://registry.npmjs.org/glob/-/glob-10.3.10.tgz", - "integrity": "sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g==", "dev": true, + "license": "ISC", "dependencies": { "foreground-child": "^3.1.0", "jackspeak": "^2.3.5", @@ -13924,8 +10750,7 @@ }, "node_modules/glob-parent": { "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", + "license": "ISC", "dependencies": { "is-glob": "^4.0.3" }, @@ -13935,18 +10760,16 @@ }, "node_modules/glob/node_modules/brace-expansion": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0" } }, "node_modules/glob/node_modules/minimatch": { "version": "9.0.3", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.3.tgz", - "integrity": "sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==", "dev": true, + "license": "ISC", "dependencies": { "brace-expansion": "^2.0.1" }, @@ -13959,9 +10782,8 @@ }, "node_modules/global-dirs": { "version": "0.1.1", - "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-0.1.1.tgz", - "integrity": "sha512-NknMLn7F2J7aflwFOlGdNIuCDpN3VGoSoB+aap3KABFWbHVn1TCgFC+np23J8W2BiZbjfEw3BFBycSMv1AFblg==", "dev": true, + "license": "MIT", "dependencies": { "ini": "^1.3.4" }, @@ -13971,9 +10793,8 @@ }, "node_modules/global-modules": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-1.0.0.tgz", - "integrity": "sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg==", "dev": true, + "license": "MIT", "dependencies": { "global-prefix": "^1.0.1", "is-windows": "^1.0.1", @@ -13985,9 +10806,8 @@ }, "node_modules/global-prefix": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-1.0.2.tgz", - "integrity": "sha512-5lsx1NUDHtSjfg0eHlmYvZKv8/nVqX4ckFbM+FrGcQ+04KWcWFo9P5MxPZYSzUvyzmdTbI7Eix8Q4IbELDqzKg==", "dev": true, + "license": "MIT", "dependencies": { "expand-tilde": "^2.0.2", "homedir-polyfill": "^1.0.1", @@ -14001,9 +10821,8 @@ }, "node_modules/global-prefix/node_modules/which": { "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", "dev": true, + "license": "ISC", "dependencies": { "isexe": "^2.0.0" }, @@ -14013,8 +10832,7 @@ }, "node_modules/globals": { "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", + "license": "MIT", "dependencies": { "type-fest": "^0.20.2" }, @@ -14027,8 +10845,7 @@ }, "node_modules/globalthis": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", - "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "license": "MIT", "dependencies": { "define-properties": "^1.1.3" }, @@ -14041,8 +10858,7 @@ }, "node_modules/globby": { "version": "11.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", - "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", + "license": "MIT", "dependencies": { "array-union": "^2.1.0", "dir-glob": "^3.0.1", @@ -14060,9 +10876,8 @@ }, "node_modules/gonzales-pe": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/gonzales-pe/-/gonzales-pe-4.3.0.tgz", - "integrity": "sha512-otgSPpUmdWJ43VXyiNgEYE4luzHCL2pz4wQ0OnDluC6Eg4Ko3Vexy/SrSynglw/eR+OhkzmqFCZa/OFa/RgAOQ==", "dev": true, + "license": "MIT", "dependencies": { "minimist": "^1.2.5" }, @@ -14075,8 +10890,7 @@ }, "node_modules/gopd": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", - "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "license": "MIT", "dependencies": { "get-intrinsic": "^1.1.3" }, @@ -14086,9 +10900,8 @@ }, "node_modules/got": { "version": "8.3.2", - "resolved": "https://registry.npmjs.org/got/-/got-8.3.2.tgz", - "integrity": "sha512-qjUJ5U/hawxosMryILofZCkm3C84PLJS/0grRIpjAwu+Lkxxj5cxeCU25BG0/3mDSpXKTyZr8oh8wIgLaH0QCw==", "dev": true, + "license": "MIT", "dependencies": { "@sindresorhus/is": "^0.7.0", "cacheable-request": "^2.1.1", @@ -14114,43 +10927,37 @@ }, "node_modules/got/node_modules/get-stream": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz", - "integrity": "sha512-GlhdIUuVakc8SJ6kK0zAFbiGzRFzNnY4jUuEbV9UROo4Y+0Ny4fjvcZFVTeDA4odpFyOQzaw6hXukJSq/f28sQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/got/node_modules/pify": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/graceful-fs": { "version": "4.2.11", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", - "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/graphemer": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", - "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==" + "license": "MIT" }, "node_modules/growly": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", - "integrity": "sha512-+xGQY0YyAWCnqy7Cd++hc2JqMYzlm0dG30Jd0beaA64sROr8C4nt8Yc9V5Ro3avlSUDTN0ulqP/VBKi1/lLygw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/handlebars": { "version": "4.7.8", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.8.tgz", - "integrity": "sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==", + "license": "MIT", "dependencies": { "minimist": "^1.2.5", "neo-async": "^2.6.2", @@ -14169,41 +10976,36 @@ }, "node_modules/handlebars/node_modules/source-map": { "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/hard-rejection": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/hard-rejection/-/hard-rejection-2.1.0.tgz", - "integrity": "sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/has-bigints": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", - "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/has-flag": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/has-property-descriptors": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.1.tgz", - "integrity": "sha512-VsX8eaIewvas0xnvinAe9bw4WfIeODpGYikiWYLH+dma0Jw6KHYqWiWfhQlgOVK8D6PvjubK5Uc4P0iIhIcNVg==", + "license": "MIT", "dependencies": { "get-intrinsic": "^1.2.2" }, @@ -14213,8 +11015,7 @@ }, "node_modules/has-proto": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", - "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -14224,17 +11025,15 @@ }, "node_modules/has-symbol-support-x": { "version": "1.4.2", - "resolved": "https://registry.npmjs.org/has-symbol-support-x/-/has-symbol-support-x-1.4.2.tgz", - "integrity": "sha512-3ToOva++HaW+eCpgqZrCfN51IPB+7bJNVT6CUATzueB5Heb8o6Nam0V3HG5dlDvZU1Gn5QLcbahiKw/XVk5JJw==", "dev": true, + "license": "MIT", "engines": { "node": "*" } }, "node_modules/has-symbols": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", - "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -14244,9 +11043,8 @@ }, "node_modules/has-to-string-tag-x": { "version": "1.4.1", - "resolved": "https://registry.npmjs.org/has-to-string-tag-x/-/has-to-string-tag-x-1.4.1.tgz", - "integrity": "sha512-vdbKfmw+3LoOYVr+mtxHaX5a96+0f3DljYd8JOqvOLsf5mw2Otda2qCDT9qRqLAhrjyQ0h7ual5nOiASpsGNFw==", "dev": true, + "license": "MIT", "dependencies": { "has-symbol-support-x": "^1.4.1" }, @@ -14256,8 +11054,7 @@ }, "node_modules/has-tostringtag": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", - "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "license": "MIT", "dependencies": { "has-symbols": "^1.0.2" }, @@ -14270,13 +11067,11 @@ }, "node_modules/has-unicode": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", - "integrity": "sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ==" + "license": "ISC" }, "node_modules/has-value": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/has-value/-/has-value-2.0.2.tgz", - "integrity": "sha512-ybKOlcRsK2MqrM3Hmz/lQxXHZ6ejzSPzpNabKB45jb5qDgJvKPa3SdapTsTLwEb9WltgWpOmNax7i+DzNOk4TA==", + "license": "MIT", "dependencies": { "get-value": "^3.0.0", "has-values": "^2.0.1" @@ -14287,8 +11082,7 @@ }, "node_modules/has-values": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-values/-/has-values-2.0.1.tgz", - "integrity": "sha512-+QdH3jOmq9P8GfdjFg0eJudqx1FqU62NQJ4P16rOEHeRdl7ckgwn6uqQjzYE0ZoHVV/e5E2esuJ5Gl5+HUW19w==", + "license": "MIT", "dependencies": { "kind-of": "^6.0.2" }, @@ -14298,8 +11092,7 @@ }, "node_modules/hasown": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.0.tgz", - "integrity": "sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==", + "license": "MIT", "dependencies": { "function-bind": "^1.1.2" }, @@ -14309,23 +11102,20 @@ }, "node_modules/heap": { "version": "0.2.7", - "resolved": "https://registry.npmjs.org/heap/-/heap-0.2.7.tgz", - "integrity": "sha512-2bsegYkkHO+h/9MGbn6KWcE45cHZgPANo5LXF7EvWdT0yT2EguSVO1nDgU5c8+ZOPwp2vMNa7YFsJhVcDR9Sdg==" + "license": "MIT" }, "node_modules/hexoid": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/hexoid/-/hexoid-1.0.0.tgz", - "integrity": "sha512-QFLV0taWQOZtvIRIAdBChesmogZrtuXvVWsFHZTk2SU+anspqZ2vMnoLg7IE1+Uk16N19APic1BuF8bC8c2m5g==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/homedir-polyfill": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/homedir-polyfill/-/homedir-polyfill-1.0.3.tgz", - "integrity": "sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA==", "dev": true, + "license": "MIT", "dependencies": { "parse-passwd": "^1.0.0" }, @@ -14335,19 +11125,16 @@ }, "node_modules/hosted-git-info": { "version": "2.8.9", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz", - "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==" + "license": "ISC" }, "node_modules/html-escaper": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", - "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/http-assert": { "version": "1.5.0", - "resolved": "https://registry.npmjs.org/http-assert/-/http-assert-1.5.0.tgz", - "integrity": "sha512-uPpH7OKX4H25hBmU6G1jWNaqJGpTXxey+YOUizJUAgu0AjLUeC8D73hTrhvDS5D+GJN1DN1+hhc/eF/wpxtp0w==", + "license": "MIT", "dependencies": { "deep-equal": "~1.0.1", "http-errors": "~1.8.0" @@ -14358,16 +11145,14 @@ }, "node_modules/http-assert/node_modules/depd": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", - "integrity": "sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/http-assert/node_modules/http-errors": { "version": "1.8.1", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.8.1.tgz", - "integrity": "sha512-Kpk9Sm7NmI+RHhnj6OIWDI1d6fIoFAtFt9RLaTMRlg/8w49juAStsrBgp0Dp4OdxdVbRIeKhtCUvoi/RuAhO4g==", + "license": "MIT", "dependencies": { "depd": "~1.1.2", "inherits": "2.0.4", @@ -14381,22 +11166,19 @@ }, "node_modules/http-assert/node_modules/statuses": { "version": "1.5.0", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", - "integrity": "sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/http-cache-semantics": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", - "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", - "dev": true + "dev": true, + "license": "BSD-2-Clause" }, "node_modules/http-errors": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", - "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", + "license": "MIT", "dependencies": { "depd": "2.0.0", "inherits": "2.0.4", @@ -14410,8 +11192,7 @@ }, "node_modules/http-graceful-shutdown": { "version": "3.1.13", - "resolved": "https://registry.npmjs.org/http-graceful-shutdown/-/http-graceful-shutdown-3.1.13.tgz", - "integrity": "sha512-Ci5LRufQ8AtrQ1U26AevS8QoMXDOhnAHCJI3eZu1com7mZGHxREmw3dNj85ftpQokQCvak8nI2pnFS8zyM1M+Q==", + "license": "MIT", "dependencies": { "debug": "^4.3.4" }, @@ -14421,9 +11202,8 @@ }, "node_modules/http-terminator": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/http-terminator/-/http-terminator-3.2.0.tgz", - "integrity": "sha512-JLjck1EzPaWjsmIf8bziM3p9fgR1Y3JoUKAkyYEbZmFrIvJM6I8vVJfBGWlEtV9IWOvzNnaTtjuwZeBY2kwB4g==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "delay": "^5.0.0", "p-wait-for": "^3.2.0", @@ -14436,9 +11216,8 @@ }, "node_modules/http-terminator/node_modules/type-fest": { "version": "2.19.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-2.19.0.tgz", - "integrity": "sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=12.20" }, @@ -14448,8 +11227,7 @@ }, "node_modules/https-proxy-agent": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", - "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", + "license": "MIT", "dependencies": { "agent-base": "6", "debug": "4" @@ -14460,32 +11238,29 @@ }, "node_modules/human-format": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/human-format/-/human-format-1.2.0.tgz", - "integrity": "sha512-GIjOefWusTiXEPezbuI59uc1G2SNMpym6w1wNfoWAG6QrTsWueuauR5We0xHHuzoJKIYTwwNtTEy0ahyji5KXw==", "dev": true, + "license": "ISC", "engines": { "node": ">=4" } }, "node_modules/human-signals": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true, + "license": "Apache-2.0", "engines": { "node": ">=10.17.0" } }, "node_modules/husky": { - "version": "8.0.3", - "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.3.tgz", - "integrity": "sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg==", + "version": "9.1.1", "dev": true, + "license": "MIT", "bin": { - "husky": "lib/bin.js" + "husky": "bin.js" }, "engines": { - "node": ">=14" + "node": ">=18" }, "funding": { "url": "https://github.com/sponsors/typicode" @@ -14493,8 +11268,7 @@ }, "node_modules/iconv-lite": { "version": "0.4.24", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "license": "MIT", "dependencies": { "safer-buffer": ">= 2.1.2 < 3" }, @@ -14504,8 +11278,6 @@ }, "node_modules/ieee754": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", - "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", "funding": [ { "type": "github", @@ -14519,20 +11291,19 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "license": "BSD-3-Clause" }, "node_modules/ignore": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.0.tgz", - "integrity": "sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg==", + "license": "MIT", "engines": { "node": ">= 4" } }, "node_modules/import-fresh": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", - "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", + "license": "MIT", "dependencies": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" @@ -14546,17 +11317,15 @@ }, "node_modules/import-fresh/node_modules/resolve-from": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/import-local": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.1.0.tgz", - "integrity": "sha512-ASB07uLtnDs1o6EHjKpX34BKYDSqnFerfTOJL2HvMqF70LnxpjkzDB8J44oT9pu4AMPkQwf8jl6szgvNd2tRIg==", "dev": true, + "license": "MIT", "dependencies": { "pkg-dir": "^4.2.0", "resolve-cwd": "^3.0.0" @@ -14573,39 +11342,34 @@ }, "node_modules/imurmurhash": { "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", + "license": "MIT", "engines": { "node": ">=0.8.19" } }, "node_modules/indent-string": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/indexes-of": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/indexes-of/-/indexes-of-1.0.1.tgz", - "integrity": "sha512-bup+4tap3Hympa+JBJUG7XuOsdNQ6fxt0MHyXMKuLBKn0OqsTfvUxkUrroEX1+B2VsSHvCjiIcZVxRtYa4nllA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/inflation": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/inflation/-/inflation-2.1.0.tgz", - "integrity": "sha512-t54PPJHG1Pp7VQvxyVCJ9mBbjG3Hqryges9bXoOO6GExCPa+//i/d5GSuFtpx3ALLd7lgIAur6zrIlBQyJuMlQ==", + "license": "MIT", "engines": { "node": ">= 0.8.0" } }, "node_modules/inflight": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "license": "ISC", "dependencies": { "once": "^1.3.0", "wrappy": "1" @@ -14613,20 +11377,17 @@ }, "node_modules/inherits": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + "license": "ISC" }, "node_modules/ini": { "version": "1.3.8", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", - "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/inquirer": { "version": "8.2.6", - "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-8.2.6.tgz", - "integrity": "sha512-M1WuAmb7pn9zdFRtQYk26ZBoY043Sse0wVDdk4Bppr+JOXyQYybdtvK+l9wUibhtjdjvtoiNy8tk+EgsYIUqKg==", "dev": true, + "license": "MIT", "dependencies": { "ansi-escapes": "^4.2.1", "chalk": "^4.1.1", @@ -14650,9 +11411,8 @@ }, "node_modules/inquirer/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -14665,9 +11425,8 @@ }, "node_modules/inquirer/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -14681,9 +11440,8 @@ }, "node_modules/inquirer/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -14693,24 +11451,21 @@ }, "node_modules/inquirer/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/inquirer/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/inquirer/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -14720,9 +11475,8 @@ }, "node_modules/inquirer/node_modules/wrap-ansi": { "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", @@ -14734,8 +11488,7 @@ }, "node_modules/internal-slot": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.6.tgz", - "integrity": "sha512-Xj6dv+PsbtwyPpEflsejS+oIZxmMlV44zAhG479uYu89MsjcYOhCFnNyKrkJrihbsiasQyY0afoCl/9BLR65bg==", + "license": "MIT", "dependencies": { "get-intrinsic": "^1.2.2", "hasown": "^2.0.0", @@ -14747,9 +11500,8 @@ }, "node_modules/into-stream": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/into-stream/-/into-stream-3.1.0.tgz", - "integrity": "sha512-TcdjPibTksa1NQximqep2r17ISRiNE9fwlfbg3F8ANdvP5/yrFTew86VcO//jk4QTaMlbjypPBq76HN2zaKfZQ==", "dev": true, + "license": "MIT", "dependencies": { "from2": "^2.1.1", "p-is-promise": "^1.1.0" @@ -14760,8 +11512,7 @@ }, "node_modules/ioredis": { "version": "5.3.2", - "resolved": "https://registry.npmjs.org/ioredis/-/ioredis-5.3.2.tgz", - "integrity": "sha512-1DKMMzlIHM02eBBVOFQ1+AolGjs6+xEcM4PDL7NqOS6szq7H9jSaEkIUH6/a5Hl241LzW6JLSiAbNvTQjUupUA==", + "license": "MIT", "dependencies": { "@ioredis/commands": "^1.1.1", "cluster-key-slot": "^1.1.0", @@ -14783,24 +11534,21 @@ }, "node_modules/ip-regex": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ip-regex/-/ip-regex-4.3.0.tgz", - "integrity": "sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/is": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/is/-/is-3.3.0.tgz", - "integrity": "sha512-nW24QBoPcFGGHJGUwnfpI7Yc5CdqWNdsyHQszVE/z2pKHXzh7FZ5GWhJqSyaQ9wMkQnsTx+kAI8bHlCX4tKdbg==", + "license": "MIT", "engines": { "node": "*" } }, "node_modules/is-array-buffer": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", - "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "get-intrinsic": "^1.2.0", @@ -14812,13 +11560,11 @@ }, "node_modules/is-arrayish": { "version": "0.2.1", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", - "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==" + "license": "MIT" }, "node_modules/is-bigint": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", - "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "license": "MIT", "dependencies": { "has-bigints": "^1.0.1" }, @@ -14828,8 +11574,7 @@ }, "node_modules/is-boolean-object": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", - "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "has-tostringtag": "^1.0.0" @@ -14843,8 +11588,6 @@ }, "node_modules/is-buffer": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.5.tgz", - "integrity": "sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==", "funding": [ { "type": "github", @@ -14859,15 +11602,15 @@ "url": "https://feross.org/support" } ], + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/is-builtin-module": { "version": "3.2.1", - "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-3.2.1.tgz", - "integrity": "sha512-BSLE3HnV2syZ0FK0iMA/yUGplUeMmNz4AW5fnTunbCIqZi4vG3WjJT9FHMy5D69xmAYBHXQhJdALdpwVxV501A==", "dev": true, + "license": "MIT", "dependencies": { "builtin-modules": "^3.3.0" }, @@ -14880,8 +11623,7 @@ }, "node_modules/is-callable": { "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -14891,8 +11633,7 @@ }, "node_modules/is-core-module": { "version": "2.13.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.1.tgz", - "integrity": "sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==", + "license": "MIT", "dependencies": { "hasown": "^2.0.0" }, @@ -14902,8 +11643,7 @@ }, "node_modules/is-date-object": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", - "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "license": "MIT", "dependencies": { "has-tostringtag": "^1.0.0" }, @@ -14916,9 +11656,8 @@ }, "node_modules/is-docker": { "version": "2.2.1", - "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", - "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", "dev": true, + "license": "MIT", "bin": { "is-docker": "cli.js" }, @@ -14931,17 +11670,15 @@ }, "node_modules/is-extglob": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-finite": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", - "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" }, @@ -14951,9 +11688,8 @@ }, "node_modules/is-fullwidth-code-point": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-4.0.0.tgz", - "integrity": "sha512-O4L094N2/dZ7xqVdrXhh9r1KODPJpFms8B5sGdJLPy664AgvXsreZUyCQQNItZRDlYug4xStLjNp/sz3HvBowQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -14963,17 +11699,15 @@ }, "node_modules/is-generator-fn": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-2.1.0.tgz", - "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/is-generator-function": { "version": "1.0.10", - "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.0.10.tgz", - "integrity": "sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==", + "license": "MIT", "dependencies": { "has-tostringtag": "^1.0.0" }, @@ -14986,8 +11720,7 @@ }, "node_modules/is-glob": { "version": "4.0.3", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", - "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "license": "MIT", "dependencies": { "is-extglob": "^2.1.1" }, @@ -14997,17 +11730,15 @@ }, "node_modules/is-interactive": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-interactive/-/is-interactive-1.0.0.tgz", - "integrity": "sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/is-ip": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/is-ip/-/is-ip-3.1.0.tgz", - "integrity": "sha512-35vd5necO7IitFPjd/YBeqwWnyDWbuLH9ZXQdMfDA8TEo7pv5X8yfrvVO3xbJbLUlERCMvf6X0hTUamQxCYJ9Q==", + "license": "MIT", "dependencies": { "ip-regex": "^4.0.0" }, @@ -15017,8 +11748,7 @@ }, "node_modules/is-negative-zero": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", - "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -15028,16 +11758,14 @@ }, "node_modules/is-number": { "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "license": "MIT", "engines": { "node": ">=0.12.0" } }, "node_modules/is-number-object": { "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", - "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "license": "MIT", "dependencies": { "has-tostringtag": "^1.0.0" }, @@ -15050,43 +11778,38 @@ }, "node_modules/is-obj": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz", - "integrity": "sha512-l4RyHgRqGN4Y3+9JHVrNqO+tN0rV5My76uW5/nuO4K1b6vw5G8d/cmFjP9tRfEsdhZNt0IFdZuK/c2Vr4Nb+Qg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-object": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-object/-/is-object-1.0.2.tgz", - "integrity": "sha512-2rRIahhZr2UWb45fIOuvZGpFtz0TyOZLf32KxBbSoUCeZR495zCKlWUKKUByk3geS2eAs7ZAABt0Y/Rx0GiQGA==", "dev": true, + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-path-inside": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/is-plain-obj": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", - "integrity": "sha512-yvkRyxmFKEOQ4pNXCmJG5AEQNlXJS5LaONXo5/cLdTZdWvsZ1ioJEonLGAosKlMWE8lwUy/bJzMjcw8az73+Fg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-plain-object": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", - "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", + "license": "MIT", "dependencies": { "isobject": "^3.0.1" }, @@ -15096,16 +11819,14 @@ }, "node_modules/is-primitive": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/is-primitive/-/is-primitive-3.0.1.tgz", - "integrity": "sha512-GljRxhWvlCNRfZyORiH77FwdFwGcMO620o37EOYC0ORWdq+WYNVqW0w2Juzew4M+L81l6/QS3t5gkkihyRqv9w==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-regex": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", - "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "has-tostringtag": "^1.0.0" @@ -15119,32 +11840,28 @@ }, "node_modules/is-regexp": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-regexp/-/is-regexp-1.0.0.tgz", - "integrity": "sha512-7zjFAPO4/gwyQAAgRRmqeEeyIICSdmCqa3tsVHMdBzaXXRiqopZL4Cyghg/XulGWrtABTpbnYYzzIRffLkP4oA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-relative-path": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-relative-path/-/is-relative-path-1.0.2.tgz", - "integrity": "sha512-i1h+y50g+0hRbBD+dbnInl3JlJ702aar58snAeX+MxBAPvzXGej7sYoPMhlnykabt0ZzCJNBEyzMlekuQZN7fA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/is-retry-allowed": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/is-retry-allowed/-/is-retry-allowed-1.2.0.tgz", - "integrity": "sha512-RUbUeKwvm3XG2VYamhJL1xFktgjvPzL0Hq8C+6yrWIswDy3BIXGqCxhxkc30N9jqK311gVU137K8Ei55/zVJRg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-shared-array-buffer": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", - "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2" }, @@ -15154,8 +11871,7 @@ }, "node_modules/is-stream": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", - "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "license": "MIT", "engines": { "node": ">=8" }, @@ -15165,8 +11881,7 @@ }, "node_modules/is-string": { "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", - "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "license": "MIT", "dependencies": { "has-tostringtag": "^1.0.0" }, @@ -15179,8 +11894,7 @@ }, "node_modules/is-symbol": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", - "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "license": "MIT", "dependencies": { "has-symbols": "^1.0.2" }, @@ -15193,9 +11907,8 @@ }, "node_modules/is-text-path": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-text-path/-/is-text-path-1.0.1.tgz", - "integrity": "sha512-xFuJpne9oFz5qDaodwmmG08e3CawH/2ZV8Qqza1Ko7Sk8POWbkRdwIoAWVhqvq0XeUzANEhKo2n0IXUGBm7A/w==", "dev": true, + "license": "MIT", "dependencies": { "text-extensions": "^1.0.0" }, @@ -15205,8 +11918,7 @@ }, "node_modules/is-typed-array": { "version": "1.1.12", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", - "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "license": "MIT", "dependencies": { "which-typed-array": "^1.1.11" }, @@ -15219,9 +11931,8 @@ }, "node_modules/is-unicode-supported": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", - "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -15231,15 +11942,13 @@ }, "node_modules/is-url": { "version": "1.2.4", - "resolved": "https://registry.npmjs.org/is-url/-/is-url-1.2.4.tgz", - "integrity": "sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/is-url-superb": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/is-url-superb/-/is-url-superb-4.0.0.tgz", - "integrity": "sha512-GI+WjezhPPcbM+tqE9LnmsY5qqjwHzTvjJ36wxYX5ujNXefSUJ/T17r5bqDV8yLhcgB59KTPNOc9O9cmHTPWsA==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -15249,14 +11958,12 @@ }, "node_modules/is-utf8": { "version": "0.2.1", - "resolved": "https://registry.npmjs.org/is-utf8/-/is-utf8-0.2.1.tgz", - "integrity": "sha512-rMYPYvCzsXywIsldgLaSoPlw5PfoB/ssr7hY4pLfcodrA5M/eArza1a9VmTiNIBNMjOGr1Ow9mTyU2o69U6U9Q==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/is-weakref": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", - "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2" }, @@ -15266,18 +11973,16 @@ }, "node_modules/is-windows": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", - "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-wsl": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", - "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", "dev": true, + "license": "MIT", "dependencies": { "is-docker": "^2.0.0" }, @@ -15287,51 +11992,44 @@ }, "node_modules/isarray": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/iserror": { "version": "0.0.2", - "resolved": "https://registry.npmjs.org/iserror/-/iserror-0.0.2.tgz", - "integrity": "sha512-oKGGrFVaWwETimP3SiWwjDeY27ovZoyZPHtxblC4hCq9fXxed/jasx+ATWFFjCVSRZng8VTMsN1nDnGo6zMBSw==" + "license": "MIT" }, "node_modules/isexe": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + "license": "ISC" }, "node_modules/isobject": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", - "integrity": "sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/isolated-vm": { "version": "4.5.0", - "resolved": "https://registry.npmjs.org/isolated-vm/-/isolated-vm-4.5.0.tgz", - "integrity": "sha512-Kse0m5t+B9wZQVeTDqzPoX1SIFNTNfyaUxhnCuFgpXL1+5GYJ9GUAN3mpD+ainixGmUXgeYaVBX+QPDjEBBu0w==", "hasInstallScript": true, + "license": "ISC", "engines": { "node": ">=10.4.0" } }, "node_modules/istanbul-lib-coverage": { "version": "3.2.2", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz", - "integrity": "sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=8" } }, "node_modules/istanbul-lib-instrument": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.1.tgz", - "integrity": "sha512-EAMEJBsYuyyztxMxW3g7ugGPkrZsV57v0Hmv3mm1uQsmB+QnZuepg731CRaIgeUVSdmsTngOkSnauNF8p7FIhA==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "@babel/core": "^7.12.3", "@babel/parser": "^7.14.7", @@ -15345,9 +12043,8 @@ }, "node_modules/istanbul-lib-report": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz", - "integrity": "sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "istanbul-lib-coverage": "^3.0.0", "make-dir": "^4.0.0", @@ -15359,18 +12056,16 @@ }, "node_modules/istanbul-lib-report/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/istanbul-lib-report/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -15380,9 +12075,8 @@ }, "node_modules/istanbul-lib-source-maps": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", - "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "debug": "^4.1.1", "istanbul-lib-coverage": "^3.0.0", @@ -15394,18 +12088,16 @@ }, "node_modules/istanbul-lib-source-maps/node_modules/source-map": { "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/istanbul-reports": { "version": "3.1.6", - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.1.6.tgz", - "integrity": "sha512-TLgnMkKg3iTDsQ9PbPTdpfAK2DzjF9mqUG7RMgcQl8oFjad8ob4laGxv5XV5U9MAfx8D6tSJiUyuAwzLicaxlg==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "html-escaper": "^2.0.0", "istanbul-lib-report": "^3.0.0" @@ -15416,9 +12108,8 @@ }, "node_modules/isurl": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isurl/-/isurl-1.0.0.tgz", - "integrity": "sha512-1P/yWsxPlDtn7QeRD+ULKQPaIaN6yF368GZ2vDfv0AL0NwpStafjWCDDdn0k8wgFMWpVAqG7oJhxHnlud42i9w==", "dev": true, + "license": "MIT", "dependencies": { "has-to-string-tag-x": "^1.2.0", "is-object": "^1.0.1" @@ -15429,9 +12120,8 @@ }, "node_modules/jackspeak": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-2.3.6.tgz", - "integrity": "sha512-N3yCS/NegsOBokc8GAdM8UcmfsKiSS8cipheD/nivzr700H+nsMOxJjQnvwOcRYVuFkdH0wGUvW2WbXGmrZGbQ==", "dev": true, + "license": "BlueOak-1.0.0", "dependencies": { "@isaacs/cliui": "^8.0.2" }, @@ -15447,9 +12137,8 @@ }, "node_modules/jest": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest/-/jest-29.7.0.tgz", - "integrity": "sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/core": "^29.7.0", "@jest/types": "^29.6.3", @@ -15473,9 +12162,8 @@ }, "node_modules/jest-changed-files": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-29.7.0.tgz", - "integrity": "sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w==", "dev": true, + "license": "MIT", "dependencies": { "execa": "^5.0.0", "jest-util": "^29.7.0", @@ -15487,9 +12175,8 @@ }, "node_modules/jest-circus": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-circus/-/jest-circus-29.7.0.tgz", - "integrity": "sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/environment": "^29.7.0", "@jest/expect": "^29.7.0", @@ -15518,9 +12205,8 @@ }, "node_modules/jest-circus/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -15533,9 +12219,8 @@ }, "node_modules/jest-circus/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -15549,9 +12234,8 @@ }, "node_modules/jest-circus/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -15561,15 +12245,13 @@ }, "node_modules/jest-circus/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-circus/node_modules/dedent": { "version": "1.5.1", - "resolved": "https://registry.npmjs.org/dedent/-/dedent-1.5.1.tgz", - "integrity": "sha512-+LxW+KLWxu3HW3M2w2ympwtqPrqYRzU8fqi6Fhd18fBALe15blJPI/I4+UHveMVG6lJqB4JNd4UG0S5cnVHwIg==", "dev": true, + "license": "MIT", "peerDependencies": { "babel-plugin-macros": "^3.1.0" }, @@ -15581,18 +12263,16 @@ }, "node_modules/jest-circus/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-circus/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -15602,9 +12282,8 @@ }, "node_modules/jest-cli": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.7.0.tgz", - "integrity": "sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg==", "dev": true, + "license": "MIT", "dependencies": { "@jest/core": "^29.7.0", "@jest/test-result": "^29.7.0", @@ -15635,9 +12314,8 @@ }, "node_modules/jest-cli/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -15650,9 +12328,8 @@ }, "node_modules/jest-cli/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -15666,9 +12343,8 @@ }, "node_modules/jest-cli/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -15678,24 +12354,21 @@ }, "node_modules/jest-cli/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-cli/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-cli/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -15705,9 +12378,8 @@ }, "node_modules/jest-config": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.7.0.tgz", - "integrity": "sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/core": "^7.11.6", "@jest/test-sequencer": "^29.7.0", @@ -15750,9 +12422,8 @@ }, "node_modules/jest-config/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -15765,9 +12436,8 @@ }, "node_modules/jest-config/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -15781,9 +12451,8 @@ }, "node_modules/jest-config/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -15793,15 +12462,13 @@ }, "node_modules/jest-config/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-config/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -15819,18 +12486,16 @@ }, "node_modules/jest-config/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-config/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -15840,9 +12505,8 @@ }, "node_modules/jest-diff": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.7.0.tgz", - "integrity": "sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.0.0", "diff-sequences": "^29.6.3", @@ -15855,9 +12519,8 @@ }, "node_modules/jest-diff/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -15870,9 +12533,8 @@ }, "node_modules/jest-diff/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -15886,9 +12548,8 @@ }, "node_modules/jest-diff/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -15898,24 +12559,21 @@ }, "node_modules/jest-diff/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-diff/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-diff/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -15925,9 +12583,8 @@ }, "node_modules/jest-docblock": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.7.0.tgz", - "integrity": "sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g==", "dev": true, + "license": "MIT", "dependencies": { "detect-newline": "^3.0.0" }, @@ -15937,9 +12594,8 @@ }, "node_modules/jest-each": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.7.0.tgz", - "integrity": "sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "chalk": "^4.0.0", @@ -15953,9 +12609,8 @@ }, "node_modules/jest-each/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -15968,9 +12623,8 @@ }, "node_modules/jest-each/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -15984,9 +12638,8 @@ }, "node_modules/jest-each/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -15996,24 +12649,21 @@ }, "node_modules/jest-each/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-each/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-each/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16023,9 +12673,8 @@ }, "node_modules/jest-environment-node": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-29.7.0.tgz", - "integrity": "sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/environment": "^29.7.0", "@jest/fake-timers": "^29.7.0", @@ -16040,18 +12689,16 @@ }, "node_modules/jest-get-type": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", - "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", "dev": true, + "license": "MIT", "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-haste-map": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-29.7.0.tgz", - "integrity": "sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "@types/graceful-fs": "^4.1.3", @@ -16074,9 +12721,8 @@ }, "node_modules/jest-leak-detector": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz", - "integrity": "sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw==", "dev": true, + "license": "MIT", "dependencies": { "jest-get-type": "^29.6.3", "pretty-format": "^29.7.0" @@ -16087,9 +12733,8 @@ }, "node_modules/jest-matcher-utils": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz", - "integrity": "sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.0.0", "jest-diff": "^29.7.0", @@ -16102,9 +12747,8 @@ }, "node_modules/jest-matcher-utils/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16117,9 +12761,8 @@ }, "node_modules/jest-matcher-utils/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16133,9 +12776,8 @@ }, "node_modules/jest-matcher-utils/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16145,24 +12787,21 @@ }, "node_modules/jest-matcher-utils/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-matcher-utils/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-matcher-utils/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16172,9 +12811,8 @@ }, "node_modules/jest-message-util": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", - "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", "dev": true, + "license": "MIT", "dependencies": { "@babel/code-frame": "^7.12.13", "@jest/types": "^29.6.3", @@ -16192,9 +12830,8 @@ }, "node_modules/jest-message-util/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16207,9 +12844,8 @@ }, "node_modules/jest-message-util/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16223,9 +12859,8 @@ }, "node_modules/jest-message-util/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16235,24 +12870,21 @@ }, "node_modules/jest-message-util/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-message-util/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-message-util/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16262,9 +12894,8 @@ }, "node_modules/jest-mock": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.7.0.tgz", - "integrity": "sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "@types/node": "*", @@ -16276,9 +12907,8 @@ }, "node_modules/jest-pnp-resolver": { "version": "1.2.3", - "resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz", - "integrity": "sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" }, @@ -16293,18 +12923,16 @@ }, "node_modules/jest-regex-util": { "version": "29.6.3", - "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-29.6.3.tgz", - "integrity": "sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg==", "dev": true, + "license": "MIT", "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-resolve": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-29.7.0.tgz", - "integrity": "sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.0.0", "graceful-fs": "^4.2.9", @@ -16322,9 +12950,8 @@ }, "node_modules/jest-resolve-dependencies": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz", - "integrity": "sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA==", "dev": true, + "license": "MIT", "dependencies": { "jest-regex-util": "^29.6.3", "jest-snapshot": "^29.7.0" @@ -16335,9 +12962,8 @@ }, "node_modules/jest-resolve/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16350,9 +12976,8 @@ }, "node_modules/jest-resolve/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16366,9 +12991,8 @@ }, "node_modules/jest-resolve/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16378,24 +13002,21 @@ }, "node_modules/jest-resolve/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-resolve/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-resolve/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16405,9 +13026,8 @@ }, "node_modules/jest-runner": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.7.0.tgz", - "integrity": "sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ==", "dev": true, + "license": "MIT", "dependencies": { "@jest/console": "^29.7.0", "@jest/environment": "^29.7.0", @@ -16437,9 +13057,8 @@ }, "node_modules/jest-runner/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16452,9 +13071,8 @@ }, "node_modules/jest-runner/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16468,9 +13086,8 @@ }, "node_modules/jest-runner/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16480,24 +13097,21 @@ }, "node_modules/jest-runner/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-runner/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-runner/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16507,9 +13121,8 @@ }, "node_modules/jest-runtime": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.7.0.tgz", - "integrity": "sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ==", "dev": true, + "license": "MIT", "dependencies": { "@jest/environment": "^29.7.0", "@jest/fake-timers": "^29.7.0", @@ -16540,9 +13153,8 @@ }, "node_modules/jest-runtime/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16555,9 +13167,8 @@ }, "node_modules/jest-runtime/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16571,9 +13182,8 @@ }, "node_modules/jest-runtime/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16583,15 +13193,13 @@ }, "node_modules/jest-runtime/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-runtime/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -16609,18 +13217,16 @@ }, "node_modules/jest-runtime/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-runtime/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16630,9 +13236,8 @@ }, "node_modules/jest-snapshot": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.7.0.tgz", - "integrity": "sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/core": "^7.11.6", "@babel/generator": "^7.7.2", @@ -16661,9 +13266,8 @@ }, "node_modules/jest-snapshot/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16676,9 +13280,8 @@ }, "node_modules/jest-snapshot/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16692,9 +13295,8 @@ }, "node_modules/jest-snapshot/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16704,24 +13306,21 @@ }, "node_modules/jest-snapshot/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-snapshot/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-snapshot/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16731,9 +13330,8 @@ }, "node_modules/jest-sonar": { "version": "0.2.16", - "resolved": "https://registry.npmjs.org/jest-sonar/-/jest-sonar-0.2.16.tgz", - "integrity": "sha512-ES6Z9BbIVDELtbz+/b6pv41B2qOfp38cQpoCLqei21FtlkG/GzhyQ0M3egEIM+erpJOkpRKM8Tc8/YQtHdiTXA==", "dev": true, + "license": "MIT", "dependencies": { "entities": "4.3.0", "strip-ansi": "6.0.1" @@ -16741,9 +13339,8 @@ }, "node_modules/jest-util": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", - "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "@types/node": "*", @@ -16758,9 +13355,8 @@ }, "node_modules/jest-util/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16773,9 +13369,8 @@ }, "node_modules/jest-util/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16789,9 +13384,8 @@ }, "node_modules/jest-util/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16801,24 +13395,21 @@ }, "node_modules/jest-util/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-util/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-util/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16828,9 +13419,8 @@ }, "node_modules/jest-validate": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", - "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", "dev": true, + "license": "MIT", "dependencies": { "@jest/types": "^29.6.3", "camelcase": "^6.2.0", @@ -16845,9 +13435,8 @@ }, "node_modules/jest-validate/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16860,9 +13449,8 @@ }, "node_modules/jest-validate/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16876,9 +13464,8 @@ }, "node_modules/jest-validate/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16888,24 +13475,21 @@ }, "node_modules/jest-validate/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-validate/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-validate/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -16915,9 +13499,8 @@ }, "node_modules/jest-watcher": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.7.0.tgz", - "integrity": "sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g==", "dev": true, + "license": "MIT", "dependencies": { "@jest/test-result": "^29.7.0", "@jest/types": "^29.6.3", @@ -16934,9 +13517,8 @@ }, "node_modules/jest-watcher/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -16949,9 +13531,8 @@ }, "node_modules/jest-watcher/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -16965,9 +13546,8 @@ }, "node_modules/jest-watcher/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -16977,24 +13557,21 @@ }, "node_modules/jest-watcher/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-watcher/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-watcher/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -17004,18 +13581,16 @@ }, "node_modules/jest-when": { "version": "3.6.0", - "resolved": "https://registry.npmjs.org/jest-when/-/jest-when-3.6.0.tgz", - "integrity": "sha512-+cZWTy0ekAJo7M9Om0Scdor1jm3wDiYJWmXE8U22UVnkH54YCXAuaqz3P+up/FdtOg8g4wHOxV7Thd7nKhT6Dg==", "dev": true, + "license": "MIT", "peerDependencies": { "jest": ">= 25" } }, "node_modules/jest-worker": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", - "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", "dev": true, + "license": "MIT", "dependencies": { "@types/node": "*", "jest-util": "^29.7.0", @@ -17028,18 +13603,16 @@ }, "node_modules/jest-worker/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/jest-worker/node_modules/supports-color": { "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -17052,40 +13625,24 @@ }, "node_modules/jiti": { "version": "1.21.0", - "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.0.tgz", - "integrity": "sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==", "dev": true, + "license": "MIT", "optional": true, "bin": { "jiti": "bin/jiti.js" } }, - "node_modules/joi": { - "version": "17.11.0", - "resolved": "https://registry.npmjs.org/joi/-/joi-17.11.0.tgz", - "integrity": "sha512-NgB+lZLNoqISVy1rZocE9PZI36bL/77ie924Ri43yEvi9GUUMPeyVIr8KdFTMUlby1p0PBYMk9spIxEUQYqrJQ==", - "dependencies": { - "@hapi/hoek": "^9.0.0", - "@hapi/topo": "^5.0.0", - "@sideway/address": "^4.1.3", - "@sideway/formula": "^3.0.1", - "@sideway/pinpoint": "^2.0.0" - } - }, "node_modules/js-sha1": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/js-sha1/-/js-sha1-0.6.0.tgz", - "integrity": "sha512-01gwBFreYydzmU9BmZxpVk6svJJHrVxEN3IOiGl6VO93bVKYETJ0sIth6DASI6mIFdt7NmfX9UiByRzsYHGU9w==" + "license": "MIT" }, "node_modules/js-tokens": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" + "license": "MIT" }, "node_modules/js-yaml": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "license": "MIT", "dependencies": { "argparse": "^2.0.1" }, @@ -17095,9 +13652,8 @@ }, "node_modules/jsesc": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.0.2.tgz", - "integrity": "sha512-xKqzzWXDttJuOcawBt4KnKHHIf5oQ/Cxax+0PWFG+DFDgHNAdi+TXECADI+RYiFUMmx8792xsMbbgXj4CwnP4g==", "dev": true, + "license": "MIT", "bin": { "jsesc": "bin/jsesc" }, @@ -17107,13 +13663,11 @@ }, "node_modules/json-buffer": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==" + "license": "MIT" }, "node_modules/json-diff": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/json-diff/-/json-diff-1.0.6.tgz", - "integrity": "sha512-tcFIPRdlc35YkYdGxcamJjllUhXWv4n2rK9oJ2RsAzV4FBkuV4ojKEDgcZ+kpKxDmJKv+PFK65+1tVVOnSeEqA==", + "license": "MIT", "dependencies": { "@ewoudenberg/difflib": "0.1.0", "colors": "^1.4.0", @@ -17128,44 +13682,37 @@ }, "node_modules/json-parse-better-errors": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/json-parse-even-better-errors": { "version": "2.3.1", - "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==" + "license": "MIT" }, "node_modules/json-schema-traverse": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==" + "license": "MIT" }, "node_modules/json-size": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-size/-/json-size-1.0.0.tgz", - "integrity": "sha512-sh8Ff4sNVI3FU1LjFXiNpcG9Er9bsn8WbeR79mGj4Ljd+/NBmxqYCV1sPzndUTGsWXa3LVUx3aLlZxpq1DzCBA==", + "license": "MIT", "dependencies": { "utf8-length": "0.0.1" } }, "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==" + "license": "MIT" }, "node_modules/json-stringify-safe": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/json5": { "version": "2.2.3", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", - "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", "dev": true, + "license": "MIT", "bin": { "json5": "lib/cli.js" }, @@ -17175,23 +13722,20 @@ }, "node_modules/jsonata": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/jsonata/-/jsonata-2.0.5.tgz", - "integrity": "sha512-wEse9+QLIIU5IaCgtJCPsFi/H4F3qcikWzF4bAELZiRz08ohfx3Q6CjDRf4ZPF5P/92RI3KIHtb7u3jqPaHXdQ==", + "license": "MIT", "engines": { "node": ">= 8" } }, "node_modules/jsonc-parser": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.0.tgz", - "integrity": "sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jsonfile": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", - "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", "dev": true, + "license": "MIT", "dependencies": { "universalify": "^2.0.0" }, @@ -17201,18 +13745,16 @@ }, "node_modules/jsonparse": { "version": "1.3.1", - "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", - "integrity": "sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg==", "dev": true, "engines": [ "node >= 0.2.0" - ] + ], + "license": "MIT" }, "node_modules/JSONStream": { "version": "1.3.5", - "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.5.tgz", - "integrity": "sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ==", "dev": true, + "license": "(MIT OR Apache-2.0)", "dependencies": { "jsonparse": "^1.2.0", "through": ">=2.2.7 <3" @@ -17226,16 +13768,18 @@ }, "node_modules/jsontoxml": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/jsontoxml/-/jsontoxml-1.0.1.tgz", - "integrity": "sha512-dtKGq0K8EWQBRqcAaePSgKR4Hyjfsz/LkurHSV3Cxk4H+h2fWDeaN2jzABz+ZmOJylgXS7FGeWmbZ6jgYUMdJQ==", + "license": "MIT", "engines": { "node": ">=0.2.0" } }, + "node_modules/jstoxml": { + "version": "5.0.2", + "license": "MIT" + }, "node_modules/keygrip": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/keygrip/-/keygrip-1.1.0.tgz", - "integrity": "sha512-iYSchDJ+liQ8iwbSI2QqsQOvqv58eJCEanyJPJi+Khyu8smkcKSFUCbPwzFcL7YVtZ6eONjqRX/38caJ7QjRAQ==", + "license": "MIT", "dependencies": { "tsscmp": "1.0.6" }, @@ -17245,33 +13789,29 @@ }, "node_modules/keyv": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", + "license": "MIT", "dependencies": { "json-buffer": "3.0.1" } }, "node_modules/kind-of": { "version": "6.0.3", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", - "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/kleur": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", - "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/koa": { "version": "2.15.0", - "resolved": "https://registry.npmjs.org/koa/-/koa-2.15.0.tgz", - "integrity": "sha512-KEL/vU1knsoUvfP4MC4/GthpQrY/p6dzwaaGI6Rt4NQuFqkw3qrvsdYF5pz3wOfi7IGTvMPHC9aZIcUKYFNxsw==", + "license": "MIT", "dependencies": { "accepts": "^1.3.5", "cache-content-type": "^1.0.0", @@ -17303,8 +13843,7 @@ }, "node_modules/koa-bodyparser": { "version": "4.4.1", - "resolved": "https://registry.npmjs.org/koa-bodyparser/-/koa-bodyparser-4.4.1.tgz", - "integrity": "sha512-kBH3IYPMb+iAXnrxIhXnW+gXV8OTzCu8VPDqvcDHW9SQrbkHmqPQtiZwrltNmSq6/lpipHnT7k7PsjlVD7kK0w==", + "license": "MIT", "dependencies": { "co-body": "^6.0.0", "copy-to": "^2.0.1", @@ -17316,13 +13855,11 @@ }, "node_modules/koa-compose": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/koa-compose/-/koa-compose-4.1.0.tgz", - "integrity": "sha512-8ODW8TrDuMYvXRwra/Kh7/rJo9BtOfPc6qO8eAfC80CnCvSjSl0bkRM24X6/XBBEyj0v1nRUQ1LyOy3dbqOWXw==" + "license": "MIT" }, "node_modules/koa-convert": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/koa-convert/-/koa-convert-2.0.0.tgz", - "integrity": "sha512-asOvN6bFlSnxewce2e/DK3p4tltyfC4VM7ZwuTuepI7dEQVcvpyFuBcEARu1+Hxg8DIwytce2n7jrZtRlPrARA==", + "license": "MIT", "dependencies": { "co": "^4.6.0", "koa-compose": "^4.1.0" @@ -17333,8 +13870,7 @@ }, "node_modules/koa/node_modules/http-errors": { "version": "1.8.1", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.8.1.tgz", - "integrity": "sha512-Kpk9Sm7NmI+RHhnj6OIWDI1d6fIoFAtFt9RLaTMRlg/8w49juAStsrBgp0Dp4OdxdVbRIeKhtCUvoi/RuAhO4g==", + "license": "MIT", "dependencies": { "depd": "~1.1.2", "inherits": "2.0.4", @@ -17348,24 +13884,21 @@ }, "node_modules/koa/node_modules/http-errors/node_modules/depd": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", - "integrity": "sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/koa/node_modules/statuses": { "version": "1.5.0", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", - "integrity": "sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/koa2-swagger-ui": { "version": "5.10.0", - "resolved": "https://registry.npmjs.org/koa2-swagger-ui/-/koa2-swagger-ui-5.10.0.tgz", - "integrity": "sha512-UEktDUyWP5BvBB8glVWHN14246IH6WZC8sryONC+v9Rm6FA3/8V+CgXpRuHkAEy0KntMwp2sJ5CutTu6ODtC3w==", + "license": "MIT", "dependencies": { "handlebars": "^4.7.8", "lodash": "^4.17.21", @@ -17377,8 +13910,7 @@ }, "node_modules/koa2-swagger-ui/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -17389,8 +13921,7 @@ }, "node_modules/koa2-swagger-ui/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -17400,8 +13931,7 @@ }, "node_modules/koa2-swagger-ui/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -17414,8 +13944,7 @@ }, "node_modules/koa2-swagger-ui/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -17425,8 +13954,7 @@ }, "node_modules/koa2-swagger-ui/node_modules/read-pkg": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", - "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", + "license": "MIT", "dependencies": { "@types/normalize-package-data": "^2.4.0", "normalize-package-data": "^2.5.0", @@ -17439,8 +13967,7 @@ }, "node_modules/koa2-swagger-ui/node_modules/read-pkg-up": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", - "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", + "license": "MIT", "dependencies": { "find-up": "^4.1.0", "read-pkg": "^5.2.0", @@ -17455,47 +13982,41 @@ }, "node_modules/koa2-swagger-ui/node_modules/read-pkg/node_modules/type-fest": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", - "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/koa2-swagger-ui/node_modules/type-fest": { "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/kuler": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/kuler/-/kuler-2.0.0.tgz", - "integrity": "sha512-Xq9nH7KlWZmXAtodXDDRE7vs6DU1gTU8zYDHDiWLSip45Egwq3plLHzPn27NgvzL2r1LMPC1vdqh98sQxtqj4A==" + "license": "MIT" }, "node_modules/lazy-ass": { "version": "1.6.0", - "resolved": "https://registry.npmjs.org/lazy-ass/-/lazy-ass-1.6.0.tgz", - "integrity": "sha512-cc8oEVoctTvsFZ/Oje/kGnHbpWHYBe8IAJe4C0QNc3t8uM/0Y8+erSz/7Y1ALuXTEZTMvxXwO6YbX1ey3ujiZw==", "dev": true, + "license": "MIT", "engines": { "node": "> 0.8" } }, "node_modules/leven": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", - "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/levn": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", + "license": "MIT", "dependencies": { "prelude-ls": "^1.2.1", "type-check": "~0.4.0" @@ -17506,28 +14027,24 @@ }, "node_modules/libphonenumber-js": { "version": "1.11.1", - "resolved": "https://registry.npmjs.org/libphonenumber-js/-/libphonenumber-js-1.11.1.tgz", - "integrity": "sha512-Wze1LPwcnzvcKGcRHFGFECTaLzxOtujwpf924difr5zniyYv1C2PiW0419qDR7m8lKDxsImu5mwxFuXhXpjmvw==" + "license": "MIT" }, "node_modules/lilconfig": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.1.0.tgz", - "integrity": "sha512-utWOt/GHzuUxnLKxB6dk81RoOeoNeHgbrXiuGk4yyF5qlRz+iIVWu56E2fqGHFrXz0QNUhLB/8nKqvRH66JKGQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" } }, "node_modules/lines-and-columns": { "version": "1.2.4", - "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", - "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==" + "license": "MIT" }, "node_modules/lint-staged": { "version": "13.3.0", - "resolved": "https://registry.npmjs.org/lint-staged/-/lint-staged-13.3.0.tgz", - "integrity": "sha512-mPRtrYnipYYv1FEE134ufbWpeggNTo+O/UPzngoaKzbzHAthvR55am+8GfHTnqNRQVRRrYQLGW9ZyUoD7DsBHQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "5.3.0", "commander": "11.0.0", @@ -17552,9 +14069,8 @@ }, "node_modules/lint-staged/node_modules/chalk": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz", - "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==", "dev": true, + "license": "MIT", "engines": { "node": "^12.17.0 || ^14.13 || >=16.0.0" }, @@ -17564,18 +14080,16 @@ }, "node_modules/lint-staged/node_modules/commander": { "version": "11.0.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-11.0.0.tgz", - "integrity": "sha512-9HMlXtt/BNoYr8ooyjjNRdIilOTkVJXB+GhxMTtOKwk0R4j4lS4NpjuqmRxroBfnfTSHQIHQB7wryHhXarNjmQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=16" } }, "node_modules/lint-staged/node_modules/execa": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/execa/-/execa-7.2.0.tgz", - "integrity": "sha512-UduyVP7TLB5IcAQl+OzLyLcS/l32W/GLg+AhHJ+ow40FOk2U3SAllPwR44v4vmdFwIWqpdwxxpQbF1n5ta9seA==", "dev": true, + "license": "MIT", "dependencies": { "cross-spawn": "^7.0.3", "get-stream": "^6.0.1", @@ -17596,18 +14110,16 @@ }, "node_modules/lint-staged/node_modules/human-signals": { "version": "4.3.1", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-4.3.1.tgz", - "integrity": "sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ==", "dev": true, + "license": "Apache-2.0", "engines": { "node": ">=14.18.0" } }, "node_modules/lint-staged/node_modules/is-stream": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-3.0.0.tgz", - "integrity": "sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==", "dev": true, + "license": "MIT", "engines": { "node": "^12.20.0 || ^14.13.1 || >=16.0.0" }, @@ -17617,9 +14129,8 @@ }, "node_modules/lint-staged/node_modules/mimic-fn": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-4.0.0.tgz", - "integrity": "sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -17629,9 +14140,8 @@ }, "node_modules/lint-staged/node_modules/npm-run-path": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-5.2.0.tgz", - "integrity": "sha512-W4/tgAXFqFA0iL7fk0+uQ3g7wkL8xJmx3XdK0VGb4cHW//eZTtKGvFBBoRKVTpY7n6ze4NL9ly7rgXcHufqXKg==", "dev": true, + "license": "MIT", "dependencies": { "path-key": "^4.0.0" }, @@ -17644,9 +14154,8 @@ }, "node_modules/lint-staged/node_modules/onetime": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-6.0.0.tgz", - "integrity": "sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==", "dev": true, + "license": "MIT", "dependencies": { "mimic-fn": "^4.0.0" }, @@ -17659,9 +14168,8 @@ }, "node_modules/lint-staged/node_modules/path-key": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-4.0.0.tgz", - "integrity": "sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -17671,9 +14179,8 @@ }, "node_modules/lint-staged/node_modules/strip-final-newline": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-3.0.0.tgz", - "integrity": "sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -17683,18 +14190,16 @@ }, "node_modules/lint-staged/node_modules/yaml": { "version": "2.3.1", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.3.1.tgz", - "integrity": "sha512-2eHWfjaoXgTBC2jNM1LRef62VQa0umtvRiDSk6HSzW7RvS5YtkabJrwYLLEKWBc8a5U2PTSCs+dJjUTJdlHsWQ==", "dev": true, + "license": "ISC", "engines": { "node": ">= 14" } }, "node_modules/listr2": { "version": "6.6.1", - "resolved": "https://registry.npmjs.org/listr2/-/listr2-6.6.1.tgz", - "integrity": "sha512-+rAXGHh0fkEWdXBmX+L6mmfmXmXvDGEKzkjxO+8mP3+nI/r/CWznVBvsibXdxda9Zz0OW2e2ikphN3OwCT/jSg==", "dev": true, + "license": "MIT", "dependencies": { "cli-truncate": "^3.1.0", "colorette": "^2.0.20", @@ -17717,9 +14222,8 @@ }, "node_modules/listr2/node_modules/ansi-regex": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", - "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -17729,9 +14233,8 @@ }, "node_modules/listr2/node_modules/ansi-styles": { "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", - "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -17741,21 +14244,18 @@ }, "node_modules/listr2/node_modules/emoji-regex": { "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/listr2/node_modules/eventemitter3": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz", - "integrity": "sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/listr2/node_modules/string-width": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", - "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", "dev": true, + "license": "MIT", "dependencies": { "eastasianwidth": "^0.2.0", "emoji-regex": "^9.2.2", @@ -17770,9 +14270,8 @@ }, "node_modules/listr2/node_modules/strip-ansi": { "version": "7.1.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", - "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-regex": "^6.0.1" }, @@ -17785,9 +14284,8 @@ }, "node_modules/listr2/node_modules/wrap-ansi": { "version": "8.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", - "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^6.1.0", "string-width": "^5.0.1", @@ -17802,9 +14300,8 @@ }, "node_modules/load-json-file": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz", - "integrity": "sha512-Kx8hMakjX03tiGTLAIdJ+lL0htKnXjEZN6hk/tozf/WOuYGdZBJrZ+rCJRbVCugsjB3jMLn9746NsQIf5VjBMw==", "dev": true, + "license": "MIT", "dependencies": { "graceful-fs": "^4.1.2", "parse-json": "^4.0.0", @@ -17817,9 +14314,8 @@ }, "node_modules/load-json-file/node_modules/parse-json": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==", "dev": true, + "license": "MIT", "dependencies": { "error-ex": "^1.3.1", "json-parse-better-errors": "^1.0.1" @@ -17830,26 +14326,23 @@ }, "node_modules/load-json-file/node_modules/pify": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/load-json-file/node_modules/strip-bom": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/locate-path": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "license": "MIT", "dependencies": { "p-locate": "^5.0.0" }, @@ -17862,100 +14355,83 @@ }, "node_modules/lodash": { "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + "license": "MIT" }, "node_modules/lodash._reinterpolate": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz", - "integrity": "sha512-xYHt68QRoYGjeeM/XOE1uJtvXQAgvszfBhjV4yvsQH0u2i9I6cI6c6/eG4Hh3UAOVn0y/xAXwmTzEay49Q//HA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.camelcase": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz", - "integrity": "sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.defaults": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/lodash.defaults/-/lodash.defaults-4.2.0.tgz", - "integrity": "sha512-qjxPLHd3r5DnsdGacqOMU6pb/avJzdh9tFX2ymgoZE27BmjXrNy/y4LoaiTeAb+O3gL8AfpJGtqfX/ae2leYYQ==" + "license": "MIT" }, "node_modules/lodash.isarguments": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz", - "integrity": "sha512-chi4NHZlZqZD18a0imDHnZPrDeBbTtVN7GXMwuGdRH9qotxAjYs3aVLKc7zNOG9eddR5Ksd8rvFEBc9SsggPpg==" + "license": "MIT" }, "node_modules/lodash.isfunction": { "version": "3.0.9", - "resolved": "https://registry.npmjs.org/lodash.isfunction/-/lodash.isfunction-3.0.9.tgz", - "integrity": "sha512-AirXNj15uRIMMPihnkInB4i3NHeb4iBtNg9WRWuK2o31S+ePwwNmDPaTL3o7dTJ+VXNZim7rFs4rxN4YU1oUJw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.ismatch": { "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.ismatch/-/lodash.ismatch-4.4.0.tgz", - "integrity": "sha512-fPMfXjGQEV9Xsq/8MTSgUf255gawYRbjwMyDbcvDhXgV7enSZA0hynz6vMPnpAb5iONEzBHBPsT+0zes5Z301g==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.isplainobject": { "version": "4.0.6", - "resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz", - "integrity": "sha512-oSXzaWypCMHkPC3NvBEaPHf0KsA5mvPrOPgQWDsbg8n7orZ290M0BmC/jgRZ4vcJ6DTAhjrsSYgdsW/F+MFOBA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.kebabcase": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/lodash.kebabcase/-/lodash.kebabcase-4.1.1.tgz", - "integrity": "sha512-N8XRTIMMqqDgSy4VLKPnJ/+hpGZN+PHQiJnSenYqPaVV/NCqEogTnAdZLQiGKhxX+JCs8waWq2t1XHWKOmlY8g==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.map": { "version": "4.6.0", - "resolved": "https://registry.npmjs.org/lodash.map/-/lodash.map-4.6.0.tgz", - "integrity": "sha512-worNHGKLDetmcEYDvh2stPCrrQRkP20E4l0iIS7F8EvzMqBBi7ltvFN5m1HvTf1P7Jk1txKhvFcmYsCr8O2F1Q==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.memoize": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", - "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.merge": { "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==" + "license": "MIT" }, "node_modules/lodash.mergewith": { "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.mergewith/-/lodash.mergewith-4.6.2.tgz", - "integrity": "sha512-GK3g5RPZWTRSeLSpgP8Xhra+pnjBC56q9FZYe1d5RN3TJ35dbkGy3YqBSMbyCrlbi+CM9Z3Jk5yTL7RCsqboyQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.snakecase": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/lodash.snakecase/-/lodash.snakecase-4.1.1.tgz", - "integrity": "sha512-QZ1d4xoBHYUeuouhEq3lk3Uq7ldgyFXGBhg04+oRLnIz8o9T65Eh+8YdroUwn846zchkA9yDsDl5CVVaV2nqYw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.sortby": { "version": "4.7.0", - "resolved": "https://registry.npmjs.org/lodash.sortby/-/lodash.sortby-4.7.0.tgz", - "integrity": "sha512-HDWXG8isMntAyRF5vZ7xKuEvOhT4AhlRt/3czTSjvGUxjYCBVRQY48ViDHyfYz9VIoBkW4TMGQNapx+l3RUwdA==" + "license": "MIT" }, "node_modules/lodash.startcase": { "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.startcase/-/lodash.startcase-4.4.0.tgz", - "integrity": "sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/lodash.template": { "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.template/-/lodash.template-4.5.0.tgz", - "integrity": "sha512-84vYFxIkmidUiFxidA/KjjH9pAycqW+h980j7Fuz5qxRtO9pgB7MDFTdys1N7A5mcucRiDyEq4fusljItR1T/A==", "dev": true, + "license": "MIT", "dependencies": { "lodash._reinterpolate": "^3.0.0", "lodash.templatesettings": "^4.0.0" @@ -17963,29 +14439,25 @@ }, "node_modules/lodash.templatesettings": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/lodash.templatesettings/-/lodash.templatesettings-4.2.0.tgz", - "integrity": "sha512-stgLz+i3Aa9mZgnjr/O+v9ruKZsPsndy7qPZOchbqk2cnTU1ZaldKK+v7m54WoKIyxiuMZTKT2H81F8BeAc3ZQ==", "dev": true, + "license": "MIT", "dependencies": { "lodash._reinterpolate": "^3.0.0" } }, "node_modules/lodash.uniq": { "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", - "integrity": "sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ==" + "license": "MIT" }, "node_modules/lodash.upperfirst": { "version": "4.3.1", - "resolved": "https://registry.npmjs.org/lodash.upperfirst/-/lodash.upperfirst-4.3.1.tgz", - "integrity": "sha512-sReKOYJIJf74dhJONhU4e0/shzi1trVbSWDOhKYE5XV2O+H7Sb2Dihwuc7xWxVl+DgFPyTqIN3zMfT9cq5iWDg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/log-symbols": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.0", "is-unicode-supported": "^0.1.0" @@ -17999,9 +14471,8 @@ }, "node_modules/log-symbols/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -18014,9 +14485,8 @@ }, "node_modules/log-symbols/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -18030,9 +14500,8 @@ }, "node_modules/log-symbols/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -18042,24 +14511,21 @@ }, "node_modules/log-symbols/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/log-symbols/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/log-symbols/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -18069,9 +14535,8 @@ }, "node_modules/log-update": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/log-update/-/log-update-5.0.1.tgz", - "integrity": "sha512-5UtUDQ/6edw4ofyljDNcOVJQ4c7OjDro4h3y8e1GQL5iYElYclVHJ3zeWchylvMaKnDbDilC8irOVyexnA/Slw==", "dev": true, + "license": "MIT", "dependencies": { "ansi-escapes": "^5.0.0", "cli-cursor": "^4.0.0", @@ -18088,9 +14553,8 @@ }, "node_modules/log-update/node_modules/ansi-escapes": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-5.0.0.tgz", - "integrity": "sha512-5GFMVX8HqE/TB+FuBJGuO5XG0WrsA6ptUqoODaT/n9mmUaZFkqnBueB4leqGBCmrUHnCnC4PCZTCd0E7QQ83bA==", "dev": true, + "license": "MIT", "dependencies": { "type-fest": "^1.0.2" }, @@ -18103,9 +14567,8 @@ }, "node_modules/log-update/node_modules/ansi-regex": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", - "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -18115,9 +14578,8 @@ }, "node_modules/log-update/node_modules/ansi-styles": { "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", - "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -18127,9 +14589,8 @@ }, "node_modules/log-update/node_modules/cli-cursor": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-4.0.0.tgz", - "integrity": "sha512-VGtlMu3x/4DOtIUwEkRezxUZ2lBacNJCHash0N0WeZDBS+7Ux1dm3XWAgWYxLJFMMdOeXMHXorshEFhbMSGelg==", "dev": true, + "license": "MIT", "dependencies": { "restore-cursor": "^4.0.0" }, @@ -18142,15 +14603,13 @@ }, "node_modules/log-update/node_modules/emoji-regex": { "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/log-update/node_modules/restore-cursor": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-4.0.0.tgz", - "integrity": "sha512-I9fPXU9geO9bHOt9pHHOhOkYerIMsmVaWB0rA2AI9ERh/+x/i7MV5HKBNrg+ljO5eoPVgCcnFuRjJ9uH6I/3eg==", "dev": true, + "license": "MIT", "dependencies": { "onetime": "^5.1.0", "signal-exit": "^3.0.2" @@ -18164,9 +14623,8 @@ }, "node_modules/log-update/node_modules/string-width": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", - "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", "dev": true, + "license": "MIT", "dependencies": { "eastasianwidth": "^0.2.0", "emoji-regex": "^9.2.2", @@ -18181,9 +14639,8 @@ }, "node_modules/log-update/node_modules/strip-ansi": { "version": "7.1.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", - "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-regex": "^6.0.1" }, @@ -18196,9 +14653,8 @@ }, "node_modules/log-update/node_modules/type-fest": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-1.4.0.tgz", - "integrity": "sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=10" }, @@ -18208,9 +14664,8 @@ }, "node_modules/log-update/node_modules/wrap-ansi": { "version": "8.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", - "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^6.1.0", "string-width": "^5.0.1", @@ -18225,8 +14680,7 @@ }, "node_modules/logform": { "version": "2.6.0", - "resolved": "https://registry.npmjs.org/logform/-/logform-2.6.0.tgz", - "integrity": "sha512-1ulHeNPp6k/LD8H91o7VYFBng5i1BDE7HoKxVbZiGFidS1Rj65qcywLxX+pVfAPoQJEjRdvKcusKwOupHCVOVQ==", + "license": "MIT", "dependencies": { "@colors/colors": "1.6.0", "@types/triple-beam": "^1.3.2", @@ -18241,23 +14695,20 @@ }, "node_modules/long": { "version": "5.2.3", - "resolved": "https://registry.npmjs.org/long/-/long-5.2.3.tgz", - "integrity": "sha512-lcHwpNoggQTObv5apGNCTdJrO69eHOZMi4BNC+rTLER8iHAqGrUVeLh/irVIM7zTw2bOXA8T6uNPeujwOLg/2Q==" + "license": "Apache-2.0" }, "node_modules/longest": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/longest/-/longest-2.0.1.tgz", - "integrity": "sha512-Ajzxb8CM6WAnFjgiloPsI3bF+WCxcvhdIG3KNA2KN962+tdBsHcuQ4k4qX/EcS/2CRkcc0iAkR956Nib6aXU/Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/loud-rejection": { "version": "1.6.0", - "resolved": "https://registry.npmjs.org/loud-rejection/-/loud-rejection-1.6.0.tgz", - "integrity": "sha512-RPNliZOFkqFumDhvYqOaNY4Uz9oJM2K9tC6JWsJJsNdhuONW4LQHRBpb0qf4pJApVffI5N39SwzWZJuEhfd7eQ==", "dev": true, + "license": "MIT", "dependencies": { "currently-unhandled": "^0.4.1", "signal-exit": "^3.0.0" @@ -18268,27 +14719,24 @@ }, "node_modules/lowercase-keys": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-1.0.1.tgz", - "integrity": "sha512-G2Lj61tXDnVFFOi8VZds+SoQjtQC3dgokKdDG2mTm1tx4m50NUHBOZSBwQQHyy0V12A0JTG4icfZQH+xPyh8VA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/lru-cache": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", - "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", "dev": true, + "license": "ISC", "dependencies": { "yallist": "^3.0.2" } }, "node_modules/madge": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/madge/-/madge-6.1.0.tgz", - "integrity": "sha512-irWhT5RpFOc6lkzGHKLihonCVgM0YtfNUh4IrFeW3EqHpnt/JHUG3z26j8PeJEktCGB4tmGOOOJi1Rl/ACWucQ==", "dev": true, + "license": "MIT", "dependencies": { "chalk": "^4.1.1", "commander": "^7.2.0", @@ -18334,9 +14782,8 @@ }, "node_modules/madge/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -18349,9 +14796,8 @@ }, "node_modules/madge/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -18365,9 +14811,8 @@ }, "node_modules/madge/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -18377,33 +14822,29 @@ }, "node_modules/madge/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/madge/node_modules/commander": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", - "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", "dev": true, + "license": "MIT", "engines": { "node": ">= 10" } }, "node_modules/madge/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/madge/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -18413,9 +14854,8 @@ }, "node_modules/make-dir": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-4.0.0.tgz", - "integrity": "sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==", "dev": true, + "license": "MIT", "dependencies": { "semver": "^7.5.3" }, @@ -18428,24 +14868,21 @@ }, "node_modules/make-error": { "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/makeerror": { "version": "1.0.12", - "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", - "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "tmpl": "1.0.5" } }, "node_modules/map-obj": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-4.3.0.tgz", - "integrity": "sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" }, @@ -18455,13 +14892,11 @@ }, "node_modules/match-json": { "version": "1.3.7", - "resolved": "https://registry.npmjs.org/match-json/-/match-json-1.3.7.tgz", - "integrity": "sha512-2/GIaio/oVWVHGdKOIbqfgqT5vH91K3c91l6EAsVydMAjB0iGy5PVABicKzNT1VAgHskZHbaZK9q96AmgTEqkw==" + "license": "MIT" }, "node_modules/md5": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/md5/-/md5-2.3.0.tgz", - "integrity": "sha512-T1GITYmFaKuO91vxyoQMFETst+O71VUPEU3ze5GNzDm0OWdP8v1ziTaAEPUr/3kLsY3Sftgz242A1SetQiDL7g==", + "license": "BSD-3-Clause", "dependencies": { "charenc": "0.0.2", "crypt": "0.0.2", @@ -18470,22 +14905,19 @@ }, "node_modules/md5/node_modules/is-buffer": { "version": "1.1.6", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + "license": "MIT" }, "node_modules/media-typer": { "version": "0.3.0", - "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", - "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/meow": { "version": "8.1.2", - "resolved": "https://registry.npmjs.org/meow/-/meow-8.1.2.tgz", - "integrity": "sha512-r85E3NdZ+mpYk1C6RjPFEMSE+s1iZMuHtsHAqY0DT3jZczl0diWUZ8g6oU7h0M9cD2EL+PzaYghhCLzR0ZNn5Q==", "dev": true, + "license": "MIT", "dependencies": { "@types/minimist": "^1.2.0", "camelcase-keys": "^6.2.2", @@ -18508,9 +14940,8 @@ }, "node_modules/meow/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -18521,9 +14952,8 @@ }, "node_modules/meow/node_modules/hosted-git-info": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", - "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", "dev": true, + "license": "ISC", "dependencies": { "lru-cache": "^6.0.0" }, @@ -18533,9 +14963,8 @@ }, "node_modules/meow/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -18545,9 +14974,8 @@ }, "node_modules/meow/node_modules/lru-cache": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", "dev": true, + "license": "ISC", "dependencies": { "yallist": "^4.0.0" }, @@ -18557,9 +14985,8 @@ }, "node_modules/meow/node_modules/normalize-package-data": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-3.0.3.tgz", - "integrity": "sha512-p2W1sgqij3zMMyRC067Dg16bfzVH+w7hyegmpIvZ4JNjqtGOVAIvLmjBx3yP7YTe9vKJgkoNOPjwQGogDoMXFA==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "hosted-git-info": "^4.0.1", "is-core-module": "^2.5.0", @@ -18572,9 +14999,8 @@ }, "node_modules/meow/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -18587,9 +15013,8 @@ }, "node_modules/meow/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -18599,9 +15024,8 @@ }, "node_modules/meow/node_modules/read-pkg": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", - "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", "dev": true, + "license": "MIT", "dependencies": { "@types/normalize-package-data": "^2.4.0", "normalize-package-data": "^2.5.0", @@ -18614,9 +15038,8 @@ }, "node_modules/meow/node_modules/read-pkg-up": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", - "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^4.1.0", "read-pkg": "^5.2.0", @@ -18631,24 +15054,21 @@ }, "node_modules/meow/node_modules/read-pkg-up/node_modules/type-fest": { "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/meow/node_modules/read-pkg/node_modules/hosted-git-info": { "version": "2.8.9", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz", - "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/meow/node_modules/read-pkg/node_modules/normalize-package-data": { "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "hosted-git-info": "^2.1.4", "resolve": "^1.10.0", @@ -18658,27 +15078,24 @@ }, "node_modules/meow/node_modules/read-pkg/node_modules/semver": { "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver" } }, "node_modules/meow/node_modules/read-pkg/node_modules/type-fest": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", - "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/meow/node_modules/type-fest": { "version": "0.18.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.18.1.tgz", - "integrity": "sha512-OIAYXk8+ISY+qTOwkHtKqzAuxchoMiD9Udx+FSGQDuiRR+PJKJHc2NJAXlbhkGwTt/4/nKZxELY1w3ReWOL8mw==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=10" }, @@ -18688,50 +15105,43 @@ }, "node_modules/meow/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/merge": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/merge/-/merge-2.1.1.tgz", - "integrity": "sha512-jz+Cfrg9GWOZbQAnDQ4hlVnQky+341Yk5ru8bZSe6sIDTCIg8n9i/u7hSQGSVOF3C7lH6mGtqjkiT9G4wFLL0w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/merge-descriptors": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", - "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/merge-stream": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", - "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/merge2": { "version": "1.4.1", - "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", - "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "license": "MIT", "engines": { "node": ">= 8" } }, "node_modules/methods": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", - "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/micromatch": { "version": "4.0.5", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", - "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", + "license": "MIT", "dependencies": { "braces": "^3.0.2", "picomatch": "^2.3.1" @@ -18742,9 +15152,8 @@ }, "node_modules/mime": { "version": "2.6.0", - "resolved": "https://registry.npmjs.org/mime/-/mime-2.6.0.tgz", - "integrity": "sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg==", "dev": true, + "license": "MIT", "bin": { "mime": "cli.js" }, @@ -18754,16 +15163,14 @@ }, "node_modules/mime-db": { "version": "1.52.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", - "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/mime-types": { "version": "2.1.35", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", - "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "license": "MIT", "dependencies": { "mime-db": "1.52.0" }, @@ -18773,35 +15180,31 @@ }, "node_modules/mimic-fn": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", - "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/mimic-response": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", - "integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/min-indent": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/min-indent/-/min-indent-1.0.1.tgz", - "integrity": "sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/minimatch": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "license": "ISC", "dependencies": { "brace-expansion": "^1.1.7" }, @@ -18811,17 +15214,15 @@ }, "node_modules/minimist": { "version": "1.2.7", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.7.tgz", - "integrity": "sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/minimist-options": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/minimist-options/-/minimist-options-4.1.0.tgz", - "integrity": "sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==", "dev": true, + "license": "MIT", "dependencies": { "arrify": "^1.0.1", "is-plain-obj": "^1.1.0", @@ -18833,17 +15234,15 @@ }, "node_modules/minipass": { "version": "7.0.4", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.0.4.tgz", - "integrity": "sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ==", "dev": true, + "license": "ISC", "engines": { "node": ">=16 || 14 >=14.17" } }, "node_modules/minizlib": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", - "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", + "license": "MIT", "dependencies": { "minipass": "^3.0.0", "yallist": "^4.0.0" @@ -18854,8 +15253,7 @@ }, "node_modules/minizlib/node_modules/minipass": { "version": "3.3.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", - "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "license": "ISC", "dependencies": { "yallist": "^4.0.0" }, @@ -18865,13 +15263,11 @@ }, "node_modules/minizlib/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + "license": "ISC" }, "node_modules/mkdirp": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", + "license": "MIT", "bin": { "mkdirp": "bin/cmd.js" }, @@ -18881,9 +15277,8 @@ }, "node_modules/mocked-env": { "version": "1.3.5", - "resolved": "https://registry.npmjs.org/mocked-env/-/mocked-env-1.3.5.tgz", - "integrity": "sha512-GyYY6ynVOdEoRlaGpaq8UYwdWkvrsU2xRme9B+WPSuJcNjh17+3QIxSYU6zwee0SbehhV6f06VZ4ahjG+9zdrA==", "dev": true, + "license": "MIT", "dependencies": { "check-more-types": "2.24.0", "debug": "4.3.2", @@ -18896,9 +15291,8 @@ }, "node_modules/mocked-env/node_modules/debug": { "version": "4.3.2", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.2.tgz", - "integrity": "sha512-mOp8wKcvj7XxC78zLgw/ZA+6TSgkoE2C/ienthhRD298T7UNwAg9diBpLRxC0mOezLl4B0xV7M0cCO6P/O0Xhw==", "dev": true, + "license": "MIT", "dependencies": { "ms": "2.1.2" }, @@ -18913,8 +15307,7 @@ }, "node_modules/modclean": { "version": "3.0.0-beta.1", - "resolved": "https://registry.npmjs.org/modclean/-/modclean-3.0.0-beta.1.tgz", - "integrity": "sha512-NyJpuqXMUI190sZePU+dBcwlGaqhfFC+UL5WyNSxmNLOHATg9cVSgRpbY+mUbwUj7t5trb4vYscgXArKevYsdA==", + "license": "MIT", "dependencies": { "await-handler": "^1.1.0", "chalk": "^2.4.1", @@ -18942,16 +15335,14 @@ }, "node_modules/modclean/node_modules/ansi-regex": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", - "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/modclean/node_modules/cli-cursor": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz", - "integrity": "sha512-8lgKz8LmCRYZZQDpRyT2m5rKJ08TnU4tR9FFFW2rxpxR1FzWi4PQ/NfyODchAatHaUgnSPVcx/R5w6NuTBzFiw==", + "license": "MIT", "dependencies": { "restore-cursor": "^2.0.0" }, @@ -18961,21 +15352,18 @@ }, "node_modules/modclean/node_modules/cli-spinners": { "version": "1.3.1", - "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-1.3.1.tgz", - "integrity": "sha512-1QL4544moEsDVH9T/l6Cemov/37iv1RtoKf7NJ04A60+4MREXNfx/QvavbH6QoGdsD4N4Mwy49cmaINR/o2mdg==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/modclean/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==" + "license": "MIT" }, "node_modules/modclean/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -18993,8 +15381,7 @@ }, "node_modules/modclean/node_modules/log-symbols": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-2.2.0.tgz", - "integrity": "sha512-VeIAFslyIerEJLXHziedo2basKbMKtTw3vfn5IzG0XTjhAVEJyNHnL2p7vc+wBDSdQuUpNw3M2u6xb9QsAY5Eg==", + "license": "MIT", "dependencies": { "chalk": "^2.0.1" }, @@ -19004,16 +15391,14 @@ }, "node_modules/modclean/node_modules/mimic-fn": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.2.0.tgz", - "integrity": "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/modclean/node_modules/onetime": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-2.0.1.tgz", - "integrity": "sha512-oyyPpiMaKARvvcgip+JV+7zci5L8D1W9RZIz2l1o08AM3pfspitVWnPt3mzHcBPp12oYMTy0pqrFs/C+m3EwsQ==", + "license": "MIT", "dependencies": { "mimic-fn": "^1.0.0" }, @@ -19023,8 +15408,7 @@ }, "node_modules/modclean/node_modules/ora": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/ora/-/ora-2.1.0.tgz", - "integrity": "sha512-hNNlAd3gfv/iPmsNxYoAPLvxg7HuPozww7fFonMZvL84tP6Ox5igfk5j/+a9rtJJwqMgKK+JgWsAQik5o0HTLA==", + "license": "MIT", "dependencies": { "chalk": "^2.3.1", "cli-cursor": "^2.1.0", @@ -19039,8 +15423,7 @@ }, "node_modules/modclean/node_modules/restore-cursor": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz", - "integrity": "sha512-6IzJLuGi4+R14vwagDHX+JrXmPVtPpn4mffDJ1UdR7/Edm87fl6yi8mMBIVvFtJaNTUvjughmW4hwLhRG7gC1Q==", + "license": "MIT", "dependencies": { "onetime": "^2.0.0", "signal-exit": "^3.0.2" @@ -19051,8 +15434,7 @@ }, "node_modules/modclean/node_modules/rimraf": { "version": "2.7.1", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", - "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", + "license": "ISC", "dependencies": { "glob": "^7.1.3" }, @@ -19062,8 +15444,7 @@ }, "node_modules/modclean/node_modules/strip-ansi": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==", + "license": "MIT", "dependencies": { "ansi-regex": "^3.0.0" }, @@ -19073,18 +15454,16 @@ }, "node_modules/modify-values": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/modify-values/-/modify-values-1.0.1.tgz", - "integrity": "sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/module-definition": { "version": "3.4.0", - "resolved": "https://registry.npmjs.org/module-definition/-/module-definition-3.4.0.tgz", - "integrity": "sha512-XxJ88R1v458pifaSkPNLUTdSPNVGMP2SXVncVmApGO+gAfrLANiYe6JofymCzVceGOMwQE2xogxBSc8uB7XegA==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^3.0.0", "node-source-walk": "^4.0.0" @@ -19098,18 +15477,16 @@ }, "node_modules/module-definition/node_modules/ast-module-types": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ast-module-types/-/ast-module-types-3.0.0.tgz", - "integrity": "sha512-CMxMCOCS+4D+DkOQfuZf+vLrSEmY/7xtORwdxs4wtcC1wVgvk2MqFFTwQCFhvWsI4KPU9lcWXPI8DgRiz+xetQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0" } }, "node_modules/module-definition/node_modules/node-source-walk": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/node-source-walk/-/node-source-walk-4.3.0.tgz", - "integrity": "sha512-8Q1hXew6ETzqKRAs3jjLioSxNfT1cx74ooiF8RlAONwVMcfq+UdzLC2eB5qcPldUxaE5w3ytLkrmV1TGddhZTA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.0.0" }, @@ -19119,9 +15496,8 @@ }, "node_modules/module-lookup-amd": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/module-lookup-amd/-/module-lookup-amd-7.0.1.tgz", - "integrity": "sha512-w9mCNlj0S8qviuHzpakaLVc+/7q50jl9a/kmJ/n8bmXQZgDPkQHnPBb8MUOYh3WpAYkXuNc2c+khsozhIp/amQ==", "dev": true, + "license": "MIT", "dependencies": { "commander": "^2.8.1", "debug": "^4.1.0", @@ -19138,15 +15514,13 @@ }, "node_modules/module-lookup-amd/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/module-lookup-amd/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -19164,16 +15538,14 @@ }, "node_modules/moment": { "version": "2.30.1", - "resolved": "https://registry.npmjs.org/moment/-/moment-2.30.1.tgz", - "integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how==", + "license": "MIT", "engines": { "node": "*" } }, "node_modules/moment-timezone": { "version": "0.5.44", - "resolved": "https://registry.npmjs.org/moment-timezone/-/moment-timezone-0.5.44.tgz", - "integrity": "sha512-nv3YpzI/8lkQn0U6RkLd+f0W/zy/JnoR5/EyPz/dNkPTBjA2jNLCVxaiQ8QpeLymhSZvX0wCL5s27NQWdOPwAw==", + "license": "MIT", "dependencies": { "moment": "^2.29.4" }, @@ -19183,24 +15555,19 @@ }, "node_modules/ms": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + "license": "MIT" }, "node_modules/mute-stream": { "version": "0.0.8", - "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", - "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/nan": { "version": "2.19.0", - "resolved": "https://registry.npmjs.org/nan/-/nan-2.19.0.tgz", - "integrity": "sha512-nO1xXxfh/RWNxfd/XPfbIfFk5vgLsAxUR9y5O0cHMJu/AW9U95JLXqthYHjEp+8gQ5p96K9jUp8nbVOxCdRbtw==" + "license": "MIT" }, "node_modules/nanoid": { "version": "3.3.7", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", - "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", "dev": true, "funding": [ { @@ -19208,6 +15575,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "bin": { "nanoid": "bin/nanoid.cjs" }, @@ -19217,31 +15585,26 @@ }, "node_modules/natural-compare": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==" + "license": "MIT" }, "node_modules/natural-compare-lite": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz", - "integrity": "sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g==" + "license": "MIT" }, "node_modules/negotiator": { "version": "0.6.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", - "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/neo-async": { "version": "2.6.2", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", - "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==" + "license": "MIT" }, "node_modules/node-cache": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/node-cache/-/node-cache-5.1.2.tgz", - "integrity": "sha512-t1QzWwnk4sjLWaQAS8CHgOJ+RAfmHpxFWmc36IWTiWHQfs0w5JDMBS1b1ZxQteo0vVVuWJvIUKHDkkeK7vIGCg==", + "license": "MIT", "dependencies": { "clone": "2.x" }, @@ -19251,8 +15614,7 @@ }, "node_modules/node-fetch": { "version": "2.7.0", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", - "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "license": "MIT", "dependencies": { "whatwg-url": "^5.0.0" }, @@ -19270,8 +15632,7 @@ }, "node_modules/node-gyp-build": { "version": "3.9.0", - "resolved": "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-3.9.0.tgz", - "integrity": "sha512-zLcTg6P4AbcHPq465ZMFNXx7XpKKJh+7kkN699NiQWisR2uWYOWNWqRHAmbnmKiL4e9aLSlmy5U7rEMUXV59+A==", + "license": "MIT", "bin": { "node-gyp-build": "bin.js", "node-gyp-build-optional": "optional.js", @@ -19280,14 +15641,12 @@ }, "node_modules/node-int64": { "version": "0.4.0", - "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", - "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/node-mocks-http": { "version": "1.14.1", - "resolved": "https://registry.npmjs.org/node-mocks-http/-/node-mocks-http-1.14.1.tgz", - "integrity": "sha512-mfXuCGonz0A7uG1FEjnypjm34xegeN5+HI6xeGhYKecfgaZhjsmYoLE9LEFmT+53G1n8IuagPZmVnEL/xNsFaA==", + "license": "MIT", "dependencies": { "@types/express": "^4.17.21", "@types/node": "^20.10.6", @@ -19308,16 +15667,14 @@ }, "node_modules/node-mocks-http/node_modules/depd": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", - "integrity": "sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/node-mocks-http/node_modules/mime": { "version": "1.6.0", - "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", - "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", + "license": "MIT", "bin": { "mime": "cli.js" }, @@ -19327,9 +15684,8 @@ }, "node_modules/node-notifier": { "version": "10.0.1", - "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-10.0.1.tgz", - "integrity": "sha512-YX7TSyDukOZ0g+gmzjB6abKu+hTGvO8+8+gIFDsRCU2t8fLV/P2unmt+LGFaIa4y64aX98Qksa97rgz4vMNeLQ==", "dev": true, + "license": "MIT", "dependencies": { "growly": "^1.3.0", "is-wsl": "^2.2.0", @@ -19341,24 +15697,21 @@ }, "node_modules/node-notifier/node_modules/uuid": { "version": "8.3.2", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", - "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", "dev": true, + "license": "MIT", "bin": { "uuid": "dist/bin/uuid" } }, "node_modules/node-releases": { "version": "2.0.14", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.14.tgz", - "integrity": "sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/node-source-walk": { "version": "5.0.2", - "resolved": "https://registry.npmjs.org/node-source-walk/-/node-source-walk-5.0.2.tgz", - "integrity": "sha512-Y4jr/8SRS5hzEdZ7SGuvZGwfORvNsSsNRwDXx5WisiqzsVfeftDvRgfeqWNgZvWSJbgubTRVRYBzK6UO+ErqjA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.21.4" }, @@ -19368,8 +15721,7 @@ }, "node_modules/nopt": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-5.0.0.tgz", - "integrity": "sha512-Tbj67rffqceeLpcRXrT7vKAN8CwfPeIBgM7E6iBkmKLV7bEMwpGgYLGv0jACUsECaa/vuxP0IjEont6umdMgtQ==", + "license": "ISC", "dependencies": { "abbrev": "1" }, @@ -19382,8 +15734,7 @@ }, "node_modules/normalize-package-data": { "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", + "license": "BSD-2-Clause", "dependencies": { "hosted-git-info": "^2.1.4", "resolve": "^1.10.0", @@ -19393,26 +15744,23 @@ }, "node_modules/normalize-package-data/node_modules/semver": { "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", + "license": "ISC", "bin": { "semver": "bin/semver" } }, "node_modules/normalize-path": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/normalize-url": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-2.0.1.tgz", - "integrity": "sha512-D6MUW4K/VzoJ4rJ01JFKxDrtY1v9wrgzCX5f2qj/lzH1m/lW6MhUZFKerVsnyjOhOsYzI9Kqqak+10l4LvLpMw==", "dev": true, + "license": "MIT", "dependencies": { "prepend-http": "^2.0.0", "query-string": "^5.0.1", @@ -19424,9 +15772,8 @@ }, "node_modules/npm-run-path": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", - "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", "dev": true, + "license": "MIT", "dependencies": { "path-key": "^3.0.0" }, @@ -19436,8 +15783,7 @@ }, "node_modules/npmlog": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-5.0.1.tgz", - "integrity": "sha512-AqZtDUWOMKs1G/8lwylVjrdYgqA4d9nu8hc+0gzRxlDb1I10+FHBGMXs6aiQHFdCUUlqH99MUMuLfzWDNDtfxw==", + "license": "ISC", "dependencies": { "are-we-there-yet": "^2.0.0", "console-control-strings": "^1.1.0", @@ -19447,62 +15793,53 @@ }, "node_modules/number-is-nan": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/oauth-1.0a": { "version": "2.2.6", - "resolved": "https://registry.npmjs.org/oauth-1.0a/-/oauth-1.0a-2.2.6.tgz", - "integrity": "sha512-6bkxv3N4Gu5lty4viIcIAnq5GbxECviMBeKR3WX/q87SPQ8E8aursPZUtsXDnxCs787af09WPRBLqYrf/lwoYQ==" + "license": "MIT" }, "node_modules/object-assign": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/object-hash": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-3.0.0.tgz", - "integrity": "sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==", + "license": "MIT", "engines": { "node": ">= 6" } }, "node_modules/object-inspect": { "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/object-keys": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "license": "MIT", "engines": { "node": ">= 0.4" } }, "node_modules/object-sizeof": { "version": "2.6.4", - "resolved": "https://registry.npmjs.org/object-sizeof/-/object-sizeof-2.6.4.tgz", - "integrity": "sha512-YuJAf7Bi61KROcYmXm8RCeBrBw8UOaJDzTm1gp0eU7RjYi1xEte3/Nmg/VyPaHcJZ3sNojs1Y0xvSrgwkLmcFw==", + "license": "MIT", "dependencies": { "buffer": "^6.0.3" } }, "node_modules/object-sizeof/node_modules/buffer": { "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", "funding": [ { "type": "github", @@ -19517,6 +15854,7 @@ "url": "https://feross.org/support" } ], + "license": "MIT", "dependencies": { "base64-js": "^1.3.1", "ieee754": "^1.2.1" @@ -19524,8 +15862,7 @@ }, "node_modules/object.assign": { "version": "4.1.5", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.5.tgz", - "integrity": "sha512-byy+U7gp+FVwmyzKPYhW2h5l3crpmGsxl7X2s8y43IgxvG4g3QZ6CffDtsNQy1WsmZpQbO+ybo0AlW7TY6DcBQ==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.5", "define-properties": "^1.2.1", @@ -19541,8 +15878,7 @@ }, "node_modules/object.entries": { "version": "1.1.7", - "resolved": "https://registry.npmjs.org/object.entries/-/object.entries-1.1.7.tgz", - "integrity": "sha512-jCBs/0plmPsOnrKAfFQXRG2NFjlhZgjjcBLSmTnEhU8U6vVTsVe8ANeQJCHTl3gSsI4J+0emOoCgoKlmQPMgmA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -19554,8 +15890,7 @@ }, "node_modules/object.fromentries": { "version": "2.0.7", - "resolved": "https://registry.npmjs.org/object.fromentries/-/object.fromentries-2.0.7.tgz", - "integrity": "sha512-UPbPHML6sL8PI/mOqPwsH4G6iyXcCGzLin8KvEPenOZN5lpCNBZZQ+V62vdjB1mQHrmqGQt5/OJzemUA+KJmEA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -19570,8 +15905,7 @@ }, "node_modules/object.groupby": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/object.groupby/-/object.groupby-1.0.1.tgz", - "integrity": "sha512-HqaQtqLnp/8Bn4GL16cj+CUYbnpe1bh0TtEaWvybszDG4tgxCJuRpV8VGuvNaI1fAnI4lUJzDG55MXcOH4JZcQ==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -19581,8 +15915,7 @@ }, "node_modules/object.values": { "version": "1.1.7", - "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.1.7.tgz", - "integrity": "sha512-aU6xnDFYT3x17e/f0IiiwlGPTy2jzMySGfUB4fq6z7CV8l85CWHDk5ErhyhpfDHhrOMwGFhSQkhMGHaIotA6Ng==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -19597,8 +15930,7 @@ }, "node_modules/on-finished": { "version": "2.4.1", - "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", - "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", + "license": "MIT", "dependencies": { "ee-first": "1.1.1" }, @@ -19608,25 +15940,22 @@ }, "node_modules/once": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "license": "ISC", "dependencies": { "wrappy": "1" } }, "node_modules/one-time": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/one-time/-/one-time-1.0.0.tgz", - "integrity": "sha512-5DXOiRKwuSEcQ/l0kGCF6Q3jcADFv5tSmRaJck/OqkVFcOzutB134KRSfF0xDrL39MNnqxbHBbUUcjZIhTgb2g==", + "license": "MIT", "dependencies": { "fn.name": "1.x.x" } }, "node_modules/onetime": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", - "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", "dev": true, + "license": "MIT", "dependencies": { "mimic-fn": "^2.1.0" }, @@ -19638,21 +15967,17 @@ } }, "node_modules/only": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/only/-/only-0.0.2.tgz", - "integrity": "sha512-Fvw+Jemq5fjjyWz6CpKx6w9s7xxqo3+JCyM0WXWeCSOboZ8ABkyvP8ID4CZuChA/wxSx+XSJmdOm8rGVyJ1hdQ==" + "version": "0.0.2" }, "node_modules/openapi-types": { "version": "12.1.3", - "resolved": "https://registry.npmjs.org/openapi-types/-/openapi-types-12.1.3.tgz", - "integrity": "sha512-N4YtSYJqghVu4iek2ZUvcN/0aqH1kRDuNqzcycDxhOUpg7GdvLa2F3DgS6yBNhInhv2r/6I0Flkn7CqL8+nIcw==", "dev": true, + "license": "MIT", "peer": true }, "node_modules/optionator": { "version": "0.9.3", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.3.tgz", - "integrity": "sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==", + "license": "MIT", "dependencies": { "@aashutoshrathi/word-wrap": "^1.2.3", "deep-is": "^0.1.3", @@ -19667,9 +15992,8 @@ }, "node_modules/ora": { "version": "5.4.1", - "resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz", - "integrity": "sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==", "dev": true, + "license": "MIT", "dependencies": { "bl": "^4.1.0", "chalk": "^4.1.0", @@ -19690,9 +16014,8 @@ }, "node_modules/ora/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -19705,9 +16028,8 @@ }, "node_modules/ora/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -19721,9 +16043,8 @@ }, "node_modules/ora/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -19733,24 +16054,21 @@ }, "node_modules/ora/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/ora/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/ora/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -19760,44 +16078,39 @@ }, "node_modules/os-tmpdir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", - "integrity": "sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/p-cancelable": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-0.4.1.tgz", - "integrity": "sha512-HNa1A8LvB1kie7cERyy21VNeHb2CWJJYqyyC2o3klWFfMGlFmWv2Z7sFgZH8ZiaYL95ydToKTFVXgMV/Os0bBQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/p-finally": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", - "integrity": "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/p-is-promise": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/p-is-promise/-/p-is-promise-1.1.0.tgz", - "integrity": "sha512-zL7VE4JVS2IFSkR2GQKDSPEVxkoH43/p7oEnwpdCndKYJO0HVeRB7fA8TJwuLOTBREtK0ea8eHaxdwcpob5dmg==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/p-limit": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "license": "MIT", "dependencies": { "yocto-queue": "^0.1.0" }, @@ -19810,8 +16123,7 @@ }, "node_modules/p-locate": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "license": "MIT", "dependencies": { "p-limit": "^3.0.2" }, @@ -19824,9 +16136,8 @@ }, "node_modules/p-timeout": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-2.0.1.tgz", - "integrity": "sha512-88em58dDVB/KzPEx1X0N3LwFfYZPyDc4B6eF38M1rk9VTZMbxXXgjugz8mmwpS9Ox4BDZ+t6t3QP5+/gazweIA==", "dev": true, + "license": "MIT", "dependencies": { "p-finally": "^1.0.0" }, @@ -19836,17 +16147,15 @@ }, "node_modules/p-try": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/p-wait-for": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/p-wait-for/-/p-wait-for-3.2.0.tgz", - "integrity": "sha512-wpgERjNkLrBiFmkMEjuZJEWKKDrNfHCKA1OhyN1wg1FrLkULbviEy6py1AyJUgZ72YWFbZ38FIpnqvVqAlDUwA==", "dev": true, + "license": "MIT", "dependencies": { "p-timeout": "^3.0.0" }, @@ -19859,9 +16168,8 @@ }, "node_modules/p-wait-for/node_modules/p-timeout": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-3.2.0.tgz", - "integrity": "sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg==", "dev": true, + "license": "MIT", "dependencies": { "p-finally": "^1.0.0" }, @@ -19871,8 +16179,7 @@ }, "node_modules/parent-module": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", - "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", + "license": "MIT", "dependencies": { "callsites": "^3.0.0" }, @@ -19882,14 +16189,12 @@ }, "node_modules/parse-github-repo-url": { "version": "1.4.1", - "resolved": "https://registry.npmjs.org/parse-github-repo-url/-/parse-github-repo-url-1.4.1.tgz", - "integrity": "sha512-bSWyzBKqcSL4RrncTpGsEKoJ7H8a4L3++ifTAbTFeMHyq2wRV+42DGmQcHIrJIvdcacjIOxEuKH/w4tthF17gg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/parse-json": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", - "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", + "license": "MIT", "dependencies": { "@babel/code-frame": "^7.0.0", "error-ex": "^1.3.1", @@ -19905,69 +16210,60 @@ }, "node_modules/parse-ms": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-2.1.0.tgz", - "integrity": "sha512-kHt7kzLoS9VBZfUsiKjv43mr91ea+U05EyKkEtqp7vNbHxmaVuEqN7XxeEVnGrMtYOAxGrDElSi96K7EgO1zCA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/parse-passwd": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/parse-passwd/-/parse-passwd-1.0.0.tgz", - "integrity": "sha512-1Y1A//QUXEZK7YKz+rD9WydcE1+EuPr6ZBgKecAB8tmoW6UFv0NREVJe1p+jRxtThkcbbKkfwIbWJe/IeE6m2Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/parse-static-imports": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/parse-static-imports/-/parse-static-imports-1.1.0.tgz", - "integrity": "sha512-HlxrZcISCblEV0lzXmAHheH/8qEkKgmqkdxyHTPbSqsTUV8GzqmN1L+SSti+VbNPfbBO3bYLPHDiUs2avbAdbA==" + "license": "MIT" }, "node_modules/parseurl": { "version": "1.3.3", - "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", - "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/path-exists": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/path-is-absolute": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/path-key": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/path-parse": { "version": "1.0.7", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", - "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + "license": "MIT" }, "node_modules/path-scurry": { "version": "1.10.1", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.10.1.tgz", - "integrity": "sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ==", "dev": true, + "license": "BlueOak-1.0.0", "dependencies": { "lru-cache": "^9.1.1 || ^10.0.0", "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" @@ -19981,36 +16277,31 @@ }, "node_modules/path-scurry/node_modules/lru-cache": { "version": "10.1.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.1.0.tgz", - "integrity": "sha512-/1clY/ui8CzjKFyjdvwPWJUYKiFVXG2I2cY0ssG7h4+hwk+XOIX7ZSG9Q7TW8TW3Kp3BUSqgFWBLgL4PJ+Blag==", "dev": true, + "license": "ISC", "engines": { "node": "14 || >=16.14" } }, "node_modules/path-to-regexp": { "version": "6.2.1", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-6.2.1.tgz", - "integrity": "sha512-JLyh7xT1kizaEvcaXOQwOc2/Yhw6KZOvPf1S8401UyLk86CU79LN3vl7ztXGm/pZ+YjoyAJ4rxmHwbkBXJX+yw==" + "license": "MIT" }, "node_modules/path-type": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", - "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/picocolors": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", - "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "license": "MIT", "engines": { "node": ">=8.6" }, @@ -20020,9 +16311,8 @@ }, "node_modules/pidtree": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/pidtree/-/pidtree-0.6.0.tgz", - "integrity": "sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g==", "dev": true, + "license": "MIT", "bin": { "pidtree": "bin/pidtree.js" }, @@ -20032,27 +16322,24 @@ }, "node_modules/pify": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", - "integrity": "sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/pinkie": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz", - "integrity": "sha512-MnUuEycAemtSaeFSjXKW/aroV7akBbY+Sv+RkyqFjgAe73F+MR0TBWKBRDkmfWq/HiFmdavfZ1G7h4SPZXaCSg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/pinkie-promise": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz", - "integrity": "sha512-0Gni6D4UcLTbv9c57DfxDGdr41XfgUjqWZu492f0cIGr16zDU06BWP/RAEvOuo7CQ0CNjHaLlM59YJJFm3NWlw==", "dev": true, + "license": "MIT", "dependencies": { "pinkie": "^2.0.0" }, @@ -20062,18 +16349,16 @@ }, "node_modules/pirates": { "version": "4.0.6", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.6.tgz", - "integrity": "sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg==", "dev": true, + "license": "MIT", "engines": { "node": ">= 6" } }, "node_modules/pkg-dir": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", - "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^4.0.0" }, @@ -20083,9 +16368,8 @@ }, "node_modules/pkg-dir/node_modules/find-up": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" @@ -20096,9 +16380,8 @@ }, "node_modules/pkg-dir/node_modules/locate-path": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^4.1.0" }, @@ -20108,9 +16391,8 @@ }, "node_modules/pkg-dir/node_modules/p-limit": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^2.0.0" }, @@ -20123,9 +16405,8 @@ }, "node_modules/pkg-dir/node_modules/p-locate": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^2.2.0" }, @@ -20135,17 +16416,14 @@ }, "node_modules/pluralize": { "version": "8.0.0", - "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-8.0.0.tgz", - "integrity": "sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/postcss": { "version": "8.4.33", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.33.tgz", - "integrity": "sha512-Kkpbhhdjw2qQs2O2DGX+8m5OVqEcbB9HRBvuYM9pgrjEFUg30A9LmXNlTAUj4S9kgtGyrMbTzVjH7E+s5Re2yg==", "dev": true, "funding": [ { @@ -20161,6 +16439,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "dependencies": { "nanoid": "^3.3.7", "picocolors": "^1.0.0", @@ -20172,9 +16451,8 @@ }, "node_modules/postcss-values-parser": { "version": "6.0.2", - "resolved": "https://registry.npmjs.org/postcss-values-parser/-/postcss-values-parser-6.0.2.tgz", - "integrity": "sha512-YLJpK0N1brcNJrs9WatuJFtHaV9q5aAOj+S4DI5S7jgHlRfm0PIbDCAFRYMQD5SHq7Fy6xsDhyutgS0QOAs0qw==", "dev": true, + "license": "MPL-2.0", "dependencies": { "color-name": "^1.1.4", "is-url-superb": "^4.0.0", @@ -20189,15 +16467,13 @@ }, "node_modules/postcss-values-parser/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/pprof": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/pprof/-/pprof-4.0.0.tgz", - "integrity": "sha512-Yhfk7Y0G1MYsy97oXxmSG5nvbM1sCz9EALiNhW/isAv5Xf7svzP+1RfGeBlS6mLSgRJvgSLh6Mi5DaisQuPttw==", "hasInstallScript": true, + "license": "Apache-2.0", "dependencies": { "@mapbox/node-pre-gyp": "^1.0.9", "bindings": "^1.2.1", @@ -20215,13 +16491,11 @@ }, "node_modules/pprof-format": { "version": "2.0.7", - "resolved": "https://registry.npmjs.org/pprof-format/-/pprof-format-2.0.7.tgz", - "integrity": "sha512-1qWaGAzwMpaXJP9opRa23nPnt2Egi7RMNoNBptEE/XwHbcn4fC2b/4U4bKc5arkGkIh2ZabpF2bEb+c5GNHEKA==" + "license": "MIT" }, "node_modules/pprof/node_modules/source-map": { "version": "0.8.0-beta.0", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.8.0-beta.0.tgz", - "integrity": "sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA==", + "license": "BSD-3-Clause", "dependencies": { "whatwg-url": "^7.0.0" }, @@ -20231,21 +16505,18 @@ }, "node_modules/pprof/node_modules/tr46": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz", - "integrity": "sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==", + "license": "MIT", "dependencies": { "punycode": "^2.1.0" } }, "node_modules/pprof/node_modules/webidl-conversions": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz", - "integrity": "sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==" + "license": "BSD-2-Clause" }, "node_modules/pprof/node_modules/whatwg-url": { "version": "7.1.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-7.1.0.tgz", - "integrity": "sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==", + "license": "MIT", "dependencies": { "lodash.sortby": "^4.7.0", "tr46": "^1.0.1", @@ -20254,9 +16525,8 @@ }, "node_modules/precinct": { "version": "8.3.1", - "resolved": "https://registry.npmjs.org/precinct/-/precinct-8.3.1.tgz", - "integrity": "sha512-pVppfMWLp2wF68rwHqBIpPBYY8Kd12lDhk8LVQzOwqllifVR15qNFyod43YLyFpurKRZQKnE7E4pofAagDOm2Q==", "dev": true, + "license": "MIT", "dependencies": { "commander": "^2.20.3", "debug": "^4.3.3", @@ -20281,9 +16551,8 @@ }, "node_modules/precinct/node_modules/@typescript-eslint/types": { "version": "4.33.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.33.0.tgz", - "integrity": "sha512-zKp7CjQzLQImXEpLt2BUw1tvOMPfNoTAfb8l51evhYbOEEzdWyQNmHWWGPR6hwKJDAi+1VXSBmnhL9kyVTTOuQ==", "dev": true, + "license": "MIT", "engines": { "node": "^8.10.0 || ^10.13.0 || >=11.10.1" }, @@ -20294,9 +16563,8 @@ }, "node_modules/precinct/node_modules/@typescript-eslint/typescript-estree": { "version": "4.33.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.33.0.tgz", - "integrity": "sha512-rkWRY1MPFzjwnEVHsxGemDzqqddw2QbTJlICPD9p9I9LfsO8fdmfQPOX3uKfUaGRDFJbfrtm/sXhVXN4E+bzCA==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "@typescript-eslint/types": "4.33.0", "@typescript-eslint/visitor-keys": "4.33.0", @@ -20321,9 +16589,8 @@ }, "node_modules/precinct/node_modules/@typescript-eslint/visitor-keys": { "version": "4.33.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.33.0.tgz", - "integrity": "sha512-uqi/2aSz9g2ftcHWf8uLPJA70rUv6yuMW5Bohw+bwcuzaxQIHaKFZCKGoGXIrc9vkTJ3+0txM73K0Hq3d5wgIg==", "dev": true, + "license": "MIT", "dependencies": { "@typescript-eslint/types": "4.33.0", "eslint-visitor-keys": "^2.0.0" @@ -20338,24 +16605,21 @@ }, "node_modules/precinct/node_modules/ast-module-types": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ast-module-types/-/ast-module-types-3.0.0.tgz", - "integrity": "sha512-CMxMCOCS+4D+DkOQfuZf+vLrSEmY/7xtORwdxs4wtcC1wVgvk2MqFFTwQCFhvWsI4KPU9lcWXPI8DgRiz+xetQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0" } }, "node_modules/precinct/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/precinct/node_modules/detective-amd": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/detective-amd/-/detective-amd-3.1.2.tgz", - "integrity": "sha512-jffU26dyqJ37JHR/o44La6CxtrDf3Rt9tvd2IbImJYxWKTMdBjctp37qoZ6ZcY80RHg+kzWz4bXn39e4P7cctQ==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^3.0.0", "escodegen": "^2.0.0", @@ -20371,9 +16635,8 @@ }, "node_modules/precinct/node_modules/detective-cjs": { "version": "3.1.3", - "resolved": "https://registry.npmjs.org/detective-cjs/-/detective-cjs-3.1.3.tgz", - "integrity": "sha512-ljs7P0Yj9MK64B7G0eNl0ThWSYjhAaSYy+fQcpzaKalYl/UoQBOzOeLCSFEY1qEBhziZ3w7l46KG/nH+s+L7BQ==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^3.0.0", "node-source-walk": "^4.0.0" @@ -20384,9 +16647,8 @@ }, "node_modules/precinct/node_modules/detective-es6": { "version": "2.2.2", - "resolved": "https://registry.npmjs.org/detective-es6/-/detective-es6-2.2.2.tgz", - "integrity": "sha512-eZUKCUsbHm8xoeoCM0z6JFwvDfJ5Ww5HANo+jPR7AzkFpW9Mun3t/TqIF2jjeWa2TFbAiGaWESykf2OQp3oeMw==", "dev": true, + "license": "MIT", "dependencies": { "node-source-walk": "^4.0.0" }, @@ -20396,9 +16658,8 @@ }, "node_modules/precinct/node_modules/detective-postcss": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/detective-postcss/-/detective-postcss-4.0.0.tgz", - "integrity": "sha512-Fwc/g9VcrowODIAeKRWZfVA/EufxYL7XfuqJQFroBKGikKX83d2G7NFw6kDlSYGG3LNQIyVa+eWv1mqre+v4+A==", "dev": true, + "license": "Apache-2.0", "dependencies": { "debug": "^4.1.1", "is-url": "^1.2.4", @@ -20411,9 +16672,8 @@ }, "node_modules/precinct/node_modules/detective-sass": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/detective-sass/-/detective-sass-3.0.2.tgz", - "integrity": "sha512-DNVYbaSlmti/eztFGSfBw4nZvwsTaVXEQ4NsT/uFckxhJrNRFUh24d76KzoCC3aarvpZP9m8sC2L1XbLej4F7g==", "dev": true, + "license": "MIT", "dependencies": { "gonzales-pe": "^4.3.0", "node-source-walk": "^4.0.0" @@ -20424,9 +16684,8 @@ }, "node_modules/precinct/node_modules/detective-scss": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/detective-scss/-/detective-scss-2.0.2.tgz", - "integrity": "sha512-hDWnWh/l0tht/7JQltumpVea/inmkBaanJUcXRB9kEEXVwVUMuZd6z7eusQ6GcBFrfifu3pX/XPyD7StjbAiBg==", "dev": true, + "license": "MIT", "dependencies": { "gonzales-pe": "^4.3.0", "node-source-walk": "^4.0.0" @@ -20437,15 +16696,13 @@ }, "node_modules/precinct/node_modules/detective-stylus": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detective-stylus/-/detective-stylus-1.0.3.tgz", - "integrity": "sha512-4/bfIU5kqjwugymoxLXXLltzQNeQfxGoLm2eIaqtnkWxqbhap9puDVpJPVDx96hnptdERzS5Cy6p9N8/08A69Q==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/precinct/node_modules/detective-typescript": { "version": "7.0.2", - "resolved": "https://registry.npmjs.org/detective-typescript/-/detective-typescript-7.0.2.tgz", - "integrity": "sha512-unqovnhxzvkCz3m1/W4QW4qGsvXCU06aU2BAm8tkza+xLnp9SOFnob2QsTxUv5PdnQKfDvWcv9YeOeFckWejwA==", "dev": true, + "license": "MIT", "dependencies": { "@typescript-eslint/typescript-estree": "^4.33.0", "ast-module-types": "^2.7.1", @@ -20458,24 +16715,21 @@ }, "node_modules/precinct/node_modules/detective-typescript/node_modules/ast-module-types": { "version": "2.7.1", - "resolved": "https://registry.npmjs.org/ast-module-types/-/ast-module-types-2.7.1.tgz", - "integrity": "sha512-Rnnx/4Dus6fn7fTqdeLEAn5vUll5w7/vts0RN608yFa6si/rDOUonlIIiwugHBFWjylHjxm9owoSZn71KwG4gw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/precinct/node_modules/eslint-visitor-keys": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz", - "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==", "dev": true, + "license": "Apache-2.0", "engines": { "node": ">=10" } }, "node_modules/precinct/node_modules/get-amd-module-type": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/get-amd-module-type/-/get-amd-module-type-3.0.2.tgz", - "integrity": "sha512-PcuKwB8ouJnKuAPn6Hk3UtdfKoUV3zXRqVEvj8XGIXqjWfgd1j7QGdXy5Z9OdQfzVt1Sk29HVe/P+X74ccOuqw==", "dev": true, + "license": "MIT", "dependencies": { "ast-module-types": "^3.0.0", "node-source-walk": "^4.2.2" @@ -20486,9 +16740,8 @@ }, "node_modules/precinct/node_modules/node-source-walk": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/node-source-walk/-/node-source-walk-4.3.0.tgz", - "integrity": "sha512-8Q1hXew6ETzqKRAs3jjLioSxNfT1cx74ooiF8RlAONwVMcfq+UdzLC2eB5qcPldUxaE5w3ytLkrmV1TGddhZTA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.0.0" }, @@ -20498,9 +16751,8 @@ }, "node_modules/precinct/node_modules/postcss-values-parser": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/postcss-values-parser/-/postcss-values-parser-2.0.1.tgz", - "integrity": "sha512-2tLuBsA6P4rYTNKCXYG/71C7j1pU6pK503suYOmn4xYrQIzW+opD+7FAFNuGSdZC/3Qfy334QbeMu7MEb8gOxg==", "dev": true, + "license": "MIT", "dependencies": { "flatten": "^1.0.2", "indexes-of": "^1.0.1", @@ -20512,9 +16764,8 @@ }, "node_modules/precinct/node_modules/typescript": { "version": "3.9.10", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", - "integrity": "sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==", "dev": true, + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -20525,26 +16776,23 @@ }, "node_modules/prelude-ls": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", + "license": "MIT", "engines": { "node": ">= 0.8.0" } }, "node_modules/prepend-http": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/prepend-http/-/prepend-http-2.0.0.tgz", - "integrity": "sha512-ravE6m9Atw9Z/jjttRUZ+clIXogdghyZAuWJ3qEzjT+jI/dL1ifAqhZeC5VHzQp1MSt1+jxKkFNemj/iO7tVUA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/prettier": { "version": "3.2.4", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.2.4.tgz", - "integrity": "sha512-FWu1oLHKCrtpO1ypU6J0SbK2d9Ckwysq6bHj/uaCP26DxrPpppCLQRGVuqAxSTvhF00AcvDRyYrLNW7ocBhFFQ==", "dev": true, + "license": "MIT", "bin": { "prettier": "bin/prettier.cjs" }, @@ -20557,9 +16805,8 @@ }, "node_modules/prettier-linter-helpers": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/prettier-linter-helpers/-/prettier-linter-helpers-1.0.0.tgz", - "integrity": "sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w==", "dev": true, + "license": "MIT", "dependencies": { "fast-diff": "^1.1.2" }, @@ -20569,9 +16816,8 @@ }, "node_modules/pretty-bytes": { "version": "5.6.0", - "resolved": "https://registry.npmjs.org/pretty-bytes/-/pretty-bytes-5.6.0.tgz", - "integrity": "sha512-FFw039TmrBqFK8ma/7OL3sDz/VytdtJr044/QUJtH0wK9lb9jLq9tJyIxUwtQJHwar2BqtiA4iCWSwo9JLkzFg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" }, @@ -20581,9 +16827,8 @@ }, "node_modules/pretty-format": { "version": "29.7.0", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", - "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", "dev": true, + "license": "MIT", "dependencies": { "@jest/schemas": "^29.6.3", "ansi-styles": "^5.0.0", @@ -20595,9 +16840,8 @@ }, "node_modules/pretty-format/node_modules/ansi-styles": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", - "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -20607,9 +16851,8 @@ }, "node_modules/pretty-ms": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-7.0.1.tgz", - "integrity": "sha512-973driJZvxiGOQ5ONsFhOF/DtzPMOMtgC11kCpUrPGMTgqp2q/1gwzCquocrN33is0VZ5GFHXZYMM9l6h67v2Q==", "dev": true, + "license": "MIT", "dependencies": { "parse-ms": "^2.1.0" }, @@ -20622,22 +16865,19 @@ }, "node_modules/process-nextick-args": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/progress": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", - "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", + "license": "MIT", "engines": { "node": ">=0.4.0" } }, "node_modules/prom-client": { "version": "14.2.0", - "resolved": "https://registry.npmjs.org/prom-client/-/prom-client-14.2.0.tgz", - "integrity": "sha512-sF308EhTenb/pDRPakm+WgiN+VdM/T1RaHj1x+MvAuT8UiQP8JmOEbxVqtkbfR4LrvOg5n7ic01kRBDGXjYikA==", + "license": "Apache-2.0", "dependencies": { "tdigest": "^0.1.1" }, @@ -20647,9 +16887,8 @@ }, "node_modules/prompts": { "version": "2.4.2", - "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", - "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", "dev": true, + "license": "MIT", "dependencies": { "kleur": "^3.0.3", "sisteransi": "^1.0.5" @@ -20660,9 +16899,8 @@ }, "node_modules/protobufjs": { "version": "7.2.6", - "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.2.6.tgz", - "integrity": "sha512-dgJaEDDL6x8ASUZ1YqWciTRrdOuYNzoOf27oHNfdyvKqHr5i0FV7FSLU+aIeFjyFgVxrpTOtQUi0BLLBymZaBw==", "hasInstallScript": true, + "license": "BSD-3-Clause", "dependencies": { "@protobufjs/aspromise": "^1.1.2", "@protobufjs/base64": "^1.1.2", @@ -20683,13 +16921,11 @@ }, "node_modules/proxy-from-env": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz", - "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==" + "license": "MIT" }, "node_modules/pump": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "license": "MIT", "dependencies": { "end-of-stream": "^1.1.0", "once": "^1.3.1" @@ -20697,16 +16933,13 @@ }, "node_modules/punycode": { "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", - "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/pure-rand": { "version": "6.0.4", - "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-6.0.4.tgz", - "integrity": "sha512-LA0Y9kxMYv47GIPJy6MI84fqTd2HmYZI83W/kM/SkKfDlajnZYfmXFTxkbY+xSBPkLJxltMa9hIkmdc29eguMA==", "dev": true, "funding": [ { @@ -20717,13 +16950,13 @@ "type": "opencollective", "url": "https://opencollective.com/fast-check" } - ] + ], + "license": "MIT" }, "node_modules/q": { "version": "1.5.1", - "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", - "integrity": "sha512-kV/CThkXo6xyFEZUugw/+pIOywXcDbFYgSct5cT3gqlbkBE1SJdwy6UQoZvodiWF/ckQLZyDE/Bu1M6gVu5lVw==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.6.0", "teleport": ">=0.2.0" @@ -20731,8 +16964,7 @@ }, "node_modules/qs": { "version": "6.11.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.2.tgz", - "integrity": "sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA==", + "license": "BSD-3-Clause", "dependencies": { "side-channel": "^1.0.4" }, @@ -20745,9 +16977,8 @@ }, "node_modules/query-string": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/query-string/-/query-string-5.1.1.tgz", - "integrity": "sha512-gjWOsm2SoGlgLEdAGt7a6slVOk9mGiXmPFMqrEhLQ68rhQuBnpfs3+EmlvqKyxnCo9/PPlF+9MtY02S1aFg+Jw==", "dev": true, + "license": "MIT", "dependencies": { "decode-uri-component": "^0.2.0", "object-assign": "^4.1.0", @@ -20759,8 +16990,6 @@ }, "node_modules/queue-microtask": { "version": "1.2.3", - "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", - "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", "funding": [ { "type": "github", @@ -20774,41 +17003,37 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "license": "MIT" }, "node_modules/quick-lru": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-4.0.1.tgz", - "integrity": "sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/quote-unquote": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/quote-unquote/-/quote-unquote-1.0.0.tgz", - "integrity": "sha512-twwRO/ilhlG/FIgYeKGFqyHhoEhqgnKVkcmqMKi2r524gz3ZbDTcyFt38E9xjJI2vT+KbRNHVbnJ/e0I25Azwg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/ramda": { "version": "0.27.1", - "resolved": "https://registry.npmjs.org/ramda/-/ramda-0.27.1.tgz", - "integrity": "sha512-PgIdVpn5y5Yns8vqb8FzBUEYn98V3xcPgawAkkgj0YJ0qDsnHCiNmZYfOGMgOvoB0eWFLpYbhxUR3mxfDIMvpw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/range-parser": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", - "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/raw-body": { "version": "2.5.2", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", - "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", + "license": "MIT", "dependencies": { "bytes": "3.1.2", "http-errors": "2.0.0", @@ -20821,9 +17046,8 @@ }, "node_modules/rc": { "version": "1.2.8", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", - "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", "dev": true, + "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", "dependencies": { "deep-extend": "^0.6.0", "ini": "~1.3.0", @@ -20836,24 +17060,21 @@ }, "node_modules/rc/node_modules/strip-json-comments": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", - "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/react-is": { "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/read-pkg": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz", - "integrity": "sha512-BLq/cCO9two+lBgiTYNqD6GdtK8s4NpaWrl6/rCO9w0TUS8oJl7cmToOZfRYllKTISY6nt1U7jQ53brmKqY6BA==", "dev": true, + "license": "MIT", "dependencies": { "load-json-file": "^4.0.0", "normalize-package-data": "^2.3.2", @@ -20865,9 +17086,8 @@ }, "node_modules/read-pkg-up": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-3.0.0.tgz", - "integrity": "sha512-YFzFrVvpC6frF1sz8psoHDBGF7fLPc+llq/8NB43oagqWkx8ar5zYtsTORtOjw9W2RHLpWP+zTWwBvf1bCmcSw==", "dev": true, + "license": "MIT", "dependencies": { "find-up": "^2.0.0", "read-pkg": "^3.0.0" @@ -20878,9 +17098,8 @@ }, "node_modules/read-pkg-up/node_modules/find-up": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", - "integrity": "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^2.0.0" }, @@ -20890,9 +17109,8 @@ }, "node_modules/read-pkg-up/node_modules/locate-path": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", - "integrity": "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^2.0.0", "path-exists": "^3.0.0" @@ -20903,9 +17121,8 @@ }, "node_modules/read-pkg-up/node_modules/p-limit": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz", - "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==", "dev": true, + "license": "MIT", "dependencies": { "p-try": "^1.0.0" }, @@ -20915,9 +17132,8 @@ }, "node_modules/read-pkg-up/node_modules/p-locate": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", - "integrity": "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^1.1.0" }, @@ -20927,27 +17143,24 @@ }, "node_modules/read-pkg-up/node_modules/p-try": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz", - "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/read-pkg-up/node_modules/path-exists": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/read-pkg/node_modules/path-type": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz", - "integrity": "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==", "dev": true, + "license": "MIT", "dependencies": { "pify": "^3.0.0" }, @@ -20957,18 +17170,16 @@ }, "node_modules/read-pkg/node_modules/pify": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/readable-stream": { "version": "2.3.8", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", - "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", "dev": true, + "license": "MIT", "dependencies": { "core-util-is": "~1.0.0", "inherits": "~2.0.3", @@ -20981,15 +17192,13 @@ }, "node_modules/readable-stream/node_modules/safe-buffer": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/redent": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-3.0.0.tgz", - "integrity": "sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg==", "dev": true, + "license": "MIT", "dependencies": { "indent-string": "^4.0.0", "strip-indent": "^3.0.0" @@ -21000,16 +17209,14 @@ }, "node_modules/redis-errors": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/redis-errors/-/redis-errors-1.2.0.tgz", - "integrity": "sha512-1qny3OExCf0UvUV/5wpYKf2YwPcOqXzkwKKSmKHiE6ZMQs5heeE/c8eXK+PNllPvmjgAbfnsbpkGZWy8cBpn9w==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/redis-parser": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/redis-parser/-/redis-parser-3.0.0.tgz", - "integrity": "sha512-DJnGAeenTdpMEH6uAJRK/uiyEIH9WVsUmoLwzudwGJUwZPp80PDBWPHXSAGNPwNvIXAbe7MSUB1zQFugFml66A==", + "license": "MIT", "dependencies": { "redis-errors": "^1.0.0" }, @@ -21019,22 +17226,19 @@ }, "node_modules/regenerator-runtime": { "version": "0.13.11", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz", - "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==" + "license": "MIT" }, "node_modules/regexp-tree": { "version": "0.1.27", - "resolved": "https://registry.npmjs.org/regexp-tree/-/regexp-tree-0.1.27.tgz", - "integrity": "sha512-iETxpjK6YoRWJG5o6hXLwvjYAoW+FEZn9os0PD/b6AP6xQwsa/Y7lCVgIixBbUPMfhu+i2LtdeAqVTgGlQarfA==", "dev": true, + "license": "MIT", "bin": { "regexp-tree": "bin/regexp-tree" } }, "node_modules/regexp.prototype.flags": { "version": "1.5.1", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", - "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -21049,9 +17253,8 @@ }, "node_modules/regjsparser": { "version": "0.9.1", - "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.9.1.tgz", - "integrity": "sha512-dQUtn90WanSNl+7mQKcXAgZxvUe7Z0SqXlgzv0za4LwiUhyzBC58yQO3liFoUgu8GiJVInAhJjkj1N0EtQ5nkQ==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "jsesc": "~0.5.0" }, @@ -21061,8 +17264,6 @@ }, "node_modules/regjsparser/node_modules/jsesc": { "version": "0.5.0", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", - "integrity": "sha512-uZz5UnB7u4T9LvwmFqXii7pZSouaRPorGs5who1Ip7VO0wxanFvBL7GkM6dTHlgX+jhBApRetaWpnDabOeTcnA==", "dev": true, "bin": { "jsesc": "bin/jsesc" @@ -21070,9 +17271,8 @@ }, "node_modules/repeating": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz", - "integrity": "sha512-ZqtSMuVybkISo2OWvqvm7iHSWngvdaW3IpsT9/uP8v4gMi591LY6h35wdOfvQdWCKFWZWm2Y1Opp4kV7vQKT6A==", "dev": true, + "license": "MIT", "dependencies": { "is-finite": "^1.0.0" }, @@ -21082,32 +17282,28 @@ }, "node_modules/require-directory": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/require-from-string": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/require-main-filename": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/requirejs": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/requirejs/-/requirejs-2.3.6.tgz", - "integrity": "sha512-ipEzlWQe6RK3jkzikgCupiTbTvm4S0/CAU5GlgptkN5SO6F3u0UD0K18wy6ErDqiCyP4J4YYe1HuAShvsxePLg==", + "version": "2.3.7", "dev": true, + "license": "MIT", "bin": { "r_js": "bin/r.js", "r.js": "bin/r.js" @@ -21118,9 +17314,8 @@ }, "node_modules/requirejs-config-file": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/requirejs-config-file/-/requirejs-config-file-4.0.0.tgz", - "integrity": "sha512-jnIre8cbWOyvr8a5F2KuqBnY+SDA4NXr/hzEZJG79Mxm2WiFQz2dzhC8ibtPJS7zkmBEl1mxSwp5HhC1W4qpxw==", "dev": true, + "license": "MIT", "dependencies": { "esprima": "^4.0.0", "stringify-object": "^3.2.1" @@ -21131,8 +17326,7 @@ }, "node_modules/resolve": { "version": "1.22.8", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", - "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", + "license": "MIT", "dependencies": { "is-core-module": "^2.13.0", "path-parse": "^1.0.7", @@ -21147,9 +17341,8 @@ }, "node_modules/resolve-cwd": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", - "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", "dev": true, + "license": "MIT", "dependencies": { "resolve-from": "^5.0.0" }, @@ -21159,18 +17352,16 @@ }, "node_modules/resolve-dependency-path": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/resolve-dependency-path/-/resolve-dependency-path-2.0.0.tgz", - "integrity": "sha512-DIgu+0Dv+6v2XwRaNWnumKu7GPufBBOr5I1gRPJHkvghrfCGOooJODFvgFimX/KRxk9j0whD2MnKHzM1jYvk9w==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, "node_modules/resolve-dir": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/resolve-dir/-/resolve-dir-1.0.1.tgz", - "integrity": "sha512-R7uiTjECzvOsWSfdM0QKFNBVFcK27aHOUwdvK53BcW8zqnGdYp0Fbj82cy54+2A4P2tFM22J5kRfe1R+lM/1yg==", "dev": true, + "license": "MIT", "dependencies": { "expand-tilde": "^2.0.0", "global-modules": "^1.0.0" @@ -21181,18 +17372,16 @@ }, "node_modules/resolve-from": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/resolve-global": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/resolve-global/-/resolve-global-1.0.0.tgz", - "integrity": "sha512-zFa12V4OLtT5XUX/Q4VLvTfBf+Ok0SPc1FNGM/z9ctUdiU618qwKpWnd0CHs3+RqROfyEg/DhuHbMWYqcgljEw==", "dev": true, + "license": "MIT", "dependencies": { "global-dirs": "^0.1.1" }, @@ -21202,27 +17391,24 @@ }, "node_modules/resolve.exports": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/resolve.exports/-/resolve.exports-2.0.2.tgz", - "integrity": "sha512-X2UW6Nw3n/aMgDVy+0rSqgHlv39WZAlZrXCdnbyEiKm17DSqHX4MmQMaST3FbeWR5FTuRcUwYAziZajji0Y7mg==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" } }, "node_modules/responselike": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/responselike/-/responselike-1.0.2.tgz", - "integrity": "sha512-/Fpe5guzJk1gPqdJLJR5u7eG/gNY4nImjbRDaVWVMRhne55TCmj2i9Q+54PBRfatRC8v/rIiv9BN0pMd9OV5EQ==", "dev": true, + "license": "MIT", "dependencies": { "lowercase-keys": "^1.0.0" } }, "node_modules/restore-cursor": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", - "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", "dev": true, + "license": "MIT", "dependencies": { "onetime": "^5.1.0", "signal-exit": "^3.0.2" @@ -21233,8 +17419,7 @@ }, "node_modules/reusify": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", - "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "license": "MIT", "engines": { "iojs": ">=1.0.0", "node": ">=0.10.0" @@ -21242,23 +17427,20 @@ }, "node_modules/rfdc": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/rfdc/-/rfdc-1.3.0.tgz", - "integrity": "sha512-V2hovdzFbOi77/WajaSMXk2OLm+xNIeQdMMuB7icj7bk6zi2F8GGAxigcnDFpJHbNyNcgyJDiP+8nOrY5cZGrA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/right-pad": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/right-pad/-/right-pad-1.0.1.tgz", - "integrity": "sha512-bYBjgxmkvTAfgIYy328fmkwhp39v8lwVgWhhrzxPV3yHtcSqyYKe9/XOhvW48UFjATg3VuJbpsp5822ACNvkmw==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.10" } }, "node_modules/rimraf": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", - "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", + "license": "ISC", "dependencies": { "glob": "^7.1.3" }, @@ -21271,8 +17453,7 @@ }, "node_modules/rimraf/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -21290,9 +17471,8 @@ }, "node_modules/roarr": { "version": "7.21.0", - "resolved": "https://registry.npmjs.org/roarr/-/roarr-7.21.0.tgz", - "integrity": "sha512-d1rPLcHmQID3GsA3p9d5vKSZYlvrTWhjbmeg9DT5DcPoLpH85VzPmkLkGKhQv376+dfkApaHwNbpYEwDB77Ibg==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "fast-printf": "^1.6.9", "safe-stable-stringify": "^2.4.3", @@ -21304,8 +17484,7 @@ }, "node_modules/rs-jsonpath": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/rs-jsonpath/-/rs-jsonpath-1.1.2.tgz", - "integrity": "sha512-IQzlqtVyZniK7aOtpKGrv7BvkamSvLJkIhRGoKKDQLppNJe94BVHqpxNRjw/2042nGjtC3vyfCWyHe+3DlWgWA==", + "license": "MIT", "dependencies": { "esprima": "1.2.2", "static-eval": "2.0.2", @@ -21314,8 +17493,6 @@ }, "node_modules/rs-jsonpath/node_modules/esprima": { "version": "1.2.2", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-1.2.2.tgz", - "integrity": "sha512-+JpPZam9w5DuJ3Q67SqsMGtiHKENSMRVoxvArfJZK01/BfLEObtZ6orJa/MtoGNR/rfMgp5837T41PAmTwAv/A==", "bin": { "esparse": "bin/esparse.js", "esvalidate": "bin/esvalidate.js" @@ -21324,36 +17501,16 @@ "node": ">=0.4.0" } }, - "node_modules/rudder-transformer-cdk": { - "version": "1.4.11", - "resolved": "https://registry.npmjs.org/rudder-transformer-cdk/-/rudder-transformer-cdk-1.4.11.tgz", - "integrity": "sha512-u2t/L47tNe9wyzSpQptLkiECT0/P5Xx8BLmZisfuXQx3lXco57oaDX/Ii1ZhEiHM2zht+NiyrGkvhBKMt1IAyA==", - "dependencies": { - "get-value": "^3.0.1", - "handlebars": "^4.7.7", - "joi": "^17.9.2", - "js-yaml": "^4.1.0", - "lodash": "^4.17.21", - "moment-timezone": "^0.5.43", - "set-value": "^4.1.0", - "sha256": "^0.2.0", - "unset-value": "^2.0.1", - "winston": "^3.8.1" - } - }, "node_modules/run-async": { "version": "2.4.1", - "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.4.1.tgz", - "integrity": "sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.12.0" } }, "node_modules/run-parallel": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", - "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", "funding": [ { "type": "github", @@ -21368,23 +17525,22 @@ "url": "https://feross.org/support" } ], + "license": "MIT", "dependencies": { "queue-microtask": "^1.2.2" } }, "node_modules/rxjs": { "version": "7.8.1", - "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.1.tgz", - "integrity": "sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==", "dev": true, + "license": "Apache-2.0", "dependencies": { "tslib": "^2.1.0" } }, "node_modules/safe-array-concat": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", - "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "get-intrinsic": "^1.2.1", @@ -21400,13 +17556,10 @@ }, "node_modules/safe-array-concat/node_modules/isarray": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + "license": "MIT" }, "node_modules/safe-buffer": { "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", "funding": [ { "type": "github", @@ -21420,21 +17573,20 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "license": "MIT" }, "node_modules/safe-regex": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-2.1.1.tgz", - "integrity": "sha512-rx+x8AMzKb5Q5lQ95Zoi6ZbJqwCLkqi3XuJXp5P3rT8OEc6sZCJG5AE5dU3lsgRr/F4Bs31jSlVN+j5KrsGu9A==", "dev": true, + "license": "MIT", "dependencies": { "regexp-tree": "~0.1.1" } }, "node_modules/safe-regex-test": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", - "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "get-intrinsic": "^1.1.3", @@ -21446,22 +17598,19 @@ }, "node_modules/safe-stable-stringify": { "version": "2.4.3", - "resolved": "https://registry.npmjs.org/safe-stable-stringify/-/safe-stable-stringify-2.4.3.tgz", - "integrity": "sha512-e2bDA2WJT0wxseVd4lsDP4+3ONX6HpMXQa1ZhFQ7SU+GjvORCmShbCMltrtIDfkYhVHrOcPtj+KhmDBdPdZD1g==", + "license": "MIT", "engines": { "node": ">=10" } }, "node_modules/safer-buffer": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + "license": "MIT" }, "node_modules/sass-lookup": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/sass-lookup/-/sass-lookup-3.0.0.tgz", - "integrity": "sha512-TTsus8CfFRn1N44bvdEai1no6PqdmDiQUiqW5DlpmtT+tYnIt1tXtDIph5KA1efC+LmioJXSnCtUVpcK9gaKIg==", "dev": true, + "license": "MIT", "dependencies": { "commander": "^2.16.0" }, @@ -21474,14 +17623,12 @@ }, "node_modules/sass-lookup/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/semver": { "version": "7.5.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "license": "ISC", "dependencies": { "lru-cache": "^6.0.0" }, @@ -21494,15 +17641,13 @@ }, "node_modules/semver-compare": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/semver-compare/-/semver-compare-1.0.0.tgz", - "integrity": "sha512-YM3/ITh2MJ5MtzaM429anh+x2jiLVjqILF4m4oyQB18W7Ggea7BfqdH/wGMK7dDiMghv/6WG7znWMwUDzJiXow==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/semver-regex": { "version": "3.1.4", - "resolved": "https://registry.npmjs.org/semver-regex/-/semver-regex-3.1.4.tgz", - "integrity": "sha512-6IiqeZNgq01qGf0TId0t3NvKzSvUsjcpdEO3AQNeIjR6A2+ckTnQlDpl4qu1bjRv0RzN3FP9hzFmws3lKqRWkA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" }, @@ -21512,8 +17657,7 @@ }, "node_modules/semver/node_modules/lru-cache": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "license": "ISC", "dependencies": { "yallist": "^4.0.0" }, @@ -21523,18 +17667,15 @@ }, "node_modules/semver/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + "license": "ISC" }, "node_modules/set-blocking": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==" + "license": "ISC" }, "node_modules/set-function-length": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.1.1.tgz", - "integrity": "sha512-VoaqjbBJKiWtg4yRcKBQ7g7wnGnLV3M8oLvVWwOk2PdYY6PEFegR1vezXR0tw6fZGF9csVakIRjrJiy2veSBFQ==", + "license": "MIT", "dependencies": { "define-data-property": "^1.1.1", "get-intrinsic": "^1.2.1", @@ -21547,8 +17688,7 @@ }, "node_modules/set-function-name": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", - "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "license": "MIT", "dependencies": { "define-data-property": "^1.0.1", "functions-have-names": "^1.2.3", @@ -21560,13 +17700,12 @@ }, "node_modules/set-value": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/set-value/-/set-value-4.1.0.tgz", - "integrity": "sha512-zTEg4HL0RwVrqcWs3ztF+x1vkxfm0lP+MQQFPiMJTKVceBwEV0A569Ou8l9IYQG8jOZdMVI1hGsc0tmeD2o/Lw==", "funding": [ "https://github.com/sponsors/jonschlinkert", "https://paypal.me/jonathanschlinkert", "https://jonschlinkert.dev/sponsor" ], + "license": "MIT", "dependencies": { "is-plain-object": "^2.0.4", "is-primitive": "^3.0.1" @@ -21577,13 +17716,10 @@ }, "node_modules/setprototypeof": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==" + "license": "ISC" }, "node_modules/sha256": { "version": "0.2.0", - "resolved": "https://registry.npmjs.org/sha256/-/sha256-0.2.0.tgz", - "integrity": "sha512-kTWMJUaez5iiT9CcMv8jSq6kMhw3ST0uRdcIWl3D77s6AsLXNXRp3heeqqfu5+Dyfu4hwpQnMzhqHh8iNQxw0w==", "dependencies": { "convert-hex": "~0.1.0", "convert-string": "~0.1.0" @@ -21591,8 +17727,7 @@ }, "node_modules/shebang-command": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "license": "MIT", "dependencies": { "shebang-regex": "^3.0.0" }, @@ -21602,22 +17737,19 @@ }, "node_modules/shebang-regex": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/shellwords": { "version": "0.1.1", - "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", - "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/side-channel": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.0", "get-intrinsic": "^1.0.2", @@ -21629,41 +17761,35 @@ }, "node_modules/signal-exit": { "version": "3.0.7", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + "license": "ISC" }, "node_modules/simple-swizzle": { "version": "0.2.2", - "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", - "integrity": "sha512-JA//kQgZtbuY83m+xT+tXJkmJncGMTFT+C+g2h2R9uxkYIrE2yy9sgmcLhCnw57/WSD+Eh3J97FPEDFnbXnDUg==", + "license": "MIT", "dependencies": { "is-arrayish": "^0.3.1" } }, "node_modules/simple-swizzle/node_modules/is-arrayish": { "version": "0.3.2", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", - "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==" + "license": "MIT" }, "node_modules/sisteransi": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", - "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/slash": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", - "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/slice-ansi": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-5.0.0.tgz", - "integrity": "sha512-FC+lgizVPfie0kkhqUScwRu1O/lF6NOgJmlCgK+/LYxDCTk8sGelYaHDhFcDN+Sn3Cv+3VSa4Byeo+IMCzpMgQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^6.0.0", "is-fullwidth-code-point": "^4.0.0" @@ -21677,9 +17803,8 @@ }, "node_modules/slice-ansi/node_modules/ansi-styles": { "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", - "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", "dev": true, + "license": "MIT", "engines": { "node": ">=12" }, @@ -21689,9 +17814,8 @@ }, "node_modules/sort-keys": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/sort-keys/-/sort-keys-2.0.0.tgz", - "integrity": "sha512-/dPCrG1s3ePpWm6yBbxZq5Be1dXGLyLn9Z791chDC3NFrpkVbWGzkBwPN1knaciexFXgRJ7hzdnwZ4stHSDmjg==", "dev": true, + "license": "MIT", "dependencies": { "is-plain-obj": "^1.0.0" }, @@ -21701,26 +17825,23 @@ }, "node_modules/source-map": { "version": "0.7.4", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.4.tgz", - "integrity": "sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==", + "license": "BSD-3-Clause", "engines": { "node": ">= 8" } }, "node_modules/source-map-js": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", - "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/source-map-support": { "version": "0.5.13", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", - "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", "dev": true, + "license": "MIT", "dependencies": { "buffer-from": "^1.0.0", "source-map": "^0.6.0" @@ -21728,17 +17849,15 @@ }, "node_modules/source-map-support/node_modules/source-map": { "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/spdx-correct": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.2.0.tgz", - "integrity": "sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==", + "license": "Apache-2.0", "dependencies": { "spdx-expression-parse": "^3.0.0", "spdx-license-ids": "^3.0.0" @@ -21746,13 +17865,11 @@ }, "node_modules/spdx-exceptions": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz", - "integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==" + "license": "CC-BY-3.0" }, "node_modules/spdx-expression-parse": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz", - "integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==", + "license": "MIT", "dependencies": { "spdx-exceptions": "^2.1.0", "spdx-license-ids": "^3.0.0" @@ -21760,13 +17877,11 @@ }, "node_modules/spdx-license-ids": { "version": "3.0.16", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.16.tgz", - "integrity": "sha512-eWN+LnM3GR6gPu35WxNgbGl8rmY1AEmoMDvL/QD6zYmPWgywxWqJWNdLGT+ke8dKNWrcYgYjPpG5gbTfghP8rw==" + "license": "CC0-1.0" }, "node_modules/split": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/split/-/split-1.0.1.tgz", - "integrity": "sha512-mTyOoPbrivtXnwnIxZRFYRrPNtEFKlpB2fvjSnCQUiAA6qAZzqwna5envK4uk6OIeP17CsdF3rSBGYVBsU0Tkg==", + "license": "MIT", "dependencies": { "through": "2" }, @@ -21776,18 +17891,16 @@ }, "node_modules/split2": { "version": "3.2.2", - "resolved": "https://registry.npmjs.org/split2/-/split2-3.2.2.tgz", - "integrity": "sha512-9NThjpgZnifTkJpzTZ7Eue85S49QwpNhZTq6GRJwObb6jnLFNGB7Qm73V5HewTROPyxD0C29xqmaI68bQtV+hg==", "dev": true, + "license": "ISC", "dependencies": { "readable-stream": "^3.0.0" } }, "node_modules/split2/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -21799,39 +17912,34 @@ }, "node_modules/sprintf-js": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", - "dev": true + "dev": true, + "license": "BSD-3-Clause" }, "node_modules/sqlstring": { "version": "2.3.3", - "resolved": "https://registry.npmjs.org/sqlstring/-/sqlstring-2.3.3.tgz", - "integrity": "sha512-qC9iz2FlN7DQl3+wjwn3802RTyjCx7sDvfQEXchwa6CWOx07/WVfh91gBmQ9fahw8snwGEWU3xGzOt4tFyHLxg==", + "license": "MIT", "engines": { "node": ">= 0.6" } }, "node_modules/stack-generator": { "version": "2.0.10", - "resolved": "https://registry.npmjs.org/stack-generator/-/stack-generator-2.0.10.tgz", - "integrity": "sha512-mwnua/hkqM6pF4k8SnmZ2zfETsRUpWXREfA/goT8SLCV4iOFa4bzOX2nDipWAZFPTjLvQB82f5yaodMVhK0yJQ==", + "license": "MIT", "dependencies": { "stackframe": "^1.3.4" } }, "node_modules/stack-trace": { "version": "0.0.10", - "resolved": "https://registry.npmjs.org/stack-trace/-/stack-trace-0.0.10.tgz", - "integrity": "sha512-KGzahc7puUKkzyMt+IqAep+TVNbKP+k2Lmwhub39m1AsTSkaDutx56aDCo+HLDzf/D26BIHTJWNiTG1KAJiQCg==", + "license": "MIT", "engines": { "node": "*" } }, "node_modules/stack-utils": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", - "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", "dev": true, + "license": "MIT", "dependencies": { "escape-string-regexp": "^2.0.0" }, @@ -21841,22 +17949,19 @@ }, "node_modules/stack-utils/node_modules/escape-string-regexp": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", - "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/stackframe": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/stackframe/-/stackframe-1.3.4.tgz", - "integrity": "sha512-oeVtt7eWQS+Na6F//S4kJ2K2VbRlS9D43mAlMyVpVWovy9o+jfgH8O9agzANzaiLjclA0oYzUXEM4PurhSUChw==" + "license": "MIT" }, "node_modules/stacktrace-parser": { "version": "0.1.10", - "resolved": "https://registry.npmjs.org/stacktrace-parser/-/stacktrace-parser-0.1.10.tgz", - "integrity": "sha512-KJP1OCML99+8fhOHxwwzyWrlUuVX5GQ0ZpJTd1DFXhdkrvg1szxfHhawXUZ3g9TkXORQd4/WG68jMlQZ2p8wlg==", + "license": "MIT", "dependencies": { "type-fest": "^0.7.1" }, @@ -21866,22 +17971,19 @@ }, "node_modules/stacktrace-parser/node_modules/type-fest": { "version": "0.7.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.7.1.tgz", - "integrity": "sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==", + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=8" } }, "node_modules/standard-as-callback": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/standard-as-callback/-/standard-as-callback-2.1.0.tgz", - "integrity": "sha512-qoRRSyROncaz1z0mvYqIE4lCd9p2R90i6GxW3uZv5ucSu8tU7B5HXUP1gG8pVZsYNVaXjk8ClXHPttLyxAL48A==" + "license": "MIT" }, "node_modules/standard-version": { "version": "9.5.0", - "resolved": "https://registry.npmjs.org/standard-version/-/standard-version-9.5.0.tgz", - "integrity": "sha512-3zWJ/mmZQsOaO+fOlsa0+QK90pwhNd042qEcw6hKFNoLFs7peGyvPffpEBbK/DSGPbyOvli0mUIFv5A4qTjh2Q==", "dev": true, + "license": "ISC", "dependencies": { "chalk": "^2.4.2", "conventional-changelog": "3.1.25", @@ -21907,9 +18009,8 @@ }, "node_modules/standard-version/node_modules/cliui": { "version": "7.0.4", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", - "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", "dev": true, + "license": "ISC", "dependencies": { "string-width": "^4.2.0", "strip-ansi": "^6.0.0", @@ -21918,9 +18019,8 @@ }, "node_modules/standard-version/node_modules/conventional-changelog": { "version": "3.1.25", - "resolved": "https://registry.npmjs.org/conventional-changelog/-/conventional-changelog-3.1.25.tgz", - "integrity": "sha512-ryhi3fd1mKf3fSjbLXOfK2D06YwKNic1nC9mWqybBHdObPd8KJ2vjaXZfYj1U23t+V8T8n0d7gwnc9XbIdFbyQ==", "dev": true, + "license": "MIT", "dependencies": { "conventional-changelog-angular": "^5.0.12", "conventional-changelog-atom": "^2.0.8", @@ -21940,9 +18040,8 @@ }, "node_modules/standard-version/node_modules/conventional-changelog-angular": { "version": "5.0.13", - "resolved": "https://registry.npmjs.org/conventional-changelog-angular/-/conventional-changelog-angular-5.0.13.tgz", - "integrity": "sha512-i/gipMxs7s8L/QeuavPF2hLnJgH6pEZAttySB6aiQLWcX3puWDL3ACVmvBhJGxnAy52Qc15ua26BufY6KpmrVA==", "dev": true, + "license": "ISC", "dependencies": { "compare-func": "^2.0.0", "q": "^1.5.1" @@ -21953,9 +18052,8 @@ }, "node_modules/standard-version/node_modules/conventional-changelog-conventionalcommits": { "version": "4.6.3", - "resolved": "https://registry.npmjs.org/conventional-changelog-conventionalcommits/-/conventional-changelog-conventionalcommits-4.6.3.tgz", - "integrity": "sha512-LTTQV4fwOM4oLPad317V/QNQ1FY4Hju5qeBIM1uTHbrnCE+Eg4CdRZ3gO2pUeR+tzWdp80M2j3qFFEDWVqOV4g==", "dev": true, + "license": "ISC", "dependencies": { "compare-func": "^2.0.0", "lodash": "^4.17.15", @@ -21967,9 +18065,8 @@ }, "node_modules/standard-version/node_modules/conventional-changelog-core": { "version": "4.2.4", - "resolved": "https://registry.npmjs.org/conventional-changelog-core/-/conventional-changelog-core-4.2.4.tgz", - "integrity": "sha512-gDVS+zVJHE2v4SLc6B0sLsPiloR0ygU7HaDW14aNJE1v4SlqJPILPl/aJC7YdtRE4CybBf8gDwObBvKha8Xlyg==", "dev": true, + "license": "MIT", "dependencies": { "add-stream": "^1.0.0", "conventional-changelog-writer": "^5.0.0", @@ -21992,18 +18089,16 @@ }, "node_modules/standard-version/node_modules/conventional-changelog-core/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/standard-version/node_modules/conventional-changelog-jquery": { "version": "3.0.11", - "resolved": "https://registry.npmjs.org/conventional-changelog-jquery/-/conventional-changelog-jquery-3.0.11.tgz", - "integrity": "sha512-x8AWz5/Td55F7+o/9LQ6cQIPwrCjfJQ5Zmfqi8thwUEKHstEn4kTIofXub7plf1xvFA2TqhZlq7fy5OmV6BOMw==", "dev": true, + "license": "ISC", "dependencies": { "q": "^1.5.1" }, @@ -22013,9 +18108,8 @@ }, "node_modules/standard-version/node_modules/conventional-changelog-writer": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-5.0.1.tgz", - "integrity": "sha512-5WsuKUfxW7suLblAbFnxAcrvf6r+0b7GvNaWUwUIk0bXMnENP/PEieGKVUQrjPqwPT4o3EPAASBXiY6iHooLOQ==", "dev": true, + "license": "MIT", "dependencies": { "conventional-commits-filter": "^2.0.7", "dateformat": "^3.0.0", @@ -22036,27 +18130,24 @@ }, "node_modules/standard-version/node_modules/conventional-changelog-writer/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/standard-version/node_modules/conventional-changelog-writer/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/standard-version/node_modules/conventional-commits-parser": { "version": "3.2.4", - "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-3.2.4.tgz", - "integrity": "sha512-nK7sAtfi+QXbxHCYfhpZsfRtaitZLIA6889kFIouLvz6repszQDgxBu7wf2WbU+Dco7sAnNCJYERCwt54WPC2Q==", "dev": true, + "license": "MIT", "dependencies": { "is-text-path": "^1.0.1", "JSONStream": "^1.0.4", @@ -22074,18 +18165,16 @@ }, "node_modules/standard-version/node_modules/conventional-commits-parser/node_modules/through2": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "3" } }, "node_modules/standard-version/node_modules/get-pkg-repo": { "version": "4.2.1", - "resolved": "https://registry.npmjs.org/get-pkg-repo/-/get-pkg-repo-4.2.1.tgz", - "integrity": "sha512-2+QbHjFRfGB74v/pYWjd5OhU3TDIC2Gv/YKUTk/tCvAz0pkn/Mz6P3uByuBimLOcPvN2jYdScl3xGFSrx0jEcA==", "dev": true, + "license": "MIT", "dependencies": { "@hutson/parse-repository-url": "^3.0.0", "hosted-git-info": "^4.0.0", @@ -22101,9 +18190,8 @@ }, "node_modules/standard-version/node_modules/git-semver-tags": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/git-semver-tags/-/git-semver-tags-4.1.1.tgz", - "integrity": "sha512-OWyMt5zBe7xFs8vglMmhM9lRQzCWL3WjHtxNNfJTMngGym7pC1kh8sP6jevfydJ6LP3ZvGxfb6ABYgPUM0mtsA==", "dev": true, + "license": "MIT", "dependencies": { "meow": "^8.0.0", "semver": "^6.0.0" @@ -22117,18 +18205,16 @@ }, "node_modules/standard-version/node_modules/git-semver-tags/node_modules/semver": { "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, + "license": "ISC", "bin": { "semver": "bin/semver.js" } }, "node_modules/standard-version/node_modules/hosted-git-info": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", - "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", "dev": true, + "license": "ISC", "dependencies": { "lru-cache": "^6.0.0" }, @@ -22138,9 +18224,8 @@ }, "node_modules/standard-version/node_modules/lru-cache": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", "dev": true, + "license": "ISC", "dependencies": { "yallist": "^4.0.0" }, @@ -22150,9 +18235,8 @@ }, "node_modules/standard-version/node_modules/normalize-package-data": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-3.0.3.tgz", - "integrity": "sha512-p2W1sgqij3zMMyRC067Dg16bfzVH+w7hyegmpIvZ4JNjqtGOVAIvLmjBx3yP7YTe9vKJgkoNOPjwQGogDoMXFA==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "hosted-git-info": "^4.0.1", "is-core-module": "^2.5.0", @@ -22165,9 +18249,8 @@ }, "node_modules/standard-version/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", "dev": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -22179,15 +18262,13 @@ }, "node_modules/standard-version/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/standard-version/node_modules/yargs": { "version": "16.2.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", - "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", "dev": true, + "license": "MIT", "dependencies": { "cliui": "^7.0.2", "escalade": "^3.1.1", @@ -22203,16 +18284,14 @@ }, "node_modules/static-eval": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/static-eval/-/static-eval-2.0.2.tgz", - "integrity": "sha512-N/D219Hcr2bPjLxPiV+TQE++Tsmrady7TqAJugLy7Xk1EumfDWS/f5dtBbkRCGE7wKKXuYockQoj8Rm2/pVKyg==", + "license": "MIT", "dependencies": { "escodegen": "^1.8.1" } }, "node_modules/static-eval/node_modules/escodegen": { "version": "1.14.3", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.14.3.tgz", - "integrity": "sha512-qFcX0XJkdg+PB3xjZZG/wKSuT1PnQWx57+TVSjIMmILd2yC/6ByYElPwJnslDsuWuSAp4AwJGumarAAmJch5Kw==", + "license": "BSD-2-Clause", "dependencies": { "esprima": "^4.0.1", "estraverse": "^4.2.0", @@ -22232,8 +18311,7 @@ }, "node_modules/static-eval/node_modules/levn": { "version": "0.3.0", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", + "license": "MIT", "dependencies": { "prelude-ls": "~1.1.2", "type-check": "~0.3.2" @@ -22244,8 +18322,7 @@ }, "node_modules/static-eval/node_modules/optionator": { "version": "0.8.3", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", - "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", + "license": "MIT", "dependencies": { "deep-is": "~0.1.3", "fast-levenshtein": "~2.0.6", @@ -22260,16 +18337,13 @@ }, "node_modules/static-eval/node_modules/prelude-ls": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", - "integrity": "sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==", "engines": { "node": ">= 0.8.0" } }, "node_modules/static-eval/node_modules/source-map": { "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "license": "BSD-3-Clause", "optional": true, "engines": { "node": ">=0.10.0" @@ -22277,8 +18351,7 @@ }, "node_modules/static-eval/node_modules/type-check": { "version": "0.3.2", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", - "integrity": "sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==", + "license": "MIT", "dependencies": { "prelude-ls": "~1.1.2" }, @@ -22288,31 +18361,26 @@ }, "node_modules/stats-accumulator": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/stats-accumulator/-/stats-accumulator-1.1.3.tgz", - "integrity": "sha512-ys8OR2RWx4Y9xC/fkFUKI3t2ElHpR4Xdp8rIWVCTl4DWmfS80gvxl0LwNKYUio/ibBUpsoMaUYbWldonVfPBFQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.8" } }, "node_modules/statsd-client": { "version": "0.4.7", - "resolved": "https://registry.npmjs.org/statsd-client/-/statsd-client-0.4.7.tgz", - "integrity": "sha512-+sGCE6FednJ/vI7vywErOg/mhVqmf6Zlktz7cdGRnF/cQWXD9ifMgtqU1CIIXmhSwm11SCk4zDN+bwNCvIR/Kg==", - "deprecated": "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info." + "license": "MIT" }, "node_modules/statuses": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", - "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/stream-browserify": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-3.0.0.tgz", - "integrity": "sha512-H73RAHsVBapbim0tU2JwwOiXUj+fikfiaoYAKHF3VJfA0pe2BCzkhAHBlLG6REzE+2WNZcxOXjK7lkso+9euLA==", + "license": "MIT", "dependencies": { "inherits": "~2.0.4", "readable-stream": "^3.5.0" @@ -22320,8 +18388,7 @@ }, "node_modules/stream-browserify/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -22333,49 +18400,43 @@ }, "node_modules/stream-to-array": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/stream-to-array/-/stream-to-array-2.3.0.tgz", - "integrity": "sha512-UsZtOYEn4tWU2RGLOXr/o/xjRBftZRlG3dEWoaHr8j4GuypJ3isitGbVyjQKAuMu+xbiop8q224TjiZWc4XTZA==", "dev": true, + "license": "MIT", "dependencies": { "any-promise": "^1.1.0" } }, "node_modules/strict-uri-encode": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz", - "integrity": "sha512-R3f198pcvnB+5IpnBlRkphuE9n46WyVl8I39W/ZUTZLz4nqSP/oLYUrcnJrw462Ds8he4YKMov2efsTIw1BDGQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/string_decoder": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "license": "MIT", "dependencies": { "safe-buffer": "~5.1.0" } }, "node_modules/string_decoder/node_modules/safe-buffer": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + "license": "MIT" }, "node_modules/string-argv": { "version": "0.3.2", - "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.3.2.tgz", - "integrity": "sha512-aqD2Q0144Z+/RqG52NeHEkZauTAUWJO8c6yTftGJKO3Tja5tUgIfmIl6kExvhtxSDP7fXB6DvzkfMpCd/F3G+Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.6.19" } }, "node_modules/string-length": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", - "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", "dev": true, + "license": "MIT", "dependencies": { "char-regex": "^1.0.2", "strip-ansi": "^6.0.0" @@ -22386,8 +18447,7 @@ }, "node_modules/string-width": { "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "license": "MIT", "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", @@ -22400,9 +18460,8 @@ "node_modules/string-width-cjs": { "name": "string-width", "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", "dev": true, + "license": "MIT", "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", @@ -22414,25 +18473,22 @@ }, "node_modules/string-width-cjs/node_modules/is-fullwidth-code-point": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/string-width/node_modules/is-fullwidth-code-point": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/string.prototype.trim": { "version": "1.2.8", - "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", - "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -22447,8 +18503,7 @@ }, "node_modules/string.prototype.trimend": { "version": "1.0.7", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", - "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -22460,8 +18515,7 @@ }, "node_modules/string.prototype.trimstart": { "version": "1.0.7", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", - "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "define-properties": "^1.2.0", @@ -22473,9 +18527,8 @@ }, "node_modules/stringify-object": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/stringify-object/-/stringify-object-3.3.0.tgz", - "integrity": "sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "get-own-enumerable-property-symbols": "^3.0.0", "is-obj": "^1.0.1", @@ -22487,15 +18540,12 @@ }, "node_modules/stringify-package": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/stringify-package/-/stringify-package-1.0.1.tgz", - "integrity": "sha512-sa4DUQsYciMP1xhKWGuFM04fB0LG/9DlluZoSVywUMRNvzid6XucHK0/90xGxRoHrAaROrcHK1aPKaijCtSrhg==", - "deprecated": "This module is not used anymore, and has been replaced by @npmcli/package-json", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/strip-ansi": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "license": "MIT", "dependencies": { "ansi-regex": "^5.0.1" }, @@ -22506,9 +18556,8 @@ "node_modules/strip-ansi-cjs": { "name": "strip-ansi", "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", "dev": true, + "license": "MIT", "dependencies": { "ansi-regex": "^5.0.1" }, @@ -22518,27 +18567,24 @@ }, "node_modules/strip-bom": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", - "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/strip-final-newline": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", - "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/strip-indent": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-3.0.0.tgz", - "integrity": "sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ==", "dev": true, + "license": "MIT", "dependencies": { "min-indent": "^1.0.0" }, @@ -22548,8 +18594,7 @@ }, "node_modules/strip-json-comments": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", - "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "license": "MIT", "engines": { "node": ">=8" }, @@ -22559,14 +18604,12 @@ }, "node_modules/strnum": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/strnum/-/strnum-1.0.5.tgz", - "integrity": "sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==" + "license": "MIT" }, "node_modules/stylus-lookup": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/stylus-lookup/-/stylus-lookup-3.0.2.tgz", - "integrity": "sha512-oEQGHSjg/AMaWlKe7gqsnYzan8DLcGIHe0dUaFkucZZ14z4zjENRlQMCHT4FNsiWnJf17YN9OvrCfCoi7VvOyg==", "dev": true, + "license": "MIT", "dependencies": { "commander": "^2.8.1", "debug": "^4.1.0" @@ -22580,23 +18623,20 @@ }, "node_modules/stylus-lookup/node_modules/commander": { "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/subdirs": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/subdirs/-/subdirs-1.0.1.tgz", - "integrity": "sha512-KSbUKpwQIRcb5Th+l4EzxEZYpCwV/g0pQ348EV7CIM5YEEgzz2L1KJD8FCeTckTiE/TKn2u09DCxpdAL6/iFbg==", + "license": "MIT", "dependencies": { "es6-promise": "^3.0.2" } }, "node_modules/superagent": { "version": "8.1.2", - "resolved": "https://registry.npmjs.org/superagent/-/superagent-8.1.2.tgz", - "integrity": "sha512-6WTxW1EB6yCxV5VFOIPQruWGHqc3yI7hEmZK6h+pyk69Lk/Ut7rLUY6W/ONF2MjBuGjvmMiIpsrVJ2vjrHlslA==", "dev": true, + "license": "MIT", "dependencies": { "component-emitter": "^1.3.0", "cookiejar": "^2.1.4", @@ -22615,9 +18655,8 @@ }, "node_modules/supertest": { "version": "6.3.3", - "resolved": "https://registry.npmjs.org/supertest/-/supertest-6.3.3.tgz", - "integrity": "sha512-EMCG6G8gDu5qEqRQ3JjjPs6+FYT1a7Hv5ApHvtSghmOFJYtsU5S+pSb6Y2EUeCEY3CmEL3mmQ8YWlPOzQomabA==", "dev": true, + "license": "MIT", "dependencies": { "methods": "^1.1.2", "superagent": "^8.0.5" @@ -22628,8 +18667,7 @@ }, "node_modules/supports-color": { "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "license": "MIT", "dependencies": { "has-flag": "^3.0.0" }, @@ -22639,8 +18677,7 @@ }, "node_modules/supports-preserve-symlinks-flag": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", - "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -22650,9 +18687,8 @@ }, "node_modules/swagger-cli": { "version": "4.0.4", - "resolved": "https://registry.npmjs.org/swagger-cli/-/swagger-cli-4.0.4.tgz", - "integrity": "sha512-Cp8YYuLny3RJFQ4CvOBTaqmOOgYsem52dPx1xM5S4EUWFblIh2Q8atppMZvXKUr1e9xH5RwipYpmdUzdPcxWcA==", "dev": true, + "license": "MIT", "dependencies": { "@apidevtools/swagger-cli": "4.0.4" }, @@ -22665,9 +18701,8 @@ }, "node_modules/synckit": { "version": "0.8.8", - "resolved": "https://registry.npmjs.org/synckit/-/synckit-0.8.8.tgz", - "integrity": "sha512-HwOKAP7Wc5aRGYdKH+dw0PRRpbO841v2DENBtjnR5HFWoiNByAl7vrx3p0G/rCyYXQsrxqtX48TImFtPcIHSpQ==", "dev": true, + "license": "MIT", "dependencies": { "@pkgr/core": "^0.1.0", "tslib": "^2.6.2" @@ -22681,17 +18716,15 @@ }, "node_modules/tapable": { "version": "2.2.1", - "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.2.1.tgz", - "integrity": "sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/tar": { "version": "6.2.1", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.2.1.tgz", - "integrity": "sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==", + "license": "ISC", "dependencies": { "chownr": "^2.0.0", "fs-minipass": "^2.0.0", @@ -22706,30 +18739,26 @@ }, "node_modules/tar/node_modules/minipass": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", - "integrity": "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==", + "license": "ISC", "engines": { "node": ">=8" } }, "node_modules/tar/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + "license": "ISC" }, "node_modules/tdigest": { "version": "0.1.2", - "resolved": "https://registry.npmjs.org/tdigest/-/tdigest-0.1.2.tgz", - "integrity": "sha512-+G0LLgjjo9BZX2MfdvPfH+MKLCrxlXSYec5DaPYP1fe6Iyhf0/fSmJ0bFiZ1F8BT6cGXl2LpltQptzjXKWEkKA==", + "license": "MIT", "dependencies": { "bintrees": "1.0.2" } }, "node_modules/test-exclude": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", - "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", "dev": true, + "license": "ISC", "dependencies": { "@istanbuljs/schema": "^0.1.2", "glob": "^7.1.4", @@ -22741,9 +18770,8 @@ }, "node_modules/test-exclude/node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -22761,33 +18789,28 @@ }, "node_modules/text-extensions": { "version": "1.9.0", - "resolved": "https://registry.npmjs.org/text-extensions/-/text-extensions-1.9.0.tgz", - "integrity": "sha512-wiBrwC1EhBelW12Zy26JeOUkQ5mRu+5o8rpsJk5+2t+Y5vE7e842qtZDQ2g1NpX/29HdyFeJ4nSIhI47ENSxlQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10" } }, "node_modules/text-hex": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/text-hex/-/text-hex-1.0.0.tgz", - "integrity": "sha512-uuVGNWzgJ4yhRaNSiubPY7OjISw4sw4E5Uv0wbjp+OzcbmVU/rsT8ujgcXJhn9ypzsgr5vlzpPqP+MBBKcGvbg==" + "license": "MIT" }, "node_modules/text-table": { "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==" + "license": "MIT" }, "node_modules/through": { "version": "2.3.8", - "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", - "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + "license": "MIT" }, "node_modules/through2": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", - "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", "dev": true, + "license": "MIT", "dependencies": { "readable-stream": "~2.3.6", "xtend": "~4.0.1" @@ -22795,18 +18818,16 @@ }, "node_modules/timed-out": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/timed-out/-/timed-out-4.0.1.tgz", - "integrity": "sha512-G7r3AhovYtr5YKOWQkta8RKAPb+J9IsO4uVmzjl8AZwfhs8UcUwTiD6gcJYSgOtzyjvQKrKYn41syHbUWMkafA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/tmp": { "version": "0.0.33", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", - "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", "dev": true, + "license": "MIT", "dependencies": { "os-tmpdir": "~1.0.2" }, @@ -22816,31 +18837,26 @@ }, "node_modules/tmpl": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", - "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", - "dev": true + "dev": true, + "license": "BSD-3-Clause" }, "node_modules/to-fast-properties": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/to-function": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/to-function/-/to-function-2.0.6.tgz", - "integrity": "sha512-LWfUmW851x5T8+78Nl82CA2j6w0trhoFj4rpS6pFUMgfUMUySDAKPgTvQkUqlWuH3Lihlk5sPyDHSVwmKDSc5Q==", "dependencies": { "component-props": "*" } }, "node_modules/to-regex-range": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "license": "MIT", "dependencies": { "is-number": "^7.0.0" }, @@ -22850,47 +18866,41 @@ }, "node_modules/toidentifier": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", - "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", + "license": "MIT", "engines": { "node": ">=0.6" } }, "node_modules/tr46": { "version": "0.0.3", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + "license": "MIT" }, "node_modules/trim-newlines": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-3.0.1.tgz", - "integrity": "sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/triple-beam": { "version": "1.4.1", - "resolved": "https://registry.npmjs.org/triple-beam/-/triple-beam-1.4.1.tgz", - "integrity": "sha512-aZbgViZrg1QNcG+LULa7nhZpJTZSLm/mXnHXnbAbjmN5aSa0y7V+wvv6+4WaBtpISJzThKy+PIPxc1Nq1EJ9mg==", + "license": "MIT", "engines": { "node": ">= 14.0.0" } }, "node_modules/truncate-utf8-bytes": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/truncate-utf8-bytes/-/truncate-utf8-bytes-1.0.2.tgz", - "integrity": "sha512-95Pu1QXQvruGEhv62XCMO3Mm90GscOCClvrIUwCM0PYOXK3kaF3l3sIHxx71ThJfcbM2O5Au6SO3AWCSEfW4mQ==", + "license": "WTFPL", "dependencies": { "utf8-byte-length": "^1.0.1" } }, "node_modules/ts-graphviz": { "version": "1.8.1", - "resolved": "https://registry.npmjs.org/ts-graphviz/-/ts-graphviz-1.8.1.tgz", - "integrity": "sha512-54/fe5iu0Jb6X0pmDmzsA2UHLfyHjUEUwfHtZcEOR0fZ6Myf+dFoO6eNsyL8CBDMJ9u7WWEewduVaiaXlvjSVw==", "dev": true, + "license": "MIT", "engines": { "node": ">=14.16" }, @@ -22901,9 +18911,8 @@ }, "node_modules/ts-jest": { "version": "29.1.1", - "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.1.tgz", - "integrity": "sha512-D6xjnnbP17cC85nliwGiL+tpoKN0StpgE0TeOjXQTU6MVCfsB4v7aW05CgQ/1OywGb0x/oy9hHFnN+sczTiRaA==", "dev": true, + "license": "MIT", "dependencies": { "bs-logger": "0.x", "fast-json-stable-stringify": "2.x", @@ -22944,18 +18953,16 @@ }, "node_modules/ts-jest/node_modules/yargs-parser": { "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", "dev": true, + "license": "ISC", "engines": { "node": ">=12" } }, "node_modules/ts-node": { "version": "10.9.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.2.tgz", - "integrity": "sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==", "dev": true, + "license": "MIT", "dependencies": { "@cspotcode/source-map-support": "^0.8.0", "@tsconfig/node10": "^1.0.7", @@ -22996,8 +19003,7 @@ }, "node_modules/tsconfig-paths": { "version": "3.15.0", - "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.15.0.tgz", - "integrity": "sha512-2Ac2RgzDe/cn48GvOe3M+o82pEFewD3UPbyoUHHdKasHwJKjds4fLXWf/Ux5kATBKN20oaFGu+jbElp1pos0mg==", + "license": "MIT", "dependencies": { "@types/json5": "^0.0.29", "json5": "^1.0.2", @@ -23007,8 +19013,7 @@ }, "node_modules/tsconfig-paths/node_modules/json5": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", - "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", + "license": "MIT", "dependencies": { "minimist": "^1.2.0" }, @@ -23018,29 +19023,25 @@ }, "node_modules/tsconfig-paths/node_modules/strip-bom": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/tslib": { "version": "2.6.2", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", - "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + "license": "0BSD" }, "node_modules/tsscmp": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/tsscmp/-/tsscmp-1.0.6.tgz", - "integrity": "sha512-LxhtAkPDTkVCMQjt2h6eBVY28KCjikZqZfMcC15YBeNjkgUpdCfBu5HoiOTDu86v6smE8yOjyEktJ8hlbANHQA==", + "license": "MIT", "engines": { "node": ">=0.6.x" } }, "node_modules/tsutils": { "version": "3.21.0", - "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-3.21.0.tgz", - "integrity": "sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==", + "license": "MIT", "dependencies": { "tslib": "^1.8.1" }, @@ -23053,13 +19054,11 @@ }, "node_modules/tsutils/node_modules/tslib": { "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" + "license": "0BSD" }, "node_modules/type-check": { "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", + "license": "MIT", "dependencies": { "prelude-ls": "^1.2.1" }, @@ -23069,17 +19068,15 @@ }, "node_modules/type-detect": { "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/type-fest": { "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=10" }, @@ -23089,8 +19086,7 @@ }, "node_modules/type-is": { "version": "1.6.18", - "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", - "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", + "license": "MIT", "dependencies": { "media-typer": "0.3.0", "mime-types": "~2.1.24" @@ -23101,8 +19097,7 @@ }, "node_modules/typed-array-buffer": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", - "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "get-intrinsic": "^1.2.1", @@ -23114,8 +19109,7 @@ }, "node_modules/typed-array-byte-length": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", - "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "for-each": "^0.3.3", @@ -23131,8 +19125,7 @@ }, "node_modules/typed-array-byte-offset": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", - "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "license": "MIT", "dependencies": { "available-typed-arrays": "^1.0.5", "call-bind": "^1.0.2", @@ -23149,8 +19142,7 @@ }, "node_modules/typed-array-length": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", - "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "for-each": "^0.3.3", @@ -23162,14 +19154,12 @@ }, "node_modules/typedarray": { "version": "0.0.6", - "resolved": "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz", - "integrity": "sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/typescript": { "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -23180,8 +19170,6 @@ }, "node_modules/ua-parser-js": { "version": "1.0.37", - "resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-1.0.37.tgz", - "integrity": "sha512-bhTyI94tZofjo+Dn8SN6Zv8nBDvyXTymAdM3LDI/0IboIUwTu1rEhW7v2TfiVsoYWgkQ4kOVqnI8APUFbIQIFQ==", "funding": [ { "type": "opencollective", @@ -23196,14 +19184,14 @@ "url": "https://github.com/sponsors/faisalman" } ], + "license": "MIT", "engines": { "node": "*" } }, "node_modules/uglify-js": { "version": "3.17.4", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.17.4.tgz", - "integrity": "sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==", + "license": "BSD-2-Clause", "optional": true, "bin": { "uglifyjs": "bin/uglifyjs" @@ -23214,8 +19202,7 @@ }, "node_modules/unbox-primitive": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", - "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "license": "MIT", "dependencies": { "call-bind": "^1.0.2", "has-bigints": "^1.0.2", @@ -23228,41 +19215,35 @@ }, "node_modules/underscore": { "version": "1.12.1", - "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.12.1.tgz", - "integrity": "sha512-hEQt0+ZLDVUMhebKxL4x1BTtDY7bavVofhZ9KZ4aI26X9SRaE+Y3m83XUL1UP2jn8ynjndwCCpEHdUG+9pP1Tw==" + "license": "MIT" }, "node_modules/undici-types": { "version": "5.26.5", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", - "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==" + "license": "MIT" }, "node_modules/uniq": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/uniq/-/uniq-1.0.1.tgz", - "integrity": "sha512-Gw+zz50YNKPDKXs+9d+aKAjVwpjNwqzvNpLigIruT4HA9lMZNdMqs9x07kKHB/L9WRzqp4+DlTU5s4wG2esdoA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/universalify": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", - "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", "dev": true, + "license": "MIT", "engines": { "node": ">= 10.0.0" } }, "node_modules/unpipe": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", - "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/unset-value": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-2.0.1.tgz", - "integrity": "sha512-2hvrBfjUE00PkqN+q0XP6yRAOGrR06uSiUoIQGZkc7GxvQ9H7v8quUPNtZjMg4uux69i8HWpIjLPUKwCuRGyNg==", + "license": "MIT", "dependencies": { "has-value": "^2.0.2", "isobject": "^4.0.0" @@ -23273,16 +19254,13 @@ }, "node_modules/unset-value/node_modules/isobject": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/isobject/-/isobject-4.0.0.tgz", - "integrity": "sha512-S/2fF5wH8SJA/kmwr6HYhK/RI/OkhD84k8ntalo0iJjZikgq1XFvR5M8NPT1x5F7fBwCG3qHfnzeP/Vh/ZxCUA==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/update-browserslist-db": { "version": "1.0.13", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.13.tgz", - "integrity": "sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg==", "dev": true, "funding": [ { @@ -23298,6 +19276,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "dependencies": { "escalade": "^3.1.1", "picocolors": "^1.0.0" @@ -23311,17 +19290,15 @@ }, "node_modules/uri-js": { "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", + "license": "BSD-2-Clause", "dependencies": { "punycode": "^2.1.0" } }, "node_modules/url-parse-lax": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/url-parse-lax/-/url-parse-lax-3.0.0.tgz", - "integrity": "sha512-NjFKA0DidqPa5ciFcSrXnAltTtzz84ogy+NebPvfEgAck0+TNg4UJ4IN+fB7zRZfbgUf0syOo9MDxFkDSMuFaQ==", "dev": true, + "license": "MIT", "dependencies": { "prepend-http": "^2.0.0" }, @@ -23331,51 +19308,44 @@ }, "node_modules/url-to-options": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/url-to-options/-/url-to-options-1.0.1.tgz", - "integrity": "sha512-0kQLIzG4fdk/G5NONku64rSH/x32NOA39LVQqlK8Le6lvTF6GGRJpqaQFGgU+CLwySIqBSMdwYM0sYcW9f6P4A==", "dev": true, + "license": "MIT", "engines": { "node": ">= 4" } }, "node_modules/utf8-byte-length": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/utf8-byte-length/-/utf8-byte-length-1.0.4.tgz", - "integrity": "sha512-4+wkEYLBbWxqTahEsWrhxepcoVOJ+1z5PGIjPZxRkytcdSUaNjIjBM7Xn8E+pdSuV7SzvWovBFA54FO0JSoqhA==" + "license": "WTFPL" }, "node_modules/utf8-length": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/utf8-length/-/utf8-length-0.0.1.tgz", - "integrity": "sha512-j/XH2ftofBiobnyApxlN/J6j/ixwT89WEjDcjT66d2i0+GIn9RZfzt8lpEXXE4jUe4NsjBSUq70kS2euQ4nnMw==" + "license": "MIT" }, "node_modules/util-deprecate": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + "license": "MIT" }, "node_modules/uuid": { "version": "9.0.1", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", - "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", "funding": [ "https://github.com/sponsors/broofa", "https://github.com/sponsors/ctavan" ], + "license": "MIT", "bin": { "uuid": "dist/bin/uuid" } }, "node_modules/v8-compile-cache-lib": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", - "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/v8-to-istanbul": { "version": "9.2.0", - "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.2.0.tgz", - "integrity": "sha512-/EH/sDgxU2eGxajKdwLCDmQ4FWq+kpi3uCmBGpw1xJtnAxEjlD8j8PEiGWpCIMIs3ciNAgH0d3TTJiUkYzyZjA==", "dev": true, + "license": "ISC", "dependencies": { "@jridgewell/trace-mapping": "^0.3.12", "@types/istanbul-lib-coverage": "^2.0.1", @@ -23386,14 +19356,11 @@ } }, "node_modules/valid-url": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/valid-url/-/valid-url-1.0.9.tgz", - "integrity": "sha512-QQDsV8OnSf5Uc30CKSwG9lnhMPe6exHtTXLRYX8uMwKENy640pU+2BgBL0LRbDh/eYRahNCS7aewCx0wf3NYVA==" + "version": "1.0.9" }, "node_modules/validate-npm-package-license": { "version": "3.0.4", - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", + "license": "Apache-2.0", "dependencies": { "spdx-correct": "^3.0.0", "spdx-expression-parse": "^3.0.0" @@ -23401,17 +19368,15 @@ }, "node_modules/vary": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", - "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "license": "MIT", "engines": { "node": ">= 0.8" } }, "node_modules/vscode-json-languageservice": { "version": "4.2.1", - "resolved": "https://registry.npmjs.org/vscode-json-languageservice/-/vscode-json-languageservice-4.2.1.tgz", - "integrity": "sha512-xGmv9QIWs2H8obGbWg+sIPI/3/pFgj/5OWBhNzs00BkYQ9UaB2F6JJaGB/2/YOZJ3BvLXQTC4Q7muqU25QgAhA==", "dev": true, + "license": "MIT", "dependencies": { "jsonc-parser": "^3.0.0", "vscode-languageserver-textdocument": "^1.0.3", @@ -23422,63 +19387,54 @@ }, "node_modules/vscode-languageserver-textdocument": { "version": "1.0.11", - "resolved": "https://registry.npmjs.org/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.11.tgz", - "integrity": "sha512-X+8T3GoiwTVlJbicx/sIAF+yuJAqz8VvwJyoMVhwEMoEKE/fkDmrqUgDMyBECcM2A2frVZIUj5HI/ErRXCfOeA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/vscode-languageserver-types": { "version": "3.17.5", - "resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.17.5.tgz", - "integrity": "sha512-Ld1VelNuX9pdF39h2Hgaeb5hEZM2Z3jUrrMgWQAu82jMtZp7p3vJT3BzToKtZI7NgQssZje5o0zryOrhQvzQAg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/vscode-nls": { "version": "5.2.0", - "resolved": "https://registry.npmjs.org/vscode-nls/-/vscode-nls-5.2.0.tgz", - "integrity": "sha512-RAaHx7B14ZU04EU31pT+rKz2/zSl7xMsfIZuo8pd+KZO6PXtQmpevpq3vxvWNcrGbdmhM/rr5Uw5Mz+NBfhVng==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/vscode-uri": { "version": "3.0.8", - "resolved": "https://registry.npmjs.org/vscode-uri/-/vscode-uri-3.0.8.tgz", - "integrity": "sha512-AyFQ0EVmsOZOlAnxoFOGOq1SQDWAB7C6aqMGS23svWAllfOaxbuFvcT8D1i8z3Gyn8fraVeZNNmN6e9bxxXkKw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/walkdir": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/walkdir/-/walkdir-0.4.1.tgz", - "integrity": "sha512-3eBwRyEln6E1MSzcxcVpQIhRG8Q1jLvEqRmCZqS3dsfXEDR/AhOF4d+jHg1qvDCpYaVRZjENPQyrVxAkQqxPgQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, "node_modules/walker": { "version": "1.0.8", - "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", - "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", "dev": true, + "license": "Apache-2.0", "dependencies": { "makeerror": "1.0.12" } }, "node_modules/wcwidth": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", - "integrity": "sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==", + "license": "MIT", "dependencies": { "defaults": "^1.0.3" } }, "node_modules/webidl-conversions": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + "license": "BSD-2-Clause" }, "node_modules/whatwg-url": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", - "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "license": "MIT", "dependencies": { "tr46": "~0.0.3", "webidl-conversions": "^3.0.0" @@ -23486,8 +19442,7 @@ }, "node_modules/which": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "license": "ISC", "dependencies": { "isexe": "^2.0.0" }, @@ -23500,8 +19455,7 @@ }, "node_modules/which-boxed-primitive": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", - "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "license": "MIT", "dependencies": { "is-bigint": "^1.0.1", "is-boolean-object": "^1.1.0", @@ -23515,14 +19469,12 @@ }, "node_modules/which-module": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.1.tgz", - "integrity": "sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/which-typed-array": { "version": "1.1.13", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.13.tgz", - "integrity": "sha512-P5Nra0qjSncduVPEAr7xhoF5guty49ArDTwzJ/yNuPIbZppyRxFQsRCWrocxIY+CnMVG+qfbU2FmDKyvSGClow==", + "license": "MIT", "dependencies": { "available-typed-arrays": "^1.0.5", "call-bind": "^1.0.4", @@ -23539,17 +19491,15 @@ }, "node_modules/wide-align": { "version": "1.1.5", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.5.tgz", - "integrity": "sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg==", + "license": "ISC", "dependencies": { "string-width": "^1.0.2 || 2 || 3 || 4" } }, "node_modules/widest-line": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/widest-line/-/widest-line-3.1.0.tgz", - "integrity": "sha512-NsmoXalsWVDMGupxZ5R08ka9flZjjiLvHVAWYOKtiKM8ujtZWr9cRffak+uSE48+Ob8ObalXpwyeUiyDD6QFgg==", "dev": true, + "license": "MIT", "dependencies": { "string-width": "^4.0.0" }, @@ -23559,8 +19509,7 @@ }, "node_modules/winston": { "version": "3.11.0", - "resolved": "https://registry.npmjs.org/winston/-/winston-3.11.0.tgz", - "integrity": "sha512-L3yR6/MzZAOl0DsysUXHVjOwv8mKZ71TrA/41EIduGpOOV5LQVodqN+QdQ6BS6PJ/RdIshZhq84P/fStEZkk7g==", + "license": "MIT", "dependencies": { "@colors/colors": "^1.6.0", "@dabh/diagnostics": "^2.0.2", @@ -23580,8 +19529,7 @@ }, "node_modules/winston-transport": { "version": "4.6.0", - "resolved": "https://registry.npmjs.org/winston-transport/-/winston-transport-4.6.0.tgz", - "integrity": "sha512-wbBA9PbPAHxKiygo7ub7BYRiKxms0tpfU2ljtWzb3SjRjv5yl6Ozuy/TkXf00HTAt+Uylo3gSkNwzc4ME0wiIg==", + "license": "MIT", "dependencies": { "logform": "^2.3.2", "readable-stream": "^3.6.0", @@ -23593,8 +19541,7 @@ }, "node_modules/winston-transport/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -23606,8 +19553,7 @@ }, "node_modules/winston/node_modules/readable-stream": { "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -23619,22 +19565,19 @@ }, "node_modules/word-wrap": { "version": "1.2.5", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", - "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/wordwrap": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", - "integrity": "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==" + "license": "MIT" }, "node_modules/wrap-ansi": { "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", @@ -23650,9 +19593,8 @@ "node_modules/wrap-ansi-cjs": { "name": "wrap-ansi", "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", @@ -23667,9 +19609,8 @@ }, "node_modules/wrap-ansi-cjs/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -23682,9 +19623,8 @@ }, "node_modules/wrap-ansi-cjs/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -23694,15 +19634,13 @@ }, "node_modules/wrap-ansi-cjs/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/wrap-ansi/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -23715,9 +19653,8 @@ }, "node_modules/wrap-ansi/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -23727,20 +19664,17 @@ }, "node_modules/wrap-ansi/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/wrappy": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + "license": "ISC" }, "node_modules/write-file-atomic": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.2.tgz", - "integrity": "sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg==", "dev": true, + "license": "ISC", "dependencies": { "imurmurhash": "^0.1.4", "signal-exit": "^3.0.7" @@ -23751,32 +19685,28 @@ }, "node_modules/xtend": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", - "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.4" } }, "node_modules/y18n": { "version": "5.0.8", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", - "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", "dev": true, + "license": "ISC", "engines": { "node": ">=10" } }, "node_modules/yallist": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", - "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/yaml": { "version": "2.4.3", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.4.3.tgz", - "integrity": "sha512-sntgmxj8o7DE7g/Qi60cqpLBA3HG3STcDA0kO+WfB05jEKhZMbY7umNm2rBpQvsmZ16/lPXCJGW2672dgOUkrg==", + "license": "ISC", "bin": { "yaml": "bin.mjs" }, @@ -23786,9 +19716,8 @@ }, "node_modules/yargs": { "version": "17.7.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", - "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", "dev": true, + "license": "MIT", "dependencies": { "cliui": "^8.0.1", "escalade": "^3.1.1", @@ -23804,43 +19733,38 @@ }, "node_modules/yargs-parser": { "version": "20.2.9", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", - "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", "dev": true, + "license": "ISC", "engines": { "node": ">=10" } }, "node_modules/yargs/node_modules/yargs-parser": { "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", "dev": true, + "license": "ISC", "engines": { "node": ">=12" } }, "node_modules/ylru": { "version": "1.3.2", - "resolved": "https://registry.npmjs.org/ylru/-/ylru-1.3.2.tgz", - "integrity": "sha512-RXRJzMiK6U2ye0BlGGZnmpwJDPgakn6aNQ0A7gHRbD4I0uvK4TW6UqkK1V0pp9jskjJBAXd3dRrbzWkqJ+6cxA==", + "license": "MIT", "engines": { "node": ">= 4.0.0" } }, "node_modules/yn": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/yocto-queue": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "license": "MIT", "engines": { "node": ">=10" }, @@ -23850,8 +19774,7 @@ }, "node_modules/zod": { "version": "3.22.4", - "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.4.tgz", - "integrity": "sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/colinhacks" } diff --git a/package.json b/package.json index 730340df16..a039fa3207 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "rudder-transformer", - "version": "1.71.3", + "version": "1.76.1", "description": "", "homepage": "https://github.com/rudderlabs/rudder-transformer#readme", "bugs": { @@ -55,7 +55,7 @@ }, "dependencies": { "@amplitude/ua-parser-js": "0.7.24", - "@aws-sdk/client-personalize": "^3.470.0", + "@aws-sdk/client-personalize": "^3.616.0", "@aws-sdk/client-s3": "^3.474.0", "@aws-sdk/credential-providers": "^3.391.0", "@aws-sdk/lib-storage": "^3.600.0", @@ -65,13 +65,13 @@ "@ndhoule/extend": "^2.0.0", "@pyroscope/nodejs": "^0.2.9", "@rudderstack/integrations-lib": "^0.2.10", - "@rudderstack/json-template-engine": "^0.17.1", - "@rudderstack/workflow-engine": "^0.8.12", + "@rudderstack/json-template-engine": "^0.18.0", + "@rudderstack/workflow-engine": "^0.8.13", "@shopify/jest-koa-mocks": "^5.1.1", "ajv": "^8.12.0", "ajv-draft-04": "^1.0.0", "ajv-formats": "^2.1.1", - "axios": "^1.6.4", + "axios": "^1.7.3", "btoa": "^1.2.1", "component-each": "^0.2.6", "crypto-js": "^4.2.0", @@ -90,6 +90,7 @@ "json-diff": "^1.0.3", "json-size": "^1.0.0", "jsontoxml": "^1.0.1", + "jstoxml": "^5.0.2", "koa": "^2.14.1", "koa-bodyparser": "^4.4.0", "koa2-swagger-ui": "^5.7.0", @@ -108,7 +109,6 @@ "prom-client": "^14.2.0", "qs": "^6.11.1", "rs-jsonpath": "^1.1.2", - "rudder-transformer-cdk": "^1.4.11", "set-value": "^4.1.0", "sha256": "^0.2.0", "sqlstring": "^2.3.3", @@ -150,7 +150,7 @@ "eslint-plugin-unicorn": "^46.0.1", "glob": "^10.3.3", "http-terminator": "^3.2.0", - "husky": "^8.0.3", + "husky": "^9.1.1", "jest": "^29.5.0", "jest-sonar": "^0.2.16", "jest-when": "^3.5.2", diff --git a/sample.env b/sample.env index 71b11fbfca..41caa84a10 100644 --- a/sample.env +++ b/sample.env @@ -9,4 +9,4 @@ REDIS_PORT = 6379 REDIS_PASSWORD = 123 REDIS_USERNAME = abc USE_REDIS_DB = true -REDIS_EXPIRY_TIME_IN_SEC = 3600 \ No newline at end of file +REDIS_EXPIRY_TIME_IN_SEC = 3600 diff --git a/src/adapters/network.js b/src/adapters/network.js index 86af19d6a1..aeb1cc128b 100644 --- a/src/adapters/network.js +++ b/src/adapters/network.js @@ -5,9 +5,14 @@ const lodash = require('lodash'); const http = require('http'); const https = require('https'); const axios = require('axios'); -const logger = require('../logger'); +const { isDefinedAndNotNull } = require('@rudderstack/integrations-lib'); const stats = require('../util/stats'); -const { removeUndefinedValues, isDefinedAndNotNullAndNotEmpty } = require('../v0/util'); +const { + removeUndefinedValues, + getErrorStatusCode, + isDefinedAndNotNullAndNotEmpty, +} = require('../v0/util'); +const logger = require('../logger'); const { processAxiosResponse } = require('./utils/networkUtils'); // Only for tests const { setResponsesForMockAxiosAdapter } = require('../../test/testHelper'); @@ -83,7 +88,9 @@ const fireHTTPStats = (clientResponse, startTime, statTags) => { const endpointPath = statTags.endpointPath ? statTags.endpointPath : ''; const requestMethod = statTags.requestMethod ? statTags.requestMethod : ''; const module = statTags.module ? statTags.module : ''; - const statusCode = clientResponse.success ? clientResponse.response.status : ''; + const statusCode = clientResponse.success + ? clientResponse.response.status + : getErrorStatusCode(clientResponse.response); const defArgs = { destType, endpointPath, @@ -94,9 +101,9 @@ const fireHTTPStats = (clientResponse, startTime, statTags) => { startTime, clientResponse, }; - if (statTags?.metadata) { + if (statTags?.metadata && typeof statTags?.metadata === 'object') { const metadata = !Array.isArray(statTags?.metadata) ? [statTags.metadata] : statTags.metadata; - metadata?.forEach((m) => { + metadata?.filter(isDefinedAndNotNull)?.forEach((m) => { fireOutgoingReqStats({ ...defArgs, metadata: m, @@ -448,4 +455,5 @@ module.exports = { getFormData, handleHttpRequest, enhanceRequestOptions, + fireHTTPStats, }; diff --git a/src/adapters/network.test.js b/src/adapters/network.test.js index 5f5ad97437..7894925ccd 100644 --- a/src/adapters/network.test.js +++ b/src/adapters/network.test.js @@ -1,8 +1,17 @@ const mockLoggerInstance = { info: jest.fn(), }; -const { getFormData, httpPOST, httpGET, httpSend } = require('./network'); +const { getFormData, httpPOST, httpGET, httpSend, fireHTTPStats } = require('./network'); const { getFuncTestData } = require('../../test/testHelper'); +jest.mock('../util/stats', () => ({ + timing: jest.fn(), + timingSummary: jest.fn(), + increment: jest.fn(), + counter: jest.fn(), + gauge: jest.fn(), + histogram: jest.fn(), +})); +const stats = require('../util/stats'); jest.mock('@rudderstack/integrations-lib', () => { return { @@ -39,6 +48,308 @@ describe(`${funcName} Tests`, () => { }); }); +describe('fireHTTPStats tests', () => { + beforeEach(() => { + stats.timing.mockClear(); + stats.counter.mockClear(); + }); + it('should not throw error when metadata is sent as correctly defined object', () => { + const clientResponse = { + success: true, + response: { + data: { a: 1, b: 2 }, + status: 200, + headers: { 'Content-Type': 'application/json' }, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: { + destType: 'DT', + destinationId: 'd1', + workspaceId: 'w1', + sourceId: 's1', + }, + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + expect(stats.timing).toHaveBeenCalledTimes(1); + expect(stats.timing).toHaveBeenNthCalledWith(1, 'outgoing_request_latency', startTime, { + destinationId: 'd1', + workspaceId: 'w1', + sourceId: 's1', + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + }); + it('should not throw error when metadata is sent as correctly defined object[]', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: [ + { + destType: 'DT', + destinationId: 'd1', + workspaceId: 'w1', + jobId: 1, + sourceId: 's1', + }, + { + destType: 'DT', + jobId: 2, + destinationId: 'd1', + workspaceId: 'w2', + sourceId: 's2', + }, + ], + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(2); + expect(stats.timing).toHaveBeenNthCalledWith(1, 'outgoing_request_latency', startTime, { + destinationId: 'd1', + workspaceId: 'w1', + sourceId: 's1', + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + expect(stats.timing).toHaveBeenNthCalledWith(2, 'outgoing_request_latency', startTime, { + destinationId: 'd1', + workspaceId: 'w2', + sourceId: 's2', + destType: 'DT', + module: '', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }); + }); + it('should not throw error when metadata is not sent', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(1); + expect(stats.timing).toHaveBeenNthCalledWith(1, 'outgoing_request_latency', startTime, { + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + }); + it('should not throw error when metadata is sent as empty array', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: [], + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(0); + }); + it('should not throw error when metadata is sent as empty object', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: {}, + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(1); + expect(stats.timing).toHaveBeenNthCalledWith(1, 'outgoing_request_latency', startTime, { + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + }); + it('should not throw error when metadata is sent as [null, null]', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: [null, null], + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(0); + }); + it('should not throw error when metadata is sent as [1, 2]', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: [1, 2], + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(2); + expect(stats.timing).toHaveBeenNthCalledWith(1, 'outgoing_request_latency', startTime, { + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + expect(stats.timing).toHaveBeenNthCalledWith(2, 'outgoing_request_latency', startTime, { + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + }); + it('should not throw error when metadata is sent as 1', () => { + const clientResponse = { + success: false, + response: { + response: { + data: { errors: [{ e: 'something went bad' }] }, + status: 400, + headers: { 'Content-Type': 'application/json' }, + }, + headers: { 'Content-Type': 'application/json' }, + status: 400, + }, + }; + const startTime = new Date(); + const statTags = { + metadata: 1, + destType: 'DT', + feature: 'feat', + endpointPath: '/some/url', + requestMethod: 'post', + }; + expect(() => { + fireHTTPStats(clientResponse, startTime, statTags); + }).not.toThrow(Error); + + expect(stats.timing).toHaveBeenCalledTimes(1); + expect(stats.timing).toHaveBeenNthCalledWith(1, 'outgoing_request_latency', startTime, { + destType: 'DT', + feature: 'feat', + module: '', + endpointPath: '/some/url', + requestMethod: 'post', + }); + }); +}); + describe('logging in http methods', () => { beforeEach(() => { mockLoggerInstance.info.mockClear(); diff --git a/src/cdk/v1/autopilot/config.yaml b/src/cdk/v1/autopilot/config.yaml deleted file mode 100644 index c6cccd59d6..0000000000 --- a/src/cdk/v1/autopilot/config.yaml +++ /dev/null @@ -1,33 +0,0 @@ -message: - supportedMessageTypes: - - identify - - track - identify: - transformation: - mapperPath: ./mapping/identify.yaml - postMapper: - name: 'identifyPostMapper' - response: - endpoint: 'https://api2.autopilothq.com/v1/contact' - method: POST - format: JSON - headers: - Accept: 'application/json' - autopilotapikey: '{{ destConfig.apiKey }}' - Content-Type: 'application/json' - userId: '{{ message.anonymousId }}' - - track: - transformation: - mapperPath: ./mapping/track.yaml - postMapper: - name: 'trackPostMapper' - response: - endpoint: '{{ rudderContext.endpoint }}' - method: POST - format: JSON - headers: - Accept: 'application/json' - autopilotapikey: '{{ destConfig.apiKey }}' - Content-Type: 'application/json' - userId: '{{ message.anonymousId }}' diff --git a/src/cdk/v1/autopilot/mapping/identify.yaml b/src/cdk/v1/autopilot/mapping/identify.yaml deleted file mode 100644 index a460907b7e..0000000000 --- a/src/cdk/v1/autopilot/mapping/identify.yaml +++ /dev/null @@ -1,38 +0,0 @@ -- destKey: Email - sourceKeys: - - traits.email - - context.traits.email - -- destKey: FirstName - sourceKeys: - - traits.firstName - - context.traits.firstName - - traits.firstname - - context.traits.firstname - -- destKey: LastName - sourceKeys: - - traits.lastName - - context.traits.lastName - - traits.lastname - - context.traits.lastname - -- destKey: Phone - sourceKeys: - - traits.phone - - context.traits.phone - -- destKey: Company - sourceKeys: - - traits.company.name - - context.traits.company.name - -- destKey: Status - sourceKeys: - - traits.status - - context.traits.status - -- destKey: LeadSource - sourceKeys: - - traits.LeadSource - - context.traits.LeadSource diff --git a/src/cdk/v1/autopilot/mapping/track.yaml b/src/cdk/v1/autopilot/mapping/track.yaml deleted file mode 100644 index 0315d2bcda..0000000000 --- a/src/cdk/v1/autopilot/mapping/track.yaml +++ /dev/null @@ -1,2 +0,0 @@ -- destKey: property - sourceKeys: properties diff --git a/src/cdk/v1/autopilot/transform.js b/src/cdk/v1/autopilot/transform.js deleted file mode 100644 index b27e50f096..0000000000 --- a/src/cdk/v1/autopilot/transform.js +++ /dev/null @@ -1,55 +0,0 @@ -const { Utils } = require('rudder-transformer-cdk'); -const { InstrumentationError } = require('@rudderstack/integrations-lib'); - -function identifyPostMapper(event, mappedPayload) { - const { message } = event; - const payload = mappedPayload; - - // better to outsource constants like this in a separate file - const identifyFields = [ - 'email', - 'firstname', - 'firstName', - 'lastname', - 'lastName', - 'phone', - 'company', - 'status', - 'LeadSource', - ]; - - let responseBody; - const customPayload = message.traits || message.context.traits || {}; - identifyFields.forEach((value) => { - delete customPayload[value]; - }); - if (Object.keys(customPayload).length > 0) { - responseBody = { - contact: { ...payload, custom: customPayload }, - }; - } else { - responseBody = { - contact: { ...payload }, - }; - } - return responseBody; // this flows onto the next stage in the yaml -} - -function trackPostMapper(event, mappedPayload, rudderContext) { - const { message, destination } = event; - - const contactIdOrEmail = Utils.getFieldValueFromMessage(message, 'email'); - if (contactIdOrEmail) { - // eslint-disable-next-line no-param-reassign - rudderContext.endpoint = `https://api2.autopilothq.com/v1/trigger/${destination.Config.triggerId}/contact/${contactIdOrEmail}`; - } else { - throw new InstrumentationError('Email is required for track calls'); - } - // The plan is to delete the rudderResponse property from the mappedPayload finally - // While removing the rudderResponse property, we'd need to do a deep-clone of rudderProperty first - // And then go ahead with `rudderResponse` property - // This `rudderResponse` property has to be combined with transformation mentioned `response` tag in config.yaml - return mappedPayload; // this flows onto the next stage in the yaml -} - -module.exports = { identifyPostMapper, trackPostMapper }; diff --git a/src/cdk/v1/dcm_floodlight/config.js b/src/cdk/v1/dcm_floodlight/config.js deleted file mode 100644 index ce7ab69902..0000000000 --- a/src/cdk/v1/dcm_floodlight/config.js +++ /dev/null @@ -1,5 +0,0 @@ -const BASE_URL = 'https://ad.doubleclick.net/ddm/activity/'; - -const BLACKLISTED_CHARACTERS = ['"', '<', '>', '#']; - -module.exports = { BASE_URL, BLACKLISTED_CHARACTERS }; diff --git a/src/cdk/v1/dcm_floodlight/config.yaml b/src/cdk/v1/dcm_floodlight/config.yaml deleted file mode 100644 index cac23f66d3..0000000000 --- a/src/cdk/v1/dcm_floodlight/config.yaml +++ /dev/null @@ -1,26 +0,0 @@ -message: - supportedMessageTypes: - - track - - page - track: - transformation: - mapperPath: ./mapping/DCMFloodlightConfig.yaml - postMapper: - name: 'postMapper' - response: - endpoint: '{{ rudderContext.endpoint }}' - method: GET - format: JSON - headers: - User-Agent: '{{ rudderContext.userAgent }}' - page: - transformation: - mapperPath: ./mapping/DCMFloodlightConfig.yaml - postMapper: - name: 'postMapper' - response: - endpoint: '{{ rudderContext.endpoint }}' - method: GET - format: JSON - headers: - User-Agent: '{{ rudderContext.userAgent }}' diff --git a/src/cdk/v1/dcm_floodlight/mapping/DCMFloodlightConfig.yaml b/src/cdk/v1/dcm_floodlight/mapping/DCMFloodlightConfig.yaml deleted file mode 100644 index 6126dac5c7..0000000000 --- a/src/cdk/v1/dcm_floodlight/mapping/DCMFloodlightConfig.yaml +++ /dev/null @@ -1,21 +0,0 @@ -- destKey: dc_rdid - sourceKeys: context.device.advertisingId - required: true - -- destKey: ord - sourceKeys: - - properties.orderId - - properties.order_id - required: false - -- destKey: qty - sourceKeys: properties.quantity - required: false - -- destKey: cost - sourceKeys: properties.revenue - required: false - -- destKey: dc_lat - sourceKeys: context.device.adTrackingEnabled - required: false diff --git a/src/cdk/v1/dcm_floodlight/transform.js b/src/cdk/v1/dcm_floodlight/transform.js deleted file mode 100644 index bb93333745..0000000000 --- a/src/cdk/v1/dcm_floodlight/transform.js +++ /dev/null @@ -1,211 +0,0 @@ -/* eslint-disable no-param-reassign */ -const get = require('get-value'); -const lodash = require('lodash'); -const { - removeUndefinedAndNullValues, - isDefinedAndNotNull, -} = require('rudder-transformer-cdk/build/utils'); -const { ConfigurationError, InstrumentationError } = require('@rudderstack/integrations-lib'); -const { - getIntegrationsObj, - isEmpty, - isEmptyObject, - getValueFromPropertiesOrTraits, - getHashFromArray, -} = require('../../../v0/util'); -const { GENERIC_TRUE_VALUES, GENERIC_FALSE_VALUES } = require('../../../constants'); -const { BASE_URL, BLACKLISTED_CHARACTERS } = require('./config'); - -// append properties to endpoint -// eg: ${BASE_URL}key1=value1;key2=value2;.... -const appendProperties = (payload) => { - let endpoint = ''; - endpoint += Object.keys(payload) - .map((key) => `${key}=${payload[key]}`) - .join(';'); - - return endpoint; -}; - -// transform webapp dynamicForm custom floodlight variable -// into {property1: u1, property2: u2, ...} -// Ref - https://support.google.com/campaignmanager/answer/2823222?hl=en -const transformCustomVariable = (customFloodlightVariable, message) => { - const customVariable = {}; - const customMapping = getHashFromArray(customFloodlightVariable, 'from', 'to', false); - - Object.keys(customMapping).forEach((key) => { - // it takes care of getting the value in the order. - // returns null if not present - const itemValue = getValueFromPropertiesOrTraits({ - message, - key, - }); - - if ( - // the value is not null - !lodash.isNil(itemValue) && - // the value is string and doesn't have any blacklisted characters - !( - typeof itemValue === 'string' && BLACKLISTED_CHARACTERS.some((k) => itemValue.includes(k)) - ) && - // boolean values are not supported - typeof itemValue !== 'boolean' - ) { - customVariable[`u${customMapping[key].replace(/u/g, '')}`] = encodeURIComponent(itemValue); - } - }); - - return customVariable; -}; - -// valid flag should be provided [1|true] or [0|false] -const mapFlagValue = (key, value) => { - if (GENERIC_TRUE_VALUES.includes(value.toString())) { - return 1; - } - if (GENERIC_FALSE_VALUES.includes(value.toString())) { - return 0; - } - - throw new InstrumentationError(`${key}: valid parameters are [1|true] or [0|false]`); -}; - -/** - * postMapper does the processing after we do the initial mapping - * defined in mapping/*.yaml - * @param {*} input - * @param {*} mappedPayload - * @param {*} rudderContext - * @returns - */ -const postMapper = (input, mappedPayload, rudderContext) => { - const { message, destination } = input; - const { advertiserId, conversionEvents } = destination.Config; - let { activityTag, groupTag } = destination.Config; - let customFloodlightVariable; - let salesTag; - - let event; - // for page() take event from name and category - if (message.type.toLowerCase() === 'page') { - const { category } = message.properties; - const { name } = message || message.properties; - - if (category && name) { - message.event = `Viewed ${category} ${name} Page`; - } else if (category) { - // categorized pages - message.event = `Viewed ${category} Page`; - } else if (name) { - // named pages - message.event = `Viewed ${name} Page`; - } else { - message.event = 'Viewed Page'; - } - } - - event = message.event; - - if (!event) { - throw new InstrumentationError(`${message.type}:: event is required`); - } - - const userAgent = get(message, 'context.userAgent'); - if (!userAgent) { - throw new InstrumentationError(`${message.type}:: userAgent is required`); - } - rudderContext.userAgent = userAgent; - - // find conversion event - // some() stops execution if at least one condition is passed and returns bool - event = event.trim().toLowerCase(); - const conversionEventFound = conversionEvents.some((conversionEvent) => { - if ( - conversionEvent && - conversionEvent.eventName && - conversionEvent.eventName.trim().toLowerCase() === event - ) { - if ( - !isEmpty(conversionEvent.floodlightActivityTag) && - !isEmpty(conversionEvent.floodlightGroupTag) - ) { - activityTag = conversionEvent.floodlightActivityTag.trim(); - groupTag = conversionEvent.floodlightGroupTag.trim(); - } - salesTag = conversionEvent.salesTag; - customFloodlightVariable = conversionEvent.customVariables || []; - return true; - } - return false; - }); - - if (!conversionEventFound) { - throw new ConfigurationError(`${message.type}:: Conversion event not found`); - } - - // Ref - https://support.google.com/displayvideo/answer/6040012?hl=en - customFloodlightVariable = transformCustomVariable(customFloodlightVariable, message); - mappedPayload = { - src: advertiserId, - cat: activityTag, - type: groupTag, - ...mappedPayload, - }; - - if (salesTag) { - // sums quantity from products array or fallback to properties.quantity - const products = get(message, 'properties.products'); - if (!isEmpty(products) && Array.isArray(products)) { - const quantities = products.reduce((accumulator, product) => { - if (product.quantity) { - return accumulator + product.quantity; - } - return accumulator; - }, 0); - if (quantities) { - mappedPayload.qty = quantities; - } - } - } else { - // for counter tag - mappedPayload.ord = get(message, 'messageId'); - delete mappedPayload.qty; - delete mappedPayload.cost; - } - - // COPPA, GDPR, npa must be provided inside integration object ("DCM FLoodlight") - // Ref - https://support.google.com/displayvideo/answer/6040012?hl=en - const integrationsObj = getIntegrationsObj(message, 'dcm_floodlight'); - if (integrationsObj) { - if (isDefinedAndNotNull(integrationsObj.COPPA)) { - mappedPayload.tag_for_child_directed_treatment = mapFlagValue('COPPA', integrationsObj.COPPA); - } - - if (isDefinedAndNotNull(integrationsObj.GDPR)) { - mappedPayload.tfua = mapFlagValue('GDPR', integrationsObj.GDPR); - } - - if (isDefinedAndNotNull(integrationsObj.npa)) { - mappedPayload.npa = mapFlagValue('npa', integrationsObj.npa); - } - } - - if (isDefinedAndNotNull(mappedPayload.dc_lat)) { - mappedPayload.dc_lat = mapFlagValue('dc_lat', mappedPayload.dc_lat); - } - - mappedPayload = removeUndefinedAndNullValues(mappedPayload); - customFloodlightVariable = removeUndefinedAndNullValues(customFloodlightVariable); - - let dcmEndpoint = `${BASE_URL}${appendProperties(mappedPayload)}`; - if (!isEmptyObject(customFloodlightVariable)) { - dcmEndpoint = `${dcmEndpoint};${appendProperties(customFloodlightVariable)}`; - } - - rudderContext.endpoint = dcmEndpoint; - - return {}; -}; - -module.exports = { postMapper }; diff --git a/src/cdk/v1/handler.js b/src/cdk/v1/handler.js deleted file mode 100644 index 0af0859f49..0000000000 --- a/src/cdk/v1/handler.js +++ /dev/null @@ -1,85 +0,0 @@ -const { ConfigFactory, Executor } = require('rudder-transformer-cdk'); -const { CustomError } = require('rudder-transformer-cdk/build/error'); -const { TRANSFORMER_METRIC } = require('rudder-transformer-cdk/build/constants'); -const path = require('path'); - -const basePath = path.resolve(__dirname); -ConfigFactory.init({ basePath, loggingMode: 'production' }); - -const { - InstrumentationError, - TransformationError, - ConfigurationError, -} = require('@rudderstack/integrations-lib'); -const tags = require('../../v0/util/tags'); -const { generateErrorObject } = require('../../v0/util'); - -const defTags = { - [tags.TAG_NAMES.IMPLEMENTATION]: tags.IMPLEMENTATIONS.CDK_V1, -}; - -/** - * Translates CDK errors into transformer errors - * @param {} err The error object - * @returns An error type which the transformer recognizes - */ -function getErrorInfo(err) { - if (err instanceof CustomError) { - let errInstance = ''; - switch (err.statTags?.meta) { - case TRANSFORMER_METRIC.MEASUREMENT_TYPE.CDK.META.BAD_CONFIG: - errInstance = new TransformationError( - `Bad transformer configuration file. Original error: ${err.message}`, - ); - break; - - case TRANSFORMER_METRIC.MEASUREMENT_TYPE.CDK.META.CONFIGURATION: - errInstance = new ConfigurationError(`Bad configuration. Original error: ${err.message}`); - break; - - case TRANSFORMER_METRIC.MEASUREMENT_TYPE.CDK.META.TF_FUNC: - errInstance = new TransformationError( - `Bad pre/post transformation function. Original error: ${err.message}`, - ); - break; - - case TRANSFORMER_METRIC.MEASUREMENT_TYPE.CDK.META.BAD_EVENT: - case TRANSFORMER_METRIC.MEASUREMENT_TYPE.CDK.META.INSTRUMENTATION: - errInstance = new InstrumentationError(`Bad event. Original error: ${err.message}`); - break; - - case TRANSFORMER_METRIC.MEASUREMENT_TYPE.CDK.META.EXCEPTION: - errInstance = new TransformationError( - `Unknown error occurred. Original error: ${err.message}`, - ); - break; - default: - break; - } - if (err.statTags.scope === TRANSFORMER_METRIC.MEASUREMENT_TYPE.EXCEPTION.SCOPE) { - errInstance = new TransformationError( - `Unknown error occurred. Original error: ${err.message}`, - ); - } - if (errInstance) { - return generateErrorObject(errInstance, defTags); - } - } - - return generateErrorObject(err, defTags); -} - -async function processCdkV1(destType, parsedEvent) { - try { - const tfConfig = await ConfigFactory.getConfig(destType); - const respEvents = await Executor.execute(parsedEvent, tfConfig); - return respEvents; - } catch (error) { - throw getErrorInfo(error); - } -} - -module.exports = { - processCdkV1, - getErrorInfo, -}; diff --git a/src/cdk/v1/heap/config.yaml b/src/cdk/v1/heap/config.yaml deleted file mode 100644 index da6a2dfe28..0000000000 --- a/src/cdk/v1/heap/config.yaml +++ /dev/null @@ -1,28 +0,0 @@ -message: - identify: - transformation: - mapperPath: ./mapping/identify.yaml - postMapper: - name: 'commonPostMapper' - response: - method: POST - format: JSON - endpoint: 'https://heapanalytics.com/api/add_user_properties' - userId: '{{ message.anonymousId }}' - headers: - Accept: 'application/json' - Content-Type: 'application/json' - - track: - transformation: - mapperPath: ./mapping/track.yaml - postMapper: - name: 'commonPostMapper' - response: - method: POST - format: JSON - endpoint: 'https://heapanalytics.com/api/track' - userId: '{{ message.anonymousId }}' - headers: - Accept: 'application/json' - Content-Type: 'application/json' diff --git a/src/cdk/v1/heap/mapping/identify.yaml b/src/cdk/v1/heap/mapping/identify.yaml deleted file mode 100644 index 6b9a237943..0000000000 --- a/src/cdk/v1/heap/mapping/identify.yaml +++ /dev/null @@ -1,17 +0,0 @@ -- destKey: identity - sourceKeys: - - userId - - traits.userId - - traits.id - - context.traits.userId - - context.traits.id - - anonymousId - required: true - -- destKey: properties - sourceKeys: - - traits - - context.traits - metadata: - type: flatJson - required: true diff --git a/src/cdk/v1/heap/mapping/track.yaml b/src/cdk/v1/heap/mapping/track.yaml deleted file mode 100644 index e0ffa2b9a5..0000000000 --- a/src/cdk/v1/heap/mapping/track.yaml +++ /dev/null @@ -1,28 +0,0 @@ -- destKey: identity - sourceKeys: - - userId - - traits.userId - - traits.id - - context.traits.userId - - context.traits.id - - anonymousId - required: true - -- destKey: event - sourceKeys: event - required: true - -- destKey: properties - sourceKeys: properties - metadata: - type: flatJson - -- destKey: timestamp - sourceKeys: - - timestamp - - originalTimestamp - required: false - -- destKey: idempotency_key - sourceKeys: properties.idempotencyKey - required: false diff --git a/src/cdk/v1/heap/transform.js b/src/cdk/v1/heap/transform.js deleted file mode 100644 index 120af3ef90..0000000000 --- a/src/cdk/v1/heap/transform.js +++ /dev/null @@ -1,15 +0,0 @@ -async function commonPostMapper(event, mappedPayload) { - const { destination } = event; - const payload = mappedPayload; - if (payload.properties && payload.properties.idempotencyKey) { - delete payload.properties.idempotencyKey; - } - const responseBody = { - ...payload, - app_id: destination.Config.appId, - }; - - return responseBody; // this flows onto the next stage in the yaml -} - -module.exports = { commonPostMapper }; diff --git a/src/cdk/v1/kochava/config.yaml b/src/cdk/v1/kochava/config.yaml deleted file mode 100644 index 90ae837fae..0000000000 --- a/src/cdk/v1/kochava/config.yaml +++ /dev/null @@ -1,15 +0,0 @@ -message: - supportedMessageTypes: - - screen - - track - default: - transformation: - mapperPath: ./mappings/default.yaml - postMapper: - name: processExtraPayloadParams - response: - endpoint: https://control.kochava.com/track/json - userId: '{{ message.anonymousId }}' - format: JSON - method: POST - headers: {} diff --git a/src/cdk/v1/kochava/mappings/default.yaml b/src/cdk/v1/kochava/mappings/default.yaml deleted file mode 100644 index c17292d40f..0000000000 --- a/src/cdk/v1/kochava/mappings/default.yaml +++ /dev/null @@ -1,49 +0,0 @@ -- destKey: data.event_data - sourceKeys: - - properties - metadata: - defaultValue: {} - -- destKey: kochava_app_id - sourceKeys: apiKey - context: destConfig - -- destKey: kochava_device_id - sourceKeys: - - context.device.id - - anonymousId - -- destKey: data.usertime - sourceKeys: - - timestamp - - originalTimestamp - metadata: - type: timestamp - -- destKey: data.app_version - sourceKeys: context.app.build - -- destKey: data.origination_ip - sourceKeys: - - context.ip - - request_ip - -- destKey: data.app_name - sourceKeys: context.app.name - -- destKey: data.app_short_string - sourceKeys: context.app.version - -- destKey: data.locale - sourceKeys: context.locale - -- destKey: data.os_version - sourceKeys: context.os.version - -- destKey: data.screen_dpi - sourceKeys: context.screen.density - -- destKey: action - sourceKeys: rudderAction # This will not be available - metadata: - defaultValue: 'event' diff --git a/src/cdk/v1/kochava/transform.js b/src/cdk/v1/kochava/transform.js deleted file mode 100644 index 504981aa6a..0000000000 --- a/src/cdk/v1/kochava/transform.js +++ /dev/null @@ -1,78 +0,0 @@ -const { Utils } = require('rudder-transformer-cdk'); - -const eventNameMapping = { - 'product added': 'Add to Cart', - 'product added to wishlist': 'Add to Wishlist', - 'checkout started': 'Checkout Start', - 'order completed': 'Purchase', - 'product reviewed': 'Rating', - 'products searched': 'Search', -}; - -function processExtraPayloadParams(event, mappedPayload) { - const clonedMappedPayload = { ...mappedPayload }; - const { message } = event; - let eventName = message.event; - const eventData = message.properties || {}; - switch (message.type.toLowerCase()) { - case 'screen': - eventName = 'screen view'; - if (message.properties && message.properties.name) { - eventName += ` ${message.properties.name}`; - } - break; - case 'track': - if (eventName) { - const evName = eventName.toLowerCase(); - if (eventNameMapping[evName] !== undefined) { - eventName = eventNameMapping[evName]; - } - } - break; - default: - break; - } - - const extraParams = { - // This kind of formatting multiple fields into a single one - // is currently not supported in cdk - app_tracking_transparency: { - att: message.context?.device?.attTrackingStatus === 3 || false, - }, - device_ver: - message.context?.device?.model && message.context?.os?.version - ? `${message.context?.device?.model}-${message.context?.os?.name}-${message.context?.os?.version}` - : '', - device_ids: { - idfa: - message.context?.os?.name && Utils.isAppleFamily(message.context?.os?.name) - ? message.context?.device?.advertisingId || '' - : '', - idfv: - message.context?.os?.name && Utils.isAppleFamily(message.context?.os?.name) - ? message.context?.device?.id || message.anonymousId || '' - : '', - adid: - message.context?.os?.name && message.context.os.name.toLowerCase() === 'android' - ? message.context?.device?.advertisingId || '' - : '', - android_id: - message.context?.os?.name && message.context.os.name.toLowerCase() === 'android' - ? message.context?.device?.id || message.anonymousId || '' - : '', - }, - event_name: eventName, - device_ua: message.context?.userAgent || '', - currency: eventData?.currency || 'USD', - }; - clonedMappedPayload.data = { ...clonedMappedPayload.data, ...extraParams }; - // Note: "defaultValue" cannot be empty string hence had to manually set it here since kochava requires it - if (Utils.getValueFromMessage(message, 'context.os.version') === '') { - clonedMappedPayload.data.os_version = ''; - } - return clonedMappedPayload; -} - -module.exports = { - processExtraPayloadParams, -}; diff --git a/src/cdk/v1/lytics/config.yaml b/src/cdk/v1/lytics/config.yaml deleted file mode 100644 index 14f2f79ddb..0000000000 --- a/src/cdk/v1/lytics/config.yaml +++ /dev/null @@ -1,53 +0,0 @@ -message: - supportedMessageTypes: - - identify - - page - - screen - - track - identify: - transformation: - mapperPath: ./mappings/identify.yaml - postMapper: - name: cleanResponse - response: - endpoint: 'https://api.lytics.io/collect/json/{{destConfig.stream}}?access_token={{destConfig.apiKey}}' - method: POST - format: JSON - headers: - Content-Type: application/json - - page: - transformation: - mapperPath: ./mappings/page-screen.yaml - postMapper: - name: cleanResponse - response: - endpoint: 'https://api.lytics.io/collect/json/{{destConfig.stream}}?access_token={{destConfig.apiKey}}' - method: POST - format: JSON - headers: - Content-Type: application/json - - screen: - transformation: - mapperPath: ./mappings/page-screen.yaml - postMapper: - name: cleanResponse - response: - endpoint: 'https://api.lytics.io/collect/json/{{destConfig.stream}}?access_token={{destConfig.apiKey}}' - method: POST - format: JSON - headers: - Content-Type: application/json - - track: - transformation: - mapperPath: ./mappings/track.yaml - postMapper: - name: cleanResponse - response: - endpoint: 'https://api.lytics.io/collect/json/{{destConfig.stream}}?access_token={{destConfig.apiKey}}' - method: POST - format: JSON - headers: - Content-Type: application/json diff --git a/src/cdk/v1/lytics/mappings/identify.yaml b/src/cdk/v1/lytics/mappings/identify.yaml deleted file mode 100644 index 388660c3c4..0000000000 --- a/src/cdk/v1/lytics/mappings/identify.yaml +++ /dev/null @@ -1,29 +0,0 @@ -- destKey: user_id - sourceKeys: - - 'userId' - - 'traits.userId' - - 'traits.id' - - 'context.traits.userId' - - 'context.traits.id' - - 'anonymousId' - -- destKey: '...' - sourceKeys: - - 'traits' - - 'context.traits' - metadata: - type: flatJson - -- destKey: first_name - sourceKeys: - - traits.firstName - - traits.firstname - - context.traits.firstName - - context.traits.firstname - -- destKey: last_name - sourceKeys: - - traits.lastName - - traits.lastname - - context.traits.lastName - - context.traits.lastname diff --git a/src/cdk/v1/lytics/mappings/page-screen.yaml b/src/cdk/v1/lytics/mappings/page-screen.yaml deleted file mode 100644 index 78fada65f0..0000000000 --- a/src/cdk/v1/lytics/mappings/page-screen.yaml +++ /dev/null @@ -1,17 +0,0 @@ -- destKey: event - sourceKeys: name - -- destKey: '...' - sourceKeys: properties - metadata: - type: flatJson - -- destKey: first_name - sourceKeys: - - properties.firstName - - properties.firstname - -- destKey: last_name - sourceKeys: - - properties.lastName - - properties.lastname diff --git a/src/cdk/v1/lytics/mappings/track.yaml b/src/cdk/v1/lytics/mappings/track.yaml deleted file mode 100644 index fdc24f16fc..0000000000 --- a/src/cdk/v1/lytics/mappings/track.yaml +++ /dev/null @@ -1,17 +0,0 @@ -- destKey: _e - sourceKeys: event - -- destKey: '...' - sourceKeys: properties - metadata: - type: flatJson - -- destKey: first_name - sourceKeys: - - properties.firstName - - properties.firstname - -- destKey: last_name - sourceKeys: - - properties.lastName - - properties.lastname diff --git a/src/cdk/v1/lytics/transform.js b/src/cdk/v1/lytics/transform.js deleted file mode 100644 index e31d0733c6..0000000000 --- a/src/cdk/v1/lytics/transform.js +++ /dev/null @@ -1,23 +0,0 @@ -const { Utils } = require('rudder-transformer-cdk'); - -const forFirstName = ['firstname', 'firstName']; -const forLastName = ['lastname', 'lastName']; - -function cleanResponse(event, mappedPayload) { - // Here basically we have a requirement wherein - // we have to remove certain properties from the final payload - const flattenedPayload = Utils.removeUndefinedAndNullValues(mappedPayload); - forFirstName.forEach((key) => { - if (flattenedPayload[key]) { - delete flattenedPayload[key]; - } - }); - forLastName.forEach((key) => { - if (flattenedPayload[key]) { - delete flattenedPayload[key]; - } - }); - return flattenedPayload; -} - -module.exports = { cleanResponse }; diff --git a/src/cdk/v1/new_relic/config.yaml b/src/cdk/v1/new_relic/config.yaml deleted file mode 100644 index d6f04b989f..0000000000 --- a/src/cdk/v1/new_relic/config.yaml +++ /dev/null @@ -1,15 +0,0 @@ -message: - supportedMessageTypes: - - track - track: - transformation: - mapperPath: ./mapping/track.yaml - postMapper: - name: 'commonPostMapper' - response: - endpoint: '{{ rudderContext.endpoint }}' - method: POST - format: JSON - headers: - Api-Key: '{{ rudderContext.insertKey }}' - Content-Type: 'application/json' diff --git a/src/cdk/v1/new_relic/mapping/track.yaml b/src/cdk/v1/new_relic/mapping/track.yaml deleted file mode 100644 index 6a4a9f04f3..0000000000 --- a/src/cdk/v1/new_relic/mapping/track.yaml +++ /dev/null @@ -1,14 +0,0 @@ -- destKey: 'event' - sourceKeys: event - -- destKey: '...' - sourceKeys: properties - metadata: - type: flatJson - -- destKey: 'timestamp' - sourceKeys: - - 'timestamp' - - 'originalTimestamp' - metadata: - type: 'secondTimestamp' diff --git a/src/cdk/v1/new_relic/transform.js b/src/cdk/v1/new_relic/transform.js deleted file mode 100644 index 43cebd548f..0000000000 --- a/src/cdk/v1/new_relic/transform.js +++ /dev/null @@ -1,112 +0,0 @@ -/* eslint-disable no-param-reassign */ -const { isBoolean } = require('lodash'); -const { Utils } = require('rudder-transformer-cdk'); - -function commonPostMapper(event, mappedPayload, rudderContext) { - const { message, destination } = event; - const payload = mappedPayload; - const destConfig = destination.Config; - const reservedNrqlWords = [ - 'ago', - 'and', - 'as', - 'auto', - 'begin', - 'begintime', - 'compare', - 'day', - 'days', - 'end', - 'endtime', - 'explain', - 'facet', - 'from', - 'hour', - 'hours', - 'in', - 'is', - 'like', - 'limit', - 'minute', - 'minutes', - 'month', - 'months', - 'not', - 'null', - 'offset', - 'or', - 'raw', - 'second', - 'seconds', - 'select', - 'since', - 'timeseries', - 'until', - 'week', - 'weeks', - 'where', - 'with', - ]; - const reservedWords = ['accountId', 'appId', 'eventType']; - - Object.keys(payload).forEach((item) => { - if (reservedNrqlWords.includes(item) && isBoolean(payload[item])) { - const str = `'${item}'`; - payload[str] = payload[item].toString(); - delete payload[item]; - } else if (reservedNrqlWords.includes(item)) { - const str = `'${item}'`; - payload[str] = payload[item]; - delete payload[item]; - } else if (reservedWords.includes(item)) { - delete payload[item]; - } else if (isBoolean(payload[item])) { - payload[item] = payload[item].toString(); - } - }); - - // If user provided a eventType name, then we will include it in the payload directly - if (destConfig.customEventType) { - payload.eventType = destConfig.customEventType; - } else { - // If eventType is not provided by the user, by default it is 'rudderstack' - payload.eventType = 'rudderstack'; - } - - // If user enables 'sendUserIdanonymousId', then we include userId and anonymousId into the payload - if (destConfig.sendUserIdanonymousId) { - if (message.userId || message.context.userId || message.context.id) { - payload.userId = message.userId; - } - if (message.anonymousId) { - payload.anonymousId = message.anonymousId; - } - } - - // Upon users choice for data center, we are updating the endpoint accordingly - rudderContext.endpoint = - destConfig.dataCenter === 'eu' - ? `https://insights-collector.eu01.nr-data.net/v1/accounts/${destConfig.accountId}/events` - : `https://insights-collector.newrelic.com/v1/accounts/${destConfig.accountId}/events`; - - rudderContext.insertKey = destConfig.insertKey; - - // If user enables 'sendDeviceContext', then we are delimiting context fields and include them in responseBody - let flattenedContext = {}; - let responseBody; - if (destConfig.sendDeviceContext) { - flattenedContext = Utils.flattenJson(message.context); - responseBody = { - ...payload, - ...flattenedContext, - }; - } else { - responseBody = { - ...payload, - }; - } - - return responseBody; // this flows onto the next stage in the yaml -} - -module.exports = { commonPostMapper }; diff --git a/src/cdk/v1/statsig/config.yaml b/src/cdk/v1/statsig/config.yaml deleted file mode 100644 index 467629faa1..0000000000 --- a/src/cdk/v1/statsig/config.yaml +++ /dev/null @@ -1,19 +0,0 @@ -message: - supportedMessageTypes: - - identify - - page - - screen - - alias - - track - - group - default: - transformation: - spreadMessage: true - response: - endpoint: 'https://api.statsig.com/v1/webhooks/rudderstack' - method: POST - # based on the format set, we can formulate - format: JSON - headers: - STATSIG-API-KEY: '{{ destConfig.secretKey }}' - content-type: 'application/json' diff --git a/src/cdk/v1/userlist/config.yaml b/src/cdk/v1/userlist/config.yaml deleted file mode 100644 index 19df913fef..0000000000 --- a/src/cdk/v1/userlist/config.yaml +++ /dev/null @@ -1,19 +0,0 @@ -message: - supportedMessageTypes: - - identify - - track - - group - default: - transformation: - # If the mapping mentioned in this yaml doesn't work - # we can make use of postMapper tag and apply the required transformation - mapperPath: ./mapping/userlist_default.yaml - spreadMessage: true - response: - endpoint: 'https://incoming.userlist.com/rudderstack/events' - method: POST - format: JSON - statusCode: 200 # probably this can be removed also. - headers: - Authorization: 'Push {{destConfig.pushKey}}' - Content-Type: 'application/json' diff --git a/src/cdk/v1/userlist/mapping/userlist_default.yaml b/src/cdk/v1/userlist/mapping/userlist_default.yaml deleted file mode 100644 index 0d9b4acade..0000000000 --- a/src/cdk/v1/userlist/mapping/userlist_default.yaml +++ /dev/null @@ -1,8 +0,0 @@ -- destKey: type - sourceKeys: type - metadata: - type: toLowerCase -- destKey: userId - sourceKeys: userIdOnly - sourceFromGenericMap: true - required: true diff --git a/src/cdk/v1/variance/config.yaml b/src/cdk/v1/variance/config.yaml deleted file mode 100644 index 9a38723206..0000000000 --- a/src/cdk/v1/variance/config.yaml +++ /dev/null @@ -1,13 +0,0 @@ -message: - default: - transformation: - spreadMessage: true - mapperPath: ./mappings/default.yaml - response: - format: JSON - method: POST - endpoint: '{{ destConfig.webhookUrl }}' - headers: - authorization: '{{ destConfig.authHeader }}' - content-type: 'application/json' - userId: '{{ message.anonymousId }}' diff --git a/src/cdk/v1/variance/mappings/default.yaml b/src/cdk/v1/variance/mappings/default.yaml deleted file mode 100644 index 5a23b4a931..0000000000 --- a/src/cdk/v1/variance/mappings/default.yaml +++ /dev/null @@ -1,4 +0,0 @@ -- destKey: context.ip - sourceKeys: - - 'context.ip' - - 'request_ip' diff --git a/src/cdk/v1/vitally/config.yaml b/src/cdk/v1/vitally/config.yaml deleted file mode 100644 index c7edbacca2..0000000000 --- a/src/cdk/v1/vitally/config.yaml +++ /dev/null @@ -1,15 +0,0 @@ -message: - supportedMessageTypes: - - track - - identify - - group - default: - transformation: - spreadMessage: true - response: - format: JSON - method: POST - endpoint: 'https://api.vitally.io/rudderstack' - headers: - authorization: 'Basic {{ destConfig.apiKeyVitally }}' - content-type: 'application/json' diff --git a/src/cdk/v1/zapier/config.yaml b/src/cdk/v1/zapier/config.yaml deleted file mode 100644 index 52f9317587..0000000000 --- a/src/cdk/v1/zapier/config.yaml +++ /dev/null @@ -1,16 +0,0 @@ -message: - supportedMessageTypes: - - track - - page - - screen - default: - transformation: - spreadMessage: true - postMapper: - name: 'commonPostMapper' - response: - format: JSON - method: POST - endpoint: '{{ rudderContext.zapUrl }}' - headers: - content-type: 'application/json' diff --git a/src/cdk/v1/zapier/transform.js b/src/cdk/v1/zapier/transform.js deleted file mode 100644 index d99c3af315..0000000000 --- a/src/cdk/v1/zapier/transform.js +++ /dev/null @@ -1,43 +0,0 @@ -/* eslint-disable no-param-reassign */ -const { getHashFromArray } = require('../../../v0/util'); - -function commonPostMapper(event, mappedPayload, rudderContext) { - const { message, destination } = event; - const destConfig = destination.Config; - - const { trackEventsToZap, pageScreenEventsToZap, zapUrl } = destConfig; - - const trackEventsMap = getHashFromArray(trackEventsToZap); - const pageScreenEventsMap = getHashFromArray(pageScreenEventsToZap); - - // default Zap URL - rudderContext.zapUrl = zapUrl; - - // track event - if (message?.type === 'track') { - const eventName = message?.event; - // checking if the event is present track events mapping - if (trackEventsMap[eventName]) { - // if present, we are updating the zapUrl(with one specified in the mapping) - rudderContext.zapUrl = trackEventsMap[eventName]; - } - } - - // page/screen event - if (message?.type === 'page' || message?.type === 'screen') { - const pageScreenName = message?.name; - // checking if the event is present page/screen events mapping - if (pageScreenEventsMap[pageScreenName]) { - // if present, we are updating the zapUrl(with the one specified in the mapping) - rudderContext.zapUrl = pageScreenEventsMap[pageScreenName]; - } - } - - const responseBody = { - ...mappedPayload, - }; - - return responseBody; // this flows onto the next stage in the yaml -} - -module.exports = { commonPostMapper }; diff --git a/src/cdk/v2/destinations/algolia/procWorkflow.yaml b/src/cdk/v2/destinations/algolia/procWorkflow.yaml index 402b48dabd..44741b5f60 100644 --- a/src/cdk/v2/destinations/algolia/procWorkflow.yaml +++ b/src/cdk/v2/destinations/algolia/procWorkflow.yaml @@ -52,7 +52,7 @@ steps: template: | const products = ^.message.properties.products products.($.removeUndefinedAndNullValues({ - "queryID" : $.isDefinedAndNotNull(.queryID) ? String(.queryID) : null, + "queryID" : $.isDefinedAndNotNull(.queryID || .queryId) ? String(.queryID || .queryId) : null, "price": $.isDefinedAndNotNull(.price) && $.isDefinedAndNotNull(^.message.properties.currency) ? String(.price) : null, "quantity": $.isDefinedAndNotNull(.quantity)? Number(.quantity) : null, "discount": $.isDefinedAndNotNull(.discount) ? String(.discount) : null diff --git a/src/cdk/v2/destinations/bloomreach_catalog/config.ts b/src/cdk/v2/destinations/bloomreach_catalog/config.ts new file mode 100644 index 0000000000..8b469c3cf9 --- /dev/null +++ b/src/cdk/v2/destinations/bloomreach_catalog/config.ts @@ -0,0 +1,31 @@ +export const MAX_PAYLOAD_SIZE = 10000000; +export const MAX_ITEMS = 5000; + +// ref:- https://documentation.bloomreach.com/engagement/reference/bulk-update-catalog-item +export const getCreateBulkCatalogItemEndpoint = ( + apiBaseUrl: string, + projectToken: string, + catalogId: string, +): string => `${apiBaseUrl}/data/v2/projects/${projectToken}/catalogs/${catalogId}/items`; + +// ref:- https://documentation.bloomreach.com/engagement/reference/bulk-partial-update-catalog-item +export const getUpdateBulkCatalogItemEndpoint = ( + apiBaseUrl: string, + projectToken: string, + catalogId: string, +): string => + `${apiBaseUrl}/data/v2/projects/${projectToken}/catalogs/${catalogId}/items/partial-update`; + +// ref:- https://documentation.bloomreach.com/engagement/reference/bulk-delete-catalog-items +export const getDeleteBulkCatalogItemEndpoint = ( + apiBaseUrl: string, + projectToken: string, + catalogId: string, +): string => + `${apiBaseUrl}/data/v2/projects/${projectToken}/catalogs/${catalogId}/items/bulk-delete`; + +export const CatalogAction = { + INSERT: 'insert', + UPDATE: 'update', + DELETE: 'delete', +}; diff --git a/src/cdk/v2/destinations/bloomreach_catalog/rtWorkflow.yaml b/src/cdk/v2/destinations/bloomreach_catalog/rtWorkflow.yaml new file mode 100644 index 0000000000..55809350eb --- /dev/null +++ b/src/cdk/v2/destinations/bloomreach_catalog/rtWorkflow.yaml @@ -0,0 +1,42 @@ +bindings: + - name: EventType + path: ../../../../constants + - name: processRecordInputs + path: ./transformRecord + - name: handleRtTfSingleEventError + path: ../../../../v0/util/index + - name: InstrumentationError + path: '@rudderstack/integrations-lib' + +steps: + - name: validateConfig + template: | + const config = ^[0].destination.Config + $.assertConfig(config.apiBaseUrl, "API Base URL is not present. Aborting"); + $.assertConfig(config.apiKey, "API Key is not present . Aborting"); + $.assertConfig(config.apiSecret, "API Secret is not present. Aborting"); + $.assertConfig(config.projectToken, "Project Token is not present. Aborting"); + $.assertConfig(config.catalogID, "Catalog Id is not present. Aborting"); + + - name: validateInput + template: | + $.assert(Array.isArray(^) && ^.length > 0, "Invalid event array") + + - name: processRecordEvents + template: | + $.processRecordInputs(^.{.message.type === $.EventType.RECORD}[], ^[0].destination) + + - name: failOtherEvents + template: | + const otherEvents = ^.{.message.type !== $.EventType.RECORD}[] + let failedEvents = otherEvents.map( + function(event) { + const error = new $.InstrumentationError("Event type " + event.message.type + " is not supported"); + $.handleRtTfSingleEventError(event, error, {}) + } + ) + failedEvents ?? [] + + - name: finalPayload + template: | + [...$.outputs.processRecordEvents, ...$.outputs.failOtherEvents] diff --git a/src/cdk/v2/destinations/bloomreach_catalog/transformRecord.ts b/src/cdk/v2/destinations/bloomreach_catalog/transformRecord.ts new file mode 100644 index 0000000000..68277448d0 --- /dev/null +++ b/src/cdk/v2/destinations/bloomreach_catalog/transformRecord.ts @@ -0,0 +1,93 @@ +import { InstrumentationError } from '@rudderstack/integrations-lib'; +import { CatalogAction } from './config'; +import { batchResponseBuilder } from './utils'; + +import { handleRtTfSingleEventError, isEmptyObject } from '../../../../v0/util'; + +const prepareCatalogInsertOrUpdatePayload = (fields: any): any => { + // eslint-disable-next-line @typescript-eslint/naming-convention + const { item_id, ...properties } = fields; + return { item_id, properties }; +}; + +const processEvent = (event: any) => { + const { message } = event; + const { fields, action } = message; + const response = { + action, + payload: null, + }; + if (isEmptyObject(fields)) { + throw new InstrumentationError('`fields` cannot be empty'); + } + if (!fields.item_id) { + throw new InstrumentationError('`item_id` cannot be empty'); + } + if (action === CatalogAction.INSERT || action === CatalogAction.UPDATE) { + response.payload = prepareCatalogInsertOrUpdatePayload(fields); + } else if (action === CatalogAction.DELETE) { + response.payload = fields.item_id; + } else { + throw new InstrumentationError( + `Invalid action type ${action}. You can only add, update or remove items from the catalog`, + ); + } + return response; +}; + +const getEventChunks = ( + input: any, + insertItemRespList: any[], + updateItemRespList: any[], + deleteItemRespList: any[], +) => { + switch (input.response.action) { + case CatalogAction.INSERT: + insertItemRespList.push({ payload: input.response.payload, metadata: input.metadata }); + break; + case CatalogAction.UPDATE: + updateItemRespList.push({ payload: input.response.payload, metadata: input.metadata }); + break; + case CatalogAction.DELETE: + deleteItemRespList.push({ payload: input.response.payload, metadata: input.metadata }); + break; + default: + throw new InstrumentationError(`Invalid action type ${input.response.action}`); + } +}; + +export const processRecordInputs = (inputs: any[], destination: any) => { + const insertItemRespList: any[] = []; + const updateItemRespList: any[] = []; + const deleteItemRespList: any[] = []; + const batchErrorRespList: any[] = []; + + if (!inputs || inputs.length === 0) { + return []; + } + + inputs.forEach((input) => { + try { + getEventChunks( + { + response: processEvent(input), + metadata: input.metadata, + }, + insertItemRespList, + updateItemRespList, + deleteItemRespList, + ); + } catch (error) { + const errRespEvent = handleRtTfSingleEventError(input, error, {}); + batchErrorRespList.push(errRespEvent); + } + }); + + const batchSuccessfulRespList = batchResponseBuilder( + insertItemRespList, + updateItemRespList, + deleteItemRespList, + destination, + ); + return [...batchSuccessfulRespList, ...batchErrorRespList]; +}; diff --git a/src/cdk/v2/destinations/bloomreach_catalog/utils.ts b/src/cdk/v2/destinations/bloomreach_catalog/utils.ts new file mode 100644 index 0000000000..0e74ce9379 --- /dev/null +++ b/src/cdk/v2/destinations/bloomreach_catalog/utils.ts @@ -0,0 +1,147 @@ +import { BatchUtils } from '@rudderstack/workflow-engine'; +import { base64Convertor } from '@rudderstack/integrations-lib'; +import { + getCreateBulkCatalogItemEndpoint, + getDeleteBulkCatalogItemEndpoint, + getUpdateBulkCatalogItemEndpoint, + MAX_ITEMS, + MAX_PAYLOAD_SIZE, +} from './config'; + +const buildBatchedRequest = ( + payload: string, + method: string, + endpoint: string, + headers: any, + metadata: any, + destination: any, +) => ({ + batchedRequest: { + body: { + JSON: {}, + JSON_ARRAY: { batch: payload }, + XML: {}, + FORM: {}, + }, + version: '1', + type: 'REST', + method, + endpoint, + headers, + params: {}, + files: {}, + }, + metadata, + batched: true, + statusCode: 200, + destination, +}); + +const getHeaders = (destination: any) => ({ + 'Content-Type': 'application/json', + Authorization: `Basic ${base64Convertor(`${destination.Config.apiKey}:${destination.Config.apiSecret}`)}`, +}); + +// returns merged metadata for a batch +const getMergedMetadata = (batch: any[]) => batch.map((input) => input.metadata); + +// returns merged payload for a batch +const getMergedEvents = (batch: any[]) => batch.map((input) => input.payload); + +// builds final batched response for insert action records +const insertItemBatchResponseBuilder = (insertItemRespList: any[], destination: any) => { + const insertItemBatchedResponse: any[] = []; + + const method = 'PUT'; + const endpoint = getCreateBulkCatalogItemEndpoint( + destination.Config.apiBaseUrl, + destination.Config.projectToken, + destination.Config.catalogID, + ); + const headers = getHeaders(destination); + + const batchesOfEvents = BatchUtils.chunkArrayBySizeAndLength(insertItemRespList, { + maxSizeInBytes: MAX_PAYLOAD_SIZE, + maxItems: MAX_ITEMS, + }); + batchesOfEvents.items.forEach((batch: any) => { + const mergedPayload = JSON.stringify(getMergedEvents(batch)); + const mergedMetadata = getMergedMetadata(batch); + insertItemBatchedResponse.push( + buildBatchedRequest(mergedPayload, method, endpoint, headers, mergedMetadata, destination), + ); + }); + return insertItemBatchedResponse; +}; + +// builds final batched response for update action records +const updateItemBatchResponseBuilder = (updateItemRespList: any[], destination: any) => { + const updateItemBatchedResponse: any[] = []; + + const method = 'POST'; + const endpoint = getUpdateBulkCatalogItemEndpoint( + destination.Config.apiBaseUrl, + destination.Config.projectToken, + destination.Config.catalogID, + ); + const headers = getHeaders(destination); + + const batchesOfEvents = BatchUtils.chunkArrayBySizeAndLength(updateItemRespList, { + maxSizeInBytes: MAX_PAYLOAD_SIZE, + maxItems: MAX_ITEMS, + }); + batchesOfEvents.items.forEach((batch: any) => { + const mergedPayload = JSON.stringify(getMergedEvents(batch)); + const mergedMetadata = getMergedMetadata(batch); + updateItemBatchedResponse.push( + buildBatchedRequest(mergedPayload, method, endpoint, headers, mergedMetadata, destination), + ); + }); + return updateItemBatchedResponse; +}; + +// builds final batched response for delete action records +const deleteItemBatchResponseBuilder = (deleteItemRespList: any[], destination: any) => { + const deleteItemBatchedResponse: any[] = []; + + const method = 'DELETE'; + const endpoint = getDeleteBulkCatalogItemEndpoint( + destination.Config.apiBaseUrl, + destination.Config.projectToken, + destination.Config.catalogID, + ); + const headers = getHeaders(destination); + + const batchesOfEvents = BatchUtils.chunkArrayBySizeAndLength(deleteItemRespList, { + maxSizeInBytes: MAX_PAYLOAD_SIZE, + maxItems: MAX_ITEMS, + }); + batchesOfEvents.items.forEach((batch: any) => { + const mergedPayload = JSON.stringify(getMergedEvents(batch)); + const mergedMetadata = getMergedMetadata(batch); + deleteItemBatchedResponse.push( + buildBatchedRequest(mergedPayload, method, endpoint, headers, mergedMetadata, destination), + ); + }); + return deleteItemBatchedResponse; +}; + +// returns final batched response +export const batchResponseBuilder = ( + insertItemRespList: any, + updateItemRespList: any, + deleteItemRespList: any, + destination: any, +) => { + const response: any[] = []; + if (insertItemRespList.length > 0) { + response.push(...insertItemBatchResponseBuilder(insertItemRespList, destination)); + } + if (updateItemRespList.length > 0) { + response.push(...updateItemBatchResponseBuilder(updateItemRespList, destination)); + } + if (deleteItemRespList.length > 0) { + response.push(...deleteItemBatchResponseBuilder(deleteItemRespList, destination)); + } + return response; +}; diff --git a/src/cdk/v2/destinations/cordial/config.js b/src/cdk/v2/destinations/cordial/config.js new file mode 100644 index 0000000000..74362eb442 --- /dev/null +++ b/src/cdk/v2/destinations/cordial/config.js @@ -0,0 +1,34 @@ +const { getMappingConfig } = require('../../../../v0/util'); + +const getCreateContactEndpoint = (config) => `${config.apiBaseUrl}/v2/contacts`; +const getUpdateContactEndpoint = (config, contactId, email) => { + if (contactId) { + return `${config.apiBaseUrl}/v2/contacts/${contactId}`; + } + return `${config.apiBaseUrl}/v2/contacts/email:${email}`; +}; + +const getEventsEndpoint = (config) => `${config.apiBaseUrl}/v2/contactactivities`; +const getContactEndpoint = getUpdateContactEndpoint; + +const CONFIG_CATEGORIES = { + IDENTIFY: { + name: 'CordialIdentifyConfig', + type: 'identify', + }, + TRACK: { + name: 'CordialTrackConfig', + type: 'track', + }, +}; + +const MAPPING_CONFIG = getMappingConfig(CONFIG_CATEGORIES, __dirname); + +module.exports = { + IDENTIFY_CONFIG: MAPPING_CONFIG[CONFIG_CATEGORIES.IDENTIFY.name], + TRACK_CONFIG: MAPPING_CONFIG[CONFIG_CATEGORIES.TRACK.name], + getCreateContactEndpoint, + getUpdateContactEndpoint, + getEventsEndpoint, + getContactEndpoint, +}; diff --git a/src/cdk/v2/destinations/cordial/data/CordialIdentifyConfig.json b/src/cdk/v2/destinations/cordial/data/CordialIdentifyConfig.json new file mode 100644 index 0000000000..71d6cf1e9e --- /dev/null +++ b/src/cdk/v2/destinations/cordial/data/CordialIdentifyConfig.json @@ -0,0 +1,11 @@ +[ + { + "destKey": "channels.email.address", + "sourceKeys": "emailOnly", + "sourceFromGenericMap": true + }, + { + "destKey": "channels.email.subscribeStatus", + "sourceKeys": ["traits.subscribeStatus", "context.traits.subscribeStatus"] + } +] diff --git a/src/cdk/v2/destinations/cordial/data/CordialTrackConfig.json b/src/cdk/v2/destinations/cordial/data/CordialTrackConfig.json new file mode 100644 index 0000000000..ddf74ce6b1 --- /dev/null +++ b/src/cdk/v2/destinations/cordial/data/CordialTrackConfig.json @@ -0,0 +1,21 @@ +[ + { + "destKey": "email", + "sourceKeys": "emailOnly", + "sourceFromGenericMap": true + }, + { + "destKey": "a", + "sourceKeys": "event", + "required": true + }, + { + "destKey": "properties", + "sourceKeys": "properties" + }, + { + "destKey": "ats", + "sourceKeys": "timestamp", + "sourceFromGenericMap": true + } +] diff --git a/src/cdk/v2/destinations/cordial/procWorkflow.yaml b/src/cdk/v2/destinations/cordial/procWorkflow.yaml new file mode 100644 index 0000000000..641cf28b06 --- /dev/null +++ b/src/cdk/v2/destinations/cordial/procWorkflow.yaml @@ -0,0 +1,113 @@ +bindings: + - name: EventType + path: ../../../../constants + - path: ../../bindings/jsontemplate + exportAll: true + - name: getHashFromArray + path: ../../../../v0/util + - name: getIntegrationsObj + path: ../../../../v0/util + - name: getDestinationExternalID + path: ../../../../v0/util + - name: removeUndefinedAndNullValues + path: ../../../../v0/util + - name: defaultRequestConfig + path: ../../../../v0/util + - name: base64Convertor + path: ../../../../v0/util + - name: constructPayload + path: ../../../../v0/util + - name: removeEmptyKey + path: ../../../../v0/util + - name: CommonUtils + path: ../../../../util/common + - path: ./utils + - path: ./config + +steps: + - name: checkIfProcessed + condition: .message.statusCode + template: | + $.batchMode ? .message.body.JSON : .message + onComplete: return + + - name: messageType + template: | + $.context.messageType = .message.type.toLowerCase(); + + - name: validateConfig + template: | + $.assertConfig(.destination.Config.apiKey, "API Key is not present. Aborting"); + $.assertConfig(.destination.Config.apiBaseUrl, "API Base URl is not present. Aborting"); + + - name: validateMessageType + template: | + let messageType = $.context.messageType; + $.assert(messageType, "message Type is not present. Aborting"); + $.assert(messageType in {{$.EventType.([.TRACK, .IDENTIFY])}}, "message type " + messageType + " is not supported"); + + - name: getContactId + template: | + $.getDestinationExternalID(.message,'cordialContactId'); + + - name: getContactEmail + template: | + .message.().({{{{$.getGenericPaths("emailOnly")}}}}); + + - name: validateEventPayload + template: | + $.assert($.outputs.getContactId || $.outputs.getContactEmail, "Either one of cordial contact id or email is required. Aborting"); + + - name: buildIdentifyPayload + condition: $.context.messageType in [{{$.EventType.IDENTIFY}}] + steps: + - name: checkIfContactExists + template: | + $.checkIfContactExists(.destination.Config, $.outputs.getContactId, $.outputs.getContactEmail); + + - name: buildPayload + template: | + const integrationObj = $.getIntegrationsObj(.message, "cordial"); + let payload = $.constructPayload(.message, $.IDENTIFY_CONFIG); + const traits = .message.().( + {{{{$.getGenericPaths("traits")}}}}; + ); + payload = {...payload, ...traits}; + payload = payload{~["email", "subscribeStatus"]}; + $.context.payload = payload; + + - name: createContact + condition: $.outputs.buildIdentifyPayload.checkIfContactExists === false + template: | + $.context.endpoint = $.getCreateContactEndpoint(.destination.Config); + $.context.method = "POST"; + + - name: updateContact + condition: $.outputs.buildIdentifyPayload.checkIfContactExists === true + template: | + $.context.endpoint = $.getUpdateContactEndpoint( + .destination.Config, $.outputs.getContactId, $.outputs.getContactEmail); + $.context.method = "PUT"; + + - name: buildTrackPayload + condition: $.context.messageType in [{{$.EventType.TRACK}}] + template: | + let payload = $.constructPayload(.message, $.TRACK_CONFIG); + payload.cID = $.outputs.getContactId; + payload.cID ? payload = payload{~["email"]} : payload = payload{~["cID"]}; + $.context.payload = payload; + $.context.endpoint = $.getEventsEndpoint(.destination.Config); + $.context.method = "POST"; + + - name: buildResponseForProcessTransformation + template: | + const payload = $.context.payload; + const response = $.defaultRequestConfig(); + response.body.JSON = $.removeUndefinedAndNullValues($.removeEmptyKey(payload)); + response.endpoint = $.context.endpoint; + response.method = $.context.method; + response.headers = { + "Content-Type": "application/json", + "Authorization": "Basic " + $.base64Convertor(.destination.Config.apiKey + ":") + }; + response; diff --git a/src/cdk/v2/destinations/cordial/rtWorkflow.yaml b/src/cdk/v2/destinations/cordial/rtWorkflow.yaml new file mode 100644 index 0000000000..dd438a911c --- /dev/null +++ b/src/cdk/v2/destinations/cordial/rtWorkflow.yaml @@ -0,0 +1,31 @@ +bindings: + - name: handleRtTfSingleEventError + path: ../../../../v0/util/index + +steps: + - name: validateInput + template: | + $.assert(Array.isArray(^) && ^.length > 0, "Invalid event array") + + - name: transform + externalWorkflow: + path: ./procWorkflow.yaml + loopOverInput: true + + - name: successfulEvents + template: | + $.outputs.transform#idx.output.({ + "batchedRequest": ., + "batched": false, + "destination": ^[idx].destination, + "metadata": ^[idx].metadata[], + "statusCode": 200 + })[] + - name: failedEvents + template: | + $.outputs.transform#idx.error.( + $.handleRtTfSingleEventError(^[idx], .originalError ?? ., {}) + )[] + - name: finalPayload + template: | + [...$.outputs.successfulEvents, ...$.outputs.failedEvents] diff --git a/src/cdk/v2/destinations/cordial/utils.js b/src/cdk/v2/destinations/cordial/utils.js new file mode 100644 index 0000000000..1d0ab5789e --- /dev/null +++ b/src/cdk/v2/destinations/cordial/utils.js @@ -0,0 +1,30 @@ +const { getContactEndpoint, destType } = require('./config'); +const { handleHttpRequest } = require('../../../../adapters/network'); + +const checkIfContactExists = async (config, contactId, email) => { + const basicAuth = Buffer.from(`${config.apiKey}:`).toString('base64'); + const endpoint = getContactEndpoint(config, contactId, email); + const { processedResponse } = await handleHttpRequest( + 'get', + endpoint, + { + headers: { + Authorization: `Basic ${basicAuth}`, + }, + }, + { + destType, + feature: 'transformation', + requestMethod: 'GET', + endpointPath: contactId ? '/contacts' : '/contacts/email', + module: 'router', + }, + ); + + // eslint-disable-next-line no-underscore-dangle + return processedResponse.status === 200 && !!processedResponse.response?._id; +}; + +module.exports = { + checkIfContactExists, +}; diff --git a/src/cdk/v2/destinations/emarsys/utils.test.js b/src/cdk/v2/destinations/emarsys/utils.test.js index 3802567ecb..72a86a1529 100644 --- a/src/cdk/v2/destinations/emarsys/utils.test.js +++ b/src/cdk/v2/destinations/emarsys/utils.test.js @@ -1,4 +1,3 @@ -const { EVENT_TYPE } = require('rudder-transformer-cdk/build/constants'); const { buildIdentifyPayload, buildGroupPayload, @@ -92,7 +91,7 @@ describe('Emarsys utils', () => { const result = buildIdentifyPayload(message, destination); - expect(result.eventType).toBe(EVENT_TYPE.IDENTIFY); + expect(result.eventType).toBe('identify'); expect(result.destinationPayload).toEqual(expectedPayload); }); @@ -185,7 +184,7 @@ describe('Emarsys utils', () => { const result = buildIdentifyPayload(message, destination); - expect(result.eventType).toBe(EVENT_TYPE.IDENTIFY); + expect(result.eventType).toBe('identify'); expect(result.destinationPayload).toEqual(expectedPayload); }); }); diff --git a/src/cdk/v2/destinations/intercom/config.js b/src/cdk/v2/destinations/intercom/config.js index c3b806f9f9..12bcf8ed5f 100644 --- a/src/cdk/v2/destinations/intercom/config.js +++ b/src/cdk/v2/destinations/intercom/config.js @@ -66,7 +66,7 @@ const ReservedAttributes = { ], }; -const ReservedCompanyProperties = ['id', 'name', 'industry']; +const ReservedCompanyProperties = ['id', 'name', 'industry', 'remove']; const MetadataTypes = { richLink: ['url', 'value'], monetaryAmount: ['amount', 'currency'] }; diff --git a/src/cdk/v2/destinations/intercom/procWorkflow.yaml b/src/cdk/v2/destinations/intercom/procWorkflow.yaml index 008b22ace5..0f2ac18fbc 100644 --- a/src/cdk/v2/destinations/intercom/procWorkflow.yaml +++ b/src/cdk/v2/destinations/intercom/procWorkflow.yaml @@ -52,7 +52,7 @@ steps: - name: searchContact condition: ($.outputs.messageType === {{$.EventType.IDENTIFY}} || $.outputs.messageType === {{$.EventType.GROUP}}) && $.outputs.apiVersion !== "v1" template: | - const contactId = await $.searchContact(.message, .destination); + const contactId = await $.searchContact(.message, .destination, .metadata); contactId; - name: identifyTransformationForLatestVersion @@ -84,6 +84,9 @@ steps: $.assert($.context.payload.external_id || $.context.payload.email, "Either email or userId is required for Identify call"); const endpoint = $.getBaseEndpoint(.destination) + "/" + "contacts"; $.context.requestMethod = $.outputs.searchContact ? 'PUT' : 'POST'; + const company = .message.traits.company || .message.context.traits.company; + const shouldDetachUserAndCompany = $.outputs.searchContact && company.remove; + shouldDetachUserAndCompany ? await $.detachContactAndCompany($.outputs.searchContact, company, .destination); $.context.endpoint = $.outputs.searchContact ? endpoint + "/" + $.outputs.searchContact : endpoint; $.context.payload = $.removeUndefinedAndNullValues($.context.payload); @@ -178,7 +181,7 @@ steps: condition: $.isDefinedAndNotNull($.outputs.searchContact) template: | const contactId = $.outputs.searchContact; - const companyId = await $.createOrUpdateCompany($.context.payload, .destination); + const companyId = await $.createOrUpdateCompany($.context.payload, .destination, .metadata); $.assert(companyId, "Unable to create or update company"); $.context.payload = { id: companyId, @@ -186,15 +189,16 @@ steps: $.context.endpoint = $.getBaseEndpoint(.destination) + "/" + "contacts" + "/" + contactId + "/" + "companies"; const payload = $.context.payload; const endpoint = $.context.endpoint; - await $.attachContactToCompany(payload, endpoint, .destination); - await $.addOrUpdateTagsToCompany(.message, .destination, companyId); + const eventData = {metadata: .metadata, destination: .destination} + await $.attachContactToCompany(payload, endpoint, eventData); + await $.addOrUpdateTagsToCompany({metadata: .metadata, destination: .destination, message: .message}, companyId); else: name: whenSearchContactNotFound template: | - const companyId = await $.createOrUpdateCompany($.context.payload, .destination); + const companyId = await $.createOrUpdateCompany($.context.payload, .destination, .metadata); $.assert(companyId, "Unable to create or update company"); $.context.endpoint = $.getBaseEndpoint(.destination) + "/" + "companies"; - await $.addOrUpdateTagsToCompany(.message, .destination, companyId); + await $.addOrUpdateTagsToCompany({metadata: .metadata, destination: .destination, message: .message}, companyId); - name: prepareFinalPayload template: | $.context.requestMethod = 'POST'; @@ -218,15 +222,16 @@ steps: response.userId = .message.anonymousId; $.context.response.push(response); payload = response.body.JSON; - const companyId = await $.createOrUpdateCompany(payload, .destination); + const companyId = await $.createOrUpdateCompany(payload, .destination, .metadata); $.assert(companyId, "Unable to create or update company"); const attachUserAndCompanyResponse = $.attachUserAndCompany(.message, .destination.Config); attachUserAndCompanyResponse ? attachUserAndCompanyResponse.userId = .message.anonymousId; attachUserAndCompanyResponse ? $.context.response.push(attachUserAndCompanyResponse); payload = attachUserAndCompanyResponse.body.JSON; let endpoint = attachUserAndCompanyResponse.endpoint; - attachUserAndCompanyResponse ? await $.attachContactToCompany(payload, endpoint, .destination); - await $.addOrUpdateTagsToCompany(.message, .destination, companyId); + const eventData = {metadata: .metadata, destination: .destination} + attachUserAndCompanyResponse ? await $.attachContactToCompany(payload, endpoint, eventData); + await $.addOrUpdateTagsToCompany({metadata: .metadata, destination: .destination, message: .message}, companyId); - name: statusCode condition: $.outputs.messageType === {{$.EventType.GROUP}} diff --git a/src/cdk/v2/destinations/intercom/utils.js b/src/cdk/v2/destinations/intercom/utils.js index baef94e97c..dc483e040b 100644 --- a/src/cdk/v2/destinations/intercom/utils.js +++ b/src/cdk/v2/destinations/intercom/utils.js @@ -6,7 +6,7 @@ const { InstrumentationError, } = require('@rudderstack/integrations-lib'); const tags = require('../../../../v0/util/tags'); -const { httpPOST } = require('../../../../adapters/network'); +const { httpPOST, handleHttpRequest } = require('../../../../adapters/network'); const { processAxiosResponse, getDynamicErrorType, @@ -164,6 +164,7 @@ const getCompaniesList = (payload) => { custom_attributes: removeUndefinedAndNullValues(customAttributes), name: company.name, industry: company.industry, + remove: company.remove, }); } return companiesList; @@ -267,7 +268,7 @@ const filterCustomAttributes = (payload, type, destination) => { * @param {*} destination * @returns */ -const searchContact = async (message, destination) => { +const searchContact = async (message, destination, metadata) => { const lookupField = getLookUpField(message); const lookupFieldValue = getFieldValueFromMessage(message, lookupField); const data = JSON.stringify({ @@ -298,6 +299,7 @@ const searchContact = async (message, destination) => { endpointPath: '/contacts/search', requestMethod: 'POST', module: 'router', + metadata, }, ); const processedUserResponse = processAxiosResponse(response); @@ -324,7 +326,7 @@ const searchContact = async (message, destination) => { * @param {*} destination * @returns */ -const createOrUpdateCompany = async (payload, destination) => { +const createOrUpdateCompany = async (payload, destination, metadata) => { const { apiVersion } = destination.Config; const headers = getHeaders(destination, apiVersion); const finalPayload = JSON.stringify(removeUndefinedAndNullValues(payload)); @@ -337,6 +339,7 @@ const createOrUpdateCompany = async (payload, destination) => { headers, }, { + metadata, destType: 'intercom', feature: 'transformation', endpointPath: '/companies', @@ -418,7 +421,7 @@ const addMetadataToPayload = (payload) => { * @param {*} endpoint * @param {*} destination */ -const attachContactToCompany = async (payload, endpoint, destination) => { +const attachContactToCompany = async (payload, endpoint, { destination, metadata }) => { let { apiVersion } = destination.Config; apiVersion = isDefinedAndNotNull(apiVersion) ? apiVersion : 'v2'; let endpointPath = '/contact/{id}/companies'; @@ -442,6 +445,7 @@ const attachContactToCompany = async (payload, endpoint, destination) => { { ...commonStatTags, endpointPath, + metadata, }, ); @@ -460,7 +464,7 @@ const attachContactToCompany = async (payload, endpoint, destination) => { * @param id * @returns */ -const addOrUpdateTagsToCompany = async (message, destination, id) => { +const addOrUpdateTagsToCompany = async ({ message, destination, metadata }, id) => { const companyTags = message?.context?.traits?.tags; if (!companyTags) return; const { apiVersion } = destination.Config; @@ -473,6 +477,7 @@ const addOrUpdateTagsToCompany = async (message, destination, id) => { endpointPath: '/tags', requestMethod: 'POST', module: 'router', + metadata, }; await Promise.all( companyTags.map(async (tag) => { @@ -503,6 +508,85 @@ const addOrUpdateTagsToCompany = async (message, destination, id) => { ); }; +/** + * Api call to get company id provided by intercom + * Ref doc v1: https://developers.intercom.com/docs/references/1.4/rest-api/companies/view-a-company + * Ref doc v2: https://developers.intercom.com/docs/references/2.10/rest-api/api.intercom.io/companies/retrievecompany + * @param {*} company + * @param {*} destination + * @returns + */ +const getCompanyId = async (company, destination) => { + if (!company.id && !company.name) return undefined; + const { apiVersion } = destination.Config; + const headers = getHeaders(destination, apiVersion); + const baseEndPoint = getBaseEndpoint(destination); + + const queryParam = company.id ? `company_id=${company.id}` : `name=${company.name}`; + const endpoint = `${baseEndPoint}/companies?${queryParam}`; + + const statTags = { + destType: 'intercom', + feature: 'transformation', + endpointPath: '/companies', + requestMethod: 'GET', + module: 'router', + }; + + const { processedResponse: response } = await handleHttpRequest( + 'GET', + endpoint, + { + headers, + }, + statTags, + ); + + if (isHttpStatusSuccess(response.status)) { + return response.response.id; + } + intercomErrorHandler('Unable to get company id due to', response); + return undefined; +}; + +/** + * Api call to detach contact and company for intercom api version v2 (version 2.10) + * Ref doc: https://developers.intercom.com/docs/references/2.10/rest-api/api.intercom.io/contacts/detachcontactfromacompany + * @param {*} contactId + * @param {*} company + * @param {*} destination + * @returns + */ +const detachContactAndCompany = async (contactId, company, destination) => { + const companyId = await getCompanyId(company, destination); + if (!companyId) return; + + const headers = getHeaders(destination); + const baseEndPoint = getBaseEndpoint(destination); + const endpoint = `${baseEndPoint}/contacts/${contactId}/companies/${companyId}`; + + const statTags = { + destType: 'intercom', + feature: 'transformation', + endpointPath: 'contacts/companies', + requestMethod: 'DELETE', + module: 'router', + }; + + const { processedResponse: response } = await handleHttpRequest( + 'DELETE', + endpoint, + { + headers, + }, + statTags, + ); + + if (!isHttpStatusSuccess(response.status)) { + intercomErrorHandler('Unable to detach contact and company due to', response); + } +}; + module.exports = { getName, getHeaders, @@ -518,4 +602,5 @@ module.exports = { separateReservedAndRestMetadata, attachContactToCompany, addOrUpdateTagsToCompany, + detachContactAndCompany, }; diff --git a/src/cdk/v2/destinations/intercom/utils.test.js b/src/cdk/v2/destinations/intercom/utils.test.js index bb5ad2b454..c2bf3f8e89 100644 --- a/src/cdk/v2/destinations/intercom/utils.test.js +++ b/src/cdk/v2/destinations/intercom/utils.test.js @@ -785,7 +785,7 @@ describe('attachContactToCompany utility test', () => { }, }); - await attachContactToCompany(payload, endpoint, destination); + await attachContactToCompany(payload, endpoint, { destination }); expect(axios.post).toHaveBeenCalledWith( endpoint, @@ -828,7 +828,7 @@ describe('attachContactToCompany utility test', () => { }, }); - await attachContactToCompany(payload, endpoint, destination); + await attachContactToCompany(payload, endpoint, { destination }); expect(axios.post).toHaveBeenCalledWith( endpoint, @@ -863,7 +863,7 @@ describe('attachContactToCompany utility test', () => { }); try { - await attachContactToCompany(payload, endpoint, destination); + await attachContactToCompany(payload, endpoint, { destination }); } catch (error) { expect(error.message).toEqual( 'Unable to attach Contact or User to Company due to : {"type":"error.list","request_id":"123","errors":[{"code":"company_not_found","message":"Company Not Found"}]}', @@ -893,7 +893,7 @@ describe('attachContactToCompany utility test', () => { }); try { - await attachContactToCompany(payload, endpoint, destination); + await attachContactToCompany(payload, endpoint, { destination }); } catch (error) { expect(error.message).toEqual( 'Unable to attach Contact or User to Company due to : {"type":"error.list","request_id":"123","errors":[{"code":"parameter_not_found","message":"company not specified"}]}', @@ -925,7 +925,7 @@ describe('addOrUpdateTagsToCompany utility test', () => { }); axios.post.mockClear(); - await addOrUpdateTagsToCompany(message, destination, id); + await addOrUpdateTagsToCompany({ message, destination }, id); expect(axios.post).toHaveBeenCalledTimes(2); @@ -973,7 +973,7 @@ describe('addOrUpdateTagsToCompany utility test', () => { try { axios.post.mockClear(); - await addOrUpdateTagsToCompany(message, destination, id); + await addOrUpdateTagsToCompany({ message, destination }, id); } catch (error) { expect(error.message).toEqual( `Unable to Add or Update the Tag to Company due to : {"type":"error.list","request_id":"request_401","errors":[{"code":"unauthorized","message":"Access Token Invalid"}]}`, @@ -1008,7 +1008,7 @@ describe('addOrUpdateTagsToCompany utility test', () => { try { axios.post.mockClear(); - await addOrUpdateTagsToCompany(message, destination, id); + await addOrUpdateTagsToCompany({ message, destination }, id); } catch (error) { expect(error.message).toEqual( `Unable to Add or Update the Tag to Company due to : {"type":"error.list","request_id":"request_429","errors":[{"code":"rate_limit_exceeded","message":"You have exceeded the rate limit. Please try again later."}]}`, @@ -1022,7 +1022,7 @@ describe('addOrUpdateTagsToCompany utility test', () => { const id = 'companyId'; axios.post.mockClear(); - await addOrUpdateTagsToCompany(message, destination, id); + await addOrUpdateTagsToCompany({ message, destination }, id); expect(axios.post).not.toHaveBeenCalled(); }); diff --git a/src/cdk/v2/destinations/koala/procWorkflow.yaml b/src/cdk/v2/destinations/koala/procWorkflow.yaml index 9ec0202b13..dc245f61c4 100644 --- a/src/cdk/v2/destinations/koala/procWorkflow.yaml +++ b/src/cdk/v2/destinations/koala/procWorkflow.yaml @@ -29,7 +29,8 @@ steps: identifies: [{ type: $.context.messageType, sent_at: .message.().({{{{$.getGenericPaths("timestamp")}}}}), - traits: koTraits + traits: koTraits, + source: "rudderstack-cloud" }] }; diff --git a/src/cdk/v2/destinations/optimizely_fullstack/procWorkflow.yaml b/src/cdk/v2/destinations/optimizely_fullstack/procWorkflow.yaml index 4d90065f7e..0776e7e8a8 100644 --- a/src/cdk/v2/destinations/optimizely_fullstack/procWorkflow.yaml +++ b/src/cdk/v2/destinations/optimizely_fullstack/procWorkflow.yaml @@ -17,6 +17,8 @@ bindings: path: ../../../../v0/util - name: generateUUID path: ../../../../v0/util + - name: getRelativePathFromURL + path: ../../../../v0/util - name: handleHttpRequest path: ../../../../adapters/network - path: ./utils @@ -59,7 +61,9 @@ steps: description: Fetch the data file from the data file url template: | const dataFileUrl = .destination.Config.dataFileUrl; - const rawResponse = await $.handleHttpRequest("get", dataFileUrl); + const urlPath = $.getRelativePathFromURL(dataFileUrl) + const reqStats = {metadata:.metadata, module: 'router',feature: "transformation", destType:"optimizely_fullstack",requestMethod:"get",endpointPath: urlPath} + const rawResponse = await $.handleHttpRequest("get", dataFileUrl, reqStats); const processedResponse = rawResponse.processedResponse; $.assertHttpResp(processedResponse, "Data File Lookup Failed due to " + JSON.stringify(processedResponse.response)); processedResponse.response; diff --git a/src/cdk/v2/destinations/rakuten/utils.js b/src/cdk/v2/destinations/rakuten/utils.js index ef6b197db7..2dd628a250 100644 --- a/src/cdk/v2/destinations/rakuten/utils.js +++ b/src/cdk/v2/destinations/rakuten/utils.js @@ -1,5 +1,4 @@ -const { InstrumentationError } = require('@rudderstack/integrations-lib'); -const { isDefinedAndNotNull } = require('rudder-transformer-cdk/build/utils'); +const { InstrumentationError, isDefinedAndNotNull } = require('@rudderstack/integrations-lib'); const { mappingConfig, ConfigCategories, @@ -57,11 +56,7 @@ const constructLineItems = (properties) => { if (!product?.amount && !product?.price) { throw new InstrumentationError('Either amount or price is required for every product'); } - - if (product.price) { - return product.quantity * product.price * 100; - } - return product.amount * 100; + return product.amount * 100 || (product.quantity || 1) * 100 * product.price; }); productList.amtlist = amountList.join('|'); return productList; diff --git a/src/cdk/v2/destinations/smartly/config.js b/src/cdk/v2/destinations/smartly/config.js new file mode 100644 index 0000000000..5083fde5fe --- /dev/null +++ b/src/cdk/v2/destinations/smartly/config.js @@ -0,0 +1,21 @@ +const { getMappingConfig } = require('../../../../v0/util'); + +const ConfigCategories = { + TRACK: { + type: 'track', + name: 'trackMapping', + }, +}; + +const mappingConfig = getMappingConfig(ConfigCategories, __dirname); +const singleEventEndpoint = 'https://s2s.smartly.io/events'; +const batchEndpoint = 'https://s2s.smartly.io/events/batch'; + +module.exports = { + ConfigCategories, + mappingConfig, + singleEventEndpoint, + batchEndpoint, + TRACK_CONFIG: mappingConfig[ConfigCategories.TRACK.name], + MAX_BATCH_SIZE: 1000, +}; diff --git a/src/cdk/v2/destinations/smartly/data/trackMapping.json b/src/cdk/v2/destinations/smartly/data/trackMapping.json new file mode 100644 index 0000000000..55ba437f12 --- /dev/null +++ b/src/cdk/v2/destinations/smartly/data/trackMapping.json @@ -0,0 +1,76 @@ +[ + { + "destKey": "value", + "sourceKeys": [ + "properties.total", + "properties.value", + "properties.revenue", + { + "operation": "multiplication", + "args": [ + { + "sourceKeys": "properties.price" + }, + { + "sourceKeys": "properties.quantity", + "default": 1 + } + ] + } + ], + "metadata": { + "type": "toNumber" + }, + "required": false + }, + { + "sourceKeys": ["properties.conversions", "properties.products.length"], + "required": false, + "metadata": { + "defaultValue": "1" + }, + "destKey": "conversions" + }, + { + "sourceKeys": ["properties.adUnitId", "properties.ad_unit_id"], + "required": true, + "destKey": "ad_unit_id", + "metadata": { + "type": "toString" + } + }, + { + "sourceKeys": ["properties.platform"], + "required": true, + "destKey": "platform" + }, + { + "sourceKeys": ["properties.adInteractionTime", "properties.ad_interaction_time"], + "required": true, + "metadata": { + "type": "secondTimestamp" + }, + "destKey": "ad_interaction_time" + }, + { + "sourceKeys": ["properties.installTime"], + "required": false, + "metadata": { + "type": "secondTimestamp" + }, + "destKey": "installTime" + }, + { + "sourceKeys": ["originalTimestamp", "timestamp"], + "required": false, + "metadata": { + "type": "secondTimestamp" + }, + "destKey": "event_time" + }, + { + "sourceKeys": ["properties.currency"], + "required": false, + "destKey": "value_currency" + } +] diff --git a/src/cdk/v2/destinations/smartly/procWorkflow.yaml b/src/cdk/v2/destinations/smartly/procWorkflow.yaml new file mode 100644 index 0000000000..b69df0dd09 --- /dev/null +++ b/src/cdk/v2/destinations/smartly/procWorkflow.yaml @@ -0,0 +1,31 @@ +bindings: + - name: EventType + path: ../../../../constants + - path: ../../bindings/jsontemplate + - name: defaultRequestConfig + path: ../../../../v0/util + - name: removeUndefinedAndNullValues + path: ../../../../v0/util + - name: constructPayload + path: ../../../../v0/util + - path: ./config + - path: ./utils +steps: + - name: messageType + template: | + .message.type.toLowerCase(); + - name: validateInput + template: | + let messageType = $.outputs.messageType; + $.assert(messageType, "message Type is not present. Aborting"); + $.assert(messageType in {{$.EventType.([.TRACK])}}, "message type " + messageType + " is not supported"); + $.assertConfig(.destination.Config.apiToken, "API Token is not present. Aborting"); + - name: preparePayload + template: | + const payload = $.removeUndefinedAndNullValues($.constructPayload(.message, $.TRACK_CONFIG)); + $.verifyAdInteractionTime(payload.ad_interaction_time); + $.context.payloadList = $.getPayloads(.message.event, .destination.Config, payload) + - name: buildResponse + template: | + const response = $.buildResponseList($.context.payloadList) + response diff --git a/src/cdk/v2/destinations/smartly/rtWorkflow.yaml b/src/cdk/v2/destinations/smartly/rtWorkflow.yaml new file mode 100644 index 0000000000..4d3afdb6d0 --- /dev/null +++ b/src/cdk/v2/destinations/smartly/rtWorkflow.yaml @@ -0,0 +1,35 @@ +bindings: + - path: ./config + - name: handleRtTfSingleEventError + path: ../../../../v0/util/index + - path: ./utils +steps: + - name: validateInput + template: | + $.assert(Array.isArray(^) && ^.length > 0, "Invalid event array") + + - name: transform + externalWorkflow: + path: ./procWorkflow.yaml + loopOverInput: true + + - name: successfulEvents + template: | + $.outputs.transform#idx.output.({ + "output": .body.JSON, + "destination": ^[idx].destination, + "metadata": ^[idx].metadata + })[] + - name: failedEvents + template: | + $.outputs.transform#idx.error.( + $.handleRtTfSingleEventError(^[idx], .originalError ?? ., {}) + )[] + - name: batchSuccessfulEvents + description: Batches the successfulEvents + template: | + $.batchResponseBuilder($.outputs.successfulEvents); + + - name: finalPayload + template: | + [...$.outputs.failedEvents, ...$.outputs.batchSuccessfulEvents] diff --git a/src/cdk/v2/destinations/smartly/utils.js b/src/cdk/v2/destinations/smartly/utils.js new file mode 100644 index 0000000000..7d53ed0d27 --- /dev/null +++ b/src/cdk/v2/destinations/smartly/utils.js @@ -0,0 +1,108 @@ +const { BatchUtils } = require('@rudderstack/workflow-engine'); +const { InstrumentationError } = require('@rudderstack/integrations-lib'); +const moment = require('moment'); +const config = require('./config'); +const { + getHashFromArrayWithDuplicate, + defaultRequestConfig, + isDefinedAndNotNull, +} = require('../../../../v0/util'); + +// docs reference : https://support.smartly.io/hc/en-us/articles/4406049685788-S2S-integration-API-description#01H8HBXZF6WSKSYBW1C6NY8A88 + +/** + * This function generates an array of payload objects, each with the event property set + * to different values associated with the given event name according to eventsMapping + * @param {*} event + * @param {*} eventsMapping + * @param {*} payload + * @returns + */ +const getPayloads = (event, Config, payload) => { + if (!isDefinedAndNotNull(event) || typeof event !== 'string') { + throw new InstrumentationError('Event is not defined or is not String'); + } + const eventsMap = getHashFromArrayWithDuplicate(Config.eventsMapping); + // eventsMap = hashmap {"prop1":["val1","val2"],"prop2":["val2"]} + const eventList = Array.isArray(eventsMap[event.toLowerCase()]) + ? eventsMap[event.toLowerCase()] + : Array.from(eventsMap[event.toLowerCase()] || [event]); + + const payloadLists = eventList.map((ev) => ({ ...payload, event_name: ev })); + return payloadLists; +}; + +// ad_interaction_time must be within one year in the future and three years in the past from the current date +// Example : "1735680000" +const verifyAdInteractionTime = (adInteractionTime) => { + if (isDefinedAndNotNull(adInteractionTime)) { + const now = moment(); + const threeYearAgo = now.clone().subtract(3, 'year'); + const oneYearFromNow = now.clone().add(1, 'year'); + const inputMoment = moment(adInteractionTime * 1000); // Convert to milliseconds + if (!inputMoment.isAfter(threeYearAgo) || !inputMoment.isBefore(oneYearFromNow)) { + throw new InstrumentationError( + 'ad_interaction_time must be within one year in the future and three years in the past.', + ); + } + } +}; + +const buildResponseList = (payloadList) => + payloadList.map((payload) => { + const response = defaultRequestConfig(); + response.body.JSON = payload; + response.endpoint = config.singleEventEndpoint; + response.method = 'POST'; + return response; + }); + +const batchBuilder = (batch, destination) => ({ + batchedRequest: { + body: { + JSON: { events: batch.map((event) => event.output) }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + version: '1', + type: 'REST', + method: 'POST', + endpoint: config.batchEndpoint, + headers: { + 'Content-Type': 'application/json', + Authorization: `Bearer ${destination.Config.apiToken}`, + }, + params: {}, + files: {}, + }, + metadata: batch + .map((event) => event.metadata) + .filter((metadata, index, self) => self.findIndex((m) => m.jobId === metadata.jobId) === index), // handling jobId duplication for multiplexed events + batched: true, + statusCode: 200, + destination: batch[0].destination, +}); + +/** + * This fucntions make chunk of successful events based on MAX_BATCH_SIZE + * and then build the response for each chunk to be returned as object of an array + * @param {*} events + * @returns + */ +const batchResponseBuilder = (events) => { + if (events.length === 0) { + return []; + } + const { destination } = events[0]; + const batches = BatchUtils.chunkArrayBySizeAndLength(events, { maxItems: config.MAX_BATCH_SIZE }); + + const response = []; + batches.items.forEach((batch) => { + const batchedResponse = batchBuilder(batch, destination); + response.push(batchedResponse); + }); + return response; +}; + +module.exports = { batchResponseBuilder, getPayloads, buildResponseList, verifyAdInteractionTime }; diff --git a/src/cdk/v2/destinations/smartly/utils.test.js b/src/cdk/v2/destinations/smartly/utils.test.js new file mode 100644 index 0000000000..0ad73f5369 --- /dev/null +++ b/src/cdk/v2/destinations/smartly/utils.test.js @@ -0,0 +1,59 @@ +const moment = require('moment'); +const { verifyAdInteractionTime } = require('./utils'); + +describe('verifyAdInteractionTime', () => { + it('should pass when adInteractionTime is 2 years in the past (UNIX timestamp)', () => { + // 2 years ago from now + const adInteractionTime = moment().subtract(2, 'years').unix(); + expect(() => verifyAdInteractionTime(adInteractionTime)).not.toThrow(); + }); + + it('should pass when adInteractionTime is 10 months in the future (UNIX timestamp)', () => { + // 10 months in the future from now + const adInteractionTime = moment().add(10, 'months').unix(); + expect(() => verifyAdInteractionTime(adInteractionTime)).not.toThrow(); + }); + + it('should fail when adInteractionTime is 4 years in the past (UNIX timestamp)', () => { + // 4 years ago from now + const adInteractionTime = moment().subtract(4, 'years').unix(); + expect(() => verifyAdInteractionTime(adInteractionTime)).toThrow( + 'ad_interaction_time must be within one year in the future and three years in the past.', + ); + }); + + it('should fail when adInteractionTime is 2 years in the future (UNIX timestamp)', () => { + // 2 years in the future from now + const adInteractionTime = moment().add(2, 'years').unix(); + expect(() => verifyAdInteractionTime(adInteractionTime)).toThrow( + 'ad_interaction_time must be within one year in the future and three years in the past.', + ); + }); + + it('should pass when adInteractionTime is exactly 1 year in the future (UTC date string)', () => { + // Exactly 1 year in the future from now + const adInteractionTime = moment.utc().add(1, 'year').toISOString(); + expect(() => verifyAdInteractionTime(adInteractionTime)).toThrow(); + }); + + it('should fail when adInteractionTime is 4 years in the past (UTC date string)', () => { + // 4 years ago from now + const adInteractionTime = moment.utc().subtract(4, 'years').toISOString(); + expect(() => verifyAdInteractionTime(adInteractionTime)).toThrow( + 'ad_interaction_time must be within one year in the future and three years in the past.', + ); + }); + + it('should fail when adInteractionTime is 2 years in the future (UTC date string)', () => { + // 2 years in the future from now + const adInteractionTime = moment.utc().add(2, 'years').toISOString(); + expect(() => verifyAdInteractionTime(adInteractionTime)).toThrow( + 'ad_interaction_time must be within one year in the future and three years in the past.', + ); + }); + + it('should not throw an error if adInteractionTime is null or undefined', () => { + expect(() => verifyAdInteractionTime(null)).not.toThrow(); + expect(() => verifyAdInteractionTime(undefined)).not.toThrow(); + }); +}); diff --git a/src/cdk/v2/destinations/the_trade_desk/transformRecord.js b/src/cdk/v2/destinations/the_trade_desk/transformRecord.js index b452f8d7bc..42bbb0816d 100644 --- a/src/cdk/v2/destinations/the_trade_desk/transformRecord.js +++ b/src/cdk/v2/destinations/the_trade_desk/transformRecord.js @@ -40,6 +40,9 @@ const batchResponseBuilder = (items, config) => { return response; }; +const checkNullUndefinedEmptyFields = (fields) => + !!Object.entries(fields).some(([, value]) => !value); + const processRecordInputs = (inputs, destination) => { const { Config } = destination; const items = []; @@ -68,6 +71,11 @@ const processRecordInputs = (inputs, destination) => { return; } + if (checkNullUndefinedEmptyFields(fields)) { + errorResponseList.push(handleRtTfSingleEventError(input, emptyFieldsError, {})); + return; + } + successMetadata.push(input.metadata); const data = [ { @@ -78,10 +86,7 @@ const processRecordInputs = (inputs, destination) => { Object.keys(fields).forEach((id) => { const value = fields[id]; - if (value) { - // adding only non empty ID's - items.push({ [id]: value, Data: data }); - } + items.push({ [id]: value, Data: data }); }); }); diff --git a/src/cdk/v2/destinations/webhook/procWorkflow.yaml b/src/cdk/v2/destinations/webhook/procWorkflow.yaml index 7095161a6b..950af46b96 100644 --- a/src/cdk/v2/destinations/webhook/procWorkflow.yaml +++ b/src/cdk/v2/destinations/webhook/procWorkflow.yaml @@ -27,7 +27,7 @@ steps: template: | let defaultHeaders = $.context.method in ['POST', 'PUT', 'PATCH'] ? {"content-type": "application/json"} : {} let configHeaders = $.getHashFromArray(.destination.Config.headers) - let messageHeader = typeof .message.header === "object" ? Object.assign(...Object.entries(.message.header).{typeof .[1] === 'string'}[].({[.[0]]: .[1]})[]) : {} + let messageHeader = typeof .message.header === "object" ? Object.assign(...Object.entries(.message.header).({[.[0]]:typeof .[1] === 'string' ? .[1] : JSON.stringify(.[1])})[]) : {} $.context.finalHeaders = { ...defaultHeaders, ...configHeaders, diff --git a/src/cdk/v2/destinations/webhook_v2/procWorkflow.yaml b/src/cdk/v2/destinations/webhook_v2/procWorkflow.yaml new file mode 100644 index 0000000000..873a9807ce --- /dev/null +++ b/src/cdk/v2/destinations/webhook_v2/procWorkflow.yaml @@ -0,0 +1,67 @@ +bindings: + - name: EventType + path: ../../../../constants + - path: ../../bindings/jsontemplate + exportAll: true + - path: ../../../../v0/destinations/webhook/utils + - name: getHashFromArray + path: ../../../../v0/util + - name: getIntegrationsObj + path: ../../../../v0/util + - name: removeUndefinedAndNullValues + path: ../../../../v0/util + - name: defaultRequestConfig + path: ../../../../v0/util + - name: isEmptyObject + path: ../../../../v0/util + - path: ./utils + +steps: + - name: validateInput + template: | + $.assertConfig(.destination.Config.webhookUrl, "Webhook URL required. Aborting"); + $.assertConfig(!(.destination.Config.auth === "basicAuth" && !(.destination.Config.username)), "Username is required for Basic Authentication. Aborting"); + $.assertConfig(!(.destination.Config.auth === "bearerTokenAuth" && !(.destination.Config.bearerToken)), "Token is required for Bearer Token Authentication. Aborting"); + $.assertConfig(!(.destination.Config.auth === "apiKeyAuth" && !(.destination.Config.apiKeyName)), "API Key Name is required for API Key Authentication. Aborting"); + $.assertConfig(!(.destination.Config.auth === "apiKeyAuth" && !(.destination.Config.apiKeyValue)), "API Key Value is required for API Key Authentication. Aborting"); + + - name: deduceMethod + template: | + $.context.method = .destination.Config.method ?? 'POST'; + + - name: deduceBodyFormat + template: | + $.context.format = .destination.Config.format ?? 'JSON'; + + - name: buildHeaders + template: | + const configAuthHeaders = $.getAuthHeaders(.destination.Config); + const additionalConfigHeaders = $.getCustomMappings(.message, .destination.Config.headers); + $.context.headers = { + ...configAuthHeaders, + ...additionalConfigHeaders + } + + - name: prepareParams + template: | + $.context.params = $.getCustomMappings(.message, .destination.Config.queryParams) + + - name: deduceEndPoint + template: | + $.context.endpoint = $.addPathParams(.message, .destination.Config.webhookUrl); + + - name: prepareBody + template: | + const payload = $.getCustomMappings(.message, .destination.Config.propertiesMapping); + $.context.payload = $.removeUndefinedAndNullValues($.excludeMappedFields(payload, .destination.Config.propertiesMapping)) + $.context.format === "XML" && !$.isEmptyObject($.context.payload) ? $.context.payload = {payload: $.getXMLPayload($.context.payload)}; + + - name: buildResponseForProcessTransformation + template: | + const response = $.defaultRequestConfig(); + $.context.format === "JSON" ? response.body.JSON = $.context.payload: response.body.XML = $.context.payload; + response.endpoint = $.context.endpoint; + response.headers = $.context.headers; + response.method = $.context.method; + response.params = $.context.params ?? {}; + response diff --git a/src/cdk/v2/destinations/webhook_v2/rtWorkflow.yaml b/src/cdk/v2/destinations/webhook_v2/rtWorkflow.yaml new file mode 100644 index 0000000000..edc31d003d --- /dev/null +++ b/src/cdk/v2/destinations/webhook_v2/rtWorkflow.yaml @@ -0,0 +1,60 @@ +bindings: + - name: handleRtTfSingleEventError + path: ../../../../v0/util/index + - path: ./utils + exportAll: true + - name: BatchUtils + path: '@rudderstack/workflow-engine' + +steps: + - name: validateInput + template: | + $.assert(Array.isArray(^) && ^.length > 0, "Invalid event array") + + - name: transform + externalWorkflow: + path: ./procWorkflow.yaml + loopOverInput: true + + - name: successfulEvents + template: | + $.outputs.transform#idx.output.({ + "batchedRequest": ., + "batched": false, + "destination": ^[idx].destination, + "metadata": ^[idx].metadata[], + "statusCode": 200 + })[] + + - name: failedEvents + template: | + $.outputs.transform#idx.error.( + $.handleRtTfSingleEventError(^[idx], .originalError ?? ., {}) + )[] + + - name: bodyFormat + template: | + $.outputs.successfulEvents[0].destination.Config.format ?? "JSON"; + + - name: batchingEnabled + template: | + $.outputs.successfulEvents[0].destination.Config.isBatchingEnabled; + + - name: batchSize + template: | + $.outputs.successfulEvents[0].destination.Config.maxBatchSize; + + - name: batchSuccessfulEvents + description: Batches the successfulEvents + condition: $.outputs.batchingEnabled && $.outputs.bodyFormat === "JSON" + template: | + $.batchSuccessfulEvents($.outputs.successfulEvents, $.outputs.batchSize); + + - name: finalPayloadWithBatching + condition: $.outputs.batchingEnabled && $.outputs.bodyFormat === "JSON" + template: | + [...$.outputs.batchSuccessfulEvents, ...$.outputs.failedEvents] + else: + name: finalPayloadWithoutBatching + template: | + [...$.outputs.successfulEvents, ...$.outputs.failedEvents] diff --git a/src/cdk/v2/destinations/webhook_v2/utils.js b/src/cdk/v2/destinations/webhook_v2/utils.js new file mode 100644 index 0000000000..8e04b59ec0 --- /dev/null +++ b/src/cdk/v2/destinations/webhook_v2/utils.js @@ -0,0 +1,146 @@ +const { toXML } = require('jstoxml'); +const { groupBy } = require('lodash'); +const { createHash } = require('crypto'); +const { ConfigurationError } = require('@rudderstack/integrations-lib'); +const { BatchUtils } = require('@rudderstack/workflow-engine'); +const { base64Convertor, applyCustomMappings, isEmptyObject } = require('../../../../v0/util'); + +const getAuthHeaders = (config) => { + let headers; + switch (config.auth) { + case 'basicAuth': { + const credentials = `${config.username}:${config.password}`; + const encodedCredentials = base64Convertor(credentials); + headers = { + Authorization: `Basic ${encodedCredentials}`, + }; + break; + } + case 'bearerTokenAuth': + headers = { Authorization: `Bearer ${config.bearerToken}` }; + break; + case 'apiKeyAuth': + headers = { [config.apiKeyName]: `${config.apiKeyValue}` }; + break; + default: + headers = {}; + } + return headers; +}; + +const getCustomMappings = (message, mapping) => { + try { + return applyCustomMappings(message, mapping); + } catch (e) { + throw new ConfigurationError(`[Webhook]:: Error in custom mappings: ${e.message}`); + } +}; + +// TODO: write a func to evaluate json path template +const addPathParams = (message, webhookUrl) => webhookUrl; + +const excludeMappedFields = (payload, mapping) => { + const rawPayload = { ...payload }; + if (mapping) { + mapping.forEach(({ from, to }) => { + // continue when from === to + if (from === to) return; + + // Remove the '$.' prefix and split the remaining string by '.' + const keys = from.replace(/^\$\./, '').split('.'); + let current = rawPayload; + + // Traverse to the parent of the key to be removed + keys.slice(0, -1).forEach((key) => { + if (current?.[key]) { + current = current[key]; + } else { + current = null; + } + }); + + if (current) { + // Remove the 'from' field from input payload + delete current[keys[keys.length - 1]]; + } + }); + } + + return rawPayload; +}; + +const getXMLPayload = (payload) => + toXML(payload, { + header: true, + }); + +const getMergedEvents = (batch) => { + const events = []; + batch.forEach((event) => { + if (!isEmptyObject(event.batchedRequest.body.JSON)) { + events.push(event.batchedRequest.body.JSON); + } + }); + return events; +}; + +const mergeMetadata = (batch) => batch.map((event) => event.metadata[0]); + +const createHashKey = (endpoint, headers, params) => { + const hash = createHash('sha256'); + hash.update(endpoint); + hash.update(JSON.stringify(headers)); + hash.update(JSON.stringify(params)); + return hash.digest('hex'); +}; + +const buildBatchedRequest = (batch) => ({ + batchedRequest: { + body: { + JSON: {}, + JSON_ARRAY: { batch: JSON.stringify(getMergedEvents(batch)) }, + XML: {}, + FORM: {}, + }, + version: '1', + type: 'REST', + method: batch[0].batchedRequest.method, + endpoint: batch[0].batchedRequest.endpoint, + headers: batch[0].batchedRequest.headers, + params: batch[0].batchedRequest.params, + files: {}, + }, + metadata: mergeMetadata(batch), + batched: true, + statusCode: 200, + destination: batch[0].destination, +}); + +const batchSuccessfulEvents = (events, batchSize) => { + const response = []; + // group events by endpoint, headers and query params + const groupedEvents = groupBy(events, (event) => { + const { endpoint, headers, params } = event.batchedRequest; + return createHashKey(endpoint, headers, params); + }); + + // batch the each grouped event + Object.keys(groupedEvents).forEach((groupKey) => { + const batches = BatchUtils.chunkArrayBySizeAndLength(groupedEvents[groupKey], { + maxItems: batchSize, + }).items; + batches.forEach((batch) => { + response.push(buildBatchedRequest(batch)); + }); + }); + return response; +}; + +module.exports = { + getAuthHeaders, + getCustomMappings, + addPathParams, + excludeMappedFields, + getXMLPayload, + batchSuccessfulEvents, +}; diff --git a/src/cdk/v2/destinations/zoho/config.js b/src/cdk/v2/destinations/zoho/config.js new file mode 100644 index 0000000000..d942d9e369 --- /dev/null +++ b/src/cdk/v2/destinations/zoho/config.js @@ -0,0 +1,61 @@ +// https://www.zoho.com/crm/developer/docs/api/v6/access-refresh.html +const DATA_CENTRE_BASE_ENDPOINTS_MAP = { + US: 'https://www.zohoapis.com', + AU: 'https://www.zohoapis.com.au', + EU: 'https://www.zohoapis.eu', + IN: 'https://www.zohoapis.in', + CN: 'https://www.zohoapis.com.cn', + JP: 'https://www.zohoapis.jp', + CA: 'https://www.zohoapiscloud.ca', +}; + +const getBaseEndpoint = (dataServer) => DATA_CENTRE_BASE_ENDPOINTS_MAP[dataServer]; +const COMMON_RECORD_ENDPOINT = (dataCenter = 'US') => + `${getBaseEndpoint(dataCenter)}/crm/v6/moduleType`; + +// ref: https://www.zoho.com/crm/developer/docs/api/v6/insert-records.html#:~:text=%2DX%20POST-,System%2Ddefined%20mandatory%20fields%20for%20each%20module,-While%20inserting%20records +const MODULE_MANDATORY_FIELD_CONFIG = { + Leads: ['Last_Name'], + Contacts: ['Last_Name'], + Accounts: ['Account_Name'], + Deals: ['Deal_Name', 'Stage', 'Pipeline'], + Tasks: ['Subject'], + Calls: ['Subject', 'Call_Type', 'Call_Start_Time', 'Call_Duration'], + Events: ['Event_Title', 'Start_DateTime', 'Remind_At', 'End_DateTime'], + Products: ['Product_Name'], + Quotes: ['Subject', 'Quoted_Items'], + Invoices: ['Subject', 'Invoiced_Items'], + Campaigns: ['Campaign_Name'], + Vendors: ['Vendor_Name'], + 'Price Books': ['Price_Book_Name', 'Pricing_Details'], + Cases: ['Case_Origin', 'Status', 'Subject'], + Solutions: ['Solution_Title'], + 'Purchase Orders': ['Subject', 'Vendor_Name', 'Purchased_Items'], + 'Sales Orders': ['Subject', 'Ordered_Items'], +}; + +const MODULE_WISE_DUPLICATE_CHECK_FIELD = { + Leads: ['Email'], + Accounts: ['Account_Name'], + Contacts: ['Email'], + Deals: ['Deal_Name'], + Campaigns: ['Campaign_Name'], + Cases: ['Subject'], + Solutions: ['Solution_Title'], + Products: ['Product_Name'], + Vendors: ['Vendor_Name'], + PriceBooks: ['Price_Book_Name'], + Quotes: ['Subject'], + SalesOrders: ['Subject'], + PurchaseOrders: ['Subject'], + Invoices: ['Subject'], + CustomModules: ['Name'], +}; + +module.exports = { + MAX_BATCH_SIZE: 100, + DATA_CENTRE_BASE_ENDPOINTS_MAP, + COMMON_RECORD_ENDPOINT, + MODULE_MANDATORY_FIELD_CONFIG, + MODULE_WISE_DUPLICATE_CHECK_FIELD, +}; diff --git a/src/cdk/v2/destinations/zoho/rtWorkflow.yaml b/src/cdk/v2/destinations/zoho/rtWorkflow.yaml new file mode 100644 index 0000000000..b50b9502e3 --- /dev/null +++ b/src/cdk/v2/destinations/zoho/rtWorkflow.yaml @@ -0,0 +1,38 @@ +bindings: + - name: EventType + path: ../../../../constants + - name: processRecordInputs + path: ./transformRecord + - name: handleRtTfSingleEventError + path: ../../../../v0/util/index + - name: InstrumentationError + path: '@rudderstack/integrations-lib' + +steps: + - name: validateConfig + template: | + const config = ^[0].destination.Config + $.assertConfig(config.region, "Datacentre Region is not present. Aborting") + + - name: validateInput + template: | + $.assert(Array.isArray(^) && ^.length > 0, "Invalid event array") + + - name: processRecordEvents + template: | + await $.processRecordInputs(^.{.message.type === $.EventType.RECORD}[], ^[0].destination) + + - name: failOtherEvents + template: | + const otherEvents = ^.{.message.type !== $.EventType.RECORD}[] + let failedEvents = otherEvents.map( + function(event) { + const error = new $.InstrumentationError("Event type " + event.message.type + " is not supported"); + $.handleRtTfSingleEventError(event, error, {}) + } + ) + failedEvents ?? [] + + - name: finalPayload + template: | + [...$.outputs.processRecordEvents, ...$.outputs.failOtherEvents] diff --git a/src/cdk/v2/destinations/zoho/transformRecord.js b/src/cdk/v2/destinations/zoho/transformRecord.js new file mode 100644 index 0000000000..8f4586e46b --- /dev/null +++ b/src/cdk/v2/destinations/zoho/transformRecord.js @@ -0,0 +1,338 @@ +const { + InstrumentationError, + getHashFromArray, + ConfigurationError, + RetryableError, +} = require('@rudderstack/integrations-lib'); +const { BatchUtils } = require('@rudderstack/workflow-engine'); +const { + defaultPostRequestConfig, + defaultRequestConfig, + getSuccessRespEvents, + removeUndefinedAndNullValues, + handleRtTfSingleEventError, + isEmptyObject, + defaultDeleteRequestConfig, +} = require('../../../../v0/util'); +const zohoConfig = require('./config'); +const { + deduceModuleInfo, + validatePresenceOfMandatoryProperties, + formatMultiSelectFields, + handleDuplicateCheck, + searchRecordId, + calculateTrigger, + validateConfigurationIssue, +} = require('./utils'); +const { REFRESH_TOKEN } = require('../../../../adapters/networkhandler/authConstants'); + +// Main response builder function +const responseBuilder = ( + items, + config, + identifierType, + operationModuleType, + commonEndPoint, + action, + metadata, +) => { + const { trigger, addDefaultDuplicateCheck, multiSelectFieldLevelDecision } = config; + + const response = defaultRequestConfig(); + response.headers = { + Authorization: `Zoho-oauthtoken ${metadata[0].secret.accessToken}`, + }; + + if (action === 'insert' || action === 'update') { + const payload = { + duplicate_check_fields: handleDuplicateCheck( + addDefaultDuplicateCheck, + identifierType, + operationModuleType, + ), + data: items, + $append_values: getHashFromArray(multiSelectFieldLevelDecision, 'from', 'to', false), + trigger: calculateTrigger(trigger), + }; + response.method = defaultPostRequestConfig.requestMethod; + response.body.JSON = removeUndefinedAndNullValues(payload); + response.endpoint = `${commonEndPoint}/upsert`; + } else { + response.endpoint = `${commonEndPoint}?ids=${items.join(',')}&wf_trigger=${trigger !== 'None'}`; + response.method = defaultDeleteRequestConfig.requestMethod; + } + + return response; +}; +const batchResponseBuilder = ( + transformedResponseToBeBatched, + config, + identifierType, + operationModuleType, + upsertEndPoint, + action, +) => { + const upsertResponseArray = []; + const deletionResponseArray = []; + const { upsertData, deletionData, upsertSuccessMetadata, deletionSuccessMetadata } = + transformedResponseToBeBatched; + + const upsertDataChunks = BatchUtils.chunkArrayBySizeAndLength(upsertData, { + maxItems: zohoConfig.MAX_BATCH_SIZE, + }); + + const deletionDataChunks = BatchUtils.chunkArrayBySizeAndLength(deletionData, { + maxItems: zohoConfig.MAX_BATCH_SIZE, + }); + + const upsertmetadataChunks = BatchUtils.chunkArrayBySizeAndLength(upsertSuccessMetadata, { + maxItems: zohoConfig.MAX_BATCH_SIZE, + }); + + const deletionmetadataChunks = BatchUtils.chunkArrayBySizeAndLength(deletionSuccessMetadata, { + maxItems: zohoConfig.MAX_BATCH_SIZE, + }); + + upsertDataChunks.items.forEach((chunk) => { + upsertResponseArray.push( + responseBuilder( + chunk, + config, + identifierType, + operationModuleType, + upsertEndPoint, + action, + upsertmetadataChunks.items[0], + ), + ); + }); + + deletionDataChunks.items.forEach((chunk) => { + deletionResponseArray.push( + responseBuilder( + chunk, + config, + identifierType, + operationModuleType, + upsertEndPoint, + action, + deletionmetadataChunks.items[0], + ), + ); + }); + + return { + upsertResponseArray, + upsertmetadataChunks, + deletionResponseArray, + deletionmetadataChunks, + }; +}; + +/** + * Handles the upsert operation for a specific module type by validating mandatory properties, + * processing the input fields, and updating the response accordingly. + * + * @param {Object} input - The input data for the upsert operation. + * @param {Object} fields - The fields to be upserted. + * @param {string} operationModuleType - The type of module operation being performed. + * @param {Object} Config - The configuration object. + * @param {Object} transformedResponseToBeBatched - The response object to be batched. + * @param {Array} errorResponseList - The list to store error responses. + * @returns {Promise} - A promise that resolves once the upsert operation is handled. + */ +const handleUpsert = async ( + input, + fields, + operationModuleType, + Config, + transformedResponseToBeBatched, + errorResponseList, +) => { + const eventErroneous = validatePresenceOfMandatoryProperties(operationModuleType, fields); + + if (eventErroneous?.status) { + const error = new ConfigurationError( + `${operationModuleType} object must have the ${eventErroneous.missingField.join('", "')} property(ies).`, + ); + errorResponseList.push(handleRtTfSingleEventError(input, error, {})); + } else { + const formattedFields = formatMultiSelectFields(Config, fields); + transformedResponseToBeBatched.upsertSuccessMetadata.push(input.metadata); + transformedResponseToBeBatched.upsertData.push(formattedFields); + } +}; + +/** + * Handles search errors in Zoho record search. + * If the search response message code is 'INVALID_TOKEN', returns a RetryableError with a specific message and status code. + * Otherwise, returns a ConfigurationError with a message indicating failure to fetch Zoho ID for a record. + * + * @param {Object} searchResponse - The response object from the search operation. + * @returns {RetryableError|ConfigurationError} - The error object based on the search response. + */ +const handleSearchError = (searchResponse) => { + if (searchResponse.message.code === 'INVALID_TOKEN') { + return new RetryableError( + `[Zoho]:: ${JSON.stringify(searchResponse.message)} during zoho record search`, + 500, + searchResponse.message, + REFRESH_TOKEN, + ); + } + return new ConfigurationError( + `failed to fetch zoho id for record for ${JSON.stringify(searchResponse.message)}`, + ); +}; + +/** + * Asynchronously handles the deletion operation based on the search response. + * + * @param {Object} input - The input object containing metadata and other details. + * @param {Array} fields - The fields to be used for searching the record. + * @param {Object} Config - The configuration object. + * @param {Object} transformedResponseToBeBatched - The object to store transformed response data to be batched. + * @param {Array} errorResponseList - The list to store error responses. + */ +const handleDeletion = async ( + input, + fields, + Config, + transformedResponseToBeBatched, + errorResponseList, +) => { + const searchResponse = await searchRecordId(fields, input.metadata, Config); + + if (searchResponse.erroneous) { + const error = handleSearchError(searchResponse); + errorResponseList.push(handleRtTfSingleEventError(input, error, {})); + } else { + transformedResponseToBeBatched.deletionData.push(...searchResponse.message); + transformedResponseToBeBatched.deletionSuccessMetadata.push(input.metadata); + } +}; + +/** + * Process the input message based on the specified action. + * If the 'fields' in the input message are empty, an error is generated. + * Determines whether to handle an upsert operation or a deletion operation based on the action. + * + * @param {Object} input - The input message containing the fields. + * @param {string} action - The action to be performed ('insert', 'update', or other). + * @param {string} operationModuleType - The type of operation module. + * @param {Object} Config - The configuration object. + * @param {Object} transformedResponseToBeBatched - The object to store transformed responses. + * @param {Array} errorResponseList - The list to store error responses. + */ +const processInput = async ( + input, + action, + operationModuleType, + Config, + transformedResponseToBeBatched, + errorResponseList, +) => { + const { fields } = input.message; + + if (isEmptyObject(fields)) { + const emptyFieldsError = new InstrumentationError('`fields` cannot be empty'); + errorResponseList.push(handleRtTfSingleEventError(input, emptyFieldsError, {})); + return; + } + + if (action === 'insert' || action === 'update') { + await handleUpsert( + input, + fields, + operationModuleType, + Config, + transformedResponseToBeBatched, + errorResponseList, + ); + } else { + await handleDeletion(input, fields, Config, transformedResponseToBeBatched, errorResponseList); + } +}; + +/** + * Appends success responses to the main response array. + * + * @param {Array} response - The main response array to which success responses will be appended. + * @param {Array} responseArray - An array of batched responses. + * @param {Array} metadataChunks - An array containing metadata chunks. + * @param {string} destination - The destination for the success responses. + */ +const appendSuccessResponses = (response, responseArray, metadataChunks, destination) => { + responseArray.forEach((batchedResponse, index) => { + response.push( + getSuccessRespEvents(batchedResponse, metadataChunks.items[index], destination, true), + ); + }); +}; + +/** + * Process multiple record inputs for a destination. + * + * @param {Array} inputs - The array of record inputs to be processed. + * @param {Object} destination - The destination object containing configuration. + * @returns {Array} - An array of responses after processing the record inputs. + */ +const processRecordInputs = async (inputs, destination) => { + if (!inputs || inputs.length === 0) { + return []; + } + + const response = []; + const errorResponseList = []; + const { Config } = destination; + const { action } = inputs[0].message; + + const transformedResponseToBeBatched = { + upsertData: [], + upsertSuccessMetadata: [], + deletionSuccessMetadata: [], + deletionData: [], + }; + + const { operationModuleType, identifierType, upsertEndPoint } = deduceModuleInfo(inputs, Config); + + validateConfigurationIssue(Config, operationModuleType, action); + + await Promise.all( + inputs.map((input) => + processInput( + input, + action, + operationModuleType, + Config, + transformedResponseToBeBatched, + errorResponseList, + ), + ), + ); + + const { + upsertResponseArray, + upsertmetadataChunks, + deletionResponseArray, + deletionmetadataChunks, + } = batchResponseBuilder( + transformedResponseToBeBatched, + Config, + identifierType, + operationModuleType, + upsertEndPoint, + action, + ); + + if (upsertResponseArray.length === 0 && deletionResponseArray.length === 0) { + return errorResponseList; + } + + appendSuccessResponses(response, upsertResponseArray, upsertmetadataChunks, destination); + appendSuccessResponses(response, deletionResponseArray, deletionmetadataChunks, destination); + + return [...response, ...errorResponseList]; +}; + +module.exports = { processRecordInputs }; diff --git a/src/cdk/v2/destinations/zoho/utils.js b/src/cdk/v2/destinations/zoho/utils.js new file mode 100644 index 0000000000..8b170d2b82 --- /dev/null +++ b/src/cdk/v2/destinations/zoho/utils.js @@ -0,0 +1,168 @@ +const { + MappedToDestinationKey, + getHashFromArray, + isDefinedAndNotNull, + ConfigurationError, +} = require('@rudderstack/integrations-lib'); +const get = require('get-value'); +const { getDestinationExternalIDInfoForRetl, isHttpStatusSuccess } = require('../../../../v0/util'); +const zohoConfig = require('./config'); +const { handleHttpRequest } = require('../../../../adapters/network'); + +const deduceModuleInfo = (inputs, Config) => { + const singleRecordInput = inputs[0].message; + const operationModuleInfo = {}; + const mappedToDestination = get(singleRecordInput, MappedToDestinationKey); + if (mappedToDestination) { + const { objectType, identifierType } = getDestinationExternalIDInfoForRetl( + singleRecordInput, + 'ZOHO', + ); + operationModuleInfo.operationModuleType = objectType; + operationModuleInfo.upsertEndPoint = zohoConfig + .COMMON_RECORD_ENDPOINT(Config.region) + .replace('moduleType', objectType); + operationModuleInfo.identifierType = identifierType; + } + return operationModuleInfo; +}; + +// eslint-disable-next-line consistent-return +function validatePresenceOfMandatoryProperties(objectName, object) { + if (zohoConfig.MODULE_MANDATORY_FIELD_CONFIG.hasOwnProperty(objectName)) { + const requiredFields = zohoConfig.MODULE_MANDATORY_FIELD_CONFIG[objectName]; + const missingFields = requiredFields.filter((field) => !object.hasOwnProperty(field)) || []; + return { status: missingFields.length > 0, missingField: missingFields }; + } + // No mandatory check performed for custom objects +} + +const formatMultiSelectFields = (config, fields) => { + // Convert multiSelectFieldLevelDecision array into a hash map for quick lookups + const multiSelectFields = getHashFromArray( + config.multiSelectFieldLevelDecision, + 'from', + 'to', + false, + ); + + Object.keys(fields).forEach((eachFieldKey) => { + if (multiSelectFields.hasOwnProperty(eachFieldKey)) { + // eslint-disable-next-line no-param-reassign + fields[eachFieldKey] = [fields[eachFieldKey]]; + } + }); + return fields; +}; + +// Utility to handle duplicate check +const handleDuplicateCheck = (addDefaultDuplicateCheck, identifierType, operationModuleType) => { + let duplicateCheckFields = [identifierType]; + + if (addDefaultDuplicateCheck) { + const moduleDuplicateCheckField = + zohoConfig.MODULE_WISE_DUPLICATE_CHECK_FIELD[operationModuleType]; + + if (isDefinedAndNotNull(moduleDuplicateCheckField)) { + duplicateCheckFields = [...moduleDuplicateCheckField]; + duplicateCheckFields.unshift(identifierType); + } else { + duplicateCheckFields.push('Name'); // user chosen duplicate field always carries higher priority + } + } + + return [...new Set(duplicateCheckFields)]; +}; + +function escapeAndEncode(value) { + return encodeURIComponent(value.replace(/([(),\\])/g, '\\$1')); +} + +function transformToURLParams(fields, Config) { + const criteria = Object.entries(fields) + .map(([key, value]) => `(${key}:equals:${escapeAndEncode(value)})`) + .join('and'); + + const dataCenter = Config.region; + const regionBasedEndPoint = zohoConfig.DATA_CENTRE_BASE_ENDPOINTS_MAP[dataCenter]; + + return `${regionBasedEndPoint}/crm/v6/Leads/search?criteria=${criteria}`; +} + +// ref : https://www.zoho.com/crm/developer/docs/api/v6/search-records.html +const searchRecordId = async (fields, metadata, Config) => { + const searchURL = transformToURLParams(fields, Config); + const searchResult = await handleHttpRequest( + 'get', + searchURL, + { + headers: { + Authorization: `Zoho-oauthtoken ${metadata.secret.accessToken}`, + }, + }, + { + destType: 'zoho', + feature: 'deleteRecords', + requestMethod: 'GET', + endpointPath: 'crm/v6/Leads/search?criteria=', + module: 'router', + }, + ); + if (!isHttpStatusSuccess(searchResult.processedResponse.status)) { + return { + erroneous: true, + message: searchResult.processedResponse.response, + }; + } + if (searchResult.processedResponse.status === 204) { + return { + erroneous: true, + message: 'No contact is found with record details', + }; + } + const recordIds = searchResult.processedResponse.response.data.map((record) => record.id); + return { + erroneous: false, + message: recordIds, + }; +}; + +// ref : https://www.zoho.com/crm/developer/docs/api/v6/upsert-records.html#:~:text=The%20trigger%20input%20can%20be%20workflow%2C%20approval%2C%20or%20blueprint.%20If%20the%20trigger%20is%20not%20mentioned%2C%20the%20workflows%2C%20approvals%20and%20blueprints%20related%20to%20the%20API%20will%20get%20executed.%20Enter%20the%20trigger%20value%20as%20%5B%5D%20to%20not%20execute%20the%20workflows. +const calculateTrigger = (trigger) => { + if (trigger === 'Default') { + return null; + } + if (trigger === 'None') { + return []; + } + return [trigger]; +}; + +const validateConfigurationIssue = (Config, operationModuleType, action) => { + const hashMapMultiselect = getHashFromArray( + Config.multiSelectFieldLevelDecision, + 'from', + 'to', + false, + ); + if ( + Object.keys(hashMapMultiselect).length > 0 && + Config.module !== operationModuleType && + action !== 'delete' + ) { + throw new ConfigurationError( + 'Object Chosen in Visual Data Mapper is not consistent with Module type selected in destination configuration. Aborting Events.', + ); + } +}; + +module.exports = { + deduceModuleInfo, + validatePresenceOfMandatoryProperties, + formatMultiSelectFields, + handleDuplicateCheck, + searchRecordId, + transformToURLParams, + calculateTrigger, + validateConfigurationIssue, +}; diff --git a/src/cdk/v2/destinations/zoho/utils.test.js b/src/cdk/v2/destinations/zoho/utils.test.js new file mode 100644 index 0000000000..332a408695 --- /dev/null +++ b/src/cdk/v2/destinations/zoho/utils.test.js @@ -0,0 +1,245 @@ +const { + handleDuplicateCheck, + deduceModuleInfo, + validatePresenceOfMandatoryProperties, + formatMultiSelectFields, + validateConfigurationIssue, +} = require('./utils'); + +const { ConfigurationError } = require('@rudderstack/integrations-lib'); + +describe('handleDuplicateCheck', () => { + // Returns identifierType when addDefaultDuplicateCheck is false + it('should return identifierType when addDefaultDuplicateCheck is false', () => { + const identifierType = 'email'; + const addDefaultDuplicateCheck = false; + const operationModuleType = 'Leads'; + const moduleWiseDuplicateCheckField = {}; + + const result = handleDuplicateCheck( + addDefaultDuplicateCheck, + identifierType, + operationModuleType, + moduleWiseDuplicateCheckField, + ); + + expect(result).toEqual([identifierType]); + }); + + it('Handles valid operationModuleType and already included identifierType', () => { + const identifierType = 'Email'; + const addDefaultDuplicateCheck = true; + const operationModuleType = 'Leads'; + + const result = handleDuplicateCheck( + addDefaultDuplicateCheck, + identifierType, + operationModuleType, + ); + + expect(result).toEqual(['Email']); + }); + + // Returns identifierType and 'Name' when addDefaultDuplicateCheck is true and moduleDuplicateCheckField is not defined + it("should return identifierType and 'Name' when addDefaultDuplicateCheck is true and moduleDuplicateCheckField is not defined", () => { + const identifierType = 'id'; + const operationModuleType = 'type3'; + const addDefaultDuplicateCheck = true; + + const result = handleDuplicateCheck( + addDefaultDuplicateCheck, + identifierType, + operationModuleType, + ); + + expect(result).toEqual(['id', 'Name']); + }); + + // Handles null values in moduleWiseDuplicateCheckField + it('should handle null values in moduleWiseDuplicateCheckField', () => { + const addDefaultDuplicateCheck = true; + const identifierType = 'Identifier'; + const operationModuleType = 'type1'; + + const result = handleDuplicateCheck( + addDefaultDuplicateCheck, + identifierType, + operationModuleType, + ); + + expect(result).toEqual(['Identifier', 'Name']); + }); +}); + +describe('deduceModuleInfo', () => { + const Config = { region: 'US' }; + + it('should return empty object when mappedToDestination is not present', () => { + const inputs = [{}]; + const result = deduceModuleInfo(inputs, Config); + expect(result).toEqual({}); + }); + + it('should return operationModuleInfo when mappedToDestination is present', () => { + const inputs = [ + { + message: { + context: { + externalId: [{ type: 'ZOHO-Leads', id: '12345', identifierType: 'Email' }], + mappedToDestination: true, + }, + }, + }, + ]; + + const result = deduceModuleInfo(inputs, Config); + expect(result).toEqual({ + operationModuleType: 'Leads', + upsertEndPoint: 'https://www.zohoapis.com/crm/v6/Leads', + identifierType: 'Email', + }); + }); + + it('should handle different regions in config', () => { + const inputs = [ + { + message: { + context: { + externalId: [{ type: 'ZOHO-Leads', id: '12345', identifierType: 'Email' }], + mappedToDestination: 'true', + }, + }, + }, + ]; + const Config = { region: 'EU' }; + + const result = deduceModuleInfo(inputs, Config); + expect(result).toEqual({ + operationModuleType: 'Leads', + upsertEndPoint: 'https://www.zohoapis.eu/crm/v6/Leads', + identifierType: 'Email', + }); + }); +}); + +describe('validatePresenceOfMandatoryProperties', () => { + it('should not throw an error if the object has all required fields', () => { + const objectName = 'Leads'; + const object = { Last_Name: 'Doe' }; + + expect(() => validatePresenceOfMandatoryProperties(objectName, object)).not.toThrow(); + }); + + it('should not throw an error if the objectName is not in MODULE_MANDATORY_FIELD_CONFIG', () => { + const objectName = 'CustomObject'; + const object = { Some_Field: 'Some Value' }; + + expect(() => validatePresenceOfMandatoryProperties(objectName, object)).not.toThrow(); + }); + + it('should throw an error if the object is missing multiple required fields', () => { + const objectName = 'Deals'; + const object = { Deal_Name: 'Big Deal' }; + const output = validatePresenceOfMandatoryProperties(objectName, object); + expect(output).toEqual({ + missingField: ['Stage', 'Pipeline'], + status: true, + }); + }); + + it('should not throw an error if the object has all required fields for Deals', () => { + const objectName = 'Deals'; + const object = { Deal_Name: 'Big Deal', Stage: 'Negotiation', Pipeline: 'Sales' }; + + expect(() => validatePresenceOfMandatoryProperties(objectName, object)).not.toThrow(); + }); +}); + +describe('validateConfigurationIssue', () => { + test('should throw ConfigurationError when hashMapMultiselect is not empty, Config.module is different from operationModuleType, and action is not delete', () => { + const Config = { + multiSelectFieldLevelDecision: [{ from: 'field1', to: 'true' }], + module: 'moduleA', + }; + const operationModuleType = 'moduleB'; + const action = 'create'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).toThrow( + ConfigurationError, + ); + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).toThrow( + 'Object Chosen in Visual Data Mapper is not consistent with Module type selected in destination configuration. Aborting Events.', + ); + }); + + test('should not throw an error when hashMapMultiselect is not empty, Config.module is the same as operationModuleType, and action is not delete', () => { + const Config = { + multiSelectFieldLevelDecision: [{ from: 'field1', to: 'true' }], + module: 'moduleA', + }; + const operationModuleType = 'moduleA'; + const action = 'create'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).not.toThrow(); + }); + + test('should not throw an error when hashMapMultiselect is empty, Config.module is different from operationModuleType, and action is not delete', () => { + const Config = { + multiSelectFieldLevelDecision: [], + module: 'moduleA', + }; + const operationModuleType = 'moduleB'; + const action = 'create'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).not.toThrow(); + }); + + test('should not throw an error when hashMapMultiselect is empty, Config.module is the same as operationModuleType, and action is not delete', () => { + const Config = { + multiSelectFieldLevelDecision: [], + module: 'moduleA', + }; + const operationModuleType = 'moduleA'; + const action = 'create'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).not.toThrow(); + }); + + test('should not throw an error when multiSelectFieldLevelDecision has entries without from key', () => { + const Config = { + multiSelectFieldLevelDecision: [{ to: 'true' }], + module: 'moduleA', + }; + const operationModuleType = 'moduleB'; + const action = 'create'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).not.toThrow(); + }); + + test('should throw ConfigurationError when multiSelectFieldLevelDecision has mixed case from keys, Config.module is different from operationModuleType, and action is not delete', () => { + const Config = { + multiSelectFieldLevelDecision: [ + { from: 'FIELD1', to: 'true' }, + { from: 'field2', to: 'false' }, + ], + module: 'moduleA', + }; + const operationModuleType = 'moduleB'; + const action = 'create'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).toThrow( + ConfigurationError, + ); + }); + + test('should not throw an error when hashMapMultiselect is not empty, Config.module is different from operationModuleType, and action is delete', () => { + const Config = { + multiSelectFieldLevelDecision: [{ from: 'field1', to: 'true' }], + module: 'moduleA', + }; + const operationModuleType = 'moduleB'; + const action = 'delete'; + + expect(() => validateConfigurationIssue(Config, operationModuleType, action)).not.toThrow(); + }); +}); diff --git a/src/constants/destinationCanonicalNames.js b/src/constants/destinationCanonicalNames.js index 915ac50b26..f99c735e45 100644 --- a/src/constants/destinationCanonicalNames.js +++ b/src/constants/destinationCanonicalNames.js @@ -101,6 +101,14 @@ const DestCanonicalNames = { awin: ['awin', 'Awin', 'AWIN'], sendinblue: ['sendinblue', 'SENDINBLUE', 'Sendinblue', 'SendinBlue'], ga4: ['GA4', 'ga4', 'Ga4', 'Google Analytics 4', 'googleAnalytics4', 'Google Analytics 4 (GA4)'], + ga4_v2: [ + 'GA4_V2', + 'ga4_v2', + 'Ga4_v2', + 'Google Analytics 4 V2', + 'googleAnalytics4V2', + 'Google Analytics 4 (GA4) V2', + ], pipedream: ['Pipedream', 'PipeDream', 'pipedream', 'PIPEDREAM'], pagerduty: ['pagerduty', 'PAGERDUTY', 'PagerDuty', 'Pagerduty', 'pagerDuty'], adobe_analytics: [ @@ -173,8 +181,11 @@ const DestCanonicalNames = { 'Klaviyo Bulk Upload', 'klaviyobulkupload', ], + Klaviyo: ['KLAVIYO', 'Klaviyo', 'klaviyo'], emarsys: ['EMARSYS', 'Emarsys', 'emarsys'], wunderkind: ['wunderkind', 'Wunderkind', 'WUNDERKIND'], + cordial: ['cordial', 'Cordial', 'CORDIAL'], + clevertap: ['clevertap', 'Clevertap', 'CleverTap', 'CLEVERTAP'], }; module.exports = { DestHandlerMap, DestCanonicalNames }; diff --git a/src/controllers/source.ts b/src/controllers/source.ts index bc4b77bd3d..230636f193 100644 --- a/src/controllers/source.ts +++ b/src/controllers/source.ts @@ -18,6 +18,7 @@ export class SourceController { version, events, ); + const resplist = await integrationService.sourceTransformRoutine( input, source, diff --git a/src/features.json b/src/features.json index ade8c90439..77ab5cb243 100644 --- a/src/features.json +++ b/src/features.json @@ -74,7 +74,12 @@ "EMARSYS": true, "KODDI": true, "WUNDERKIND": true, - "CLICKSEND": true + "CLICKSEND": true, + "ZOHO": true, + "CORDIAL": true, + "BLOOMREACH_CATALOG": true, + "SMARTLY": true, + "WEBHOOK_V2": true }, "regulations": [ "BRAZE", diff --git a/src/helpers/__tests__/serviceSelector.test.ts b/src/helpers/__tests__/serviceSelector.test.ts index c48d6bbe8b..0dab906f7a 100644 --- a/src/helpers/__tests__/serviceSelector.test.ts +++ b/src/helpers/__tests__/serviceSelector.test.ts @@ -1,9 +1,8 @@ -import { ServiceSelector } from '../serviceSelector'; import { INTEGRATION_SERVICE } from '../../routes/utils/constants'; -import { ProcessorTransformationRequest } from '../../types/index'; -import { CDKV1DestinationService } from '../../services/destination/cdkV1Integration'; import { CDKV2DestinationService } from '../../services/destination/cdkV2Integration'; import { NativeIntegrationDestinationService } from '../../services/destination/nativeIntegration'; +import { ProcessorTransformationRequest } from '../../types/index'; +import { ServiceSelector } from '../serviceSelector'; afterEach(() => { jest.clearAllMocks(); @@ -27,20 +26,6 @@ describe('ServiceSelector Service', () => { ); }); - test('isCdkDestination should return true', async () => { - const destinationDefinitionConfig = { - cdkEnabled: true, - }; - expect(ServiceSelector['isCdkDestination'](destinationDefinitionConfig)).toBe(true); - }); - - test('isCdkDestination should return false', async () => { - const destinationDefinitionConfig = { - cdkEnabledXYZ: true, - }; - expect(ServiceSelector['isCdkDestination'](destinationDefinitionConfig)).toBe(false); - }); - test('isCdkV2Destination should return true', async () => { const destinationDefinitionConfig = { cdkV2Enabled: true, @@ -55,23 +40,6 @@ describe('ServiceSelector Service', () => { expect(ServiceSelector['isCdkV2Destination'](destinationDefinitionConfig)).toBe(false); }); - test('getPrimaryDestinationService should return cdk v1 dest service', async () => { - const events = [ - { - destination: { - DestinationDefinition: { - Config: { - cdkEnabled: true, - }, - }, - }, - }, - ] as ProcessorTransformationRequest[]; - expect(ServiceSelector['getPrimaryDestinationService'](events)).toBeInstanceOf( - CDKV1DestinationService, - ); - }); - test('getPrimaryDestinationService should return cdk v2 dest service', async () => { const events = [ { diff --git a/src/helpers/serviceSelector.ts b/src/helpers/serviceSelector.ts index faa1c58240..a1f6a43349 100644 --- a/src/helpers/serviceSelector.ts +++ b/src/helpers/serviceSelector.ts @@ -1,29 +1,23 @@ import { PlatformError } from '@rudderstack/integrations-lib'; -import { ProcessorTransformationRequest, RouterTransformationRequestData } from '../types/index'; +import { DestinationService } from '../interfaces/DestinationService'; +import { SourceService } from '../interfaces/SourceService'; import { INTEGRATION_SERVICE } from '../routes/utils/constants'; -import { CDKV1DestinationService } from '../services/destination/cdkV1Integration'; +import { ComparatorService } from '../services/comparator'; import { CDKV2DestinationService } from '../services/destination/cdkV2Integration'; -import { DestinationService } from '../interfaces/DestinationService'; import { NativeIntegrationDestinationService } from '../services/destination/nativeIntegration'; -import { SourceService } from '../interfaces/SourceService'; import { NativeIntegrationSourceService } from '../services/source/nativeIntegration'; -import { ComparatorService } from '../services/comparator'; +import { ProcessorTransformationRequest, RouterTransformationRequestData } from '../types/index'; import { FixMe } from '../util/types'; export class ServiceSelector { private static serviceMap: Map = new Map(); private static services = { - [INTEGRATION_SERVICE.CDK_V1_DEST]: CDKV1DestinationService, [INTEGRATION_SERVICE.CDK_V2_DEST]: CDKV2DestinationService, [INTEGRATION_SERVICE.NATIVE_DEST]: NativeIntegrationDestinationService, [INTEGRATION_SERVICE.NATIVE_SOURCE]: NativeIntegrationSourceService, }; - private static isCdkDestination(destinationDefinitionConfig: FixMe) { - return !!destinationDefinitionConfig?.cdkEnabled; - } - private static isCdkV2Destination(destinationDefinitionConfig: FixMe) { return Boolean(destinationDefinitionConfig?.cdkV2Enabled); } @@ -68,9 +62,6 @@ export class ServiceSelector { ): DestinationService { const destinationDefinitionConfig: FixMe = events[0]?.destination?.DestinationDefinition?.Config; - if (this.isCdkDestination(destinationDefinitionConfig)) { - return this.fetchCachedService(INTEGRATION_SERVICE.CDK_V1_DEST); - } if (this.isCdkV2Destination(destinationDefinitionConfig)) { return this.fetchCachedService(INTEGRATION_SERVICE.CDK_V2_DEST); } diff --git a/src/legacy/router.js b/src/legacy/router.js index 6cf035350c..60f786e225 100644 --- a/src/legacy/router.js +++ b/src/legacy/router.js @@ -18,7 +18,6 @@ const { isNonFuncObject, getMetadata, generateErrorObject, - isCdkDestination, checkAndCorrectUserId, } = require('../v0/util'); const { processDynamicConfig } = require('../util/dynamicConfig'); @@ -35,12 +34,9 @@ const { sendViolationMetrics, constructValidationErrors, } = require('../util/utils'); -const { processCdkV1 } = require('../cdk/v1/handler'); const { extractLibraries } = require('../util/customTransformer'); const { getCompatibleStatusCode } = require('../adapters/utils/networkUtils'); -const CDK_V1_DEST_PATH = 'cdk/v1'; - const transformerMode = process.env.TRANSFORMER_MODE; const startDestTransformer = transformerMode === 'destination' || !transformerMode; @@ -157,14 +153,11 @@ async function handleDest(ctx, version, destination) { parsedEvent.request = { query: reqParams }; parsedEvent = processDynamicConfig(parsedEvent); let respEvents; - if (isCdkDestination(parsedEvent)) { - respEvents = await processCdkV1(destination, parsedEvent); - } else { - if (destHandler === null) { - destHandler = getDestHandler(version, destination); - } - respEvents = await handleV0Destination(destHandler.process, [parsedEvent]); + if (destHandler === null) { + destHandler = getDestHandler(version, destination); } + respEvents = await handleV0Destination(destHandler.process, [parsedEvent]); + if (respEvents) { if (!Array.isArray(respEvents)) { respEvents = [respEvents]; @@ -185,12 +178,8 @@ async function handleDest(ctx, version, destination) { } catch (error) { logger.error(error); - let implementation = tags.IMPLEMENTATIONS.NATIVE; - let errCtx = 'Processor Transformation'; - if (isCdkDestination(event)) { - errCtx = `CDK - ${errCtx}`; - implementation = tags.IMPLEMENTATIONS.CDK_V1; - } + const implementation = tags.IMPLEMENTATIONS.NATIVE; + const errCtx = 'Processor Transformation'; const errObj = generateErrorObject(error, { [tags.TAG_NAMES.DEST_TYPE]: destination.toUpperCase(), @@ -432,7 +421,6 @@ async function routerHandleDest(ctx) { if (startDestTransformer) { SUPPORTED_VERSIONS.forEach((version) => { const destinations = getIntegrations(path.resolve(__dirname, `../${version}/destinations`)); - destinations.push(...getIntegrations(path.resolve(__dirname, `../${CDK_V1_DEST_PATH}`))); destinations.forEach((destination) => { // eg. v0/destinations/ga router.post(`/${version}/destinations/${destination}`, async (ctx) => { diff --git a/src/routerUtils.js b/src/routerUtils.js index ff9dd4b6f8..081070d78a 100644 --- a/src/routerUtils.js +++ b/src/routerUtils.js @@ -22,6 +22,7 @@ const userTransformHandler = () => { async function sendToDestination(destination, payload) { let parsedResponse; logger.info('Request recieved for destination', destination); + const resp = await proxyRequest(payload); if (resp.success) { diff --git a/src/services/comparator.ts b/src/services/comparator.ts index 0e28339797..1eb67cd597 100644 --- a/src/services/comparator.ts +++ b/src/services/comparator.ts @@ -33,6 +33,7 @@ export class ComparatorService implements DestinationService { public init(): void { this.primaryService.init(); + this.secondaryService.init(); } diff --git a/src/services/destination/cdkV1Integration.ts b/src/services/destination/cdkV1Integration.ts deleted file mode 100644 index c6e60f5857..0000000000 --- a/src/services/destination/cdkV1Integration.ts +++ /dev/null @@ -1,134 +0,0 @@ -/* eslint-disable @typescript-eslint/no-unused-vars */ -import { ConfigFactory, Executor, RudderBaseConfig } from 'rudder-transformer-cdk'; -import path from 'path'; -import { TransformationError } from '@rudderstack/integrations-lib'; -import { DestinationService } from '../../interfaces/DestinationService'; -import { - DeliveryV0Response, - ErrorDetailer, - MetaTransferObject, - ProcessorTransformationRequest, - ProcessorTransformationResponse, - RouterTransformationRequestData, - RouterTransformationResponse, - UserDeletionRequest, - UserDeletionResponse, - ProxyRequest, - DeliveryV1Response, -} from '../../types/index'; -import { DestinationPostTransformationService } from './postTransformation'; -import tags from '../../v0/util/tags'; -import { getErrorInfo } from '../../cdk/v1/handler'; -import { CatchErr } from '../../util/types'; - -export class CDKV1DestinationService implements DestinationService { - public init() { - ConfigFactory.init({ - basePath: path.resolve(__dirname, '../../cdk/v1'), - loggingMode: 'production', - }); - } - - public getName(): string { - return 'CDK_V1'; - } - - public getTags( - destType: string, - destinationId: string, - workspaceId: string, - feature: string, - ): MetaTransferObject { - const metaTO = { - errorDetails: { - destType: destType.toUpperCase(), - module: tags.MODULES.DESTINATION, - implementation: tags.IMPLEMENTATIONS.CDK_V1, - feature, - destinationId, - workspaceId, - } as ErrorDetailer, - errorContext: '[CDKV1 Integration Service] Failure During Proc Transform', - } as MetaTransferObject; - return metaTO; - } - - private async processCDKV1(event: any, tfConfig: RudderBaseConfig): Promise { - try { - const respEvents = await Executor.execute(event, tfConfig); - return respEvents; - } catch (error) { - throw getErrorInfo(error); - } - } - - public async doProcessorTransformation( - events: ProcessorTransformationRequest[], - destinationType: string, - _version: string, - _requestMetadata: NonNullable, - ): Promise { - const tfConfig = await ConfigFactory.getConfig(destinationType); - const respList: ProcessorTransformationResponse[][] = await Promise.all( - events.map(async (event) => { - try { - const transformedPayloads: any = await this.processCDKV1(event as any, tfConfig); - // We are not passing destinationHandler to post processor as we don't have post processing in CDK flows - return DestinationPostTransformationService.handleProcessorTransformSucessEvents( - event, - transformedPayloads, - undefined, - ); - } catch (error: CatchErr) { - const metaTO = this.getTags( - destinationType, - event.metadata.destinationId, - event.metadata.workspaceId, - tags.FEATURES.PROCESSOR, - ); - metaTO.metadata = event.metadata; - const erroredResp = - DestinationPostTransformationService.handleProcessorTransformFailureEvents( - error, - metaTO, - ); - return [erroredResp]; - } - }), - ); - return respList.flat(); - } - - public doRouterTransformation( - _events: RouterTransformationRequestData[], - _destinationType: string, - _version: string, - _requestMetadata: NonNullable, - ): Promise { - throw new TransformationError('CDKV1 Does not Implement Router Transform Routine'); - } - - public doBatchTransformation( - _events: RouterTransformationRequestData[], - _destinationType: string, - _version: any, - _requestMetadata: NonNullable, - ): RouterTransformationResponse[] { - throw new TransformationError('CDKV1 Does not Implement Batch Transform Routine'); - } - - public deliver( - _event: ProxyRequest, - _destinationType: string, - _requestMetadata: NonNullable, - ): Promise { - throw new TransformationError('CDV1 Does not Implement Delivery Routine'); - } - - public processUserDeletion( - requests: UserDeletionRequest[], - rudderDestInfo: string, - ): Promise { - throw new TransformationError('CDV1 Does not Implement Deletion Routine'); - } -} diff --git a/src/services/source/__tests__/nativeIntegration.test.ts b/src/services/source/__tests__/nativeIntegration.test.ts index a2a5af041e..2ef8129cdc 100644 --- a/src/services/source/__tests__/nativeIntegration.test.ts +++ b/src/services/source/__tests__/nativeIntegration.test.ts @@ -8,22 +8,23 @@ afterEach(() => { jest.clearAllMocks(); }); +const headers = { + 'x-rudderstack-source': 'test', +}; + describe('NativeIntegration Source Service', () => { test('sourceTransformRoutine - success', async () => { const sourceType = '__rudder_test__'; const version = 'v0'; const requestMetadata = {}; - const event = { message: { a: 'b' } }; + const event = { message: { a: 'b' }, headers }; const events = [event, event]; - const tevent = { anonymousId: 'test' } as RudderMessage; + const tevent = { anonymousId: 'test', context: { headers } } as RudderMessage; const tresp = { output: { batch: [tevent] }, statusCode: 200 } as SourceTransformationResponse; - const tresponse = [ - { output: { batch: [{ anonymousId: 'test' }] }, statusCode: 200 }, - { output: { batch: [{ anonymousId: 'test' }] }, statusCode: 200 }, - ]; + const tresponse = [tresp, tresp]; FetchHandler.getSourceHandler = jest.fn().mockImplementationOnce((d, v) => { expect(d).toEqual(sourceType); diff --git a/src/services/source/__tests__/postTransformation.test.ts b/src/services/source/__tests__/postTransformation.test.ts index e5efbe8194..ea8b463bf9 100644 --- a/src/services/source/__tests__/postTransformation.test.ts +++ b/src/services/source/__tests__/postTransformation.test.ts @@ -5,6 +5,10 @@ import { } from '../../../types/index'; import { SourcePostTransformationService } from '../../source/postTransformation'; +const headers = { + 'x-rudderstack-source': 'test', +}; + describe('Source PostTransformation Service', () => { test('should handleFailureEventsSource', async () => { const e = new Error('test error'); @@ -26,24 +30,32 @@ describe('Source PostTransformation Service', () => { output: { batch: [{ anonymousId: 'test' }] }, } as SourceTransformationResponse; - const result = SourcePostTransformationService.handleSuccessEventsSource(event); + const postProcessedEvents = { + outputToSource: {}, + output: { batch: [{ anonymousId: 'test', context: { headers } }] }, + } as SourceTransformationResponse; - expect(result).toEqual(event); + const result = SourcePostTransformationService.handleSuccessEventsSource(event, { headers }); + + expect(result).toEqual(postProcessedEvents); }); test('should return the events as batch in SourceTransformationResponse if it is an array', () => { + const headers = { + 'x-rudderstack-source': 'test', + }; const events = [{ anonymousId: 'test' }, { anonymousId: 'test' }] as RudderMessage[]; + const postProcessedEvents = events.map((event) => ({ ...event, context: { headers } })); + const result = SourcePostTransformationService.handleSuccessEventsSource(events, { headers }); - const result = SourcePostTransformationService.handleSuccessEventsSource(events); - - expect(result).toEqual({ output: { batch: events } }); + expect(result).toEqual({ output: { batch: postProcessedEvents } }); }); test('should return the event as batch in SourceTransformationResponse if it is a single object', () => { const event = { anonymousId: 'test' } as RudderMessage; - const result = SourcePostTransformationService.handleSuccessEventsSource(event); + const result = SourcePostTransformationService.handleSuccessEventsSource(event, { headers }); - expect(result).toEqual({ output: { batch: [event] } }); + expect(result).toEqual({ output: { batch: [{ ...event, context: { headers } }] } }); }); }); diff --git a/src/services/source/nativeIntegration.ts b/src/services/source/nativeIntegration.ts index a4f26d068a..5c89de7b92 100644 --- a/src/services/source/nativeIntegration.ts +++ b/src/services/source/nativeIntegration.ts @@ -4,6 +4,7 @@ import { ErrorDetailer, MetaTransferObject, RudderMessage, + SourceTransformationEvent, SourceTransformationResponse, } from '../../types/index'; import stats from '../../util/stats'; @@ -27,7 +28,7 @@ export class NativeIntegrationSourceService implements SourceService { } public async sourceTransformRoutine( - sourceEvents: NonNullable[], + sourceEvents: NonNullable[], sourceType: string, version: string, // eslint-disable-next-line @typescript-eslint/no-unused-vars @@ -38,9 +39,12 @@ export class NativeIntegrationSourceService implements SourceService { const respList: SourceTransformationResponse[] = await Promise.all( sourceEvents.map(async (sourceEvent) => { try { + const newSourceEvent = sourceEvent; + const { headers } = newSourceEvent; + delete newSourceEvent.headers; const respEvents: RudderMessage | RudderMessage[] | SourceTransformationResponse = - await sourceHandler.process(sourceEvent); - return SourcePostTransformationService.handleSuccessEventsSource(respEvents); + await sourceHandler.process(newSourceEvent); + return SourcePostTransformationService.handleSuccessEventsSource(respEvents, { headers }); } catch (error: FixMe) { stats.increment('source_transform_errors', { source: sourceType, diff --git a/src/services/source/postTransformation.ts b/src/services/source/postTransformation.ts index 20c815171b..c62f0ed713 100644 --- a/src/services/source/postTransformation.ts +++ b/src/services/source/postTransformation.ts @@ -1,4 +1,5 @@ import { MetaTransferObject, RudderMessage, SourceTransformationResponse } from '../../types/index'; +import { CommonUtils } from '../../util/common'; import { CatchErr } from '../../util/types'; import { generateErrorObject } from '../../v0/util'; import { ErrorReportingService } from '../errorReporting'; @@ -20,16 +21,25 @@ export class SourcePostTransformationService { public static handleSuccessEventsSource( events: RudderMessage | RudderMessage[] | SourceTransformationResponse, + context: { headers?: Record }, ): SourceTransformationResponse { // We send response back to the source // through outputToSource. This is not sent to gateway // We will not return array for events not meant for gateway - if (Object.prototype.hasOwnProperty.call(events, 'outputToSource')) { - return events as SourceTransformationResponse; + let sourceTransformationResponse = events as SourceTransformationResponse; + if (!Object.prototype.hasOwnProperty.call(events, 'outputToSource')) { + const eventsBatch = CommonUtils.toArray(events); + sourceTransformationResponse = { + output: { batch: eventsBatch }, + } as SourceTransformationResponse; } - if (Array.isArray(events)) { - return { output: { batch: events } } as SourceTransformationResponse; + + if (sourceTransformationResponse.output) { + sourceTransformationResponse.output.batch.forEach((event) => { + const newEvent = event as RudderMessage; + newEvent.context = { ...event.context, ...context }; + }); } - return { output: { batch: [events] } } as SourceTransformationResponse; + return sourceTransformationResponse; } } diff --git a/src/services/userTransform.ts b/src/services/userTransform.ts index 9ad92e8ca3..2afad88c56 100644 --- a/src/services/userTransform.ts +++ b/src/services/userTransform.ts @@ -196,6 +196,7 @@ export class UserTransformService { public static async testTransformRoutine(events, trRevCode, libraryVersionIDs, credentials) { const response: FixMe = {}; + let errorCode: number | undefined; try { if (!trRevCode || !trRevCode.code || !trRevCode.codeVersion) { throw new Error('Invalid Request. Missing parameters in transformation code block'); @@ -231,6 +232,13 @@ export class UserTransformService { response.body = { error: extractStackTraceUptoLastSubstringMatch(error.stack, SUPPORTED_FUNC_NAMES), }; + errorCode = error.statusCode; + } finally { + const metaTags = getTransformationMetadata(events[0]?.metadata); + stats.counter('user_transform_test_count_total', events.length, { + status: errorCode || response.status, + ...metaTags, + }); } return response; } diff --git a/src/types/index.ts b/src/types/index.ts index 150758363e..7aa6bd8ebf 100644 --- a/src/types/index.ts +++ b/src/types/index.ts @@ -185,6 +185,12 @@ type RouterTransformationResponse = { statTags?: object; }; +type SourceTransformationEvent = { + headers?: Record; + query_params?: Record; + [key: string]: any; +}; + type SourceTransformationOutput = { batch: RudderMessage[]; }; @@ -360,6 +366,7 @@ export { RouterTransformationRequestData, RouterTransformationResponse, RudderMessage, + SourceTransformationEvent, SourceTransformationResponse, UserDeletionRequest, UserDeletionResponse, diff --git a/src/util/errorNotifier/bugsnag.js b/src/util/errorNotifier/bugsnag.js index a6a22655ad..f9f37e8234 100644 --- a/src/util/errorNotifier/bugsnag.js +++ b/src/util/errorNotifier/bugsnag.js @@ -1,9 +1,5 @@ /* eslint-disable no-param-reassign */ const Bugsnag = require('@bugsnag/js'); -const { - CustomError: CDKCustomError, - DataValidationError, -} = require('rudder-transformer-cdk/build/error/index'); const stackTraceParser = require('stacktrace-parser'); const { BaseError, @@ -46,8 +42,6 @@ const errorTypesDenyList = [ UnhandledStatusCodeError, UnauthorizedError, NetworkInstrumentationError, - CDKCustomError, - DataValidationError, FilteredEventsError, ]; diff --git a/src/util/openfaas/index.js b/src/util/openfaas/index.js index b5021cf715..1f44df86bb 100644 --- a/src/util/openfaas/index.js +++ b/src/util/openfaas/index.js @@ -241,8 +241,9 @@ const deployFaasFunction = async ( // To handle concurrent create requests, // throw retry error if deployment or service already exists so that request can be retried if ( - (error.statusCode === 500 || error.statusCode === 400) && - error.message.includes('already exists') + ((error.statusCode === 500 || error.statusCode === 400) && + error.message.includes('already exists')) || + (error.statusCode === 409 && error.message.includes('Conflict change already made')) ) { setFunctionInCache(functionName); throw new RetryRequestError(`${functionName} already exists`); diff --git a/src/util/prometheus.js b/src/util/prometheus.js index 0b1f3b34bf..27747faf4b 100644 --- a/src/util/prometheus.js +++ b/src/util/prometheus.js @@ -431,7 +431,7 @@ class Prometheus { name: 'shopify_redis_no_val', help: 'shopify_redis_no_val', type: 'counter', - labelNames: ['writeKey', 'source'], + labelNames: ['writeKey', 'source', 'event'], }, { name: 'invalid_shopify_event', @@ -502,6 +502,12 @@ class Prometheus { type: 'counter', labelNames: ['destination_id'], }, + { + name: 'hs_batch_size', + help: 'hs_batch_size', + type: 'gauge', + labelNames: ['destination_id'], + }, { name: 'mixpanel_batch_engage_pack_size', help: 'mixpanel_batch_engage_pack_size', @@ -835,6 +841,12 @@ class Prometheus { 'k8_namespace', ], }, + { + name: 'user_transform_test_count_total', + help: 'user_transform_test_count_total', + type: 'counter', + labelNames: ['workspaceId', 'transformationId', 'status'], + }, { name: 'user_transform_requests', help: 'user_transform_requests', diff --git a/src/util/redis/testData/shopify_source.json b/src/util/redis/testData/shopify_source.json index 2120475baf..9c09de4643 100644 --- a/src/util/redis/testData/shopify_source.json +++ b/src/util/redis/testData/shopify_source.json @@ -53,7 +53,7 @@ "input": { "event": "rudderSessionIdentifier", "sessionId": "session_id", - "cartToken": "shopify_test_set_map_fail", + "cartToken": "shopify_test_set_map_fail?key=abcd13234", "query_parameters": { "writeKey": ["Shopify Write Key"] }, @@ -1298,7 +1298,7 @@ "input": { "event": "rudderIdentifier", "anonymousId": "b9993cc5-9e60-4e69-be0e-4e38c228314b", - "cartToken": "shopify_test1", + "cartToken": "shopify_test1?key=abcd1234", "query_parameters": { "writeKey": ["Shopify Write Key"] }, diff --git a/src/util/types.ts b/src/util/types.ts index bd2836d710..549003f79a 100644 --- a/src/util/types.ts +++ b/src/util/types.ts @@ -7,7 +7,6 @@ export type ContextBodySimple = { destType: string; }; export interface Config { - cdkEnabled?: boolean; cdkV2Enabled?: boolean; comparisonTestEnabeld?: boolean; comparisonService?: string; diff --git a/src/v0/destinations/active_campaign/transform.js b/src/v0/destinations/active_campaign/transform.js index 3978f868b1..f21bb1a70d 100644 --- a/src/v0/destinations/active_campaign/transform.js +++ b/src/v0/destinations/active_campaign/transform.js @@ -49,7 +49,7 @@ const responseBuilderSimple = (payload, category, destination) => { throw new TransformationError('Payload could not be constructed'); }; -const syncContact = async (contactPayload, category, destination) => { +const syncContact = async (contactPayload, category, { destination, metadata }) => { const { endPoint } = category; const endpoint = `${destination.Config.apiUrl}${endPoint}`; const requestData = { @@ -60,6 +60,7 @@ const syncContact = async (contactPayload, category, destination) => { }; const res = await httpPOST(endpoint, requestData, requestOptions, { destType: 'active_campaign', + metadata, feature: 'transformation', endpointPath: endPoint, requestMethod: 'POST', @@ -75,7 +76,7 @@ const syncContact = async (contactPayload, category, destination) => { return createdContact.id; }; -const customTagProcessor = async (message, category, destination, contactId) => { +const customTagProcessor = async ({ message, destination, metadata }, category, contactId) => { const tagsToBeCreated = []; const tagIds = []; let res; @@ -102,6 +103,7 @@ const customTagProcessor = async (message, category, destination, contactId) => destType: 'active_campaign', feature: 'transformation', tagEndPoint, + metadata, }); if (res.success === false) { errorHandler(res, 'Failed to fetch already created tags'); @@ -133,6 +135,7 @@ const customTagProcessor = async (message, category, destination, contactId) => endpointPath: `/api/3/tags`, requestMethod: 'GET', module: 'router', + metadata, }); promises.push(resp); } @@ -174,6 +177,7 @@ const customTagProcessor = async (message, category, destination, contactId) => res = await httpPOST(endpoint, requestData, requestOptions, { destType: 'active_campaign', feature: 'transformation', + metadata, }); if (res.success === false) { errorHandler(res, 'Failed to create new tag'); @@ -202,6 +206,7 @@ const customTagProcessor = async (message, category, destination, contactId) => res = httpPOST(endpoint, requestData, requestOptions, { destType: 'active_campaign', feature: 'transformation', + metadata, }); return res; }), @@ -212,7 +217,7 @@ const customTagProcessor = async (message, category, destination, contactId) => }); }; -const customFieldProcessor = async (message, category, destination) => { +const customFieldProcessor = async ({ message, destination, metadata }, category) => { const responseStaging = []; const { fieldEndPoint } = category; // Step - 1 @@ -235,6 +240,7 @@ const customFieldProcessor = async (message, category, destination) => { }; const res = await httpGET(endpoint, requestOptions, { destType: 'active_campaign', + metadata, feature: 'transformation', fieldEndPoint, }); @@ -258,6 +264,7 @@ const customFieldProcessor = async (message, category, destination) => { feature: 'transformation', endpointPath: `/api/3/fields`, requestMethod: 'GET', + metadata, module: 'router', }); promises.push(resp); @@ -317,7 +324,7 @@ const customFieldProcessor = async (message, category, destination) => { return fieldsArrValues; }; -const customListProcessor = async (message, category, destination, contactId) => { +const customListProcessor = async ({ message, destination, metadata }, category, contactId) => { const { mergeListWithContactUrl } = category; // Here we extract the list info from the message const listInfo = get(message?.context?.traits, 'lists') @@ -359,6 +366,7 @@ const customListProcessor = async (message, category, destination, contactId) => endpointPath: mergeListWithContactUrl, requestMethod: 'POST', module: 'router', + metadata, }); promises.push(res); } @@ -374,18 +382,18 @@ const customListProcessor = async (message, category, destination, contactId) => // This the handler func for identify type of events here before we transform the event // and return to rudder server we process the message by calling specific destination apis // for handling tag information and custom field information. -const identifyRequestHandler = async (message, category, destination) => { +const identifyRequestHandler = async ({ message, destination, metadata }, category) => { // create skeleton contact payload let contactPayload = constructPayload(message, MAPPING_CONFIG[category.name]); contactPayload = removeUndefinedAndNullValues(contactPayload); // sync to Active Campaign - const contactId = await syncContact(contactPayload, category, destination); + const contactId = await syncContact(contactPayload, category, { destination, metadata }); // create, and merge tags - await customTagProcessor(message, category, destination, contactId); + await customTagProcessor({ message, destination, metadata }, category, contactId); // add the contact to lists if applicabale - await customListProcessor(message, category, destination, contactId); + await customListProcessor({ message, destination, metadata }, category, contactId); // extract fieldValues to merge with contact - const fieldValues = await customFieldProcessor(message, category, destination); + const fieldValues = await customFieldProcessor({ message, destination, metadata }, category); contactPayload.fieldValues = fieldValues; contactPayload = removeUndefinedAndNullValues(contactPayload); const payload = { @@ -404,7 +412,7 @@ const pageRequestHandler = (message, category, destination) => { return responseBuilderSimple(payload, category, destination); }; -const screenRequestHandler = async (message, category, destination) => { +const screenRequestHandler = async ({ message, destination, metadata }, category) => { // Need to check if the event with same name already exists if not need to create // Retrieve All events from destination // https://developers.activecampaign.com/reference/list-all-event-types @@ -417,6 +425,7 @@ const screenRequestHandler = async (message, category, destination) => { destType: 'active_campaign', feature: 'transformation', endpointPath: `/api/3/eventTrackingEvents`, + metadata, requestMethod: 'GET', module: 'router', }); @@ -445,6 +454,7 @@ const screenRequestHandler = async (message, category, destination) => { }; res = await httpPOST(endpoint, requestData, requestOpt, { destType: 'active_campaign', + metadata, feature: 'transformation', }); if (res.success === false) { @@ -469,7 +479,7 @@ const screenRequestHandler = async (message, category, destination) => { return responseBuilderSimple(payload, category, destination); }; -const trackRequestHandler = async (message, category, destination) => { +const trackRequestHandler = async ({ message, destination, metadata }, category) => { // Need to check if the event with same name already exists if not need to create // Retrieve All events from destination // https://developers.activecampaign.com/reference/list-all-event-types @@ -480,6 +490,7 @@ const trackRequestHandler = async (message, category, destination) => { }, }; let res = await httpGET(endpoint, requestOptions, { + metadata, destType: 'active_campaign', feature: 'transformation', endpointPath: `/api/3/eventTrackingEvents`, @@ -511,6 +522,7 @@ const trackRequestHandler = async (message, category, destination) => { headers: getHeader(destination), }; res = await httpPOST(endpoint, requestData, requestOpt, { + metadata, destType: 'active_campaign', feature: 'transformation', }); @@ -537,7 +549,8 @@ const trackRequestHandler = async (message, category, destination) => { // The main entry point where the message is processed based on what type of event // each scenario is resolved by using specific handler function which does // subsquent processing and transformations and the response is sent to rudder-server -const processEvent = async (message, destination) => { +const processEvent = async (event) => { + const { message, destination } = event; if (!message.type) { throw new InstrumentationError('Message Type is not present. Aborting message.'); } @@ -547,7 +560,7 @@ const processEvent = async (message, destination) => { switch (messageType) { case EventType.IDENTIFY: category = CONFIG_CATEGORIES.IDENTIFY; - response = await identifyRequestHandler(message, category, destination); + response = await identifyRequestHandler(event, category); break; case EventType.PAGE: category = CONFIG_CATEGORIES.PAGE; @@ -555,11 +568,11 @@ const processEvent = async (message, destination) => { break; case EventType.SCREEN: category = CONFIG_CATEGORIES.SCREEN; - response = await screenRequestHandler(message, category, destination); + response = await screenRequestHandler(event, category); break; case EventType.TRACK: category = CONFIG_CATEGORIES.TRACK; - response = await trackRequestHandler(message, category, destination); + response = await trackRequestHandler(event, category); break; default: throw new InstrumentationError('Message type not supported'); @@ -568,7 +581,7 @@ const processEvent = async (message, destination) => { }; const process = async (event) => { - const result = await processEvent(event.message, event.destination); + const result = await processEvent(event); return result; }; diff --git a/src/v0/destinations/af/deleteUsers.js b/src/v0/destinations/af/deleteUsers.js index ab515642aa..e0da3699ed 100644 --- a/src/v0/destinations/af/deleteUsers.js +++ b/src/v0/destinations/af/deleteUsers.js @@ -10,7 +10,7 @@ const { processAxiosResponse, getDynamicErrorType, } = require('../../../adapters/utils/networkUtils'); -const { generateUUID, isHttpStatusSuccess } = require('../../util'); +const utils = require('../../util'); const tags = require('../../util/tags'); const { executeCommonValidations } = require('../../util/regulation-api'); @@ -23,7 +23,7 @@ const { executeCommonValidations } = require('../../util/regulation-api'); * @returns */ const deleteUser = async (config, endpoint, body, identityType, identityValue) => { - body.subject_request_id = generateUUID(); + body.subject_request_id = utils.generateUUID(); body.submitted_time = new Date().toISOString(); body.subject_identities[0].identity_type = identityType; body.subject_identities[0].identity_value = identityValue; @@ -44,7 +44,7 @@ const deleteUser = async (config, endpoint, body, identityType, identityValue) = }, ); const handledDelResponse = processAxiosResponse(response); - if (!isHttpStatusSuccess(handledDelResponse.status)) { + if (!utils.isHttpStatusSuccess(handledDelResponse.status)) { throw new NetworkError( 'User deletion request failed', handledDelResponse.status, diff --git a/src/v0/destinations/attentive_tag/transform.js b/src/v0/destinations/attentive_tag/transform.js index fa05eb6c21..5522c078b0 100644 --- a/src/v0/destinations/attentive_tag/transform.js +++ b/src/v0/destinations/attentive_tag/transform.js @@ -16,7 +16,7 @@ const { const { getDestinationItemProperties, getExternalIdentifiersMapping, - getPropertiesKeyValidation, + arePropertiesValid, validateTimestamp, } = require('./util'); const { JSON_MIME_TYPE } = require('../../util/constant'); @@ -137,9 +137,9 @@ const trackResponseBuilder = (message, { Config }) => { payload = constructPayload(message, mappingConfig[ConfigCategory.TRACK.name]); endpoint = ConfigCategory.TRACK.endpoint; payload.type = get(message, 'event'); - if (!getPropertiesKeyValidation(payload)) { + if (!arePropertiesValid(payload.properties)) { throw new InstrumentationError( - '[Attentive Tag]:The event name contains characters which is not allowed', + '[Attentive Tag]:The properties contains characters which is not allowed', ); } } diff --git a/src/v0/destinations/attentive_tag/util.js b/src/v0/destinations/attentive_tag/util.js index c96d03028f..8e73f572fc 100644 --- a/src/v0/destinations/attentive_tag/util.js +++ b/src/v0/destinations/attentive_tag/util.js @@ -14,12 +14,19 @@ const { mappingConfig, ConfigCategory } = require('./config'); * The keys should not contain any of the values inside the validationArray. * STEP 1: Storing keys in the array. * Checking for the non-valid characters inside the keys of properties. + * ref: https://docs.attentivemobile.com/openapi/reference/tag/Custom-Events/ * @param {*} payload * @returns */ -const getPropertiesKeyValidation = (payload) => { +const arePropertiesValid = (properties) => { + if (!isDefinedAndNotNullAndNotEmpty(properties)) { + return true; + } + if (typeof properties !== 'object') { + return false; + } const validationArray = [`'`, `"`, `{`, `}`, `[`, `]`, ',', `,`]; - const keys = Object.keys(payload.properties); + const keys = Object.keys(properties); for (const key of keys) { for (const validationChar of validationArray) { if (key.includes(validationChar)) { @@ -134,6 +141,6 @@ const getDestinationItemProperties = (message, isItemsRequired) => { module.exports = { getDestinationItemProperties, getExternalIdentifiersMapping, - getPropertiesKeyValidation, + arePropertiesValid, validateTimestamp, }; diff --git a/src/v0/destinations/attentive_tag/util.test.js b/src/v0/destinations/attentive_tag/util.test.js new file mode 100644 index 0000000000..59fdc9f361 --- /dev/null +++ b/src/v0/destinations/attentive_tag/util.test.js @@ -0,0 +1,51 @@ +const { arePropertiesValid } = require('./util'); + +describe('arePropertiesValid', () => { + // returns true for valid properties object with no special characters in keys + it('should return true when properties object has no special characters in keys', () => { + const properties = { key1: 'value1', key2: 'value2' }; + const result = arePropertiesValid(properties); + expect(result).toBe(true); + }); + + // returns true for null properties input + it('should return true when properties input is null', () => { + const properties = null; + const result = arePropertiesValid(properties); + expect(result).toBe(true); + }); + + // returns false for properties object with keys containing special characters + it('should return false for properties object with keys containing special characters', () => { + const properties = { + key1: 'value1', + 'key,2': 'value2', + key3: 'value3', + }; + expect(arePropertiesValid(properties)).toBe(false); + }); + + // returns true for empty properties object + it('should return true for empty properties object', () => { + const properties = {}; + expect(arePropertiesValid(properties)).toBe(true); + }); + + // returns true for undefined properties input + it('should return true for undefined properties input', () => { + const result = arePropertiesValid(undefined); + expect(result).toBe(true); + }); + + // returns true for empty string properties input + it('should return true for empty string properties input', () => { + const result = arePropertiesValid(''); + expect(result).toBe(true); + }); + + // returns false for empty string properties input + it('should return false for non object properties input', () => { + const result = arePropertiesValid('1234'); + expect(result).toBe(false); + }); +}); diff --git a/src/v0/destinations/braze/braze.util.test.js b/src/v0/destinations/braze/braze.util.test.js index 460f1db565..5ec48d29f1 100644 --- a/src/v0/destinations/braze/braze.util.test.js +++ b/src/v0/destinations/braze/braze.util.test.js @@ -1,6 +1,12 @@ const _ = require('lodash'); const { handleHttpRequest } = require('../../../adapters/network'); -const { BrazeDedupUtility, addAppId, getPurchaseObjs, setAliasObject } = require('./util'); +const { + BrazeDedupUtility, + addAppId, + getPurchaseObjs, + setAliasObject, + handleReservedProperties, +} = require('./util'); const { processBatch } = require('./util'); const { removeUndefinedAndNullValues, @@ -261,7 +267,7 @@ describe('dedup utility tests', () => { }; // Call the function - const users = await BrazeDedupUtility.doApiLookup(identfierChunks, destination); + const users = await BrazeDedupUtility.doApiLookup(identfierChunks, { destination }); // Check the result expect(users).toEqual([ @@ -399,7 +405,9 @@ describe('dedup utility tests', () => { }, })); - const chunkedUserData = await BrazeDedupUtility.doApiLookup(identifierChunks, destination); + const chunkedUserData = await BrazeDedupUtility.doApiLookup(identifierChunks, { + destination, + }); const result = _.flatMap(chunkedUserData); expect(result).toHaveLength(110); expect(handleHttpRequest).toHaveBeenCalledTimes(3); @@ -455,7 +463,7 @@ describe('dedup utility tests', () => { }, })); - const users = await BrazeDedupUtility.doApiLookup(chunks, destination); + const users = await BrazeDedupUtility.doApiLookup(chunks, { destination }); expect(handleHttpRequest).toHaveBeenCalledTimes(2); // Assert that the first chunk was successful and the second failed @@ -522,7 +530,7 @@ describe('dedup utility tests', () => { [{ alias_name: 'alias1', alias_label: 'rudder_id' }], [{ alias_name: 'alias2', alias_label: 'rudder_id' }], ], - { Config: { restApiKey: 'xyz' } }, + { destination: { Config: { restApiKey: 'xyz' } } }, ); // restore the original implementation of the mocked functions @@ -783,6 +791,136 @@ describe('dedup utility tests', () => { const result = BrazeDedupUtility.deduplicate(userData, store); expect(result).toBeNull(); }); + + test('deduplicates user data correctly when user data is null and it doesnt exist in stored data', () => { + const userData = { + external_id: '123', + nullProperty: null, + color: 'green', + age: 30, + }; + const storeData = { + external_id: '123', + custom_attributes: { + color: 'green', + age: 30, + }, + }; + store.set('123', storeData); + const result = BrazeDedupUtility.deduplicate(userData, store); + expect(store.size).toBe(1); + expect(result).toEqual(null); + }); + + test('deduplicates user data correctly when user data is null and it is same in stored data', () => { + const userData = { + external_id: '123', + nullProperty: null, + color: 'green', + age: 30, + }; + const storeData = { + external_id: '123', + custom_attributes: { + color: 'green', + age: 30, + nullProperty: null, + }, + }; + store.set('123', storeData); + const result = BrazeDedupUtility.deduplicate(userData, store); + expect(store.size).toBe(1); + expect(result).toEqual(null); + }); + + test('deduplicates user data correctly when user data is null and it is different in stored data', () => { + const userData = { + external_id: '123', + nullProperty: null, + color: 'green', + age: 30, + }; + const storeData = { + external_id: '123', + custom_attributes: { + color: 'green', + age: 30, + nullProperty: 'valid data', + }, + }; + store.set('123', storeData); + const result = BrazeDedupUtility.deduplicate(userData, store); + expect(store.size).toBe(1); + expect(result).toEqual({ + external_id: '123', + nullProperty: null, + }); + }); + + test('deduplicates user data correctly when user data is undefined and it doesnt exist in stored data', () => { + const userData = { + external_id: '123', + undefinedProperty: undefined, + color: 'green', + age: 30, + }; + const storeData = { + external_id: '123', + custom_attributes: { + color: 'green', + age: 30, + }, + }; + store.set('123', storeData); + const result = BrazeDedupUtility.deduplicate(userData, store); + expect(store.size).toBe(1); + expect(result).toEqual(null); + }); + + test('deduplicates user data correctly when user data is undefined and it is same in stored data', () => { + const userData = { + external_id: '123', + undefinedProperty: undefined, + color: 'green', + age: 30, + }; + const storeData = { + external_id: '123', + custom_attributes: { + color: 'green', + undefinedProperty: undefined, + age: 30, + }, + }; + store.set('123', storeData); + const result = BrazeDedupUtility.deduplicate(userData, store); + expect(store.size).toBe(1); + expect(result).toEqual(null); + }); + + test('deduplicates user data correctly when user data is undefined and it is defined in stored data', () => { + const userData = { + external_id: '123', + undefinedProperty: undefined, + color: 'green', + age: 30, + }; + const storeData = { + external_id: '123', + custom_attributes: { + color: 'green', + undefinedProperty: 'defined data', + age: 30, + }, + }; + store.set('123', storeData); + const result = BrazeDedupUtility.deduplicate(userData, store); + expect(store.size).toBe(1); + expect(result).toEqual({ + external_id: '123', + undefinedProperty: undefined, + }); + }); }); }); @@ -1538,3 +1676,64 @@ describe('setAliasObject function', () => { }); }); }); + +describe('handleReservedProperties', () => { + // Removes 'time' and 'event_name' keys from the input object + it('should remove "time" and "event_name" keys when they are present in the input object', () => { + const props = { time: '2023-10-01T00:00:00Z', event_name: 'test_event', other_key: 'value' }; + const result = handleReservedProperties(props); + expect(result).toEqual({ other_key: 'value' }); + }); + + // Input object is empty + it('should return an empty object when the input object is empty', () => { + const props = {}; + const result = handleReservedProperties(props); + expect(result).toEqual({}); + }); + + // Works correctly with an object that has no reserved keys + it('should remove reserved keys when present in the input object', () => { + const props = { time_stamp: '2023-10-01T00:00:00Z', event: 'test_event', other_key: 'value' }; + const result = handleReservedProperties(props); + expect(result).toEqual({ + time_stamp: '2023-10-01T00:00:00Z', + event: 'test_event', + other_key: 'value', + }); + }); + + // Input object is null or undefined + it('should return an empty object when input object is null', () => { + const props = null; + const result = handleReservedProperties(props); + expect(result).toEqual({}); + }); + + // Handles non-object inputs gracefully + it('should return an empty object when a non-object input is provided', () => { + const props = 'not an object'; + try { + handleReservedProperties(props); + } catch (e) { + expect(e.message).toBe('Invalid event properties'); + } + }); + + // Input object has only reserved keys + it('should remove "time" and "event_name" keys when they are present in the input object', () => { + const props = { time: '2023-10-01T00:00:00Z', event_name: 'test_event', other_key: 'value' }; + const result = handleReservedProperties(props); + expect(result).toEqual({ other_key: 'value' }); + }); + + // Works with objects having special characters in keys + it('should not remove special characters keys when they are present in the input object', () => { + const props = { 'special!@#$%^&*()_+-={}[]|\\;:\'",.<>?/`~': 'value', other_key: 'value' }; + const result = handleReservedProperties(props); + expect(result).toEqual({ + other_key: 'value', + 'special!@#$%^&*()_+-={}[]|\\;:\'",.<>?/`~': 'value', + }); + }); +}); diff --git a/src/v0/destinations/braze/transform.js b/src/v0/destinations/braze/transform.js index 3d6a99d424..09fb0205c5 100644 --- a/src/v0/destinations/braze/transform.js +++ b/src/v0/destinations/braze/transform.js @@ -15,6 +15,7 @@ const { setAliasObject, collectStatsForAliasFailure, collectStatsForAliasMissConfigurations, + handleReservedProperties, } = require('./util'); const tags = require('../../util/tags'); const { EventType, MappedToDestinationKey } = require('../../../constants'); @@ -29,6 +30,7 @@ const { simpleProcessRouterDest, isNewStatusCodesAccepted, getDestinationExternalID, + getIntegrationsObj, } = require('../../util'); const { ConfigCategory, @@ -203,7 +205,7 @@ function getUserAttributesObject(message, mappingJson, destination) { * @param {*} message * @param {*} destination */ -async function processIdentify(message, destination) { +async function processIdentify({ message, destination, metadata }) { const identifyPayload = getIdentifyPayload(message); const identifyEndpoint = getIdentifyEndpoint(getEndpointFromConfig(destination)); const { processedResponse: brazeIdentifyResp } = await handleHttpRequest( @@ -223,6 +225,7 @@ async function processIdentify(message, destination) { requestMethod: 'POST', module: 'router', endpointPath: '/users/identify', + metadata, }, ); @@ -279,17 +282,6 @@ function processTrackWithUserAttributes( throw new InstrumentationError('No attributes found to update the user profile'); } -function handleReservedProperties(props) { - // remove reserved keys from custom event properties - // https://www.appboy.com/documentation/Platform_Wide/#reserved-keys - const reserved = ['time', 'product_id', 'quantity', 'event_name', 'price', 'currency']; - - reserved.forEach((element) => { - delete props[element]; - }); - return props; -} - function addMandatoryEventProperties(payload, message) { payload.name = message.event; payload.time = message.timestamp; @@ -331,13 +323,6 @@ function processTrackEvent(messageType, message, destination, mappingJson, proce eventName.toLowerCase() === 'order completed' ) { const purchaseObjs = getPurchaseObjs(message, destination.Config); - - // del used properties - delete properties.products; - delete properties.currency; - - const payload = { properties }; - setExternalIdOrAliasObject(payload, message); return buildResponse( message, destination, @@ -514,10 +499,14 @@ async function process(event, processParams = { userStore: new Map() }, reqMetad if (mappedToDestination) { adduserIdFromExternalId(message); } + + const integrationsObj = getIntegrationsObj(message, 'BRAZE'); + const isAliasPresent = isDefinedAndNotNull(integrationsObj?.alias); + const brazeExternalID = getDestinationExternalID(message, 'brazeExternalId') || message.userId; - if (message.anonymousId && brazeExternalID) { - await processIdentify(message, destination); + if ((message.anonymousId || isAliasPresent) && brazeExternalID) { + await processIdentify({ message, destination }); } else { collectStatsForAliasMissConfigurations(destination.ID); } diff --git a/src/v0/destinations/braze/util.js b/src/v0/destinations/braze/util.js index 45063d0ba2..e5df75b562 100644 --- a/src/v0/destinations/braze/util.js +++ b/src/v0/destinations/braze/util.js @@ -142,7 +142,7 @@ const BrazeDedupUtility = { return identfierChunks; }, - async doApiLookup(identfierChunks, destination) { + async doApiLookup(identfierChunks, { destination, metadata }) { return Promise.all( identfierChunks.map(async (ids) => { const externalIdentifiers = ids.filter((id) => id.external_id); @@ -167,6 +167,7 @@ const BrazeDedupUtility = { requestMethod: 'POST', module: 'router', endpointPath: '/users/export/ids', + metadata, }, ); stats.counter('braze_lookup_failure_count', 1, { @@ -189,10 +190,10 @@ const BrazeDedupUtility = { */ async doLookup(inputs) { const lookupStartTime = new Date(); - const { destination } = inputs[0]; + const { destination, metadata } = inputs[0]; const { externalIdsToQuery, aliasIdsToQuery } = this.prepareInputForDedup(inputs); const identfierChunks = this.prepareChunksForDedup(externalIdsToQuery, aliasIdsToQuery); - const chunkedUserData = await this.doApiLookup(identfierChunks, destination); + const chunkedUserData = await this.doApiLookup(identfierChunks, { destination, metadata }); stats.timing('braze_lookup_time', lookupStartTime, { destination_id: destination.Config.destinationId, }); @@ -287,7 +288,14 @@ const BrazeDedupUtility = { if (keys.length > 0) { keys.forEach((key) => { - if (!_.isEqual(userData[key], storedUserData[key])) { + // ref: https://www.braze.com/docs/user_guide/data_and_analytics/custom_data/custom_attributes/#adding-descriptions + // null is a valid value in braze for unsetting, so we need to compare the values only if the key is present in the stored user data + // in case of keys having null values only compare if the key is present in the stored user data + if (userData[key] === null) { + if (isDefinedAndNotNull(storedUserData[key])) { + deduplicatedUserData[key] = userData[key]; + } + } else if (!_.isEqual(userData[key], storedUserData[key])) { deduplicatedUserData[key] = userData[key]; } }); @@ -706,6 +714,16 @@ const collectStatsForAliasMissConfigurations = (destinationId) => { stats.increment('braze_alias_missconfigured_count', { destination_id: destinationId }); }; +function handleReservedProperties(props) { + if (typeof props !== 'object') { + throw new InstrumentationError('Invalid event properties'); + } + // remove reserved keys from custom event properties + const reserved = ['time', 'event_name']; + + return _.omit(props, reserved); +} + module.exports = { BrazeDedupUtility, CustomAttributeOperationUtil, @@ -720,4 +738,5 @@ module.exports = { addMandatoryPurchaseProperties, collectStatsForAliasFailure, collectStatsForAliasMissConfigurations, + handleReservedProperties, }; diff --git a/src/v0/destinations/canny/transform.js b/src/v0/destinations/canny/transform.js index f4364e1fb7..02b4e7633d 100644 --- a/src/v0/destinations/canny/transform.js +++ b/src/v0/destinations/canny/transform.js @@ -55,7 +55,7 @@ const identifyResponseBuilder = (message, { Config }) => { return responseBuilder(responseConfgs); }; -const getTrackResponse = async (apiKey, message, operationType) => { +const getTrackResponse = async (apiKey, message, operationType, metadata) => { let endpoint; let responseBody; let contentType; @@ -70,7 +70,7 @@ const getTrackResponse = async (apiKey, message, operationType) => { } payload.apiKey = apiKey; - const voterID = await retrieveUserId(apiKey, message); + const voterID = await retrieveUserId(apiKey, message, metadata); payload.voterID = voterID; endpoint = ConfigCategory.CREATE_VOTE.endpoint; } else if (operationType === 'createPost') { @@ -82,7 +82,7 @@ const getTrackResponse = async (apiKey, message, operationType) => { validateCreatePostFields(payload); payload.apiKey = apiKey; - payload.authorID = await retrieveUserId(apiKey, message); + payload.authorID = await retrieveUserId(apiKey, message, metadata); endpoint = ConfigCategory.CREATE_POST.endpoint; } @@ -97,7 +97,7 @@ const getTrackResponse = async (apiKey, message, operationType) => { return responseBuilder(responseConfgs); }; -const trackResponseBuilder = async (message, { Config }) => { +const trackResponseBuilder = async (message, { Config }, metadata) => { const { apiKey, eventsToEvents } = Config; const configuredEventsMap = getHashFromArrayWithDuplicate(eventsToEvents); @@ -113,7 +113,7 @@ const trackResponseBuilder = async (message, { Config }) => { // eslint-disable-next-line no-restricted-syntax for (const destinationEvent of destinationEvents) { // eslint-disable-next-line no-await-in-loop - const response = await getTrackResponse(apiKey, message, destinationEvent); + const response = await getTrackResponse(apiKey, message, destinationEvent, metadata); responseArray.push(response); } } @@ -122,7 +122,7 @@ const trackResponseBuilder = async (message, { Config }) => { return responseArray; }; -const processEvent = (message, destination) => { +const processEvent = async (message, destination, metadata) => { if (!destination.Config.apiKey) { throw new ConfigurationError('API Key is not present. Aborting message.'); } @@ -137,7 +137,7 @@ const processEvent = (message, destination) => { response = identifyResponseBuilder(message, destination); break; case EventType.TRACK: - response = trackResponseBuilder(message, destination); + response = await trackResponseBuilder(message, destination, metadata); break; default: throw new InstrumentationError('Message type not supported'); @@ -145,7 +145,7 @@ const processEvent = (message, destination) => { return response; }; -const process = (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event.message, event.destination, event.metadata); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/canny/util.js b/src/v0/destinations/canny/util.js index 1d03eed4b9..eeefc141db 100644 --- a/src/v0/destinations/canny/util.js +++ b/src/v0/destinations/canny/util.js @@ -13,7 +13,7 @@ const { JSON_MIME_TYPE } = require('../../util/constant'); * @param message * @returns canny userId */ -const retrieveUserId = async (apiKey, message) => { +const retrieveUserId = async (apiKey, message, metadata) => { const cannyId = getDestinationExternalID(message, 'cannyUserId'); if (cannyId) { return cannyId; @@ -43,6 +43,7 @@ const retrieveUserId = async (apiKey, message) => { qs.stringify(requestBody), { headers }, { + metadata, destType: 'canny', feature: 'transformation', endpointPath: `/v1/users/retrieve`, diff --git a/src/v0/destinations/clevertap/config.js b/src/v0/destinations/clevertap/config.js index 25ece35537..a8ae1b506d 100644 --- a/src/v0/destinations/clevertap/config.js +++ b/src/v0/destinations/clevertap/config.js @@ -42,6 +42,7 @@ const CLEVERTAP_DEFAULT_EXCLUSION = [ 'ts', 'overrideFields', ]; +const ALLOWED_DEVICE_TOKEN_TYPES = ['chrome', 'fcm', 'gcm', 'apns', 'wns', 'mpns']; // ref : https://developer.clevertap.com/docs/disassociate-api const DEL_MAX_BATCH_SIZE = 100; @@ -54,4 +55,5 @@ module.exports = { CONFIG_CATEGORIES, CLEVERTAP_DEFAULT_EXCLUSION, DESTINATION: 'CLEVERTAP', + ALLOWED_DEVICE_TOKEN_TYPES, }; diff --git a/src/v0/destinations/clevertap/transform.js b/src/v0/destinations/clevertap/transform.js index 51ed5c851e..e558b119f1 100644 --- a/src/v0/destinations/clevertap/transform.js +++ b/src/v0/destinations/clevertap/transform.js @@ -1,7 +1,11 @@ /* eslint-disable no-param-reassign */ /* eslint-disable no-nested-ternary */ const get = require('get-value'); -const { InstrumentationError, TransformationError } = require('@rudderstack/integrations-lib'); +const { + InstrumentationError, + TransformationError, + isDefinedAndNotNull, +} = require('@rudderstack/integrations-lib'); const { EventType } = require('../../../constants'); const { getEndpoint, @@ -22,8 +26,10 @@ const { handleRtTfSingleEventError, batchMultiplexedEvents, getSuccessRespEvents, + getIntegrationsObj, + removeUndefinedNullValuesAndEmptyObjectArray, } = require('../../util'); -const { generateClevertapBatchedPayload } = require('./utils'); +const { generateClevertapBatchedPayload, deduceTokenType } = require('./utils'); const { JSON_MIME_TYPE } = require('../../util/constant'); @@ -268,7 +274,9 @@ const responseBuilderSimple = (message, category, destination) => { deviceToken && (deviceOS === 'android' || isAppleFamily(deviceOS)) ) { - const tokenType = deviceOS === 'android' ? 'fcm' : 'apns'; + const tokenType = deduceTokenType(message, deviceOS); + const integObject = getIntegrationsObj(message, 'clevertap'); + const chromeKeys = integObject?.chromeKeys; const payloadForDeviceToken = { d: [ { @@ -276,6 +284,7 @@ const responseBuilderSimple = (message, category, destination) => { tokenData: { id: deviceToken, type: tokenType, + keys: isDefinedAndNotNull(chromeKeys) ? chromeKeys : null, }, objectId: get(message, 'anonymousId'), }, @@ -283,7 +292,12 @@ const responseBuilderSimple = (message, category, destination) => { }; const respArr = []; respArr.push(responseWrapper(payload, destination)); // identify - respArr.push(responseWrapper(payloadForDeviceToken, destination)); // device token + respArr.push( + responseWrapper( + removeUndefinedNullValuesAndEmptyObjectArray(payloadForDeviceToken), + destination, + ), + ); // device token return respArr; } } else { @@ -302,7 +316,7 @@ const responseBuilderSimple = (message, category, destination) => { // For 'Order Completed' type of events we are mapping it as 'Charged' // Special event in Clevertap. // Source: https://developer.clevertap.com/docs/concepts-events#recording-customer-purchases - if (get(message.event) && get(message.event).toLowerCase() === 'order completed') { + if (get(message.event) && get(message.event).toString().toLowerCase() === 'order completed') { eventPayload = { evtName: 'Charged', evtData: constructPayload(message, MAPPING_CONFIG[CONFIG_CATEGORIES.ECOM.name]), diff --git a/src/v0/destinations/clevertap/utils.js b/src/v0/destinations/clevertap/utils.js index f2dba13ca3..bdc7f63fbd 100644 --- a/src/v0/destinations/clevertap/utils.js +++ b/src/v0/destinations/clevertap/utils.js @@ -1,6 +1,6 @@ -const { defaultBatchRequestConfig } = require('../../util'); +const { defaultBatchRequestConfig, getIntegrationsObj } = require('../../util'); -const { getEndpoint } = require('./config'); +const { getEndpoint, ALLOWED_DEVICE_TOKEN_TYPES } = require('./config'); const { JSON_MIME_TYPE } = require('../../util/constant'); function generateClevertapBatchedPayload(events, destination) { @@ -28,7 +28,25 @@ function generateClevertapBatchedPayload(events, destination) { return batchedRequest; } +/** + * Deduces the device token type based on the integration object and device operating system. + * Ref : https://developer.clevertap.com/docs/upload-device-tokens-api + * @param {Object} message - The message object containing integration details. + * @param {string} deviceOS - The device operating system ('android' or 'ios'). + * @returns {string} The deduced device token type ('fcm' for Android or 'apns' for iOS). + */ +const deduceTokenType = (message, deviceOS) => { + const integrationObj = getIntegrationsObj(message, 'clevertap'); + if ( + integrationObj?.deviceTokenType && + ALLOWED_DEVICE_TOKEN_TYPES.includes(integrationObj?.deviceTokenType) + ) { + return integrationObj?.deviceTokenType; + } + return deviceOS === 'android' ? 'fcm' : 'apns'; +}; module.exports = { generateClevertapBatchedPayload, + deduceTokenType, }; diff --git a/src/v0/destinations/clevertap/utils.test.js b/src/v0/destinations/clevertap/utils.test.js new file mode 100644 index 0000000000..0b0e0d34c5 --- /dev/null +++ b/src/v0/destinations/clevertap/utils.test.js @@ -0,0 +1,87 @@ +const { deduceTokenType } = require('./utils'); + +describe('deduceTokenType', () => { + // deduces token type from integration object when valid token type is present + it('should return the token type from integration object when it is valid', () => { + const message = { + integrations: { + clevertap: { + deviceTokenType: 'fcm', + }, + }, + }; + const deviceOS = 'android'; + const result = deduceTokenType(message, deviceOS); + expect(result).toBe('fcm'); + }); + + // handles null or undefined message input gracefully + it('should return default token type based on deviceOS when message is null', () => { + const message = null; + const deviceOS = 'android'; + const result = deduceTokenType(message, deviceOS); + expect(result).toBe('fcm'); + }); + + // returns 'fcm' when deviceOS is 'android' and no valid token type is present + it("should return 'fcm' when deviceOS is 'android' and no valid token type is present", () => { + const message = { integrations: { clevertap: { deviceTokenType: null } } }; + const result = deduceTokenType(message, 'android'); + expect(result).toBe('fcm'); + }); + + // returns 'apns' when deviceOS is not 'android' and no valid token type is present + it("should return 'apns' when deviceOS is not 'android' and no valid token type is present", () => { + const message = { integrations: { clevertap: { deviceTokenType: null } } }; + const result = deduceTokenType(message, 'ios'); + expect(result).toBe('apns'); + }); + + // handles null or undefined deviceOS input gracefully + it('should return default token type when deviceOS is null', () => { + const message = {}; + const deviceOS = null; + const result = deduceTokenType(message, deviceOS); + expect(result).toEqual('apns'); + }); + + // handles empty integration object in message + it('should return default token type when integration object is empty', () => { + const message = { integrations: {} }; + const deviceOS = 'ios'; + const result = deduceTokenType(message, deviceOS); + expect(result).toEqual('apns'); + }); + + // handles integration object with invalid token type + it('should return default token type when integration object has an invalid token type', () => { + const message = { integrations: { clevertap: { deviceTokenType: 'invalidType' } } }; + const deviceOS = 'ios'; + const result = deduceTokenType(message, deviceOS); + expect(result).toEqual('apns'); + }); + + // handles integration object with no token type + it('should return default token type when integration object has no token type', () => { + const message = { integrations: { clevertap: {} } }; + const deviceOS = 'android'; + const result = deduceTokenType(message, deviceOS); + expect(result).toEqual('fcm'); + }); + + // verifies integration object retrieval with 'clevertap' as destination name + it('should retrieve correct device token type for CleverTap destination', () => { + const message = { integrations: { clevertap: { deviceTokenType: 'fcm' } } }; + const deviceOS = 'ios'; + const result = deduceTokenType(message, deviceOS); + expect(result).toBe('fcm'); + }); + + // checks for case sensitivity in deviceOS values + it('should handle case sensitivity in deviceOS values', () => { + const message = { integrations: { clevertap: { deviceTokenType: 'fcm' } } }; + const deviceOS = 'Android'; + const result = deduceTokenType(message, deviceOS); + expect(result).toBe('fcm'); + }); +}); diff --git a/src/v0/destinations/clickup/transform.js b/src/v0/destinations/clickup/transform.js index 0637d65bd4..799fdf7e7b 100644 --- a/src/v0/destinations/clickup/transform.js +++ b/src/v0/destinations/clickup/transform.js @@ -33,7 +33,7 @@ const responseBuilder = async (payload, listId, apiToken) => { throw new TransformationError('Something went wrong while constructing the payload'); }; -const trackResponseBuilder = async (message, destination) => { +const trackResponseBuilder = async (message, destination, metadata) => { const { apiToken, keyToCustomFieldName } = destination.Config; const { properties } = message; const externalListId = getDestinationExternalID(message, 'clickUpListId'); @@ -45,6 +45,7 @@ const trackResponseBuilder = async (message, destination) => { properties, listId, apiToken, + metadata, ); let payload = constructPayload(message, MAPPING_CONFIG[CONFIG_CATEGORIES.TRACK.name]); @@ -55,7 +56,7 @@ const trackResponseBuilder = async (message, destination) => { return responseBuilder(payload, listId, apiToken); }; -const processEvent = async (message, destination) => { +const processEvent = async (message, destination, metadata) => { if (!message.type) { throw new InstrumentationError('Event type is required'); } @@ -64,13 +65,13 @@ const processEvent = async (message, destination) => { const messageType = message.type.toLowerCase(); if (messageType === EventType.TRACK) { - return trackResponseBuilder(message, destination); + return trackResponseBuilder(message, destination, metadata); } throw new InstrumentationError(`Event type "${messageType}" is not supported`); }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event.message, event.destination, event.metadata); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/clickup/util.js b/src/v0/destinations/clickup/util.js index 74e961906c..5da4192b5b 100644 --- a/src/v0/destinations/clickup/util.js +++ b/src/v0/destinations/clickup/util.js @@ -206,7 +206,7 @@ const getListOfAssignees = (message, type) => { * @param {*} apiToken * @returns */ -const retrieveCustomFields = async (listId, apiToken) => { +const retrieveCustomFields = async (listId, apiToken, metadata) => { const endpoint = getCustomFieldsEndPoint(listId); const requestOptions = { headers: { @@ -220,6 +220,7 @@ const retrieveCustomFields = async (listId, apiToken) => { endpointPath: '/list/listId/field', requestMethod: 'GET', module: 'router', + metadata, }); const processedCustomFieldsResponse = processAxiosResponse(customFieldsResponse); @@ -278,11 +279,17 @@ const extractUIMappedCustomFieldDetails = ( * @param {*} apiToken * @returns [{"id":"b0f40a94-ea2a-4998-a514-8074d0eddcde","value":"https://www.rudderstack.com/"}] */ -const customFieldsBuilder = async (keyToCustomFieldName, properties, listId, apiToken) => { +const customFieldsBuilder = async ( + keyToCustomFieldName, + properties, + listId, + apiToken, + metadata, +) => { const responseArray = []; if (properties && keyToCustomFieldName) { // retrieve available clickup custom field for the given list - const availableCustomFields = await retrieveCustomFields(listId, apiToken); + const availableCustomFields = await retrieveCustomFields(listId, apiToken, metadata); // convert array to hashMap with key as field name and value as custom field object const availableCustomFieldsMap = getHashFromArrayWithValueAsObject( availableCustomFields, diff --git a/src/v0/destinations/custify/transform.js b/src/v0/destinations/custify/transform.js index 6b08be1c56..d13a476a68 100644 --- a/src/v0/destinations/custify/transform.js +++ b/src/v0/destinations/custify/transform.js @@ -19,7 +19,7 @@ const { JSON_MIME_TYPE } = require('../../util/constant'); * @param {*} destination * @returns */ -const validateAndBuildResponse = async (message, destination) => { +const validateAndBuildResponse = async ({ message, destination, metadata }) => { const messageType = message.type.toLowerCase(); const response = defaultRequestConfig(); let responseBody; @@ -34,7 +34,7 @@ const validateAndBuildResponse = async (message, destination) => { category = ConfigCategory.TRACK; break; case EventType.GROUP: - responseBody = await processGroup(message, destination); + responseBody = await processGroup(message, destination, metadata); category = ConfigCategory.GROUP_USER; break; default: @@ -57,14 +57,14 @@ const validateAndBuildResponse = async (message, destination) => { return response; }; -const processSingleMessage = async (message, destination) => { +const processSingleMessage = async ({ message, destination, metadata }) => { if (!message.type) { throw new InstrumentationError('Message Type is not present. Ignoring message.'); } - return validateAndBuildResponse(message, destination); + return validateAndBuildResponse({ message, destination, metadata }); }; -const process = (event) => processSingleMessage(event.message, event.destination); +const process = (event) => processSingleMessage(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/custify/util.js b/src/v0/destinations/custify/util.js index b6f3446503..f35dd4dd23 100644 --- a/src/v0/destinations/custify/util.js +++ b/src/v0/destinations/custify/util.js @@ -27,7 +27,7 @@ const { JSON_MIME_TYPE } = require('../../util/constant'); * @param {*} Config * @api https://docs.custify.com/#tag/Company/paths/~1company/post */ -const createUpdateCompany = async (companyPayload, Config) => { +const createUpdateCompany = async (companyPayload, Config, metadata) => { const companyResponse = await httpPOST( ConfigCategory.GROUP_COMPANY.endpoint, companyPayload, @@ -43,6 +43,7 @@ const createUpdateCompany = async (companyPayload, Config) => { endpointPath: `/company`, requestMethod: 'POST', module: 'router', + metadata, }, ); const processedCompanyResponse = processAxiosResponse(companyResponse); @@ -187,7 +188,7 @@ const processTrack = (message, { Config }) => { * @api https://docs.custify.com/#tag/People/paths/~1people/post * @api https://docs.custify.com/#tag/Company/paths/~1company/post */ -const processGroup = async (message, { Config }) => { +const processGroup = async (message, { Config }, metadata) => { let companyPayload = constructPayload(message, MappingConfig[ConfigCategory.GROUP_COMPANY.name]); if (!companyPayload.company_id) { throw new InstrumentationError('groupId Id is mandatory'); @@ -205,7 +206,7 @@ const processGroup = async (message, { Config }) => { }); } companyPayload = removeUndefinedAndNullValues(companyPayload); - await createUpdateCompany(companyPayload, Config); + await createUpdateCompany(companyPayload, Config, metadata); const userPayload = constructPayload(message, MappingConfig[ConfigCategory.GROUP_USER.name]); const { sendAnonymousId } = Config; if (sendAnonymousId && !userPayload.user_id) { diff --git a/src/v0/destinations/customerio/util.js b/src/v0/destinations/customerio/util.js index ef983748a5..cadad5620c 100644 --- a/src/v0/destinations/customerio/util.js +++ b/src/v0/destinations/customerio/util.js @@ -286,6 +286,9 @@ const defaultResponseBuilder = (message, evName, userId, evType, destination, me // 100 - len(`Viewed Screen`) = 86 trimmedEvName = `Viewed ${truncate(message.event || message.properties.name, 86)} Screen`; } else { + if (typeof evName !== 'string') { + throw new InstrumentationError('Event Name type should be a string'); + } // validating evName here as well as message.name could be undefined as well trimmedEvName = truncate(evName, 100); } // anonymous_id needs to be sent for anon track calls to provide information on which anon user is being tracked diff --git a/src/v0/destinations/delighted/transform.js b/src/v0/destinations/delighted/transform.js index cf80dc878d..c560dba03d 100644 --- a/src/v0/destinations/delighted/transform.js +++ b/src/v0/destinations/delighted/transform.js @@ -77,7 +77,7 @@ const identifyResponseBuilder = (message, { Config }) => { return response; }; -const trackResponseBuilder = async (message, { Config }) => { +const trackResponseBuilder = async (message, { Config }, metadata) => { // checks if the event is valid if not throws error else nothing const isValidEvent = eventValidity(Config, message); if (!isValidEvent) { @@ -94,7 +94,7 @@ const trackResponseBuilder = async (message, { Config }) => { const { userIdType, userIdValue } = isValidUserIdOrError(channel, userId); // checking if user already exists or not, throw error if it doesn't - const check = await userValidity(channel, Config, userId); + const check = await userValidity({ channel, Config, userId, metadata }); if (!check) { throw new NetworkInstrumentationError(`user ${userId} doesn't exist`); @@ -167,7 +167,7 @@ const aliasResponseBuilder = (message, { Config }) => { }; const process = async (event) => { - const { message, destination } = event; + const { message, destination, metadata } = event; if (!message.type) { throw new InstrumentationError('Message Type is not present. Aborting message.'); } @@ -184,7 +184,7 @@ const process = async (event) => { response = identifyResponseBuilder(message, destination); break; case EventType.TRACK: - response = await trackResponseBuilder(message, destination); + response = await trackResponseBuilder(message, destination, metadata); break; case EventType.ALIAS: response = aliasResponseBuilder(message, destination); diff --git a/src/v0/destinations/delighted/util.js b/src/v0/destinations/delighted/util.js index 53f416b48d..99a0923dc9 100644 --- a/src/v0/destinations/delighted/util.js +++ b/src/v0/destinations/delighted/util.js @@ -61,7 +61,7 @@ const getErrorStatus = (status) => { return errStatus; }; -const userValidity = async (channel, Config, userId) => { +const userValidity = async ({ channel, Config, userId, metadata }) => { const paramsdata = {}; if (channel === 'email') { paramsdata.email = userId; @@ -81,6 +81,7 @@ const userValidity = async (channel, Config, userId) => { params: paramsdata, }, { + metadata, destType: 'delighted', feature: 'transformation', requestMethod: 'GET', diff --git a/src/v0/destinations/facebook_conversions/config.js b/src/v0/destinations/facebook_conversions/config.js index 0c1fc12e15..2bbe9ab017 100644 --- a/src/v0/destinations/facebook_conversions/config.js +++ b/src/v0/destinations/facebook_conversions/config.js @@ -1,7 +1,7 @@ const { getMappingConfig } = require('../../util'); const ENDPOINT = (datasetId, accessToken) => - `https://graph.facebook.com/v18.0/${datasetId}/events?access_token=${accessToken}`; + `https://graph.facebook.com/v20.0/${datasetId}/events?access_token=${accessToken}`; const CONFIG_CATEGORIES = { USERDATA: { diff --git a/src/v0/destinations/facebook_pixel/config.js b/src/v0/destinations/facebook_pixel/config.js index 17d5887e1b..f259892165 100644 --- a/src/v0/destinations/facebook_pixel/config.js +++ b/src/v0/destinations/facebook_pixel/config.js @@ -1,6 +1,6 @@ const { getMappingConfig } = require('../../util'); -const VERSION = 'v18.0'; +const VERSION = 'v20.0'; const CONFIG_CATEGORIES = { USERDATA: { diff --git a/src/v0/destinations/fb/config.js b/src/v0/destinations/fb/config.js index 0e52b42416..d84fa7d672 100644 --- a/src/v0/destinations/fb/config.js +++ b/src/v0/destinations/fb/config.js @@ -1,7 +1,7 @@ const fs = require('fs'); const path = require('path'); -const VERSION = 'v18.0'; +const VERSION = 'v20.0'; const getPath = (file) => path.resolve(__dirname, file); diff --git a/src/v0/destinations/fb_custom_audience/config.js b/src/v0/destinations/fb_custom_audience/config.js index 284ab0d4a4..39ca2d04c4 100644 --- a/src/v0/destinations/fb_custom_audience/config.js +++ b/src/v0/destinations/fb_custom_audience/config.js @@ -1,4 +1,4 @@ -const BASE_URL = 'https://graph.facebook.com/v18.0'; +const BASE_URL = 'https://graph.facebook.com/v20.0'; function getEndPoint(audienceId) { return `${BASE_URL}/${audienceId}/users`; diff --git a/src/v0/destinations/fb_custom_audience/util.test.js b/src/v0/destinations/fb_custom_audience/util.test.js index 60e0aff464..5c8eb15b71 100644 --- a/src/v0/destinations/fb_custom_audience/util.test.js +++ b/src/v0/destinations/fb_custom_audience/util.test.js @@ -18,7 +18,7 @@ const basePayload = { const baseResponse = { version: '1', type: 'REST', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', diff --git a/src/v0/destinations/freshmarketer/transform.js b/src/v0/destinations/freshmarketer/transform.js index aa0e03811d..9cf9757441 100644 --- a/src/v0/destinations/freshmarketer/transform.js +++ b/src/v0/destinations/freshmarketer/transform.js @@ -70,7 +70,7 @@ const identifyResponseBuilder = (message, { Config }) => { * @param {*} Config * @returns */ -const trackResponseBuilder = async (message, { Config }, event) => { +const trackResponseBuilder = async ({ message, destination: { Config }, metadata }, event) => { if (!event) { throw new InstrumentationError('Event name is required for track call.'); } @@ -85,11 +85,12 @@ const trackResponseBuilder = async (message, { Config }, event) => { payload, message, Config, + metadata, ); break; } case 'lifecycle_stage': { - response.body.JSON = await UpdateContactWithLifeCycleStage(message, Config); + response.body.JSON = await UpdateContactWithLifeCycleStage(message, Config, metadata); response.endpoint = `https://${Config.domain}${CONFIG_CATEGORIES.IDENTIFY.baseUrl}`; break; } @@ -111,7 +112,7 @@ const trackResponseBuilder = async (message, { Config }, event) => { * @param {*} Config * @returns */ -const groupResponseBuilder = async (message, { Config }) => { +const groupResponseBuilder = async ({ message, destination: { Config }, metadata }) => { const groupType = get(message, 'traits.groupType'); if (!groupType) { throw new InstrumentationError('groupType is required for Group call'); @@ -130,7 +131,7 @@ const groupResponseBuilder = async (message, { Config }) => { response = updateAccountWOContact(payload, Config); break; } - const accountDetails = await getUserAccountDetails(payload, userEmail, Config); + const accountDetails = await getUserAccountDetails(payload, userEmail, Config, metadata); response = identifyResponseConfig(Config); response.body.JSON.contact = { sales_accounts: accountDetails }; response.body.JSON.unique_identifier = { emails: userEmail }; @@ -143,7 +144,7 @@ const groupResponseBuilder = async (message, { Config }) => { 'email is required for adding in the marketing lists. Aborting!', ); } - const userDetails = await getContactsDetails(userEmail, Config); + const userDetails = await getContactsDetails(userEmail, Config, metadata); const userId = userDetails.response?.contact?.id; if (!userId) { throw new NetworkInstrumentationError('Failed in fetching userId. Aborting!'); @@ -153,7 +154,7 @@ const groupResponseBuilder = async (message, { Config }) => { if (listId) { response = updateContactWithList(userId, listId, Config); } else if (listName) { - listId = await createOrUpdateListDetails(listName, Config); + listId = await createOrUpdateListDetails(listName, Config, metadata); if (!listId) { throw new NetworkInstrumentationError('Failed in fetching listId. Aborting!'); } @@ -198,7 +199,7 @@ function eventMappingHandler(message, destination) { return [...mappedEvents]; } -const processEvent = async (message, destination) => { +const processEvent = async ({ message, destination, metadata }) => { if (!message.type) { throw new InstrumentationError('Message Type is not present. Aborting message.'); } @@ -213,16 +214,19 @@ const processEvent = async (message, destination) => { if (mappedEvents.length > 0) { response = await Promise.all( mappedEvents.map(async (mappedEvent) => - trackResponseBuilder(message, destination, mappedEvent), + trackResponseBuilder({ message, destination, metadata }, mappedEvent), ), ); } else { - response = await trackResponseBuilder(message, destination, get(message, 'event')); + response = await trackResponseBuilder( + { message, destination, metadata }, + get(message, 'event'), + ); } break; } case EventType.GROUP: - response = await groupResponseBuilder(message, destination); + response = await groupResponseBuilder({ message, destination, metadata }); break; default: throw new InstrumentationError(`message type ${messageType} not supported`); @@ -230,7 +234,7 @@ const processEvent = async (message, destination) => { return response; }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/freshmarketer/utils.js b/src/v0/destinations/freshmarketer/utils.js index c80711ff8d..879cd6eace 100644 --- a/src/v0/destinations/freshmarketer/utils.js +++ b/src/v0/destinations/freshmarketer/utils.js @@ -37,7 +37,7 @@ const getHeaders = (apiKey) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_an_account */ -const createUpdateAccount = async (payload, Config) => { +const createUpdateAccount = async (payload, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -52,6 +52,7 @@ const createUpdateAccount = async (payload, Config) => { endpointPath: `/crm/sales/api/sales_accounts/upsert`, requestMethod: 'POST', module: 'router', + metadata, }); accountResponse = processAxiosResponse(accountResponse); if (accountResponse.status !== 200 && accountResponse.status !== 201) { @@ -80,7 +81,7 @@ const createUpdateAccount = async (payload, Config) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_a_contact */ -const getUserAccountDetails = async (payload, userEmail, Config) => { +const getUserAccountDetails = async (payload, userEmail, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -99,6 +100,7 @@ const getUserAccountDetails = async (payload, userEmail, Config) => { endpointPath: `crm/sales/api/contacts/upsert?include=sales_accounts`, requestMethod: 'POST', module: 'router', + metadata, }); userSalesAccountResponse = processAxiosResponse(userSalesAccountResponse); if (userSalesAccountResponse.status !== 200 && userSalesAccountResponse.status !== 201) { @@ -117,7 +119,7 @@ const getUserAccountDetails = async (payload, userEmail, Config) => { if (!accountDetails) { throw new NetworkInstrumentationError('Fails in fetching user accountDetails'); } - const accountId = await createUpdateAccount(payload, Config); + const accountId = await createUpdateAccount(payload, Config, metadata); const accountDetail = { id: accountId, is_primary: false, @@ -139,7 +141,7 @@ const getUserAccountDetails = async (payload, userEmail, Config) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_an_account */ -const createOrUpdateListDetails = async (listName, Config) => { +const createOrUpdateListDetails = async (listName, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -151,6 +153,7 @@ const createOrUpdateListDetails = async (listName, Config) => { endpointPath: `/crm/sales/api/lists`, requestMethod: 'GET', module: 'router', + metadata, }); listResponse = processAxiosResponse(listResponse); if (listResponse.status !== 200) { @@ -173,6 +176,7 @@ const createOrUpdateListDetails = async (listName, Config) => { endpointPath: `/crm/sales/api/lists`, requestMethod: 'POST', module: 'router', + metadata, }); listResponse = processAxiosResponse(listResponse); if (listResponse.status !== 200) { @@ -231,7 +235,7 @@ const updateContactWithList = (userId, listId, Config) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_a_contact */ -const getContactsDetails = async (userEmail, Config) => { +const getContactsDetails = async (userEmail, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -250,6 +254,7 @@ const getContactsDetails = async (userEmail, Config) => { endpointPath: `/crm/sales/api/contacts/upsert`, requestMethod: 'POST', module: 'router', + metadata, }); userResponse = processAxiosResponse(userResponse); if (userResponse.status !== 200 && userResponse.status !== 201) { @@ -276,8 +281,14 @@ const getContactsDetails = async (userEmail, Config) => { * returns */ -const responseBuilderWithContactDetails = async (email, Config, payload, salesActivityTypeId) => { - const userDetails = await getContactsDetails(email, Config); +const responseBuilderWithContactDetails = async ( + email, + Config, + payload, + salesActivityTypeId, + metadata, +) => { + const userDetails = await getContactsDetails(email, Config, metadata); const userId = userDetails.response?.contact?.id; if (!userId) { throw new NetworkInstrumentationError('Failed in fetching userId. Aborting!'); @@ -295,7 +306,7 @@ const responseBuilderWithContactDetails = async (email, Config, payload, salesAc * @param {*} Config - headers, apiKey... * ref: https://developers.freshworks.com/crm/api/#admin_configuration */ -const UpdateContactWithLifeCycleStage = async (message, Config) => { +const UpdateContactWithLifeCycleStage = async (message, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -326,6 +337,7 @@ const UpdateContactWithLifeCycleStage = async (message, Config) => { endpointPath: `/crm/sales/api/selector/lifecycle_stages`, requestMethod: 'GET', module: 'router', + metadata, }); lifeCycleStagesResponse = processAxiosResponse(lifeCycleStagesResponse); if (lifeCycleStagesResponse.status !== 200) { @@ -368,7 +380,7 @@ const UpdateContactWithLifeCycleStage = async (message, Config) => { * @param {*} Config - headers, apiKey... * ref: https://developers.freshworks.com/crm/api/#list_all_sales_activities */ -const UpdateContactWithSalesActivity = async (payload, message, Config) => { +const UpdateContactWithSalesActivity = async (payload, message, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -414,6 +426,7 @@ const UpdateContactWithSalesActivity = async (payload, message, Config) => { endpointPath: `/crm/sales/api/selector/sales_activity_types`, requestMethod: 'GET', module: 'router', + metadata, }); salesActivityResponse = processAxiosResponse(salesActivityResponse); if (salesActivityResponse.status !== 200) { @@ -452,6 +465,7 @@ const UpdateContactWithSalesActivity = async (payload, message, Config) => { Config, payload, salesActivityDetails.id, + metadata, ); } diff --git a/src/v0/destinations/freshsales/transform.js b/src/v0/destinations/freshsales/transform.js index 096a2d749c..37c081be49 100644 --- a/src/v0/destinations/freshsales/transform.js +++ b/src/v0/destinations/freshsales/transform.js @@ -66,7 +66,7 @@ const identifyResponseBuilder = (message, { Config }) => { * @param {*} Config * @returns */ -const trackResponseBuilder = async (message, { Config }, event) => { +const trackResponseBuilder = async ({ message, destination: { Config }, metadata }, event) => { let payload; const response = defaultRequestConfig(); @@ -78,11 +78,12 @@ const trackResponseBuilder = async (message, { Config }, event) => { payload, message, Config, + metadata, ); break; } case 'lifecycle_stage': { - response.body.JSON = await UpdateContactWithLifeCycleStage(message, Config); + response.body.JSON = await UpdateContactWithLifeCycleStage(message, Config, metadata); response.endpoint = `https://${Config.domain}${CONFIG_CATEGORIES.IDENTIFY.baseUrl}`; break; } @@ -100,7 +101,7 @@ const trackResponseBuilder = async (message, { Config }, event) => { * @param {*} Config * @returns */ -const groupResponseBuilder = async (message, { Config }) => { +const groupResponseBuilder = async ({ message, destination: { Config }, metadata }) => { const payload = constructPayload(message, MAPPING_CONFIG[CONFIG_CATEGORIES.GROUP.name]); if (!payload) { // fail-safety for developer error @@ -114,7 +115,7 @@ const groupResponseBuilder = async (message, { Config }) => { return updateAccountWOContact(payload, Config); } - const accountDetails = await getUserAccountDetails(payload, userEmail, Config); + const accountDetails = await getUserAccountDetails(payload, userEmail, Config, metadata); const responseIdentify = identifyResponseConfig(Config); responseIdentify.body.JSON.contact = { sales_accounts: accountDetails }; responseIdentify.body.JSON.unique_identifier = { emails: userEmail }; @@ -146,7 +147,8 @@ function eventMappingHandler(message, destination) { return [...mappedEvents]; } -const processEvent = async (message, destination) => { +const processEvent = async (event) => { + const { message, destination, metadata } = event; if (!message.type) { throw new InstrumentationError('Message Type is not present. Aborting message.'); } @@ -162,25 +164,28 @@ const processEvent = async (message, destination) => { if (mappedEvents.length > 0) { const respList = await Promise.all( mappedEvents.map(async (mappedEvent) => - trackResponseBuilder(message, destination, mappedEvent), + trackResponseBuilder({ message, destination, metadata }, mappedEvent), ), ); response = respList; } else { - response = await trackResponseBuilder(message, destination, get(message, 'event')); + response = await trackResponseBuilder( + { message, destination, metadata }, + get(message, 'event'), + ); } break; } case EventType.GROUP: - response = await groupResponseBuilder(message, destination); + response = await groupResponseBuilder({ message, destination, metadata }); break; default: throw new InstrumentationError(`message type ${messageType} not supported`); } return response; }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/freshsales/utils.js b/src/v0/destinations/freshsales/utils.js index 977bde0abb..14cca0a3d6 100644 --- a/src/v0/destinations/freshsales/utils.js +++ b/src/v0/destinations/freshsales/utils.js @@ -35,7 +35,7 @@ const getHeaders = (apiKey) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_an_account */ -const createUpdateAccount = async (payload, Config) => { +const createUpdateAccount = async (payload, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -50,6 +50,7 @@ const createUpdateAccount = async (payload, Config) => { endpointPath: `/crm/sales/api/sales_accounts/upsert`, requestMethod: 'POST', module: 'router', + metadata, }); accountResponse = processAxiosResponse(accountResponse); if (accountResponse.status !== 200 && accountResponse.status !== 201) { @@ -77,7 +78,7 @@ const createUpdateAccount = async (payload, Config) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_a_contact */ -const getUserAccountDetails = async (payload, userEmail, Config) => { +const getUserAccountDetails = async (payload, userEmail, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -96,6 +97,7 @@ const getUserAccountDetails = async (payload, userEmail, Config) => { endpointPath: `/crm/sales/api/contacts/upsert?include=sales_accounts`, requestMethod: 'POST', module: 'router', + metadata, }); userSalesAccountResponse = processAxiosResponse(userSalesAccountResponse); if (userSalesAccountResponse.status !== 200 && userSalesAccountResponse.status !== 201) { @@ -114,7 +116,7 @@ const getUserAccountDetails = async (payload, userEmail, Config) => { if (!accountDetails) { throw new NetworkInstrumentationError('Fails in fetching user accountDetails'); } - const accountId = await createUpdateAccount(payload, Config); + const accountId = await createUpdateAccount(payload, Config, metadata); const accountDetail = { id: accountId, is_primary: false, @@ -135,7 +137,7 @@ const getUserAccountDetails = async (payload, userEmail, Config) => { * @returns * ref: https://developers.freshworks.com/crm/api/#upsert_a_contact */ -const getContactsDetails = async (userEmail, Config) => { +const getContactsDetails = async (userEmail, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -154,6 +156,7 @@ const getContactsDetails = async (userEmail, Config) => { endpointPath: `/crm/sales/api/contacts/upsert`, requestMethod: 'POST', module: 'router', + metadata, }); userResponse = processAxiosResponse(userResponse); if (userResponse.status !== 200 && userResponse.status !== 201) { @@ -180,8 +183,14 @@ const getContactsDetails = async (userEmail, Config) => { * returns */ -const responseBuilderWithContactDetails = async (email, Config, payload, salesActivityTypeId) => { - const userDetails = await getContactsDetails(email, Config); +const responseBuilderWithContactDetails = async ( + email, + Config, + payload, + salesActivityTypeId, + metadata, +) => { + const userDetails = await getContactsDetails(email, Config, metadata); const userId = userDetails.response?.contact?.id; if (!userId) { throw new NetworkInstrumentationError('Failed in fetching userId. Aborting!', userDetails); @@ -201,7 +210,7 @@ const responseBuilderWithContactDetails = async (email, Config, payload, salesAc * @param {*} Config - headers, apiKey... * ref: https://developers.freshworks.com/crm/api/#list_all_sales_activities */ -const UpdateContactWithSalesActivity = async (payload, message, Config) => { +const UpdateContactWithSalesActivity = async (payload, message, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -230,11 +239,12 @@ const UpdateContactWithSalesActivity = async (payload, message, Config) => { sales_activity_type_id: payload.sales_activity_type_id, }; } else { - responseBody = responseBuilderWithContactDetails( + responseBody = await responseBuilderWithContactDetails( email, Config, payload, payload.sales_activity_type_id, + metadata, ); } return responseBody; @@ -247,6 +257,7 @@ const UpdateContactWithSalesActivity = async (payload, message, Config) => { endpointPath: `/crm/sales/api/sales_activity_types`, requestMethod: 'GET', module: 'router', + metadata, }); salesActivityResponse = processAxiosResponse(salesActivityResponse); if (salesActivityResponse.status !== 200) { @@ -285,6 +296,7 @@ const UpdateContactWithSalesActivity = async (payload, message, Config) => { Config, payload, salesActivityDetails.id, + metadata, ); } @@ -298,7 +310,7 @@ const UpdateContactWithSalesActivity = async (payload, message, Config) => { * @param {*} Config - headers, apiKey... * ref: https://developers.freshworks.com/crm/api/#admin_configuration */ -const UpdateContactWithLifeCycleStage = async (message, Config) => { +const UpdateContactWithLifeCycleStage = async (message, Config, metadata) => { const requestOptions = { headers: getHeaders(Config.apiKey), }; @@ -329,6 +341,7 @@ const UpdateContactWithLifeCycleStage = async (message, Config) => { endpointPath: `/crm/sales/api/lifecycle_stages`, requestMethod: 'GET', module: 'router', + metadata, }); lifeCycleStagesResponse = processAxiosResponse(lifeCycleStagesResponse); if (lifeCycleStagesResponse.status !== 200) { diff --git a/src/v0/destinations/ga4/transform.js b/src/v0/destinations/ga4/transform.js index e4dad80564..feafc4c45f 100644 --- a/src/v0/destinations/ga4/transform.js +++ b/src/v0/destinations/ga4/transform.js @@ -39,7 +39,7 @@ require('../../util/constant'); * @param {*} Config * @returns */ -const responseBuilder = (message, { Config }) => { +const responseBuilder = (message, { Config }, destType) => { let event = get(message, 'event'); basicValidation(event); @@ -54,7 +54,7 @@ const responseBuilder = (message, { Config }) => { // get common top level rawPayload let rawPayload = constructPayload(message, trackCommonConfig); - rawPayload = addClientDetails(rawPayload, message, Config); + rawPayload = addClientDetails(rawPayload, message, Config, destType); let payload = {}; const eventConfig = ConfigCategory[`${event.toUpperCase()}`]; @@ -162,7 +162,7 @@ const responseBuilder = (message, { Config }) => { } removeReservedParameterPrefixNames(payload.params); - const integrationsObj = getIntegrationsObj(message, 'ga4'); + const integrationsObj = getIntegrationsObj(message, destType); if (isHybridModeEnabled(Config) && integrationsObj && integrationsObj.sessionId) { payload.params.session_id = integrationsObj.sessionId; } @@ -186,7 +186,7 @@ const responseBuilder = (message, { Config }) => { } // Prepare GA4 consents - const consents = prepareUserConsents(message); + const consents = prepareUserConsents(message, destType); if (!isEmptyObject(consents)) { rawPayload.consent = consents; } @@ -197,7 +197,7 @@ const responseBuilder = (message, { Config }) => { return buildDeliverablePayload(rawPayload, Config); }; -const process = (event) => { +const processEvents = ({ event, destType = 'ga4' }) => { const { message, destination } = event; const { Config } = destination; @@ -212,13 +212,13 @@ const process = (event) => { let response; switch (messageType) { case EventType.TRACK: - response = responseBuilder(message, destination); + response = responseBuilder(message, destination, destType); break; case EventType.PAGE: // GA4 custom event 'page_view' is fired for page if (!isHybridModeEnabled(Config)) { message.event = 'page_view'; - response = responseBuilder(message, destination); + response = responseBuilder(message, destination, destType); } else { throw new UnsupportedEventError( 'GA4 Hybrid mode is enabled, page calls will be sent through device mode', @@ -228,7 +228,7 @@ const process = (event) => { case EventType.GROUP: // GA4 standard event 'join_group' is fired for group message.event = 'join_group'; - response = responseBuilder(message, destination); + response = responseBuilder(message, destination, destType); break; default: throw new InstrumentationError(`Message type ${messageType} not supported`); @@ -236,4 +236,7 @@ const process = (event) => { return response; }; -module.exports = { process }; +// Keeping this for other params which comes as part of process args +const process = (event) => processEvents({ event }); + +module.exports = { process, processEvents }; diff --git a/src/v0/destinations/ga4/utils.js b/src/v0/destinations/ga4/utils.js index 18994efd7f..7b9528143c 100644 --- a/src/v0/destinations/ga4/utils.js +++ b/src/v0/destinations/ga4/utils.js @@ -448,8 +448,8 @@ const prepareUserProperties = (message, piiPropertiesToIgnore = []) => { * @param {*} message * @returns */ -const prepareUserConsents = (message) => { - const integrationObj = getIntegrationsObj(message, 'ga4') || {}; +const prepareUserConsents = (message, destType = 'ga4') => { + const integrationObj = getIntegrationsObj(message, destType) || {}; const eventLevelConsentsData = integrationObj?.consents || {}; const consentConfigMap = { analyticsPersonalizationConsent: 'ad_user_data', @@ -474,11 +474,11 @@ const basicValidation = (event) => { * @param {*} message * @returns */ -const getGA4ClientId = (message, Config) => { +const getGA4ClientId = (message, Config, destType) => { let clientId; if (isHybridModeEnabled(Config)) { - const integrationsObj = getIntegrationsObj(message, 'ga4'); + const integrationsObj = getIntegrationsObj(message, destType); if (integrationsObj?.clientId) { clientId = integrationsObj.clientId; } @@ -494,14 +494,14 @@ const getGA4ClientId = (message, Config) => { return clientId; }; -const addClientDetails = (payload, message, Config) => { +const addClientDetails = (payload, message, Config, destType = 'ga4') => { const { typesOfClient } = Config; const rawPayload = cloneDeep(payload); switch (typesOfClient) { case 'gtag': // gtag.js uses client_id // GA4 uses it as an identifier to distinguish site visitors. - rawPayload.client_id = getGA4ClientId(message, Config); + rawPayload.client_id = getGA4ClientId(message, Config, destType); if (!isDefinedAndNotNull(rawPayload.client_id)) { throw new ConfigurationError('ga4ClientId, anonymousId or messageId must be provided'); } @@ -581,6 +581,16 @@ const basicConfigvalidaiton = (Config) => { } }; +const addSessionDetailsForHybridMode = (ga4Payload, message, Config, destType = 'ga4') => { + const integrationsObj = getIntegrationsObj(message, destType); + if (isHybridModeEnabled(Config) && integrationsObj?.sessionId) { + ga4Payload.events[0].params.session_id = `${integrationsObj.sessionId}`; + } + if (integrationsObj?.sessionNumber) { + ga4Payload.events[0].params.session_number = integrationsObj.sessionNumber; + } +}; + module.exports = { addClientDetails, basicValidation, @@ -603,4 +613,5 @@ module.exports = { GA4_RESERVED_PARAMETER_EXCLUSION, removeReservedParameterPrefixNames, GA4_RESERVED_USER_PROPERTY_EXCLUSION, + addSessionDetailsForHybridMode, }; diff --git a/src/v0/destinations/ga4_v2/customMappingsHandler.js b/src/v0/destinations/ga4_v2/customMappingsHandler.js index 0f20788076..b5818d6fff 100644 --- a/src/v0/destinations/ga4_v2/customMappingsHandler.js +++ b/src/v0/destinations/ga4_v2/customMappingsHandler.js @@ -13,8 +13,9 @@ const { GA4_PARAMETERS_EXCLUSION, prepareUserProperties, sanitizeUserProperties, + addSessionDetailsForHybridMode, } = require('../ga4/utils'); -const { InstrumentationError } = require('@rudderstack/integrations-lib'); +const { InstrumentationError, ConfigurationError } = require('@rudderstack/integrations-lib'); const { removeUndefinedAndNullRecurse, constructPayload, @@ -71,6 +72,7 @@ const handleCustomMappings = (message, Config) => { // Default mapping let rawPayload = constructPayload(message, trackCommonConfig); + rawPayload = addClientDetails(rawPayload, message, Config, 'ga4_v2'); const ga4EventPayload = {}; @@ -113,11 +115,16 @@ const handleCustomMappings = (message, Config) => { // Add common top level payload let ga4BasicPayload = constructPayload(message, trackCommonConfig); - ga4BasicPayload = addClientDetails(ga4BasicPayload, message, Config); + ga4BasicPayload = addClientDetails(ga4BasicPayload, message, Config, 'ga4_v2'); const eventPropertiesMappings = mapping.eventProperties || []; - const ga4MappedPayload = applyCustomMappings(message, eventPropertiesMappings); + let ga4MappedPayload = {}; + try { + ga4MappedPayload = applyCustomMappings(message, eventPropertiesMappings); + } catch (e) { + throw new ConfigurationError(`[GA4]:: Error in custom mappings: ${e.message}`); + } removeUndefinedAndNullRecurse(ga4MappedPayload); @@ -138,11 +145,7 @@ const handleCustomMappings = (message, Config) => { const boilerplateOperations = (ga4Payload, message, Config, eventName) => { removeReservedParameterPrefixNames(ga4Payload.events[0].params); ga4Payload.events[0].name = eventName; - const integrationsObj = getIntegrationsObj(message, 'ga4'); - - if (isHybridModeEnabled(Config) && integrationsObj?.sessionId) { - ga4Payload.events[0].params.session_id = integrationsObj.sessionId; - } + const integrationsObj = getIntegrationsObj(message, 'ga4_v2'); if (ga4Payload.events[0].params) { ga4Payload.events[0].params = removeInvalidParams( @@ -155,7 +158,7 @@ const boilerplateOperations = (ga4Payload, message, Config, eventName) => { } // Prepare GA4 consents - const consents = prepareUserConsents(message); + const consents = prepareUserConsents(message, 'ga4_v2'); if (!isEmptyObject(consents)) { ga4Payload.consent = consents; } @@ -164,6 +167,8 @@ const boilerplateOperations = (ga4Payload, message, Config, eventName) => { if (isDefinedAndNotNull(ga4Payload.user_properties)) { ga4Payload.user_properties = sanitizeUserProperties(ga4Payload.user_properties); } + + addSessionDetailsForHybridMode(ga4Payload, message, Config, 'ga4_v2'); }; module.exports = { diff --git a/src/v0/destinations/ga4_v2/transform.ts b/src/v0/destinations/ga4_v2/transform.ts index 79892d791e..06d4bd9023 100644 --- a/src/v0/destinations/ga4_v2/transform.ts +++ b/src/v0/destinations/ga4_v2/transform.ts @@ -5,7 +5,7 @@ import { } from '@rudderstack/integrations-lib'; import { ProcessorTransformationRequest } from '../../../types'; import { handleCustomMappings } from './customMappingsHandler'; -import { process as ga4Process } from '../ga4/transform'; +import { processEvents as ga4Process } from '../ga4/transform'; import { basicConfigvalidaiton } from '../ga4/utils'; export function process(event: ProcessorTransformationRequest) { @@ -30,7 +30,7 @@ export function process(event: ProcessorTransformationRequest) { } if (eventPayload.type !== 'track') { - return ga4Process(event); + return ga4Process({ event, destType: 'ga4_v2' }); } basicConfigvalidaiton(Config); diff --git a/src/v0/destinations/gainsight_px/transform.js b/src/v0/destinations/gainsight_px/transform.js index a63be08c80..0911b76b6c 100644 --- a/src/v0/destinations/gainsight_px/transform.js +++ b/src/v0/destinations/gainsight_px/transform.js @@ -39,7 +39,7 @@ const { JSON_MIME_TYPE } = require('../../util/constant'); /** * Create/Update a User with user attributes */ -const identifyResponseBuilder = async (message, { Config }) => { +const identifyResponseBuilder = async (message, { Config }, metadata) => { const userId = getFieldValueFromMessage(message, 'userId'); if (!userId) { throw new InstrumentationError('userId or anonymousId is required for identify'); @@ -51,7 +51,7 @@ const identifyResponseBuilder = async (message, { Config }) => { 'Content-Type': JSON_MIME_TYPE, }; - const { success: isUserPresent } = await objectExists(userId, Config, 'user'); + const { success: isUserPresent } = await objectExists(userId, Config, 'user', metadata); let payload = constructPayload(message, identifyMapping); const name = getValueFromMessage(message, ['traits.name', 'context.traits.name']); @@ -110,7 +110,7 @@ const identifyResponseBuilder = async (message, { Config }) => { * Pros: Will make atleast 2 API call and at most 3 API calls * Cons: There might be some unwanted accounts */ -const newGroupResponseBuilder = async (message, { Config }) => { +const newGroupResponseBuilder = async (message, { Config }, metadata) => { const userId = getFieldValueFromMessage(message, 'userId'); if (!userId) { throw new InstrumentationError('userId or anonymousId is required for group'); @@ -140,12 +140,12 @@ const newGroupResponseBuilder = async (message, { Config }) => { payload = removeUndefinedAndNullValues(payload); // update account - const { success: updateSuccess, err } = await updateAccount(groupId, payload, Config); + const { success: updateSuccess, err } = await updateAccount(groupId, payload, Config, metadata); // will not throw error if it is due to unavailable accounts if (!updateSuccess && err === null) { // create account payload.id = groupId; - const { success: createSuccess, error } = await createAccount(payload, Config); + const { success: createSuccess, error } = await createAccount(payload, Config, metadata); if (!createSuccess) { throw new ConfigurationError(`failed to create account for group: ${error}`); } @@ -172,13 +172,13 @@ const newGroupResponseBuilder = async (message, { Config }) => { /** * Associates a User with an Account. */ -const groupResponseBuilder = async (message, { Config }) => { +const groupResponseBuilder = async (message, { Config }, metadata) => { const userId = getFieldValueFromMessage(message, 'userId'); if (!userId) { throw new InstrumentationError('userId or anonymousId is required for group'); } - const { success: isPresent, err: e } = await objectExists(userId, Config, 'user'); + const { success: isPresent, err: e } = await objectExists(userId, Config, 'user', metadata); if (!isPresent) { throw new InstrumentationError(`aborting group call: ${e}`); } @@ -188,7 +188,7 @@ const groupResponseBuilder = async (message, { Config }) => { throw new InstrumentationError('groupId is required for group'); } - const { success: accountIsPresent } = await objectExists(groupId, Config, 'account'); + const { success: accountIsPresent } = await objectExists(groupId, Config, 'account', metadata); let payload = constructPayload(message, groupMapping); let customAttributes = {}; @@ -210,14 +210,14 @@ const groupResponseBuilder = async (message, { Config }) => { if (accountIsPresent) { // update account - const { success: updateSuccess, err } = await updateAccount(groupId, payload, Config); + const { success: updateSuccess, err } = await updateAccount(groupId, payload, Config, metadata); if (!updateSuccess) { throw new ConfigurationError(`failed to update account for group: ${err}`); } } else { // create account payload.id = groupId; - const { success: createSuccess, err } = await createAccount(payload, Config); + const { success: createSuccess, err } = await createAccount(payload, Config, metadata); if (!createSuccess) { throw new ConfigurationError(`failed to create account for group: ${err}`); } @@ -279,7 +279,7 @@ const trackResponseBuilder = (message, { Config }) => { * Processing Single event */ const process = async (event) => { - const { message, destination } = event; + const { message, destination, metadata } = event; if (!message.type) { throw new InstrumentationError('Message Type is not present. Aborting message.'); } @@ -301,16 +301,16 @@ const process = async (event) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder(message, destination, metadata); break; case EventType.TRACK: response = trackResponseBuilder(message, destination); break; case EventType.GROUP: if (limitAPIForGroup) { - response = await newGroupResponseBuilder(message, destination); + response = await newGroupResponseBuilder(message, destination, metadata); } else { - response = await groupResponseBuilder(message, destination); + response = await groupResponseBuilder(message, destination, metadata); } break; default: diff --git a/src/v0/destinations/gainsight_px/util.js b/src/v0/destinations/gainsight_px/util.js index 83d23566dd..7300189297 100644 --- a/src/v0/destinations/gainsight_px/util.js +++ b/src/v0/destinations/gainsight_px/util.js @@ -1,9 +1,9 @@ const { NetworkError } = require('@rudderstack/integrations-lib'); -const myAxios = require('../../../util/myAxios'); const { ENDPOINTS } = require('./config'); const tags = require('../../util/tags'); const { getDynamicErrorType } = require('../../../adapters/utils/networkUtils'); const { JSON_MIME_TYPE } = require('../../util/constant'); +const { handleHttpRequest } = require('../../../adapters/network'); const handleErrorResponse = (error, customErrMessage, expectedErrStatus, defaultStatus = 400) => { let destResp; @@ -37,133 +37,86 @@ const handleErrorResponse = (error, customErrMessage, expectedErrStatus, default * @param {*} objectType * @returns */ -const objectExists = async (id, Config, objectType) => { +const objectExists = async (id, Config, objectType, metadata) => { let url = `${ENDPOINTS.USERS_ENDPOINT}/${id}`; - let err = 'invalid response while searching user'; if (objectType === 'account') { url = `${ENDPOINTS.ACCOUNTS_ENDPOINT}/${id}`; - err = 'invalid response while searching account'; } - - let response; - try { - response = await myAxios.get( - url, - { - headers: { - 'X-APTRINSIC-API-KEY': Config.apiKey, - 'Content-Type': JSON_MIME_TYPE, - }, - }, - { - destType: 'gainsight_px', - feature: 'transformation', - requestMethod: 'GET', - endpointPath: '/accounts/accountId', - module: 'router', - }, - ); - if (response && response.status === 200) { - return { success: true, err: null }; - } - const defStatus = 400; - const status = response ? response.status || defStatus : defStatus; - throw new NetworkError( - err, - status, - { - [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), + const { httpResponse: res } = await handleHttpRequest( + 'get', + url, + { + headers: { + 'X-APTRINSIC-API-KEY': Config.apiKey, + 'Content-Type': JSON_MIME_TYPE, }, - response, - ); - } catch (error) { - return handleErrorResponse(error, `error while fetching ${objectType}`, 404); + }, + { + metadata, + destType: 'gainsight_px', + feature: 'transformation', + requestMethod: 'GET', + endpointPath: '/accounts/accountId', + module: 'router', + }, + ); + if (res.success && res.response && res.response.status === 200) { + return { success: true, err: null }; } + return handleErrorResponse(res.response, `error while fetching ${objectType}`, 404); }; -const createAccount = async (payload, Config) => { - let response; - try { - response = await myAxios.post( - ENDPOINTS.ACCOUNTS_ENDPOINT, - payload, - { - headers: { - 'X-APTRINSIC-API-KEY': Config.apiKey, - 'Content-Type': JSON_MIME_TYPE, - }, - }, - { - destType: 'gainsight_px', - feature: 'transformation', - requestMethod: 'POST', - endpointPath: '/accounts', - module: 'router', - }, - ); - if (response && response.status === 201) { - return { success: true, err: null }; - } - - const defStatus = 400; - const status = response ? response.status || defStatus : defStatus; - throw new NetworkError( - 'invalid response while creating account', - status, - { - [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), +const createAccount = async (payload, Config, metadata) => { + const { httpResponse: res } = await handleHttpRequest( + 'post', + ENDPOINTS.ACCOUNTS_ENDPOINT, + payload, + { + headers: { + 'X-APTRINSIC-API-KEY': Config.apiKey, + 'Content-Type': JSON_MIME_TYPE, }, - response, - ); - } catch (error) { - return handleErrorResponse(error, 'error while creating account', 400); + }, + { + metadata, + destType: 'gainsight_px', + feature: 'transformation', + requestMethod: 'POST', + endpointPath: '/accounts', + module: 'router', + }, + ); + if (res.success && res.response.status === 201) { + return { success: true, err: null }; } + return handleErrorResponse(res.response, 'error while creating account', 400); }; -const updateAccount = async (accountId, payload, Config) => { - let response; - try { - response = await myAxios.put( - `${ENDPOINTS.ACCOUNTS_ENDPOINT}/${accountId}`, - payload, - { - headers: { - 'X-APTRINSIC-API-KEY': Config.apiKey, - 'Content-Type': JSON_MIME_TYPE, - }, - }, - { - destType: 'gainsight_px', - feature: 'transformation', - requestMethod: 'PUT', - endpointPath: '/accounts/accountId', - module: 'router', - }, - ); - if (response && response.status === 204) { - return { success: true, err: null }; - } - const defStatus = 400; - const status = response ? response.status || defStatus : defStatus; - throw new NetworkError( - 'invalid response while updating account', - status, - { - [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), +const updateAccount = async (accountId, payload, Config, metadata) => { + const { httpResponse: res } = await handleHttpRequest( + 'put', + `${ENDPOINTS.ACCOUNTS_ENDPOINT}/${accountId}`, + payload, + { + headers: { + 'X-APTRINSIC-API-KEY': Config.apiKey, + 'Content-Type': JSON_MIME_TYPE, }, - response, - ); - } catch (error) { - // it will only occur if the user does not exist - if ( - error.response?.status === 404 && - error.response?.data?.externalapierror?.status === 'NOT_FOUND' - ) { - return { success: false, err: null }; - } - return handleErrorResponse(error, 'error while updating account', 400); + }, + { + metadata, + destType: 'gainsight_px', + feature: 'transformation', + requestMethod: 'PUT', + endpointPath: '/accounts/accountId', + module: 'router', + }, + ); + if (res.success && res.response.status === 204) { + return { success: true, err: null }; } + return handleErrorResponse(res.response, 'error while updating account', 400); }; /** diff --git a/src/v0/destinations/google_adwords_enhanced_conversions/config.js b/src/v0/destinations/google_adwords_enhanced_conversions/config.js index e8f486fb7a..8a3f8ab673 100644 --- a/src/v0/destinations/google_adwords_enhanced_conversions/config.js +++ b/src/v0/destinations/google_adwords_enhanced_conversions/config.js @@ -1,6 +1,8 @@ const { getMappingConfig } = require('../../util'); -const BASE_ENDPOINT = 'https://googleads.googleapis.com/v15/customers'; +const API_VERSION = 'v17'; + +const BASE_ENDPOINT = 'https://googleads.googleapis.com/v17/customers'; const CONFIG_CATEGORIES = { TRACK_CONFIG: { type: 'track', name: 'trackConfig' }, @@ -17,4 +19,5 @@ module.exports = { hashAttributes, CONVERSION_ACTION_ID_CACHE_TTL, destType: 'google_adwords_enhanced_conversions', + API_VERSION, }; diff --git a/src/v0/destinations/google_adwords_enhanced_conversions/networkHandler.js b/src/v0/destinations/google_adwords_enhanced_conversions/networkHandler.js index 21a5fff78b..a2795a1671 100644 --- a/src/v0/destinations/google_adwords_enhanced_conversions/networkHandler.js +++ b/src/v0/destinations/google_adwords_enhanced_conversions/networkHandler.js @@ -3,7 +3,7 @@ const sha256 = require('sha256'); const { NetworkError, NetworkInstrumentationError } = require('@rudderstack/integrations-lib'); const SqlString = require('sqlstring'); const { prepareProxyRequest, handleHttpRequest } = require('../../../adapters/network'); -const { isHttpStatusSuccess, getAuthErrCategoryFromStCode } = require('../../util/index'); +const { isHttpStatusSuccess } = require('../../util/index'); const { CONVERSION_ACTION_ID_CACHE_TTL } = require('./config'); const Cache = require('../../util/cache'); @@ -16,6 +16,7 @@ const { const { BASE_ENDPOINT } = require('./config'); const tags = require('../../util/tags'); +const { getAuthErrCategory } = require('../../util/googleUtils'); const ERROR_MSG_PATH = 'response[0].error.message'; @@ -69,7 +70,7 @@ const getConversionActionId = async ({ method, headers, params, metadata }) => { [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), }, response, - getAuthErrCategoryFromStCode(status), + getAuthErrCategory(gaecConversionActionIdResponse), ); } const conversionActionId = get( @@ -126,9 +127,7 @@ const responseHandler = (responseParams) => { // Ref - https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto if (partialFailureError && partialFailureError.code !== 0) { throw new NetworkError( - `[Google Adwords Enhanced Conversions]:: partialFailureError - ${JSON.stringify( - partialFailureError, - )}`, + JSON.stringify(partialFailureError), 400, { [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(400), @@ -153,7 +152,7 @@ const responseHandler = (responseParams) => { [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), }, response, - getAuthErrCategoryFromStCode(status), + getAuthErrCategory(destinationResponse), ); }; diff --git a/src/v0/destinations/google_adwords_offline_conversions/networkHandler.js b/src/v0/destinations/google_adwords_offline_conversions/networkHandler.js index 8c86fc9bc0..df69a95299 100644 --- a/src/v0/destinations/google_adwords_offline_conversions/networkHandler.js +++ b/src/v0/destinations/google_adwords_offline_conversions/networkHandler.js @@ -11,7 +11,6 @@ const { isHttpStatusSuccess, getHashFromArray, isDefinedAndNotNullAndNotEmpty, - getAuthErrCategoryFromStCode, } = require('../../util'); const { getConversionActionId } = require('./utils'); const Cache = require('../../util/cache'); @@ -21,6 +20,7 @@ const { getDynamicErrorType, } = require('../../../adapters/utils/networkUtils'); const tags = require('../../util/tags'); +const { getAuthErrCategory } = require('../../util/googleUtils'); const conversionCustomVariableCache = new Cache(CONVERSION_CUSTOM_VARIABLE_CACHE_TTL); @@ -43,10 +43,10 @@ const createJob = async ({ endpoint, headers, payload, metadata }) => { const { response, status } = createJobResponse; if (!isHttpStatusSuccess(status)) { throw new AbortedError( - `[Google Ads Offline Conversions]:: ${response?.error?.message} during google_ads_offline_store_conversions Job Creation`, + `[Google Ads Offline Conversions]:: ${response?.error?.message || response?.[0]?.error?.message} during google_ads_offline_store_conversions Job Creation`, status, response, - getAuthErrCategoryFromStCode(status), + getAuthErrCategory(createJobResponse), ); } return response.resourceName.split('/')[3]; @@ -74,7 +74,7 @@ const addConversionToJob = async ({ endpoint, headers, jobId, payload, metadata `[Google Ads Offline Conversions]:: ${response?.error?.message} during google_ads_offline_store_conversions Add Conversion`, status, response, - getAuthErrCategoryFromStCode(get(addConversionToJobResponse, 'status')), + getAuthErrCategory(addConversionToJobResponse), ); } return true; @@ -135,7 +135,7 @@ const getConversionCustomVariable = async ({ headers, params, metadata }) => { [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), }, response || searchStreamResponse, - getAuthErrCategoryFromStCode(status), + getAuthErrCategory(searchStreamResponse), ); } const conversionCustomVariable = get(searchStreamResponse, 'response.0.results'); @@ -318,7 +318,7 @@ const responseHandler = (responseParams) => { `[Google Ads Offline Conversions]:: ${response?.error?.message} during google_ads_offline_conversions response transformation`, status, response, - getAuthErrCategoryFromStCode(status), + getAuthErrCategory(destinationResponse), ); }; diff --git a/src/v0/destinations/google_adwords_offline_conversions/utils.js b/src/v0/destinations/google_adwords_offline_conversions/utils.js index 7c21371ccf..7228bb8da4 100644 --- a/src/v0/destinations/google_adwords_offline_conversions/utils.js +++ b/src/v0/destinations/google_adwords_offline_conversions/utils.js @@ -16,7 +16,6 @@ const { getFieldValueFromMessage, isDefinedAndNotNullAndNotEmpty, isDefinedAndNotNull, - getAuthErrCategoryFromStCode, getAccessToken, getIntegrationsObj, } = require('../../util'); @@ -34,7 +33,7 @@ const { const { processAxiosResponse } = require('../../../adapters/utils/networkUtils'); const Cache = require('../../util/cache'); const helper = require('./helper'); -const { finaliseConsent } = require('../../util/googleUtils'); +const { finaliseConsent, getAuthErrCategory } = require('../../util/googleUtils'); const conversionActionIdCache = new Cache(CONVERSION_ACTION_ID_CACHE_TTL); @@ -86,7 +85,7 @@ const getConversionActionId = async ({ headers, params, metadata }) => { )} during google_ads_offline_conversions response transformation`, status, response, - getAuthErrCategoryFromStCode(get(searchStreamResponse, 'status')), + getAuthErrCategory(searchStreamResponse), ); } const conversionAction = get( diff --git a/src/v0/destinations/google_adwords_remarketing_lists/config.js b/src/v0/destinations/google_adwords_remarketing_lists/config.js index c7b97e0e6c..0478a1b11b 100644 --- a/src/v0/destinations/google_adwords_remarketing_lists/config.js +++ b/src/v0/destinations/google_adwords_remarketing_lists/config.js @@ -1,6 +1,8 @@ const { getMappingConfig } = require('../../util'); -const BASE_ENDPOINT = 'https://googleads.googleapis.com/v16/customers'; +const API_VERSION = 'v17'; + +const BASE_ENDPOINT = `https://googleads.googleapis.com/${API_VERSION}/customers`; const CONFIG_CATEGORIES = { AUDIENCE_LIST: { type: 'audienceList', name: 'offlineDataJobs' }, ADDRESSINFO: { type: 'addressInfo', name: 'addressInfo' }, @@ -22,6 +24,7 @@ const consentConfigMap = { }; module.exports = { + API_VERSION, BASE_ENDPOINT, TYPEOFLIST, attributeMapping, diff --git a/src/v0/destinations/google_adwords_remarketing_lists/networkHandler.js b/src/v0/destinations/google_adwords_remarketing_lists/networkHandler.js index 4c9a9156e8..8fa4867b78 100644 --- a/src/v0/destinations/google_adwords_remarketing_lists/networkHandler.js +++ b/src/v0/destinations/google_adwords_remarketing_lists/networkHandler.js @@ -1,12 +1,13 @@ const { NetworkError } = require('@rudderstack/integrations-lib'); +const get = require('get-value'); const { prepareProxyRequest, handleHttpRequest } = require('../../../adapters/network'); -const { isHttpStatusSuccess, getAuthErrCategoryFromStCode } = require('../../util/index'); - +const { isHttpStatusSuccess } = require('../../util/index'); const { processAxiosResponse, getDynamicErrorType, } = require('../../../adapters/utils/networkUtils'); const tags = require('../../util/tags'); +const { getAuthErrCategory } = require('../../util/googleUtils'); /** * This function helps to create a offlineUserDataJobs * @param endpoint @@ -147,18 +148,24 @@ const gaAudienceProxyRequest = async (request) => { }; const gaAudienceRespHandler = (destResponse, stageMsg) => { - const { status, response } = destResponse; - // const respAttributes = response["@attributes"] || null; - // const { stat, err_code: errorCode } = respAttributes; + let { status } = destResponse; + const { response } = destResponse; + + if ( + status === 400 && + get(response, 'error.details.0.errors.0.errorCode.databaseError') === 'CONCURRENT_MODIFICATION' + ) { + status = 500; + } throw new NetworkError( - `${response?.error?.message} ${stageMsg}`, + `${JSON.stringify(response)} ${stageMsg}`, status, { [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), }, response, - getAuthErrCategoryFromStCode(status), + getAuthErrCategory(destResponse), ); }; diff --git a/src/v0/destinations/google_adwords_remarketing_lists/util.test.js b/src/v0/destinations/google_adwords_remarketing_lists/util.test.js index e9fe90c317..a5897776c0 100644 --- a/src/v0/destinations/google_adwords_remarketing_lists/util.test.js +++ b/src/v0/destinations/google_adwords_remarketing_lists/util.test.js @@ -1,5 +1,5 @@ const { populateIdentifiers, responseBuilder } = require('./util'); - +const { API_VERSION } = require('./config'); const accessToken = 'abcd1234'; const developerToken = 'ijkl9101'; const body = { @@ -66,7 +66,7 @@ const expectedResponse = { version: '1', type: 'REST', method: 'POST', - endpoint: 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer abcd1234', 'Content-Type': 'application/json', diff --git a/src/v0/destinations/googlepubsub/util.js b/src/v0/destinations/googlepubsub/util.js index 8af71ac25f..a163356ed0 100644 --- a/src/v0/destinations/googlepubsub/util.js +++ b/src/v0/destinations/googlepubsub/util.js @@ -1,3 +1,4 @@ +const { ConfigurationAuthError } = require('@rudderstack/integrations-lib'); const { getHashFromArray, getValueFromMessage, @@ -18,6 +19,10 @@ const getTopic = (event) => { const { eventToTopicMap } = destination.Config; const hashMap = getHashFromArray(eventToTopicMap, 'from', 'to'); + if (!message.type) { + throw new ConfigurationAuthError('type is required for event'); + } + return ( (message.event ? hashMap[message.event.toLowerCase()] : null) || hashMap[message.type.toLowerCase()] || diff --git a/src/v0/destinations/hs/HSTransform-v1.js b/src/v0/destinations/hs/HSTransform-v1.js index 51feebea74..ed94bd7c17 100644 --- a/src/v0/destinations/hs/HSTransform-v1.js +++ b/src/v0/destinations/hs/HSTransform-v1.js @@ -51,7 +51,7 @@ const { JSON_MIME_TYPE } = require('../../util/constant'); * @param {*} propertyMap * @returns */ -const processLegacyIdentify = async (message, destination, propertyMap) => { +const processLegacyIdentify = async ({ message, destination, metadata }, propertyMap) => { const { Config } = destination; let traits = getFieldValueFromMessage(message, 'traits'); const mappedToDestination = get(message, MappedToDestinationKey); @@ -82,7 +82,7 @@ const processLegacyIdentify = async (message, destination, propertyMap) => { response.method = defaultPatchRequestConfig.requestMethod; } - traits = await populateTraits(propertyMap, traits, destination); + traits = await populateTraits(propertyMap, traits, destination, metadata); response.body.JSON = removeUndefinedAndNullValues({ properties: traits }); response.source = 'rETL'; response.operation = operation; @@ -92,7 +92,10 @@ const processLegacyIdentify = async (message, destination, propertyMap) => { } const { email } = traits; - const userProperties = await getTransformedJSON(message, destination, propertyMap); + const userProperties = await getTransformedJSON( + { message, destination, metadata }, + propertyMap, + ); const payload = { properties: formatPropertyValueForIdentify(userProperties), @@ -134,7 +137,7 @@ const processLegacyIdentify = async (message, destination, propertyMap) => { * @param {*} propertyMap * @returns */ -const processLegacyTrack = async (message, destination, propertyMap) => { +const processLegacyTrack = async ({ message, destination, metadata }, propertyMap) => { const { Config } = destination; if (!Config.hubID) { @@ -151,7 +154,7 @@ const processLegacyTrack = async (message, destination, propertyMap) => { id: getDestinationExternalID(message, 'hubspotId'), }; - const userProperties = await getTransformedJSON(message, destination, propertyMap); + const userProperties = await getTransformedJSON({ message, destination, metadata }, propertyMap); const payload = { ...parameters, ...userProperties }; const params = removeUndefinedAndNullValues(payload); diff --git a/src/v0/destinations/hs/HSTransform-v2.js b/src/v0/destinations/hs/HSTransform-v2.js index d2b26f1ab8..3dd9f87ea4 100644 --- a/src/v0/destinations/hs/HSTransform-v2.js +++ b/src/v0/destinations/hs/HSTransform-v2.js @@ -20,6 +20,7 @@ const { getDestinationExternalIDInfoForRetl, getDestinationExternalIDObjectForRetl, } = require('../../util'); +const stats = require('../../../util/stats'); const { IDENTIFY_CRM_UPDATE_CONTACT, IDENTIFY_CRM_CREATE_NEW_CONTACT, @@ -68,7 +69,7 @@ const addHsAuthentication = (response, Config) => { * @param {*} propertyMap * @returns */ -const processIdentify = async (message, destination, propertyMap) => { +const processIdentify = async ({ message, destination, metadata }, propertyMap) => { const { Config } = destination; let traits = getFieldValueFromMessage(message, 'traits'); const mappedToDestination = get(message, MappedToDestinationKey); @@ -125,7 +126,7 @@ const processIdentify = async (message, destination, propertyMap) => { response.method = defaultPatchRequestConfig.requestMethod; } - traits = await populateTraits(propertyMap, traits, destination); + traits = await populateTraits(propertyMap, traits, destination, metadata); response.body.JSON = removeUndefinedAndNullValues({ properties: traits }); response.source = 'rETL'; response.operation = operation; @@ -138,10 +139,10 @@ const processIdentify = async (message, destination, propertyMap) => { // if contactId is not provided then search if (!contactId) { - contactId = await searchContacts(message, destination); + contactId = await searchContacts(message, destination, metadata); } - const properties = await getTransformedJSON(message, destination, propertyMap); + const properties = await getTransformedJSON({ message, destination, metadata }, propertyMap); const payload = { properties, @@ -187,7 +188,7 @@ const processIdentify = async (message, destination, propertyMap) => { * @param {*} destination * @returns */ -const processTrack = async (message, destination) => { +const processTrack = async ({ message, destination }) => { const { Config } = destination; let payload = constructPayload(message, mappingConfig[ConfigCategory.TRACK.name]); @@ -235,10 +236,14 @@ const processTrack = async (message, destination) => { const batchIdentify = (arrayChunksIdentify, batchedResponseList, batchOperation) => { // list of chunks [ [..], [..] ] + const { destinationId } = arrayChunksIdentify[0][0].destination; arrayChunksIdentify.forEach((chunk) => { const identifyResponseList = []; const metadata = []; - + // add metric for batch size + stats.gauge('hs_batch_size', chunk.length, { + destination_id: destinationId, + }); // extracting message, destination value // from the first event in a batch const { message, destination } = chunk[0]; diff --git a/src/v0/destinations/hs/transform.js b/src/v0/destinations/hs/transform.js index 9eed244af4..b6ca213f03 100644 --- a/src/v0/destinations/hs/transform.js +++ b/src/v0/destinations/hs/transform.js @@ -1,7 +1,11 @@ const get = require('get-value'); const { InstrumentationError } = require('@rudderstack/integrations-lib'); const { EventType } = require('../../../constants'); -const { handleRtTfSingleEventError, getDestinationExternalIDInfoForRetl } = require('../../util'); +const { + handleRtTfSingleEventError, + getDestinationExternalIDInfoForRetl, + groupEventsByType: batchEventsInOrder, +} = require('../../util'); const { API_VERSION } = require('./config'); const { processLegacyIdentify, @@ -15,9 +19,10 @@ const { fetchFinalSetOfTraits, getProperties, validateDestinationConfig, + convertToResponseFormat, } = require('./util'); -const processSingleMessage = async (message, destination, propertyMap) => { +const processSingleMessage = async ({ message, destination, metadata }, propertyMap) => { if (!message.type) { throw new InstrumentationError('Message type is not present. Aborting message.'); } @@ -30,18 +35,18 @@ const processSingleMessage = async (message, destination, propertyMap) => { case EventType.IDENTIFY: { response = []; if (destination.Config.apiVersion === API_VERSION.v3) { - response.push(await processIdentify(message, destination, propertyMap)); + response.push(await processIdentify({ message, destination, metadata }, propertyMap)); } else { // Legacy API - response.push(await processLegacyIdentify(message, destination, propertyMap)); + response.push(await processLegacyIdentify({ message, destination, metadata }, propertyMap)); } break; } case EventType.TRACK: if (destination.Config.apiVersion === API_VERSION.v3) { - response = await processTrack(message, destination, propertyMap); + response = await processTrack({ message, destination }, propertyMap); } else { - response = await processLegacyTrack(message, destination, propertyMap); + response = await processLegacyTrack({ message, destination, metadata }, propertyMap); } break; default: @@ -53,36 +58,38 @@ const processSingleMessage = async (message, destination, propertyMap) => { // has been deprecated - using routerTransform for both the versions const process = async (event) => { - const { destination, message } = event; + const { destination, message, metadata } = event; const mappedToDestination = get(message, MappedToDestinationKey); let events = []; events = [event]; if (mappedToDestination && GENERIC_TRUE_VALUES.includes(mappedToDestination?.toString())) { // get info about existing objects and splitting accordingly. - events = await splitEventsForCreateUpdate([event], destination); + events = await splitEventsForCreateUpdate([event], destination, metadata); } - return processSingleMessage(events[0].message, events[0].destination); + return processSingleMessage({ + message: events[0].message, + destination: events[0].destination, + metadata: events[0].metadata || metadata, + }); }; - -// we are batching by default at routerTransform -const processRouterDest = async (inputs, reqMetadata) => { +const processBatchRouter = async (inputs, reqMetadata) => { let tempInputs = inputs; - - const successRespList = []; - const errorRespList = []; // using the first destination config for transforming the batch - const { destination } = tempInputs[0]; + const { destination, metadata } = tempInputs[0]; let propertyMap; const mappedToDestination = get(tempInputs[0].message, MappedToDestinationKey); const { objectType } = getDestinationExternalIDInfoForRetl(tempInputs[0].message, 'HS'); - + const successRespList = []; + const errorRespList = []; + // batch implementation + let batchedResponseList = []; try { if (mappedToDestination && GENERIC_TRUE_VALUES.includes(mappedToDestination?.toString())) { // skip splitting the batches to inserts and updates if object it is an association if (objectType.toLowerCase() !== 'association') { - propertyMap = await getProperties(destination); + propertyMap = await getProperties(destination, metadata); // get info about existing objects and splitting accordingly. - tempInputs = await splitEventsForCreateUpdate(tempInputs, destination); + tempInputs = await splitEventsForCreateUpdate(tempInputs, destination, metadata); } } else { // reduce the no. of calls for properties endpoint @@ -90,16 +97,22 @@ const processRouterDest = async (inputs, reqMetadata) => { (input) => fetchFinalSetOfTraits(input.message) !== undefined, ); if (traitsFound) { - propertyMap = await getProperties(destination); + propertyMap = await getProperties(destination, metadata); } } } catch (error) { // Any error thrown from the above try block applies to all the events - return tempInputs.map((input) => handleRtTfSingleEventError(input, error, reqMetadata)); + return { + batchedResponseList, + errorRespList: tempInputs.map((input) => + handleRtTfSingleEventError(input, error, reqMetadata), + ), + dontBatchEvents: [], + }; } await Promise.all( - tempInputs.map(async (input) => { + inputs.map(async (input) => { try { if (input.message.statusCode) { // already transformed event @@ -111,8 +124,7 @@ const processRouterDest = async (inputs, reqMetadata) => { } else { // event is not transformed let receivedResponse = await processSingleMessage( - input.message, - destination, + { message: input.message, destination, metadata: input.metadata }, propertyMap, ); @@ -137,16 +149,51 @@ const processRouterDest = async (inputs, reqMetadata) => { }), ); + const dontBatchTrueResponses = []; + const dontBatchFalseOrUndefinedResponses = []; + // segregating successRepList depending on dontbatch value + successRespList.forEach((successResp) => { + if (successResp.metadata?.dontBatch) { + dontBatchTrueResponses.push(successResp); + } else { + dontBatchFalseOrUndefinedResponses.push(successResp); + } + }); + // batch implementation - let batchedResponseList = []; - if (successRespList.length > 0) { + if (dontBatchFalseOrUndefinedResponses.length > 0) { if (destination.Config.apiVersion === API_VERSION.v3) { - batchedResponseList = batchEvents(successRespList); + batchedResponseList = batchEvents(dontBatchFalseOrUndefinedResponses); } else { - batchedResponseList = legacyBatchEvents(successRespList); + batchedResponseList = legacyBatchEvents(dontBatchFalseOrUndefinedResponses); } } - return [...batchedResponseList, ...errorRespList]; + return { + batchedResponseList, + errorRespList, + // if there are any events where dontbatch set to true we need to update them according to the response format + dontBatchEvents: convertToResponseFormat(dontBatchTrueResponses), + }; +}; +// we are batching by default at routerTransform +const processRouterDest = async (inputs, reqMetadata) => { + const tempNewInputs = batchEventsInOrder(inputs); + const batchedResponseList = []; + const errorRespList = []; + const dontBatchEvents = []; + const promises = tempNewInputs.map(async (inputEvents) => { + const response = await processBatchRouter(inputEvents, reqMetadata); + return response; + }); + + const results = await Promise.all(promises); + + results.forEach((response) => { + errorRespList.push(...response.errorRespList); + batchedResponseList.push(...response.batchedResponseList); + dontBatchEvents.push(...response.dontBatchEvents); + }); + return [...batchedResponseList, ...errorRespList, ...dontBatchEvents]; }; module.exports = { process, processRouterDest }; diff --git a/src/v0/destinations/hs/util.js b/src/v0/destinations/hs/util.js index b30207fe15..56ec6e4167 100644 --- a/src/v0/destinations/hs/util.js +++ b/src/v0/destinations/hs/util.js @@ -22,6 +22,9 @@ const { getValueFromMessage, isNull, validateEventName, + defaultBatchRequestConfig, + defaultPostRequestConfig, + getSuccessRespEvents, } = require('../../util'); const { CONTACT_PROPERTY_MAP_ENDPOINT, @@ -90,7 +93,7 @@ const fetchFinalSetOfTraits = (message) => { * @param {*} destination * @returns */ -const getProperties = async (destination) => { +const getProperties = async (destination, metadata) => { let hubspotPropertyMap = {}; let hubspotPropertyMapResponse; const { Config } = destination; @@ -110,6 +113,7 @@ const getProperties = async (destination) => { endpointPath: `/properties/v1/contacts/properties`, requestMethod: 'GET', module: 'router', + metadata, }); hubspotPropertyMapResponse = processAxiosResponse(hubspotPropertyMapResponse); } else { @@ -124,6 +128,7 @@ const getProperties = async (destination) => { endpointPath: `/properties/v1/contacts/properties?hapikey`, requestMethod: 'GET', module: 'router', + metadata, }, ); hubspotPropertyMapResponse = processAxiosResponse(hubspotPropertyMapResponse); @@ -208,7 +213,7 @@ const getUTCMidnightTimeStampValue = (propValue) => { * @param {*} propertyMap * @returns */ -const getTransformedJSON = async (message, destination, propertyMap) => { +const getTransformedJSON = async ({ message, destination, metadata }, propertyMap) => { let rawPayload = {}; const traits = fetchFinalSetOfTraits(message); @@ -217,7 +222,7 @@ const getTransformedJSON = async (message, destination, propertyMap) => { if (!propertyMap) { // fetch HS properties // eslint-disable-next-line no-param-reassign - propertyMap = await getProperties(destination); + propertyMap = await getProperties(destination, metadata); } rawPayload = constructPayload(message, hsCommonConfigJson); @@ -325,7 +330,7 @@ const getLookupFieldValue = (message, lookupField) => { * @param {*} destination * @returns */ -const searchContacts = async (message, destination) => { +const searchContacts = async (message, destination, metadata) => { const { Config } = destination; let searchContactsResponse; let contactId; @@ -377,6 +382,7 @@ const searchContacts = async (message, destination) => { endpointPath, requestMethod: 'POST', module: 'router', + metadata, }, ); searchContactsResponse = processAxiosResponse(searchContactsResponse); @@ -389,6 +395,7 @@ const searchContacts = async (message, destination) => { endpointPath, requestMethod: 'POST', module: 'router', + metadata, }); searchContactsResponse = processAxiosResponse(searchContactsResponse); } @@ -528,6 +535,7 @@ const performHubSpotSearch = async ( objectType, identifierType, destination, + metadata, ) => { let checkAfter = 1; const searchResults = []; @@ -556,6 +564,7 @@ const performHubSpotSearch = async ( endpointPath, requestMethod: 'POST', module: 'router', + metadata, }); const processedResponse = processAxiosResponse(searchResponse); @@ -655,7 +664,7 @@ const getRequestData = (identifierType, chunk) => { * @param {*} inputs * @param {*} destination */ -const getExistingContactsData = async (inputs, destination) => { +const getExistingContactsData = async (inputs, destination, metadata) => { const { Config } = destination; const hsIdsToBeUpdated = []; const firstMessage = inputs[0].message; @@ -683,6 +692,7 @@ const getExistingContactsData = async (inputs, destination) => { objectType, identifierType, destination, + metadata, ); if (searchResults.length > 0) { hsIdsToBeUpdated.push(...searchResults); @@ -728,9 +738,9 @@ const setHsSearchId = (input, id, useSecondaryProp = false) => { * For email as primary key we use `hs_additional_emails` as well property to search existing contacts * */ -const splitEventsForCreateUpdate = async (inputs, destination) => { +const splitEventsForCreateUpdate = async (inputs, destination, metadata) => { // get all the id and properties of already existing objects needed for update. - const hsIdsToBeUpdated = await getExistingContactsData(inputs, destination); + const hsIdsToBeUpdated = await getExistingContactsData(inputs, destination, metadata); const resultInput = inputs.map((input) => { const { message } = input; @@ -805,12 +815,12 @@ const getHsSearchId = (message) => { * @param {*} traits * @param {*} destination */ -const populateTraits = async (propertyMap, traits, destination) => { +const populateTraits = async (propertyMap, traits, destination, metadata) => { const populatedTraits = traits; let propertyToTypeMap = propertyMap; if (!propertyToTypeMap) { // fetch HS properties - propertyToTypeMap = await getProperties(destination); + propertyToTypeMap = await getProperties(destination, metadata); } const keys = Object.keys(populatedTraits); @@ -837,6 +847,42 @@ const addExternalIdToHSTraits = (message) => { set(getFieldValueFromMessage(message, 'traits'), externalIdObj.identifierType, externalIdObj.id); }; +const convertToResponseFormat = (successRespListWithDontBatchTrue) => { + const response = []; + if (Array.isArray(successRespListWithDontBatchTrue)) { + successRespListWithDontBatchTrue.forEach((event) => { + const { message, metadata, destination } = event; + const endpoint = get(message, 'endpoint'); + + const batchedResponse = defaultBatchRequestConfig(); + batchedResponse.batchedRequest.headers = message.headers; + batchedResponse.batchedRequest.endpoint = endpoint; + batchedResponse.batchedRequest.body = message.body; + batchedResponse.batchedRequest.params = message.params; + batchedResponse.batchedRequest.method = defaultPostRequestConfig.requestMethod; + batchedResponse.metadata = [metadata]; + batchedResponse.destination = destination; + + response.push( + getSuccessRespEvents( + batchedResponse.batchedRequest, + batchedResponse.metadata, + batchedResponse.destination, + ), + ); + }); + } + return response; +}; + +const isIterable = (obj) => { + // checks for null and undefined + if (obj == null) { + return false; + } + return typeof obj[Symbol.iterator] === 'function'; +}; + module.exports = { validateDestinationConfig, addExternalIdToHSTraits, @@ -856,4 +902,6 @@ module.exports = { getObjectAndIdentifierType, extractIDsForSearchAPI, getRequestData, + convertToResponseFormat, + isIterable, }; diff --git a/src/v0/destinations/hs/util.test.js b/src/v0/destinations/hs/util.test.js index ea2e10dc3d..819baff83c 100644 --- a/src/v0/destinations/hs/util.test.js +++ b/src/v0/destinations/hs/util.test.js @@ -3,6 +3,7 @@ const { extractIDsForSearchAPI, validatePayloadDataTypes, getObjectAndIdentifierType, + isIterable, } = require('./util'); const { primaryToSecondaryFields } = require('./config'); @@ -239,3 +240,21 @@ describe('getRequestDataAndRequestOptions utility test cases', () => { expect(requestData).toEqual(expectedRequestData); }); }); + +describe('isIterable utility test cases', () => { + it('should return true when the input is an array', () => { + const input = [1, 2, 3]; + const result = isIterable(input); + expect(result).toBe(true); + }); + it('should return false when the input is null', () => { + const input = null; + const result = isIterable(input); + expect(result).toBe(false); + }); + it('should return false when the input is undefined', () => { + const input = undefined; + const result = isIterable(input); + expect(result).toBe(false); + }); +}); diff --git a/src/v0/destinations/klaviyo/batchUtil.js b/src/v0/destinations/klaviyo/batchUtil.js new file mode 100644 index 0000000000..0351bd2e2f --- /dev/null +++ b/src/v0/destinations/klaviyo/batchUtil.js @@ -0,0 +1,238 @@ +const lodash = require('lodash'); +const { defaultRequestConfig, getSuccessRespEvents, isDefinedAndNotNull } = require('../../util'); +const { JSON_MIME_TYPE } = require('../../util/constant'); +const { BASE_ENDPOINT, CONFIG_CATEGORIES, MAX_BATCH_SIZE, revision } = require('./config'); +const { buildRequest, getSubscriptionPayload } = require('./util'); + +/** + * This function groups the subscription responses on list id + * @param {*} subscribeResponseList + * @returns + * Example subsribeResponseList = + * [ + * { payload: {id:'list_id', profile: {}}, metadata:{} }, + * { payload: {id:'list_id', profile: {}}, metadata:{} } + * ] + */ +const groupSubscribeResponsesUsingListIdV2 = (subscribeResponseList) => { + const subscribeEventGroups = lodash.groupBy( + subscribeResponseList, + (event) => event.payload.listId, + ); + return subscribeEventGroups; +}; + +/** + * This function takes susbscription as input and batches them into a single request body + * @param {subscription} + * subscription= {listId, subscriptionProfileList, operation} + * subscription.operation could be either subscribe or unsubscribe + */ +const generateBatchedSubscriptionRequest = (subscription, destination) => { + const subscriptionPayloadResponse = defaultRequestConfig(); + // fetching listId from first event as listId is same for all the events + const profiles = []; // list of profiles to be subscribed + const { listId, subscriptionProfileList, operation } = subscription; + subscriptionProfileList.forEach((profileList) => profiles.push(...profileList)); + subscriptionPayloadResponse.body.JSON = getSubscriptionPayload(listId, profiles, operation); + subscriptionPayloadResponse.endpoint = `${BASE_ENDPOINT}/api/${operation === 'subscribe' ? 'profile-subscription-bulk-create-jobs' : 'profile-subscription-bulk-delete-jobs'}`; + subscriptionPayloadResponse.headers = { + Authorization: `Klaviyo-API-Key ${destination.Config.privateApiKey}`, + 'Content-Type': JSON_MIME_TYPE, + Accept: JSON_MIME_TYPE, + revision, + }; + return subscriptionPayloadResponse; +}; + +/** + * This function generates requests using profiles array and returns an array of all these requests + * @param {*} profiles + * @param {*} destination + */ +const getProfileRequests = (profiles, destination) => { + const profilePayloadResponses = profiles.map((profile) => + buildRequest(profile, destination, CONFIG_CATEGORIES.IDENTIFYV2), + ); + return profilePayloadResponses; +}; + +/** + * this function populates profileSubscriptionAndMetadataArr with respective profiles based upon common metadata + * @param {*} profileSubscriptionAndMetadataArr + * @param {*} metaDataIndexMap + * @param {*} profiles + * @returns updated profileSubscriptionAndMetadataArr obj + */ +const populateArrWithRespectiveProfileData = ( + profileSubscriptionAndMetadataArr, + metaDataIndexMap, + profiles, +) => { + const updatedPSMArr = lodash.cloneDeep(profileSubscriptionAndMetadataArr); + profiles.forEach((profile) => { + const index = metaDataIndexMap.get(profile.metadata.jobId); + if (isDefinedAndNotNull(index)) { + // using isDefinedAndNotNull as index can be 0 + updatedPSMArr[index].profiles.push(profile.payload); + } else { + // in case there is no subscription for a given profile + updatedPSMArr.push({ + profiles: [profile.payload], + metadataList: [profile.metadata], + }); + } + }); + return updatedPSMArr; +}; + +/** + * This function generates the final output batched payload for each object in profileSubscriptionAndMetadataArr + * ex: + * profileSubscriptionAndMetadataArr = [ + { + subscription: { subscriptionProfileList, listId1, operation }, + metadataList1, + profiles: [respectiveProfiles for above metadata] + }, + { + subscription: { subscriptionProfile List With No Profiles, listId2, operation }, + metadataList2, + }, + { + metadataList3, + profiles: [respectiveProfiles for above metadata with no subscription] + } + ] + * @param {*} profileSubscriptionAndMetadataArr + * @param {*} destination + * @returns + */ +const buildProfileAndSubscriptionRequests = (profileSubscriptionAndMetadataArr, destination) => { + const finalResponseList = []; + profileSubscriptionAndMetadataArr.forEach((profileSubscriptionData) => { + const batchedRequest = []; + // we are keeping profiles request prior to subscription ones as first profile creation and then subscription should happen + if (profileSubscriptionData.profiles?.length > 0) { + batchedRequest.push(...getProfileRequests(profileSubscriptionData.profiles, destination)); + } + // following condition ensures if no subscriptions are present we won't build subscription payload + if (profileSubscriptionData.subscription?.subscriptionProfileList?.length > 0) { + batchedRequest.push( + generateBatchedSubscriptionRequest(profileSubscriptionData.subscription, destination), + ); + } + + finalResponseList.push( + getSuccessRespEvents(batchedRequest, profileSubscriptionData.metadataList, destination, true), + ); + }); + return finalResponseList; +}; + +/** + * This function updates the profileSubscriptionAndMetadataArr array with the subscription requests + * @param {*} subscribeStatusList + * @param {*} profilesList + * @param {*} operation + * @param {*} profileSubscriptionAndMetadataArr + * @param {*} metaDataIndexMap + */ +const updateArrWithSubscriptions = ( + subscribeStatusList, + profilesList, + operation, + profileSubscriptionAndMetadataArr, + metaDataIndexMap, +) => { + const subscribeEventGroups = groupSubscribeResponsesUsingListIdV2(subscribeStatusList); + + Object.keys(subscribeEventGroups).forEach((listId) => { + // eventChunks = [[e1,e2,e3,..batchSize],[e1,e2,e3,..batchSize]..] + const eventChunks = lodash.chunk(subscribeEventGroups[listId], MAX_BATCH_SIZE); + eventChunks.forEach((chunk) => { + // get subscriptionProfiles for the chunk + const subscriptionProfileList = chunk.map((event) => event.payload?.profile); + // get metadata for this chunk + const metadataList = chunk.map((event) => event.metadata); + // get list of jobIds from the above metdadata + const jobIdList = metadataList.map((metadata) => metadata.jobId); + // using length as index + const index = profileSubscriptionAndMetadataArr.length; + // push the jobId: index to metadataIndex mapping which let us know the metadata respective payload index position in batched request + jobIdList.forEach((jobId) => { + metaDataIndexMap.set(jobId, index); + }); + profileSubscriptionAndMetadataArr.push({ + subscription: { subscriptionProfileList, listId, operation }, + metadataList, + profiles: [], + }); + }); + }); +}; + +/** + * This function performs batching for the subscription and unsubscription requests and attaches respective profile request as well if present + * @param {*} subscribeList + * @param {*} unsubscribeList + * @param {*} profilesList + * @param {*} destination + * @returns + */ +const batchRequestV2 = (subscribeList, unsubscribeList, profilesList, destination) => { + const profileSubscriptionAndMetadataArr = []; + const metaDataIndexMap = new Map(); + updateArrWithSubscriptions( + subscribeList, + profilesList, + 'subscribe', + profileSubscriptionAndMetadataArr, + metaDataIndexMap, + ); + updateArrWithSubscriptions( + unsubscribeList, + profilesList, + 'unsubscribe', + profileSubscriptionAndMetadataArr, + metaDataIndexMap, + ); + const subscriptionsAndProfileArr = populateArrWithRespectiveProfileData( + profileSubscriptionAndMetadataArr, + metaDataIndexMap, + profilesList, + ); + /* Till this point I have a profileSubscriptionAndMetadataArr + containing the the events in one object for which batching has to happen in following format + [ + { + subscription: { subscriptionProfileList, listId1, operation }, + metadataList1, + profiles: [respectiveProfiles for above metadata] + }, + { + subscription: { subscriptionProfile List With No Profiles, listId2, operation }, + metadataList2, + }, + { + metadataList3, + profiles: [respectiveProfiles for above metadata with no subscription] + } + ] + */ + return buildProfileAndSubscriptionRequests(subscriptionsAndProfileArr, destination); + /* for identify calls with batching batched with identify with no batching + we will construct O/P as: + [ + [2 calls for identify with batching], + [1 call identify calls with batching] + ] + */ +}; + +module.exports = { + groupSubscribeResponsesUsingListIdV2, + populateArrWithRespectiveProfileData, + generateBatchedSubscriptionRequest, + batchRequestV2, +}; diff --git a/src/v0/destinations/klaviyo/batchUtil.test.js b/src/v0/destinations/klaviyo/batchUtil.test.js new file mode 100644 index 0000000000..9c04a402ca --- /dev/null +++ b/src/v0/destinations/klaviyo/batchUtil.test.js @@ -0,0 +1,192 @@ +const { OperatorType } = require('@rudderstack/json-template-engine'); +const { + groupSubscribeResponsesUsingListIdV2, + populateArrWithRespectiveProfileData, + generateBatchedSubscriptionRequest, +} = require('./batchUtil'); +const { revision } = require('./config'); + +describe('groupSubscribeResponsesUsingListIdV2', () => { + // Groups subscription responses by listId correctly + it('should group subscription responses by listId correctly when given a valid list', () => { + const subscribeResponseList = [ + { payload: { listId: 'list_1', profile: {} }, metadata: {} }, + { payload: { listId: 'list_1', profile: {} }, metadata: {} }, + { payload: { listId: 'list_2', profile: {} }, metadata: {} }, + ]; + + const expectedOutput = { + list_1: [ + { payload: { listId: 'list_1', profile: {} }, metadata: {} }, + { payload: { listId: 'list_1', profile: {} }, metadata: {} }, + ], + list_2: [{ payload: { listId: 'list_2', profile: {} }, metadata: {} }], + }; + + const result = groupSubscribeResponsesUsingListIdV2(subscribeResponseList); + + expect(result).toEqual(expectedOutput); + }); + + // Handles empty subscription response list + it('should return an empty object when given an empty subscription response list', () => { + const subscribeResponseList = []; + + const expectedOutput = {}; + + const result = groupSubscribeResponsesUsingListIdV2(subscribeResponseList); + + expect(result).toEqual(expectedOutput); + }); +}); + +describe('populateArrWithRespectiveProfileData', () => { + // Correctly populates array when all profiles have corresponding metadata + it('should correctly populate array when all profiles have corresponding metadata', () => { + const profileSubscriptionAndMetadataArr = [ + { profiles: [], metadataList: [{ jobId: '1' }], subscriptions: [] }, + { profiles: [], metadataList: [{ jobId: '2' }], subscriptions: [] }, + ]; + const metadataIndexMap = new Map([ + ['1', 0], + ['2', 1], + ]); + const profiles = [ + { payload: { name: 'John' }, metadata: { jobId: '1' } }, + { payload: { name: 'Doe' }, metadata: { jobId: '2' } }, + ]; + + const result = populateArrWithRespectiveProfileData( + profileSubscriptionAndMetadataArr, + metadataIndexMap, + profiles, + ); + + expect(result[0].profiles).toEqual([{ name: 'John' }]); + expect(result[1].profiles).toEqual([{ name: 'Doe' }]); + }); + + // Handles empty profileSubscriptionAndMetadataArr input + it('should handle empty profileSubscriptionAndMetadataArr input', () => { + const profileSubscriptionAndMetadataArr = []; + const metadataIndexMap = new Map(); + const profiles = [{ payload: { name: 'John' }, metadata: { jobId: '1' } }]; + + const result = populateArrWithRespectiveProfileData( + profileSubscriptionAndMetadataArr, + metadataIndexMap, + profiles, + ); + + expect(result).toEqual([ + { + profiles: [{ name: 'John' }], + metadataList: [{ jobId: '1' }], + }, + ]); + }); +}); + +// Generated by CodiumAI + +describe('generateBatchedSubscriptionRequest', () => { + // Generates a batched subscription request with valid subscription and destination inputs + it('should generate a valid batched subscription request when given valid subscription and destination inputs', () => { + const subscription = { + listId: 'test-list-id', + subscriptionProfileList: [[{ id: 'profile1' }, { id: 'profile2' }], [{ id: 'profile3' }]], + operation: 'subscribe', + }; + const destination = { + Config: { + privateApiKey: 'test-api-key', + }, + }; + const expectedRequest = { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: { + Authorization: 'Klaviyo-API-Key test-api-key', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision, + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { data: [{ id: 'profile1' }, { id: 'profile2' }, { id: 'profile3' }] }, + }, + relationships: { + list: { + data: { + type: 'list', + id: 'test-list-id', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }; + const result = generateBatchedSubscriptionRequest(subscription, destination); + expect(result).toEqual(expectedRequest); + }); + + // Handles empty subscriptionProfileList gracefully + it('should handle empty subscriptionProfileList gracefully', () => { + const subscription = { + listId: 'test-list-id', + subscriptionProfileList: [], + operation: 'subscribe', + }; + const destination = { + Config: { + privateApiKey: 'test-api-key', + }, + }; + const expectedRequest = { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: { + Authorization: 'Klaviyo-API-Key test-api-key', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision, + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { profiles: { data: [] } }, + relationships: { + list: { + data: { + type: 'list', + id: 'test-list-id', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }; + const result = generateBatchedSubscriptionRequest(subscription, destination); + expect(result).toEqual(expectedRequest); + }); +}); diff --git a/src/v0/destinations/klaviyo/config.js b/src/v0/destinations/klaviyo/config.js index d8583ab9cb..9f907330df 100644 --- a/src/v0/destinations/klaviyo/config.js +++ b/src/v0/destinations/klaviyo/config.js @@ -9,14 +9,21 @@ const MAX_BATCH_SIZE = 100; const CONFIG_CATEGORIES = { IDENTIFY: { name: 'KlaviyoIdentify', apiUrl: '/api/profiles' }, - SCREEN: { name: 'KlaviyoTrack', apiUrl: '/api/events' }, + IDENTIFYV2: { name: 'KlaviyoProfileV2', apiUrl: '/api/profile-import' }, TRACK: { name: 'KlaviyoTrack', apiUrl: '/api/events' }, + TRACKV2: { name: 'KlaviyoTrackV2', apiUrl: '/api/events' }, GROUP: { name: 'KlaviyoGroup' }, PROFILE: { name: 'KlaviyoProfile' }, + PROFILEV2: { name: 'KlaviyoProfileV2' }, STARTED_CHECKOUT: { name: 'StartedCheckout' }, VIEWED_PRODUCT: { name: 'ViewedProduct' }, ADDED_TO_CART: { name: 'AddedToCart' }, ITEMS: { name: 'Items' }, + SUBSCRIBE: { name: 'KlaviyoProfileV2', apiUrl: '/api/profile-subscription-bulk-create-jobs' }, + UNSUBSCRIBE: { + name: 'KlaviyoProfileV2', + apiUrl: '/api/profile-subscription-bulk-delete-jobs', + }, }; const ecomExclusionKeys = [ 'name', @@ -55,10 +62,37 @@ const LIST_CONF = { SUBSCRIBE: 'subscribe_with_consentInfo', ADD_TO_LIST: 'subscribe_without_consentInfo', }; - +const useUpdatedKlaviyoAPI = process.env.USE_UPDATED_KLAVIYO_API === 'true' || false; const MAPPING_CONFIG = getMappingConfig(CONFIG_CATEGORIES, __dirname); -const destType = 'klaviyo'; +const WhiteListedTraitsV2 = [ + 'email', + 'firstName', + 'firstname', + 'first_name', + 'lastName', + 'lastname', + 'last_name', + 'phone', + 'title', + 'organization', + 'city', + 'region', + 'country', + 'zip', + 'image', + 'timezone', + 'anonymousId', + 'userId', + 'properties', + 'location', + '_kx', + 'street', + 'address', +]; +const destType = 'klaviyo'; +// api version used +const revision = '2024-06-15'; module.exports = { BASE_ENDPOINT, MAX_BATCH_SIZE, @@ -70,4 +104,7 @@ module.exports = { eventNameMapping, jsonNameMapping, destType, + revision, + WhiteListedTraitsV2, + useUpdatedKlaviyoAPI, }; diff --git a/src/v0/destinations/klaviyo/data/AddedToCart.json b/src/v0/destinations/klaviyo/data/AddedToCart.json index 302cc79804..13ba9e7d47 100644 --- a/src/v0/destinations/klaviyo/data/AddedToCart.json +++ b/src/v0/destinations/klaviyo/data/AddedToCart.json @@ -2,6 +2,7 @@ { "destKey": "$value", "sourceKeys": "value", + "metadata": { "type": "isFloat" }, "required": false }, { diff --git a/src/v0/destinations/klaviyo/data/KlaviyoProfileV2.json b/src/v0/destinations/klaviyo/data/KlaviyoProfileV2.json new file mode 100644 index 0000000000..310f3eba38 --- /dev/null +++ b/src/v0/destinations/klaviyo/data/KlaviyoProfileV2.json @@ -0,0 +1,128 @@ +[ + { + "destKey": "external_id", + "sourceKeys": "userIdOnly", + "sourceFromGenericMap": true + }, + { + "destKey": "anonymous_id", + "sourceKeys": "anonymousId" + }, + { + "destKey": "email", + "sourceKeys": "emailOnly", + "sourceFromGenericMap": true + }, + { + "destKey": "first_name", + "sourceKeys": "firstName", + "sourceFromGenericMap": true + }, + { + "destKey": "last_name", + "sourceKeys": "lastName", + "sourceFromGenericMap": true + }, + { + "destKey": "phone_number", + "sourceKeys": "phone", + "sourceFromGenericMap": true + }, + { + "destKey": "title", + "sourceKeys": ["traits.title", "context.traits.title", "properties.title"] + }, + { + "destKey": "organization", + "sourceKeys": ["traits.organization", "context.traits.organization", "properties.organization"] + }, + { + "destKey": "location.city", + "sourceKeys": [ + "traits.city", + "traits.address.city", + "context.traits.city", + "context.traits.address.city", + "properties.city" + ] + }, + { + "destKey": "location.region", + "sourceKeys": [ + "traits.region", + "traits.address.region", + "context.traits.region", + "context.traits.address.region", + "properties.region", + "traits.state", + "traits.address.state", + "context.traits.address.state", + "context.traits.state", + "properties.state" + ] + }, + { + "destKey": "location.country", + "sourceKeys": [ + "traits.country", + "traits.address.country", + "context.traits.country", + "context.traits.address.country", + "properties.country" + ] + }, + { + "destKey": "location.zip", + "sourceKeys": [ + "traits.zip", + "traits.postalcode", + "traits.postalCode", + "traits.address.zip", + "traits.address.postalcode", + "traits.address.postalCode", + "context.traits.zip", + "context.traits.postalcode", + "context.traits.postalCode", + "context.traits.address.zip", + "context.traits.address.postalcode", + "context.traits.address.postalCode", + "properties.zip", + "properties.postalcode", + "properties.postalCode" + ] + }, + { + "destKey": "location.ip", + "sourceKeys": ["context.ip", "request_ip"] + }, + { + "destKey": "_kx", + "sourceKeys": ["traits._kx", "context.traits._kx"] + }, + { + "destKey": "image", + "sourceKeys": ["traits.image", "context.traits.image", "properties.image"] + }, + { + "destKey": "location.timezone", + "sourceKeys": ["traits.timezone", "context.traits.timezone", "properties.timezone"] + }, + { + "destKey": "location.latitude", + "sourceKeys": ["latitude", "context.address.latitude", "context.location.latitude"] + }, + { + "destKey": "location.longitude", + "sourceKeys": ["longitude", "context.address.longitude", "context.location.longitude"] + }, + { + "destKey": "location.address1", + "sourceKeys": [ + "traits.street", + "traits.address.street", + "context.traits.street", + "context.traits.address.street", + "properties.street" + ] + } +] diff --git a/src/v0/destinations/klaviyo/data/KlaviyoTrackV2.json b/src/v0/destinations/klaviyo/data/KlaviyoTrackV2.json new file mode 100644 index 0000000000..a92472d215 --- /dev/null +++ b/src/v0/destinations/klaviyo/data/KlaviyoTrackV2.json @@ -0,0 +1,44 @@ +[ + { + "destKey": "value", + "sourceKeys": ["properties.revenue", "properties.total", "properties.value"], + "metadata": { + "excludes": [ + "event", + "email", + "phone", + "revenue", + "total", + "value", + "value_currency", + "currency" + ], + "type": "isFloat" + } + }, + { + "destKey": "value_currency", + "sourceKeys": "properties.currency" + }, + { + "destKey": "time", + "sourceKeys": "timestamp", + "sourceFromGenericMap": true + }, + { + "destKey": "properties", + "sourceKeys": "properties", + "metadata": { + "excludes": [ + "event", + "email", + "phone", + "revenue", + "total", + "value", + "value_currency", + "currency" + ] + } + } +] diff --git a/src/v0/destinations/klaviyo/data/StartedCheckout.json b/src/v0/destinations/klaviyo/data/StartedCheckout.json index 1a4691709d..10441cb277 100644 --- a/src/v0/destinations/klaviyo/data/StartedCheckout.json +++ b/src/v0/destinations/klaviyo/data/StartedCheckout.json @@ -7,7 +7,8 @@ { "destKey": "$value", "sourceKeys": "value", - "required": false + "required": false, + "metadata": { "type": "isFloat" } }, { "destKey": "Categories", diff --git a/src/v0/destinations/klaviyo/klaviyoUtil.test.js b/src/v0/destinations/klaviyo/klaviyoUtil.test.js new file mode 100644 index 0000000000..051a6c3599 --- /dev/null +++ b/src/v0/destinations/klaviyo/klaviyoUtil.test.js @@ -0,0 +1,227 @@ +const { addSubscribeFlagToTraits } = require('./util'); + +describe('addSubscribeFlagToTraits', () => { + // The function should add a 'subscribe' property to the 'properties' object if it exists in the input 'traitsInfo'. + it('should add subscribe property to properties object when it exists in traitsInfo', () => { + // Arrange + const traitsInfo = { + properties: { + name: 'John', + age: 30, + }, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(true); + }); + + // The input 'traitsInfo' object is null. + it('should create a new traitsInfo object with properties object containing subscribe property when traitsInfo is null', () => { + // Arrange + const traitsInfo = null; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result).toEqual(null); + }); + + // The function should create a new 'properties' object with a 'subscribe' property and assign it to the 'traitsInfo' if 'properties' does not exist in the input 'traitsInfo'. + it("should create a new 'properties' object with a 'subscribe' property when 'properties' does not exist in traitsInfo", () => { + // Arrange + const traitsInfo = {}; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties).toBeDefined(); + expect(result.properties.subscribe).toBe(true); + }); + + // The function should return the modified 'traitsInfo' object with the 'subscribe' property added. + it('should add subscribe property to properties object when it exists in traitsInfo', () => { + // Arrange + const traitsInfo = { + properties: { + name: 'John', + age: 30, + }, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(true); + }); + + // The input 'traitsInfo' object has an empty 'properties' object. + it('should add subscribe property to properties object when it exists in traitsInfo', () => { + // Arrange + const traitsInfo = { + properties: {}, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(true); + }); + + // The input 'traitsInfo' object has a 'properties' object with a 'subscribe' property already present. + it('should add subscribe property to properties object when it exists in traitsInfo', () => { + // Arrange + const traitsInfo = { + properties: { + name: 'John', + age: 30, + subscribe: false, + }, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(false); + }); + + // The function should not modify any other properties of the 'traitsInfo' object. + it('should not modify any other properties of the traitsInfo object', () => { + // Arrange + const traitsInfo = { + properties: { + name: 'John', + age: 30, + }, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(true); + expect(result.properties.name).toBe('John'); + expect(result.properties.age).toBe(30); + }); + + // The function should handle cases where the input 'traitsInfo' object has nested objects. + it('should add subscribe property to nested properties object when it exists in traitsInfo', () => { + // Arrange + const traitsInfo = { + properties: { + name: 'John', + age: 30, + address: { + street: '123 Main St', + city: 'New York', + }, + }, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(true); + expect(result.properties.address).toMatchObject({ + street: '123 Main St', + city: 'New York', + }); + }); + + // The function should handle cases where the input 'traitsInfo' object has properties with null or undefined values. + it('should add subscribe property to properties object when it exists in traitsInfo', () => { + // Arrange + const traitsInfo = { + properties: { + name: 'John', + age: 30, + address: null, + }, + }; + + // Act + const result = addSubscribeFlagToTraits(traitsInfo); + + // Assert + expect(result.properties.subscribe).toBe(true); + }); +}); + +const { getProfileMetadataAndMetadataFields } = require('./util'); + +describe('getProfileMetadataAndMetadataFields', () => { + // Correctly generates metadata with fields to unset, append, and unappend when all fields are provided + it('should generate metadata with fields to unset, append, and unappend when all fields are provided', () => { + const message = { + integrations: { + Klaviyo: { + fieldsToUnset: ['Unset1', 'Unset2'], + fieldsToAppend: ['appendList1', 'appendList2'], + fieldsToUnappend: ['unappendList1', 'unappendList2'], + }, + All: true, + }, + traits: { + appendList1: 'New Value 1', + appendList2: 'New Value 2', + unappendList1: 'Old Value 1', + unappendList2: 'Old Value 2', + }, + }; + + jest.mock('../../util', () => ({ + getIntegrationsObj: jest.fn(() => message.integrations.Klaviyo), + getFieldValueFromMessage: jest.fn(() => message.traits), + isDefinedAndNotNull: jest.fn((value) => value !== null && value !== undefined), + })); + + const result = getProfileMetadataAndMetadataFields(message); + + expect(result).toEqual({ + meta: { + patch_properties: { + append: { + appendList1: 'New Value 1', + appendList2: 'New Value 2', + }, + unappend: { + unappendList1: 'Old Value 1', + unappendList2: 'Old Value 2', + }, + unset: ['Unset1', 'Unset2'], + }, + }, + metadataFields: [ + 'Unset1', + 'Unset2', + 'appendList1', + 'appendList2', + 'unappendList1', + 'unappendList2', + ], + }); + }); + + // Handles null or undefined message input gracefully + it('should return empty metadata and metadataFields when message is null or undefined', () => { + jest.mock('../../util', () => ({ + getIntegrationsObj: jest.fn(() => null), + getFieldValueFromMessage: jest.fn(() => ({})), + isDefinedAndNotNull: jest.fn((value) => value !== null && value !== undefined), + })); + + let result = getProfileMetadataAndMetadataFields(null); + expect(result).toEqual({ meta: { patch_properties: {} }, metadataFields: [] }); + + result = getProfileMetadataAndMetadataFields(undefined); + expect(result).toEqual({ meta: { patch_properties: {} }, metadataFields: [] }); + }); +}); diff --git a/src/v0/destinations/klaviyo/transform.js b/src/v0/destinations/klaviyo/transform.js index 09e75919f9..d73dbca600 100644 --- a/src/v0/destinations/klaviyo/transform.js +++ b/src/v0/destinations/klaviyo/transform.js @@ -13,6 +13,7 @@ const { eventNameMapping, jsonNameMapping, } = require('./config'); +const { processRouter: processRouterV2, processV2 } = require('./transformV2'); const { createCustomerProperties, subscribeUserToList, @@ -20,6 +21,7 @@ const { batchSubscribeEvents, getIdFromNewOrExistingProfile, profileUpdateResponseBuilder, + addSubscribeFlagToTraits, } = require('./util'); const { defaultRequestConfig, @@ -33,6 +35,7 @@ const { adduserIdFromExternalId, getSuccessRespEvents, handleRtTfSingleEventError, + groupEventsByType, flattenJson, isNewStatusCodesAccepted, } = require('../../util'); @@ -58,11 +61,13 @@ const identifyRequestHandler = async ( // If listId property is present try to subscribe/member user in list const { privateApiKey, enforceEmailAsPrimary, listId, flattenProperties } = destination.Config; const mappedToDestination = get(message, MappedToDestinationKey); + let traitsInfo = getFieldValueFromMessage(message, 'traits'); if (mappedToDestination) { addExternalIdToTraits(message); adduserIdFromExternalId(message); + traitsInfo = addSubscribeFlagToTraits(traitsInfo); } - const traitsInfo = getFieldValueFromMessage(message, 'traits'); + let propertyPayload = constructPayload(message, MAPPING_CONFIG[category.name]); // Extract other K-V property from traits about user custom properties let customPropertyPayload = {}; @@ -277,6 +282,9 @@ const groupRequestHandler = (message, category, destination) => { // Main event processor using specific handler funcs const processEvent = async (event, reqMetadata) => { const { message, destination, metadata } = event; + if (destination.Config?.apiVersion === 'v2') { + return processV2(event, reqMetadata); + } if (!message.type) { throw new InstrumentationError('Event type is required'); } @@ -326,12 +334,16 @@ const getEventChunks = (event, subscribeRespList, nonSubscribeRespList) => { } }; -const processRouterDest = async (inputs, reqMetadata) => { +const processRouter = async (inputs, reqMetadata) => { + const { destination } = inputs[0]; + // This is used to switch to latest API version + if (destination.Config?.apiVersion === 'v2') { + return processRouterV2(inputs, reqMetadata); + } let batchResponseList = []; const batchErrorRespList = []; const subscribeRespList = []; const nonSubscribeRespList = []; - const { destination } = inputs[0]; await Promise.all( inputs.map(async (event) => { try { @@ -392,7 +404,26 @@ const processRouterDest = async (inputs, reqMetadata) => { batchResponseList = [...batchedSubscribeResponseList, ...nonSubscribeSuccessList]; - return [...batchResponseList, ...batchErrorRespList]; + return { successEvents: batchResponseList, errorEvents: batchErrorRespList }; +}; +const processRouterDest = async (inputs, reqMetadata) => { + /** + We are doing this to maintain the order of events not only fo transformation but for delivery as well + Job Id: 1 2 3 4 5 6 + Input : ['user1 track1', 'user1 identify 1', 'user1 track 2', 'user2 identify 1', 'user2 track 1', 'user1 track 3'] + Output after batching : [['user1 track1'],['user1 identify 1', 'user2 identify 1'], [ 'user1 track 2', 'user2 track 1', 'user1 track 3']] + Output after transformation: [1, [2,4], [3,5,6]] + */ + const inputsGroupedByType = groupEventsByType(inputs); + const respList = []; + const errList = []; + await Promise.all( + inputsGroupedByType.map(async (typedEventList) => { + const { successEvents, errorEvents } = await processRouter(typedEventList, reqMetadata); + respList.push(...successEvents); + errList.push(...errorEvents); + }), + ); + return [...respList, ...errList]; }; - module.exports = { process, processRouterDest }; diff --git a/src/v0/destinations/klaviyo/transformV2.js b/src/v0/destinations/klaviyo/transformV2.js new file mode 100644 index 0000000000..bcb028bcea --- /dev/null +++ b/src/v0/destinations/klaviyo/transformV2.js @@ -0,0 +1,244 @@ +/* eslint-disable no-nested-ternary */ +/* eslint-disable no-underscore-dangle */ +/* eslint-disable array-callback-return */ +const get = require('get-value'); +const { ConfigurationError, InstrumentationError } = require('@rudderstack/integrations-lib'); +const { EventType, MappedToDestinationKey } = require('../../../constants'); +const { CONFIG_CATEGORIES, MAPPING_CONFIG } = require('./config'); +const { + constructProfile, + subscribeOrUnsubscribeUserToListV2, + buildRequest, + buildSubscriptionOrUnsubscriptionPayload, + getTrackRequests, + fetchTransformedEvents, + addSubscribeFlagToTraits, +} = require('./util'); +const { batchRequestV2 } = require('./batchUtil'); +const { + constructPayload, + getFieldValueFromMessage, + removeUndefinedAndNullValues, + handleRtTfSingleEventError, + addExternalIdToTraits, + adduserIdFromExternalId, + flattenJson, + isDefinedAndNotNull, +} = require('../../util'); + +/** + * Main Identify request handler func + * The function is used to create/update new users and also for subscribing + * users to the list. + * DOCS: 1. https://developers.klaviyo.com/en/reference/create_or_update_profile + * 2. https://developers.klaviyo.com/en/reference/subscribe_profiles + * @param {*} message + * @param {*} category + * @param {*} destination + * @returns one object with keys profile and subscription(conditional) and values as objects + */ +const identifyRequestHandler = (message, category, destination) => { + // If listId property is present try to subscribe/member user in list + const { listId } = destination.Config; + let traitsInfo = getFieldValueFromMessage(message, 'traits'); + const mappedToDestination = get(message, MappedToDestinationKey); + if (mappedToDestination) { + addExternalIdToTraits(message); + adduserIdFromExternalId(message); + traitsInfo = addSubscribeFlagToTraits(traitsInfo); + } + const payload = removeUndefinedAndNullValues(constructProfile(message, destination, true)); + const response = { profile: payload }; + // check if user wants to subscribe/unsubscribe profile or do nothing and listId is present or not + if ( + isDefinedAndNotNull(traitsInfo?.properties?.subscribe) && + (traitsInfo.properties?.listId || listId) + ) { + response.subscription = subscribeOrUnsubscribeUserToListV2( + message, + traitsInfo, + destination, + traitsInfo.properties.subscribe ? 'subscribe' : 'unsubscribe', + ); + } + return response; +}; + +/** + * Main handler func for track/screen request + * User info needs to be mapped to a track event (mandatory) + * DOCS: https://developers.klaviyo.com/en/reference/create_event + * @param {*} message + * @param {*} category + * @param {*} destination + * @returns event request + */ +const trackOrScreenRequestHandler = (message, category, destination) => { + const { flattenProperties } = destination.Config; + // event for track and name for screen call + const event = get(message, 'event') || get(message, 'name'); + if (event && typeof event !== 'string') { + throw new InstrumentationError('Event type should be a string'); + } + const attributes = constructPayload(message, MAPPING_CONFIG[category.name]); + + // if flattenProperties is enabled from UI, flatten the event properties + attributes.properties = flattenProperties + ? flattenJson(attributes.properties, '.', 'normal', false) + : attributes.properties; + + // get profile object + attributes.profile = removeUndefinedAndNullValues(constructProfile(message, destination, false)); + attributes.metric = { + data: { + type: 'metric', + attributes: { + name: event, + }, + }, + }; + return { event: { data: { type: 'event', attributes } } }; +}; + +/** + * Main handlerfunc for group request add/subscribe to or remove/delete users to the list based on property sent + * DOCS:https://developers.klaviyo.com/en/reference/subscribe_profiles + * @param {*} message + * @param {*} category + * @param {*} destination + * @returns subscription object + */ +const groupRequestHandler = (message, category, destination) => { + if (!message.groupId) { + throw new InstrumentationError('groupId is a required field for group events'); + } + const traitsInfo = getFieldValueFromMessage(message, 'traits'); + if (!isDefinedAndNotNull(traitsInfo?.subscribe)) { + throw new InstrumentationError('Subscribe flag should be included in group call'); + } + return { + subscription: subscribeOrUnsubscribeUserToListV2( + message, + traitsInfo, + destination, + traitsInfo.subscribe ? 'subscribe' : 'unsubscribe', + ), + }; +}; + +const processEvent = (event) => { + const { message, destination } = event; + if (!message.type) { + throw new InstrumentationError('Event type is required'); + } + if (!destination.Config.privateApiKey) { + throw new ConfigurationError(`Private API Key is a required field for ${message.type} events`); + } + const messageType = message.type.toLowerCase(); + + let category; + let response; + switch (messageType) { + case EventType.IDENTIFY: + category = CONFIG_CATEGORIES.IDENTIFYV2; + response = identifyRequestHandler(message, category, destination); + break; + case EventType.SCREEN: + case EventType.TRACK: + category = CONFIG_CATEGORIES.TRACKV2; + response = trackOrScreenRequestHandler(message, category, destination); + break; + case EventType.GROUP: + category = CONFIG_CATEGORIES.GROUP; + response = groupRequestHandler(message, category, destination); + break; + default: + throw new InstrumentationError(`Event type ${messageType} is not supported`); + } + return response; +}; +// {subscription:{}, event:{}, profile:{}} +const processV2 = (event) => { + const response = processEvent(event); + const { destination } = event; + const respList = []; + if (response.profile) { + respList.push(buildRequest(response.profile, destination, CONFIG_CATEGORIES.IDENTIFYV2)); + } + if (response.subscription) { + respList.push(buildSubscriptionOrUnsubscriptionPayload(response.subscription, destination)); + } + if (response.event) { + respList.push(buildRequest(response.event, destination, CONFIG_CATEGORIES.TRACKV2)); + } + return respList; +}; + +// This function separates subscribe, proifle and event responses from process () and other responses in chunks +const getEventChunks = ( + input, + subscribeRespList, + profileRespList, + eventRespList, + unsubscriptionList, +) => { + if (input.payload.subscription) { + if (input.payload.subscription.operation === 'subscribe') { + subscribeRespList.push({ payload: input.payload.subscription, metadata: input.metadata }); + } else { + unsubscriptionList.push({ payload: input.payload.subscription, metadata: input.metadata }); + } + } + if (input.payload.profile) { + profileRespList.push({ payload: input.payload.profile, metadata: input.metadata }); + } + if (input.payload.event) { + eventRespList.push({ payload: input.payload.event, metadata: input.metadata }); + } +}; + +const processRouter = (inputs, reqMetadata) => { + const batchResponseList = []; + const batchErrorRespList = []; + const subscribeRespList = []; + const unsubscriptionList = []; + const profileRespList = []; + const eventRespList = []; + const { destination } = inputs[0]; + inputs.map((event) => { + try { + if (event.message.statusCode) { + // already transformed event + batchResponseList.push(fetchTransformedEvents(event)); + } else { + // if not transformed + getEventChunks( + { + payload: processEvent(event), + metadata: event.metadata, + }, + subscribeRespList, + profileRespList, + eventRespList, + unsubscriptionList, + ); + } + } catch (error) { + const errRespEvent = handleRtTfSingleEventError(event, error, reqMetadata); + batchErrorRespList.push(errRespEvent); + } + }); + const batchedResponseList = batchRequestV2( + subscribeRespList, + unsubscriptionList, + profileRespList, + destination, + ); + const trackRespList = getTrackRequests(eventRespList, destination); + + batchResponseList.push(...trackRespList, ...batchedResponseList); + + return { successEvents: batchResponseList, errorEvents: batchErrorRespList }; +}; + +module.exports = { processV2, processRouter }; diff --git a/src/v0/destinations/klaviyo/util.js b/src/v0/destinations/klaviyo/util.js index 3f6f6ca2ca..4421764d95 100644 --- a/src/v0/destinations/klaviyo/util.js +++ b/src/v0/destinations/klaviyo/util.js @@ -1,8 +1,7 @@ -const { defaultRequestConfig } = require('rudder-transformer-cdk/build/utils'); +const set = require('set-value'); const lodash = require('lodash'); const { NetworkError, InstrumentationError } = require('@rudderstack/integrations-lib'); const { WhiteListedTraits } = require('../../../constants'); - const { constructPayload, getFieldValueFromMessage, @@ -11,13 +10,25 @@ const { removeUndefinedAndNullValues, defaultBatchRequestConfig, getSuccessRespEvents, + flattenJson, defaultPatchRequestConfig, + isDefinedAndNotNull, + getDestinationExternalID, + getIntegrationsObj, + defaultRequestConfig, } = require('../../util'); const tags = require('../../util/tags'); const { handleHttpRequest } = require('../../../adapters/network'); const { JSON_MIME_TYPE, HTTP_STATUS_CODES } = require('../../util/constant'); const { getDynamicErrorType } = require('../../../adapters/utils/networkUtils'); -const { BASE_ENDPOINT, MAPPING_CONFIG, CONFIG_CATEGORIES, MAX_BATCH_SIZE } = require('./config'); +const { + BASE_ENDPOINT, + MAPPING_CONFIG, + CONFIG_CATEGORIES, + MAX_BATCH_SIZE, + WhiteListedTraitsV2, + revision, +} = require('./config'); const REVISION_CONSTANT = '2023-02-22'; @@ -42,12 +53,12 @@ const getIdFromNewOrExistingProfile = async ({ endpoint, payload, requestOptions payload, requestOptions, { + metadata, destType: 'klaviyo', feature: 'transformation', endpointPath, requestMethod: 'POST', module: 'router', - metadata, }, ); @@ -274,13 +285,11 @@ const getBatchedResponseList = (subscribeEventGroups, identifyResponseList) => { }); batchedResponseList = [...batchedResponseList, ...batchedResponse]; }); - if (identifyResponseList.length > 0) { identifyResponseList.forEach((response) => { batchedResponseList[0].batchedRequest.push(response); }); } - return batchedResponseList; }; @@ -305,6 +314,312 @@ const batchSubscribeEvents = (subscribeRespList) => { return batchedResponseList; }; +const buildRequest = (payload, destination, category) => { + const { privateApiKey } = destination.Config; + const response = defaultRequestConfig(); + response.endpoint = `${BASE_ENDPOINT}${category.apiUrl}`; + response.method = defaultPostRequestConfig.requestMethod; + response.headers = { + Authorization: `Klaviyo-API-Key ${privateApiKey}`, + Accept: JSON_MIME_TYPE, + 'Content-Type': JSON_MIME_TYPE, + revision, + }; + response.body.JSON = removeUndefinedAndNullValues(payload); + return response; +}; + +/** + * This function generates the metadat object used for updating a list attribute and unset properties + * message = { + integrations: { + Klaviyo: { fieldsToUnset: ['Unset1', 'Unset2'], + fieldsToAppend: ['appendList1', 'appendList2'], + fieldsToUnappend: ['unappendList1', 'unappendList2'] + }, + All: true, + }, + }; + Output metadata = { + "meta": { + "patch_properties": { + "append": { + "appendList1": "New Value 1", + "appendList2": "New Value 2" + }, + "unappend": { + "unappendList1": "Old Value 1", + "unappendList2": "Old Value 2" + }, + "unset": ['Unset1', 'Unset2'] + } + } + } + * @param {*} message + */ +const getProfileMetadataAndMetadataFields = (message) => { + const intgObj = getIntegrationsObj(message, 'Klaviyo'); + const meta = { patch_properties: {} }; + let metadataFields = []; + const traitsInfo = getFieldValueFromMessage(message, 'traits'); + // fetch and set fields to unset + const fieldsToUnset = intgObj?.fieldsToUnset; + if (Array.isArray(fieldsToUnset)) { + meta.patch_properties.unset = fieldsToUnset; + metadataFields = fieldsToUnset; + } + + // fetch list of fields to append , their value and append these fields in metadataFields + const fieldsToAppend = intgObj?.fieldsToAppend; + if (Array.isArray(fieldsToAppend)) { + const append = {}; + fieldsToAppend.forEach((key) => { + if (isDefinedAndNotNull(traitsInfo[key])) { + append[key] = traitsInfo[key]; + } + }); + meta.patch_properties.append = append; + metadataFields = metadataFields.concat(fieldsToAppend); + } + + // fetch list of fields to unappend , their value and append these fields in metadataFields + const fieldsToUnappend = intgObj?.fieldsToUnappend; + if (Array.isArray(fieldsToUnappend)) { + const unappend = {}; + fieldsToUnappend.forEach((key) => { + if (isDefinedAndNotNull(traitsInfo[key])) { + unappend[key] = traitsInfo[key]; + } + }); + meta.patch_properties.unappend = unappend; + metadataFields = metadataFields.concat(fieldsToUnappend); + } + + return { meta, metadataFields }; +}; + +/** + * Following function is used to construct profile object for version 15-06-2024 + * If we have isIdentifyCall as true then there are two extra scenarios + * 1. `enforceEmailAsPrimary` config kicks in and if email or phone is not present we throw an error + * 2. Place of Metadata object in payload for klaviyo is a little but different + * @param {*} message input to build output from + * @param {*} destination dest object with config + * @param {*} isIdentifyCall let us know if processing is done for identify call + * @returns profile object + * https://developers.klaviyo.com/en/reference/create_or_update_profile + */ +const constructProfile = (message, destination, isIdentifyCall) => { + const profileAttributes = constructPayload( + message, + MAPPING_CONFIG[CONFIG_CATEGORIES.PROFILEV2.name], + ); + const { enforceEmailAsPrimary, flattenProperties } = destination.Config; + let customPropertyPayload = {}; + const { meta, metadataFields } = getProfileMetadataAndMetadataFields(message); + customPropertyPayload = extractCustomFields( + message, + customPropertyPayload, + ['traits', 'context.traits'], + // omitting whitelistedTraitsV2 and metadatafields from constructing custom properties as these are already used + [...WhiteListedTraitsV2, ...metadataFields], + ); + const profileId = getDestinationExternalID(message, 'klaviyo-profileId'); + // if flattenProperties is enabled from UI, flatten the user properties + customPropertyPayload = flattenProperties + ? flattenJson(customPropertyPayload, '.', 'normal', false) + : customPropertyPayload; + if (enforceEmailAsPrimary) { + delete profileAttributes.external_id; // so that multiple profiles are not found, one w.r.t email and one for external_id + customPropertyPayload = { + ...customPropertyPayload, + _id: getFieldValueFromMessage(message, 'userIdOnly'), // custom attribute + }; + } + const data = removeUndefinedAndNullValues({ + type: 'profile', + id: profileId, + attributes: { + ...profileAttributes, + properties: removeUndefinedAndNullValues(customPropertyPayload), + meta, + }, + }); + if (isIdentifyCall) { + // For identify call meta object comes inside + data.meta = meta; + delete data.attributes.meta; + } + + return { data }; +}; + +/** This function update profile with consents for subscribing to email and/or phone + * @param {*} profileAttributes + * @param {*} subscribeConsent + * @param {*} email + * @param {*} phone + */ +const updateProfileWithConsents = (profileAttributes, subscribeConsent, email, phone) => { + let consent = subscribeConsent; + if (!Array.isArray(consent)) { + consent = [consent]; + } + if (consent.includes('email') && email) { + set(profileAttributes, 'subscriptions.email.marketing.consent', 'SUBSCRIBED'); + } + if (consent.includes('sms') && phone) { + set(profileAttributes, 'subscriptions.sms.marketing.consent', 'SUBSCRIBED'); + } +}; +/** + * This function is used for creating profile response for subscribing users to a particular list for V2 + * DOCS: https://developers.klaviyo.com/en/reference/subscribe_profiles + * Return an object with listId, profiles and operation + */ +const subscribeOrUnsubscribeUserToListV2 = (message, traitsInfo, destination, operation) => { + // listId from message properties are preferred over Config listId + const { consent } = destination.Config; + let { listId } = destination.Config; + const subscribeConsent = traitsInfo.consent || traitsInfo.properties?.consent || consent; + const email = getFieldValueFromMessage(message, 'email'); + const phone = getFieldValueFromMessage(message, 'phone'); + const profileAttributes = { + email, + phone_number: phone, + }; + + // used only for subscription and not for unsubscription + if (operation === 'subscribe' && subscribeConsent) { + updateProfileWithConsents(profileAttributes, subscribeConsent, email, phone); + } + + const profile = removeUndefinedAndNullValues({ + type: 'profile', + id: + operation === 'subscribe' + ? getDestinationExternalID(message, 'klaviyo-profileId') + : undefined, // id is not applicable for unsubscription + attributes: removeUndefinedAndNullValues(profileAttributes), + }); + if (!email && !phone && profile.id) { + if (operation === 'subscribe') { + throw new InstrumentationError( + 'Profile Id, Email or/and Phone are required to subscribe to a list', + ); + } else { + throw new InstrumentationError('Email or/and Phone are required to unsubscribe from a list'); + } + } + // fetch list id from message + if (traitsInfo?.properties?.listId) { + // for identify call + listId = traitsInfo.properties.listId; + } + if (message.type === 'group') { + listId = message.groupId; + } + return { listId, profile: [profile], operation }; +}; +/** + * This Create a subscription payload to subscribe profile(s) to list listId + * @param {*} listId + * @param {*} profiles + * @param {*} operation can be either subscribe or unsubscribe + */ +const getSubscriptionPayload = (listId, profiles, operation) => ({ + data: { + type: + operation === 'subscribe' + ? 'profile-subscription-bulk-create-job' + : 'profile-subscription-bulk-delete-job', + attributes: { profiles: { data: profiles } }, + relationships: { + list: { + data: { + type: 'list', + id: listId, + }, + }, + }, + }, +}); + +/** + * This function accepts subscriptions/ unsubscription object and builds a request for it + * @param {*} subscription + * @param {*} destination + * @param {*} operation can be either subscription or unsubscription + * @returns defaultRequestConfig + */ +const buildSubscriptionOrUnsubscriptionPayload = (subscription, destination) => { + const response = defaultRequestConfig(); + response.endpoint = `${BASE_ENDPOINT}${CONFIG_CATEGORIES[subscription.operation.toUpperCase()].apiUrl}`; + response.method = defaultPostRequestConfig.requestMethod; + response.headers = { + Authorization: `Klaviyo-API-Key ${destination.Config.privateApiKey}`, + Accept: JSON_MIME_TYPE, + 'Content-Type': JSON_MIME_TYPE, + revision, + }; + response.body.JSON = getSubscriptionPayload( + subscription.listId, + subscription.profile, + subscription.operation, + ); + return response; +}; + +const getTrackRequests = (eventRespList, destination) => { + // building and pushing all the event requests + const respList = []; + eventRespList.forEach((resp) => + respList.push( + getSuccessRespEvents( + buildRequest(resp.payload, destination, CONFIG_CATEGORIES.TRACKV2), + [resp.metadata], + destination, + ), + ), + ); + return respList; +}; + +/** + * This function checks for the transformed event structure and accordingly send back the batched responses + * @param {*} event + */ +const fetchTransformedEvents = (event) => { + const { message, destination, metadata } = event; + // checking if we have any output field if yes then we return message.output + return getSuccessRespEvents( + message.output || message, + Array.isArray(metadata) ? metadata : [metadata], + destination, + ); +}; + +const addSubscribeFlagToTraits = (traitsInfo) => { + let traits = traitsInfo; + if (!isDefinedAndNotNull(traits)) { + return traits; + } + // check if properties already contains subscribe flag + + if (traits.properties) { + if (traits.properties.subscribe === undefined) { + traits.properties.subscribe = true; + } else { + // return if subscribe flag is already present + return traits; + } + } else { + traits = { + properties: { subscribe: true }, + }; + } + return traits; +}; module.exports = { subscribeUserToList, @@ -314,4 +629,13 @@ module.exports = { batchSubscribeEvents, profileUpdateResponseBuilder, getIdFromNewOrExistingProfile, + constructProfile, + subscribeOrUnsubscribeUserToListV2, + getProfileMetadataAndMetadataFields, + buildRequest, + buildSubscriptionOrUnsubscriptionPayload, + getTrackRequests, + fetchTransformedEvents, + addSubscribeFlagToTraits, + getSubscriptionPayload, }; diff --git a/src/v0/destinations/mailchimp/transform.js b/src/v0/destinations/mailchimp/transform.js index 87f547c124..1f708b4f64 100644 --- a/src/v0/destinations/mailchimp/transform.js +++ b/src/v0/destinations/mailchimp/transform.js @@ -78,7 +78,7 @@ const trackResponseBuilder = (message, { Config }) => { return responseBuilderSimple(processedPayload, endpoint, Config, audienceId); }; -const identifyResponseBuilder = async (message, { Config }) => { +const identifyResponseBuilder = async (message, { Config }, metadata) => { const { datacenterId } = Config; const email = getFieldValueFromMessage(message, 'email'); if (!email) { @@ -86,13 +86,13 @@ const identifyResponseBuilder = async (message, { Config }) => { } const audienceId = getAudienceId(message, Config); const endpoint = mailChimpSubscriptionEndpoint(datacenterId, audienceId, email); - const processedPayload = await processPayload(message, Config, audienceId); + const processedPayload = await processPayload(message, Config, audienceId, metadata); return responseBuilderSimple(processedPayload, endpoint, Config, audienceId); }; const process = async (event) => { let response; - const { message, destination } = event; + const { message, destination, metadata } = event; const messageType = message.type.toLowerCase(); const destConfig = destination.Config; @@ -114,7 +114,7 @@ const process = async (event) => { switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder(message, destination, metadata); break; case EventType.TRACK: response = trackResponseBuilder(message, destination); diff --git a/src/v0/destinations/mailchimp/utils.js b/src/v0/destinations/mailchimp/utils.js index f678742f2d..58f6a29445 100644 --- a/src/v0/destinations/mailchimp/utils.js +++ b/src/v0/destinations/mailchimp/utils.js @@ -1,7 +1,6 @@ const get = require('get-value'); const md5 = require('md5'); const { InstrumentationError, NetworkError } = require('@rudderstack/integrations-lib'); -const myAxios = require('../../../util/myAxios'); const { MappedToDestinationKey } = require('../../../constants'); const { isDefinedAndNotNull, @@ -20,6 +19,7 @@ const { MERGE_CONFIG, MERGE_ADDRESS, SUBSCRIPTION_STATUS, VALID_STATUSES } = req const { getDynamicErrorType } = require('../../../adapters/utils/networkUtils'); const tags = require('../../util/tags'); const { JSON_MIME_TYPE } = require('../../util/constant'); +const { handleHttpRequest } = require('../../../adapters/network'); const ADDRESS_MANDATORY_FIELDS = ['addr1', 'city', 'state', 'zip']; @@ -145,7 +145,7 @@ const filterTagValue = (tag) => { * @param {*} email * @returns */ -const checkIfMailExists = async (apiKey, datacenterId, audienceId, email) => { +const checkIfMailExists = async (apiKey, datacenterId, audienceId, email, metadata) => { if (!email) { return false; } @@ -155,28 +155,31 @@ const checkIfMailExists = async (apiKey, datacenterId, audienceId, email) => { }; const url = `${mailChimpSubscriptionEndpoint(datacenterId, audienceId, email)}`; const basicAuth = Buffer.from(`apiKey:${apiKey}`).toString('base64'); - try { - const response = await myAxios.get( - url, - { - headers: { - Authorization: `Basic ${basicAuth}`, - }, - }, - { - destType: 'mailchimp', - feature: 'transformation', - endpointPath: '/lists/audienceId/members/email', - requestMethod: 'GET', - module: 'router', + + const { processedResponse, httpResponse } = await handleHttpRequest( + 'get', + url, + { + headers: { + Authorization: `Basic ${basicAuth}`, }, - ); - if (response?.data?.contact_id) { - userStatus.exists = true; - userStatus.subscriptionStatus = response.data.status; - } - } catch (error) { - logger.info(`[Mailchimp] :: Email does not exists, Error: ${error.message}`); + }, + { + metadata, + destType: 'mailchimp', + feature: 'transformation', + endpointPath: '/lists/audienceId/members/email', + requestMethod: 'GET', + module: 'router', + }, + ); + if (!httpResponse.success) { + logger.info(`[Mailchimp] :: Email does not exists, Error: ${httpResponse.response?.message}`); + return userStatus; + } + if (processedResponse.response.contact_id) { + userStatus.exists = true; + userStatus.subscriptionStatus = processedResponse.response.status; } return userStatus; }; @@ -188,33 +191,35 @@ const checkIfMailExists = async (apiKey, datacenterId, audienceId, email) => { * @param {*} audienceId * @returns */ -const checkIfDoubleOptIn = async (apiKey, datacenterId, audienceId) => { - let response; +const checkIfDoubleOptIn = async (apiKey, datacenterId, audienceId, metadata) => { const url = `${getMailChimpBaseEndpoint(datacenterId, audienceId)}`; const basicAuth = Buffer.from(`apiKey:${apiKey}`).toString('base64'); - try { - response = await myAxios.get( - url, - { - headers: { - Authorization: `Basic ${basicAuth}`, - }, - }, - { - destType: 'mailchimp', - feature: 'transformation', - endpointPath: '/lists/audienceId', - requestMethod: 'GET', - module: 'router', + const { httpResponse, processedResponse } = await handleHttpRequest( + 'get', + url, + { + headers: { + Authorization: `Basic ${basicAuth}`, }, - ); - } catch (error) { + }, + { + metadata, + destType: 'mailchimp', + feature: 'transformation', + endpointPath: '/lists/audienceId', + requestMethod: 'GET', + module: 'router', + }, + ); + if (!httpResponse.success) { + const error = httpResponse.response?.response; const status = error.status || 400; throw new NetworkError('User does not have access to the requested operation', status, { [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), }); } - return !!response.data.double_optin; + + return !!processedResponse.response?.double_optin; }; /** @@ -313,7 +318,7 @@ const overrideSubscriptionStatus = (message, primaryPayload, userStatus) => { * @param {*} audienceId * @returns */ -const processPayload = async (message, Config, audienceId) => { +const processPayload = async (message, Config, audienceId, metadata) => { let primaryPayload; let email; const { apiKey, datacenterId, enableMergeFields } = Config; @@ -351,10 +356,10 @@ const processPayload = async (message, Config, audienceId) => { merge_fields: mergeAdditionalTraitsFields(traits, mergedFieldPayload), }; } - const userStatus = await checkIfMailExists(apiKey, datacenterId, audienceId, email); + const userStatus = await checkIfMailExists(apiKey, datacenterId, audienceId, email, metadata); if (!userStatus.exists) { - const isDoubleOptin = await checkIfDoubleOptIn(apiKey, datacenterId, audienceId); + const isDoubleOptin = await checkIfDoubleOptIn(apiKey, datacenterId, audienceId, metadata); primaryPayload.status = isDoubleOptin ? SUBSCRIPTION_STATUS.pending : SUBSCRIPTION_STATUS.subscribed; diff --git a/src/v0/destinations/marketo/transform.js b/src/v0/destinations/marketo/transform.js index b811596f95..accca1d449 100644 --- a/src/v0/destinations/marketo/transform.js +++ b/src/v0/destinations/marketo/transform.js @@ -55,7 +55,7 @@ const authCache = new Cache(AUTH_CACHE_TTL); // 1 hr // fails the transformer if auth fails // ------------------------ // Ref: https://developers.marketo.com/rest-api/authentication/#creating_an_access_token -const getAuthToken = async (formattedDestination) => +const getAuthToken = async (formattedDestination, metadata) => authCache.get(formattedDestination.ID, async () => { const { accountId, clientId, clientSecret } = formattedDestination; const clientResponse = await sendGetRequest( @@ -67,6 +67,7 @@ const getAuthToken = async (formattedDestination) => grant_type: 'client_credentials', }, }, + metadata, ); const data = marketoResponseHandler(clientResponse, 'During fetching auth token'); if (data) { @@ -92,7 +93,7 @@ const getAuthToken = async (formattedDestination) => // If lookupField is omitted, the default key is email. // ------------------------ // Thus we'll always be using createOrUpdate -const createOrUpdateLead = async (formattedDestination, token, userId, anonymousId) => +const createOrUpdateLead = async (formattedDestination, token, userId, anonymousId, metadata) => userIdLeadCache.get(userId || anonymousId, async () => { const attribute = userId ? { userId } : { anonymousId }; stats.increment(LEAD_LOOKUP_METRIC, { @@ -114,6 +115,7 @@ const createOrUpdateLead = async (formattedDestination, token, userId, anonymous 'Content-type': JSON_MIME_TYPE, }, }, + metadata, ); const data = getResponseHandlerData( clientResponse, @@ -135,7 +137,7 @@ const createOrUpdateLead = async (formattedDestination, token, userId, anonymous // ------------------------ // Ref: https://developers.marketo.com/rest-api/lead-database/leads/#create_and_update // ------------------------ -const lookupLeadUsingEmail = async (formattedDestination, token, email) => +const lookupLeadUsingEmail = async (formattedDestination, token, email, metadata) => emailLeadCache.get(email, async () => { stats.increment(LEAD_LOOKUP_METRIC, { type: 'email', action: 'fetch' }); const clientResponse = await sendGetRequest( @@ -145,6 +147,7 @@ const lookupLeadUsingEmail = async (formattedDestination, token, email) => params: { filterValues: email, filterType: 'email' }, headers: { Authorization: `Bearer ${token}` }, }, + metadata, ); const data = getResponseHandlerData( clientResponse, @@ -167,7 +170,7 @@ const lookupLeadUsingEmail = async (formattedDestination, token, email) => // ------------------------ // Ref: https://developers.marketo.com/rest-api/lead-database/leads/#create_and_update // ------------------------ -const lookupLeadUsingId = async (formattedDestination, token, userId, anonymousId) => +const lookupLeadUsingId = async (formattedDestination, token, userId, anonymousId, metadata) => userIdLeadCache.get(userId || anonymousId, async () => { stats.increment(LEAD_LOOKUP_METRIC, { type: 'userId', action: 'fetch' }); const clientResponse = await sendGetRequest( @@ -179,6 +182,7 @@ const lookupLeadUsingId = async (formattedDestination, token, userId, anonymousI }, headers: { Authorization: `Bearer ${token}` }, }, + metadata, ); const data = getResponseHandlerData( clientResponse, @@ -195,7 +199,7 @@ const lookupLeadUsingId = async (formattedDestination, token, userId, anonymousI return null; }); -const getLeadId = async (message, formattedDestination, token) => { +const getLeadId = async (message, formattedDestination, token, metadata) => { // precedence ->> // -> externalId (context.externalId[0].type == marketoLeadId) // -> lookup lead using email @@ -225,10 +229,16 @@ const getLeadId = async (message, formattedDestination, token) => { if (!leadId) { // search for lead using email if (email) { - leadId = await lookupLeadUsingEmail(formattedDestination, token, email); + leadId = await lookupLeadUsingEmail(formattedDestination, token, email, metadata); } else { // search lead using userId or anonymousId - leadId = await lookupLeadUsingId(formattedDestination, token, userId, message.anonymousId); + leadId = await lookupLeadUsingId( + formattedDestination, + token, + userId, + message.anonymousId, + metadata, + ); } } @@ -236,7 +246,13 @@ const getLeadId = async (message, formattedDestination, token) => { if (!leadId) { // check we have permission to create lead on marketo if (formattedDestination.createIfNotExist) { - leadId = await createOrUpdateLead(formattedDestination, token, userId, message.anonymousId); + leadId = await createOrUpdateLead( + formattedDestination, + token, + userId, + message.anonymousId, + metadata, + ); } else { throw new ConfigurationError('Lead creation is turned off on the dashboard'); } @@ -264,7 +280,7 @@ const getLeadId = async (message, formattedDestination, token) => { // ------------------------ // Almost same as leadId lookup. Noticable difference from lookup is we'll using // `id` i.e. leadId as lookupField at the end of it -const processIdentify = async (message, formattedDestination, token) => { +const processIdentify = async (message, formattedDestination, token, metadata) => { // If mapped to destination, Add externalId to traits if (get(message, MappedToDestinationKey)) { addExternalIdToTraits(message); @@ -277,7 +293,7 @@ const processIdentify = async (message, formattedDestination, token) => { throw new InstrumentationError('Invalid traits value for Marketo'); } - const leadId = await getLeadId(message, formattedDestination, token); + const leadId = await getLeadId(message, formattedDestination, token, metadata); let attribute = constructPayload(traits, identifyConfig); // leadTraitMapping will not be used if mapping is done through VDM in rETL @@ -338,7 +354,7 @@ const processIdentify = async (message, formattedDestination, token) => { // process track events - only mapped events // ------------------------ // Ref: https://developers.marketo.com/rest-api/endpoint-reference/lead-database-endpoint-reference/#!/Activities/addCustomActivityUsingPOST -const processTrack = async (message, formattedDestination, token) => { +const processTrack = async (message, formattedDestination, token, metadata) => { // check if trackAnonymousEvent is turned off and userId is not present - fail // check if the event is mapped in customActivityEventMap. if not - fail // get primaryKey name for the event @@ -373,7 +389,7 @@ const processTrack = async (message, formattedDestination, token) => { } // get leadId - const leadId = await getLeadId(message, formattedDestination, token); + const leadId = await getLeadId(message, formattedDestination, token, metadata); // handle addition of custom activity attributes // Reference: https://developers.marketo.com/rest-api/lead-database/activities/#add_custom_activities @@ -420,7 +436,7 @@ const responseWrapper = (response) => { return resp; }; -const processEvent = async (message, destination, token) => { +const processEvent = async ({ message, destination, metadata }, token) => { if (!message.type) { throw new InstrumentationError('Message Type is not present. Aborting message.'); } @@ -430,10 +446,10 @@ const processEvent = async (message, destination, token) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await processIdentify(message, formattedDestination, token); + response = await processIdentify(message, formattedDestination, token, metadata); break; case EventType.TRACK: - response = await processTrack(message, formattedDestination, token); + response = await processTrack(message, formattedDestination, token, metadata); break; default: throw new InstrumentationError('Message type not supported'); @@ -444,11 +460,11 @@ const processEvent = async (message, destination, token) => { }; const process = async (event) => { - const token = await getAuthToken(formatConfig(event.destination)); + const token = await getAuthToken(formatConfig(event.destination), event.metadata); if (!token) { throw new UnauthorizedError('Authorization failed'); } - const response = await processEvent(event.message, event.destination, token); + const response = await processEvent(event, token); return response; }; @@ -457,7 +473,7 @@ const processRouterDest = async (inputs, reqMetadata) => { // If destination information is not present Error should be thrown let token; try { - token = await getAuthToken(formatConfig(inputs[0].destination)); + token = await getAuthToken(formatConfig(inputs[0].destination), inputs[0].metadata); // If token is null track/identify calls cannot be executed. if (!token) { @@ -483,7 +499,7 @@ const processRouterDest = async (inputs, reqMetadata) => { inputs.map(async (input) => { try { return getSuccessRespEvents( - await processEvent(input.message, input.destination, token), + await processEvent(input, token), [input.metadata], input.destination, ); diff --git a/src/v0/destinations/marketo/util.js b/src/v0/destinations/marketo/util.js index b3a24fb411..aee872efac 100644 --- a/src/v0/destinations/marketo/util.js +++ b/src/v0/destinations/marketo/util.js @@ -243,13 +243,14 @@ const marketoResponseHandler = ( * @param {*} options * @returns { response, status } */ -const sendGetRequest = async (url, options) => { +const sendGetRequest = async (url, options, metadata) => { const clientResponse = await httpGET(url, options, { destType: 'marketo', feature: 'transformation', endpointPath: `/v1/leads`, requestMethod: 'GET', module: 'router', + metadata, }); const processedResponse = processAxiosResponse(clientResponse); return processedResponse; @@ -261,13 +262,14 @@ const sendGetRequest = async (url, options) => { * @param {*} options * @returns { response, status } */ -const sendPostRequest = async (url, data, options) => { +const sendPostRequest = async (url, data, options, metadata) => { const clientResponse = await httpPOST(url, data, options, { destType: 'marketo', feature: 'transformation', endpointPath: `/v1/leads`, requestMethod: 'POST', module: 'router', + metadata, }); const processedResponse = processAxiosResponse(clientResponse); return processedResponse; diff --git a/src/v0/destinations/marketo_static_list/transform.js b/src/v0/destinations/marketo_static_list/transform.js index 92c137c614..810b528bbf 100644 --- a/src/v0/destinations/marketo_static_list/transform.js +++ b/src/v0/destinations/marketo_static_list/transform.js @@ -93,7 +93,7 @@ const processEvent = (event) => { // eslint-disable-next-line @typescript-eslint/no-unused-vars const process = async (event, _processParams) => { - const token = await getAuthToken(formatConfig(event.destination)); + const token = await getAuthToken(formatConfig(event.destination), event.metadata); if (!token) { throw new UnauthorizedError('Authorization failed'); } @@ -106,9 +106,9 @@ const processRouterDest = async (inputs, reqMetadata) => { // Token needs to be generated for marketo which will be done on input level. // If destination information is not present Error should be thrown - const { destination } = inputs[0]; + const { destination, metadata } = inputs[0]; try { - const token = await getAuthToken(formatConfig(destination)); + const token = await getAuthToken(formatConfig(destination), metadata); if (!token) { throw new UnauthorizedError('Could not retrieve authorisation token'); } diff --git a/src/v0/destinations/mautic/transform.js b/src/v0/destinations/mautic/transform.js index 13808f6e3c..56cfceb371 100644 --- a/src/v0/destinations/mautic/transform.js +++ b/src/v0/destinations/mautic/transform.js @@ -56,7 +56,7 @@ const responseBuilder = async (payload, endpoint, method, messageType, Config) = * @param {*} endPoint * @returns build response for group call */ -const groupResponseBuilder = async (message, Config, endPoint) => { +const groupResponseBuilder = async ({ message, Config, metadata }, endPoint) => { let groupClass; validateGroupCall(message); switch (message.traits?.type?.toLowerCase()) { @@ -76,7 +76,7 @@ const groupResponseBuilder = async (message, Config, endPoint) => { } let contactId = getDestinationExternalID(message, 'mauticContactId'); if (!contactId) { - const contacts = await searchContactIds(message, Config, endPoint); + const contacts = await searchContactIds({ message, Config, metadata }, endPoint); if (!contacts || contacts.length === 0) { throw new ConfigurationError('Could not find any contact ID on lookup'); } @@ -117,7 +117,7 @@ const groupResponseBuilder = async (message, Config, endPoint) => { * @param {*} endPoint * @returns build response for identify call */ -const identifyResponseBuilder = async (message, Config, endpoint) => { +const identifyResponseBuilder = async ({ message, Config, metadata }, endpoint) => { let method; let endPoint; // constructing payload from mapping JSONs @@ -135,7 +135,7 @@ const identifyResponseBuilder = async (message, Config, endpoint) => { let contactId = getDestinationExternalID(message, 'mauticContactId'); if (!contactId) { - const contacts = await searchContactIds(message, Config, endpoint); + const contacts = await searchContactIds({ message, Config, metadata }, endpoint); if (contacts?.length === 1) { const [first] = contacts; contactId = first; @@ -154,7 +154,7 @@ const identifyResponseBuilder = async (message, Config, endpoint) => { }; const process = async (event) => { - const { message, destination } = event; + const { message, destination, metadata } = event; const { password, userName } = destination.Config; if (!password) { throw new ConfigurationError( @@ -178,10 +178,16 @@ const process = async (event) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination.Config, endpoint); + response = await identifyResponseBuilder( + { message, Config: destination.Config, metadata }, + endpoint, + ); break; case EventType.GROUP: - response = await groupResponseBuilder(message, destination.Config, endpoint); + response = await groupResponseBuilder( + { message, Config: destination.Config, metadata }, + endpoint, + ); break; default: throw new InstrumentationError(`Event type "${messageType}" is not supported`); diff --git a/src/v0/destinations/mautic/utils.js b/src/v0/destinations/mautic/utils.js index 7a1827e769..fc9654d2e3 100644 --- a/src/v0/destinations/mautic/utils.js +++ b/src/v0/destinations/mautic/utils.js @@ -154,7 +154,7 @@ const validateGroupCall = (message) => { * It checks for lookUpfield Validation and make axios call ,if Valid, and returns the contactIDs received. * It Gets the contact Id using Lookup field and then email, otherwise returns null */ -const searchContactIds = async (message, Config, baseUrl) => { +const searchContactIds = async ({ message, Config, metadata }, baseUrl) => { const { lookUpField, userName, password } = Config; const traits = getFieldValueFromMessage(message, 'traits'); @@ -186,6 +186,7 @@ const searchContactIds = async (message, Config, baseUrl) => { endpointPath: '/contacts', requestMethod: 'GET', module: 'router', + metadata, }, ); searchContactsResponse = processAxiosResponse(searchContactsResponse); diff --git a/src/v0/destinations/monday/transform.js b/src/v0/destinations/monday/transform.js index 152b42f8d0..de34fa0521 100644 --- a/src/v0/destinations/monday/transform.js +++ b/src/v0/destinations/monday/transform.js @@ -38,7 +38,7 @@ const responseBuilder = (payload, endpoint, apiToken) => { * @param {*} param1 * @returns */ -const trackResponseBuilder = async (message, { Config }) => { +const trackResponseBuilder = async ({ message, destination: { Config }, metadata }) => { const { apiToken } = Config; let boardId = getDestinationExternalID(message, 'boardId'); const event = get(message, 'event'); @@ -54,14 +54,14 @@ const trackResponseBuilder = async (message, { Config }) => { } const endpoint = ENDPOINT; - const processedResponse = await getBoardDetails(endpoint, boardId, apiToken); + const processedResponse = await getBoardDetails(endpoint, boardId, apiToken, metadata); const payload = populatePayload(message, Config, processedResponse); return responseBuilder(payload, endpoint, apiToken); }; -const processEvent = async (message, destination) => { +const processEvent = async ({ message, destination, metadata }) => { if (!message.type) { throw new InstrumentationError('Event type is required'); } @@ -71,14 +71,14 @@ const processEvent = async (message, destination) => { const messageType = message.type.toLowerCase(); let response; if (messageType === EventType.TRACK) { - response = await trackResponseBuilder(message, destination); + response = await trackResponseBuilder({ message, destination, metadata }); } else { throw new InstrumentationError(`Event type ${messageType} is not supported`); } return response; }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/monday/util.js b/src/v0/destinations/monday/util.js index 0694028eb2..07e084c158 100644 --- a/src/v0/destinations/monday/util.js +++ b/src/v0/destinations/monday/util.js @@ -179,7 +179,7 @@ const mapColumnValues = (properties, columnToPropertyMapping, board) => { * @param {*} apiToken * @returns */ -const getBoardDetails = async (url, boardID, apiToken) => { +const getBoardDetails = async (url, boardID, apiToken, metadata) => { const clientResponse = await httpPOST( url, { @@ -197,6 +197,7 @@ const getBoardDetails = async (url, boardID, apiToken) => { endpointPath: '/v2', requestMethod: 'POST', module: 'router', + metadata, }, ); const boardDetailsResponse = processAxiosResponse(clientResponse); diff --git a/src/v0/destinations/pardot/networkHandler.js b/src/v0/destinations/pardot/networkHandler.js index 60d2f7ee23..6344301d39 100644 --- a/src/v0/destinations/pardot/networkHandler.js +++ b/src/v0/destinations/pardot/networkHandler.js @@ -118,6 +118,7 @@ const prepareProxyReq = (request) => { * @returns */ const pardotProxyRequest = async (request) => { + const { metadata } = request; const { endpoint, data, method, params, headers } = prepareProxyReq(request); const requestOptions = { @@ -130,6 +131,7 @@ const pardotProxyRequest = async (request) => { const response = await httpSend(requestOptions, { feature: 'proxy', destType: 'pardot', + metadata, }); return response; }; diff --git a/src/v0/destinations/personalize/scripts/personalize_cleanup.sh b/src/v0/destinations/personalize/scripts/personalize_cleanup.sh new file mode 100644 index 0000000000..5bf6426fa6 --- /dev/null +++ b/src/v0/destinations/personalize/scripts/personalize_cleanup.sh @@ -0,0 +1,67 @@ +#!/bin/bash + +# Set the AWS region +AWS_REGION="us-east-1" + +# Function to wait for dataset deletion +wait_for_deletion() { + local resource_arn=$1 + local resource_type=$2 + local status="" + + echo "Waiting for $resource_type $resource_arn to be deleted..." + + while true; do + if [ "$resource_type" == "dataset" ]; then + status=$(aws personalize describe-dataset --dataset-arn $resource_arn --region $AWS_REGION --query "dataset.status" --output text 2>/dev/null) + fi + + if [ -z "$status" ]; then + echo "$resource_type $resource_arn has been deleted." + break + else + echo "$resource_type $resource_arn status: $status. Waiting..." + sleep 10 + fi + done +} + +# Delete dataset groups +for dataset_group_arn in $(aws personalize list-dataset-groups --region $AWS_REGION --query "datasetGroups[*].datasetGroupArn" --output text); do + + echo "Processing dataset group: $dataset_group_arn" + + # List and delete all event trackers in the dataset group + for event_tracker_arn in $(aws personalize list-event-trackers --dataset-group-arn $dataset_group_arn --region $AWS_REGION --query "eventTrackers[*].eventTrackerArn" --output text); do + echo "Deleting event tracker $event_tracker_arn" + aws personalize delete-event-tracker --event-tracker-arn $event_tracker_arn --region $AWS_REGION + done + + # List and delete all solutions in the dataset group + for solution_arn in $(aws personalize list-solutions --dataset-group-arn $dataset_group_arn --region $AWS_REGION --query "solutions[*].solutionArn" --output text); do + + # List and delete all campaigns for the solution + for campaign_arn in $(aws personalize list-campaigns --solution-arn $solution_arn --region $AWS_REGION --query "campaigns[*].campaignArn" --output text); do + echo "Deleting campaign $campaign_arn" + aws personalize delete-campaign --campaign-arn $campaign_arn --region $AWS_REGION + done + + echo "Deleting solution $solution_arn" + aws personalize delete-solution --solution-arn $solution_arn --region $AWS_REGION + done + + # List and delete all datasets in the dataset group + for dataset_arn in $(aws personalize list-datasets --dataset-group-arn $dataset_group_arn --region $AWS_REGION --query "datasets[*].datasetArn" --output text); do + echo "Deleting dataset $dataset_arn" + aws personalize delete-dataset --dataset-arn $dataset_arn --region $AWS_REGION + wait_for_deletion $dataset_arn "dataset" + done + + # Finally, delete the dataset group + echo "Deleting dataset group $dataset_group_arn" + aws personalize delete-dataset-group --dataset-group-arn $dataset_group_arn --region $AWS_REGION + wait_for_deletion $dataset_group_arn "dataset_group" +done + +echo "All datasets, event trackers, solutions, campaigns, and dataset groups have been deleted." + diff --git a/src/v0/destinations/profitwell/transform.js b/src/v0/destinations/profitwell/transform.js index 58449fd9c1..e88718771e 100644 --- a/src/v0/destinations/profitwell/transform.js +++ b/src/v0/destinations/profitwell/transform.js @@ -24,18 +24,19 @@ const { getDynamicErrorType } = require('../../../adapters/utils/networkUtils'); const tags = require('../../util/tags'); const { JSON_MIME_TYPE } = require('../../util/constant'); -const identifyResponseBuilder = async (message, { Config }) => { +const identifyResponseBuilder = async ({ message, destination: { Config }, metadata }) => { const { userId, userAlias, subscriptionId, subscriptionAlias } = validatePayloadAndRetunImpIds(message); let finalSubscriptionId = subscriptionId; let finalSubscriptionAlias = subscriptionAlias; - - const targetUrl = `${BASE_ENDPOINT}/v2/users/${userId || userAlias}/`; - const res = await getSubscriptionHistory(targetUrl, { + const options = { headers: { Authorization: Config.privateApiKey, }, - }); + }; + + const targetUrl = `${BASE_ENDPOINT}/v2/users/${userId || userAlias}/`; + const res = await getSubscriptionHistory(targetUrl, options, metadata); let payload; const response = defaultRequestConfig(); @@ -159,7 +160,7 @@ const process = async (event) => { let response; if (messageType === EventType.IDENTIFY) { - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder(event); } else { throw new InstrumentationError(`Event type ${messageType} is not supported`); } diff --git a/src/v0/destinations/profitwell/utils.js b/src/v0/destinations/profitwell/utils.js index 1b23561721..cdc4f8a47d 100644 --- a/src/v0/destinations/profitwell/utils.js +++ b/src/v0/destinations/profitwell/utils.js @@ -179,7 +179,7 @@ const CURRENCY_CODES = [ 'zwl', ]; -const getSubscriptionHistory = async (endpoint, options) => { +const getSubscriptionHistory = async (endpoint, options, metadata) => { const requestOptions = { method: 'get', ...options, @@ -191,6 +191,7 @@ const getSubscriptionHistory = async (endpoint, options) => { endpointPath: '/users/userId', requestMethod: 'GET', module: 'router', + metadata, }); return res; }; diff --git a/src/v0/destinations/rakuten/networkHandler.js b/src/v0/destinations/rakuten/networkHandler.js index 4c97a23e51..95189cab62 100644 --- a/src/v0/destinations/rakuten/networkHandler.js +++ b/src/v0/destinations/rakuten/networkHandler.js @@ -10,6 +10,7 @@ const { HTTP_STATUS_CODES } = require('../../util/constant'); const DESTINATION = 'RAKUTEN'; const prepareProxyRequest = (request) => request; const proxyRequest = async (request, destType) => { + const { metadata } = request; const { endpoint, data, method, params, headers } = prepareProxyRequest(request); const requestOptions = { url: endpoint, @@ -21,6 +22,7 @@ const proxyRequest = async (request, destType) => { const response = await httpSend(requestOptions, { feature: 'proxy', destType, + metadata, endpointPath: '/ep', requestMethod: 'GET', module: 'dataDelivery', diff --git a/src/v0/destinations/reddit/networkHandler.js b/src/v0/destinations/reddit/networkHandler.js index 55087b52ac..e691255a26 100644 --- a/src/v0/destinations/reddit/networkHandler.js +++ b/src/v0/destinations/reddit/networkHandler.js @@ -1,4 +1,5 @@ const { RetryableError } = require('@rudderstack/integrations-lib'); +const isString = require('lodash/isString'); const { prepareProxyRequest, proxyRequest } = require('../../../adapters/network'); const { isHttpStatusSuccess } = require('../../util/index'); const { REFRESH_TOKEN } = require('../../../adapters/networkhandler/authConstants'); @@ -9,12 +10,23 @@ const redditRespHandler = (destResponse) => { const { status, response } = destResponse; // to handle the case when authorization-token is invalid - if (status === 401 && response.includes('Authorization Required')) { + if (status === 401) { + let errorMessage = 'Authorization failed'; + let authErrorCategory = ''; + + if (isString(response) && response.includes('Authorization Required')) { + errorMessage = `Request failed due to ${response}`; + authErrorCategory = REFRESH_TOKEN; + } else if (response?.error?.reason === 'UNAUTHORIZED') { + errorMessage = response.error.explanation || errorMessage; + authErrorCategory = REFRESH_TOKEN; + } + throw new RetryableError( - `Request failed due to ${response} 'during reddit response transformation'`, - 500, + `${errorMessage} during reddit response transformation`, + status, destResponse, - REFRESH_TOKEN, + authErrorCategory, ); } }; diff --git a/src/v0/destinations/revenue_cat/transform.js b/src/v0/destinations/revenue_cat/transform.js index 407cb91608..1fc054e578 100644 --- a/src/v0/destinations/revenue_cat/transform.js +++ b/src/v0/destinations/revenue_cat/transform.js @@ -1,5 +1,4 @@ const set = require('set-value'); -const { defaultRequestConfig } = require('rudder-transformer-cdk/build/utils'); const { ConfigurationError, TransformationError, @@ -13,6 +12,7 @@ const { extractCustomFields, defaultGetRequestConfig, getFieldValueFromMessage, + defaultRequestConfig, } = require('../../util'); const { CONFIG_CATEGORIES, diff --git a/src/v0/destinations/salesforce/transform.js b/src/v0/destinations/salesforce/transform.js index b8f032c5bf..9b7123c207 100644 --- a/src/v0/destinations/salesforce/transform.js +++ b/src/v0/destinations/salesforce/transform.js @@ -106,7 +106,7 @@ async function getSaleforceIdForRecord( objectType, identifierType, identifierValue, - destination, + { destination, metadata }, authorizationFlow, ) { const objSearchUrl = `${authorizationData.instanceUrl}/services/data/v${SF_API_VERSION}/parameterizedSearch/?q=${identifierValue}&sobject=${objectType}&in=${identifierType}&${objectType}.fields=id,${identifierType}`; @@ -117,6 +117,7 @@ async function getSaleforceIdForRecord( headers: getAuthHeader({ authorizationFlow, authorizationData }), }, { + metadata, destType: 'salesforce', feature: 'transformation', endpointPath: '/parameterizedSearch', @@ -156,9 +157,8 @@ async function getSaleforceIdForRecord( // // Default Object type will be "Lead" for backward compatibility async function getSalesforceIdFromPayload( - message, + { message, destination, metadata }, authorizationData, - destination, authorizationFlow, ) { // define default map @@ -201,7 +201,7 @@ async function getSalesforceIdFromPayload( objectType, identifierType, id, - destination, + { destination, metadata }, authorizationFlow, ); } @@ -233,6 +233,7 @@ async function getSalesforceIdFromPayload( headers: getAuthHeader({ authorizationFlow, authorizationData }), }, { + metadata, destType: 'salesforce', feature: 'transformation', endpointPath: '/parameterizedSearch', @@ -283,7 +284,11 @@ async function getSalesforceIdFromPayload( } // Function for handling identify events -async function processIdentify(message, authorizationData, destination, authorizationFlow) { +async function processIdentify( + { message, destination, metadata }, + authorizationData, + authorizationFlow, +) { const mapProperty = destination.Config.mapProperty === undefined ? true : destination.Config.mapProperty; // check the traits before hand @@ -305,9 +310,8 @@ async function processIdentify(message, authorizationData, destination, authoriz // get salesforce object map const salesforceMaps = await getSalesforceIdFromPayload( - message, + { message, destination, metadata }, authorizationData, - destination, authorizationFlow, ); @@ -331,10 +335,18 @@ async function processIdentify(message, authorizationData, destination, authoriz // Generic process function which invokes specific handler functions depending on message type // and event type where applicable -async function processSingleMessage(message, authorizationData, destination, authorizationFlow) { +async function processSingleMessage( + { message, destination, metadata }, + authorizationData, + authorizationFlow, +) { let response; if (message.type === EventType.IDENTIFY) { - response = await processIdentify(message, authorizationData, destination, authorizationFlow); + response = await processIdentify( + { message, destination, metadata }, + authorizationData, + authorizationFlow, + ); } else { throw new InstrumentationError(`message type ${message.type} is not supported`); } @@ -344,9 +356,8 @@ async function processSingleMessage(message, authorizationData, destination, aut async function process(event) { const authInfo = await collectAuthorizationInfo(event); const response = await processSingleMessage( - event.message, + event, authInfo.authorizationData, - event.destination, authInfo.authorizationFlow, ); return response; @@ -377,12 +388,7 @@ const processRouterDest = async (inputs, reqMetadata) => { // unprocessed payload return getSuccessRespEvents( - await processSingleMessage( - input.message, - authInfo.authorizationData, - input.destination, - authInfo.authorizationFlow, - ), + await processSingleMessage(input, authInfo.authorizationData, authInfo.authorizationFlow), [input.metadata], input.destination, ); diff --git a/src/v0/destinations/salesforce/utils.js b/src/v0/destinations/salesforce/utils.js index bb1236d290..9a4effc502 100644 --- a/src/v0/destinations/salesforce/utils.js +++ b/src/v0/destinations/salesforce/utils.js @@ -101,7 +101,7 @@ const salesforceResponseHandler = (destResponse, sourceMessage, authKey, authori * Utility method to construct the header to be used for SFDC API calls * The "Authorization: Bearer " header element needs to be passed * for authentication for all SFDC REST API calls - * @param {*} destination + * @param {destination: Record, metadata: Record} * @returns */ const getAccessTokenOauth = (metadata) => ({ @@ -109,7 +109,7 @@ const getAccessTokenOauth = (metadata) => ({ instanceUrl: metadata.secret?.instance_url, }); -const getAccessToken = async (destination) => { +const getAccessToken = async ({ destination, metadata }) => { const accessTokenKey = destination.ID; return ACCESS_TOKEN_CACHE.get(accessTokenKey, async () => { @@ -137,6 +137,7 @@ const getAccessToken = async (destination) => { endpointPath: '/services/oauth2/token', requestMethod: 'POST', module: 'router', + metadata, }, ); // If the request fails, throwing error. @@ -173,7 +174,7 @@ const collectAuthorizationInfo = async (event) => { authorizationData = getAccessTokenOauth(event.metadata); } else { authorizationFlow = LEGACY; - authorizationData = await getAccessToken(event.destination); + authorizationData = await getAccessToken(event); } return { authorizationFlow, authorizationData }; }; diff --git a/src/v0/destinations/sendgrid/transform.js b/src/v0/destinations/sendgrid/transform.js index c32e34c489..a3516687db 100644 --- a/src/v0/destinations/sendgrid/transform.js +++ b/src/v0/destinations/sendgrid/transform.js @@ -57,15 +57,15 @@ const responseBuilder = (payload, method, endpoint, apiKey) => { throw new TransformationError(ErrorMessage.FailedToConstructPayload); }; -const identifyResponseBuilder = async (message, destination) => { +const identifyResponseBuilder = async ({ message, destination, metadata }) => { validateIdentifyPayload(message); - const builder = await createOrUpdateContactPayloadBuilder(message, destination); + const builder = await createOrUpdateContactPayloadBuilder({ message, destination, metadata }); const { payload, method, endpoint } = builder; const { apiKey } = destination.Config; return responseBuilder(payload, method, endpoint, apiKey); }; -const trackResponseBuilder = async (message, { Config }) => { +const trackResponseBuilder = async ({ message, destination: { Config } }) => { validateTrackPayload(message, Config); let payload = {}; payload = constructPayload(message, MAPPING_CONFIG[CONFIG_CATEGORIES.TRACK.name]); @@ -123,7 +123,8 @@ const trackResponseBuilder = async (message, { Config }) => { return responseBuilder(payload, method, endpoint, apiKey); }; -const processEvent = async (message, destination) => { +const processEvent = async (event) => { + const { message, destination } = event; // Validating if message type is even given or not if (!message.type) { throw new InstrumentationError('Event type is required'); @@ -137,10 +138,10 @@ const processEvent = async (message, destination) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder(event); break; case EventType.TRACK: - response = await trackResponseBuilder(message, destination); + response = await trackResponseBuilder(event); break; default: throw new InstrumentationError(`Event type ${messageType} is not supported`); @@ -148,7 +149,7 @@ const processEvent = async (message, destination) => { return response; }; -const process = (event) => processEvent(event.message, event.destination); +const process = (event) => processEvent(event); const generateBatchedPaylaodForArray = (events, combination) => { let batchEventResponse = defaultBatchRequestConfig(); diff --git a/src/v0/destinations/sendgrid/util.js b/src/v0/destinations/sendgrid/util.js index 7105c5cda5..28c9aae6d2 100644 --- a/src/v0/destinations/sendgrid/util.js +++ b/src/v0/destinations/sendgrid/util.js @@ -431,7 +431,7 @@ const getContactListIds = (message, destination) => { * @param {*} destination * @returns */ -const fetchCustomFields = async (destination) => { +const fetchCustomFields = async ({ destination, metadata }) => { const { apiKey } = destination.Config; return customFieldsCache.get(destination.ID, async () => { const requestOptions = { @@ -448,6 +448,7 @@ const fetchCustomFields = async (destination) => { endpointPath: '/marketing/field_definitions', requestMethod: 'GET', module: 'router', + metadata, }); const processedResponse = processAxiosResponse(resonse); if (isHttpStatusSuccess(processedResponse.status)) { @@ -475,14 +476,14 @@ const fetchCustomFields = async (destination) => { * @param {*} contactDetails * @returns */ -const getCustomFields = async (message, destination) => { +const getCustomFields = async ({ message, destination, metadata }) => { const customFields = {}; - const payload = get(message, 'context.traits'); + const payload = get(message, 'context.traits') || get(message, 'traits'); const { customFieldsMapping } = destination.Config; const fieldsMapping = getHashFromArray(customFieldsMapping, 'from', 'to', false); const fields = Object.keys(fieldsMapping); if (fields.length > 0) { - const destinationCustomFields = await fetchCustomFields(destination); + const destinationCustomFields = await fetchCustomFields({ destination, metadata }); const customFieldNameToIdMapping = {}; const customFieldNamesArray = destinationCustomFields.map((destinationCustomField) => { const { id, name } = destinationCustomField; @@ -511,13 +512,13 @@ const getCustomFields = async (message, destination) => { * @param {*} destination * @returns */ -const createOrUpdateContactPayloadBuilder = async (message, destination) => { +const createOrUpdateContactPayloadBuilder = async ({ message, destination, metadata }) => { const contactDetails = constructPayload(message, MAPPING_CONFIG[CONFIG_CATEGORIES.IDENTIFY.name]); if (contactDetails.address_line_1) { contactDetails.address_line_1 = flattenAddress(contactDetails.address_line_1); } const contactListIds = getContactListIds(message, destination); - contactDetails.custom_fields = await getCustomFields(message, destination); + contactDetails.custom_fields = await getCustomFields({ message, destination, metadata }); const payload = { contactDetails, contactListIds }; const { endpoint } = CONFIG_CATEGORIES.IDENTIFY; const method = defaultPutRequestConfig.requestMethod; diff --git a/src/v0/destinations/sendinblue/transform.js b/src/v0/destinations/sendinblue/transform.js index 7663672f12..4e22200ee5 100644 --- a/src/v0/destinations/sendinblue/transform.js +++ b/src/v0/destinations/sendinblue/transform.js @@ -13,6 +13,7 @@ const { defaultPutRequestConfig, getIntegrationsObj, ErrorMessage, + removeEmptyKey, } = require('../../util'); const { CONFIG_CATEGORIES, MAPPING_CONFIG, getUnlinkContactEndpoint } = require('./config'); const { @@ -21,7 +22,6 @@ const { validateEmailAndPhone, checkIfContactExists, prepareHeader, - removeEmptyKey, transformUserTraits, prepareTrackEventData, getListIds, @@ -176,7 +176,7 @@ const updateDOIContactResponseBuilder = (message, destination, identifier) => { ); }; -const createOrUpdateDOIContactResponseBuilder = async (message, destination) => { +const createOrUpdateDOIContactResponseBuilder = async ({ message, destination, metadata }) => { let email = getFieldValueFromMessage(message, 'emailOnly'); const phone = getFieldValueFromMessage(message, 'phone'); @@ -196,7 +196,7 @@ const createOrUpdateDOIContactResponseBuilder = async (message, destination) => } const { apiKey } = destination.Config; - const contactExists = await checkIfContactExists(identifier, apiKey); + const contactExists = await checkIfContactExists(identifier, apiKey, metadata); if (contactExists) { return updateDOIContactResponseBuilder(message, destination, identifier); @@ -205,7 +205,7 @@ const createOrUpdateDOIContactResponseBuilder = async (message, destination) => return createDOIContactResponseBuilder(message, destination); }; -const identifyResponseBuilder = async (message, destination) => { +const identifyResponseBuilder = async ({ message, destination, metadata }) => { const { doi } = destination.Config; if (!doi) { const unlinkListIds = getListIds(message, 'sendinblueUnlinkListIds'); @@ -215,7 +215,7 @@ const identifyResponseBuilder = async (message, destination) => { return createOrUpdateContactResponseBuilder(message, destination); } - return createOrUpdateDOIContactResponseBuilder(message, destination); + return createOrUpdateDOIContactResponseBuilder({ message, destination, metadata }); }; // ref:- https://tracker-doc.sendinblue.com/reference/trackevent-3 @@ -305,7 +305,8 @@ const pageResponseBuilder = (message, destination) => { return responseBuilder(payload, endpoint, destination, true); }; -const processEvent = async (message, destination) => { +const processEvent = async (event) => { + const { message, destination } = event; if (!message.type) { throw new InstrumentationError('Event type is required'); } @@ -314,7 +315,7 @@ const processEvent = async (message, destination) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder(event); break; case EventType.TRACK: response = trackResponseBuilder(message, destination); @@ -328,7 +329,7 @@ const processEvent = async (message, destination) => { return response; }; -const process = (event) => processEvent(event.message, event.destination); +const process = (event) => processEvent(event); const processRouterDest = async (inputs) => { const respList = await simpleProcessRouterDest(inputs, process, process); diff --git a/src/v0/destinations/sendinblue/util.js b/src/v0/destinations/sendinblue/util.js index 9fded8e493..3af35cd7b9 100644 --- a/src/v0/destinations/sendinblue/util.js +++ b/src/v0/destinations/sendinblue/util.js @@ -52,7 +52,7 @@ const validateEmailAndPhone = (email, phone = null) => { */ const prepareEmailFromPhone = (phone) => `${phone.replace('+', '')}${EMAIL_SUFFIX}`; -const checkIfContactExists = async (identifier, apiKey) => { +const checkIfContactExists = async (identifier, apiKey, metadata) => { const endpoint = getContactDetailsEndpoint(identifier); const requestOptions = { headers: prepareHeader(apiKey), @@ -63,6 +63,7 @@ const checkIfContactExists = async (identifier, apiKey) => { endpointPath: '/contacts', requestMethod: 'GET', module: 'router', + metadata, }); const processedContactDetailsResponse = processAxiosResponse(contactDetailsResponse); @@ -90,20 +91,6 @@ const checkIfContactExists = async (identifier, apiKey) => { return false; }; -/** - * Function to remove empty key ("") from payload - * @param {*} payload {"key1":"a","":{"id":1}} - * @returns // {"key1":"a"} - */ -const removeEmptyKey = (payload) => { - const rawPayload = payload; - const key = ''; - if (Object.prototype.hasOwnProperty.call(rawPayload, key)) { - delete rawPayload['']; - } - return rawPayload; -}; - /** * Function to remove duplicate traits from user traits * @param {*} userTraits {"location":"San Francisco","LOCATION":"San Francisco"} @@ -171,7 +158,6 @@ module.exports = { validateEmailAndPhone, checkIfContactExists, prepareHeader, - removeEmptyKey, transformUserTraits, prepareTrackEventData, getListIds, diff --git a/src/v0/destinations/sfmc/config.js b/src/v0/destinations/sfmc/config.js index 1b1f5c323b..1c89c04112 100644 --- a/src/v0/destinations/sfmc/config.js +++ b/src/v0/destinations/sfmc/config.js @@ -7,6 +7,10 @@ const ENDPOINTS = { EVENT: 'rest.marketingcloudapis.com/interaction/v1/events', }; +const ACCESS_TOKEN_CACHE_TTL = process.env.SFMC_ACCESS_TOKEN_CACHE_TTL + ? parseInt(process.env.SFMC_ACCESS_TOKEN_CACHE_TTL, 10) + : 1000; + const CONFIG_CATEGORIES = { IDENTIFY: { type: 'identify', @@ -24,4 +28,5 @@ module.exports = { ENDPOINTS, MAPPING_CONFIG, CONFIG_CATEGORIES, + ACCESS_TOKEN_CACHE_TTL, }; diff --git a/src/v0/destinations/sfmc/transform.js b/src/v0/destinations/sfmc/transform.js index bf474ff3f0..d20a9ed40d 100644 --- a/src/v0/destinations/sfmc/transform.js +++ b/src/v0/destinations/sfmc/transform.js @@ -6,10 +6,19 @@ const { InstrumentationError, isDefinedAndNotNull, isEmpty, + MappedToDestinationKey, + GENERIC_TRUE_VALUES, + PlatformError, } = require('@rudderstack/integrations-lib'); +const get = require('get-value'); const { EventType } = require('../../../constants'); const { handleHttpRequest } = require('../../../adapters/network'); -const { CONFIG_CATEGORIES, MAPPING_CONFIG, ENDPOINTS } = require('./config'); +const { + CONFIG_CATEGORIES, + MAPPING_CONFIG, + ENDPOINTS, + ACCESS_TOKEN_CACHE_TTL, +} = require('./config'); const { removeUndefinedAndNullValues, getFieldValueFromMessage, @@ -21,17 +30,20 @@ const { toTitleCase, getHashFromArray, simpleProcessRouterDest, + getDestinationExternalIDInfoForRetl, } = require('../../util'); const { getDynamicErrorType } = require('../../../adapters/utils/networkUtils'); const { isHttpStatusSuccess } = require('../../util'); const tags = require('../../util/tags'); const { JSON_MIME_TYPE } = require('../../util/constant'); +const Cache = require('../../util/cache'); +const accessTokenCache = new Cache(ACCESS_TOKEN_CACHE_TTL); const CONTACT_KEY_KEY = 'Contact Key'; // DOC: https://developer.salesforce.com/docs/atlas.en-us.mc-app-development.meta/mc-app-development/access-token-s2s.htm -const getToken = async (clientId, clientSecret, subdomain) => { +const getToken = async (clientId, clientSecret, subdomain, metadata) => { const { processedResponse: processedResponseSfmc } = await handleHttpRequest( 'post', `https://${subdomain}.${ENDPOINTS.GET_TOKEN}`, @@ -49,6 +61,7 @@ const getToken = async (clientId, clientSecret, subdomain) => { endpointPath: '/token', requestMethod: 'POST', module: 'router', + metadata, }, ); @@ -194,7 +207,7 @@ const responseBuilderForMessageEvent = (message, subDomain, authToken, hashMapEv return response; }; -const responseBuilderSimple = async (message, category, destination) => { +const responseBuilderSimple = async ({ message, destination, metadata }, category) => { const { clientId, clientSecret, @@ -213,7 +226,7 @@ const responseBuilderSimple = async (message, category, destination) => { // map from an event name to uuid as true or false to determine to send uuid as primary key or not. const hashMapUUID = getHashFromArray(eventToUUID, 'event', 'uuid'); // token needed for authorization for subsequent calls - const authToken = await getToken(clientId, clientSecret, subDomain); + const authToken = await getToken(clientId, clientSecret, subDomain, metadata); // map from an event name to an event definition key. const hashMapEventDefinition = getHashFromArray(eventToDefinitionMapping, 'from', 'to'); // if createOrUpdateContacts is true identify calls for create and update of contacts will not occur. @@ -270,11 +283,41 @@ const responseBuilderSimple = async (message, category, destination) => { throw new ConfigurationError(`Event type '${category.type}' not supported`); }; -const processEvent = async (message, destination) => { +const retlResponseBuilder = async (message, destination, metadata) => { + const { clientId, clientSecret, subDomain, externalKey } = destination.Config; + const token = await accessTokenCache.get(metadata.destinationId, () => + getToken(clientId, clientSecret, subDomain, metadata), + ); + const { destinationExternalId, objectType, identifierType } = getDestinationExternalIDInfoForRetl( + message, + 'SFMC', + ); + if (objectType?.toLowerCase() === 'data extension') { + const response = defaultRequestConfig(); + response.method = defaultPutRequestConfig.requestMethod; + response.endpoint = `https://${subDomain}.${ENDPOINTS.INSERT_CONTACTS}${externalKey}/rows/${identifierType}:${destinationExternalId}`; + response.headers = { + 'Content-Type': JSON_MIME_TYPE, + Authorization: `Bearer ${token}`, + }; + response.body.JSON = { + values: { + ...message.traits, + }, + }; + return response; + } + throw new PlatformError('Unsupported object type for rETL use case'); +}; + +const processEvent = async ({ message, destination, metadata }) => { if (!message.type) { throw new InstrumentationError('Event type is required'); } - + const mappedToDestination = get(message, MappedToDestinationKey); + if (mappedToDestination && GENERIC_TRUE_VALUES.includes(mappedToDestination?.toString())) { + return retlResponseBuilder(message, destination, metadata); + } const messageType = message.type.toLowerCase(); let category; // only accept track and identify calls @@ -290,12 +333,12 @@ const processEvent = async (message, destination) => { } // build the response - const response = await responseBuilderSimple(message, category, destination); + const response = await responseBuilderSimple({ message, destination, metadata }, category); return response; }; const process = async (event) => { - const response = await processEvent(event.message, event.destination); + const response = await processEvent(event); return response; }; diff --git a/src/v0/destinations/sfmc/transform.test.js b/src/v0/destinations/sfmc/transform.test.js index 8d382ef649..e182fb0d78 100644 --- a/src/v0/destinations/sfmc/transform.test.js +++ b/src/v0/destinations/sfmc/transform.test.js @@ -33,7 +33,7 @@ describe('responseBuilderSimple', () => { name: 'Identify', }; - const response = await responseBuilderSimple(message, category, destination); + const response = await responseBuilderSimple({ message, destination }, category); expect(response).toHaveLength(2); expect(response[0]).toHaveProperty('endpoint'); @@ -58,7 +58,7 @@ describe('responseBuilderSimple', () => { }; try { - await responseBuilderSimple(message, category, destination); + await responseBuilderSimple({ message, destination }, category); } catch (e) { expect(e).toBeInstanceOf(ConfigurationError); expect(e.message).toBe('Event name is required for track events'); @@ -77,7 +77,7 @@ describe('responseBuilderSimple', () => { name: 'Track', }; try { - await responseBuilderSimple(message, category, destination); + await responseBuilderSimple({ message, destination }, category); } catch (e) { expect(e).toBeInstanceOf(ConfigurationError); expect(e.message).toBe('Event not mapped for this track call'); @@ -96,7 +96,7 @@ describe('responseBuilderSimple', () => { }; try { - await responseBuilderSimple(message, category, destination); + await responseBuilderSimple({ message, destination }, category); } catch (e) { expect(e).toBeInstanceOf(ConfigurationError); expect(e.message).toBe("Event type 'unsupported' not supported"); @@ -116,7 +116,7 @@ describe('responseBuilderSimple', () => { name: 'Track', }; - const response = await responseBuilderSimple(message, category, destination); + const response = await responseBuilderSimple({ message, destination }, category); expect(response).toHaveProperty('endpoint'); expect(response).toHaveProperty('method'); expect(response).toHaveProperty('body.JSON'); diff --git a/src/v0/destinations/snapchat_conversion/transform.js b/src/v0/destinations/snapchat_conversion/transform.js index 6fec6313a4..dbb2865e4a 100644 --- a/src/v0/destinations/snapchat_conversion/transform.js +++ b/src/v0/destinations/snapchat_conversion/transform.js @@ -179,7 +179,7 @@ const getEventConversionType = (message) => { // Returns the response for the track event after constructing the payload and setting necessary fields const trackResponseBuilder = (message, { Config }, mappedEvent) => { let payload = {}; - const event = mappedEvent.trim().replace(/\s+/g, '_'); + const event = mappedEvent?.toString().trim().replace(/\s+/g, '_'); const eventConversionType = getEventConversionType(message); const { apiKey, pixelId, snapAppId, appId, deduplicationKey, enableDeduplication } = Config; validateEventConfiguration(eventConversionType, pixelId, snapAppId, appId); @@ -305,7 +305,7 @@ const eventMappingHandler = (message, destination) => { if (!event) { throw new InstrumentationError('Event name is required'); } - event = event.trim().replace(/\s+/g, '_'); + event = event.toString().trim().replace(/\s+/g, '_'); let { rudderEventsToSnapEvents } = destination.Config; const mappedEvents = new Set(); diff --git a/src/v0/destinations/snapchat_custom_audience/networkHandler.js b/src/v0/destinations/snapchat_custom_audience/networkHandler.js index 6044216293..da2a021345 100644 --- a/src/v0/destinations/snapchat_custom_audience/networkHandler.js +++ b/src/v0/destinations/snapchat_custom_audience/networkHandler.js @@ -31,6 +31,7 @@ const prepareProxyReq = (request) => { }; const scAudienceProxyRequest = async (request) => { + const { metadata } = request; const { endpoint, data, method, params, headers } = prepareProxyReq(request); const requestOptions = { @@ -46,6 +47,7 @@ const scAudienceProxyRequest = async (request) => { endpointPath: '/segments/segmentId/users', requestMethod: requestOptions?.method, module: 'dataDelivery', + metadata, }); return response; }; diff --git a/src/v0/destinations/the_trade_desk/networkHandler.js b/src/v0/destinations/the_trade_desk/networkHandler.js index aebbfc0785..d04b5216b0 100644 --- a/src/v0/destinations/the_trade_desk/networkHandler.js +++ b/src/v0/destinations/the_trade_desk/networkHandler.js @@ -10,6 +10,7 @@ const tags = require('../../util/tags'); const { JSON_MIME_TYPE } = require('../../util/constant'); const proxyRequest = async (request) => { + const { metadata } = request; const { endpoint, data, method, params, headers, config } = prepareProxyRequest(request); if (!config?.advertiserSecretKey) { @@ -43,6 +44,7 @@ const proxyRequest = async (request) => { endpointPath: '/track/realtimeconversion', requestMethod: 'POST', module: 'dataDelivery', + metadata, }); return response; }; diff --git a/src/v0/destinations/tiktok_ads/data/TikTokTrackV2.json b/src/v0/destinations/tiktok_ads/data/TikTokTrackV2.json index 2910f1b44c..ec66cf9ba2 100644 --- a/src/v0/destinations/tiktok_ads/data/TikTokTrackV2.json +++ b/src/v0/destinations/tiktok_ads/data/TikTokTrackV2.json @@ -126,5 +126,41 @@ "destKey": "user.user_agent", "sourceKeys": ["properties.context.user.userAgent", "context.userAgent"], "required": false + }, + { + "destKey": "user.first_name", + "sourceKeys": "firstName", + "metadata": { + "type": ["trim", "toLower", "hashToSha256"] + }, + "sourceFromGenericMap": true + }, + { + "destKey": "user.last_name", + "sourceKeys": "lastName", + "metadata": { + "type": ["trim", "toLower", "hashToSha256"] + }, + "sourceFromGenericMap": true + }, + { + "destKey": "user.city", + "sourceKeys": ["context.traits.city", "context.traits.address.city", "properties.city"] + }, + { + "destKey": "user.country", + "sourceKeys": ["context.traits.country", "context.traits.address.country", "properties.country"] + }, + { + "destKey": "user.state", + "sourceKeys": ["context.traits.address.state", "context.traits.state", "properties.state"] + }, + { + "destKey": "user.zip_code", + "sourceKeys": "zipcode", + "sourceFromGenericMap": true, + "metadata": { + "type": ["removeSpacesAndDashes", "hashToSha256"] + } } ] diff --git a/src/v0/destinations/tiktok_ads/util.js b/src/v0/destinations/tiktok_ads/util.js index 3d86ac69b7..5f86193531 100644 --- a/src/v0/destinations/tiktok_ads/util.js +++ b/src/v0/destinations/tiktok_ads/util.js @@ -23,6 +23,7 @@ const getContents = (message, getContentType = true) => { price: product.price, quantity: product.quantity, description: product.description, + brand: product.brand, }; contents.push(removeUndefinedAndNullValues(singleProduct)); }); diff --git a/src/v0/destinations/user/transform.js b/src/v0/destinations/user/transform.js index ed04f5ccd4..24baadd200 100644 --- a/src/v0/destinations/user/transform.js +++ b/src/v0/destinations/user/transform.js @@ -43,23 +43,24 @@ const responseBuilder = async (payload, endpoint, method, apiKey) => { throw new TransformationError('Something went wrong while constructing the payload'); }; -const identifyResponseBuilder = async (message, destination) => { +const identifyResponseBuilder = async (event) => { + const { destination } = event; let builder; - const user = await retrieveUserFromLookup(message, destination); + const user = await retrieveUserFromLookup(event); const { Config } = destination; const { apiKey } = Config; // If user already exist we will update it else creates a new user if (!user) { - builder = createOrUpdateUserPayloadBuilder(message, destination); + builder = createOrUpdateUserPayloadBuilder(event); } else { const { id } = user; - builder = createOrUpdateUserPayloadBuilder(message, destination, id); + builder = createOrUpdateUserPayloadBuilder(event, id); } const { payload, endpoint, method } = builder; return responseBuilder(payload, endpoint, method, apiKey); }; -const trackResponseBuilder = async (message, destination) => { +const trackResponseBuilder = async ({ message, destination, metadata }) => { if (!message.event) { throw new InstrumentationError('Parameter event is required'); } @@ -68,7 +69,7 @@ const trackResponseBuilder = async (message, destination) => { let endpoint; let method; let builder; - const user = await retrieveUserFromLookup(message, destination); + const user = await retrieveUserFromLookup({ message, destination, metadata }); const { Config } = destination; const { apiKey, appSubdomain } = Config; if (user) { @@ -85,12 +86,12 @@ const trackResponseBuilder = async (message, destination) => { ); }; -const pageResponseBuilder = async (message, destination) => { +const pageResponseBuilder = async ({ message, destination, metadata }) => { let payload; let endpoint; let method; let builder; - const user = await retrieveUserFromLookup(message, destination); + const user = await retrieveUserFromLookup({ message, destination, metadata }); const { Config } = destination; const { apiKey, appSubdomain } = Config; if (user) { @@ -106,14 +107,14 @@ const pageResponseBuilder = async (message, destination) => { ); }; -const groupResponseBuilder = async (message, destination) => { +const groupResponseBuilder = async ({ message, destination, metadata }) => { validateGroupPayload(message); let payload; let endpoint; let method; let builder; - const user = await getUserByCustomId(message, destination); + const user = await getUserByCustomId(message, destination, metadata); const { Config } = destination; const { apiKey, appSubdomain } = Config; /* @@ -121,11 +122,11 @@ const groupResponseBuilder = async (message, destination) => { * user does not exist -> throw an error */ if (user) { - let company = await getCompanyByCustomId(message, destination); + let company = await getCompanyByCustomId(message, destination, metadata); if (!company) { - company = await createCompany(message, destination); + company = await createCompany(message, destination, metadata); } else { - company = await updateCompany(message, destination, company); + company = await updateCompany(message, destination, company, metadata); } builder = addUserToCompanyPayloadBuilder(user, company); payload = builder.payload; @@ -137,7 +138,8 @@ const groupResponseBuilder = async (message, destination) => { throw new NetworkInstrumentationError('No user found with given userId'); }; -const processEvent = async (message, destination) => { +const processEvent = async (event) => { + const { message } = event; // Validating if message type is even given or not if (!message.type) { throw new InstrumentationError('Event type is required'); @@ -146,16 +148,16 @@ const processEvent = async (message, destination) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder(event); break; case EventType.GROUP: - response = await groupResponseBuilder(message, destination); + response = await groupResponseBuilder(event); break; case EventType.TRACK: - response = await trackResponseBuilder(message, destination); + response = await trackResponseBuilder(event); break; case EventType.PAGE: - response = await pageResponseBuilder(message, destination); + response = await pageResponseBuilder(event); break; default: throw new InstrumentationError(`Event type ${messageType} is not supported`); @@ -163,7 +165,7 @@ const processEvent = async (message, destination) => { return response; }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/user/utils.js b/src/v0/destinations/user/utils.js index f332d7a4a7..f469d123d8 100644 --- a/src/v0/destinations/user/utils.js +++ b/src/v0/destinations/user/utils.js @@ -211,7 +211,7 @@ const validateGroupPayload = (message) => { * @param {*} destination * @returns */ -const createCompany = async (message, destination) => { +const createCompany = async (message, destination, metadata) => { const commonCompanyPropertiesPayload = constructPayload( message, MAPPING_CONFIG[CONFIG_CATEGORIES.CREATE_COMPANY.name], @@ -240,6 +240,7 @@ const createCompany = async (message, destination) => { endpointPath: `/companies/`, requestMethod: 'POST', module: 'router', + metadata, }); const data = processAxiosResponse(response); return data.response; @@ -253,7 +254,7 @@ const createCompany = async (message, destination) => { * @param {*} company * @returns */ -const updateCompany = async (message, destination, company) => { +const updateCompany = async (message, destination, company, metadata) => { const commonCompanyPropertiesPayload = constructPayload( message, MAPPING_CONFIG[CONFIG_CATEGORIES.UPDATE_COMPANY.name], @@ -283,6 +284,7 @@ const updateCompany = async (message, destination, company) => { endpointPath: `/companies/`, requestMethod: 'PUT', module: 'router', + metadata, }); const data = processAxiosResponse(response); return data.response; @@ -296,7 +298,7 @@ const updateCompany = async (message, destination, company) => { * @param {*} appSubdomain * @returns */ -const getUserByUserKey = async (apiKey, userKey, appSubdomain) => { +const getUserByUserKey = async (apiKey, userKey, appSubdomain, metadata) => { const endpoint = prepareUrl(`${BASE_ENDPOINT}/users/search/?key=${userKey}`, appSubdomain); const requestOptions = { headers: { @@ -312,6 +314,7 @@ const getUserByUserKey = async (apiKey, userKey, appSubdomain) => { endpointPath: `/users/search`, requestMethod: 'GET', module: 'router', + metadata, }); const processedUserResponse = processAxiosResponse(userResponse); if (processedUserResponse.status === 200) { @@ -328,7 +331,7 @@ const getUserByUserKey = async (apiKey, userKey, appSubdomain) => { * @param {*} appSubdomain * @returns */ -const getUserByEmail = async (apiKey, email, appSubdomain) => { +const getUserByEmail = async (apiKey, email, appSubdomain, metadata) => { if (!email) { throw new InstrumentationError('Lookup field : email value is not present'); } @@ -348,6 +351,7 @@ const getUserByEmail = async (apiKey, email, appSubdomain) => { endpointPath: `/users/search/?email`, requestMethod: 'GET', module: 'router', + metadata, }); const processedUserResponse = processAxiosResponse(userResponse); @@ -366,7 +370,7 @@ const getUserByEmail = async (apiKey, email, appSubdomain) => { * @param {*} appSubdomain * @returns */ -const getUserByPhoneNumber = async (apiKey, phoneNumber, appSubdomain) => { +const getUserByPhoneNumber = async (apiKey, phoneNumber, appSubdomain, metadata) => { if (!phoneNumber) { throw new InstrumentationError('Lookup field : phone value is not present'); } @@ -389,6 +393,7 @@ const getUserByPhoneNumber = async (apiKey, phoneNumber, appSubdomain) => { endpointPath: `/users/search/?phone_number`, requestMethod: 'GET', module: 'router', + metadata, }); const processedUserResponse = processAxiosResponse(userResponse); @@ -415,7 +420,7 @@ const getUserByPhoneNumber = async (apiKey, phoneNumber, appSubdomain) => { * @param {*} destination * @returns */ -const getUserByCustomId = async (message, destination) => { +const getUserByCustomId = async (message, destination, metadata) => { const { Config } = destination; const { appSubdomain, apiKey } = Config; const userCustomId = getFieldValueFromMessage(message, 'userId'); @@ -436,6 +441,7 @@ const getUserByCustomId = async (message, destination) => { endpointPath: `/users-by-id/`, requestMethod: 'GET', module: 'router', + metadata, }); const processedUserResponse = processAxiosResponse(userResponse); @@ -453,7 +459,7 @@ const getUserByCustomId = async (message, destination) => { * @param {*} destination * @returns */ -const getCompanyByCustomId = async (message, destination) => { +const getCompanyByCustomId = async (message, destination, metadata) => { const { Config } = destination; const { appSubdomain, apiKey } = Config; const companyCustomId = getFieldValueFromMessage(message, 'groupId'); @@ -474,6 +480,7 @@ const getCompanyByCustomId = async (message, destination) => { endpointPath: `/companies-by-id/`, requestMethod: 'GET', module: 'router', + metadata, }); const processedUserResponse = processAxiosResponse(response); if (processedUserResponse.status === 200) { @@ -490,12 +497,12 @@ const getCompanyByCustomId = async (message, destination) => { * @param {*} destination * @returns */ -const retrieveUserFromLookup = async (message, destination) => { +const retrieveUserFromLookup = async ({ message, destination, metadata }) => { const { Config } = destination; const { appSubdomain, apiKey } = Config; const userKey = getDestinationExternalID(message, 'userKey'); if (isDefinedAndNotNullAndNotEmpty(userKey)) { - return getUserByUserKey(apiKey, userKey, appSubdomain); + return getUserByUserKey(apiKey, userKey, appSubdomain, metadata); } const integrationsObj = getIntegrationsObj(message, 'user'); @@ -504,11 +511,11 @@ const retrieveUserFromLookup = async (message, destination) => { const lookupFieldValue = getFieldValueFromMessage(message, lookupField); if (lookupField === 'email') { - return getUserByEmail(apiKey, lookupFieldValue, appSubdomain); + return getUserByEmail(apiKey, lookupFieldValue, appSubdomain, metadata); } if (lookupField === 'phone') { - return getUserByPhoneNumber(apiKey, lookupFieldValue, appSubdomain); + return getUserByPhoneNumber(apiKey, lookupFieldValue, appSubdomain, metadata); } throw new InstrumentationError( @@ -517,11 +524,11 @@ const retrieveUserFromLookup = async (message, destination) => { } else { const userId = getValueFromMessage(message, 'userId'); if (userId) { - return getUserByCustomId(message, destination); + return getUserByCustomId(message, destination, metadata); } const email = getFieldValueFromMessage(message, 'email'); if (isDefinedAndNotNullAndNotEmpty(email)) { - return getUserByEmail(apiKey, email, appSubdomain); + return getUserByEmail(apiKey, email, appSubdomain, metadata); } throw new InstrumentationError('Default lookup field : email value is empty'); @@ -535,7 +542,7 @@ const retrieveUserFromLookup = async (message, destination) => { * @param {*} id * @returns */ -const createOrUpdateUserPayloadBuilder = (message, destination, id = null) => { +const createOrUpdateUserPayloadBuilder = ({ message, destination }, id = null) => { const { appSubdomain } = destination.Config; const commonUserPropertiesPayload = constructPayload( message, diff --git a/src/v0/destinations/webengage/transform.js b/src/v0/destinations/webengage/transform.js index f18a7399ff..fc5b0374e4 100644 --- a/src/v0/destinations/webengage/transform.js +++ b/src/v0/destinations/webengage/transform.js @@ -79,8 +79,8 @@ const processEvent = (message, destination) => { return responseBuilder(message, CONFIG_CATEGORIES.EVENT, destination); case EventType.PAGE: case EventType.SCREEN: - name = message.name || message.properties.name; - category = message.properties.category; + name = message.name || message.properties?.name; + category = message.properties?.category; if (name && category) { eventName = `Viewed ${category} ${name} ${messageType}`; } else if (name) { diff --git a/src/v0/destinations/wootric/transform.js b/src/v0/destinations/wootric/transform.js index f8b4274af7..940d6e9e5d 100644 --- a/src/v0/destinations/wootric/transform.js +++ b/src/v0/destinations/wootric/transform.js @@ -37,17 +37,17 @@ const responseBuilder = async (payload, endpoint, method, accessToken) => { throw new TransformationError('Something went wrong while constructing the payload'); }; -const identifyResponseBuilder = async (message, destination) => { +const identifyResponseBuilder = async ({ message, destination, metadata }) => { let payload; let endpoint; let method; let builder; - const accessToken = await getAccessToken(destination); + const accessToken = await getAccessToken(destination, metadata); const rawEndUserId = getDestinationExternalID(message, 'wootricEndUserId'); const userId = getFieldValueFromMessage(message, 'userIdOnly'); - const userDetails = await retrieveUserDetails(rawEndUserId, userId, accessToken); + const userDetails = await retrieveUserDetails(rawEndUserId, userId, accessToken, metadata); const wootricEndUserId = userDetails?.id; // If user already exist we will update it else creates a new user @@ -132,7 +132,7 @@ const trackResponseBuilder = async (message, destination) => { return responseBuilder(payload, endpoint, method, accessToken); }; -const processEvent = async (message, destination) => { +const processEvent = async ({ message, destination, metadata }) => { if (!message.type) { throw new InstrumentationError('Event type is required'); } @@ -140,7 +140,7 @@ const processEvent = async (message, destination) => { let response; switch (messageType) { case EventType.IDENTIFY: - response = await identifyResponseBuilder(message, destination); + response = await identifyResponseBuilder({ message, destination, metadata }); break; case EventType.TRACK: response = await trackResponseBuilder(message, destination); @@ -151,7 +151,7 @@ const processEvent = async (message, destination) => { return response; }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/wootric/util.js b/src/v0/destinations/wootric/util.js index c2505c635b..398fe94c7d 100644 --- a/src/v0/destinations/wootric/util.js +++ b/src/v0/destinations/wootric/util.js @@ -20,7 +20,7 @@ const ACCESS_TOKEN_CACHE = new Cache(ACCESS_TOKEN_CACHE_TTL_SECONDS); * @param {*} destination * @returns */ -const getAccessToken = async (destination) => { +const getAccessToken = async (destination, metadata) => { const { username, password, accountToken } = destination.Config; const accessTokenKey = destination.ID; @@ -49,6 +49,7 @@ const getAccessToken = async (destination) => { endpointPath: `/oauth/token`, requestMethod: 'POST', module: 'router', + metadata, }); const processedAuthResponse = processAxiosResponse(wootricAuthResponse); // If the request fails, throwing error. @@ -79,7 +80,7 @@ const getAccessToken = async (destination) => { * @returns */ -const retrieveUserDetails = async (endUserId, externalId, accessToken) => { +const retrieveUserDetails = async (endUserId, externalId, accessToken, metadata) => { let endpoint; if (isDefinedAndNotNullAndNotEmpty(endUserId)) { endpoint = `${BASE_ENDPOINT}/${VERSION}/end_users/${endUserId}`; @@ -104,6 +105,7 @@ const retrieveUserDetails = async (endUserId, externalId, accessToken) => { endpointPath: `/v1/end_users/`, requestMethod: 'GET', module: 'router', + metadata, }); const processedUserResponse = processAxiosResponse(userResponse); diff --git a/src/v0/destinations/yahoo_dsp/transform.js b/src/v0/destinations/yahoo_dsp/transform.js index 4cd1eee73d..f11f1629a8 100644 --- a/src/v0/destinations/yahoo_dsp/transform.js +++ b/src/v0/destinations/yahoo_dsp/transform.js @@ -21,7 +21,7 @@ const { JSON_MIME_TYPE } = require('../../util/constant'); * @param {*} destination * @returns */ -const responseBuilder = async (message, destination) => { +const responseBuilder = async (message, destination, metadata) => { let dspListPayload = {}; const { Config } = destination; const { listData } = message.properties; @@ -72,7 +72,7 @@ const responseBuilder = async (message, destination) => { response.endpoint = `${BASE_ENDPOINT}/traffic/audiences/${ENDPOINTS[audienceType]}/${audienceId}`; response.body.JSON = removeUndefinedAndNullValues(dspListPayload); response.method = defaultPutRequestConfig.requestMethod; - const accessToken = await getAccessToken(destination); + const accessToken = await getAccessToken(destination, metadata); response.headers = { 'X-Auth-Token': accessToken, 'X-Auth-Method': 'OAuth2', @@ -81,7 +81,7 @@ const responseBuilder = async (message, destination) => { return response; }; -const processEvent = async (message, destination) => { +const processEvent = async ({ message, destination, metadata }) => { let response; if (!message.type) { throw new InstrumentationError('Event type is required'); @@ -93,14 +93,14 @@ const processEvent = async (message, destination) => { throw new InstrumentationError('listData is not present inside properties. Aborting message'); } if (message.type.toLowerCase() === 'audiencelist') { - response = await responseBuilder(message, destination); + response = await responseBuilder(message, destination, metadata); } else { throw new InstrumentationError(`Event type ${message.type} is not supported`, 400); } return response; }; -const process = async (event) => processEvent(event.message, event.destination); +const process = async (event) => processEvent(event); const processRouterDest = async (inputs, reqMetadata) => { const respList = await simpleProcessRouterDest(inputs, process, reqMetadata); diff --git a/src/v0/destinations/yahoo_dsp/util.js b/src/v0/destinations/yahoo_dsp/util.js index 54002a3bce..ba19ac7725 100644 --- a/src/v0/destinations/yahoo_dsp/util.js +++ b/src/v0/destinations/yahoo_dsp/util.js @@ -95,7 +95,7 @@ const createPayload = (audienceList, Config) => { * @param {*} destination * @returns */ -const getAccessToken = async (destination) => { +const getAccessToken = async (destination, metadata) => { const { clientId, clientSecret } = destination.Config; const accessTokenKey = destination.ID; @@ -140,6 +140,7 @@ const getAccessToken = async (destination) => { endpointPath: '/identity/oauth2/access_token', requestMethod: 'POST', module: 'router', + metadata, }); // If the request fails, throwing error. if (dspAuthorisationData.success === false) { diff --git a/src/v0/destinations/zendesk/transform.js b/src/v0/destinations/zendesk/transform.js index cadb1d3964..792e8df350 100644 --- a/src/v0/destinations/zendesk/transform.js +++ b/src/v0/destinations/zendesk/transform.js @@ -95,7 +95,13 @@ const responseBuilderToUpdatePrimaryAccount = ( * @param {*} headers -> Authorizations for API's call * @returns it return payloadbuilder for updating email */ -const payloadBuilderforUpdatingEmail = async (userId, headers, userEmail, baseEndpoint) => { +const payloadBuilderforUpdatingEmail = async ( + userId, + headers, + userEmail, + baseEndpoint, + metadata, +) => { // url for list all identities of user const url = `${baseEndpoint}users/${userId}/identities`; const config = { headers }; @@ -106,6 +112,7 @@ const payloadBuilderforUpdatingEmail = async (userId, headers, userEmail, baseEn endpointPath: 'users/userId/identities', requestMethod: 'POST', module: 'router', + metadata, }); if (res?.response?.data?.count > 0) { const { identities } = res.response.data; @@ -131,7 +138,7 @@ const payloadBuilderforUpdatingEmail = async (userId, headers, userEmail, baseEn return {}; }; -async function createUserFields(url, config, newFields, fieldJson) { +async function createUserFields(url, config, newFields, fieldJson, metadata) { let fieldData; // removing trailing 's' from fieldJson const fieldJsonSliced = fieldJson.slice(0, -1); @@ -154,6 +161,7 @@ async function createUserFields(url, config, newFields, fieldJson) { endpointPath: '/users/userId/identities', requestMethod: 'POST', module: 'router', + metadata, }); if (response.status !== 201) { logger.debug(`${NAME}:: Failed to create User Field : `, field); @@ -173,6 +181,7 @@ async function checkAndCreateUserFields( fieldJson, headers, baseEndpoint, + metadata, ) { let newFields = []; @@ -185,6 +194,7 @@ async function checkAndCreateUserFields( feature: 'transformation', requestMethod: 'POST', module: 'router', + metadata, }); const fields = get(response.data, fieldJson); if (response.data && fields) { @@ -199,7 +209,7 @@ async function checkAndCreateUserFields( ); if (newFields.length > 0) { - await createUserFields(url, config, newFields, fieldJson); + await createUserFields(url, config, newFields, fieldJson, metadata); } } } catch (error) { @@ -249,7 +259,7 @@ function getIdentifyPayload(message, category, destinationConfig, type) { * @param {*} headers headers for authorizations * @returns */ -const getUserIdByExternalId = async (message, headers, baseEndpoint) => { +const getUserIdByExternalId = async (message, headers, baseEndpoint, metadata) => { const externalId = getFieldValueFromMessage(message, 'userIdOnly'); if (!externalId) { logger.debug(`${NAME}:: externalId is required for getting zenuserId`); @@ -265,6 +275,7 @@ const getUserIdByExternalId = async (message, headers, baseEndpoint) => { endpointPath, requestMethod: 'GET', module: 'router', + metadata, }); if (resp?.response?.data?.count > 0) { @@ -278,7 +289,7 @@ const getUserIdByExternalId = async (message, headers, baseEndpoint) => { return undefined; }; -async function getUserId(message, headers, baseEndpoint, type) { +async function getUserId(message, headers, baseEndpoint, type, metadata) { const traits = type === 'group' ? get(message, CONTEXT_TRAITS_KEY_PATH) @@ -298,6 +309,7 @@ async function getUserId(message, headers, baseEndpoint, type) { endpointPath, requestMethod: 'GET', module: 'router', + metadata, }); if (!resp || !resp.data || resp.data.count === 0) { logger.debug(`${NAME}:: User not found`); @@ -315,7 +327,7 @@ async function getUserId(message, headers, baseEndpoint, type) { } } -async function isUserAlreadyAssociated(userId, orgId, headers, baseEndpoint) { +async function isUserAlreadyAssociated(userId, orgId, headers, baseEndpoint, metadata) { const url = `${baseEndpoint}/users/${userId}/organization_memberships.json`; const config = { headers }; try { @@ -325,6 +337,7 @@ async function isUserAlreadyAssociated(userId, orgId, headers, baseEndpoint) { endpointPath: '/users/userId/organization_memberships.json', requestMethod: 'GET', module: 'router', + metadata, }); if (response?.data?.organization_memberships?.[0]?.organization_id === orgId) { return true; @@ -336,7 +349,7 @@ async function isUserAlreadyAssociated(userId, orgId, headers, baseEndpoint) { return false; } -async function createUser(message, headers, destinationConfig, baseEndpoint, type) { +async function createUser(message, headers, destinationConfig, baseEndpoint, type, metadata) { const traits = type === 'group' ? get(message, CONTEXT_TRAITS_KEY_PATH) @@ -360,6 +373,7 @@ async function createUser(message, headers, destinationConfig, baseEndpoint, typ endpointPath: '/users/create_or_update.json', requestMethod: 'POST', module: 'router', + metadata, }); if (!resp.data || !resp.data.user || !resp.data.user.id) { @@ -377,9 +391,16 @@ async function createUser(message, headers, destinationConfig, baseEndpoint, typ } } -async function getUserMembershipPayload(message, headers, orgId, destinationConfig, baseEndpoint) { +async function getUserMembershipPayload( + message, + headers, + orgId, + destinationConfig, + baseEndpoint, + metadata, +) { // let zendeskUserID = await getUserId(message.userId, headers); - let zendeskUserID = await getUserId(message, headers, baseEndpoint, 'group'); + let zendeskUserID = await getUserId(message, headers, baseEndpoint, 'group', metadata); const traits = get(message, CONTEXT_TRAITS_KEY_PATH); if (!zendeskUserID) { if (traits && traits.name && traits.email) { @@ -389,6 +410,7 @@ async function getUserMembershipPayload(message, headers, orgId, destinationConf destinationConfig, baseEndpoint, 'group', + metadata, ); zendeskUserID = zendeskUserId; } else { @@ -405,7 +427,14 @@ async function getUserMembershipPayload(message, headers, orgId, destinationConf return payload; } -async function createOrganization(message, category, headers, destinationConfig, baseEndpoint) { +async function createOrganization( + message, + category, + headers, + destinationConfig, + baseEndpoint, + metadata, +) { if (!isDefinedAndNotNull(message.traits)) { throw new InstrumentationError('Organisation Traits are missing. Aborting.'); } @@ -415,6 +444,7 @@ async function createOrganization(message, category, headers, destinationConfig, category.organizationFieldsJson, headers, baseEndpoint, + metadata, ); const mappingJson = mappingConfig[category.name]; const payload = constructPayload(message, mappingJson); @@ -447,6 +477,7 @@ async function createOrganization(message, category, headers, destinationConfig, endpointPath: '/organizations/create_or_update.json', requestMethod: 'POST', module: 'router', + metadata, }); if (!resp.data || !resp.data.organization) { @@ -468,7 +499,7 @@ function validateUserId(message) { } } -async function processIdentify(message, destinationConfig, headers, baseEndpoint) { +async function processIdentify(message, destinationConfig, headers, baseEndpoint, metadata) { validateUserId(message); const category = ConfigCategory.IDENTIFY; const traits = getFieldValueFromMessage(message, 'traits'); @@ -480,6 +511,7 @@ async function processIdentify(message, destinationConfig, headers, baseEndpoint category.userFieldsJson, headers, baseEndpoint, + metadata, ); const payload = getIdentifyPayload(message, category, destinationConfig, 'identify'); @@ -487,7 +519,12 @@ async function processIdentify(message, destinationConfig, headers, baseEndpoint const returnList = []; if (destinationConfig.searchByExternalId) { - const userIdByExternalId = await getUserIdByExternalId(message, headers, baseEndpoint); + const userIdByExternalId = await getUserIdByExternalId( + message, + headers, + baseEndpoint, + metadata, + ); const userEmail = traits?.email; if (userIdByExternalId && userEmail) { const payloadForUpdatingEmail = await payloadBuilderforUpdatingEmail( @@ -495,6 +532,7 @@ async function processIdentify(message, destinationConfig, headers, baseEndpoint headers, userEmail, baseEndpoint, + metadata, ); if (!isEmptyObject(payloadForUpdatingEmail)) returnList.push(payloadForUpdatingEmail); } @@ -507,7 +545,7 @@ async function processIdentify(message, destinationConfig, headers, baseEndpoint traits.company.id ) { const orgId = traits.company.id; - const userId = await getUserId(message, headers, baseEndpoint); + const userId = await getUserId(message, headers, baseEndpoint, metadata); if (userId) { const membershipUrl = `${baseEndpoint}users/${userId}/organization_memberships.json`; try { @@ -518,6 +556,7 @@ async function processIdentify(message, destinationConfig, headers, baseEndpoint endpointPath: '/users/userId/organization_memberships.json', requestMethod: 'GET', module: 'router', + metadata, }); if ( response.data && @@ -547,7 +586,7 @@ async function processIdentify(message, destinationConfig, headers, baseEndpoint return returnList; } -async function processTrack(message, destinationConfig, headers, baseEndpoint) { +async function processTrack(message, destinationConfig, headers, baseEndpoint, metadata) { validateUserId(message); const traits = getFieldValueFromMessage(message, 'traits'); let userEmail; @@ -568,6 +607,7 @@ async function processTrack(message, destinationConfig, headers, baseEndpoint) { endpointPath, requestMethod: 'GET', module: 'router', + metadata, }); if (!get(userResponse, 'data.users.0.id') || userResponse.data.count === 0) { const { zendeskUserId, email } = await createUser( @@ -575,6 +615,7 @@ async function processTrack(message, destinationConfig, headers, baseEndpoint) { headers, destinationConfig, baseEndpoint, + metadata, ); if (!zendeskUserId) { throw new NetworkInstrumentationError('User not found'); @@ -618,13 +659,20 @@ async function processTrack(message, destinationConfig, headers, baseEndpoint) { return response; } -async function processGroup(message, destinationConfig, headers, baseEndpoint) { +async function processGroup(message, destinationConfig, headers, baseEndpoint, metadata) { const category = ConfigCategory.GROUP; let payload; let url; if (destinationConfig.sendGroupCallsWithoutUserId && !message.userId) { - payload = await createOrganization(message, category, headers, destinationConfig, baseEndpoint); + payload = await createOrganization( + message, + category, + headers, + destinationConfig, + baseEndpoint, + metadata, + ); url = baseEndpoint + category.createEndpoint; } else { validateUserId(message); @@ -634,6 +682,7 @@ async function processGroup(message, destinationConfig, headers, baseEndpoint) { headers, destinationConfig, baseEndpoint, + metadata, ); if (!orgId) { throw new NetworkInstrumentationError( @@ -648,11 +697,12 @@ async function processGroup(message, destinationConfig, headers, baseEndpoint) { orgId, destinationConfig, baseEndpoint, + metadata, ); url = baseEndpoint + category.userMembershipEndpoint; const userId = payload.organization_membership.user_id; - if (await isUserAlreadyAssociated(userId, orgId, headers, baseEndpoint)) { + if (await isUserAlreadyAssociated(userId, orgId, headers, baseEndpoint, metadata)) { throw new InstrumentationError('User is already associated with organization'); } } @@ -678,15 +728,15 @@ async function processSingleMessage(event) { 'Content-Type': JSON_MIME_TYPE, }; - const { message } = event; + const { message, metadata } = event; const evType = getEventType(message); switch (evType) { case EventType.IDENTIFY: - return processIdentify(message, destinationConfig, headers, baseEndpoint); + return processIdentify(message, destinationConfig, headers, baseEndpoint, metadata); case EventType.GROUP: - return processGroup(message, destinationConfig, headers, baseEndpoint); + return processGroup(message, destinationConfig, headers, baseEndpoint, metadata); case EventType.TRACK: - return processTrack(message, destinationConfig, headers, baseEndpoint); + return processTrack(message, destinationConfig, headers, baseEndpoint, metadata); default: throw new InstrumentationError(`Event type ${evType} is not supported`); } diff --git a/src/v0/sources/appcenter/transform.js b/src/v0/sources/appcenter/transform.js index 40399d92e2..35d15f697e 100644 --- a/src/v0/sources/appcenter/transform.js +++ b/src/v0/sources/appcenter/transform.js @@ -1,7 +1,7 @@ const path = require('path'); const fs = require('fs'); const { TransformationError } = require('@rudderstack/integrations-lib'); -const { generateUUID } = require('../../util'); +const utils = require('../../util'); const Message = require('../message'); const mappingJson = JSON.parse(fs.readFileSync(path.resolve(__dirname, './mapping.json'), 'utf-8')); @@ -37,7 +37,7 @@ const processNormalEvent = (event) => { message.setPropertiesV2(event, mappingJson); // app center does not has the concept of user but we need to set some random anonymousId in order to make the server accept the message - message.anonymousId = generateUUID(); + message.anonymousId = utils.generateUUID(); return message; }; diff --git a/src/v0/sources/braze/eventMapping.json b/src/v0/sources/braze/eventMapping.json deleted file mode 100644 index 0967ef424b..0000000000 --- a/src/v0/sources/braze/eventMapping.json +++ /dev/null @@ -1 +0,0 @@ -{} diff --git a/src/v0/sources/customerio/config.js b/src/v0/sources/customerio/config.js index f084f5e189..41257ed6de 100644 --- a/src/v0/sources/customerio/config.js +++ b/src/v0/sources/customerio/config.js @@ -8,6 +8,7 @@ const emailEventNameMap = { spammed: 'Email Marked as Spam', dropped: 'Email Dropped', bounced: 'Email Bounced', + subscribed: 'Email Subscribed', unsubscribed: 'Email Unsubscribed', converted: 'Email Converted', clicked: 'Email Link Clicked', diff --git a/src/v0/sources/shopify/transform.js b/src/v0/sources/shopify/transform.js index bc2135d215..b55fc61327 100644 --- a/src/v0/sources/shopify/transform.js +++ b/src/v0/sources/shopify/transform.js @@ -144,8 +144,13 @@ const processEvent = async (inputEvent, metricMetadata) => { break; case 'carts_update': if (useRedisDatabase) { - redisData = await getDataFromRedis(event.id || event.token, metricMetadata); - const isValidEvent = await checkAndUpdateCartItems(inputEvent, redisData, metricMetadata); + redisData = await getDataFromRedis(event.id || event.token, metricMetadata, 'Cart Update'); + const isValidEvent = await checkAndUpdateCartItems( + inputEvent, + redisData, + metricMetadata, + shopifyTopic, + ); if (!isValidEvent) { return NO_OPERATION_SUCCESS; } @@ -208,11 +213,20 @@ const isIdentifierEvent = (event) => ['rudderIdentifier', 'rudderSessionIdentifier'].includes(event?.event); const processIdentifierEvent = async (event, metricMetadata) => { if (useRedisDatabase) { + const cartToken = + typeof event.cartToken === 'string' ? event.cartToken.split('?')[0] : event.cartToken; + logger.info(`{{SHOPIFY::}} writeKey: ${metricMetadata.writeKey}, cartToken: ${cartToken}`, { + type: 'set', + source: metricMetadata.source, + writeKey: metricMetadata.writeKey, + }); let value; let field; if (event.event === 'rudderIdentifier') { field = 'anonymousId'; + // eslint-disable-next-line unicorn/consistent-destructuring const lineItemshash = getHashLineItems(event.cart); + // eslint-disable-next-line unicorn/consistent-destructuring value = ['anonymousId', event.anonymousId, 'itemsHash', lineItemshash]; stats.increment('shopify_redis_calls', { type: 'set', @@ -227,6 +241,7 @@ const processIdentifierEvent = async (event, metricMetadata) => { */ } else { field = 'sessionId'; + // eslint-disable-next-line unicorn/consistent-destructuring value = ['sessionId', event.sessionId]; /* cart_token: { anonymousId:'anon_id1', @@ -242,7 +257,7 @@ const processIdentifierEvent = async (event, metricMetadata) => { source: metricMetadata.source, writeKey: metricMetadata.writeKey, }); - await RedisDB.setVal(`${event.cartToken}`, value); + await RedisDB.setVal(`${cartToken}`, value); } catch (e) { logger.debug(`{{SHOPIFY::}} cartToken map set call Failed due redis error ${e}`, { type: 'set', diff --git a/src/v0/sources/shopify/util.js b/src/v0/sources/shopify/util.js index 6aea0d19bd..6d13d13bdf 100644 --- a/src/v0/sources/shopify/util.js +++ b/src/v0/sources/shopify/util.js @@ -24,7 +24,7 @@ const { } = require('./config'); const logger = require('../../../logger'); -const getDataFromRedis = async (key, metricMetadata) => { +const getDataFromRedis = async (key, metricMetadata, event) => { try { stats.increment('shopify_redis_calls', { type: 'get', @@ -40,6 +40,7 @@ const getDataFromRedis = async (key, metricMetadata) => { stats.increment('shopify_redis_no_val', { writeKey: metricMetadata.writeKey, source: metricMetadata.source, + event, }); } return redisData; @@ -187,8 +188,9 @@ const getAnonymousIdAndSessionId = async (message, metricMetadata, redisData = n } if (useRedisDatabase) { if (!isDefinedAndNotNull(redisData)) { + const { event } = message; // eslint-disable-next-line no-param-reassign - redisData = await getDataFromRedis(cartToken, metricMetadata); + redisData = await getDataFromRedis(cartToken, metricMetadata, event); } anonymousId = redisData?.anonymousId; sessionId = redisData?.sessionId; @@ -243,11 +245,11 @@ const updateCartItemsInRedis = async (cartToken, newCartItemsHash, metricMetadat * @param {*} metricMetadata * @returns boolean */ -const checkAndUpdateCartItems = async (inputEvent, redisData, metricMetadata) => { +const checkAndUpdateCartItems = async (inputEvent, redisData, metricMetadata, shopifyTopic) => { const cartToken = inputEvent.token || inputEvent.id; if (!isDefinedAndNotNull(redisData)) { // eslint-disable-next-line no-param-reassign - redisData = await getDataFromRedis(cartToken, metricMetadata); + redisData = await getDataFromRedis(cartToken, metricMetadata, SHOPIFY_TRACK_MAP[shopifyTopic]); } const itemsHash = redisData?.itemsHash; if (isDefinedAndNotNull(itemsHash)) { diff --git a/src/v0/util/facebookUtils/index.js b/src/v0/util/facebookUtils/index.js index 7462320cca..fd94db442b 100644 --- a/src/v0/util/facebookUtils/index.js +++ b/src/v0/util/facebookUtils/index.js @@ -148,11 +148,13 @@ const getContentType = (message, defaultValue, categoryToContent, destinationNam } let { category } = properties || {}; - if (!category) { - const { products } = properties; - if (products && products.length > 0 && Array.isArray(products) && isObject(products[0])) { - category = products[0].category; - } + if ( + !category && + Array.isArray(properties?.products) && + properties?.products.length > 0 && + isObject(properties?.products[0]) + ) { + category = properties?.products[0].category; } if (Array.isArray(categoryToContent) && category) { diff --git a/src/v0/util/facebookUtils/index.test.js b/src/v0/util/facebookUtils/index.test.js index 1a2de4ed12..90588c627b 100644 --- a/src/v0/util/facebookUtils/index.test.js +++ b/src/v0/util/facebookUtils/index.test.js @@ -639,6 +639,21 @@ describe('getContentType', () => { expect(result).toBe(defaultValue); }); + + it('should return default value when no product array or categoryToContent is provided', () => { + const message = { + properties: { + revenue: 1234, + }, + }; + const defaultValue = 'product'; + const categoryToContent = []; + const destinationName = 'fb_pixel'; + + const result = getContentType(message, defaultValue, categoryToContent, destinationName); + + expect(result).toBe(defaultValue); + }); }); describe('isHtmlFormat', () => { diff --git a/src/v0/util/googleUtils/index.js b/src/v0/util/googleUtils/index.js index ef7c244c17..124f63eda5 100644 --- a/src/v0/util/googleUtils/index.js +++ b/src/v0/util/googleUtils/index.js @@ -3,7 +3,11 @@ const GA4_ALLOWED_CONSENT_STATUS = ['GRANTED', 'DENIED']; const UNSPECIFIED_CONSENT = 'UNSPECIFIED'; const UNKNOWN_CONSENT = 'UNKNOWN'; - +const get = require('get-value'); +const { + AUTH_STATUS_INACTIVE, + REFRESH_TOKEN, +} = require('../../../adapters/networkhandler/authConstants'); /** * Populates the consent object based on the provided configuration and consent mapping. * @@ -108,6 +112,32 @@ const finaliseAnalyticsConsents = (consentConfigMap, eventLevelConsent = {}) => return consentObj; }; +const getAuthErrCategory = ({ response, status }) => { + if (status === 401) { + let respArr = response; + if (!Array.isArray(response)) { + respArr = [response]; + } + const authenticationError = respArr.map((resp) => + get(resp, 'error.details.0.errors.0.errorCode.authenticationError'), + ); + if ( + // https://developers.google.com/google-ads/api/docs/oauth/2sv + authenticationError.includes('TWO_STEP_VERIFICATION_NOT_ENROLLED') || + // https://developers.google.com/google-ads/api/docs/common-errors#:~:text=this%20for%20you.-,CUSTOMER_NOT_FOUND,-Summary + authenticationError.includes('CUSTOMER_NOT_FOUND') + ) { + return AUTH_STATUS_INACTIVE; + } + return REFRESH_TOKEN; + } + if (status === 403) { + // ACCESS_DENIED + return AUTH_STATUS_INACTIVE; + } + return ''; +}; + module.exports = { populateConsentFromConfig, UNSPECIFIED_CONSENT, @@ -115,4 +145,5 @@ module.exports = { GOOGLE_ALLOWED_CONSENT_STATUS, finaliseConsent, finaliseAnalyticsConsents, + getAuthErrCategory, }; diff --git a/src/v0/util/index.js b/src/v0/util/index.js index 12b8d4dd7e..e1fe8ee942 100644 --- a/src/v0/util/index.js +++ b/src/v0/util/index.js @@ -171,6 +171,20 @@ const isDefinedNotNullNotEmpty = (value) => const removeUndefinedNullEmptyExclBoolInt = (obj) => lodash.pickBy(obj, isDefinedNotNullNotEmpty); +/** + * Function to remove empty key ("") from payload + * @param {*} payload {"key1":"a","":{"id":1}} + * @returns // {"key1":"a"} + */ +const removeEmptyKey = (payload) => { + const rawPayload = payload; + const key = ''; + if (Object.prototype.hasOwnProperty.call(rawPayload, key)) { + delete rawPayload['']; + } + return rawPayload; +}; + /** * Recursively removes undefined, null, empty objects, and empty arrays from the given object at all levels. * @param {*} obj @@ -844,6 +858,19 @@ function formatValues(formattedVal, formattingType, typeFormat, integrationsObj) curFormattedVal = formattedVal.trim(); } }, + isFloat: () => { + if (isDefinedAndNotNull(formattedVal)) { + curFormattedVal = parseFloat(formattedVal); + if (Number.isNaN(curFormattedVal)) { + throw new InstrumentationError('Invalid float value'); + } + } + }, + removeSpacesAndDashes: () => { + if (typeof formattedVal === 'string') { + curFormattedVal = formattedVal.replace(/ /g, '').replace(/-/g, ''); + } + }, }; if (formattingType in formattingFunctions) { @@ -1141,7 +1168,7 @@ const getDestinationExternalIDInfoForRetl = (message, destination) => { if (externalIdArray) { externalIdArray.forEach((extIdObj) => { const { type, id } = extIdObj; - if (type.includes(`${destination}-`)) { + if (type?.includes(`${destination}-`)) { destinationExternalId = id; objectType = type.replace(`${destination}-`, ''); identifierType = extIdObj.identifierType; @@ -1168,7 +1195,7 @@ const getDestinationExternalIDObjectForRetl = (message, destination) => { // some stops the execution when the element is found externalIdArray.some((extIdObj) => { const { type } = extIdObj; - if (type.includes(`${destination}-`)) { + if (type?.includes(`${destination}-`)) { obj = extIdObj; return true; } @@ -1606,16 +1633,6 @@ function removeHyphens(str) { return str.replace(/-/g, ''); } -function isCdkDestination(event) { - // TODO: maybe dont need all these checks in place - return ( - event.destination && - event.destination.DestinationDefinition && - event.destination.DestinationDefinition.Config && - event.destination.DestinationDefinition.Config.cdkEnabled - ); -} - /** * This function helps to remove any invalid object values from the config generated by dynamicForm, * dynamicCustomForm, and dynamicSelectForm web app form elements. @@ -2251,6 +2268,27 @@ const validateEventAndLowerCaseConversion = (event, isMandatory, convertToLowerC const applyCustomMappings = (message, mappings) => JsonTemplateEngine.createAsSync(mappings, { defaultPathType: PathType.JSON }).evaluate(message); +const applyJSONStringTemplate = (message, template) => + JsonTemplateEngine.createAsSync(template.replace(/{{/g, '${').replace(/}}/g, '}'), { + defaultPathType: PathType.JSON, + }).evaluate(message); + +/** + * Gets url path omitting the hostname & protocol + * + * **Note**: + * - This should only be used when there are no dynamic paths in URL + * @param {*} inputUrl + * @returns + */ +const getRelativePathFromURL = (inputUrl) => { + if (isValidUrl(inputUrl)) { + const url = new URL(inputUrl); + return url.pathname; + } + return inputUrl; +}; + // ======================================================================== // EXPORTS // ======================================================================== @@ -2260,6 +2298,7 @@ module.exports = { addExternalIdToTraits, adduserIdFromExternalId, applyCustomMappings, + applyJSONStringTemplate, base64Convertor, batchMultiplexedEvents, checkEmptyStringInarray, @@ -2313,7 +2352,6 @@ module.exports = { hashToSha256, isAppleFamily, isBlank, - isCdkDestination, isDefined, isDefinedAndNotNull, isDefinedAndNotNullAndNotEmpty, @@ -2371,4 +2409,6 @@ module.exports = { removeDuplicateMetadata, combineBatchRequestsWithSameJobIds, validateEventAndLowerCaseConversion, + getRelativePathFromURL, + removeEmptyKey, }; diff --git a/src/v0/util/index.test.js b/src/v0/util/index.test.js index c34d513325..a8d13ab873 100644 --- a/src/v0/util/index.test.js +++ b/src/v0/util/index.test.js @@ -9,6 +9,7 @@ const { combineBatchRequestsWithSameJobIds, validateEventAndLowerCaseConversion, } = require('./index'); +const exp = require('constants'); // Names of the utility functions to test const functionNames = [ @@ -690,3 +691,47 @@ describe('extractCustomFields', () => { }); }); }); + +describe('applyJSONStringTemplate', () => { + it('should apply JSON string template to the payload', () => { + const payload = { + domain: 'abc', + }; + const template = '`https://{{$.domain}}.com`'; + + const result = utilities.applyJSONStringTemplate(payload, template); + expect(result).toEqual('https://abc.com'); + }); + + it('should apply JSON string template to the payload multiple times', () => { + const payload = { + domain: 'abc', + subdomain: 'def', + }; + const template = '`https://{{$.subdomain}}.{{$.domain}}.com`'; + + const result = utilities.applyJSONStringTemplate(payload, template); + expect(result).toEqual('https://def.abc.com'); + }); +}); + +describe('get relative path from url', () => { + test('valid url', () => { + expect(utilities.getRelativePathFromURL('https://google.com/a/b/c')).toEqual('/a/b/c'); + }); + test('valid url with query parameters', () => { + expect(utilities.getRelativePathFromURL('https://google.com/a/b/c?q=1&n=2')).toEqual('/a/b/c'); + }); + test('normal string', () => { + expect(utilities.getRelativePathFromURL('s=1&n=2')).toEqual('s=1&n=2'); + }); + test('undefined', () => { + expect(utilities.getRelativePathFromURL(undefined)).toEqual(undefined); + }); + test('number', () => { + expect(utilities.getRelativePathFromURL(1)).toEqual(1); + }); + test('null', () => { + expect(utilities.getRelativePathFromURL(null)).toEqual(null); + }); +}); diff --git a/src/v0/util/tags.js b/src/v0/util/tags.js index dce8c0a338..1fdb5ddef2 100644 --- a/src/v0/util/tags.js +++ b/src/v0/util/tags.js @@ -24,7 +24,6 @@ const MODULES = { const IMPLEMENTATIONS = { NATIVE: 'native', - CDK_V1: 'cdkV1', CDK_V2: 'cdkV2', }; diff --git a/src/v1/destinations/bloomreach_catalog/networkHandler.js b/src/v1/destinations/bloomreach_catalog/networkHandler.js new file mode 100644 index 0000000000..1fb987b840 --- /dev/null +++ b/src/v1/destinations/bloomreach_catalog/networkHandler.js @@ -0,0 +1,85 @@ +const { TransformerProxyError } = require('../../../v0/util/errorTypes'); +const { proxyRequest, prepareProxyRequest } = require('../../../adapters/network'); +const { + processAxiosResponse, + getDynamicErrorType, +} = require('../../../adapters/utils/networkUtils'); +const { isHttpStatusSuccess } = require('../../../v0/util/index'); +const tags = require('../../../v0/util/tags'); + +// Catalog response +// [ +// { +// "errors": { +// "properties": [ +// "Fields [field1, field2] are not properly defined." +// ] +// }, +// "queued": false, +// "success": false +// }, +// { +// "success" : "True", +// "queued" : "True", +// }, +// ] +const checkIfEventIsAbortableAndExtractErrorMessage = (element) => { + if (element.success) { + return { isAbortable: false, errorMsg: '' }; + } + + const errorMsg = Object.values(element.errors || {}) + .flat() + .join(', '); + + return { isAbortable: true, errorMsg }; +}; + +const responseHandler = (responseParams) => { + const { destinationResponse, rudderJobMetadata } = responseParams; + + const message = '[BLOOMREACH_CATALOG Response V1 Handler] - Request Processed Successfully'; + const responseWithIndividualEvents = []; + const { response, status } = destinationResponse; + + if (isHttpStatusSuccess(status)) { + // check for Partial Event failures and Successes + response.forEach((event, idx) => { + const proxyOutput = { + statusCode: 200, + error: 'success', + metadata: rudderJobMetadata[idx], + }; + // update status of partial event if abortable + const { isAbortable, errorMsg } = checkIfEventIsAbortableAndExtractErrorMessage(event); + if (isAbortable) { + proxyOutput.error = errorMsg; + proxyOutput.statusCode = 400; + } + responseWithIndividualEvents.push(proxyOutput); + }); + return { + status, + message, + destinationResponse, + response: responseWithIndividualEvents, + }; + } + throw new TransformerProxyError( + `BLOOMREACH_CATALOG: Error encountered in transformer proxy V1`, + status, + { + [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), + }, + destinationResponse, + '', + responseWithIndividualEvents, + ); +}; +function networkHandler() { + this.proxy = proxyRequest; + this.processAxiosResponse = processAxiosResponse; + this.prepareProxy = prepareProxyRequest; + this.responseHandler = responseHandler; +} +module.exports = { networkHandler }; diff --git a/src/v1/destinations/hs/networkHandler.ts b/src/v1/destinations/hs/networkHandler.ts new file mode 100644 index 0000000000..8dd22b465f --- /dev/null +++ b/src/v1/destinations/hs/networkHandler.ts @@ -0,0 +1,148 @@ +import { TransformerProxyError } from '../../../v0/util/errorTypes'; +import { prepareProxyRequest, proxyRequest } from '../../../adapters/network'; +import { isHttpStatusSuccess, getAuthErrCategoryFromStCode } from '../../../v0/util/index'; +import { DeliveryV1Response, DeliveryJobState } from '../../../types/index'; + +import { processAxiosResponse, getDynamicErrorType } from '../../../adapters/utils/networkUtils'; + +const tags = require('../../../v0/util/tags'); + +/** + * + * @param results + * @param rudderJobMetadata + * @param destinationConfig + * @returns boolean + */ + +const findFeatureandVersion = (response, rudderJobMetadata, destinationConfig) => { + const { results, errors } = response; + if (Array.isArray(rudderJobMetadata) && rudderJobMetadata.length === 1) { + return 'singleEvent'; + } + if (destinationConfig?.apiVersion === 'legacyApi') { + return 'legacyApiWithMultipleEvents'; + } + if (destinationConfig?.apiVersion === 'newApi') { + if (Array.isArray(results) && results.length === rudderJobMetadata.length) + return 'newApiWithMultipleEvents'; + + if ( + Array.isArray(results) && + results.length !== rudderJobMetadata.length && + Array.isArray(errors) && + results.length + errors.length === rudderJobMetadata.length + ) + return 'newApiWithMultipleEventsAndErrors'; + } + return 'unableToFindVersionWithMultipleEvents'; +}; + +const populateResponseWithDontBatch = (rudderJobMetadata, response) => { + const errorMessage = JSON.stringify(response); + const responseWithIndividualEvents: DeliveryJobState[] = []; + + rudderJobMetadata.forEach((metadata) => { + responseWithIndividualEvents.push({ + statusCode: 500, + metadata: { ...metadata, dontBatch: true }, + error: errorMessage, + }); + }); + return responseWithIndividualEvents; +}; + +type Response = { + status?: string; + results?: Array; + errors?: Array; + startedAt?: Date; + completedAt?: Date; + message?: string; + correlationId?: string; + failureMessages?: Array; +}; + +const responseHandler = (responseParams) => { + const { destinationResponse, rudderJobMetadata, destinationRequest } = responseParams; + const successMessage = `[HUBSPOT Response V1 Handler] - Request Processed Successfully`; + const failureMessage = + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation'; + const responseWithIndividualEvents: DeliveryJobState[] = []; + const { response, status } = destinationResponse; + + if (isHttpStatusSuccess(status)) { + // populate different response for each event + const destResponse = response as Response; + let proxyOutputObj: DeliveryJobState; + const featureAndVersion = findFeatureandVersion( + destResponse, + rudderJobMetadata, + destinationRequest?.destinationConfig, + ); + switch (featureAndVersion) { + case 'singleEvent': + proxyOutputObj = { + statusCode: status, + metadata: rudderJobMetadata[0], + error: JSON.stringify(destResponse), + }; + responseWithIndividualEvents.push(proxyOutputObj); + break; + case 'newApiWithMultipleEvents': + rudderJobMetadata.forEach((metadata: any, index: string | number) => { + proxyOutputObj = { + statusCode: 200, + metadata, + error: JSON.stringify(destResponse.results?.[index]), + }; + responseWithIndividualEvents.push(proxyOutputObj); + }); + break; + default: + rudderJobMetadata.forEach((metadata) => { + proxyOutputObj = { + statusCode: 200, + metadata, + error: 'success', + }; + responseWithIndividualEvents.push(proxyOutputObj); + }); + break; + } + return { + status, + message: successMessage, + response: responseWithIndividualEvents, + } as DeliveryV1Response; + } + + // At least one event in the batch is invalid. + if (status === 400 && Array.isArray(rudderJobMetadata) && rudderJobMetadata.length > 1) { + // sending back 500 for retry only when events came in a batch + return { + status: 500, + message: failureMessage, + response: populateResponseWithDontBatch(rudderJobMetadata, response), + } as DeliveryV1Response; + } + throw new TransformerProxyError( + failureMessage, + status, + { + [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), + }, + destinationResponse, + getAuthErrCategoryFromStCode(status), + response, + ); +}; + +function networkHandler(this: any) { + this.prepareProxy = prepareProxyRequest; + this.proxy = proxyRequest; + this.processAxiosResponse = processAxiosResponse; + this.responseHandler = responseHandler; +} + +module.exports = { networkHandler }; diff --git a/src/v1/destinations/zoho/networkHandler.js b/src/v1/destinations/zoho/networkHandler.js new file mode 100644 index 0000000000..2ceb0bbdf3 --- /dev/null +++ b/src/v1/destinations/zoho/networkHandler.js @@ -0,0 +1,141 @@ +const { TransformerProxyError } = require('../../../v0/util/errorTypes'); +const { proxyRequest, prepareProxyRequest } = require('../../../adapters/network'); +const { + processAxiosResponse, + getDynamicErrorType, +} = require('../../../adapters/utils/networkUtils'); +const { isHttpStatusSuccess, getAuthErrCategoryFromStCode } = require('../../../v0/util/index'); +const tags = require('../../../v0/util/tags'); + +/** + * upsert response : + + { + "data": [ + { + "code": "INVALID_DATA", + "details": { + "expected_data_type": "integer", + "api_name": "No_of_Employees", + "json_path": "$.data[0].No_of_Employees" + }, + "message": "invalid data", + "status": "error" + }, + { + "code": "SUCCESS", + "duplicate_field": "Email", + "action": "update", + "details": { + "Modified_Time": "2024-07-14T10:54:15+05:30", + "Modified_By": { + "name": "dummy user", + "id": "724445000000323001" + }, + "Created_Time": "2024-07-01T21:25:36+05:30", + "id": "724445000000349039", + "Created_By": { + "name": "dummy user", + "id": "724445000000323001" + } + }, + "message": "record updated", + "status": "success" + } + ] +} + +* delete response : + + { + "data": [ + { + "code": "SUCCESS", + "details": { + "id": "724445000000445001" + }, + "message": "record deleted", + "status": "success" + }, + { + "code": "INVALID_DATA", + "details": { + "id": "724445000000323001" + }, + "message": "record not deleted", + "status": "error" + } + ] +} + */ + +const checkIfEventIsAbortableAndExtractErrorMessage = (element) => { + if (element.status === 'success') { + return { isAbortable: false, errorMsg: '' }; + } + + const errorMsg = `message: ${element.messaege} ${JSON.stringify(element.details)}`; + return { isAbortable: true, errorMsg }; +}; + +const responseHandler = (responseParams) => { + const { destinationResponse, rudderJobMetadata } = responseParams; + + const message = '[ZOHO Response V1 Handler] - Request Processed Successfully'; + const responseWithIndividualEvents = []; + const { response, status } = destinationResponse; + if (isHttpStatusSuccess(status)) { + // check for Partial Event failures and Successes + const { data } = response; + data.forEach((event, idx) => { + const proxyOutput = { + statusCode: 200, + metadata: rudderJobMetadata[idx], + error: 'success', + }; + // update status of partial event if abortable + const { isAbortable, errorMsg } = checkIfEventIsAbortableAndExtractErrorMessage(event); + if (isAbortable) { + proxyOutput.statusCode = 400; + proxyOutput.error = errorMsg; + } + responseWithIndividualEvents.push(proxyOutput); + }); + return { + status, + message, + destinationResponse, + response: responseWithIndividualEvents, + }; + } + + if (response?.code === 'INVALID_TOKEN') { + throw new TransformerProxyError( + `Zoho: Error transformer proxy v1 during Zoho response transformation. ${response.message}`, + 500, + { + [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(500), + }, + destinationResponse, + getAuthErrCategoryFromStCode(status), + response.message, + ); + } + throw new TransformerProxyError( + `ZOHO: Error encountered in transformer proxy V1`, + status, + { + [tags.TAG_NAMES.ERROR_TYPE]: getDynamicErrorType(status), + }, + destinationResponse, + '', + responseWithIndividualEvents, + ); +}; +function networkHandler() { + this.proxy = proxyRequest; + this.processAxiosResponse = processAxiosResponse; + this.prepareProxy = prepareProxyRequest; + this.responseHandler = responseHandler; +} +module.exports = { networkHandler }; diff --git a/src/v0/sources/braze/ignore.json b/src/v1/sources/braze/ignore.json similarity index 100% rename from src/v0/sources/braze/ignore.json rename to src/v1/sources/braze/ignore.json diff --git a/src/v0/sources/braze/mapping.json b/src/v1/sources/braze/mapping.json similarity index 100% rename from src/v0/sources/braze/mapping.json rename to src/v1/sources/braze/mapping.json diff --git a/src/v0/sources/braze/transform.js b/src/v1/sources/braze/transform.js similarity index 79% rename from src/v0/sources/braze/transform.js rename to src/v1/sources/braze/transform.js index e3d7200023..771c5887b3 100644 --- a/src/v0/sources/braze/transform.js +++ b/src/v1/sources/braze/transform.js @@ -3,17 +3,15 @@ const get = require('get-value'); const path = require('path'); const fs = require('fs'); const { TransformationError } = require('@rudderstack/integrations-lib'); -const { formatTimeStamp, removeUndefinedAndNullValues } = require('../../util'); -const Message = require('../message'); +const { + formatTimeStamp, + removeUndefinedAndNullValues, + getHashFromArray, +} = require('../../../v0/util'); +const Message = require('../../../v0/sources/message'); // import mapping json using JSON.parse to preserve object key order const mapping = JSON.parse(fs.readFileSync(path.resolve(__dirname, './mapping.json'), 'utf-8')); - -// if we need to map braze event name to something else. blank as of now -const eventNameMap = JSON.parse( - fs.readFileSync(path.resolve(__dirname, './eventMapping.json'), 'utf-8'), -); - // ignored properties // to be deleted from the field `event.properties` as already mapped // using mapping.json @@ -21,7 +19,7 @@ const ignoredProperties = JSON.parse( fs.readFileSync(path.resolve(__dirname, './ignore.json'), 'utf-8'), ); -const processEvent = (event) => { +const processEvent = (event, eventMapping) => { const messageType = 'track'; if (event.event_type) { @@ -32,7 +30,7 @@ const processEvent = (event) => { message.setEventType(messageType); // set event name - const eventName = eventNameMap[eventType] || eventType; + const eventName = eventMapping[eventType] || eventType; message.setEventName(eventName); // map event properties based on mapping.json @@ -68,14 +66,17 @@ const processEvent = (event) => { throw new TransformationError('Unknown event type from Braze'); }; -const process = (events) => { +const process = (inputEvent) => { + const { event, source } = inputEvent; + const { customMapping } = source.Config; + const eventMapping = getHashFromArray(customMapping, 'from', 'to', false); const responses = []; // Ref: Custom Currents Connector Partner Dev Documentation.pdf - const eventList = Array.isArray(events) && events.length > 0 ? events[0].events : events.events; - eventList.forEach((event) => { + const eventList = Array.isArray(event) && event.length > 0 ? event[0].events : event.events; + eventList.forEach((singleEvent) => { try { - const resp = processEvent(event); + const resp = processEvent(singleEvent, eventMapping); if (resp) { responses.push(removeUndefinedAndNullValues(resp)); } diff --git a/src/v1/sources/cordial/config.js b/src/v1/sources/cordial/config.js new file mode 100644 index 0000000000..764c734870 --- /dev/null +++ b/src/v1/sources/cordial/config.js @@ -0,0 +1,6 @@ +const eventsMapping = { + crdl_app_install: 'Application Installed', + crdl_app_open: 'Application Opened', +}; + +module.exports = { eventsMapping }; diff --git a/src/v1/sources/cordial/mapping.json b/src/v1/sources/cordial/mapping.json new file mode 100644 index 0000000000..1ce066e07c --- /dev/null +++ b/src/v1/sources/cordial/mapping.json @@ -0,0 +1,22 @@ +[ + { + "sourceKeys": "event._id", + "destKeys": "properties.event_id" + }, + { + "sourceKeys": "contact._id", + "destKeys": ["context.traits.userId", "userId"] + }, + { + "sourceKeys": ["event.ts", "event.ats"], + "destKeys": ["timestamp", "sentAt", "originalTimestamp"] + }, + { + "sourceKeys": "event.d", + "destKeys": "context.device" + }, + { + "sourceKeys": "contact.channels.email.address", + "destKeys": ["context.traits.email"] + } +] diff --git a/src/v1/sources/cordial/transform.js b/src/v1/sources/cordial/transform.js new file mode 100644 index 0000000000..5548efee70 --- /dev/null +++ b/src/v1/sources/cordial/transform.js @@ -0,0 +1,51 @@ +const Message = require('../../../v0/sources/message'); +const { CommonUtils } = require('../../../util/common'); +const { generateUUID, isDefinedAndNotNull } = require('../../../v0/util'); +const { eventsMapping } = require('./config'); + +const mapping = require('./mapping.json'); + +const processEvent = (inputPaylaod) => { + const message = new Message(`Cordial`); + let eventName = inputPaylaod.event?.a || inputPaylaod.event?.action; + if (eventName in eventsMapping) { + eventName = eventsMapping[eventName]; + } + message.setEventType('track'); + message.setEventName(eventName); + message.setPropertiesV2(inputPaylaod, mapping); + + const externalId = []; + // setting up cordial contact_id to externalId + if (inputPaylaod.contact.cID) { + externalId.push({ + type: 'cordialContactId', + id: inputPaylaod.contact.cID, + }); + } + message.context.externalId = externalId; + + if (!isDefinedAndNotNull(message.userId)) { + message.anonymousId = generateUUID(); + } + // Due to multiple mappings to the same destination path object some are not showing up due to which we are doing the following + message.context.traits = { ...message.context.traits, ...inputPaylaod.contact }; + message.properties = { + ...message.properties, + ...inputPaylaod.event.properties, + ...inputPaylaod.event, + }; + delete message.properties.properties; + delete message.properties.d; + // eslint-disable-next-line no-underscore-dangle + delete message.properties._id; + return message; +}; + +const process = (inputEvent) => { + const { event: events } = inputEvent; + const eventsArray = CommonUtils.toArray(events); + return eventsArray.map(processEvent); +}; + +exports.process = process; diff --git a/swagger/components/examples/processor/failure.yaml b/swagger/components/examples/processor/failure.yaml index 3c7f8c13a8..cddfd1cd21 100644 --- a/swagger/components/examples/processor/failure.yaml +++ b/swagger/components/examples/processor/failure.yaml @@ -1,40 +1,26 @@ metadata: - sourceId: '27O0bmEEx3GgfmEhZHUcPwJQVWC' - workspaceId: '27O0bhB6p5ehfOWeeZlOSsSDTLg' - namespace: '' - instanceId: '1' - sourceType: 'HTTP' - sourceCategory: '' - trackingPlanId: '' - trackingPlanVersion: 0 - sourceTpConfig: null - mergedTpConfig: null - destinationId: '2JIqVoWNvSOHa9ppKOqSo4hPuc0' - jobRunId: '' + destinationId: '2JIqVoWNvSOHa9ppKOqSoxxx' jobId: 1 - sourceBatchId: '' - sourceJobId: '' - sourceJobRunId: '' - sourceTaskId: '' - sourceTaskRunId: '' - recordId: null - destinationType: 'PINTEREST_TAG' - messageId: 'cededd59-671c-4a2e-a89a-6461ed662ab9' - oauthAccessToken: '' - messageIds: null - rudderId: '<<>>anon-id<<>>testUser' - receivedAt: '2023-01-01T14:15:41.731+05:30' eventName: 'Product Viewed' eventType: 'track' - sourceDefinitionId: '1b6gJdqOPOCadT3cddw8eidV591' - destinationDefinitionId: '' + sourceId: '2ifsnRxzoONtZeIoGxgNWsr4xx' + sourceCategory: '' + attemptNum: 0 + receivedAt: '2024-07-17T16:45:40.114+05:30' + createdAt: '2024-07-17T11:15:41.140Z' + firstAttemptedAt: '' + transformAt: 'router' + workspaceId: '2hSS1hZ8kuCpUZAAYsQucAFdxxx' + secret: null + workerAssignedTime: '2024-07-17T16:45:41.264239+05:30' + dontBatch: false + traceparent: '' statusCode: 400 -error: Random is not mapped in UI. Make sure to map the event in UI or enable the 'send as custom event' setting +error: Missing required value from 'userIdOnly' statTags: - errorCategory: 'platform' - implementation: 'cdkV2' - destType: 'PINTEREST_TAG' + errorCategory: 'dataValidation' + implementation: 'native' + destType: 'JUNE' module: 'destination' feature: 'processor' - destinationId: '2JIqVoWNvSOHa9ppKOqSo4hPuc0' - workspaceId: '27O0bhB6p5ehfOWeeZlOSsSDTLg' + destinationId: '2JIqVoWNvSOHa9ppKOqSoxxx' diff --git a/swagger/components/examples/processor/success.yaml b/swagger/components/examples/processor/success.yaml index 08924c8813..7d5325ccf5 100644 --- a/swagger/components/examples/processor/success.yaml +++ b/swagger/components/examples/processor/success.yaml @@ -1,72 +1,37 @@ output: body: JSON: - event_time: 1672564081 - event_source_url: https://www.website.com/product/path - action_source: offline - event_id: 6ee69cf1-ce37-4287-9a0f-8b8453219082 - app_id: '' - advertiser_id: 'advertiserId123' - user_data: - em: - - b9ecbd1d999a0f17d442a08971caeea92d770dba89ac900688ecede233d652df - ph: - - 92b5072176e723878b5e06ff3ca61898e4eb74e8c46642a0f2db800b17364ab0 - ge: - - 62c66a7a5dd70c3146618063c344e531e6d4b59e379808443ce962b3abd63c5a - ln: - - dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251 - fn: - - 9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08 - client_ip_address: '[::1]' - custom_data: - num_items: 11 - content_ids: - - '123' - contents: - - quantity: 11 - item_price: '13.49' - event_name: add_to_cart + anonymousId: 'abc123' + userId: '123' + timestamp: '2022-01-20T13:39:21.032Z' JSON_ARRAY: {} XML: {} FORM: {} version: '1' type: REST method: POST - endpoint: https://ct.pinterest.com/events/v3 + endpoint: https://api.june.so/api/identify headers: Content-Type: application/json params: {} files: {} userId: '' -metadata: - sourceId: 27O0bmEEx3GgfmEhZHUcPwJQVWC - workspaceId: 27O0bhB6p5ehfOWeeZlOSsSDTLg - namespace: '' - instanceId: '1' - sourceType: HTTP - sourceCategory: '' - trackingPlanId: '' - trackingPlanVersion: 0 - sourceTpConfig: - mergedTpConfig: - destinationId: 2JIqVoWNvSOHa9ppKOqSo4hPuc0 - jobRunId: '' - jobId: 1 - sourceBatchId: '' - sourceJobId: '' - sourceJobRunId: '' - sourceTaskId: '' - sourceTaskRunId: '' - recordId: - destinationType: PINTEREST_TAG - messageId: 6ee69cf1-ce37-4287-9a0f-8b8453219082 - oauthAccessToken: '' - messageIds: - rudderId: '<<>>anon-id<<>>testUser' - receivedAt: '2023-01-01T14:38:01.482+05:30' - eventName: Product Added - eventType: track - sourceDefinitionId: 1b6gJdqOPOCadT3cddw8eidV591 - destinationDefinitionId: '' + metadata: + userId: '<<>>12345<<>>12345' + jobId: 1 + sourceId: '2ifsnRxzoONtZeIoGxgNWsr4xx' + sourceCategory: '' + destinationId: '2JIqVoWNvSOHa9ppKOqSxxx' + attemptNum: 0 + receivedAt: '2024-07-17T16:45:40.114+05:30' + createdAt: '2024-07-17T11:15:41.140Z' + firstAttemptedAt: '' + transformAt: 'router' + workspaceId: '2hSS1hZ8kuCpUZAAYsQucAFdxxx' + secret: null + workerAssignedTime: '2024-07-17T16:45:41.264239+05:30' + dontBatch: false + traceparent: '' + eventName: 'Product Added' + eventType: 'track' statusCode: 200 diff --git a/swagger/components/examples/router/failure.yaml b/swagger/components/examples/router/failure.yaml index c592bb47cd..4f14d66701 100644 --- a/swagger/components/examples/router/failure.yaml +++ b/swagger/components/examples/router/failure.yaml @@ -1,130 +1,33 @@ metadata: - - sourceId: '27O0bmEEx3GgfmEhZHUcPwJQVWC' - workspaceId: '27O0bhB6p5ehfOWeeZlOSsSDTLg' - namespace: '' - instanceId: '1' - sourceType: 'HTTP' + - jobId: 2 + destinationId: '2JIqVoWNvSOHa9ppKOqSoxxx' + sourceId: '2ifsnRxzoONtZeIoGxgNWsr4xx' sourceCategory: '' - trackingPlanId: '' - trackingPlanVersion: 0 - sourceTpConfig: null - mergedTpConfig: null - destinationId: '2JIqVoWNvSOHa9ppKOqSo4hPuc0' - jobRunId: '' - jobId: 1 - sourceBatchId: '' - sourceJobId: '' - sourceJobRunId: '' - sourceTaskId: '' - sourceTaskRunId: '' - recordId: null - destinationType: 'PINTEREST_TAG' - messageId: 'cededd59-671c-4a2e-a89a-6461ed662ab9' - oauthAccessToken: '' - messageIds: null - rudderId: '<<>>anon-id<<>>testUser' - receivedAt: '2023-01-01T14:15:41.731+05:30' - eventName: 'Product Viewed' - eventType: 'track' - sourceDefinitionId: '1b6gJdqOPOCadT3cddw8eidV591' - destinationDefinitionId: '' + attemptNum: 0 + receivedAt: '2024-07-17T16:45:40.114+05:30' + createdAt: '2024-07-17T11:15:41.140Z' + firstAttemptedAt: '' + transformAt: 'router' + workspaceId: '2hSS1hZ8kuCpUZAAYsQucAFdxxx' + secret: null + workerAssignedTime: '2024-07-17T16:45:41.264239+05:30' + dontBatch: false + traceparent: '' destination: - ID: '2JIqVoWNvSOHa9ppKOqSo4hPuc0' - Name: 'Pinterest-test' DestinationDefinition: - ID: '1s0w2bMAleYngscZRgH1ExynlpT' - Name: 'PINTEREST_TAG' - DisplayName: 'Pinterest Tag' - Config: - cdkV2TestThreshold: 1 - cdkV2Enabled: true - destConfig: - defaultConfig: - - 'tagId' - - 'appId' - - 'advertiserId' - - 'sendingUnHashedData' - - 'enableDeduplication' - - 'deduplicationKey' - - 'customProperties' - - 'eventsMapping' - - 'enhancedMatch' - - 'blacklistedEvents' - - 'whitelistedEvents' - - 'eventFilteringOption' - web: - - 'useNativeSDK' - - 'oneTrustCookieCategories' - excludeKeys: [] - includeKeys: - - 'tagId' - - 'advertiserId' - - 'appId' - - 'customProperties' - - 'eventsMapping' - - 'enhancedMatch' - - 'enableDeduplication' - - 'deduplicationKey' - - 'blacklistedEvents' - - 'whitelistedEvents' - - 'oneTrustCookieCategories' - - 'eventFilteringOption' - saveDestinationResponse: false - secretKeys: [] - supportedSourceTypes: - - 'android' - - 'ios' - - 'web' - - 'unity' - - 'amp' - - 'cloud' - - 'warehouse' - - 'reactnative' - - 'flutter' - - 'cordova' - transformAt: 'router' - transformAtV1: 'router' - ResponseRules: {} + ID: '1s0w2bMAleYngscZRgH1Exx' + Name: 'abc_tag' Config: - advertiserId: 'advertiserId123' - appId: '' - apiVersion: 'newApi' - adAccountId: 'accountId123' - conversionToken: 'conversionToken123' - sendAsCustomEvent: false - blacklistedEvents: - - eventName: '' - customProperties: - - properties: '' - deduplicationKey: '' - enableDeduplication: false - enhancedMatch: false - eventFilteringOption: 'disable' - eventsMapping: - - from: 'Product Added' - to: 'AddToCart' - - from: 'Product Viewed' - to: 'ViewCategory' - - from: 'Product Seen' - to: 'PageVisit' - sendingUnHashedData: true - tagId: 'Techno@2020' - whitelistedEvents: - - eventName: '' - Enabled: true - WorkspaceID: '27O0bhB6p5ehfOWeeZlOSsSDTLg' - Transformations: [] - IsProcessorEnabled: true - RevisionID: '2JgW8QPyFsDvodPYShZ29XH3sKB' + apiKey: '93AEyDLvfpbRxx12' + ID: 'june123' batched: false statusCode: 400 -error: "Random is not mapped in UI. Make sure to map the event in UI or enable the 'send as custom event' setting" +error: 'Missing required value from "userIdOnly"' statTags: + destType: 'JUNE' errorCategory: 'dataValidation' - errorType: 'configuration' - destType: 'PINTEREST_TAG' - module: 'destination' - implementation: 'cdkV2' + errorType: 'instrumentation' feature: 'router' - destinationId: '2JIqVoWNvSOHa9ppKOqSo4hPuc0' - workspaceId: '27O0bhB6p5ehfOWeeZlOSsSDTLg' + implementation: 'native' + module: 'destination' + destinationId: '2JIqVoWNvSOHa9ppKOqSoxxx' diff --git a/swagger/components/examples/router/success.yaml b/swagger/components/examples/router/success.yaml index 9d0f80807d..6eeefbf595 100644 --- a/swagger/components/examples/router/success.yaml +++ b/swagger/components/examples/router/success.yaml @@ -1,71 +1,42 @@ body: JSON: - event_time: 1672564081 - event_source_url: 'https://www.website.com/product/path' - action_source: offline - event_id: '6ee69cf1-ce37-4287-9a0f-8b8453219082' - app_id: '' - advertiser_id: 'advertiserId123' - user_data: - em: - - 'b9ecbd1d999a0f17d442a08971caeea92d770dba89ac900688ecede233d652df' - ph: - - '92b5072176e723878b5e06ff3ca61898e4eb74e8c46642a0f2db800b17364ab0' - ge: - - '62c66a7a5dd70c3146618063c344e531e6d4b59e379808443ce962b3abd63c5a' - ln: - - 'dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251' - fn: - - '9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08' - client_ip_address: '[::1]' - custom_data: - num_items: 11 - content_ids: - - '123' - contents: - - quantity: 11 - item_price: '13.49' - event_name: add_to_cart + anonymousId: 'ab12' + timestamp: '2022-01-20T13:39:21.032Z' + traits: + age: 25 + email: 'johndoe@gmail.com' + name: 'John Doe' + userId: '12' JSON_ARRAY: {} XML: {} FORM: {} version: '1' type: REST method: POST -endpoint: 'https://ct.pinterest.com/events/v3' +endpoint: 'https://api.june.so/api/identify' headers: Content-Type: 'application/json' params: {} files: {} userId: '' +destination: + Config: + apiKey: '93AEyDLvfpbRxxx' + ID: 'june123' metadata: - sourceId: '27O0bmEEx3GgfmEhZHUcPwJQVWC' - workspaceId: '27O0bhB6p5ehfOWeeZlOSsSDTLg' - namespace: '' - instanceId: '1' - sourceType: HTTP - sourceCategory: '' - trackingPlanId: '' - trackingPlanVersion: 0 - sourceTpConfig: null - mergedTpConfig: null - destinationId: '2JIqVoWNvSOHa9ppKOqSo4hPuc0' - jobRunId: '' + userId: '<<>>123456<<>>123456' jobId: 1 - sourceBatchId: '' - sourceJobId: '' - sourceJobRunId: '' - sourceTaskId: '' - sourceTaskRunId: '' - recordId: null - destinationType: PINTEREST_TAG - messageId: '6ee69cf1-ce37-4287-9a0f-8b8453219082' - oauthAccessToken: '' - messageIds: null - rudderId: '<<>>anon-id<<>>testUser' - receivedAt: '2023-01-01T14:38:01.482+05:30' - eventName: Product Added - eventType: track - sourceDefinitionId: '1b6gJdqOPOCadT3cddw8eidV591' - destinationDefinitionId: '' + sourceId: '2ifsnRxzoONtZeIoGxgNWsr4xx' + sourceCategory: '' + destinationId: '2JIqVoWNvSOHa9ppKOqSoxxx' + attemptNum: 0 + receivedAt: '2024-07-17T16:45:40.114+05:30' + createdAt: '2024-07-17T11:15:41.140Z' + firstAttemptedAt: '' + transformAt: 'router' + workspaceId: '2hSS1hZ8kuCpUZAAYsQucAFdxxx' + secret: null + workerAssignedTime: '2024-07-17T16:45:41.264239+05:30' + dontBatch: false + traceparent: '' statusCode: 200 diff --git a/swagger/components/schemas/request.yaml b/swagger/components/schemas/request.yaml new file mode 100644 index 0000000000..c0f9117bf8 --- /dev/null +++ b/swagger/components/schemas/request.yaml @@ -0,0 +1,5 @@ +title: request +type: object +parameters: + query: + type: string diff --git a/swagger/components/schemas/routerTransformationRequest.yaml b/swagger/components/schemas/routerTransformationRequest.yaml index 90d29997cc..2ae2380c51 100644 --- a/swagger/components/schemas/routerTransformationRequest.yaml +++ b/swagger/components/schemas/routerTransformationRequest.yaml @@ -7,7 +7,7 @@ properties: type: object properties: request: - type: object + $ref: './request.yaml' message: type: object metadata: diff --git a/test/__tests__/appcenter_source.test.js b/test/__tests__/appcenter_source.test.js deleted file mode 100644 index a3745f881e..0000000000 --- a/test/__tests__/appcenter_source.test.js +++ /dev/null @@ -1,33 +0,0 @@ -const integration = "appcenter"; -const name = "Appcenter"; - -const fs = require("fs"); -const path = require("path"); -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -/* Source Code has randomm ID generation logic. - For Some of the test cases deleting this random ID won't work as it getting hashed -*/ - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { -// try { - const output = await transformer.process(input); -// expect(output).toEqual(expectedData[index]); -// } catch (error) { -// expect(error.message).toEqual(expectedData[index].message); -// } - }); -}); diff --git a/test/__tests__/appsflyer_source.test.js b/test/__tests__/appsflyer_source.test.js deleted file mode 100644 index de9c6d61e3..0000000000 --- a/test/__tests__/appsflyer_source.test.js +++ /dev/null @@ -1,31 +0,0 @@ -const integration = "appsflyer"; -const name = "Appsflyer"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - delete output.anonymousId; - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/braze_source.test.js b/test/__tests__/braze_source.test.js deleted file mode 100644 index 009b650578..0000000000 --- a/test/__tests__/braze_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "braze"; -const name = "Braze"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, () => { - try { - const output = transformer.process(input); - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/canny_source.test.js b/test/__tests__/canny_source.test.js deleted file mode 100644 index efd664ab4b..0000000000 --- a/test/__tests__/canny_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "canny"; -const name = "Canny"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/cdk_postMapper/autopilot.test.js b/test/__tests__/cdk_postMapper/autopilot.test.js deleted file mode 100644 index 0dde490017..0000000000 --- a/test/__tests__/cdk_postMapper/autopilot.test.js +++ /dev/null @@ -1,60 +0,0 @@ -const { - trackPostMapper, - identifyPostMapper -} = require("../../../src/cdk/v1/autopilot/transform"); - -describe("Unit Test for track postMapper", () => { - it("should update the rudderContext with correct endpoint", () => { - const message = { traits: { email: "test@email.com" } }; - const destination = { Config: { triggerId: "sample-trigger-id" } }; - const event = { message, destination }; - const expectedRudderContext = { - endpoint: `https://api2.autopilothq.com/v1/trigger/sample-trigger-id/contact/test@email.com` - }; - const rudderContext = {}; - trackPostMapper(event, {}, rudderContext); - expect(rudderContext).toEqual(expectedRudderContext); - }); -}); - -describe("Unit Test for identify postMapper", () => { - it("should delete fields from traits", () => { - const message = { - traits: { email: "test@email.com", firstName: "firstName" } - }; - const destination = {}; - const event = { message, destination }; - const payload = { someKey: "here" }; - const expected = { contact: { someKey: "here" } }; - const resp = identifyPostMapper(event, payload, {}); - expect(resp).toEqual(expected); - }); - - it("should delete fields from traits and keep custom values", () => { - const message = { - traits: { - email: "test@email.com", - firstName: "firstName", - something: "custom" - } - }; - const destination = {}; - const event = { message, destination }; - const payload = { someKey: "here" }; - const expected = { - contact: { someKey: "here", custom: { something: "custom" } } - }; - const resp = identifyPostMapper(event, payload, {}); - expect(resp).toEqual(expected); - }); - - it("should not throw error on empty traits", () => { - const message = { traits: {} }; - const destination = {}; - const event = { message, destination }; - const payload = { someKey: "here" }; - const expected = { contact: { someKey: "here" } }; - const resp = identifyPostMapper(event, payload, {}); - expect(resp).toEqual(expected); - }); -}); diff --git a/test/__tests__/cdk_postMapper/dcm_floodlight.test.js b/test/__tests__/cdk_postMapper/dcm_floodlight.test.js deleted file mode 100644 index 9bf7563a8d..0000000000 --- a/test/__tests__/cdk_postMapper/dcm_floodlight.test.js +++ /dev/null @@ -1,106 +0,0 @@ -const { postMapper } = require("../../../src/cdk/v1/dcm_floodlight/transform"); - -describe("Unit Test for postMapper", () => { - it("should update the rudderContext with userAgent and valid endpoint", () => { - const message = { - event: "Checkout Started", - type: "track", - properties: { - orderId: 1234, - quantity: 45, - revenue: 800 - }, - context: { - device: { - advertisingId: "2a3e36d172-5e28-45a1-9eda-ce22a3e36d1a" - }, - userAgent: - "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.88 Safari/537.36" - } - }; - const destination = { - Config: { - advertiserId: "12649566", - activityTag: "", - groupTag: "", - conversionEvents: [ - { - customVariables: [ - { - from: "", - to: "" - } - ], - eventName: "Sign up Completed", - floodlightActivityTag: "signu0", - floodlightGroupTag: "conv01", - salesTag: false - }, - { - customVariables: [ - { - from: "1", - to: "rudder1" - }, - { - from: "2", - to: "akash1" - } - ], - eventName: "Order Complete", - floodlightActivityTag: "order0", - floodlightGroupTag: "conv000", - salesTag: false - }, - { - eventName: "Checkout Started", - floodlightActivityTag: "check0", - floodlightGroupTag: "conv0000", - salesTag: true - }, - { - customVariables: [ - { - from: "1", - to: "rudder2" - }, - { - from: "2", - to: "akash2" - }, - { - from: "3", - to: "friendlyName2" - }, - { - from: "4", - to: "name2" - } - ], - eventName: "Purchase", - floodlightActivityTag: "Pur0", - floodlightGroupTag: "conv111", - salesTag: false - } - ] - } - }; - const event = { message, destination }; - const payload = { - dc_rdid: "T0T0T072-5e28-45a1-9eda-ce22a3e36d1a", - ord: 111, - qty: 999999, - cost: 800, - dc_lat: "true" - }; - const expectedRudderContext = { - userAgent: - "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.88 Safari/537.36", - endpoint: - "https://ad.doubleclick.net/ddm/activity/src=12649566;cat=check0;type=conv0000;dc_rdid=T0T0T072-5e28-45a1-9eda-ce22a3e36d1a;ord=111;qty=999999;cost=800;dc_lat=1" - }; - const rudderContext = {}; - postMapper(event, payload, rudderContext); - expect(rudderContext).toEqual(expectedRudderContext); - }); -}); diff --git a/test/__tests__/cdk_postMapper/heap.test.js b/test/__tests__/cdk_postMapper/heap.test.js deleted file mode 100644 index 440cdb2f6b..0000000000 --- a/test/__tests__/cdk_postMapper/heap.test.js +++ /dev/null @@ -1,27 +0,0 @@ -const { commonPostMapper } = require("../../../src/cdk/v1/heap/transform"); - -describe("Unit test cases for heap common post mapper", () => { - let payload, event, rudderContext; - beforeEach(() => { - payload = { should: "remain", properties: { idempotencyKey: "someKey" } }; - event = { message: {}, destination: { Config: { appId: "app_id" } } }; - rudderContext = {}; - }); - - it("should delete idempotency key from mappedPayload", async () => { - const expectedOutput = { - should: "remain", - app_id: "app_id", - properties: {} - }; - await expect( - commonPostMapper(event, payload, rudderContext) - ).resolves.toMatchObject(expectedOutput); - }); - - it("should mutate the mappedPayload on calling postMapper", async () => { - await expect( - commonPostMapper(event, payload, rudderContext) - ).resolves.toMatchObject({ should: "remain", properties: {} }); - }); -}); diff --git a/test/__tests__/cdk_postMapper/kochava.test.js b/test/__tests__/cdk_postMapper/kochava.test.js deleted file mode 100644 index 67f09faff3..0000000000 --- a/test/__tests__/cdk_postMapper/kochava.test.js +++ /dev/null @@ -1,110 +0,0 @@ -const { - processExtraPayloadParams -} = require("../../../src/cdk/v1/kochava/transform"); - -describe("Unit Test for kochava postMapper", () => { - it("should set all the default values", () => { - const event = { - destination: { - Config: { - apiKey: "" - }, - DestinationDefinition: { - Config: { - cdkEnabled: true - }, - DisplayName: "Kochava", - ID: "1WTpBSTiL3iAUHUdW7rHT4sawgU", - Name: "KOCHAVA" - }, - Enabled: true, - ID: "1WTpIHpH7NTBgjeiUPW1kCUgZGI", - Name: "kochava test", - Transformations: [] - }, - message: { - anonymousId: "sampath", - channel: "web", - context: {}, - event: "product added", - properties: { name: "sampath" }, - type: "track", - event: "eventName" - } - }; - const expected = { - data: { - app_tracking_transparency: { - att: false - }, - device_ver: "", - device_ids: { - idfa: "", - idfv: "", - adid: "", - android_id: "" - }, - event_name: "eventName", - device_ua: "", - currency: "USD" - } - }; - const resp = processExtraPayloadParams(event, {}, {}); - expect(resp).toEqual(expected); - }); - - it("should set all the default values and os_version as empty string", () => { - const event = { - destination: { - Config: { - apiKey: "" - }, - DestinationDefinition: { - Config: { - cdkEnabled: true - }, - DisplayName: "Kochava", - ID: "1WTpBSTiL3iAUHUdW7rHT4sawgU", - Name: "KOCHAVA" - }, - Enabled: true, - ID: "1WTpIHpH7NTBgjeiUPW1kCUgZGI", - Name: "kochava test", - Transformations: [] - }, - message: { - anonymousId: "sampath", - channel: "web", - context: { - os: { - version: "" - } - }, - event: "product added", - properties: { name: "sampath" }, - type: "track", - event: "eventName" - } - }; - const expected = { - data: { - app_tracking_transparency: { - att: false - }, - device_ver: "", - device_ids: { - idfa: "", - idfv: "", - adid: "", - android_id: "" - }, - event_name: "eventName", - device_ua: "", - currency: "USD", - os_version: "" - } - }; - const resp = processExtraPayloadParams(event, {}, {}); - expect(resp).toEqual(expected); - }); -}); diff --git a/test/__tests__/cdk_postMapper/lytics.test.js b/test/__tests__/cdk_postMapper/lytics.test.js deleted file mode 100644 index 0b005155dc..0000000000 --- a/test/__tests__/cdk_postMapper/lytics.test.js +++ /dev/null @@ -1,14 +0,0 @@ -const { cleanResponse } = require("../../../src/cdk/v1/lytics/transform"); - -describe("Test for Lytics common post mapper", () => { - it("should remove both first name and last name from mappedPayload", () => { - const mappedPayload = { - firstname: "somename", - lastName: "lastName", - some: "otherKey" - }; - const resp = cleanResponse({}, mappedPayload, {}); - const expected = { some: "otherKey" }; - expect(resp).toEqual(expected); - }); -}); diff --git a/test/__tests__/cdk_postMapper/new_relic.test.js b/test/__tests__/cdk_postMapper/new_relic.test.js deleted file mode 100644 index 3aab6aaf67..0000000000 --- a/test/__tests__/cdk_postMapper/new_relic.test.js +++ /dev/null @@ -1,86 +0,0 @@ -const { even } = require("is"); -const { commonPostMapper } = require("../../../src/cdk/v1/new_relic/transform"); - -describe("Unit test cases for new_relic common post mapper", () => { - let payload, event, rudderContext, expectedOutput; - beforeEach(() => { - payload = { - event: "first", - timestamp: 1580602989, - abc: "123", - key: 124, - auto: true, - eventType: "standard" - }; - event = { - message: { - userId: "identified user id", - anonymousId: "anon-id-new", - context: { - traits: { trait1: "new-val" }, - ip: "14.5.67.21", - library: { name: "http" } - } - }, - destination: { - Config: { - accountId: "12345", - insertKey: "11111122702j2a2U2K2C7H", - dataCenter: "us", - customEventType: "", - sendDeviceContext: false, - sendUserIdanonymousId: true - } - } - }; - rudderContext = {}; - expectedOutput = { - event: "first", - timestamp: 1580602989, - abc: "123", - key: 124, - eventType: "rudderstack", - userId: "identified user id", - anonymousId: "anon-id-new", - "'auto'": "true" - }; - }); - - it('If user did not provid a eventType name, then we will include "rudderstack" in the payload directly', () => { - // event is manupulated to suit the test-cases - event.destination.Config.sendDeviceContext = false; - expect(commonPostMapper(event, payload, rudderContext)).toEqual( - expectedOutput - ); - }); - - it("If user provides a eventType name, then we will include it in the payload directly", () => { - event.destination.Config.customEventType = "abc"; - // expectedOutput is also manupulated to suit the expectation of the test-case - expectedOutput.eventType = "abc"; - expect(commonPostMapper(event, payload, rudderContext)).toEqual( - expectedOutput - ); - }); - it('when "sendUserIdanonymousId" is false, we do not send userId or anonymousId ', () => { - event.destination.Config.sendUserIdanonymousId = false; - event.destination.Config.customEventType = "abc"; - expectedOutput.eventType = "abc"; - delete expectedOutput.userId; - delete expectedOutput.anonymousId; - expect(commonPostMapper(event, payload, rudderContext)).toEqual( - expectedOutput - ); - }); - - it('when "sendDeviceContext" is true, we will flatten the context and merge with the payload ', () => { - event.destination.Config.sendUserIdanonymousId = true; - event.destination.Config.sendDeviceContext = true; - expectedOutput["traits.trait1"] = "new-val"; - expectedOutput.ip = "14.5.67.21"; - expectedOutput["library.name"] = "http"; - expect(commonPostMapper(event, payload, rudderContext)).toEqual( - expectedOutput - ); - }); -}); diff --git a/test/__tests__/cdk_postMapper/zapier.test.js b/test/__tests__/cdk_postMapper/zapier.test.js deleted file mode 100644 index c12b737afd..0000000000 --- a/test/__tests__/cdk_postMapper/zapier.test.js +++ /dev/null @@ -1,37 +0,0 @@ -const { commonPostMapper } = require("../../../src/cdk/v1/zapier/transform"); - -describe("Unit test cases for zapier common post mapper", () => { - it("should update the rudderContext with default endpoint", () => { - const message = { - type: "track", - userId: "identified user id", - anonymousId: "anon-id-new", - event: "Product Purchased new", - properties: { - name: "Shirt", - revenue: 4.99 - }, - context: { - ip: "14.5.67.21", - library: { - name: "http" - } - }, - timestamp: "2020-02-02T00:23:09.544Z" - }; - const destination = { - Config: { - zapUrl: "zapier.abcd-hook", - trackEventsToZap: {}, - pageScreenEventsToZap: {} - } - }; - const event = { message, destination }; - const expectedRudderContext = { - zapUrl: `zapier.abcd-hook` - }; - const rudderContext = {}; - commonPostMapper(event, {}, rudderContext); - expect(rudderContext).toEqual(expectedRudderContext); - }); -}); diff --git a/test/__tests__/customerio_source.test.js b/test/__tests__/customerio_source.test.js deleted file mode 100644 index d753c8cef7..0000000000 --- a/test/__tests__/customerio_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "customerio"; -const name = "CustomerIO"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/data/appcenter_source_input.json b/test/__tests__/data/appcenter_source_input.json deleted file mode 100644 index 1cde0666b1..0000000000 --- a/test/__tests__/data/appcenter_source_input.json +++ /dev/null @@ -1,78 +0,0 @@ -[ - { - "text": "Hello from your abc-test app in App Center!", - "sent_at": "2023-01-02T07: 53: 28.3117824Z", - "url": "https://appcenter.ms/users/abc-rudderstack.com/apps/abc-test" - }, - { - "app_name": "MSAppCenterTesting", - "branch": "master", - "build_status": "Succeeded", - "build_id": "1", - "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/1", - "build_reason": "manual", - "finish_time": "2021-03-02T16:41:29.891411Z", - "icon_link": null, - "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", - "os": "Android", - "start_time": "2021-03-02T16:34:13.9184874Z", - "source_version": "7ed5c7b279316f19e9a0c45bb0fb49c0655471af", - "sent_at": "2021-03-02T16:41:55.8819564Z" - }, - { - "app_name": "MSAppCenterTesting", - "branch": "master", - "build_status": "Broken", - "build_id": "2", - "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/2", - "build_reason": "automatic", - "finish_time": "2021-03-02T16:52:04.2587506Z", - "icon_link": null, - "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", - "os": "Android", - "start_time": "2021-03-02T16:50:52.2584107Z", - "source_version": "0624e1e3e48eaf2371c37316208ff83bdd5c123b", - "sent_at": "2021-03-02T16:52:35.8848052Z" - }, - { - "app_name": "MSAppCenterTesting", - "app_display_name": "MSAppCenterTesting", - "release_id": "1", - "platform": "Android", - "uploaded_at": "2021-03-02T17:49:35.463Z", - "fingerprint": "9cbdc86d96c5359d2af3972fdda46624", - "release_notes": "Degraded to 4.0.0", - "version": "1614707021", - "short_version": "1.0", - "min_os": "7.1", - "mandatory_update": true, - "size": 2919106, - "provisioning_profile_name": null, - "provisioning_profile_type": null, - "bundle_identifier": "tech.desusai.msappcentertesting", - "install_link": "https://install.appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/releases/1?source=email", - "icon_link": "https://appcenter-filemanagement-distrib2ede6f06e.azureedge.net/dbbd3d57-9c09-448b-9782-0d57200f7c9b/ic_launcher.png?sv=2019-02-02&sr=c&sig=BNzQcMcvTbwf4fv59ByGiYXsr%2BA9PYDFyGJCqsE2RO0%3D&se=2021-03-09T17%3A49%3A35Z&sp=r", - "distribution_group_id": "00000000-0000-0000-0000-000000000000", - "installable": true, - "sent_at": "2021-03-02T17:49:37.127635Z", - "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" - }, - { - "id": "1139624368u", - "name": "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25)", - "reason": "java.lang.ArithmeticException: divide by zero", - "file_name": null, - "line_number": null, - "url": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/crashes/errors/1139624368u", - "app_display_name": "MSAppCenterTesting", - "app_platform": "Java", - "app_version": "1.0(1)", - "stack_trace": [ - "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25);" - ], - "affected_users": 0, - "crash_count": 0, - "sent_at": "2021-03-02T18:14:33.9713246Z", - "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" - } -] diff --git a/test/__tests__/data/appcenter_source_output.json b/test/__tests__/data/appcenter_source_output.json deleted file mode 100644 index 82b5eb899f..0000000000 --- a/test/__tests__/data/appcenter_source_output.json +++ /dev/null @@ -1,198 +0,0 @@ -[ - { - "outputToSource": { - "body": "eyJ0ZXh0IjoiSGVsbG8gZnJvbSB5b3VyIEFuYW50LXRlc3QgYXBwIGluIEFwcCBDZW50ZXIhIiwic2VudF9hdCI6IjIwMjMtMDEtMDJUMDc6IDUzOiAyOC4zMTE3ODI0WiIsInVybCI6Imh0dHBzOiAvL2FwcGNlbnRlci5tcy91c2Vycy9hbmFudC1ydWRkZXJzdGFjay5jb20vYXBwcy9BbmFudC10ZXN0In0=", - "contentType": "application/json" - }, - "statusCode": 200 - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "APPCENTER" - }, - "app": { - "name": "MSAppCenterTesting", - "build": "1" - }, - "device": { - "type": "Android" - }, - "network": { - "carrier": "Android" - }, - "os": { - "name": "Android" - } - }, - "integrations": { - "APPCENTER": false - }, - "properties": { - "app_name": "MSAppCenterTesting", - "branch": "master", - "build_status": "Succeeded", - "build_id": "1", - "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/1", - "build_reason": "manual", - "finish_time": "2021-03-02T16:41:29.891411Z", - "icon_link": null, - "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", - "os": "Android", - "start_time": "2021-03-02T16:34:13.9184874Z", - "source_version": "7ed5c7b279316f19e9a0c45bb0fb49c0655471af", - "sent_at": "2021-03-02T16:41:55.8819564Z" - }, - "type": "track", - "event": "Build Succeeded", - "originalTimeStamp": "2021-03-02T16:34:13.9184874Z", - "anonymousId": "7e32188a4dab669f", - "sentAt": "2021-03-02T16:41:55.8819564Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "APPCENTER" - }, - "app": { - "name": "MSAppCenterTesting", - "build": "2" - }, - "device": { - "type": "Android" - }, - "network": { - "carrier": "Android" - }, - "os": { - "name": "Android" - } - }, - "integrations": { - "APPCENTER": false - }, - "properties": { - "app_name": "MSAppCenterTesting", - "branch": "master", - "build_status": "Broken", - "build_id": "2", - "build_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/2", - "build_reason": "automatic", - "finish_time": "2021-03-02T16:52:04.2587506Z", - "icon_link": null, - "notification_settings_link": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications", - "os": "Android", - "start_time": "2021-03-02T16:50:52.2584107Z", - "source_version": "0624e1e3e48eaf2371c37316208ff83bdd5c123b", - "sent_at": "2021-03-02T16:52:35.8848052Z" - }, - "type": "track", - "event": "Build Failed", - "originalTimeStamp": "2021-03-02T16:50:52.2584107Z", - "anonymousId": "7e32188a4dab669f", - "sentAt": "2021-03-02T16:52:35.8848052Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "APPCENTER" - }, - "app": { - "name": "MSAppCenterTesting", - "version": "1.0", - "namespace": "tech.desusai.msappcentertesting" - }, - "device": { - "type": "Android" - }, - "network": { - "carrier": "Android" - }, - "os": { - "name": "Android" - } - }, - "integrations": { - "APPCENTER": false - }, - "properties": { - "app_name": "MSAppCenterTesting", - "app_display_name": "MSAppCenterTesting", - "release_id": "1", - "platform": "Android", - "uploaded_at": "2021-03-02T17:49:35.463Z", - "fingerprint": "9cbdc86d96c5359d2af3972fdda46624", - "release_notes": "Degraded to 4.0.0", - "version": "1614707021", - "short_version": "1.0", - "min_os": "7.1", - "mandatory_update": true, - "size": 2919106, - "provisioning_profile_name": null, - "provisioning_profile_type": null, - "bundle_identifier": "tech.desusai.msappcentertesting", - "install_link": "https://install.appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/releases/1?source=email", - "icon_link": "https://appcenter-filemanagement-distrib2ede6f06e.azureedge.net/dbbd3d57-9c09-448b-9782-0d57200f7c9b/ic_launcher.png?sv=2019-02-02&sr=c&sig=BNzQcMcvTbwf4fv59ByGiYXsr%2BA9PYDFyGJCqsE2RO0%3D&se=2021-03-09T17%3A49%3A35Z&sp=r", - "distribution_group_id": "00000000-0000-0000-0000-000000000000", - "installable": true, - "sent_at": "2021-03-02T17:49:37.127635Z", - "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" - }, - "type": "track", - "event": "Released Version 1.0", - "anonymousId": "7e32188a4dab669f", - "sentAt": "2021-03-02T17:49:37.127635Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "APPCENTER" - }, - "app": { - "name": "MSAppCenterTesting", - "version": "1.0(1)" - } - }, - "integrations": { - "APPCENTER": false - }, - "properties": { - "id": "1139624368u", - "name": "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25)", - "reason": "java.lang.ArithmeticException: divide by zero", - "file_name": null, - "line_number": null, - "url": "https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/crashes/errors/1139624368u", - "app_display_name": "MSAppCenterTesting", - "app_platform": "Java", - "app_version": "1.0(1)", - "stack_trace": [ - "tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25);" - ], - "affected_users": 0, - "crash_count": 0, - "sent_at": "2021-03-02T18:14:33.9713246Z", - "app_id": "ce8b5280-4605-4c1c-8c48-bd54c8fdda31" - }, - "type": "track", - "event": "App Crashed", - "anonymousId": "7e32188a4dab669f", - "sentAt": "2021-03-02T18:14:33.9713246Z" - } -] diff --git a/test/__tests__/data/appsflyer_source_input.json b/test/__tests__/data/appsflyer_source_input.json deleted file mode 100644 index 694281924d..0000000000 --- a/test/__tests__/data/appsflyer_source_input.json +++ /dev/null @@ -1,908 +0,0 @@ -[ - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "device_type": "iPhoneXR", - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "ios", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "device_type": "Nokia 5.3", - "idfa": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "android", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "device_type": "iPhoneXR", - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "ios", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "device_type": "iPhoneXR", - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "ios", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "ios", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "watchos", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "ipados", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "customer_user_id": "hi.from@appsflyer.example.com", - "is_lat": null, - "contributor_2_af_prt": null, - "bundle_id": "com.appsflyer.AppsFlyer", - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "app_version": "1.4.1", - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "city": "Khu Pho Binh Hoa", - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "app_name": "AppsFlyer", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "postal_code": "823941", - "wifi": true, - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "country_code": "VN", - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "appsflyer_id": "1547985076649-5309999", - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "ip": "1.1.1.1", - "oaid": null, - "event_time": "2020-01-15 14:57:24.898", - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "android_id": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "idfa": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "carrier": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "os_version": "12.3.1", - "platform": "tvos", - "af_sub3": null, - "contributor_3_match_type": null, - "selected_timezone": "UTC", - "af_ad_id": null, - "contributor_3_touch_time": null, - "user_agent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - } -] diff --git a/test/__tests__/data/appsflyer_source_output.json b/test/__tests__/data/appsflyer_source_output.json deleted file mode 100644 index 03eb49a8ae..0000000000 --- a/test/__tests__/data/appsflyer_source_output.json +++ /dev/null @@ -1,1092 +0,0 @@ -[ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "model": "iPhoneXR", - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "ios", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - }, - "userId": "hi.from@appsflyer.example.com" - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "type": "track", - "event": "My Apps", - "userId": "hi.from@appsflyer.example.com", - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "ios", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "model": "Nokia 5.3", - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "android", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - }, - "userId": "hi.from@appsflyer.example.com" - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "type": "track", - "event": "My Apps", - "userId": "hi.from@appsflyer.example.com", - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "android", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - }, - { - "statusCode": 400, - "message": "Unknwon event type from Appsflyer" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "model": "iPhoneXR", - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "ios", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "type": "track", - "event": "My Apps", - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "ios", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "ios", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - }, - "userId": "hi.from@appsflyer.example.com" - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "type": "track", - "event": "My Apps", - "userId": "hi.from@appsflyer.example.com", - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "ios", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "watchos", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - }, - "userId": "hi.from@appsflyer.example.com" - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "type": "track", - "event": "My Apps", - "userId": "hi.from@appsflyer.example.com", - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "watchos", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "ipados", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - }, - "userId": "hi.from@appsflyer.example.com" - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "type": "track", - "event": "My Apps", - "userId": "hi.from@appsflyer.example.com", - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "ipados", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "AF" - }, - "ip": "1.1.1.1", - "timezone": "UTC", - "userAgent": "AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0", - "app": { - "namespace": "com.appsflyer.AppsFlyer", - "version": "1.4.1", - "name": "AppsFlyer" - }, - "device": { - "advertisingId": "A7071198-3848-40A5-B3D0-94578D9BZZZZ", - "adTrackingEnabled": true - }, - "network": { - "wifi": true - }, - "os": { - "name": "tvos", - "version": "12.3.1" - }, - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - }, - "userId": "hi.from@appsflyer.example.com" - }, - "externalId": [ - { - "type": "appsflyerExternalId", - "value": "1547985076649-5309999" - } - ] - }, - "integrations": { - "AF": false - }, - "properties": { - "idfv": "868049A3-4B2F-4A11-9B00-CFFC362XXXXX", - "device_category": "phone", - "af_sub1": null, - "is_lat": null, - "contributor_2_af_prt": null, - "gp_broadcast_referrer": "", - "contributor_2_touch_time": null, - "contributor_3_touch_type": null, - "event_source": "SDK", - "af_cost_value": null, - "contributor_1_match_type": null, - "contributor_3_af_prt": null, - "custom_data": null, - "contributor_2_touch_type": null, - "gp_install_begin": null, - "amazon_aid": null, - "gp_referrer": null, - "af_cost_model": null, - "af_c_id": null, - "attributed_touch_time_selected_timezone": null, - "selected_currency": "USD", - "install_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "install_time": "2019-01-20 04:51:16.000", - "operator": null, - "attributed_touch_type": null, - "af_attribution_lookback": null, - "campaign_type": null, - "keyword_match_type": null, - "af_adset_id": null, - "device_download_time_selected_timezone": "2019-01-20 04:51:16.000+0000", - "contributor_2_media_source": null, - "conversion_type": null, - "contributor_2_match_type": null, - "api_version": "2.0", - "attributed_touch_time": null, - "revenue_in_selected_currency": null, - "is_retargeting": false, - "gp_click_time": null, - "contributor_1_af_prt": null, - "match_type": null, - "dma": "None", - "http_referrer": null, - "af_sub5": null, - "af_prt": null, - "event_revenue_currency": "USD", - "store_reinstall": null, - "install_app_store": null, - "media_source": "organic", - "deeplink_url": null, - "campaign": null, - "af_keywords": null, - "region": "AS", - "cost_in_selected_currency": null, - "event_value": "{}", - "oaid": null, - "is_receipt_validated": null, - "contributor_1_campaign": null, - "af_sub4": null, - "imei": null, - "contributor_3_campaign": null, - "event_revenue_usd": null, - "af_sub2": null, - "original_url": null, - "contributor_2_campaign": null, - "contributor_3_media_source": null, - "af_adset": null, - "af_ad": null, - "state": "57", - "network_account_id": null, - "retargeting_conversion_type": null, - "af_channel": null, - "af_cost_currency": null, - "contributor_1_media_source": null, - "keyword_id": null, - "device_download_time": "2019-01-20 04:51:16.000", - "contributor_1_touch_type": null, - "af_reengagement_window": null, - "af_siteid": null, - "language": "en-US", - "app_id": "id1217828636", - "contributor_1_touch_time": null, - "event_revenue": null, - "af_ad_type": null, - "event_name": "My Apps", - "af_sub_siteid": null, - "advertising_id": null, - "af_sub3": null, - "contributor_3_match_type": null, - "af_ad_id": null, - "contributor_3_touch_time": null, - "is_primary_attribution": true, - "sdk_version": "v4.10.0", - "event_time_selected_timezone": "2020-01-15 14:57:24.898+0000" - }, - "type": "track", - "event": "My Apps", - "userId": "hi.from@appsflyer.example.com", - "timestamp": "2020-01-15 14:57:24.898", - "originalTimestamp": "2020-01-15 14:57:24.898", - "platform": "tvos", - "traits": { - "address": { - "city": "Khu Pho Binh Hoa", - "zip": "823941", - "country": "VN" - } - } - } -] diff --git a/test/__tests__/data/braze_source_input.json b/test/__tests__/data/braze_source_input.json deleted file mode 100644 index aef068229b..0000000000 --- a/test/__tests__/data/braze_source_input.json +++ /dev/null @@ -1,243 +0,0 @@ -[ - [ - { - "events": [ - { - "event_type": "users.messages.inappmessage.Click", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1607988752, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210", - "timezone": "America/Chicago" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "platform": "android", - "os_version": "Android (N)", - "device_model": "Nexus 5X", - "button_id": "0", - "send_id": "f123456789abcdef01234567" - } - }, - { - "event_type": "users.messages.pushnotification.Send", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210", - "timezone": "America/Chicago" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "platform": "ios", - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "send_id": "f123456789abcdef01234567", - "dispatch_id": "01234567-89ab-cdef-0123-456789abcdef" - } - }, - { - "event_type": "users.messages.email.Open", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "timezone": "America/Chicago" - }, - "properties": { - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "dispatch_id": "12345qwert", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "email_address": "test@test.com", - "send_id": "f123456789abcdef01234567", - "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Safari/537.36" - } - }, - { - "event_type": "users.messages.sms.Delivery", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "timezone": "America/Chicago" - }, - "properties": { - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "dispatch_id": "12345qwert", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "to_phone_number": "+16462345678", - "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", - "from_phone_number": "+12123470922" - } - }, - { - "event_type": "users.messages.inappmessage.Click", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210", - "timezone": "America/Chicago" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "My Cool Campaign", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "platform": "android", - "os_version": "Android (N)", - "device_model": "Nexus 5X", - "button_id": "0", - "send_id": "f123456789abcdef01234567" - } - }, - { - "event_type": "users.messages.pushnotification.Send", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210", - "timezone": "America/Chicago" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "platform": "ios", - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "My Cool Campaign", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "send_id": "f123456789abcdef01234567", - "dispatch_id": "01234567-89ab-cdef-0123-456789abcdef" - } - }, - { - "event_type": "users.messages.email.Open", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "timezone": "America/Chicago" - }, - "properties": { - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "My Cool Canvas", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "dispatch_id": "12345qwert", - "email_address": "test@test.com", - "send_id": "f123456789abcdef01234567", - "user_agent": "Mozilla/5.0(Macintosh;IntelMacOSX10_13_5)AppleWebKit/537.36(KHTML,likeGecko)Chrome/67.0.3396.99Safari/537.36" - } - }, - { - "event_type": "users.messages.sms.Delivery", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "timezone": "America/Chicago" - }, - "properties": { - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "MyCoolCanvas", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "dispatch_id": "12345qwert", - "to_phone_number": "+16462345678", - "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", - "from_phone_number": "+12123470922" - } - }, - { - "event_type": "users.behaviors.CustomEvent", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210", - "timezone": "America/Chicago" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "platform": "ios", - "os_version": "iOS10.3.1", - "device_model": "iPhone7Plus", - "name": "customeventname", - "ad_id": "01234567-89ab-cdef-0123-456789abcdef", - "ad_id_type": "roku_ad_id", - "ad_tracking_enabled": true, - "custom_properties": { - "stringpropertyname": "a", - "numberpropertyname": 1, - "listpropertyname": ["a", "b"] - } - } - }, - { - "event_type": "users.behaviors.Purchase", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210", - "timezone": "America/Chicago" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "platform": "ios", - "os_version": "iOS10.3.1", - "device_model": "iPhone7Plus", - "product_id": "1234", - "price": 12.34, - "currency": "AED", - "ad_id": "01234567-89ab-cdef-0123-456789abcdef", - "ad_id_type": "roku_ad_id", - "ad_tracking_enabled": true, - "purchase_properties": { - "stringpropertyname": "a", - "numberpropertyname": 1, - "listpropertyname": ["a", "b"] - } - } - }, - { - "event_type": "users.behaviors.app.SessionStart", - "id": "a1234567-89ab-cdef-0123-456789abcdef", - "time": 1477502783, - "user": { - "user_id": "0123456789abcdef01234567", - "external_user_id": "user_id", - "device_id": "fedcba87-6543-210f-edc-ba9876543210" - }, - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "platform": "ios", - "os_version": "iOS10.3.1", - "device_model": "iPhone7Plus", - "session_id": "b1234567-89ab-cdef-0123-456789abcdef" - } - } - ] - } - ] -] diff --git a/test/__tests__/data/braze_source_output.json b/test/__tests__/data/braze_source_output.json deleted file mode 100644 index b4e61885fe..0000000000 --- a/test/__tests__/data/braze_source_output.json +++ /dev/null @@ -1,288 +0,0 @@ -[ - [ - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { - "id": "fedcba87-6543-210f-edc-ba9876543210", - "model": "Nexus 5X" - }, - "timezone": "America/Chicago", - "os": { "version": "Android (N)", "name": "android" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.inappmessage.Click", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "button_id": "0", - "send_id": "f123456789abcdef01234567" - }, - "timestamp": "2020-12-14T23:32:32.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { "id": "fedcba87-6543-210f-edc-ba9876543210" }, - "timezone": "America/Chicago", - "os": { "name": "ios" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.pushnotification.Send", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "send_id": "f123456789abcdef01234567", - "dispatch_id": "01234567-89ab-cdef-0123-456789abcdef" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "timezone": "America/Chicago", - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Safari/537.36" - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.email.Open", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "traits": { "email": "test@test.com" }, - "properties": { - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "dispatch_id": "12345qwert", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "send_id": "f123456789abcdef01234567" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "timezone": "America/Chicago", - "integration": { "name": "Braze" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.sms.Delivery", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "traits": { "phone": "+16462345678" }, - "properties": { - "campaign_id": "11234567-89ab-cdef-0123-456789abcdef", - "campaign_name": "Test Campaign", - "dispatch_id": "12345qwert", - "message_variation_id": "c1234567-89ab-cdef-0123-456789abcdef", - "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", - "from_phone_number": "+12123470922" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { - "id": "fedcba87-6543-210f-edc-ba9876543210", - "model": "Nexus 5X" - }, - "timezone": "America/Chicago", - "os": { "version": "Android (N)", "name": "android" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.inappmessage.Click", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "My Cool Campaign", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "button_id": "0", - "send_id": "f123456789abcdef01234567" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { "id": "fedcba87-6543-210f-edc-ba9876543210" }, - "timezone": "America/Chicago", - "os": { "name": "ios" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.pushnotification.Send", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "My Cool Campaign", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "send_id": "f123456789abcdef01234567", - "dispatch_id": "01234567-89ab-cdef-0123-456789abcdef" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "timezone": "America/Chicago", - "userAgent": "Mozilla/5.0(Macintosh;IntelMacOSX10_13_5)AppleWebKit/537.36(KHTML,likeGecko)Chrome/67.0.3396.99Safari/537.36" - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.email.Open", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "traits": { "email": "test@test.com" }, - "properties": { - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "My Cool Canvas", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "dispatch_id": "12345qwert", - "send_id": "f123456789abcdef01234567" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "timezone": "America/Chicago", - "integration": { "name": "Braze" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.messages.sms.Delivery", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "traits": { "phone": "+16462345678" }, - "properties": { - "canvas_id": "11234567-89ab-cdef-0123-456789abcdef", - "canvas_name": "MyCoolCanvas", - "canvas_variation_id": "31234567-89ab-cdef-0123-456789abcdef", - "canvas_step_id": "41234567-89ab-cdef-0123-456789abcdef", - "dispatch_id": "12345qwert", - "subscription_group_id": "41234567-89ab-cdef-0123-456789abcdef", - "from_phone_number": "+12123470922" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { - "id": "fedcba87-6543-210f-edc-ba9876543210", - "model": "iPhone7Plus", - "advertisingId": "01234567-89ab-cdef-0123-456789abcdef", - "adTrackingEnabled": true - }, - "timezone": "America/Chicago", - "os": { "version": "iOS10.3.1", "name": "ios" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.behaviors.CustomEvent", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "name": "customeventname", - "ad_id_type": "roku_ad_id", - "custom_properties": { - "stringpropertyname": "a", - "numberpropertyname": 1, - "listpropertyname": ["a", "b"] - } - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { - "id": "fedcba87-6543-210f-edc-ba9876543210", - "model": "iPhone7Plus", - "advertisingId": "01234567-89ab-cdef-0123-456789abcdef", - "adTrackingEnabled": true - }, - "timezone": "America/Chicago", - "os": { "version": "iOS10.3.1", "name": "ios" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.behaviors.Purchase", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "product_id": "1234", - "price": 12.34, - "currency": "AED", - "ad_id_type": "roku_ad_id", - "purchase_properties": { - "stringpropertyname": "a", - "numberpropertyname": 1, - "listpropertyname": ["a", "b"] - } - }, - "timestamp": "2016-10-26T17:26:23.000Z" - }, - { - "context": { - "library": { "name": "unknown", "version": "unknown" }, - "integration": { "name": "Braze" }, - "device": { - "id": "fedcba87-6543-210f-edc-ba9876543210", - "model": "iPhone7Plus" - }, - "os": { "version": "iOS10.3.1", "name": "ios" } - }, - "integrations": { "Braze": false }, - "type": "track", - "event": "users.behaviors.app.SessionStart", - "messageId": "a1234567-89ab-cdef-0123-456789abcdef", - "anonymousId": "0123456789abcdef01234567", - "userId": "user_id", - "properties": { - "app_id": "01234567-89ab-cdef-0123-456789abcdef", - "session_id": "b1234567-89ab-cdef-0123-456789abcdef" - }, - "timestamp": "2016-10-26T17:26:23.000Z" - } - ] -] diff --git a/test/__tests__/data/canny_source_input.json b/test/__tests__/data/canny_source_input.json deleted file mode 100644 index 5547473209..0000000000 --- a/test/__tests__/data/canny_source_input.json +++ /dev/null @@ -1,667 +0,0 @@ -[ - { - "created": "2022-07-28T10:52:46.294Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 13, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-28T10:52:46.172Z", - "customFields": [ - { - "id": "62e13820d7949d44b92d3876", - "name": "abc", - "value": "123" - } - ], - "details": "Array of images", - "eta": null, - "id": "62e26a7e1d4ea13c124337bd", - "imageURLs": [ - "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", - "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" - ], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Custom Fields Testing", - "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" - }, - "objectType": "post", - "type": "post.created" - }, - { - "created": "2022-07-26T10:35:16.390Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 10, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-26T08:18:52.459Z", - "deletedBy": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "details": "This is the post's details", - "eta": null, - "id": "62dfa36c9950e94655320fe7", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" - }, - "objectType": "post", - "type": "post.deleted" - }, - { - "created": "2022-07-26T18:32:28.337Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "category": null, - "commentCount": 0, - "created": "2022-07-26T10:43:43.752Z", - "details": "This is the post's details", - "eta": null, - "id": "62dfc55ffe7f6f465b9b4568", - "imageURLs": [], - "issue": { - "description": "This is the post's details\n\nhttps://rudder.canny.io/admin/board/features/p/post-title-8", - "id": "10001", - "key": "TES-2", - "status": "To Do", - "summary": "Canny Source Testing", - "url": "https://rudderstack-user.atlassian.net/browse/TES-2" - }, - "owner": null, - "score": 2, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-8" - }, - "objectType": "post", - "type": "post.jira_issue_linked" - }, - { - "created": "2022-07-27T04:08:24.377Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "category": null, - "commentCount": 0, - "created": "2022-07-26T11:32:31.228Z", - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "issue": { - "description": "Array of images\n\nhttps://rudder.canny.io/admin/board/features/p/images-testing-2", - "id": "10002", - "key": "TES-3", - "status": "To Do", - "summary": "Images testing", - "url": "https://rudderstack-user.atlassian.net/browse/TES-3" - }, - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "objectType": "post", - "type": "post.jira_issue_unlinked" - }, - { - "created": "2022-07-26T18:07:03.143Z", - "object": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "changeComment": { - "imageURLs": ["https://canny.io/images/0a4b1c6a967ad9fc17f0c71dc11d1de2.webp"], - "value": "" - }, - "changedAt": "2022-07-26T18:07:03.143Z", - "changer": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "commentCount": 1, - "created": "2022-07-26T08:22:31.089Z", - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "jira": { - "linkedIssues": [], - "linkedIssueIDs": [] - }, - "owner": null, - "score": 2, - "status": "planned", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - }, - "objectType": "post", - "type": "post.status_changed" - }, - { - "created": "2022-07-26T10:52:17.712Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 11, - "url": "https://rudder.canny.io/admin/board/features" - }, - "created": "2022-07-26T10:52:17.618Z", - "id": "62dfc761af6e2b467381b103", - "imageURLs": ["https://canny.io/images/59ef1b731f87d1c84bbdc078d0b9221e.webp"], - "internal": true, - "mentions": [], - "parentID": null, - "post": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 1, - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "owner": null, - "score": 2, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - }, - "private": false, - "value": "webhook-test" - }, - "objectType": "comment", - "type": "comment.created" - }, - { - "created": "2022-07-27T04:12:09.290Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "created": "2022-07-27T04:11:59.942Z", - "id": "62e0bb0faf6e2b467328b133", - "imageURLs": [], - "parentID": null, - "post": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 0, - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "private": false, - "value": "good" - }, - "objectType": "comment", - "type": "comment.deleted" - }, - { - "created": "2022-07-26T11:32:31.378Z", - "object": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T11:32:31.263Z", - "id": "62dfd0cfb2870d468c9618f5", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 0, - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "score": 1, - "voter": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - } - }, - "objectType": "vote", - "type": "vote.created" - }, - { - "created": "2022-07-26T18:09:27.358Z", - "object": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T08:22:31.109Z", - "id": "62dfa4479950e9465532a338", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 1, - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "planned", - "tags": [ - { - "id": "62e02db67ad24c46bc175f56", - "name": "abc-tag", - "postCount": 1, - "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" - } - ], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - }, - "score": 0, - "voter": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - } - }, - "objectType": "vote", - "type": "vote.deleted" - }, - { - "created": "2022-07-28T10:52:46.294Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": "sampleuserId" - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 13, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-28T10:52:46.172Z", - "customFields": [ - { - "id": "62e13820d7949d44b92d3876", - "name": "abc", - "value": "123" - } - ], - "details": "Array of images", - "eta": null, - "id": "62e26a7e1d4ea13c124337bd", - "imageURLs": [ - "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", - "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" - ], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Custom Fields Testing", - "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" - }, - "objectType": "post", - "type": "post.created" - }, - { - "created": "2022-07-26T11:32:31.378Z", - "object": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T11:32:31.263Z", - "id": "62dfd0cfb2870d468c9618f5", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 0, - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "score": 1, - "voter": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": "123" - } - }, - "objectType": "vote", - "type": "vote.created" - }, - { - "created": "2022-07-26T18:09:27.358Z", - "object": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T08:22:31.109Z", - "id": "62dfa4479950e9465532a338", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 1, - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "planned", - "tags": [ - { - "id": "62e02db67ad24c46bc175f56", - "name": "abc-tag", - "postCount": 1, - "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" - } - ], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - }, - "score": 0, - "voter": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": null, - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - } - }, - "objectType": "vote", - "type": "vote.deleted" - }, - { - "created": "2022-07-26T10:35:16.390Z", - "object": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 10, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-26T08:18:52.459Z", - "deletedBy": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "details": "This is the post's details", - "eta": null, - "id": "62dfa36c9950e94655320fe7", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" - }, - "objectType": "post" - } -] diff --git a/test/__tests__/data/canny_source_output.json b/test/__tests__/data/canny_source_output.json deleted file mode 100644 index 67f919ba9b..0000000000 --- a/test/__tests__/data/canny_source_output.json +++ /dev/null @@ -1,789 +0,0 @@ -[ - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "post.created", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-28T10:52:46.294Z", - "originalTimestamp": "2022-07-28T10:52:46.294Z", - "type": "track", - "properties": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 13, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-28T10:52:46.172Z", - "customFields": [ - { - "id": "62e13820d7949d44b92d3876", - "name": "abc", - "value": "123" - } - ], - "details": "Array of images", - "eta": null, - "id": "62e26a7e1d4ea13c124337bd", - "imageURLs": [ - "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", - "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" - ], - "objectType": "post", - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Custom Fields Testing", - "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "post.deleted", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T10:35:16.390Z", - "originalTimestamp": "2022-07-26T10:35:16.390Z", - "type": "track", - "properties": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 10, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-26T08:18:52.459Z", - "deletedBy": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "details": "This is the post's details", - "eta": null, - "id": "62dfa36c9950e94655320fe7", - "imageURLs": [], - "objectType": "post", - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-4" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "post.jira_issue_linked", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T18:32:28.337Z", - "originalTimestamp": "2022-07-26T18:32:28.337Z", - "type": "track", - "properties": { - "by": null, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "category": null, - "commentCount": 0, - "created": "2022-07-26T10:43:43.752Z", - "details": "This is the post's details", - "eta": null, - "id": "62dfc55ffe7f6f465b9b4568", - "imageURLs": [], - "issue": { - "description": "This is the post's details\n\nhttps://rudder.canny.io/admin/board/features/p/post-title-8", - "id": "10001", - "key": "TES-2", - "status": "To Do", - "summary": "Canny Source Testing", - "url": "https://rudderstack-user.atlassian.net/browse/TES-2" - }, - "objectType": "post", - "owner": null, - "score": 2, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-8" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "post.jira_issue_unlinked", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-27T04:08:24.377Z", - "originalTimestamp": "2022-07-27T04:08:24.377Z", - "type": "track", - "properties": { - "objectType": "post", - "by": null, - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "category": null, - "commentCount": 0, - "created": "2022-07-26T11:32:31.228Z", - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "issue": { - "description": "Array of images\n\nhttps://rudder.canny.io/admin/board/features/p/images-testing-2", - "id": "10002", - "key": "TES-3", - "status": "To Do", - "summary": "Images testing", - "url": "https://rudderstack-user.atlassian.net/browse/TES-3" - }, - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "post.status_changed", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T18:07:03.143Z", - "originalTimestamp": "2022-07-26T18:07:03.143Z", - "type": "track", - "properties": { - "objectType": "post", - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "changeComment": { - "imageURLs": ["https://canny.io/images/0a4b1c6a967ad9fc17f0c71dc11d1de2.webp"], - "value": "" - }, - "changedAt": "2022-07-26T18:07:03.143Z", - "changer": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "commentCount": 1, - "created": "2022-07-26T08:22:31.089Z", - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "jira": { - "linkedIssues": [], - "linkedIssueIDs": [] - }, - "owner": null, - "score": 2, - "status": "planned", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "comment.created", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T10:52:17.712Z", - "originalTimestamp": "2022-07-26T10:52:17.712Z", - "type": "track", - "properties": { - "objectType": "comment", - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 11, - "url": "https://rudder.canny.io/admin/board/features" - }, - "created": "2022-07-26T10:52:17.618Z", - "id": "62dfc761af6e2b467381b103", - "imageURLs": ["https://canny.io/images/59ef1b731f87d1c84bbdc078d0b9221e.webp"], - "internal": true, - "mentions": [], - "parentID": null, - "post": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 1, - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "owner": null, - "score": 2, - "status": "open", - "tags": [], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - }, - "private": false, - "value": "webhook-test" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "comment.deleted", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-27T04:12:09.290Z", - "originalTimestamp": "2022-07-27T04:12:09.290Z", - "type": "track", - "properties": { - "objectType": "comment", - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "created": "2022-07-27T04:11:59.942Z", - "id": "62e0bb0faf6e2b467328b133", - "imageURLs": [], - "parentID": null, - "post": { - "author": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 0, - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "private": false, - "value": "good" - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "vote.created", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T11:32:31.378Z", - "originalTimestamp": "2022-07-26T11:32:31.378Z", - "type": "track", - "properties": { - "objectType": "vote", - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T11:32:31.263Z", - "id": "62dfd0cfb2870d468c9618f5", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 0, - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "score": 1 - } - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "event": "vote.deleted", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T18:09:27.358Z", - "originalTimestamp": "2022-07-26T18:09:27.358Z", - "type": "track", - "properties": { - "objectType": "vote", - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T08:22:31.109Z", - "id": "62dfa4479950e9465532a338", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 1, - "details": "This is the post's details", - "eta": null, - "id": "62dfa4479950e9465532a31e", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "planned", - "tags": [ - { - "id": "62e02db67ad24c46bc175f56", - "name": "abc-tag", - "postCount": 1, - "url": "https://rudder.canny.io/admin/board/features?tags=abc-tag" - } - ], - "title": "Post Title", - "url": "https://rudder.canny.io/admin/board/features/p/post-title-7" - }, - "score": 0 - } - }, - { - "userId": "sampleuserId", - "event": "post.created", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-28T10:52:46.294Z", - "originalTimestamp": "2022-07-28T10:52:46.294Z", - "type": "track", - "properties": { - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 13, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "category": null, - "commentCount": 0, - "created": "2022-07-28T10:52:46.172Z", - "customFields": [ - { - "id": "62e13820d7949d44b92d3876", - "name": "abc", - "value": "123" - } - ], - "details": "Array of images", - "eta": null, - "id": "62e26a7e1d4ea13c124337bd", - "imageURLs": [ - "https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg", - "https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg" - ], - "objectType": "post", - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Custom Fields Testing", - "url": "https://rudder.canny.io/admin/board/features/p/custom-fields-testing" - } - }, - { - "userId": "123", - "event": "vote.created", - "integrations": { - "Canny": false - }, - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Canny", - "version": "1.0.0" - }, - "traits": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser" - }, - "externalId": [ - { - "type": "cannyUserId", - "id": "62d14c90fff7c80d0ec08375" - } - ] - }, - "timestamp": "2022-07-26T11:32:31.378Z", - "originalTimestamp": "2022-07-26T11:32:31.378Z", - "type": "track", - "properties": { - "objectType": "vote", - "board": { - "created": "2022-07-25T12:11:19.895Z", - "id": "62de88676bc28b44aaaf25cc", - "name": "features", - "postCount": 12, - "url": "https://rudder.canny.io/admin/board/features" - }, - "by": null, - "created": "2022-07-26T11:32:31.263Z", - "id": "62dfd0cfb2870d468c9618f5", - "post": { - "author": { - "avatarURL": "https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png", - "created": "2022-07-15T11:16:32.648Z", - "email": "test@rudderstack.com", - "id": "62d14c90fff7c80d0ec08375", - "isAdmin": true, - "name": "Rudder Test", - "url": "https://rudder.canny.io/admin/users/dummyUser", - "userID": null - }, - "by": null, - "category": null, - "commentCount": 0, - "details": "Array of images", - "eta": null, - "id": "62dfd0cfb2870d468c9618dd", - "imageURLs": [], - "owner": null, - "score": 1, - "status": "open", - "tags": [], - "title": "Images testing", - "url": "https://rudder.canny.io/admin/board/features/p/images-testing-2" - }, - "score": 1 - } - }, - { - "message": "Missing essential fields from Canny. Error: (TypeError [ERR_INVALID_ARG_TYPE]: The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received null)" - }, - { - "message": "Missing essential fields from Canny" - } -] diff --git a/test/__tests__/data/customerio_source_input.json b/test/__tests__/data/customerio_source_input.json deleted file mode 100644 index 769c1b7fd3..0000000000 --- a/test/__tests__/data/customerio_source_input.json +++ /dev/null @@ -1,390 +0,0 @@ -[ - { - "data": { - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "email_address": "test@example.com" - }, - "event_id": "01E4C4CT6YDC7Y5M7FE1GWWPQJ", - "object_type": "customer", - "metric": "subscribed", - "timestamp": "abc" - }, - { - "data": { - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "email_address": "test@example.com" - }, - "event_id": "01E4C4CT6YDC7Y5M7FE1GWWPQJ", - "object_type": "customer", - "metric": "subscribed", - "timestamp": "1585250199" - }, - { - "data": { - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "email_address": "test@example.com" - }, - "event_id": "01E4C4CT6YDC7Y5M7FE1GWWPQJ", - "object_type": "customer", - "metric": "subscribed", - "timestamp": 1585250199 - }, - { - "data": { - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "email_address": "test@example.com" - }, - "event_id": "01E4C4C6P79C12J5A6KPE6XNFD", - "object_type": "customer", - "metric": "unsubscribed", - "timestamp": 1585250179 - }, - { - "data": { - "action_id": 36, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgABcRhIBqSp7kiPekGBIeVh" - }, - "event_id": "01E4C4G1S0AMNG0XVF2M7RPH5S", - "object_type": "email", - "metric": "drafted", - "timestamp": 1585250305 - }, - { - "data": { - "content_id": 1146, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=", - "failure_message": "550 5.5.0 Requested action not taken: mailbox unavailable", - "newsletter_id": 736, - "recipient": "test@example.com", - "subject": "Thanks for joining!" - }, - "event_id": "12ASDG7S9P6MAZPTJ78DAND9GDC", - "object_type": "email", - "metric": "bounced", - "timestamp": 1234567890 - }, - { - "data": { - "action_id": 36, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgABcRhIBqSp7kiPekGBIeVh", - "href": "http://google.com", - "link_id": 1, - "recipient": "test@example.com", - "subject": "hello" - }, - "event_id": "01E4C8BES5XT87ZWRJFTB35YJ3", - "object_type": "email", - "metric": "clicked", - "timestamp": 1585254348 - }, - { - "data": { - "action_id": 42, - "campaign_id": 23, - "content": "Welcome to the club, we are with you.", - "customer_id": "user-123", - "delivery_id": "RAECAAFwnUSneIa0ZXkmq8EdkAM==", - "headers": { - "Custom-Header": ["custom-value"] - }, - "identifiers": { - "id": "user-123" - }, - "recipient": "test@example.com", - "subject": "Thanks for signing up" - }, - "event_id": "01E2EMRMM6TZ12TF9WGZN0WJQT", - "metric": "sent", - "object_type": "email", - "timestamp": 1644227937 - }, - { - "data": { - "customer_id": "user-123", - "delivery_id": "REAC4wUAAYYJgQgkyRqwwEPeOA6Nfv==", - "identifiers": { - "cio_id": "7ef807109981", - "id": "user-123" - }, - "recipient": "test@example.com", - "subject": "Thanks for signing up", - "transactional_message_id": 2 - }, - "event_id": "01ER4R5WB62QWCNREKFB4DYXGR", - "metric": "delivered", - "object_type": "email", - "timestamp": 1675196819 - }, - { - "data": { - "action_id": 38, - "campaign_id": 6, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RAEABQFxN56fWzydfV4_EGvfobI=", - "failure_message": "NoDevicesSynced" - }, - "event_id": "01E4VSX8SZ0T9AQMH4Q16NRB89", - "object_type": "push", - "metric": "attempted", - "timestamp": 1585776075 - }, - { - "data": { - "action_id": 37, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", - "recipients": [ - { - "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof", - "device_platform": "android" - } - ] - }, - "event_id": "01E4C4HDQ7P1X9KTKF0ZX7PWHE", - "object_type": "push", - "metric": "sent", - "timestamp": 1585250350 - }, - { - "data": { - "action_id": 37, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", - "href": "ciosas://product/2", - "link_id": 1, - "recipients": [ - { - "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" - } - ] - }, - "event_id": "01E4V2SBHYK4TNTG8WKMP39G9R", - "object_type": "push", - "metric": "clicked", - "timestamp": 1585751829 - }, - { - "data": { - "action_id": 41, - "campaign_id": 7, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "ROk1AAIBcR4iT6mueuxiDtzO8HXv", - "failure_message": "Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309." - }, - "event_id": "01E4F3DCS83P8HT7R3E6DWQN1X", - "object_type": "sms", - "metric": "attempted", - "timestamp": 1234567890 - }, - { - "data": { - "action_id": 38, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgIBcRh6qzHz-8gKvscP2UZa", - "href": "https://app.com/verify", - "link_id": 1, - "recipient": "+18008675309" - }, - "event_id": "01E4XXPN42JDF4B1ATQKTZ8WHV", - "object_type": "sms", - "metric": "clicked", - "timestamp": 1585847161 - }, - { - "data": { - "action_id": 39, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgQBcRhNAufb0s30bmz5HD7Y", - "recipient": "#signups" - }, - "event_id": "01E4C4TQKD6KJ274870J5DE2HB", - "object_type": "slack", - "metric": "sent", - "timestamp": 1585250655 - }, - { - "data": { - "action_id": 39, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgQBcRhocpCJE3mFfwvRzNe6", - "href": "http://bing.com", - "link_id": 1, - "recipient": "#signups" - }, - "event_id": "01E4C6HJTBNDX18XC4B88M3Y2G", - "object_type": "slack", - "metric": "clicked", - "timestamp": 1585252451 - }, - { - "data": { - "action_id": 39, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgQBcRhIBqRiZAc0fyQiLvkC", - "failure_message": "value passed for channel was invalid" - }, - "event_id": "01E4C4HDQ77BCN0X23Z3WBE764", - "object_type": "slack", - "metric": "failed", - "timestamp": 1585250350 - }, - { - "data": { - "action_id": 40, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgEBcRhIBqSrYcXDr2ks6Pj9" - }, - "event_id": "01E4C4G1S04QCV1NASF4NWMQNR", - "object_type": "webhook", - "metric": "drafted", - "timestamp": 1585250305 - }, - { - "data": { - "action_id": 38, - "broadcast_id": 6, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RAECAQFxNeUBx6LqgjqrN1j-BJc=", - "failure_message": "Variable 'customer.test' is missing" - }, - "event_id": "01E4TYA2KA9T0XGHCRJ784B774", - "object_type": "webhook", - "metric": "attempted", - "timestamp": 1585747134 - }, - { - "data": { - "action_id": 40, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgEBcRhNAufr2aU82jtDZEh6", - "recipient": "https://test.example.com/process" - }, - "event_id": "01E4C6EP0HCKRHKFARMZ5XEH7A", - "object_type": "webhook", - "metric": "sent", - "timestamp": 1585252357 - }, - { - "data": { - "action_id": 40, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgEBcRhNAufr2aU82jtDZEh6", - "href": "http://bing.com", - "link_id": 1, - "recipient": "https://test.example.com/process" - }, - "event_id": "01E4C6F5N1Y54TVGJTN64Y1ZS9", - "object_type": "webhook", - "metric": "clicked", - "timestamp": 1585252373 - }, - { - "data": { - "action_id": 38, - "broadcast_id": 6, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RAECAQFxNeK3bC4SYqhQqFGBQrQ=", - "failure_message": "HTTP 404 Not Found []" - }, - "event_id": "01E4TY5FVB0ZQ4KVDKRME0XSYZ", - "object_type": "webhook", - "metric": "failed", - "timestamp": 1585746984 - }, - { - "data": { - "action_id": 37, - "broadcast_id": 9, - "customer_id": "0200102", - "identifiers": { - "id": "0200102" - }, - "delivery_id": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", - "href": "ciosas://product/2", - "link_id": 1, - "recipients": [ - { - "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" - } - ] - }, - "event_id": "01E4V2SBHYK4TNTG8WKMP39G9S", - "object_type": "push", - "metric": "delivered", - "timestamp": 1585751830 - } -] diff --git a/test/__tests__/data/customerio_source_output.json b/test/__tests__/data/customerio_source_output.json deleted file mode 100644 index 52df88e833..0000000000 --- a/test/__tests__/data/customerio_source_output.json +++ /dev/null @@ -1,651 +0,0 @@ -[ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Customer Subscribed", - "properties": { - "eventId": "01E4C4CT6YDC7Y5M7FE1GWWPQJ" - }, - "userId": "0200102" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Customer Subscribed", - "properties": { - "eventId": "01E4C4CT6YDC7Y5M7FE1GWWPQJ" - }, - "userId": "0200102" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Customer Subscribed", - "properties": { - "eventId": "01E4C4CT6YDC7Y5M7FE1GWWPQJ" - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:16:39.000Z", - "sentAt": "2020-03-26T19:16:39.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Customer Unsubscribed", - "properties": { - "eventId": "01E4C4C6P79C12J5A6KPE6XNFD" - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:16:19.000Z", - "sentAt": "2020-03-26T19:16:19.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Email Drafted", - "properties": { - "eventId": "01E4C4G1S0AMNG0XVF2M7RPH5S", - "deliveryId": "RPILAgABcRhIBqSp7kiPekGBIeVh", - "actionId": 36, - "broadcastId": 9 - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:18:25.000Z", - "sentAt": "2020-03-26T19:18:25.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Email Bounced", - "properties": { - "eventId": "12ASDG7S9P6MAZPTJ78DAND9GDC", - "deliveryId": "RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=", - "contentId": 1146, - "emailSubject": "Thanks for joining!", - "reason": "550 5.5.0 Requested action not taken: mailbox unavailable", - "newsletterId": 736 - }, - "userId": "0200102", - "originalTimestamp": "2009-02-13T23:31:30.000Z", - "sentAt": "2009-02-13T23:31:30.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Email Link Clicked", - "properties": { - "eventId": "01E4C8BES5XT87ZWRJFTB35YJ3", - "deliveryId": "RPILAgABcRhIBqSp7kiPekGBIeVh", - "actionId": 36, - "broadcastId": 9, - "emailSubject": "hello", - "link": { - "url": "http://google.com", - "id": 1 - } - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T20:25:48.000Z", - "sentAt": "2020-03-26T20:25:48.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Email Sent", - "properties": { - "eventId": "01E2EMRMM6TZ12TF9WGZN0WJQT", - "deliveryId": "RAECAAFwnUSneIa0ZXkmq8EdkAM==", - "actionId": 42, - "content": "Welcome to the club, we are with you.", - "emailSubject": "Thanks for signing up", - "campaignId": 23 - }, - "userId": "user-123", - "originalTimestamp": "2022-02-07T09:58:57.000Z", - "sentAt": "2022-02-07T09:58:57.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "cioId": "7ef807109981", - "email": "test@example.com" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Email Delivered", - "properties": { - "eventId": "01ER4R5WB62QWCNREKFB4DYXGR", - "deliveryId": "REAC4wUAAYYJgQgkyRqwwEPeOA6Nfv==", - "emailSubject": "Thanks for signing up", - "transactionalMessageId": 2 - }, - "userId": "user-123", - "originalTimestamp": "2023-01-31T20:26:59.000Z", - "sentAt": "2023-01-31T20:26:59.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Push Attempted", - "properties": { - "eventId": "01E4VSX8SZ0T9AQMH4Q16NRB89", - "deliveryId": "RAEABQFxN56fWzydfV4_EGvfobI=", - "actionId": 38, - "reason": "NoDevicesSynced", - "campaignId": 6 - }, - "userId": "0200102", - "originalTimestamp": "2020-04-01T21:21:15.000Z", - "sentAt": "2020-04-01T21:21:15.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Push Sent", - "properties": { - "eventId": "01E4C4HDQ7P1X9KTKF0ZX7PWHE", - "deliveryId": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", - "actionId": 37, - "broadcastId": 9, - "recipients": [ - { - "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof", - "device_platform": "android" - } - ] - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:19:10.000Z", - "sentAt": "2020-03-26T19:19:10.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Push Link Clicked", - "properties": { - "eventId": "01E4V2SBHYK4TNTG8WKMP39G9R", - "deliveryId": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", - "actionId": 37, - "broadcastId": 9, - "link": { - "url": "ciosas://product/2", - "id": 1 - }, - "recipients": [ - { - "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" - } - ] - }, - "userId": "0200102", - "originalTimestamp": "2020-04-01T14:37:09.000Z", - "sentAt": "2020-04-01T14:37:09.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "SMS Attempted", - "properties": { - "eventId": "01E4F3DCS83P8HT7R3E6DWQN1X", - "deliveryId": "ROk1AAIBcR4iT6mueuxiDtzO8HXv", - "actionId": 41, - "reason": "Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309.", - "campaignId": 7 - }, - "userId": "0200102", - "originalTimestamp": "2009-02-13T23:31:30.000Z", - "sentAt": "2009-02-13T23:31:30.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "+18008675309" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "SMS Link Clicked", - "properties": { - "eventId": "01E4XXPN42JDF4B1ATQKTZ8WHV", - "deliveryId": "RPILAgIBcRh6qzHz-8gKvscP2UZa", - "actionId": 38, - "broadcastId": 9, - "link": { - "url": "https://app.com/verify", - "id": 1 - } - }, - "userId": "0200102", - "originalTimestamp": "2020-04-02T17:06:01.000Z", - "sentAt": "2020-04-02T17:06:01.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "#signups" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Slack Message Sent", - "properties": { - "eventId": "01E4C4TQKD6KJ274870J5DE2HB", - "deliveryId": "RPILAgQBcRhNAufb0s30bmz5HD7Y", - "actionId": 39, - "broadcastId": 9 - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:24:15.000Z", - "sentAt": "2020-03-26T19:24:15.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "#signups" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Slack Message Link Clicked", - "properties": { - "eventId": "01E4C6HJTBNDX18XC4B88M3Y2G", - "deliveryId": "RPILAgQBcRhocpCJE3mFfwvRzNe6", - "actionId": 39, - "broadcastId": 9, - "link": { - "url": "http://bing.com", - "id": 1 - } - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:54:11.000Z", - "sentAt": "2020-03-26T19:54:11.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Slack Message Failed", - "properties": { - "eventId": "01E4C4HDQ77BCN0X23Z3WBE764", - "deliveryId": "RPILAgQBcRhIBqRiZAc0fyQiLvkC", - "actionId": 39, - "broadcastId": 9, - "reason": "value passed for channel was invalid" - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:19:10.000Z", - "sentAt": "2020-03-26T19:19:10.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Webhook Message Drafted", - "properties": { - "eventId": "01E4C4G1S04QCV1NASF4NWMQNR", - "deliveryId": "RPILAgEBcRhIBqSrYcXDr2ks6Pj9", - "actionId": 40, - "broadcastId": 9 - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:18:25.000Z", - "sentAt": "2020-03-26T19:18:25.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Webhook Message Attempted", - "properties": { - "eventId": "01E4TYA2KA9T0XGHCRJ784B774", - "deliveryId": "RAECAQFxNeUBx6LqgjqrN1j-BJc=", - "actionId": 38, - "broadcastId": 6, - "reason": "Variable 'customer.test' is missing" - }, - "userId": "0200102", - "originalTimestamp": "2020-04-01T13:18:54.000Z", - "sentAt": "2020-04-01T13:18:54.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "https://test.example.com/process" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Webhook Message Sent", - "properties": { - "eventId": "01E4C6EP0HCKRHKFARMZ5XEH7A", - "deliveryId": "RPILAgEBcRhNAufr2aU82jtDZEh6", - "actionId": 40, - "broadcastId": 9 - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:52:37.000Z", - "sentAt": "2020-03-26T19:52:37.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - }, - "traits": { - "email": "https://test.example.com/process" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Webhook Message Link Clicked", - "properties": { - "eventId": "01E4C6F5N1Y54TVGJTN64Y1ZS9", - "deliveryId": "RPILAgEBcRhNAufr2aU82jtDZEh6", - "actionId": 40, - "broadcastId": 9, - "link": { - "url": "http://bing.com", - "id": 1 - } - }, - "userId": "0200102", - "originalTimestamp": "2020-03-26T19:52:53.000Z", - "sentAt": "2020-03-26T19:52:53.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Webhook Message Failed", - "properties": { - "eventId": "01E4TY5FVB0ZQ4KVDKRME0XSYZ", - "deliveryId": "RAECAQFxNeK3bC4SYqhQqFGBQrQ=", - "actionId": 38, - "broadcastId": 6, - "reason": "HTTP 404 Not Found []" - }, - "userId": "0200102", - "originalTimestamp": "2020-04-01T13:16:24.000Z", - "sentAt": "2020-04-01T13:16:24.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Customer.io" - } - }, - "integrations": { - "Customer.io": false - }, - "type": "track", - "event": "Push Delivered", - "properties": { - "eventId": "01E4V2SBHYK4TNTG8WKMP39G9S", - "deliveryId": "RPILAgUBcRhIBqSfeiIwdIYJKxTY", - "actionId": 37, - "broadcastId": 9, - "link": { - "url": "ciosas://product/2", - "id": 1 - }, - "recipients": [ - { - "device_id": "eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof" - } - ] - }, - "userId": "0200102", - "originalTimestamp": "2020-04-01T14:37:10.000Z", - "sentAt": "2020-04-01T14:37:10.000Z" - } -] diff --git a/test/__tests__/data/formsort_source.json b/test/__tests__/data/formsort_source.json deleted file mode 100644 index d94cfd677b..0000000000 --- a/test/__tests__/data/formsort_source.json +++ /dev/null @@ -1,94 +0,0 @@ -[ - { - "description": "when we receive finalized as false", - "input": { - "answers": { - "yes": true, - "enter_email": "test@user.com", - "enter_name": "2022-11-17", - "yes_or_no": false - }, - "responder_uuid": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", - "flow_label": "new-flow-2022-11-25", - "variant_label": "main", - "variant_uuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea", - "finalized": false, - "created_at": "2022-11-25T14:41:22+00:00" - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Formsort" - }, - "page": { - "title": "new-flow-2022-11-25" - }, - "variantLabel": "main", - "variantUuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea" - }, - "integrations": { - "Formsort": false - }, - "type": "track", - "userId": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", - "originalTimestamp": "2022-11-25T14:41:22+00:00", - "properties": { - "yes": true, - "enter_email": "test@user.com", - "enter_name": "2022-11-17", - "yes_or_no": false - }, - "event": "FlowLoaded" - } - }, - { - "description": "when we receive finalized as true", - "input": { - "answers": { - "yes": true, - "enter_email": "test@user.com", - "enter_name": "2022-11-17", - "yes_or_no": false - }, - "responder_uuid": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", - "flow_label": "new-flow-2022-11-25", - "variant_label": "main", - "variant_uuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea", - "finalized": true, - "created_at": "2022-11-25T14:41:22+00:00" - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Formsort" - }, - "page": { - "title": "new-flow-2022-11-25" - }, - "variantLabel": "main", - "variantUuid": "0828efa7-7215-4e7d-a7ab-6c1079010cea" - }, - "integrations": { - "Formsort": false - }, - "type": "track", - "userId": "66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7", - "originalTimestamp": "2022-11-25T14:41:22+00:00", - "properties": { - "yes": true, - "enter_email": "test@user.com", - "enter_name": "2022-11-17", - "yes_or_no": false - }, - "event": "FlowFinalized" - } - } -] diff --git a/test/__tests__/data/gainsightpx_source.json b/test/__tests__/data/gainsightpx_source.json deleted file mode 100644 index 438d1d0cf6..0000000000 --- a/test/__tests__/data/gainsightpx_source.json +++ /dev/null @@ -1,1519 +0,0 @@ -[ - { - "description": "Identify Call", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "SIGN_UP", - "eventId": "1283c08b-f290-4bc4-9deb-75c7867d69ee", - "propertyKey": "AP-EOXPSEZGC5LA-2-1", - "date": 1665582808376, - "sessionId": "AP-EOXPSEZGC5LA-2-1665582441084-16821368", - "globalContext": {}, - "userType": "USER" - }, - "configId": "32f07727-d231-4c9d-881e-fb50b80bad63" - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "identify", - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "score": 0, - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "id": "New!", - "country": "India", - "account": { - "id": "IBM", - "name": "International Business Machine", - "numberOfEmployees": 0, - "numberOfUsers": 0 - } - }, - "userId": "New!", - "createdAt": "2022-10-12T13:53:11.753Z", - "originalTimestamp": "2022-10-12T13:53:11.753Z" - } - }, - { - "description": "Custom Track Call ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "CUSTOM", - "eventId": "df58cbd6-2736-4f8a-ad26-6049eac2e150", - "propertyKey": "AP-EOXPSEZGC5LA-2-1", - "date": 1665656881448, - "sessionId": "AP-EOXPSEZGC5LA-2-1665656622955-48127533", - "globalContext": {}, - "userType": "USER", - "eventName": "Product Clicked", - "attributes": { - "Audience Size": 5000, - "name": "TESTing TRACK CALL FIRST", - "Launched date": 1520532660000, - "Launched": true - }, - "url": "http://127.0.0.1:5501/GPXTEST2.html", - "referrer": "", - "remoteHost": "122.161.66.140" - }, - "configId": "32f07727-d231-4c9d-881e-fb50b80bad63" - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "ip": "122.161.66.140", - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-EOXPSEZGC5LA-2-1", - "Audience Size": 5000, - "name": "TESTing TRACK CALL FIRST", - "Launched date": 1520532660000, - "Launched": true, - "ip": "122.161.66.140", - "url": "http://127.0.0.1:5501/GPXTEST2.html" - }, - "userId": "New!", - "category": "CUSTOM", - "event": "Product Clicked", - "sentAt": "2022-10-13T10:28:01.448Z", - "originalTimestamp": "2022-10-13T10:28:01.448Z" - } - }, - { - "description": "Feedback Track Call ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "FEEDBACK", - "eventId": "d007bd76-decb-4a77-8456-d84fb15c6a83", - "propertyKey": "AP-E9VUBBLZ6BIS-2-1", - "date": 1665415753621, - "sessionId": "AP-E9VUBBLZ6BIS-2-1665415678379-45445457", - "globalContext": null, - "userType": "USER", - "subject": "feedback title", - "category": "Labels test", - "description": "feedback body", - "labels": ["492120f5-3573-11ec-bef0-42010a800545"], - "remoteHost": "122.161.66.140", - "source": "Knowledge Center Bot" - }, - "configId": "32f07727-d231-4c9d-881e-fb50b80bad63" - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ], - "ip": "122.161.66.140" - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-E9VUBBLZ6BIS-2-1", - "feedback": { - "labels": ["492120f5-3573-11ec-bef0-42010a800545"], - "description": "feedback body", - "subject": "feedback title", - "source": "Knowledge Center Bot" - }, - "ip": "122.161.66.140" - }, - "userId": "New!", - "category": "FEEDBACK", - "event": "Labels test", - "sentAt": "2022-10-10T15:29:13.621Z", - "originalTimestamp": "2022-10-10T15:29:13.621Z" - } - }, - { - "description": "Feature Match Track Call ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "FEATURE_MATCH", - "eventId": "ae1e5538-1736-4088-86d1-e90a10ffe901-05951b40-944f-4052-9a4a-51c74683f658", - "propertyKey": "AP-8MF5LPSWUBFW-2-1", - "date": 1665582808376, - "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", - "globalContext": { - "role": "Admin" - }, - "userType": "USER", - "featureId": "05951b40-944f-4052-9a4a-51c74683f658", - "featureName": "Charts" - } - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-8MF5LPSWUBFW-2-1", - "globalContext": { - "role": "Admin" - }, - "featureId": "05951b40-944f-4052-9a4a-51c74683f658" - }, - "userId": "New!", - "category": "FEATURE_MATCH", - "event": "Charts", - "sentAt": "2022-10-12T13:53:28.376Z", - "originalTimestamp": "2022-10-12T13:53:28.376Z" - } - }, - { - "description": "Segment Match Track Call and no userId and yes anonymousId as event.sessionId", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "SEGMENT", - "eventId": "ddb9ca94-beb1-449c-bdcd-b53190f8e784", - "propertyKey": "AP-8MF5LPSWUBFW-2-1", - "date": 1665582808376, - "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", - "globalContext": { - "role": "Admin" - }, - "userType": "USER", - "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845", - "segmentName": "Linux User" - } - }, - "output": { - "anonymousId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-8MF5LPSWUBFW-2-1", - "globalContext": { - "role": "Admin" - }, - "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845" - }, - "category": "SEGMENT", - "event": "Linux User", - "sentAt": "2022-10-12T13:53:28.376Z", - "originalTimestamp": "2022-10-12T13:53:28.376Z" - } - }, - { - "description": "No Match Track Call ", - "input": { - "event": { - "eventType": "Unavailable", - "eventId": "ddb9ca94-beb1-449c-bdcd-b53190f8e784", - "propertyKey": "AP-8MF5LPSWUBFW-2-1", - "date": 1601303075964, - "sessionId": "AP-8MF5LPSWUBFW-2-1601303023809-98881162", - "globalContext": { - "role": "Admin" - }, - "userType": "USER", - "segmentId": "e3ab2e48-24f9-4602-ab92-b9f1f4343845", - "segmentName": "Linux User" - } - }, - "output": { - "error": "Event type Unavailable not supported" - } - }, - { - "description": "Survey Track Call -> Multi Question Survey ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "SURVEY", - "eventId": "c9883e3b-05d4-4f96-8b9c-e2ce10430493", - "propertyKey": "AP-N6SV00EVMR1E-2-1", - "date": 1601303075964, - "sessionId": "AP-N6SV00EVMR1E-2-1605265939566-23853426", - "globalContext": { - "role": "Admin" - }, - "userType": "EMPTY_USER_TYPE", - "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", - "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", - "engagementName": "Quarterly Survey", - "surveyType": "Multi Question", - "interaction": "SINGLE_STEP_SURVEY_RESPONDED", - "score": 0, - "activation": "Auto", - "executionId": "1ad2d383-d1fa-425d-84f0-2a531e17a5d9", - "executionDate": 1605265939965, - "questionType": "Multi choice", - "questionId": "de9e6bf1-351c-46ec-907d-c985bd420c2b", - "questionHtml": "
Favorite travel destinations
", - "questionText": "Favorite travel destinations", - "answers": [ - { - "answerId": "563e2103-2906-4088-869f-bcccd185f288", - "answerHtml": "
Europe
", - "answerText": "Europe" - } - ] - } - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-N6SV00EVMR1E-2-1", - "globalContext": { - "role": "Admin" - }, - "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", - "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", - "surveyType": "Multi Question", - "interaction": "SINGLE_STEP_SURVEY_RESPONDED", - "survey": { - "activation": "Auto", - "questionType": "Multi choice", - "score": 0, - "questionId": "de9e6bf1-351c-46ec-907d-c985bd420c2b", - "questionHtml": "
Favorite travel destinations
", - "questionText": "Favorite travel destinations", - "answers": [ - { - "answerId": "563e2103-2906-4088-869f-bcccd185f288", - "answerHtml": "
Europe
", - "answerText": "Europe" - } - ] - } - }, - "userId": "New!", - "category": "SURVEY", - "event": "Quarterly Survey", - "sentAt": "2020-09-28T14:24:35.964Z", - "originalTimestamp": "2020-09-28T14:24:35.964Z" - } - }, - { - "description": "Survey Track Call -> NPS ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "SURVEY", - "eventId": "c9883e3b-05d4-4f96-8b9c-e2ce10430493", - "propertyKey": "AP-N6SV00EVMR1E-2-1", - "date": 1601303075964, - "sessionId": "AP-N6SV00EVMR1E-2-1605265939566-23853426", - "globalContext": { - "role": "Admin" - }, - "userType": "EMPTY_USER_TYPE", - "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", - "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", - "engagementName": "Quarterly Survey", - "surveyType": "Multi Question", - "interaction": "SINGLE_STEP_SURVEY_RESPONDED", - "score": 0, - "scoreType": null, - "stepNumber": null, - "userInput": "I like new features", - "activation": "Auto", - "executionId": "1ad2d383-d1fa-425d-84f0-2a531e17a5d9", - "executionDate": 1605265939965, - "questionType": "Open text question", - "questionHtml": "
\n
\n How was your experience?\n
\n
\n", - "questionText": "How was your experience?" - } - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-N6SV00EVMR1E-2-1", - "globalContext": { - "role": "Admin" - }, - "engagementId": "e5362226-75da-4ef6-999a-823727e3d7a7", - "contentType": "IN_APP_MULTIPLE_QUESTION_SURVEY", - "surveyType": "Multi Question", - "interaction": "SINGLE_STEP_SURVEY_RESPONDED", - "survey": { - "activation": "Auto", - "userInput": "I like new features", - "questionType": "Open text question", - "score": 0, - "questionHtml": "
\n
\n How was your experience?\n
\n
\n", - "questionText": "How was your experience?" - } - }, - "userId": "New!", - "category": "SURVEY", - "event": "Quarterly Survey", - "sentAt": "2020-09-28T14:24:35.964Z", - "originalTimestamp": "2020-09-28T14:24:35.964Z" - } - }, - { - "description": "Engagement Track Call ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "ENGAGEMENT", - "eventId": "6494e73a-976b-4ee5-b8a8-de9effff7e80", - "propertyKey": "AP-N6SV00EVMR1E-2-1", - "date": 1605262539389, - "sessionId": "AP-N6SV00EVMR1E-2-1605262502068-24197555", - "globalContext": { - "role": "Admin" - }, - "userType": "EMPTY_USER_TYPE", - "contentType": "IN_APP_DIALOG", - "engagementId": "83c30d4e-88c3-4054-a0fa-33451a6ea7fc", - "engagementType": "Dialog", - "engagementName": "Release Announcement", - "interaction": "VIEWED", - "stepNumber": 1, - "activation": "Auto", - "executionId": "b633945f-d4a5-404a-ae39-5ced5b542240", - "executionDate": 1605262539389 - } - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-N6SV00EVMR1E-2-1", - "engagementId": "83c30d4e-88c3-4054-a0fa-33451a6ea7fc", - "contentType": "IN_APP_DIALOG", - "engagementType": "Dialog", - "interaction": "VIEWED", - "globalContext": { - "role": "Admin" - }, - "engagement": { - "stepNumber": 1, - "activation": "Auto" - } - }, - "userId": "New!", - "category": "ENGAGEMENT", - "event": "Release Announcement", - "sentAt": "2020-11-13T10:15:39.389Z", - "originalTimestamp": "2020-11-13T10:15:39.389Z" - } - }, - { - "description": "SegmentIO S2S Track Call ", - "input": { - "user": { - "aptrinsicId": "cab9c469-8602-4933-acdb-68338fbb9ab1", - "identifyId": "New!", - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "lastSeenDate": 1665582808669, - "signUpDate": 1665582791753, - "firstVisitDate": 1665582791753, - "title": "Mr.", - "phone": "", - "score": 0, - "role": "", - "subscriptionId": "", - "accountId": "IBM", - "numberOfVisits": 1, - "location": { - "countryName": "India", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665582808376, - "lastModifiedDate": 1665582808717, - "customAttributes": null, - "globalUnsubscribe": false, - "sfdcContactId": "", - "lastVisitedUserAgentData": null, - "id": "New!", - "lastInferredLocation": null - }, - "account": { - "id": "IBM", - "name": "International Business Machine", - "trackedSubscriptionId": "", - "sfdcId": "", - "lastSeenDate": 1665582808669, - "dunsNumber": "", - "industry": "", - "numberOfEmployees": 0, - "sicCode": "", - "website": "", - "naicsCode": "", - "plan": "", - "location": { - "countryName": "", - "countryCode": "", - "stateName": "", - "stateCode": "", - "city": "", - "street": "", - "postalCode": "", - "continent": "", - "regionName": "", - "timeZone": "", - "coordinates": { - "latitude": 0, - "longitude": 0 - } - }, - "numberOfUsers": 0, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "createDate": 1665578567565, - "lastModifiedDate": 1665582808669, - "customAttributes": null, - "parentGroupId": "" - }, - "event": { - "eventType": "SEGMENT_IO", - "eventId": "ajs-next-69810a17571dc115ccead5281cc3fb7d", - "propertyKey": "AP-EOXPSEZGC5LA-2-1", - "date": 1666687235178, - "sessionId": "31a524fa-1490-48db-9600-adfb1fa95333", - "globalContext": {}, - "userType": "USER", - "segmentIOEvent": { - "pxPropertyKey": "AP-EOXPSEZGC5LA-2", - "type": "group", - "userId": "1001", - "anonymousId": "a4303a13-eb10-46d8-8935-d787daf1cfbd", - "context": { - "ip": "122.161.67.121", - "library": { - "name": "analytics.js", - "version": "next-1.45.0" - }, - "locale": "en-GB", - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36", - "page": { - "path": "/abc.html", - "title": "Engage Testing", - "url": "http://127.0.0.1:5501/abc.html" - } - }, - "messageId": "ajs-next-69810a17571dc115ccead5281cc3fb7d", - "receivedAt": "2022-10-25T08:40:35.184Z", - "sentAt": "2022-10-25T08:40:34.809Z", - "timestamp": "2022-10-25T08:40:35.178Z", - "traits": { - "name": "International Business Machine" - }, - "version": 2, - "channel": "client", - "groupId": "IBM" - } - } - }, - "output": { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "GAINSIGHTPX" - }, - "traits": { - "type": "USER", - "gender": "EMPTY_GENDER", - "email": "userEmail@address.com", - "firstName": "test", - "lastName": "rudderlabs", - "title": "Mr.", - "globalUnsubscribe": false, - "accountId": "IBM", - "numberOfVisits": 1, - "propertyKeys": ["AP-EOXPSEZGC5LA-2-1"], - "score": 0, - "id": "New!", - "country": "India", - "account": { - "numberOfEmployees": 0, - "numberOfUsers": 0, - "id": "IBM", - "name": "International Business Machine" - } - }, - "externalId": [ - { - "type": "gainsightpxAptrinsicId", - "id": "cab9c469-8602-4933-acdb-68338fbb9ab1" - } - ] - }, - "integrations": { - "GAINSIGHTPX": false - }, - "type": "track", - "properties": { - "propertyKey": "AP-EOXPSEZGC5LA-2-1", - "pxPropertyKey": "AP-EOXPSEZGC5LA-2", - "type": "group", - "userId": "1001", - "anonymousId": "a4303a13-eb10-46d8-8935-d787daf1cfbd", - "context": { - "ip": "122.161.67.121", - "library": { - "name": "analytics.js", - "version": "next-1.45.0" - }, - "locale": "en-GB", - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36", - "page": { - "path": "/abc.html", - "title": "Engage Testing", - "url": "http://127.0.0.1:5501/abc.html" - } - }, - "messageId": "ajs-next-69810a17571dc115ccead5281cc3fb7d", - "receivedAt": "2022-10-25T08:40:35.184Z", - "sentAt": "2022-10-25T08:40:34.809Z", - "timestamp": "2022-10-25T08:40:35.178Z", - "traits": { - "name": "International Business Machine" - }, - "version": 2, - "channel": "client", - "groupId": "IBM" - }, - "userId": "New!", - "category": "SEGMENT_IO", - "event": "SegmentIO Cloud Server", - "sentAt": "2022-10-25T08:40:35.178Z", - "originalTimestamp": "2022-10-25T08:40:35.178Z" - } - } -] diff --git a/test/__tests__/data/iterable_source_input.json b/test/__tests__/data/iterable_source_input.json deleted file mode 100644 index 798b0818c1..0000000000 --- a/test/__tests__/data/iterable_source_input.json +++ /dev/null @@ -1,600 +0,0 @@ -[ - { - "email": "test@rudderstack.com", - "eventName": "emailSubscribe", - "dataFields": { - "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", - "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", - "signupSource": "WebForm", - "email": "test@rudderstack.com", - "createdAt": "2022-04-19 03:33:50 +00:00", - "messageTypeIds": [], - "emailListIds": [1589748], - "channelIds": [] - } - }, - { - "eventName": "emailSubscribe", - "dataFields": { - "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", - "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", - "signupSource": "WebForm", - "email": "test@abcd.com", - "createdAt": "2022-04-19 03:33:50 +00:00", - "messageTypeIds": [], - "emailListIds": [1589748], - "channelIds": [] - } - }, - { - "email": "test@ruddstack.com", - "eventTitle": "smsReceived", - "dataFields": { - "fromPhoneNumber": "+16503926753", - "toPhoneNumber": "+14155824541", - "smsMessage": "Message text", - "email": "docs@iterable.com", - "createdAt": "2016-12-05 22:51:25 +00:00" - } - }, - { - "email": "test@rudderstack.com", - "eventName": "inAppSendSkip" - }, - { - "email": "test@rudderstack.com", - "eventName": "emailSend", - "dataFields": { - "contentId": 331201, - "email": "test@rudderstack.com", - "createdAt": "2016-12-02 20:21:04 +00:00", - "campaignId": 59667, - "templateId": 93849, - "messageId": "d0aa7801f91f4824997a631f3ed583c3", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c59667:t93849:docs@iterable.com" - } - }, - { - "email": "invalid_email@iterable.com", - "eventName": "emailBounce", - "dataFields": { - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2598, - "messageTypeId": 2870, - "experimentId": null, - "recipientState": "HardBounce", - "templateId": 167484, - "email": "invalid_email@iterable.com", - "createdAt": "2017-05-15 23:59:47 +00:00", - "campaignId": 114746, - "messageId": "d0aa7801f91f4824997a631f3ed583c3", - "emailId": "c114746:t167484:invalid_email@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "emailClick", - "dataFields": { - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36", - "ip": "162.245.22.184", - "templateId": 93849, - "userAgentDevice": "Mac", - "url": "https://www.iterable.com", - "canonicalUrlId": "3145668988", - "city": "San Francisco", - "region": "CA", - "email": "docs@iterable.com", - "createdAt": "2016-12-02 20:31:39 +00:00", - "campaignId": 59667, - "messageId": "d0aa7801f91f4824997a631f3ed583c3", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "linkUrl": "https://www.iterable.com", - "linkId": "3145668988", - "emailId": "c59667:t93849:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "emailComplaint", - "dataFields": { - "recipientState": "Complaint", - "templateId": 79190, - "email": "docs@iterable.com", - "createdAt": "2016-12-09 18:52:19 +00:00", - "campaignId": 49313, - "messageId": "d3c44d47b4994306b4db8d16a94db025", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "test template", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c49313:t79190:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "emailOpen", - "dataFields": { - "userAgent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", - "proxySource": "Gmail", - "ip": "66.249.84.204", - "templateId": 79190, - "device": "Gmail", - "email": "docs@iterable.com", - "createdAt": "2016-12-02 18:51:45 +00:00", - "campaignId": 49313, - "messageId": "210badf49fe54f2591d64ad0d055f4fb", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c49313:t79190:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "emailSendSkip", - "dataFields": { - "createdAt": "2019-08-07 18:56:10 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 721398, - "messageId": "98430abe1b9842c991ce221010121553", - "email": "docs@iterable.com" - } - }, - { - "email": "test@rudderstack.com", - "eventName": "emailSubscribe", - "dataFields": { - "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", - "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", - "signupSource": "WebForm", - "email": "test@abcd.com", - "createdAt": "2022-04-19 03:33:50 +00:00", - "messageTypeIds": [], - "emailListIds": [1589748], - "channelIds": [] - } - }, - { - "email": "docs@iterable.com", - "eventName": "emailUnSubscribe", - "dataFields": { - "campaignId": 1089024, - "messageId": "bf008db8ab194b65816398c05bf30f99", - "emailId": "c1089024:t1526112:docs@iterable.com", - "workflowName": "My test workflow", - "messageTypeIds": [], - "locale": null, - "templateId": 1526112, - "emailSubject": "Upcoming events!", - "labels": [], - "unsubSource": "EmailLink", - "createdAt": "2020-03-20 23:34:15 +00:00", - "templateName": "My test template", - "emailListIds": [], - "messageTypeId": 31082, - "experimentId": null, - "channelIds": [27447], - "campaignName": "My test campaign", - "workflowId": 76786, - "email": "docs@iterable.com", - "channelId": 27447 - } - }, - { - "email": "docs@iterable.com", - "userId": "1", - "eventName": "hostedUnsubscribeClick", - "dataFields": { - "country": "United States", - "city": "San Jose", - "campaignId": 1074721, - "ip": "192.168.0.1", - "userAgentDevice": "Mac", - "messageId": "ceb3d4d929fc406ca93b28a0ef1efff1", - "emailId": "c1074721:t1506266:docs@iterable.com", - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36", - "workflowName": "My workflow", - "locale": null, - "templateId": 1506266, - "emailSubject": "My email subject", - "url": "https://iterable.com", - "labels": [], - "createdAt": "2020-03-21 00:24:08 +00:00", - "templateName": "My email template", - "messageTypeId": 13406, - "experimentId": null, - "region": "CA", - "campaignName": "My email campaign", - "workflowId": 60102, - "email": "docs@iterable.com", - "channelId": 12466 - } - }, - { - "email": "docs@iterable.com", - "eventName": "inAppClick", - "dataFields": { - "email": "docs@iterable.com", - "createdAt": "2018-03-27 00:44:40 +00:00", - "campaignId": 269450 - } - }, - { - "email": "docs@iterable.com", - "eventName": "inAppOpen", - "dataFields": { - "email": "docs@iterable.com", - "createdAt": "2018-03-27 00:44:30 +00:00", - "campaignId": 269450 - } - }, - { - "email": "docs@iterable.com", - "eventName": "inAppSend", - "dataFields": { - "messageContext": { - "saveToInbox": false, - "trigger": "immediate" - }, - "campaignId": 732678, - "contentId": 18997, - "messageId": "vA16d48VVi4LQ5hMuZuquKzL0BXTdQJJUMJRjKnL1", - "workflowName": null, - "emailId": "c732678:t1032729:docs@iterable.com", - "locale": null, - "templateId": 1032729, - "inAppBody": "", - "email": "docs@iterable.com", - "createdAt": "2016-12-10 01:00:38 +00:00", - "campaignId": 74768, - "templateId": 113554, - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2203, - "messageTypeId": 2439, - "experimentId": null, - "payload": { - "path": "yourpath/subpath" - }, - "sound": "", - "badge": null, - "contentAvailable": false, - "deeplink": null, - "locale": null - } - }, - { - "email": "docs@iterable.com", - "eventName": "pushOpen", - "dataFields": { - "appAlreadyRunning": false, - "email": "docs@iterable.com", - "createdAt": "2016-12-08 01:25:22 +00:00", - "campaignId": 74768, - "templateId": 113554, - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2203, - "messageTypeId": 2439, - "experimentId": null, - "payload": { - "path": "shop_home" - }, - "sound": null, - "badge": null, - "contentAvailable": false, - "deeplink": null, - "locale": null - } - }, - { - "email": "docs@iterable.com", - "eventName": "pushSend", - "dataFields": { - "contentId": 6724, - "platformEndpoint": "", - "email": "docs@iterable.com", - "createdAt": "2016-12-08 00:53:11 +00:00", - "campaignId": 74758, - "templateId": 113541, - "messageId": "73f2d3f13cd04db0b56c6143b179adc5", - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 1744, - "messageTypeId": 1759, - "experimentId": null, - "payload": { - "a": "2" - }, - "sound": "", - "badge": "", - "contentAvailable": false, - "deeplink": null, - "locale": null - } - }, - { - "email": "docs@iterable.com", - "eventName": "pushSendSkip", - "dataFields": { - "createdAt": "2019-08-07 22:28:51 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 732667, - "messageId": "8306ae0c74324635b7554947c5ec0e56", - "email": "docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "pushUninstall", - "dataFields": { - "isGhostPush": false, - "platformEndpoint": "", - "email": "docs@iterable.com", - "createdAt": "2016-12-09 20:50:54 +00:00", - "campaignId": 74768, - "templateId": 113554, - "messageId": "73f2d3f13cd04db0b56c6143b179adc5", - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2203, - "messageTypeId": 2439, - "experimentId": null, - "payload": { - "path": "your_folder/30" - }, - "sound": "", - "badge": null, - "contentAvailable": false, - "deeplink": null, - "locale": null - } - }, - { - "email": "docs@iterable.com", - "eventName": "smsBounce", - "dataFields": { - "smsProviderResponse": { - "status": 404, - "message": "The requested resource /2010-04-01/Accounts/ACCOUNT_NUMBER/Messages.json was not found", - "code": 20404, - "more_info": "https://www.twilio.com/docs/errors/20404" - }, - "email": "docs@iterable.com", - "createdAt": "2016-12-05 22:43:24 +00:00", - "campaignId": 74003, - "templateId": 112561, - "smsMessage": "Here is example message, please respond with 'received'", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 4270, - "messageTypeId": 4769, - "experimentId": null, - "fromPhoneNumberId": 268, - "imageUrl": null, - "locale": null, - "emailId": "c74003:t112561:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "smsClick", - "dataFields": { - "campaignId": 1234567, - "campaignName": "My test campaign", - "workflowId": null, - "workflowName": null, - "templateName": "My template", - "locale": null, - "channelId": 98765, - "messageTypeId": 43210, - "experimentId": null, - "labels": [], - "smsMessage": "Test SMS! https://www.example.com", - "fromPhoneNumberId": 1234, - "imageUrl": null, - "clickedUrl": "https://www.example.com", - "email": "docs@iterable.com", - "createdAt": "2022-03-10 05:00:14 +00:00", - "templateId": 1112222, - "messageId": "ebd8f3cfc1f74353b423c5e0f3dd8b39", - "emailId": "c1234567:t9876543:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "smsReceived", - "dataFields": { - "fromPhoneNumber": "+16503926753", - "toPhoneNumber": "+14155824541", - "smsMessage": "Message text", - "email": "docs@iterable.com", - "createdAt": "2016-12-05 22:51:25 +00:00" - } - }, - { - "email": "docs@iterable.com", - "eventName": "smsSend", - "dataFields": { - "toPhoneNumber": "+16503926753", - "fromSMSSenderId": 258, - "contentId": 2086, - "email": "docs@iterable.com", - "createdAt": "2016-12-05 21:50:32 +00:00", - "campaignId": 73974, - "templateId": 112523, - "smsMessage": "Message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 4270, - "messageTypeId": 4769, - "experimentId": null, - "fromPhoneNumberId": 258, - "imageUrl": null, - "locale": null, - "emailId": "c73974:t112523:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "smsSendSkip", - "dataFields": { - "createdAt": "2019-08-07 18:49:48 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 729390, - "messageId": "2c780bf42f26485db0fc6571d2e0f6a0", - "email": "docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "emailSend", - "dataFields": { - "contentId": 274222, - "email": "docs@iterable.com", - "createdAt": "2016-12-02 18:51:40 +00:00", - "campaignId": 49313, - "transactionalData": { - "__comment": "transactionalData lists the fields contained in the dataFields property of the API call or event used to trigger the email, campaign, or workflow. transactionalData must contain no more than 12k characters in total." - }, - "templateId": 79190, - "messageId": "210badf49fe54f2591d64ad0d055f4fb", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c49313:t79190:docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "webPushSend", - "dataFields": { - "campaignId": 723636, - "browserToken": "cZn_inqLGPk:APA91bHsn5jo0-4V55RB38eCeLHj8ZXVJYciU7k6Kipbit3lrRlEe2Dt6bNzR4lSf6r2YNVdWY8l90hV0jmb_Y7y5ufcJ68xNI7wbsH6Q2jbEghA_Qo4kWbtu6A4NZN4gxc1xsEbyh7b", - "contentId": 3681, - "messageId": "af4c726ae76b48c7871b6d0d7760d47c", - "workflowName": "My workflow name", - "emailId": "c723636:t1020396:docs@iterable.com", - "locale": null, - "webPushIcon": null, - "templateId": 1020396, - "labels": [], - "createdAt": "2019-08-07 23:43:02 +00:00", - "templateName": "My template name", - "webPushMessage": "", - "messageTypeId": 9106, - "webPushBody": null, - "experimentId": null, - "webPushClickAction": null, - "campaignName": "My campaign name", - "workflowId": 53505, - "channelId": 8539, - "email": "docs@iterable.com" - } - }, - { - "email": "docs@iterable.com", - "eventName": "webPushSendSkip", - "dataFields": { - "createdAt": "2019-08-07 23:43:48 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 723636, - "messageId": "4238c918b20a41dfbe9a910275b76f12", - "email": "docs@iterable.com" - } - } -] diff --git a/test/__tests__/data/iterable_source_output.json b/test/__tests__/data/iterable_source_output.json deleted file mode 100644 index b1ff817241..0000000000 --- a/test/__tests__/data/iterable_source_output.json +++ /dev/null @@ -1,1084 +0,0 @@ -[ - { - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "test@rudderstack.com" - } - }, - "event": "emailSubscribe", - "integrations": { - "Iterable": false - }, - "properties": { - "channelIds": [], - "createdAt": "2022-04-19 03:33:50 +00:00", - "emailListIds": [1589748], - "messageTypeIds": [], - "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", - "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", - "signupSource": "WebForm" - }, - "receivedAt": "2022-04-19T03:33:50.000Z", - "timestamp": "2022-04-19T03:33:50.000Z", - "type": "track" - }, - { - "message": "Unknwon event type from Iterable" - }, - { - "message": "Unknwon event type from Iterable" - }, - { - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "test@rudderstack.com" - } - }, - "event": "inAppSendSkip", - "integrations": { - "Iterable": false - }, - "type": "track", - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7" - }, - { - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "test@rudderstack.com" - } - }, - "event": "emailSend", - "integrations": { - "Iterable": false - }, - "properties": { - "contentId": 331201, - "createdAt": "2016-12-02 20:21:04 +00:00", - "campaignId": 59667, - "templateId": 93849, - "messageId": "d0aa7801f91f4824997a631f3ed583c3", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c59667:t93849:docs@iterable.com" - }, - "receivedAt": "2016-12-02T20:21:04.000Z", - "timestamp": "2016-12-02T20:21:04.000Z", - "type": "track" - }, - { - "userId": "b053765f5d0d23b0d5e4dd960be9513f", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "invalid_email@iterable.com" - } - }, - "event": "emailBounce", - "integrations": { - "Iterable": false - }, - "properties": { - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2598, - "messageTypeId": 2870, - "experimentId": null, - "recipientState": "HardBounce", - "templateId": 167484, - "createdAt": "2017-05-15 23:59:47 +00:00", - "campaignId": 114746, - "messageId": "d0aa7801f91f4824997a631f3ed583c3", - "emailId": "c114746:t167484:invalid_email@iterable.com" - }, - "receivedAt": "2017-05-15T23:59:47.000Z", - "timestamp": "2017-05-15T23:59:47.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "emailClick", - "integrations": { - "Iterable": false - }, - "properties": { - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36", - "ip": "162.245.22.184", - "templateId": 93849, - "userAgentDevice": "Mac", - "url": "https://www.iterable.com", - "canonicalUrlId": "3145668988", - "city": "San Francisco", - "region": "CA", - "createdAt": "2016-12-02 20:31:39 +00:00", - "campaignId": 59667, - "messageId": "d0aa7801f91f4824997a631f3ed583c3", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "linkUrl": "https://www.iterable.com", - "linkId": "3145668988", - "emailId": "c59667:t93849:docs@iterable.com" - }, - "receivedAt": "2016-12-02T20:31:39.000Z", - "timestamp": "2016-12-02T20:31:39.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "emailComplaint", - "integrations": { - "Iterable": false - }, - "properties": { - "recipientState": "Complaint", - "templateId": 79190, - "createdAt": "2016-12-09 18:52:19 +00:00", - "campaignId": 49313, - "messageId": "d3c44d47b4994306b4db8d16a94db025", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "test template", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c49313:t79190:docs@iterable.com" - }, - "receivedAt": "2016-12-09T18:52:19.000Z", - "timestamp": "2016-12-09T18:52:19.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "emailOpen", - "integrations": { - "Iterable": false - }, - "properties": { - "userAgent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", - "proxySource": "Gmail", - "ip": "66.249.84.204", - "templateId": 79190, - "device": "Gmail", - "createdAt": "2016-12-02 18:51:45 +00:00", - "campaignId": 49313, - "messageId": "210badf49fe54f2591d64ad0d055f4fb", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c49313:t79190:docs@iterable.com" - }, - "receivedAt": "2016-12-02T18:51:45.000Z", - "timestamp": "2016-12-02T18:51:45.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "emailSendSkip", - "integrations": { - "Iterable": false - }, - "properties": { - "createdAt": "2019-08-07 18:56:10 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 721398, - "messageId": "98430abe1b9842c991ce221010121553" - }, - "receivedAt": "2019-08-07T18:56:10.000Z", - "timestamp": "2019-08-07T18:56:10.000Z", - "type": "track" - }, - { - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "test@rudderstack.com" - } - }, - "event": "emailSubscribe", - "integrations": { - "Iterable": false - }, - "properties": { - "channelIds": [], - "createdAt": "2022-04-19 03:33:50 +00:00", - "emailListIds": [1589748], - "messageTypeIds": [], - "profileUpdatedAt": "2022-04-19 03:33:50 +00:00", - "publicIdString": "ad474bf7-e785-480f-b9d0-861b85ab5bf5", - "signupSource": "WebForm" - }, - "receivedAt": "2022-04-19T03:33:50.000Z", - "timestamp": "2022-04-19T03:33:50.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "emailUnSubscribe", - "integrations": { - "Iterable": false - }, - "properties": { - "campaignId": 1089024, - "messageId": "bf008db8ab194b65816398c05bf30f99", - "emailId": "c1089024:t1526112:docs@iterable.com", - "workflowName": "My test workflow", - "messageTypeIds": [], - "locale": null, - "templateId": 1526112, - "emailSubject": "Upcoming events!", - "labels": [], - "unsubSource": "EmailLink", - "createdAt": "2020-03-20 23:34:15 +00:00", - "templateName": "My test template", - "emailListIds": [], - "messageTypeId": 31082, - "experimentId": null, - "channelIds": [27447], - "campaignName": "My test campaign", - "workflowId": 76786, - "channelId": 27447 - }, - "receivedAt": "2020-03-20T23:34:15.000Z", - "timestamp": "2020-03-20T23:34:15.000Z", - "type": "track" - }, - { - "userId": "1", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "hostedUnsubscribeClick", - "integrations": { - "Iterable": false - }, - "properties": { - "country": "United States", - "city": "San Jose", - "campaignId": 1074721, - "ip": "192.168.0.1", - "userAgentDevice": "Mac", - "messageId": "ceb3d4d929fc406ca93b28a0ef1efff1", - "emailId": "c1074721:t1506266:docs@iterable.com", - "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36", - "workflowName": "My workflow", - "locale": null, - "templateId": 1506266, - "emailSubject": "My email subject", - "url": "https://iterable.com", - "labels": [], - "createdAt": "2020-03-21 00:24:08 +00:00", - "templateName": "My email template", - "messageTypeId": 13406, - "experimentId": null, - "region": "CA", - "campaignName": "My email campaign", - "workflowId": 60102, - "channelId": 12466 - }, - "receivedAt": "2020-03-21T00:24:08.000Z", - "timestamp": "2020-03-21T00:24:08.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "inAppClick", - "integrations": { - "Iterable": false - }, - "properties": { - "createdAt": "2018-03-27 00:44:40 +00:00", - "campaignId": 269450 - }, - "receivedAt": "2018-03-27T00:44:40.000Z", - "timestamp": "2018-03-27T00:44:40.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "inAppOpen", - "integrations": { - "Iterable": false - }, - "properties": { - "createdAt": "2018-03-27 00:44:30 +00:00", - "campaignId": 269450 - }, - "receivedAt": "2018-03-27T00:44:30.000Z", - "timestamp": "2018-03-27T00:44:30.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "inAppSend", - "integrations": { - "Iterable": false - }, - "properties": { - "messageContext": { - "saveToInbox": false, - "trigger": "immediate" - }, - "campaignId": 732678, - "contentId": 18997, - "messageId": "vA16d48VVi4LQ5hMuZuquKzL0BXTdQJJUMJRjKnL1", - "workflowName": null, - "emailId": "c732678:t1032729:docs@iterable.com", - "locale": null, - "templateId": 1032729, - "inAppBody": "", - "createdAt": "2016-12-10 01:00:38 +00:00", - "campaignId": 74768, - "templateId": 113554, - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2203, - "messageTypeId": 2439, - "experimentId": null, - "payload": { - "path": "yourpath/subpath" - }, - "sound": "", - "badge": null, - "contentAvailable": false, - "deeplink": null, - "locale": null - }, - "receivedAt": "2016-12-10T01:00:38.000Z", - "timestamp": "2016-12-10T01:00:38.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "pushOpen", - "integrations": { - "Iterable": false - }, - "properties": { - "appAlreadyRunning": false, - "createdAt": "2016-12-08 01:25:22 +00:00", - "campaignId": 74768, - "templateId": 113554, - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2203, - "messageTypeId": 2439, - "experimentId": null, - "payload": { - "path": "shop_home" - }, - "sound": null, - "badge": null, - "contentAvailable": false, - "deeplink": null, - "locale": null - }, - "receivedAt": "2016-12-08T01:25:22.000Z", - "timestamp": "2016-12-08T01:25:22.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "pushSend", - "integrations": { - "Iterable": false - }, - "properties": { - "contentId": 6724, - "platformEndpoint": "", - "createdAt": "2016-12-08 00:53:11 +00:00", - "campaignId": 74758, - "templateId": 113541, - "messageId": "73f2d3f13cd04db0b56c6143b179adc5", - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 1744, - "messageTypeId": 1759, - "experimentId": null, - "payload": { - "a": "2" - }, - "sound": "", - "badge": "", - "contentAvailable": false, - "deeplink": null, - "locale": null - }, - "receivedAt": "2016-12-08T00:53:11.000Z", - "timestamp": "2016-12-08T00:53:11.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "pushSendSkip", - "integrations": { - "Iterable": false - }, - "properties": { - "createdAt": "2019-08-07 22:28:51 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 732667, - "messageId": "8306ae0c74324635b7554947c5ec0e56" - }, - "receivedAt": "2019-08-07T22:28:51.000Z", - "timestamp": "2019-08-07T22:28:51.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "pushUninstall", - "integrations": { - "Iterable": false - }, - "properties": { - "isGhostPush": false, - "platformEndpoint": "", - "createdAt": "2016-12-09 20:50:54 +00:00", - "campaignId": 74768, - "templateId": 113554, - "messageId": "73f2d3f13cd04db0b56c6143b179adc5", - "pushMessage": "Push message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 2203, - "messageTypeId": 2439, - "experimentId": null, - "payload": { - "path": "your_folder/30" - }, - "sound": "", - "badge": null, - "contentAvailable": false, - "deeplink": null, - "locale": null - }, - "receivedAt": "2016-12-09T20:50:54.000Z", - "timestamp": "2016-12-09T20:50:54.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "smsBounce", - "integrations": { - "Iterable": false - }, - "properties": { - "smsProviderResponse": { - "status": 404, - "message": "The requested resource /2010-04-01/Accounts/ACCOUNT_NUMBER/Messages.json was not found", - "code": 20404, - "more_info": "https://www.twilio.com/docs/errors/20404" - }, - "createdAt": "2016-12-05 22:43:24 +00:00", - "campaignId": 74003, - "templateId": 112561, - "smsMessage": "Here is example message, please respond with 'received'", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 4270, - "messageTypeId": 4769, - "experimentId": null, - "fromPhoneNumberId": 268, - "imageUrl": null, - "locale": null, - "emailId": "c74003:t112561:docs@iterable.com" - }, - "receivedAt": "2016-12-05T22:43:24.000Z", - "timestamp": "2016-12-05T22:43:24.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "smsClick", - "integrations": { - "Iterable": false - }, - "properties": { - "campaignId": 1234567, - "campaignName": "My test campaign", - "workflowId": null, - "workflowName": null, - "templateName": "My template", - "locale": null, - "channelId": 98765, - "messageTypeId": 43210, - "experimentId": null, - "labels": [], - "smsMessage": "Test SMS! https://www.example.com", - "fromPhoneNumberId": 1234, - "imageUrl": null, - "clickedUrl": "https://www.example.com", - "createdAt": "2022-03-10 05:00:14 +00:00", - "templateId": 1112222, - "messageId": "ebd8f3cfc1f74353b423c5e0f3dd8b39", - "emailId": "c1234567:t9876543:docs@iterable.com" - }, - "receivedAt": "2022-03-10T05:00:14.000Z", - "timestamp": "2022-03-10T05:00:14.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "smsReceived", - "integrations": { - "Iterable": false - }, - "properties": { - "fromPhoneNumber": "+16503926753", - "toPhoneNumber": "+14155824541", - "smsMessage": "Message text", - "createdAt": "2016-12-05 22:51:25 +00:00" - }, - "receivedAt": "2016-12-05T22:51:25.000Z", - "timestamp": "2016-12-05T22:51:25.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "smsSend", - "integrations": { - "Iterable": false - }, - "properties": { - "toPhoneNumber": "+16503926753", - "fromSMSSenderId": 258, - "contentId": 2086, - "createdAt": "2016-12-05 21:50:32 +00:00", - "campaignId": 73974, - "templateId": 112523, - "smsMessage": "Message text", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 4270, - "messageTypeId": 4769, - "experimentId": null, - "fromPhoneNumberId": 258, - "imageUrl": null, - "locale": null, - "emailId": "c73974:t112523:docs@iterable.com" - }, - "receivedAt": "2016-12-05T21:50:32.000Z", - "timestamp": "2016-12-05T21:50:32.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "smsSendSkip", - "integrations": { - "Iterable": false - }, - "properties": { - "createdAt": "2019-08-07 18:49:48 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 729390, - "messageId": "2c780bf42f26485db0fc6571d2e0f6a0" - }, - "receivedAt": "2019-08-07T18:49:48.000Z", - "timestamp": "2019-08-07T18:49:48.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "emailSend", - "integrations": { - "Iterable": false - }, - "properties": { - "contentId": 274222, - "createdAt": "2016-12-02 18:51:40 +00:00", - "campaignId": 49313, - "transactionalData": { - "__comment": "transactionalData lists the fields contained in the dataFields property of the API call or event used to trigger the email, campaign, or workflow. transactionalData must contain no more than 12k characters in total." - }, - "templateId": 79190, - "messageId": "210badf49fe54f2591d64ad0d055f4fb", - "emailSubject": "My subject", - "campaignName": "My campaign name", - "workflowId": null, - "workflowName": null, - "templateName": "My template name", - "channelId": 3420, - "messageTypeId": 3866, - "experimentId": null, - "emailId": "c49313:t79190:docs@iterable.com" - }, - "receivedAt": "2016-12-02T18:51:40.000Z", - "timestamp": "2016-12-02T18:51:40.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "webPushSend", - "integrations": { - "Iterable": false - }, - "properties": { - "campaignId": 723636, - "browserToken": "cZn_inqLGPk:APA91bHsn5jo0-4V55RB38eCeLHj8ZXVJYciU7k6Kipbit3lrRlEe2Dt6bNzR4lSf6r2YNVdWY8l90hV0jmb_Y7y5ufcJ68xNI7wbsH6Q2jbEghA_Qo4kWbtu6A4NZN4gxc1xsEbyh7b", - "contentId": 3681, - "messageId": "af4c726ae76b48c7871b6d0d7760d47c", - "workflowName": "My workflow name", - "emailId": "c723636:t1020396:docs@iterable.com", - "locale": null, - "webPushIcon": null, - "templateId": 1020396, - "labels": [], - "createdAt": "2019-08-07 23:43:02 +00:00", - "templateName": "My template name", - "webPushMessage": "", - "messageTypeId": 9106, - "webPushBody": null, - "experimentId": null, - "webPushClickAction": null, - "campaignName": "My campaign name", - "workflowId": 53505, - "channelId": 8539 - }, - "receivedAt": "2019-08-07T23:43:02.000Z", - "timestamp": "2019-08-07T23:43:02.000Z", - "type": "track" - }, - { - "userId": "0e13848b1c7e27eb5d88c5d35b70783e", - "context": { - "integration": { - "name": "Iterable", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "docs@iterable.com" - } - }, - "event": "webPushSendSkip", - "integrations": { - "Iterable": false - }, - "properties": { - "createdAt": "2019-08-07 23:43:48 +00:00", - "reason": "DuplicateMarketingMessage", - "campaignId": 723636, - "messageId": "4238c918b20a41dfbe9a910275b76f12" - }, - "receivedAt": "2019-08-07T23:43:48.000Z", - "timestamp": "2019-08-07T23:43:48.000Z", - "type": "track" - } -] diff --git a/test/__tests__/data/mailjet_source.json b/test/__tests__/data/mailjet_source.json deleted file mode 100644 index 6d9562e2c4..0000000000 --- a/test/__tests__/data/mailjet_source.json +++ /dev/null @@ -1,369 +0,0 @@ -[ - { - "description": "MailJet email open event", - "input": [ - { - "event": "open", - "time": 1664443614, - "MessageID": 94857068804950690, - "Message_GUID": "54d6cdec-f659-4547-8926-13d9c4126b82", - "email": "test@rudderstack.com", - "mj_campaign_id": 108760, - "mj_contact_id": 399962859, - "customcampaign": "mj.nl=58424", - "ip": "66.249.84.231", - "geo": "US", - "agent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", - "CustomID": "", - "Payload": "" - } - ], - "output": [ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "MailJet" - }, - "traits": { - "email": "test@rudderstack.com" - }, - "ip": "66.249.84.231", - "userAgent": "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)", - "externalId": [ - { - "type": "mailjetContactId", - "id": 399962859 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "open", - "properties": { - "ip": "66.249.84.231", - "customcampaign": "mj.nl=58424", - "mj_campaign_id": 108760, - "Payload": "" - }, - "originalTimestamp": "2022-09-29T09:26:54.000Z", - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7" - } - ] - }, - { - "description": "MailJet email bounce event where input event is of type ", - "input": { - "event": "bounce", - "time": 1664444171, - "MessageID": 55169098999352350, - "Message_GUID": "447d7eab-3335-4aba-9a51-09454bc14b81", - "email": "test@rudderstack.com", - "mj_campaign_id": 108892, - "mj_contact_id": 373142816, - "customcampaign": "mj.nl=58486", - "blocked": false, - "hard_bounce": false, - "error_related_to": "system", - "error": "connection issue" - }, - "output": [ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "MailJet" - }, - "traits": { - "email": "test@rudderstack.com" - }, - "externalId": [ - { - "type": "mailjetContactId", - "id": 373142816 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "bounce", - "properties": { - "customcampaign": "mj.nl=58486", - "mj_campaign_id": 108892 - }, - "originalTimestamp": "2022-09-29T09:36:11.000Z", - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7" - } - ] - }, - { - "description": "MailJet email sent event", - "input": [ - { - "event": "sent", - "time": 1664444171, - "MessageID": 92886743924596480, - "Message_GUID": "0230c73a-2b77-4aea-8ef2-ed15d0edc5fd", - "email": "test@rudderstack.com", - "mj_campaign_id": 108892, - "mj_contact_id": 372651182, - "customcampaign": "mj.nl=58486", - "smtp_reply": "250 2.0.0 OK DMARC:Quarantine 1664444171 u17-20020adfdd51000000b0022cc3f2bf13si3225188wrm.271 - gsmtp" - } - ], - "output": [ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "MailJet" - }, - "traits": { - "email": "test@rudderstack.com" - }, - "externalId": [ - { - "type": "mailjetContactId", - "id": 372651182 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "sent", - "properties": { - "customcampaign": "mj.nl=58486", - "mj_campaign_id": 108892 - }, - "originalTimestamp": "2022-09-29T09:36:11.000Z", - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7" - } - ] - }, - { - "description": "MailJet email bounce event", - "input": [ - { - "event": "bounce", - "time": 1664444170, - "MessageID": 56013522696710744, - "Message_GUID": "dbe4f0a3-4a5a-4784-a724-a9794d3c0444", - "email": "test@rudderstack.com", - "mj_campaign_id": 108892, - "mj_contact_id": 373142182, - "customcampaign": "mj.nl=58486", - "blocked": false, - "hard_bounce": false, - "error_related_to": "system", - "error": "connection issue" - } - ], - "output": [ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "MailJet" - }, - "traits": { - "email": "test@rudderstack.com" - }, - "externalId": [ - { - "type": "mailjetContactId", - "id": 373142182 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "bounce", - "properties": { - "customcampaign": "mj.nl=58486", - "mj_campaign_id": 108892 - }, - "originalTimestamp": "2022-09-29T09:36:10.000Z", - "userId": "5b6a3426dba2cb24e4f0aeec43bee9d7" - } - ] - }, - { - "description": "MailJet when no email is present", - "input": [ - { - "event": "bounce", - "time": 1664444170, - "MessageID": 56013522696710744, - "Message_GUID": "dbe4f0a3-4a5a-4784-a724-a9794d3c0444", - "mj_campaign_id": 108892, - "mj_contact_id": 373142182, - "customcampaign": "mj.nl=58486", - "blocked": false, - "hard_bounce": false, - "error_related_to": "system", - "error": "connection issue" - } - ], - "output": [ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "MailJet" - }, - "externalId": [ - { - "type": "mailjetContactId", - "id": 373142182 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "bounce", - "properties": { - "customcampaign": "mj.nl=58486", - "mj_campaign_id": 108892 - }, - "originalTimestamp": "2022-09-29T09:36:10.000Z" - } - ] - }, - { - "description": "MailJet Multiple payloads in single request", - "input": [ - { - "event": "open", - "time": 1704458040, - "MessageID": 987654, - "Message_GUID": "876r-oihugyf-7tfygh", - "email": "abc@r.com", - "mj_campaign_id": 321, - "mj_contact_id": 123, - "customcampaign": "test_campaign", - "url": "https://www.example.com/", - "ip": "ip_info", - "geo": "some geo info", - "agent": "mailjet api test" - }, - { - "event": "click", - "time": 1704458041, - "MessageID": 12345234567, - "Message_GUID": "12345-kjhgfd-2efv", - "email": "abc@r.com", - "mj_campaign_id": 12, - "mj_contact_id": 32532, - "customcampaign": "test_campaign", - "url": "https://www.example.com/", - "ip": "ip_info", - "geo": "some geo info", - "agent": "mailjet api test" - } - ], - "output": [ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "ip": "ip_info", - "integration": { - "name": "MailJet" - }, - "traits": { - "email": "abc@r.com" - }, - "page": { - "url": "https://www.example.com/" - }, - "userAgent": "mailjet api test", - "externalId": [ - { - "type": "mailjetContactId", - "id": 123 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "open", - "properties": { - "customcampaign": "test_campaign", - "mj_campaign_id": 321, - "ip": "ip_info", - "url": "https://www.example.com/" - }, - "userId": "593a5aff0b445b3b77a6d9676b7ec86e", - "originalTimestamp": "2024-01-05T12:34:00.000Z" - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "page": { - "url": "https://www.example.com/" - }, - - "integration": { - "name": "MailJet" - }, - "traits": { - "email": "abc@r.com" - }, - "userAgent": "mailjet api test", - "ip": "ip_info", - "externalId": [ - { - "type": "mailjetContactId", - "id": 32532 - } - ] - }, - "integrations": { - "MailJet": false - }, - "type": "track", - "event": "click", - "properties": { - "customcampaign": "test_campaign", - "mj_campaign_id": 12, - "ip": "ip_info", - "url": "https://www.example.com/" - }, - "userId": "593a5aff0b445b3b77a6d9676b7ec86e", - "originalTimestamp": "2024-01-05T12:34:01.000Z" - } - ] - } -] diff --git a/test/__tests__/data/mailmodo_source_input.json b/test/__tests__/data/mailmodo_source_input.json deleted file mode 100644 index 5ecc44b8f2..0000000000 --- a/test/__tests__/data/mailmodo_source_input.json +++ /dev/null @@ -1,153 +0,0 @@ -[ - { - "triggerData": { - "data": {}, - "triggerSource": "CsvList", - "email": "gouhgc@mailmodo.com", - "triggerDetails": "file:1a69df39hfbfg4e0b-8b5c-73776157aa37/7647792f-4ebc-4f9d-ac79-05fb0356137e", - "userId": "d3775892hvh4f2f-b9d5-e49810eb2cae", - "journeyId": "1a69df39hgvh4e0b-8b5c-73776157aa37", - "eventProperty": {} - } - }, - { - "fuuid": "27905", - "next-step-id": "success", - "total-steps": "3", - "responseId": "b9a5d224-cc5a-4e64-9800-5a3db9515fdf", - "recipientEmail": "test.rudderlabs21997@gmail.com", - "formId": "formosztd5", - "recordedAt": { - "ts": 1662695704, - "date": "2022-09-09", - "hour": 9, - "minute": 25 - }, - "submissionSource": "amp", - "elementjbtz42": "Everything ", - "element8jzo13": ["Reliable", "High Quality", "Useful"], - "recipientData": { - "email": "test.rudderlabs21997@gmail.com" - }, - "recommend": "9", - "liking": "upvote", - "satisfaction": "4", - "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", - "campaignName": "Campaign-testing" - }, - { - "triggerData": { - "data": {}, - "triggerSource": "Manual Add To List", - "email": "gou****@mailmodo.com", - "userId": "d3775892-****-4f2f-b9d5-e49810eb2cae", - "journeyId": "349e986e-f56c-****-bc3b-b5f13c3e34da", - "eventProperty": {} - } - }, - { - "triggerData": { - "data": {}, - "triggerSource": "Dashboard-change in property: first_name", - "email": "gou****@mailmodo.com", - "userId": "cc56708d-****-****-8c07-a4bfa5a7b79b", - "journeyId": "a78d7221-de34-47d8-81c6-5ad70cf4ee38", - "eventProperty": {} - } - }, - { - "triggerData": { - "data": {}, - "formSubmissionData": { - "element6ehxt3": "Te**", - "element6jkcy4": "Bang****", - "fuuid": "47949", - "next-step-id": "step7tr7n2", - "total-steps": "3", - "responseId": "4a8bfda7-****-4a8c-9cd1-a30d30a6dab9", - "recipientEmail": "gou****@mailmodo.com", - "formId": "formmqxnu2", - "recordedAt": { - "ts": 1657097786, - "date": "2022-07-06", - "hour": 14, - "minute": 26 - }, - "submissionSource": "amp" - }, - "email": "gou****@mailmodo.com", - "triggerSource": "form submission", - "userId": "11bff3e8-****-4e93-a533-fd8f9defc768", - "journeyId": "03664747-****-412e-8790-de9e9abe96a5", - "eventProperty": {} - } - }, - { - "triggerData": { - "data": {}, - "eventProperty": { - "Name": "APPLE iPhone 13 (Blue, 128 GB)", - "Category": "Mobiles", - "Is Purchased": "false", - "Price": "829", - "Currency": "USD" - }, - "triggerSource": "New Custom Event Trigger - Product Viewed", - "email": "gou****@mailmodo.com", - "userId": "d3775892-****-4f2f-b9d5-e49810eb2cae", - "journeyId": "3f135bf7-****-4e31-b265-f61cfe1bd423" - } - }, - { - "triggerData": { - "email": "gou****@mailmodo.com", - "data": {}, - "userId": "d3775892-****-4f2f-b9d5-e49810eb2cae", - "journeyId": "b1ee6bf6-****-4b5a-b7b5-0637853cd8c3", - "triggerSource": "Api", - "eventProperty": {} - } - }, - { - "eventData": { - "type": "html" - }, - "triggerData": { - "data": {}, - "triggerSource": "CsvList", - "email": "gou****@mailmodo.com", - "triggerDetails": "file:5d31c2b4-****-4a84-acd3-834cae80231b/5a61e0b8-b6f6-4d7d-abf2-90357d6638af", - "userId": "cc56708d-****-4fea-8c07-a4bfa5a7b79b", - "journeyId": "5d31c2b4-****-4a84-acd3-834cae80231b", - "eventProperty": {} - }, - "lastCampaignEmailRef": "064c76e7-****-4780-a001-226c066aaa12", - "lastCampaignId": "31422f76-****-4a72-a630-dd6f9f615bc3" - }, - { - "fuuid": "98255", - "next-step-id": "success", - "total-steps": "3", - "responseId": "ad20a980-4fce-44b6-887d-2236df514a76", - "recipientEmail": "test@rudderstack.com", - "formId": "formosztd5", - "recordedAt": { - "ts": 1662695887, - "date": "2022-09-09", - "hour": 9, - "minute": 28 - }, - "submissionSource": "amp", - "elementjbtz42": "peace", - "element8jzo13": ["Useful"], - "recipientData": { - "email": "test@rudderstack.com", - "first_name": "abcda" - }, - "recommend": "1", - "liking": "downvote", - "satisfaction": "1", - "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", - "campaignName": "Campaign-testing" - } -] diff --git a/test/__tests__/data/mailmodo_source_output.json b/test/__tests__/data/mailmodo_source_output.json deleted file mode 100644 index 3ffcf147f1..0000000000 --- a/test/__tests__/data/mailmodo_source_output.json +++ /dev/null @@ -1,315 +0,0 @@ -[ - { - "anonymousId": "f43848cce166e51b097cbed2851adc16ed9d4c341928f1c790215c50cefb59b0", - "context": { - "externalId": [ - { - "id": "d3775892hvh4f2f-b9d5-e49810eb2cae", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gouhgc@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "CsvList", - "integrations": { - "Mailmodo": false - }, - "properties": { - "triggerData.triggerSource": "CsvList", - "triggerData.triggerDetails": "file:1a69df39hfbfg4e0b-8b5c-73776157aa37/7647792f-4ebc-4f9d-ac79-05fb0356137e", - "triggerData.journeyId": "1a69df39hgvh4e0b-8b5c-73776157aa37" - }, - "type": "track" - }, - { - "anonymousId": "a80b34ec43ca959c7b8e5116ac626c3cf8561f62616e000a01729a8a900cc0a0", - "context": { - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "test.rudderlabs21997@gmail.com" - } - }, - "event": "Form Submitted", - "integrations": { - "Mailmodo": false - }, - "originalTimestamp": "2022-09-09T03:55:04.000Z", - "properties": { - "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", - "campaignName": "Campaign-testing", - "element8jzo13[0]": "Reliable", - "element8jzo13[1]": "High Quality", - "element8jzo13[2]": "Useful", - "elementjbtz42": "Everything ", - "formId": "formosztd5", - "fuuid": "27905", - "liking": "upvote", - "next-step-id": "success", - "recommend": "9", - "responseId": "b9a5d224-cc5a-4e64-9800-5a3db9515fdf", - "satisfaction": "4", - "submissionSource": "amp", - "total-steps": "3" - }, - "type": "track" - }, - { - "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", - "context": { - "externalId": [ - { - "id": "d3775892-****-4f2f-b9d5-e49810eb2cae", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gou****@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "Manual Add To List", - "integrations": { - "Mailmodo": false - }, - "properties": { - "triggerData.triggerSource": "Manual Add To List", - "triggerData.journeyId": "349e986e-f56c-****-bc3b-b5f13c3e34da" - }, - "type": "track" - }, - { - "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", - "context": { - "externalId": [ - { - "id": "cc56708d-****-****-8c07-a4bfa5a7b79b", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gou****@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "Dashboard-change in property: first_name", - "integrations": { - "Mailmodo": false - }, - "properties": { - "triggerData.triggerSource": "Dashboard-change in property: first_name", - "triggerData.journeyId": "a78d7221-de34-47d8-81c6-5ad70cf4ee38" - }, - "type": "track" - }, - { - "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", - "context": { - "externalId": [ - { - "id": "11bff3e8-****-4e93-a533-fd8f9defc768", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gou****@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "form submission", - "integrations": { - "Mailmodo": false - }, - "originalTimestamp": "2022-07-06T08:56:26.000Z", - "properties": { - "triggerData.triggerSource": "form submission", - "triggerData.formSubmissionData.element6ehxt3": "Te**", - "triggerData.formSubmissionData.element6jkcy4": "Bang****", - "triggerData.formSubmissionData.formId": "formmqxnu2", - "triggerData.formSubmissionData.fuuid": "47949", - "triggerData.formSubmissionData.next-step-id": "step7tr7n2", - "triggerData.formSubmissionData.responseId": "4a8bfda7-****-4a8c-9cd1-a30d30a6dab9", - "triggerData.formSubmissionData.submissionSource": "amp", - "triggerData.formSubmissionData.total-steps": "3", - "triggerData.journeyId": "03664747-****-412e-8790-de9e9abe96a5" - }, - "type": "track" - }, - { - "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", - "context": { - "externalId": [ - { - "id": "d3775892-****-4f2f-b9d5-e49810eb2cae", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gou****@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "New Custom Event Trigger - Product Viewed", - "integrations": { - "Mailmodo": false - }, - "properties": { - "triggerData.eventProperty.Category": "Mobiles", - "triggerData.eventProperty.Currency": "USD", - "triggerData.eventProperty.Is Purchased": "false", - "triggerData.eventProperty.Name": "APPLE iPhone 13 (Blue, 128 GB)", - "triggerData.eventProperty.Price": "829", - "triggerData.journeyId": "3f135bf7-****-4e31-b265-f61cfe1bd423", - "triggerData.triggerSource": "New Custom Event Trigger - Product Viewed" - }, - "type": "track" - }, - { - "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", - "context": { - "externalId": [ - { - "id": "d3775892-****-4f2f-b9d5-e49810eb2cae", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gou****@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "Api", - "integrations": { - "Mailmodo": false - }, - "properties": { - "triggerData.triggerSource": "Api", - "triggerData.journeyId": "b1ee6bf6-****-4b5a-b7b5-0637853cd8c3" - }, - "type": "track" - }, - { - "anonymousId": "26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92", - "context": { - "externalId": [ - { - "id": "cc56708d-****-4fea-8c07-a4bfa5a7b79b", - "type": "mailmodoUserId" - } - ], - "traits": { - "email": "gou****@mailmodo.com" - }, - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "event": "CsvList", - "integrations": { - "Mailmodo": false - }, - "properties": { - "eventData.type": "html", - "lastCampaignEmailRef": "064c76e7-****-4780-a001-226c066aaa12", - "lastCampaignId": "31422f76-****-4a72-a630-dd6f9f615bc3", - "triggerData.journeyId": "5d31c2b4-****-4a84-acd3-834cae80231b", - "triggerData.triggerDetails": "file:5d31c2b4-****-4a84-acd3-834cae80231b/5a61e0b8-b6f6-4d7d-abf2-90357d6638af", - "triggerData.triggerSource": "CsvList" - }, - "type": "track" - }, - { - "anonymousId": "1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd", - "context": { - "integration": { - "name": "Mailmodo", - "version": "1.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "email": "test@rudderstack.com", - "first_name": "abcda" - } - }, - "event": "Form Submitted", - "integrations": { - "Mailmodo": false - }, - "originalTimestamp": "2022-09-09T03:58:07.000Z", - "properties": { - "fuuid": "98255", - "next-step-id": "success", - "total-steps": "3", - "responseId": "ad20a980-4fce-44b6-887d-2236df514a76", - "formId": "formosztd5", - "submissionSource": "amp", - "elementjbtz42": "peace", - "element8jzo13[0]": "Useful", - "recommend": "1", - "liking": "downvote", - "satisfaction": "1", - "campaignId": "0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd", - "campaignName": "Campaign-testing" - }, - "type": "track" - } -] diff --git a/test/__tests__/data/monday_source_input.json b/test/__tests__/data/monday_source_input.json deleted file mode 100644 index bb4f729460..0000000000 --- a/test/__tests__/data/monday_source_input.json +++ /dev/null @@ -1,125 +0,0 @@ -[ - { - "event": { - "userId": 33556506, - "originalTriggerUuid": null, - "boardId": 3139815405, - "pulseId": 3160188786, - "pulseName": "New Sprint Item", - "groupId": "topics", - "groupName": "Group Title", - "groupColor": "#579bfc", - "isTopGroup": true, - "columnValues": {}, - "app": "monday", - "type": "create_pulse", - "triggerTime": "2022-08-30T09:02:39.191Z", - "subscriptionId": 150881106, - "triggerUuid": "049869226bf6711705c62e301a2c3eee" - } - }, - { - "event": { - "userId": 33556506, - "originalTriggerUuid": null, - "boardId": 3139815405, - "itemId": 3160188786, - "itemName": "New Sprint Item", - "app": "monday", - "type": "delete_pulse", - "triggerTime": "2022-08-30T09:06:09.176Z", - "subscriptionId": 150882006, - "triggerUuid": "4e4f87c8255c4ba4ba2f5e9934cb6d40" - } - }, - { - "event": { - "userId": 33556506, - "originalTriggerUuid": null, - "boardId": 3139815405, - "groupId": "topics", - "pulseId": 3160181387, - "pulseName": "New Sprint Item", - "columnId": "status", - "columnType": "color", - "columnTitle": "Status", - "value": { - "label": { - "index": 1, - "text": "Done", - "style": { - "color": "#00c875", - "border": "#00B461", - "var_name": "green-shadow" - }, - "is_done": true - }, - "post_id": null - }, - "previousValue": null, - "changedAt": 1661859406.8970098, - "isTopGroup": true, - "app": "monday", - "type": "update_column_value", - "triggerTime": "2022-08-30T11:36:47.406Z", - "subscriptionId": 150894742, - "triggerUuid": "51730730740a9d00ec45203bd392a9bd" - } - }, - { - "event": { - "userId": 33556506, - "originalTriggerUuid": null, - "boardId": 3139815405, - "groupId": "topics", - "pulseId": 3160181387, - "value": { - "name": "New Sprint Item renamed" - }, - "previousValue": { - "name": "New Sprint Item" - }, - "app": "monday", - "type": "update_name", - "triggerTime": "2022-08-30T11:40:17.351Z", - "subscriptionId": 150910867, - "triggerUuid": "05ce13d32d0256c4fb7dd5de25b1a1ba" - } - }, - { - "event": { - "userId": 33556506, - "originalTriggerUuid": null, - "boardId": 3160805239, - "pulseId": 3161163765, - "pulseName": "new subitem", - "groupId": "topics", - "groupName": "Subitems", - "groupColor": "#579bfc", - "isTopGroup": true, - "columnValues": {}, - "app": "monday", - "type": "create_pulse", - "triggerTime": "2022-08-30T12:56:27.281Z", - "subscriptionId": 150911592, - "triggerUuid": "70a2219427804e47a508a91b5c244543", - "parentItemId": "3160181387", - "parentItemBoardId": "3139815405", - "itemId": 3161163765 - } - }, - { - "event": { - "userId": 33556506, - "originalTriggerUuid": null, - "boardId": 3139815405, - "itemId": 3160181387, - "itemName": "New Sprint Item renamed", - "app": "monday", - "type": "archive_pulse", - "triggerTime": "2022-08-30T12:58:15.844Z", - "subscriptionId": 150925947, - "triggerUuid": "aa8bd5dbb6fd592aedd57322dd776379" - } - } -] diff --git a/test/__tests__/data/monday_source_output.json b/test/__tests__/data/monday_source_output.json deleted file mode 100644 index cf636d818a..0000000000 --- a/test/__tests__/data/monday_source_output.json +++ /dev/null @@ -1,251 +0,0 @@ -[ - { - "type": "track", - "event": "Create Pulse", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "externalId": [ - { - "id": 33556506, - "type": "mondayUserId" - } - ], - "integration": { - "name": "MONDAY" - } - }, - "timestamp": "2022-08-30T09:02:39.191Z", - "properties": { - "app": "monday", - "type": "create_pulse", - "boardId": 3139815405, - "groupId": "topics", - "pulseId": 3160188786, - "groupName": "Group Title", - "pulseName": "New Sprint Item", - "groupColor": "#579bfc", - "isTopGroup": true, - "triggerUuid": "049869226bf6711705c62e301a2c3eee", - "columnValues": {}, - "subscriptionId": 150881106, - "originalTriggerUuid": null - }, - "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", - "integrations": { - "MONDAY": false - }, - "originalTimestamp": "2022-08-30T09:02:39.191Z" - }, - { - "type": "track", - "event": "Delete Pulse", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "externalId": [ - { - "id": 33556506, - "type": "mondayUserId" - } - ], - "integration": { - "name": "MONDAY" - } - }, - "timestamp": "2022-08-30T09:06:09.176Z", - "properties": { - "app": "monday", - "type": "delete_pulse", - "itemId": 3160188786, - "boardId": 3139815405, - "itemName": "New Sprint Item", - "triggerUuid": "4e4f87c8255c4ba4ba2f5e9934cb6d40", - "subscriptionId": 150882006, - "originalTriggerUuid": null - }, - "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", - "integrations": { - "MONDAY": false - }, - "originalTimestamp": "2022-08-30T09:06:09.176Z" - }, - { - "type": "track", - "event": "Update Column Value", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "externalId": [ - { - "id": 33556506, - "type": "mondayUserId" - } - ], - "integration": { - "name": "MONDAY" - } - }, - "timestamp": "2022-08-30T11:36:47.406Z", - "properties": { - "app": "monday", - "type": "update_column_value", - "value": { - "label": { - "text": "Done", - "index": 1, - "style": { - "color": "#00c875", - "border": "#00B461", - "var_name": "green-shadow" - }, - "is_done": true - }, - "post_id": null - }, - "boardId": 3139815405, - "groupId": "topics", - "pulseId": 3160181387, - "columnId": "status", - "changedAt": 1661859406.8970098, - "pulseName": "New Sprint Item", - "columnType": "color", - "isTopGroup": true, - "columnTitle": "Status", - "triggerUuid": "51730730740a9d00ec45203bd392a9bd", - "previousValue": null, - "subscriptionId": 150894742, - "originalTriggerUuid": null - }, - "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", - "integrations": { - "MONDAY": false - }, - "originalTimestamp": "2022-08-30T11:36:47.406Z" - }, - { - "type": "track", - "event": "Update Name", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "externalId": [ - { - "id": 33556506, - "type": "mondayUserId" - } - ], - "integration": { - "name": "MONDAY" - } - }, - "timestamp": "2022-08-30T11:40:17.351Z", - "properties": { - "app": "monday", - "type": "update_name", - "value": { - "name": "New Sprint Item renamed" - }, - "boardId": 3139815405, - "groupId": "topics", - "pulseId": 3160181387, - "triggerUuid": "05ce13d32d0256c4fb7dd5de25b1a1ba", - "previousValue": { - "name": "New Sprint Item" - }, - "subscriptionId": 150910867, - "originalTriggerUuid": null - }, - "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", - "integrations": { - "MONDAY": false - }, - "originalTimestamp": "2022-08-30T11:40:17.351Z" - }, - { - "type": "track", - "event": "Create Pulse", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "externalId": [ - { - "id": 33556506, - "type": "mondayUserId" - } - ], - "integration": { - "name": "MONDAY" - } - }, - "timestamp": "2022-08-30T12:56:27.281Z", - "properties": { - "app": "monday", - "type": "create_pulse", - "itemId": 3161163765, - "boardId": 3160805239, - "groupId": "topics", - "pulseId": 3161163765, - "groupName": "Subitems", - "pulseName": "new subitem", - "groupColor": "#579bfc", - "isTopGroup": true, - "triggerUuid": "70a2219427804e47a508a91b5c244543", - "columnValues": {}, - "parentItemId": "3160181387", - "subscriptionId": 150911592, - "parentItemBoardId": "3139815405", - "originalTriggerUuid": null - }, - "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", - "integrations": { - "MONDAY": false - }, - "originalTimestamp": "2022-08-30T12:56:27.281Z" - }, - { - "type": "track", - "event": "Archive Pulse", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "externalId": [ - { - "id": 33556506, - "type": "mondayUserId" - } - ], - "integration": { - "name": "MONDAY" - } - }, - "timestamp": "2022-08-30T12:58:15.844Z", - "properties": { - "app": "monday", - "type": "archive_pulse", - "itemId": 3160181387, - "boardId": 3139815405, - "itemName": "New Sprint Item renamed", - "triggerUuid": "aa8bd5dbb6fd592aedd57322dd776379", - "subscriptionId": 150925947, - "originalTriggerUuid": null - }, - "anonymousId": "6f0a3dc76a335860e17fa1d8ab779742e2ca", - "integrations": { - "MONDAY": false - }, - "originalTimestamp": "2022-08-30T12:58:15.844Z" - } -] diff --git a/test/__tests__/data/olark_source.json b/test/__tests__/data/olark_source.json deleted file mode 100644 index 96707bfbb2..0000000000 --- a/test/__tests__/data/olark_source.json +++ /dev/null @@ -1,299 +0,0 @@ -[ - { - "description": "Olark webhook response", - "input": { - "kind": "Conversation", - "id": "ho6HrHxoabmm6q0G103JU0JFaor0BobA", - "manuallySubmitted": false, - "items": [ - { - "kind": "OfflineMessage", - "timestamp": "1669285628.796693", - "body": "name: test rudderlabs\nemail: ruddertest@gmail.com\nMessage: I am Fine" - } - ], - "tags": [], - "visitor": { - "kind": "Visitor", - "id": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", - "fullName": "test", - "emailAddress": "ruddertest@gmail.com", - "ip": "", - "country": "India", - "countryCode": "IN", - "browser": "Chrome 105.0.0.0", - "operatingSystem": "Macintosh", - "conversationBeginPage": "http://localhost:5503/" - } - }, - "output": [ - { - "type": "track", - "event": "Conversation", - "traits": {}, - "userId": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", - "context": { - "os": { - "name": "Macintosh" - }, - "page": { - "url": "http://localhost:5503/" - }, - "traits": { - "name": "test", - "email": "ruddertest@gmail.com", - "country": "India" - }, - "browser": { - "name": "Chrome", - "version": "105.0.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Olark" - } - }, - "properties": { - "tags": [], - "items": [ - { - "body": "name: test rudderlabs\nemail: ruddertest@gmail.com\nMessage: I am Fine", - "kind": "OfflineMessage", - "timestamp": "1669285628.796693" - } - ] - }, - "integrations": { - "Olark": false - } - } - ] - }, - { - "description": "Olark webhook response", - "input": { - "kind": "Conversation", - "id": "NOTAREALTRANSCRIPT5LGcbVTa3hKBRB", - "manuallySubmitted": false, - "items": [ - { - "kind": "MessageToVisitor", - "nickname": "Olark operator", - "operatorId": "6208911878914048", - "timestamp": "1473774819.263083", - "body": "Hi from an operator" - }, - { - "kind": "MessageToOperator", - "nickname": "Returning Visitor | USA (San Francisco, CA) #7617", - "timestamp": "1473774821.411154", - "body": "Hi from a visitor", - "visitor_nickname": "Olark Visitor" - } - ], - "tags": ["test_example"], - "visitor": { - "kind": "Visitor", - "id": "NOTAREALVISITORIDS5LGl6QUrK2OaPP", - "fullName": "Olark", - "phoneNumber": "5555555555", - "emailAddress": "support+integrationtest@olark.com", - "ip": "", - "city": "San Francisco", - "region": "CA", - "country": "United States", - "countryCode": "US", - "organization": "Visitor Organization", - "browser": "Internet Explorer 11", - "operatingSystem": "Windows", - "referrer": "http://www.olark.com", - "conversationBeginPage": "http://www.olark.com", - "chat_feedback": { - "overall_chat": 4, - "responsiveness": 5, - "knowledge": 4, - "friendliness": 5 - } - }, - "operators": { - "6208911878914048": { - "kind": "Operator", - "id": "6208911878914048", - "nickname": "integration", - "emailAddress": "integration-accounts@rudderstack.com", - "username": "integration-accounts-92750bc547" - } - } - }, - "output": [ - { - "type": "track", - "event": "Conversation", - "traits": { - "organization": "Visitor Organization", - "chat_feedback": { - "knowledge": 4, - "friendliness": 5, - "overall_chat": 4, - "responsiveness": 5 - } - }, - "userId": "NOTAREALVISITORIDS5LGl6QUrK2OaPP", - "context": { - "os": { - "name": "Windows" - }, - "page": { - "url": "http://www.olark.com", - "referrer": "http://www.olark.com" - }, - "traits": { - "city": "San Francisco", - "name": "Olark", - "email": "support+integrationtest@olark.com", - "phone": "5555555555", - "region": "CA", - "country": "United States" - }, - "browser": { - "name": "Internet Explorer", - "version": "11" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Olark" - } - }, - "properties": { - "tags": ["test_example"], - "items": [ - { - "body": "Hi from an operator", - "kind": "MessageToVisitor", - "nickname": "Olark operator", - "timestamp": "1473774819.263083", - "operatorId": "6208911878914048" - }, - { - "body": "Hi from a visitor", - "kind": "MessageToOperator", - "nickname": "Returning Visitor | USA (San Francisco, CA) #7617", - "timestamp": "1473774821.411154", - "visitor_nickname": "Olark Visitor" - } - ] - }, - "integrations": { - "Olark": false - } - } - ] - }, - { - "description": "Olark webhook response", - "input": { - "kind": "Conversation", - "id": "ho6HrHxoabmm6q0G103JU0JFaor0BobA", - "manuallySubmitted": false, - "items": [ - { - "kind": "OfflineMessage", - "timestamp": "1669288532.567071", - "body": "name: test rudderstack\nemail: rudder14@gmail.com\nMessage: veavv" - } - ], - "tags": [], - "groups": [ - { - "kind": "Group", - "id": "ca77f4296fb7568909ad864aebf48201", - "name": "Group 1" - } - ], - "visitor": { - "kind": "Visitor", - "id": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", - "fullName": "test rudderstack", - "emailAddress": "rudder14@gmail.com", - "ip": "", - "country": "India", - "countryCode": "IN", - "browser": "Chrome 105.0.0.0", - "operatingSystem": "Macintosh", - "conversationBeginPage": "http://localhost:5503/" - } - }, - "output": [ - { - "type": "track", - "event": "Conversation", - "traits": {}, - "userId": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", - "context": { - "os": { - "name": "Macintosh" - }, - "page": { - "url": "http://localhost:5503/" - }, - "traits": { - "name": "test rudderstack", - "email": "rudder14@gmail.com", - "country": "India" - }, - "browser": { - "name": "Chrome", - "version": "105.0.0.0" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Olark" - } - }, - "properties": { - "tags": [], - "items": [ - { - "body": "name: test rudderstack\nemail: rudder14@gmail.com\nMessage: veavv", - "kind": "OfflineMessage", - "timestamp": "1669288532.567071" - } - ] - }, - "integrations": { - "Olark": false - } - }, - { - "name": "Group 1", - "type": "group", - "traits": { - "kind": "Group" - }, - "userId": "45WjM9eMYwJ7cJMo103JU0JaForAA6Db", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Olark" - } - }, - "groupId": "ca77f4296fb7568909ad864aebf48201", - "integrations": { - "Olark": false - } - } - ] - } -] diff --git a/test/__tests__/data/pagerduty_source.json b/test/__tests__/data/pagerduty_source.json deleted file mode 100644 index 0d116cff9b..0000000000 --- a/test/__tests__/data/pagerduty_source.json +++ /dev/null @@ -1,639 +0,0 @@ -[ - { - "description": "Incident Triggered", - "input": { - "event": { - "id": "01DEN0V2VIFEN5871PQGX72URP", - "event_type": "incident.triggered", - "resource_type": "incident", - "occurred_at": "2022-12-07T10:56:52.337Z", - "agent": { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - }, - "client": { - "name": "Monitoring Service", - "url": "https://monitoring.service.com" - }, - "data": { - "id": "Q3S7IX2U5KTCOY", - "type": "incident", - "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "number": 2, - "status": "triggered", - "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", - "created_at": "2022-12-07T10:56:52Z", - "title": "Server Crashed", - "service": { - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "summary": "Database", - "type": "service_reference" - }, - "assignees": [ - { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - } - ], - "escalation_policy": { - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "summary": "Default", - "type": "escalation_policy_reference" - }, - "teams": [], - "priority": { - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", - "id": "PPMNDVQ", - "self": "https://api.pagerduty.com/priorities/PPMNDVQ", - "summary": "P1", - "type": "priority_reference" - }, - "urgency": "high", - "conference_bridge": null, - "resolve_reason": null - } - } - }, - "output": { - "type": "track", - "event": "Incident Triggered", - "userId": "PXZZD2E", - "context": { - "traits": { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "PagerDuty" - } - }, - "messageId": "01DEN0V2VIFEN5871PQGX72URP", - "properties": { - "data": { - "id": "Q3S7IX2U5KTCOY", - "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "type": "incident", - "teams": [], - "title": "Server Crashed", - "number": 2, - "status": "triggered", - "service": { - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "type": "service_reference", - "summary": "Database", - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" - }, - "urgency": "high", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "priority": { - "id": "PPMNDVQ", - "self": "https://api.pagerduty.com/priorities/PPMNDVQ", - "type": "priority_reference", - "summary": "P1", - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" - }, - "assignees": [ - { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - } - ], - "created_at": "2022-12-07T10:56:52Z", - "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", - "resolve_reason": null, - "conference_bridge": null, - "escalation_policy": { - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "type": "escalation_policy_reference", - "summary": "Default", - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" - } - }, - "client": { - "url": "https://monitoring.service.com", - "name": "Monitoring Service" - }, - "resourceType": "incident" - }, - "integrations": { - "PagerDuty": false - }, - "originalTimestamp": "2022-12-07T10:56:52.000Z" - } - }, - { - "description": "Incident Priority Updated", - "input": { - "event": { - "id": "01DFU6P4VDDZCIHVQ5Q0ME99OE", - "event_type": "incident.priority_updated", - "resource_type": "incident", - "occurred_at": "2022-12-20T11:43:24.342Z", - "agent": { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - }, - "client": null, - "data": { - "id": "Q1KRTY75EUMGM0", - "type": "incident", - "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "number": 7, - "status": "acknowledged", - "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", - "created_at": "2022-12-20T11:37:19Z", - "title": "Event Stream Failure", - "service": { - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "summary": "Database", - "type": "service_reference" - }, - "assignees": [ - { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - } - ], - "escalation_policy": { - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "summary": "Default", - "type": "escalation_policy_reference" - }, - "teams": [], - "priority": { - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", - "id": "PPMNDVQ", - "self": "https://api.pagerduty.com/priorities/PPMNDVQ", - "summary": "P1", - "type": "priority_reference" - }, - "urgency": "high", - "conference_bridge": null, - "resolve_reason": null - } - } - }, - "output": { - "type": "track", - "event": "Incident Priority Updated", - "userId": "PXZZD2E", - "context": { - "traits": { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "PagerDuty" - } - }, - "messageId": "01DFU6P4VDDZCIHVQ5Q0ME99OE", - "properties": { - "data": { - "id": "Q1KRTY75EUMGM0", - "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "type": "incident", - "teams": [], - "title": "Event Stream Failure", - "number": 7, - "status": "acknowledged", - "service": { - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "type": "service_reference", - "summary": "Database", - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" - }, - "urgency": "high", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "priority": { - "id": "PPMNDVQ", - "self": "https://api.pagerduty.com/priorities/PPMNDVQ", - "type": "priority_reference", - "summary": "P1", - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" - }, - "assignees": [ - { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - } - ], - "created_at": "2022-12-20T11:37:19Z", - "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", - "resolve_reason": null, - "conference_bridge": null, - "escalation_policy": { - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "type": "escalation_policy_reference", - "summary": "Default", - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" - } - }, - "resourceType": "incident" - }, - "integrations": { - "PagerDuty": false - }, - "originalTimestamp": "2022-12-20T11:43:24.000Z" - } - }, - { - "description": "Incident Responder Added", - "input": { - "event": { - "id": "01DFU6Z1ZCLMV9SEK3X5JZ5WLW", - "event_type": "incident.responder.added", - "resource_type": "incident", - "occurred_at": "2022-12-20T11:46:44.213Z", - "agent": { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - }, - "client": null, - "data": { - "incident": { - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "id": "Q1KRTY75EUMGM0", - "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "summary": "Event Stream Failure", - "type": "incident_reference" - }, - "user": { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - }, - "escalation_policy": null, - "message": "Please help with \"Event Stream Failure\"", - "state": "pending", - "type": "incident_responder" - } - } - }, - "output": { - "type": "track", - "event": "Incident Responder Added", - "userId": "PXZZD2E", - "context": { - "traits": { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "PagerDuty" - } - }, - "messageId": "01DFU6Z1ZCLMV9SEK3X5JZ5WLW", - "properties": { - "data": { - "type": "incident_responder", - "user": { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - }, - "state": "pending", - "message": "Please help with \"Event Stream Failure\"", - "incident": { - "id": "Q1KRTY75EUMGM0", - "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "type": "incident_reference", - "summary": "Event Stream Failure", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0" - }, - "escalation_policy": null - }, - "resourceType": "incident" - }, - "integrations": { - "PagerDuty": false - }, - "originalTimestamp": "2022-12-20T11:46:44.000Z" - } - }, - { - "description": "Incident Escalated", - "input": { - "event": { - "id": "01DFU77KTKK9UUYX779UX0N1ZP", - "event_type": "incident.escalated", - "resource_type": "incident", - "occurred_at": "2022-12-20T11:49:35.385Z", - "agent": { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - }, - "client": null, - "data": { - "id": "Q1KRTY75EUMGM0", - "type": "incident", - "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "number": 7, - "status": "triggered", - "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", - "created_at": "2022-12-20T11:37:19Z", - "title": "Event Stream Failure", - "service": { - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "summary": "Database", - "type": "service_reference" - }, - "assignees": [ - { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - } - ], - "escalation_policy": { - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "summary": "Default", - "type": "escalation_policy_reference" - }, - "teams": [], - "priority": { - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", - "id": "PPMNDVQ", - "self": "https://api.pagerduty.com/priorities/PPMNDVQ", - "summary": "P1", - "type": "priority_reference" - }, - "urgency": "high", - "conference_bridge": null, - "resolve_reason": null - } - } - }, - "output": { - "type": "track", - "event": "Incident Escalated", - "userId": "PXZZD2E", - "context": { - "traits": { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "PagerDuty" - } - }, - "messageId": "01DFU77KTKK9UUYX779UX0N1ZP", - "properties": { - "data": { - "id": "Q1KRTY75EUMGM0", - "self": "https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "type": "incident", - "teams": [], - "title": "Event Stream Failure", - "number": 7, - "status": "triggered", - "service": { - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "type": "service_reference", - "summary": "Database", - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" - }, - "urgency": "high", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0", - "priority": { - "id": "PPMNDVQ", - "self": "https://api.pagerduty.com/priorities/PPMNDVQ", - "type": "priority_reference", - "summary": "P1", - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" - }, - "assignees": [ - { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - } - ], - "created_at": "2022-12-20T11:37:19Z", - "incident_key": "a3e0e442f8b74a8c94298f19de0dcbed", - "resolve_reason": null, - "conference_bridge": null, - "escalation_policy": { - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "type": "escalation_policy_reference", - "summary": "Default", - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" - } - }, - "resourceType": "incident" - }, - "integrations": { - "PagerDuty": false - }, - "originalTimestamp": "2022-12-20T11:49:35.000Z" - } - }, - { - "description": "Incident Resolved", - "input": { - "event": { - "id": "01DEN1HNLBC1VITK192ETJ1MPJ", - "event_type": "incident.resolved", - "resource_type": "incident", - "occurred_at": "2022-12-07T11:04:27.459Z", - "agent": { - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E", - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "summary": "rudder test", - "type": "user_reference" - }, - "client": null, - "data": { - "id": "Q3S7IX2U5KTCOY", - "type": "incident", - "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "number": 2, - "status": "resolved", - "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", - "created_at": "2022-12-07T10:56:52Z", - "title": "Server Crashed", - "service": { - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT", - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "summary": "Database", - "type": "service_reference" - }, - "assignees": [], - "escalation_policy": { - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4", - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "summary": "Default", - "type": "escalation_policy_reference" - }, - "teams": [], - "priority": { - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities", - "id": "P5DBC3A", - "self": "https://api.pagerduty.com/priorities/P5DBC3A", - "summary": "P3", - "type": "priority_reference" - }, - "urgency": "high", - "conference_bridge": { - "conference_number": "", - "conference_url": "" - }, - "resolve_reason": null - } - } - }, - "output": { - "type": "track", - "event": "Incident Resolved", - "userId": "PXZZD2E", - "context": { - "traits": { - "id": "PXZZD2E", - "self": "https://api.pagerduty.com/users/user@1", - "type": "user_reference", - "summary": "rudder test", - "html_url": "https://rudderlabs-com.pagerduty.com/users/PXZZD2E" - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "PagerDuty" - } - }, - "messageId": "01DEN1HNLBC1VITK192ETJ1MPJ", - "properties": { - "data": { - "id": "Q3S7IX2U5KTCOY", - "self": "https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "type": "incident", - "teams": [], - "title": "Server Crashed", - "number": 2, - "status": "resolved", - "service": { - "id": "PAJBUTT", - "self": "https://api.pagerduty.com/services/PAJBUTT", - "type": "service_reference", - "summary": "Database", - "html_url": "https://rudderlabs-com.pagerduty.com/services/PAJBUTT" - }, - "urgency": "high", - "html_url": "https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY", - "priority": { - "id": "P5DBC3A", - "self": "https://api.pagerduty.com/priorities/P5DBC3A", - "type": "priority_reference", - "summary": "P3", - "html_url": "https://rudderlabs-com.pagerduty.com/account/incident_priorities" - }, - "assignees": [], - "created_at": "2022-12-07T10:56:52Z", - "incident_key": "faaecfc0aca04b6ea07154188b5d3c6c", - "resolve_reason": null, - "conference_bridge": { - "conference_url": "", - "conference_number": "" - }, - "escalation_policy": { - "id": "PB7HKU4", - "self": "https://api.pagerduty.com/escalation_policies/PB7HKU4", - "type": "escalation_policy_reference", - "summary": "Default", - "html_url": "https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4" - } - }, - "resourceType": "incident" - }, - "integrations": { - "PagerDuty": false - }, - "originalTimestamp": "2022-12-07T11:04:27.000Z" - } - } -] diff --git a/test/__tests__/data/pipedream_source.json b/test/__tests__/data/pipedream_source.json deleted file mode 100644 index 2d542e8673..0000000000 --- a/test/__tests__/data/pipedream_source.json +++ /dev/null @@ -1,275 +0,0 @@ -[ - { - "description": "No type or userId is given", - "input": { - "anonymousId": "63767499ca6fb1b7c988d5bb", - "artist": "Gautam", - "genre": "Jazz", - "song": "Take Five" - }, - "output": { - "event": "pipedream_source_event", - "anonymousId": "63767499ca6fb1b7c988d5bb", - "context": { - "integration": { - "name": "PIPEDREAM" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "integrations": { - "PIPEDREAM": false - }, - "type": "track", - "properties": { - "anonymousId": "63767499ca6fb1b7c988d5bb", - "artist": "Gautam", - "genre": "Jazz", - "song": "Take Five" - } - } - }, - { - "description": "No type or anonymousId is given", - "input": { - "userId": "12", - "artist": "Gautam", - "genre": "Jazz", - "song": "Take Five" - }, - "output": { - "event": "pipedream_source_event", - "anonymousId": "12", - "context": { - "integration": { - "name": "PIPEDREAM" - }, - "library": { - "name": "unknown", - "version": "unknown" - } - }, - "integrations": { - "PIPEDREAM": false - }, - "type": "track", - "properties": { - "userId": "12", - "artist": "Gautam", - "genre": "Jazz", - "song": "Take Five" - } - } - }, - { - "description": "Track Call -> type and userId is given", - "input": { - "event": "Song Played", - "userId": "R1234", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe", - "userDeleted": false - }, - "locale": "en", - "location": { - "country": "IN", - "countryName": "India", - "short": "India", - "long": "India" - }, - "device": { - "os": "macOS", - "type": "desktop" - }, - "page": { - "referrer": "http://127.0.0.1:5500/testSm.html" - } - }, - "type": "track", - "properties": { - "artist": "John", - "Album": "ABCD" - } - }, - "output": { - "event": "Song Played", - "userId": "R1234", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe", - "userDeleted": false - }, - "locale": "en", - "location": { - "country": "IN", - "countryName": "India", - "short": "India", - "long": "India" - }, - "device": { - "os": "macOS", - "type": "desktop" - }, - "page": { - "referrer": "http://127.0.0.1:5500/testSm.html" - } - }, - "type": "track", - "properties": { - "artist": "John", - "Album": "ABCD" - } - } - }, - { - "description": "Identify type -> type and userId is given", - "input": { - "userId": "1", - "originalTimestamp": "2020-09-28T19:53:31.900Z", - "traits": { - "firstName": "John", - "lastName": "doe", - "email": "John@r.com", - "hasPurchased": "yes", - "address": { - "Home": { - "city": "iudcb" - }, - "Office": { - "abc": "jbc" - } - }, - "state": "Delhi", - "title": "Mr" - }, - "timestamp": "2020-09-29T14:50:29.907+05:30", - "type": "identify" - }, - "output": { - "userId": "1", - "originalTimestamp": "2020-09-28T19:53:31.900Z", - "traits": { - "firstName": "John", - "lastName": "doe", - "email": "John@r.com", - "hasPurchased": "yes", - "address": { - "Home": { - "city": "iudcb" - }, - "Office": { - "abc": "jbc" - } - }, - "state": "Delhi", - "title": "Mr" - }, - "timestamp": "2020-09-29T14:50:29.907+05:30", - "type": "identify" - } - }, - { - "description": "Group type -> type and userId is given", - "input": { - "userId": "user123", - "groupId": "17", - "context": {}, - "traits": { - "operation": "add" - }, - "type": "group" - }, - "output": { - "userId": "user123", - "groupId": "17", - "context": {}, - "traits": { - "operation": "add" - }, - "type": "group" - } - }, - { - "description": "Page type -> type and userId is given", - "input": { - "anonymousId": "21e13f4bc7ceddad", - "channel": "mobile", - "context": { - "os": { - "name": "Android", - "version": "9" - }, - "timezone": "Asia/Kolkata", - "traits": { - "customProp": "customValue" - }, - "userAgent": "Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)" - }, - "name": "Home", - "properties": { - "title": "Home | RudderStack", - "url": "http://www.rudderstack.com" - }, - "receivedAt": "2020-09-29T14:50:43.005+05:30", - "type": "page" - }, - "output": { - "anonymousId": "21e13f4bc7ceddad", - "channel": "mobile", - "context": { - "os": { - "name": "Android", - "version": "9" - }, - "timezone": "Asia/Kolkata", - "traits": { - "customProp": "customValue" - }, - "userAgent": "Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)" - }, - "name": "Home", - "properties": { - "title": "Home | RudderStack", - "url": "http://www.rudderstack.com" - }, - "receivedAt": "2020-09-29T14:50:43.005+05:30", - "type": "page" - } - }, - { - "description": "Alias type -> type and userId is given", - "input": { - "type": "alias", - "previousId": "name@surname.com", - "userId": "12345" - }, - "output": { - "type": "alias", - "previousId": "name@surname.com", - "userId": "12345" - } - } -] diff --git a/test/__tests__/data/refiner_source.json b/test/__tests__/data/refiner_source.json deleted file mode 100644 index c5ed3ab2e8..0000000000 --- a/test/__tests__/data/refiner_source.json +++ /dev/null @@ -1,394 +0,0 @@ -[ - { - "description": "Refiner webhook response", - "input": { - "uuid": "d769e130-49cf-11ed-968d-936a69fadf81", - "project_uuid": "0d8759d0-401c-11ed-8ded-9757c4929b55", - "remote_id": "user@17", - "email": "test17@user.com", - "display_name": "test user", - "first_seen_at": "2022-10-12T01:47:33.000000Z", - "last_seen_at": "2022-10-12T02:00:00.000000Z", - "attributes": { - "address": null, - "address_city": null, - "address_state": null, - "age": null, - "another_attribute": null, - "city": null, - "country": null, - "created_at": null, - "email": "test17@user.com", - "event": null, - "first_name": null, - "first_seen_at": "2022-10-12T01:47:33.000000Z", - "form_submissions_count": "1", - "form_views_count": "2", - "gender": null, - "last_form_submission_at": "2022-10-12T02:05:55.000000Z", - "last_form_view_at": "2022-10-12T02:03:46.000000Z", - "last_name": null, - "last_seen_at": "2022-10-12T02:00:00.000000Z", - "name": "test user", - "phone": null, - "some_attribute": null, - "status": null, - "student": null, - "tag": null, - "trait1": null, - "trait2": null, - "trait3": null, - "url": null, - "user_address_city": null, - "user_address_state": null, - "user_country": null, - "user_id": null, - "username": null, - "useroccupation": null, - "why_did_you_cancel_your_subscription": "Pricing" - }, - "segments": [ - { - "uuid": "0d91d7a0-401c-11ed-8898-bb1ee0c23ae5", - "name": "All Users", - "created_at": "2022-10-12T01:47:34.000000Z", - "updated_at": "2022-10-12T01:47:34.000000Z" - }, - { - "uuid": "f71ad940-455c-11ed-85e0-bf25f168b224", - "name": "test-segment", - "created_at": "2022-10-12T01:47:34.000000Z", - "updated_at": "2022-10-12T01:47:34.000000Z" - } - ], - "account": { - "uuid": "d76c9e80-49cf-11ed-a783-6317eca951a6", - "remote_id": "ACCOUNT-ID-ABC-1", - "domain": null, - "display_name": "Awesome Inc.", - "first_seen_at": "2022-10-12T01:47:33.000000Z", - "last_seen_at": "2022-10-12T02:00:00.000000Z", - "attributes": { - "a_date_at": "2022-10-01T00:00:00.000000Z", - "business_email": null, - "company": null, - "email": null, - "isfunded": null, - "name": "Awesome Inc.", - "revenue": null, - "some_account_data": "something", - "trait1": null, - "trait2": null, - "trait3": null - } - }, - "triggered_event": "Completed Survey", - "form": { - "uuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", - "name": "Customer Churn Survey" - }, - "response": { - "uuid": "eb117cb0-49cf-11ed-b050-03a44b32151c", - "first_shown_at": "2022-10-12T01:48:06.000000Z", - "last_shown_at": "2022-10-12T02:03:46.000000Z", - "show_counter": null, - "first_data_reception_at": "2022-10-12T02:05:55.000000Z", - "last_data_reception_at": "2022-10-12T02:05:55.000000Z", - "completed_at": "2022-10-12T02:05:55.000000Z", - "dismissed_at": null, - "received_at": "2022-10-12T02:05:55.000000Z", - "data": { - "why_did_you_cancel_your_subscription": "Pricing" - }, - "tags": [] - } - }, - "output": [ - { - "context": { - "traits": { - "email": "test17@user.com", - "segments": [ - { - "name": "All Users", - "uuid": "0d91d7a0-401c-11ed-8898-bb1ee0c23ae5", - "created_at": "2022-10-12T01:47:34.000000Z", - "updated_at": "2022-10-12T01:47:34.000000Z" - }, - { - "name": "test-segment", - "uuid": "f71ad940-455c-11ed-85e0-bf25f168b224", - "created_at": "2022-10-12T01:47:34.000000Z", - "updated_at": "2022-10-12T01:47:34.000000Z" - } - ] - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Refiner" - }, - "formUuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", - "formName": "Customer Churn Survey" - }, - "integrations": { "Refiner": false }, - "type": "identify", - "userId": "user@17", - "traits": { "why_did_you_cancel_your_subscription": "Pricing" }, - "originalTimestamp": "2022-10-12T02:05:55.000000Z" - }, - { - "type": "track", - "event": "Completed Survey", - "userId": "user@17", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "formName": "Customer Churn Survey", - "formUuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", - "integration": { - "name": "Refiner" - } - }, - "properties": { - "response": { - "data": { - "why_did_you_cancel_your_subscription": "Pricing" - }, - "tags": [], - "uuid": "eb117cb0-49cf-11ed-b050-03a44b32151c", - "received_at": "2022-10-12T02:05:55.000000Z", - "completed_at": "2022-10-12T02:05:55.000000Z", - "last_shown_at": "2022-10-12T02:03:46.000000Z", - "first_shown_at": "2022-10-12T01:48:06.000000Z", - "last_data_reception_at": "2022-10-12T02:05:55.000000Z", - "first_data_reception_at": "2022-10-12T02:05:55.000000Z" - }, - "refiner_form_name": "Customer Churn Survey", - "refiner_form_uuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae" - }, - "integrations": { - "Refiner": false - }, - "originalTimestamp": "2022-10-12T02:05:55.000000Z" - }, - { - "type": "group", - "traits": { - "name": "Awesome Inc.", - "a_date_at": "2022-10-01T00:00:00.000000Z", - "some_account_data": "something" - }, - "userId": "user@17", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Refiner" - } - }, - "groupId": "ACCOUNT-ID-ABC-1", - "integrations": { - "Refiner": false - }, - "originalTimestamp": "2022-10-12T02:05:55.000000Z" - } - ] - }, - { - "description": "Refiner webhook response", - "input": { - "uuid": "69b83e20-4ea2-11ed-941c-e1cb6c7a3870", - "cookie_uuid": "2f9b7e6a-9ba8-1c68-d474-48d719d92a60", - "project_uuid": "0d8759d0-401c-11ed-8ded-9757c4929b55", - "remote_id": "sdk@30", - "email": "sdk30@gmail.com", - "display_name": "", - "first_seen_at": "2022-10-18T05:04:58.000000Z", - "last_seen_at": "2022-10-18T05:04:58.000000Z", - "attributes": { - "address": null, - "address_city": null, - "address_state": null, - "age": null, - "another_attribute": null, - "city": null, - "country": null, - "created_at": null, - "email": "sdk30@gmail.com", - "event": null, - "first_name": null, - "first_seen_at": "2022-10-18T05:04:58.000000Z", - "form_submissions_count": "1", - "form_views_count": "1", - "gender": null, - "last_form_submission_at": "2022-10-18T05:05:45.000000Z", - "last_form_view_at": "2022-10-18T05:05:29.000000Z", - "last_name": null, - "last_seen_at": "2022-10-18T05:04:58.000000Z", - "name": null, - "phone": null, - "some_attribute": null, - "status": null, - "student": null, - "tag": null, - "trait1": null, - "trait2": null, - "trait3": null, - "url": null, - "user_address_city": null, - "user_address_state": null, - "user_country": null, - "user_id": null, - "username": null, - "useroccupation": null, - "why_did_you_cancel_your_subscription": "Missing features" - }, - "segments": [ - { - "uuid": "0d91d7a0-401c-11ed-8898-bb1ee0c23ae5", - "name": "All Users", - "created_at": "2022-10-18T05:04:58.000000Z", - "updated_at": "2022-10-18T05:04:58.000000Z" - }, - { - "uuid": "f71ad940-455c-11ed-85e0-bf25f168b224", - "name": "test-segment", - "created_at": "2022-10-18T05:04:58.000000Z", - "updated_at": "2022-10-18T05:04:58.000000Z" - } - ], - "account": { - "uuid": "69ba2030-4ea2-11ed-adfc-595e70c7ab07", - "remote_id": null, - "domain": null, - "display_name": "", - "first_seen_at": "2022-10-18T05:04:58.000000Z", - "last_seen_at": "2022-10-18T05:04:58.000000Z", - "attributes": { - "1": null, - "2": null, - "3": null, - "4": null, - "a_date_at": null, - "business_email": null, - "company": null, - "email": null, - "isfunded": null, - "location": null, - "name": null, - "revenue": null, - "some_account_data": null, - "trait1": null, - "trait2": null, - "trait3": null, - "user_id": null - } - }, - "triggered_event": "Completed Survey", - "form": { - "uuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", - "name": "Customer Churn Survey" - }, - "response": { - "uuid": "7c508c60-4ea2-11ed-9302-57708fe11d26", - "first_shown_at": "2022-10-18T05:05:29.000000Z", - "last_shown_at": "2022-10-18T05:05:29.000000Z", - "show_counter": null, - "first_data_reception_at": "2022-10-18T05:05:45.000000Z", - "last_data_reception_at": "2022-10-18T05:05:45.000000Z", - "completed_at": "2022-10-18T05:05:45.000000Z", - "dismissed_at": null, - "received_at": "2022-10-18T05:05:45.000000Z", - "data": { - "why_did_you_cancel_your_subscription": "Missing features" - }, - "tags": [] - } - }, - "output": [ - { - "type": "identify", - "traits": { - "why_did_you_cancel_your_subscription": "Missing features" - }, - "userId": "sdk@30", - "context": { - "traits": { - "email": "sdk30@gmail.com", - "segments": [ - { - "name": "All Users", - "uuid": "0d91d7a0-401c-11ed-8898-bb1ee0c23ae5", - "created_at": "2022-10-18T05:04:58.000000Z", - "updated_at": "2022-10-18T05:04:58.000000Z" - }, - { - "name": "test-segment", - "uuid": "f71ad940-455c-11ed-85e0-bf25f168b224", - "created_at": "2022-10-18T05:04:58.000000Z", - "updated_at": "2022-10-18T05:04:58.000000Z" - } - ] - }, - "library": { - "name": "unknown", - "version": "unknown" - }, - "formName": "Customer Churn Survey", - "formUuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", - "integration": { - "name": "Refiner" - } - }, - "integrations": { - "Refiner": false - }, - "originalTimestamp": "2022-10-18T05:05:45.000000Z" - }, - { - "type": "track", - "event": "Completed Survey", - "userId": "sdk@30", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "formName": "Customer Churn Survey", - "formUuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae", - "integration": { - "name": "Refiner" - } - }, - "properties": { - "response": { - "data": { - "why_did_you_cancel_your_subscription": "Missing features" - }, - "tags": [], - "uuid": "7c508c60-4ea2-11ed-9302-57708fe11d26", - "received_at": "2022-10-18T05:05:45.000000Z", - "completed_at": "2022-10-18T05:05:45.000000Z", - "last_shown_at": "2022-10-18T05:05:29.000000Z", - "first_shown_at": "2022-10-18T05:05:29.000000Z", - "last_data_reception_at": "2022-10-18T05:05:45.000000Z", - "first_data_reception_at": "2022-10-18T05:05:45.000000Z" - }, - "refiner_form_name": "Customer Churn Survey", - "refiner_form_uuid": "0d94c790-401c-11ed-bb27-e31f6832c5ae" - }, - "integrations": { - "Refiner": false - }, - "originalTimestamp": "2022-10-18T05:05:45.000000Z" - } - ] - } -] diff --git a/test/__tests__/data/satismeter_source.json b/test/__tests__/data/satismeter_source.json deleted file mode 100644 index 97b8b44a15..0000000000 --- a/test/__tests__/data/satismeter_source.json +++ /dev/null @@ -1,443 +0,0 @@ -[ - { - "description": " All fields Check with event as completed", - "input": { - "response": { - "id": "63767499ca6fb1b7c988d5bb", - "created": "2022-11-17T17:51:21.764Z", - "rating": 5, - "feedback": "Many things to imporve\n", - "dismissed": false, - "pending": false, - "answers": [ - { - "label": "How likely are you to recommend us to your friends and colleagues?", - "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", - "value": 5, - "name": "SM_rating", - "type": "scale", - "metric": "nps" - }, - { - "label": "What could we do to improve?", - "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", - "value": "Many things to imporve\n", - "name": "SM_comment", - "type": "long-text" - }, - { - "label": "The company made it easy for me to handle my issue.", - "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "scale", - "metric": "ces" - }, - { - "label": "How satisfied were you with the service you received?", - "id": "24c5b290-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "smiley", - "metric": "csat" - }, - { - "label": "How you like to rate the surevy?", - "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", - "value": 4, - "type": "scale" - }, - { - "label": "Your Name (Single Answer)", - "id": "37a8c000-66a0-11ed-856c-6f39711bf041", - "value": "a", - "type": "single-choice" - }, - { - "label": "Your Name (Multiple Answer)", - "id": "4b435da0-66a0-11ed-856c-6f39711bf041", - "value": ["a1", "b1"], - "type": "multiple-choice" - } - ], - "category": "detractor", - "score": -100, - "user": { - "id": "63766fbb7ac7b72676145338", - "name": "John Doe", - "email": "john@doe.com", - "userId": "No response", - "deleted": false, - "groups": { - "group1": "grooupId" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe" - } - }, - "device": { - "os": "macOS", - "type": "desktop" - }, - "location": { - "country": "IN", - "countryName": "India", - "region": "", - "city": "", - "short": "India", - "long": "India" - }, - "referrer": "http://127.0.0.1:5500/testSm.html", - "method": "In-app", - "language": "en", - "project": "6372247a764986ebee62bf66", - "campaign": "6373271b764986ebee62bfca" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe" - }, - "campaign": { - "id": "6373271b764986ebee62bfca", - "name": "NPS Survey" - }, - "event": "completed" - }, - "output": { - "event": "Survey completed", - "anonymousId": "63766fbb7ac7b72676145338", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe", - "userDeleted": false - }, - "locale": "en", - "campaign": { - "id": "6373271b764986ebee62bfca", - "name": "NPS Survey" - }, - "integration": { - "name": "SATISMETER" - }, - "location": { - "country": "IN", - "countryName": "India", - "short": "India", - "long": "India" - }, - "device": { - "os": "macOS", - "type": "desktop" - }, - "page": { - "referrer": "http://127.0.0.1:5500/testSm.html" - } - }, - "integrations": { - "SATISMETER": false - }, - "type": "track", - "traits": { - "groups": { "group1": "grooupId" } - }, - "userId": "No response", - "properties": { - "category": "detractor", - "answers": [ - { - "label": "How likely are you to recommend us to your friends and colleagues?", - "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", - "value": 5, - "name": "SM_rating", - "type": "scale", - "metric": "nps" - }, - { - "label": "What could we do to improve?", - "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", - "value": "Many things to imporve\n", - "name": "SM_comment", - "type": "long-text" - }, - { - "label": "The company made it easy for me to handle my issue.", - "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "scale", - "metric": "ces" - }, - { - "label": "How satisfied were you with the service you received?", - "id": "24c5b290-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "smiley", - "metric": "csat" - }, - { - "label": "How you like to rate the surevy?", - "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", - "value": 4, - "type": "scale" - }, - { - "label": "Your Name (Single Answer)", - "id": "37a8c000-66a0-11ed-856c-6f39711bf041", - "value": "a", - "type": "single-choice" - }, - { - "label": "Your Name (Multiple Answer)", - "id": "4b435da0-66a0-11ed-856c-6f39711bf041", - "value": ["a1", "b1"], - "type": "multiple-choice" - } - ], - "surveyDismissed": false, - "surveyPending": false, - "receivedAt": "2022-11-17T17:51:21.764Z" - } - } - }, - { - "description": " Neither reponse.user.id or response.user.userId is provided in payload then mapping response.id to anonymousId", - "input": { - "response": { - "id": "63767499ca6fb1b7c988d5bb", - "created": "2022-11-17T17:51:21.764Z", - "rating": 5, - "feedback": "Many things to imporve\n", - "dismissed": false, - "pending": false, - "answers": [ - { - "label": "How likely are you to recommend us to your friends and colleagues?", - "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", - "value": 5, - "name": "SM_rating", - "type": "scale", - "metric": "nps" - }, - { - "label": "What could we do to improve?", - "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", - "value": "Many things to imporve\n", - "name": "SM_comment", - "type": "long-text" - }, - { - "label": "The company made it easy for me to handle my issue.", - "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "scale", - "metric": "ces" - }, - { - "label": "How satisfied were you with the service you received?", - "id": "24c5b290-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "smiley", - "metric": "csat" - }, - { - "label": "How you like to rate the surevy?", - "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", - "value": 4, - "type": "scale" - }, - { - "label": "Your Name (Single Answer)", - "id": "37a8c000-66a0-11ed-856c-6f39711bf041", - "value": "a", - "type": "single-choice" - }, - { - "label": "Your Name (Multiple Answer)", - "id": "4b435da0-66a0-11ed-856c-6f39711bf041", - "value": ["a1", "b1"], - "type": "multiple-choice" - } - ], - "category": "detractor", - "score": -100, - "user": { - "name": "John Doe", - "email": "john@doe.com", - "deleted": false, - "groups": { - "group1": "grooupId" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe" - } - }, - "device": { - "os": "macOS", - "type": "desktop" - }, - "location": { - "country": "IN", - "countryName": "India", - "region": "", - "city": "", - "short": "India", - "long": "India" - }, - "referrer": "http://127.0.0.1:5500/testSm.html", - "method": "In-app", - "language": "en", - "project": "6372247a764986ebee62bf66", - "campaign": "6373271b764986ebee62bfca" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe" - }, - "campaign": { - "id": "6373271b764986ebee62bfca", - "name": "NPS Survey" - }, - "event": "completed" - }, - "output": { - "event": "Survey completed", - "anonymousId": "63767499ca6fb1b7c988d5bb", - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "traits": { - "createdAt": "2022-10-15T05:41:06.016Z", - "custom": { - "key1": "v1", - "key2": "V2" - }, - "email": "john@doe.com", - "name": "John Doe", - "userDeleted": false - }, - "locale": "en", - "campaign": { - "id": "6373271b764986ebee62bfca", - "name": "NPS Survey" - }, - "integration": { - "name": "SATISMETER" - }, - "location": { - "country": "IN", - "countryName": "India", - "short": "India", - "long": "India" - }, - "device": { - "os": "macOS", - "type": "desktop" - }, - "page": { - "referrer": "http://127.0.0.1:5500/testSm.html" - } - }, - "integrations": { - "SATISMETER": false - }, - "type": "track", - "traits": { - "groups": { "group1": "grooupId" } - }, - "properties": { - "category": "detractor", - "answers": [ - { - "label": "How likely are you to recommend us to your friends and colleagues?", - "id": "7ddb22b0-64a8-11ed-a4c7-b3bed73771cd", - "value": 5, - "name": "SM_rating", - "type": "scale", - "metric": "nps" - }, - { - "label": "What could we do to improve?", - "id": "7ddb22b1-64a8-11ed-a4c7-b3bed73771cd", - "value": "Many things to imporve\n", - "name": "SM_comment", - "type": "long-text" - }, - { - "label": "The company made it easy for me to handle my issue.", - "id": "1dc53f60-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "scale", - "metric": "ces" - }, - { - "label": "How satisfied were you with the service you received?", - "id": "24c5b290-66a0-11ed-856c-6f39711bf041", - "value": 4, - "name": null, - "type": "smiley", - "metric": "csat" - }, - { - "label": "How you like to rate the surevy?", - "id": "27b3d1d0-66a0-11ed-856c-6f39711bf041", - "value": 4, - "type": "scale" - }, - { - "label": "Your Name (Single Answer)", - "id": "37a8c000-66a0-11ed-856c-6f39711bf041", - "value": "a", - "type": "single-choice" - }, - { - "label": "Your Name (Multiple Answer)", - "id": "4b435da0-66a0-11ed-856c-6f39711bf041", - "value": ["a1", "b1"], - "type": "multiple-choice" - } - ], - "surveyDismissed": false, - "surveyPending": false, - "receivedAt": "2022-11-17T17:51:21.764Z" - } - } - } -] diff --git a/test/__tests__/data/segment_source_input.json b/test/__tests__/data/segment_source_input.json deleted file mode 100644 index f5c7173e00..0000000000 --- a/test/__tests__/data/segment_source_input.json +++ /dev/null @@ -1,112 +0,0 @@ -[ - [ - { - "date": "2020-07-10T07:43:07.766Z", - "type": "s", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", - "details": { - "prompts": [], - "completedAt": 1594366987765, - "elapsedTime": null, - "session_id": "**************_***************" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": true - }, - { - "date": "2020-07-10T07:43:09.620Z", - "type": "seacft", - "description": "", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "okhttp 2.7.5 / Other 0.0.0", - "details": { - "code": "*************Xst" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": false - }, - { - "date": "2020-07-10T07:43:07.766Z", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", - "details": { - "prompts": [], - "completedAt": 1594366987765, - "elapsedTime": null, - "session_id": "**************_***************" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": true - }, - { - "type": "s", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", - "details": { - "prompts": [], - "completedAt": 1594366987765, - "elapsedTime": null, - "session_id": "**************_***************" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": true - } - ] -] diff --git a/test/__tests__/data/segment_source_output.json b/test/__tests__/data/segment_source_output.json deleted file mode 100644 index f5c7173e00..0000000000 --- a/test/__tests__/data/segment_source_output.json +++ /dev/null @@ -1,112 +0,0 @@ -[ - [ - { - "date": "2020-07-10T07:43:07.766Z", - "type": "s", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", - "details": { - "prompts": [], - "completedAt": 1594366987765, - "elapsedTime": null, - "session_id": "**************_***************" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": true - }, - { - "date": "2020-07-10T07:43:09.620Z", - "type": "seacft", - "description": "", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "okhttp 2.7.5 / Other 0.0.0", - "details": { - "code": "*************Xst" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": false - }, - { - "date": "2020-07-10T07:43:07.766Z", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", - "details": { - "prompts": [], - "completedAt": 1594366987765, - "elapsedTime": null, - "session_id": "**************_***************" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": true - }, - { - "type": "s", - "connection_id": "", - "client_id": "********************************", - "client_name": "My App", - "ip": "47.15.6.58", - "user_agent": "Chrome Mobile 69.0.3497 / Android 0.0.0", - "details": { - "prompts": [], - "completedAt": 1594366987765, - "elapsedTime": null, - "session_id": "**************_***************" - }, - "hostname": "************.us.auth0.com", - "user_id": "auth0|************************", - "user_name": "example@test.com", - "auth0_client": { - "name": "Auth0.Android", - "env": { - "android": "28" - }, - "version": "1.23.0" - }, - "log_id": "********************************************************", - "_id": "********************************************************", - "isMobile": true - } - ] -] diff --git a/test/__tests__/data/shopify.json b/test/__tests__/data/shopify.json deleted file mode 100644 index 48ca8c75a0..0000000000 --- a/test/__tests__/data/shopify.json +++ /dev/null @@ -1,515 +0,0 @@ -[ - { - "description": "Track Call -> carts_create ", - "input": { - "id": "shopify_test3", - "query_parameters": { - "topic": ["carts_create"] - }, - "token": "shopify_test3", - "line_items": [], - "note": null, - "updated_at": "2023-02-10T12:16:07.251Z", - "created_at": "2023-02-10T12:05:04.402Z" - }, - "output": { - "outputToSource": { - "body": "T0s=", - "contentType": "text/plain" - }, - "statusCode": 200 - } - }, - { - "description": "No Query Parameters", - "input": {}, - "output": { - "error": "Query_parameters is missing" - } - }, - { - "description": "Invalid topic", - "input": { - "query_parameters": { - "signature": ["rudderstack"], - "writeKey": ["sample-write-key"] - } - }, - "output": { - "error": "Invalid topic in query_parameters" - } - }, - { - "description": "Topic Not found", - "input": { - "query_parameters": { - "topic": [], - "signature": ["rudderstack"], - "writeKey": ["sample-write-key"] - } - }, - "output": { - "error": "Topic not found" - } - }, - { - "description": "Unsupported Event Type", - "input": { - "query_parameters": { - "topic": ["random_event"], - "signature": ["rudderstack"], - "writeKey": ["sample-write-key"] - } - }, - "output": { - "outputToSource": { - "body": "T0s=", - "contentType": "text/plain" - }, - "statusCode": 200 - } - }, - { - "description": "Identify Call for customers create event", - "input": { - "query_parameters": { - "topic": ["customers_create"], - "signature": ["rudderstack"], - "writeKey": ["sample-write-key"] - }, - "id": 5747017285820, - "email": "anuraj@rudderstack.com", - "accepts_marketing": false, - "created_at": "2021-12-29T15:15:19+05:30", - "updated_at": "2021-12-29T15:15:20+05:30", - "first_name": "Anuraj", - "last_name": "Guha", - "orders_count": 0, - "state": "disabled", - "total_spent": "0.00", - "last_order_id": null, - "note": "", - "verified_email": true, - "multipass_identifier": null, - "tax_exempt": false, - "phone": "+919876543210", - "tags": "", - "last_order_name": null, - "currency": "INR", - "addresses": [ - { - "id": 6947581821116, - "customer_id": 5747017285820, - "first_name": "Anuraj", - "last_name": "Guha", - "company": "Rudderstack", - "address1": "Home", - "address2": "Apartment", - "city": "Kolkata", - "province": "West Bengal", - "country": "India", - "zip": "708091", - "phone": "+919876543210", - "name": "Anuraj Guha", - "province_code": "WB", - "country_code": "IN", - "country_name": "India", - "default": true - } - ], - "accepts_marketing_updated_at": "2021-12-29T15:15:20+05:30", - "marketing_opt_in_level": null, - "tax_exemptions": [], - "sms_marketing_consent": { - "state": "not_subscribed", - "opt_in_level": "single_opt_in", - "consent_updated_at": null, - "consent_collected_from": "SHOPIFY" - }, - "admin_graphql_api_id": "gid://shopify/Customer/5747017285820", - "default_address": { - "id": 6947581821116, - "customer_id": 5747017285820, - "first_name": "Anuraj", - "last_name": "Guha", - "company": "Rudderstack", - "address1": "Home", - "address2": "Apartment", - "city": "Kolkata", - "province": "West Bengal", - "country": "India", - "zip": "708091", - "phone": "+919876543210", - "name": "Anuraj Guha", - "province_code": "WB", - "country_code": "IN", - "country_name": "India", - "default": true - } - }, - "output": { - "context": { - "library": { - "name": "RudderStack Shopify Cloud", - "version": "1.0.0" - }, - "integration": { - "name": "SHOPIFY" - }, - "topic": "customers_create" - }, - "integrations": { - "SHOPIFY": true - }, - "type": "identify", - "userId": "5747017285820", - "traits": { - "email": "anuraj@rudderstack.com", - "firstName": "Anuraj", - "lastName": "Guha", - "phone": "+919876543210", - "addressList": [ - { - "id": 6947581821116, - "customer_id": 5747017285820, - "first_name": "Anuraj", - "last_name": "Guha", - "company": "Rudderstack", - "address1": "Home", - "address2": "Apartment", - "city": "Kolkata", - "province": "West Bengal", - "country": "India", - "zip": "708091", - "phone": "+919876543210", - "name": "Anuraj Guha", - "province_code": "WB", - "country_code": "IN", - "country_name": "India", - "default": true - } - ], - "address": { - "id": 6947581821116, - "customer_id": 5747017285820, - "first_name": "Anuraj", - "last_name": "Guha", - "company": "Rudderstack", - "address1": "Home", - "address2": "Apartment", - "city": "Kolkata", - "province": "West Bengal", - "country": "India", - "zip": "708091", - "phone": "+919876543210", - "name": "Anuraj Guha", - "province_code": "WB", - "country_code": "IN", - "country_name": "India", - "default": true - }, - "acceptsMarketing": false, - "orderCount": 0, - "state": "disabled", - "totalSpent": "0.00", - "note": "", - "verifiedEmail": true, - "taxExempt": false, - "tags": "", - "currency": "INR", - "taxExemptions": [], - "smsMarketingConsent": { - "state": "not_subscribed", - "opt_in_level": "single_opt_in", - "consent_updated_at": null, - "consent_collected_from": "SHOPIFY" - }, - "adminGraphqlApiId": "gid://shopify/Customer/5747017285820", - "acceptsMarketingUpdatedAt": "2021-12-29T15:15:20+05:30" - }, - "timestamp": "2021-12-29T09:45:20.000Z" - } - }, - { - "description": "Unsupported checkout event", - "input": { - "query_parameters": { - "topic": ["checkout_delete"], - "writeKey": ["sample-write-key"], - "signature": ["rudderstack"] - }, - "admin_graphql_api_id": "gid://shopify/Fulfillment/4124667937024", - "created_at": "2022-01-05T18:13:02+05:30", - "destination": null, - "id": 4124667937024, - "line_items": [], - "customer": { - "email": "test_person@email.com", - "first_name": "Test", - "last_name": "Person" - }, - "billing_address": { - "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" - }, - "shipping_address": { - "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" - }, - "location_id": 66855371008, - "name": "#1002.1", - "order_id": 4617255092480, - "origin_address": null, - "receipt": {}, - "service": "manual", - "shipment_status": null, - "status": "success", - "tracking_company": "Amazon Logistics UK", - "tracking_number": "Sample001test", - "tracking_numbers": ["Sample001test"], - "tracking_url": "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530", - "tracking_urls": ["https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530"], - "updated_at": "2022-01-05T18:16:48+05:30" - }, - "output": { - "outputToSource": { - "body": "T0s=", - "contentType": "text/plain" - }, - "statusCode": 200 - } - }, - { - "description": "Track Call -> Fullfillments updated event", - "input": { - "query_parameters": { - "topic": ["fulfillments_update"], - "writeKey": ["sample-write-key"], - "signature": ["rudderstack"] - }, - "shipping_address": { - "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" - }, - "billing_address": { - "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" - }, - "admin_graphql_api_id": "gid://shopify/Fulfillment/4124667937024", - "created_at": "2022-01-05T18:13:02+05:30", - "destination": null, - "email": "test_person@email.com", - "id": 4124667937024, - "line_items": [ - { - "admin_graphql_api_id": "gid://shopify/LineItem/11896203149568", - "discount_allocations": [], - "duties": [], - "fulfillable_quantity": 0, - "fulfillment_service": "manual", - "fulfillment_status": "fulfilled", - "gift_card": false, - "grams": 0, - "id": 11896203149568, - "name": "p1", - "origin_location": { - "address1": "74 CC/7, Anupama Housing Estate - II", - "address2": "", - "city": "Kolkatta", - "country_code": "IN", - "id": 3373642219776, - "name": "74 CC/7, Anupama Housing Estate - II", - "province_code": "WB", - "zip": "700052" - }, - "price": "5000.00", - "price_set": { - "presentment_money": { - "amount": "5000.00", - "currency_code": "INR" - }, - "shop_money": { - "amount": "5000.00", - "currency_code": "INR" - } - }, - "product_exists": true, - "product_id": 7510929801472, - "properties": [], - "quantity": 1, - "requires_shipping": true, - "sku": "15", - "tax_lines": [ - { - "channel_liable": false, - "price": "900.00", - "price_set": { - "presentment_money": { - "amount": "900.00", - "currency_code": "INR" - }, - "shop_money": { - "amount": "900.00", - "currency_code": "INR" - } - }, - "rate": 0.18, - "title": "IGST" - } - ], - "taxable": true, - "title": "p1", - "total_discount": "0.00", - "total_discount_set": { - "presentment_money": { - "amount": "0.00", - "currency_code": "INR" - }, - "shop_money": { - "amount": "0.00", - "currency_code": "INR" - } - }, - "variant_id": 42211160228096, - "variant_inventory_management": "shopify", - "variant_title": "", - "vendor": "rudderstack-store" - } - ], - "location_id": 66855371008, - "name": "#1002.1", - "order_id": 4617255092480, - "origin_address": null, - "receipt": {}, - "service": "manual", - "shipment_status": null, - "status": "success", - "tracking_company": "Amazon Logistics UK", - "tracking_number": "Sample001test", - "tracking_numbers": ["Sample001test"], - "tracking_url": "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530", - "tracking_urls": ["https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530"], - "updated_at": "2022-01-05T18:16:48+05:30" - }, - "output": { - "context": { - "library": { - "name": "RudderStack Shopify Cloud", - "version": "1.0.0" - }, - "integration": { - "name": "SHOPIFY" - }, - "topic": "fulfillments_update" - }, - "integrations": { - "SHOPIFY": true - }, - "type": "track", - "userId": "shopify-admin", - "event": "Fulfillments Update", - "properties": { - "admin_graphql_api_id": "gid://shopify/Fulfillment/4124667937024", - "created_at": "2022-01-05T18:13:02+05:30", - "destination": null, - "email": "test_person@email.com", - "id": 4124667937024, - "location_id": 66855371008, - "name": "#1002.1", - "order_id": 4617255092480, - "origin_address": null, - "receipt": {}, - "service": "manual", - "shipment_status": null, - "status": "success", - "tracking_company": "Amazon Logistics UK", - "tracking_number": "Sample001test", - "tracking_numbers": ["Sample001test"], - "tracking_url": "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530", - "tracking_urls": [ - "https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530" - ], - "updated_at": "2022-01-05T18:16:48+05:30", - "products": [ - { - "product_id": 7510929801472, - "sku": "15", - "title": "p1", - "price": "5000.00", - "brand": "rudderstack-store", - "quantity": 1, - "admin_graphql_api_id": "gid://shopify/LineItem/11896203149568", - "discount_allocations": [], - "duties": [], - "fulfillable_quantity": 0, - "fulfillment_service": "manual", - "fulfillment_status": "fulfilled", - "gift_card": false, - "grams": 0, - "id": 11896203149568, - "origin_location": { - "address1": "74 CC/7, Anupama Housing Estate - II", - "address2": "", - "city": "Kolkatta", - "country_code": "IN", - "id": 3373642219776, - "name": "74 CC/7, Anupama Housing Estate - II", - "province_code": "WB", - "zip": "700052" - }, - "price_set": { - "presentment_money": { - "amount": "5000.00", - "currency_code": "INR" - }, - "shop_money": { - "amount": "5000.00", - "currency_code": "INR" - } - }, - "product_exists": true, - "properties": [], - "requires_shipping": true, - "tax_lines": [ - { - "channel_liable": false, - "price": "900.00", - "price_set": { - "presentment_money": { - "amount": "900.00", - "currency_code": "INR" - }, - "shop_money": { - "amount": "900.00", - "currency_code": "INR" - } - }, - "rate": 0.18, - "title": "IGST" - } - ], - "taxable": true, - "total_discount": "0.00", - "total_discount_set": { - "presentment_money": { - "amount": "0.00", - "currency_code": "INR" - }, - "shop_money": { - "amount": "0.00", - "currency_code": "INR" - } - }, - "variant_inventory_management": "shopify", - "variant": "42211160228096 " - } - ] - }, - "traits": { - "shippingAddress": { - "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" - }, - "billingAddress": { - "address1": "11 Rani Sankari Lane Patuapara Bhowanipore" - }, - "email": "test_person@email.com" - } - } - } -] diff --git a/test/__tests__/data/signl4_source_input.json b/test/__tests__/data/signl4_source_input.json deleted file mode 100644 index a3309cd03c..0000000000 --- a/test/__tests__/data/signl4_source_input.json +++ /dev/null @@ -1,123 +0,0 @@ -[ - { - "eventType": 200, - "eventRaisedUtc": "2017-09-01T08:11:37.4815663Z", - "subscription": { - "id": "0acf8014-22f2-4503-88d7-f7d05b46744f" - }, - "alert": { - "statusCode": 1, - "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "externalEventId": "INC091210", - "id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" - }, - "id": "dd209a2d-e037-41ee-b37d-f605cc0a39fb" - }, - { - "eventType": 201, - "eventRaisedUtc": "2017-09-01T08:11:37.4815663Z", - "subscription": { - "id": "0acf8014-22f2-4503-88d7-f7d05b46744f" - }, - "user": { - "username": "Rene", - "mailaddress": "rene@signl4.com", - "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" - }, - "alert": { - "statusCode": 2, - "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "externalEventId": "Content you passed in the X-S4-ExternalID parameter", - "acknowledgedUserIds": ["f0bd5063-9588-51cf-b3d9-94e5647dedc5"], - "id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" - }, - "id": "dd209a2d-e037-41ee-b37d-f605cc0a39fb" - }, - { - "eventType": 201, - "eventRaisedUtc": "2017-09-01T08:11:37.4815663Z", - "subscription": { - "id": "0acf8014-22f2-4503-88d7-f7d05b46744f" - }, - "user": { - "username": "Rene", - "mailaddress": "rene@signl4.com", - "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" - }, - "alert": { - "statusCode": 4, - "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "externalEventId": "Content you passed in the X-S4-ExternalID parameter", - "acknowledgedUserIds": ["f0bd5063-9588-51cf-b3d9-94e5647dedc5"], - "id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" - }, - "id": "dd209a2d-e037-41ee-b37d-f605cc0a39fb" - }, - { - "eventType": 202, - "eventRaisedUtc": "2020-01-10T12:27:19Z", - "subscription": { - "id": "b8fdd850-e2ad-45ff-924d-9c332a063200" - }, - "team": { - "id": "0e8979f7-0c6a-472d-8918-ecfd339252f8" - }, - "alert": { - "statusCode": 1, - "eventId": "2518236416806594587_0e67b746-6c88-4ddf-8872-99690b0457d9", - "externalEventId": "INC091210", - "acknowledgedUserIds": [], - "id": "2518236416804564453_12ea0f6f-948c-43d0-9034-f9565d7b6bd2" - }, - "id": "27283793-47c8-4da2-9767-d37be224338d" - }, - { - "eventType": 203, - "eventRaisedUtc": "2018-04-17T15:00:32Z", - "subscription": { - "id": "1578ebd9-0a27-44ab-bc8e-52cd7d32e81d" - }, - "user": { - "username": "Rene", - "mailaddress": "rene@signl4.com", - "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" - }, - "alert": { - "statusCode": 0, - "eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "externalEventId": "Content you passed in the X-S4-ExternalID parameter", - "id": "2518783235958846071_4e2dfab2-4717-42bc-8d37-8682402309c2" - }, - "annotation": { - "message": "OK, I'll take care about it.", - "id": "2518783235661483318_99ebffe0-1b90-40ef-990a-fbd842484761" - }, - "id": "141c0f88-7831-4d5e-b055-f6e83c269770" - }, - { - "eventType": 300, - "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", - "team": { "id": "f1801955-4724-44de-902a-f6f02ba9e10f" }, - "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" - }, - { - "eventType": 301, - "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", - "team": { "id": "f1801955-4724-44de-902a-f6f02ba9e10f" }, - "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" - }, - { - "eventType": 302, - "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", - "team": { "id": "f1801955-4724-44de-902a-f6f02ba9e10f" }, - "user": { "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" }, - "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" - }, - { - "eventType": 303, - "eventRaisedUtc": "2017-09-01T09:16:17.3717355Z", - "team": { "id": "f1801955-4724-44de-902a-f6f02ba9e10f" }, - "user": { "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" }, - "id": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3" - } -] diff --git a/test/__tests__/data/signl4_source_output.json b/test/__tests__/data/signl4_source_output.json deleted file mode 100644 index a56fb814de..0000000000 --- a/test/__tests__/data/signl4_source_output.json +++ /dev/null @@ -1,269 +0,0 @@ -[ - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "dd209a2d-e037-41ee-b37d-f605cc0a39fb", - "originalTimestamp": "2017-09-01T08:11:37.000Z", - "event": "New Alert Created", - "properties": { - "eventType": 200, - "subscription.id": "0acf8014-22f2-4503-88d7-f7d05b46744f", - "alert.statusCode": 1, - "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "alert.externalEventId": "INC091210", - "alert.id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - }, - "externalId": [ - { - "type": "signl4UserId", - "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" - } - ], - "traits": { - "email": "rene@signl4.com", - "name": "Rene" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "dd209a2d-e037-41ee-b37d-f605cc0a39fb", - "originalTimestamp": "2017-09-01T08:11:37.000Z", - "event": "Alert Confirmed", - "properties": { - "eventType": 201, - "subscription.id": "0acf8014-22f2-4503-88d7-f7d05b46744f", - "alert.statusCode": 2, - "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "alert.externalEventId": "Content you passed in the X-S4-ExternalID parameter", - "alert.acknowledgedUserIds[0]": "f0bd5063-9588-51cf-b3d9-94e5647dedc5", - "alert.id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - }, - "externalId": [ - { - "type": "signl4UserId", - "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" - } - ], - "traits": { - "email": "rene@signl4.com", - "name": "Rene" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "dd209a2d-e037-41ee-b37d-f605cc0a39fb", - "originalTimestamp": "2017-09-01T08:11:37.000Z", - "event": "Alert Resolved", - "properties": { - "eventType": 201, - "subscription.id": "0acf8014-22f2-4503-88d7-f7d05b46744f", - "alert.statusCode": 4, - "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "alert.externalEventId": "Content you passed in the X-S4-ExternalID parameter", - "alert.acknowledgedUserIds[0]": "f0bd5063-9588-51cf-b3d9-94e5647dedc5", - "alert.id": "2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685" - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "27283793-47c8-4da2-9767-d37be224338d", - "originalTimestamp": "2020-01-10T12:27:19.000Z", - "event": "Alert Escalated", - "properties": { - "eventType": 202, - "subscription.id": "b8fdd850-e2ad-45ff-924d-9c332a063200", - "team.id": "0e8979f7-0c6a-472d-8918-ecfd339252f8", - "alert.statusCode": 1, - "alert.eventId": "2518236416806594587_0e67b746-6c88-4ddf-8872-99690b0457d9", - "alert.externalEventId": "INC091210", - "alert.id": "2518236416804564453_12ea0f6f-948c-43d0-9034-f9565d7b6bd2", - "alert.acknowledgedUserIds": [] - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - }, - "externalId": [ - { - "type": "signl4UserId", - "id": "f0bd5063-9588-51cf-b3d9-94e5647dedc5" - } - ], - "traits": { - "email": "rene@signl4.com", - "name": "Rene" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "141c0f88-7831-4d5e-b055-f6e83c269770", - "originalTimestamp": "2018-04-17T15:00:32.000Z", - "event": "Alert Annotated", - "properties": { - "eventType": 203, - "subscription.id": "1578ebd9-0a27-44ab-bc8e-52cd7d32e81d", - "alert.statusCode": 0, - "alert.eventId": "2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2", - "alert.externalEventId": "Content you passed in the X-S4-ExternalID parameter", - "alert.id": "2518783235958846071_4e2dfab2-4717-42bc-8d37-8682402309c2", - "annotation.message": "OK, I'll take care about it.", - "annotation.id": "2518783235661483318_99ebffe0-1b90-40ef-990a-fbd842484761" - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", - "originalTimestamp": "2017-09-01T09:16:17.000Z", - "event": "Duty Period Started", - "properties": { - "eventType": 300, - "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" - } - }, - - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - } - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", - "originalTimestamp": "2017-09-01T09:16:17.000Z", - "event": "Duty Period Ended", - "properties": { - "eventType": 301, - "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - }, - "externalId": [ - { - "type": "signl4UserId", - "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" - } - ] - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", - "originalTimestamp": "2017-09-01T09:16:17.000Z", - "event": "Somebody Punched-In", - "properties": { - "eventType": 302, - "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" - } - }, - { - "context": { - "library": { - "name": "unknown", - "version": "unknown" - }, - "integration": { - "name": "Signl4" - }, - "externalId": [ - { - "type": "signl4UserId", - "id": "e31da15f-7e13-43f1-b4a5-1ce3b470a504" - } - ] - }, - "integrations": { - "Signl4": false - }, - "type": "track", - "messageId": "f56a6b59-1197-4e7d-8eca-8d21a4b57ec3", - "originalTimestamp": "2017-09-01T09:16:17.000Z", - "event": "Somebody Punched-Out", - "properties": { - "eventType": 303, - "team.id": "f1801955-4724-44de-902a-f6f02ba9e10f" - } - } -] diff --git a/test/__tests__/data/versioned_processor_heap_input.json b/test/__tests__/data/versioned_processor_heap_input.json index d9f94fe9b5..901eea3a9f 100644 --- a/test/__tests__/data/versioned_processor_heap_input.json +++ b/test/__tests__/data/versioned_processor_heap_input.json @@ -11,7 +11,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -74,7 +74,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -138,7 +138,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -204,7 +204,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -272,7 +272,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -340,7 +340,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, diff --git a/test/__tests__/data/versioned_processor_heap_output.json b/test/__tests__/data/versioned_processor_heap_output.json index 3041a6f35c..73ef473017 100644 --- a/test/__tests__/data/versioned_processor_heap_output.json +++ b/test/__tests__/data/versioned_processor_heap_output.json @@ -139,7 +139,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -153,7 +153,7 @@ "errorCategory": "dataValidation", "errorType": "instrumentation", "feature": "processor", - "implementation": "cdkV1", + "implementation": "cdkV", "module": "destination", "destType": "HEAP" } @@ -171,7 +171,7 @@ "ID": "1WTbl0l5GjOQKOvfmcGwk0T49kV", "Name": "HEAP", "Config": { - "cdkEnabled": true + "cdkV2Enabled": true } }, "Enabled": true, @@ -184,7 +184,7 @@ "statTags": { "errorCategory": "transformation", "feature": "processor", - "implementation": "cdkV1", + "implementation": "cdkV2", "module": "destination", "destType": "HEAP" } diff --git a/test/__tests__/formsort_source.test.js b/test/__tests__/formsort_source.test.js deleted file mode 100644 index 29c1c0831d..0000000000 --- a/test/__tests__/formsort_source.test.js +++ /dev/null @@ -1,26 +0,0 @@ -const integration = "formsort"; -const name = "formsort"; - -const version = "v0"; -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${name} Tests: payload: ${index} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - delete output.anonymousId; - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.message); - } - }); -}); diff --git a/test/__tests__/gpx_source.test.js b/test/__tests__/gpx_source.test.js deleted file mode 100644 index c8e7df5f4a..0000000000 --- a/test/__tests__/gpx_source.test.js +++ /dev/null @@ -1,22 +0,0 @@ -const integration = "gainsightpx"; -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${index}. ${integration} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.error); - } - }); -}); diff --git a/test/__tests__/iterable_source.test.js b/test/__tests__/iterable_source.test.js deleted file mode 100644 index e478966bd7..0000000000 --- a/test/__tests__/iterable_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "iterable"; -const name = "Iterable"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/mailjet_source.test.js b/test/__tests__/mailjet_source.test.js deleted file mode 100644 index 7a778e7b4e..0000000000 --- a/test/__tests__/mailjet_source.test.js +++ /dev/null @@ -1,26 +0,0 @@ -const integration = "mailjet"; -const name = "MailJet"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${name} Tests: payload: ${index}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output); - } - }); -}); diff --git a/test/__tests__/mailmodo_source.test.js b/test/__tests__/mailmodo_source.test.js deleted file mode 100644 index d038e4236c..0000000000 --- a/test/__tests__/mailmodo_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "mailmodo"; -const name = "Mailmodo"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/monday_source.test.js b/test/__tests__/monday_source.test.js deleted file mode 100644 index d97f73451e..0000000000 --- a/test/__tests__/monday_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "monday"; -const name = "Monday"; - -const fs = require("fs"); -const path = require("path"); - -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/olark_source.test.js b/test/__tests__/olark_source.test.js deleted file mode 100644 index 6e69bd466c..0000000000 --- a/test/__tests__/olark_source.test.js +++ /dev/null @@ -1,23 +0,0 @@ -const integration = "olark"; - -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${index}. ${integration} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.message); - } - }); -}); diff --git a/test/__tests__/pagerduty_source.test.js b/test/__tests__/pagerduty_source.test.js deleted file mode 100644 index ddfb69aba6..0000000000 --- a/test/__tests__/pagerduty_source.test.js +++ /dev/null @@ -1,23 +0,0 @@ -const integration = "pagerduty"; - -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${index}. ${integration} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.message); - } - }); -}); diff --git a/test/__tests__/pipedream_source.test.js b/test/__tests__/pipedream_source.test.js deleted file mode 100644 index 1edc642bad..0000000000 --- a/test/__tests__/pipedream_source.test.js +++ /dev/null @@ -1,23 +0,0 @@ -const integration = "pipedream"; - -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${index}. ${integration} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.message); - } - }); -}); diff --git a/test/__tests__/refiner_source.test.js b/test/__tests__/refiner_source.test.js deleted file mode 100644 index 5a064d0472..0000000000 --- a/test/__tests__/refiner_source.test.js +++ /dev/null @@ -1,23 +0,0 @@ -const integration = "refiner"; - -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${index}. ${integration} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.message); - } - }); -}); diff --git a/test/__tests__/satismeter_source.test.js b/test/__tests__/satismeter_source.test.js deleted file mode 100644 index d0d1a540d3..0000000000 --- a/test/__tests__/satismeter_source.test.js +++ /dev/null @@ -1,22 +0,0 @@ -const integration = "satismeter"; -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source.json`) -); - -const testData = JSON.parse(testDataFile); - -testData.forEach((data, index) => { - it(`${index}. ${integration} - ${data.description}`, () => { - try { - const output = transformer.process(data.input); - expect(output).toEqual(data.output); - } catch (error) { - expect(error.message).toEqual(data.output.error); - } - }); -}); diff --git a/test/__tests__/segment_source.test.js b/test/__tests__/segment_source.test.js deleted file mode 100644 index 3668232e4a..0000000000 --- a/test/__tests__/segment_source.test.js +++ /dev/null @@ -1,22 +0,0 @@ -const integration = "segment"; -const name = "Segment"; - -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - -test(`${name} Tests`, () => { - const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) - ); - const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) - ); - const inputData = JSON.parse(inputDataFile); - const expectedData = JSON.parse(outputDataFile); - inputData.forEach(async (input, index) => { - const output = transformer.process(input); - expect(output).toEqual(expectedData[index]); - }); -}); diff --git a/test/__tests__/shopify_source.test.js b/test/__tests__/shopify_source.test.js deleted file mode 100644 index 2a7e69bd82..0000000000 --- a/test/__tests__/shopify_source.test.js +++ /dev/null @@ -1,32 +0,0 @@ -const integration = "shopify"; -const name = "Shopify"; - -const fs = require("fs"); -const path = require("path"); - -const transformer = require(`../../src/v0/sources/${integration}/transform`); - - -// Processor Test Data -const testDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}.json`) -); -const testData = JSON.parse(testDataFile); -describe(`${name} Tests`, () => { - describe("Processor", () => { - testData.forEach((dataPoint, index) => { - it(`${index}. ${integration} - ${dataPoint.description}`, async () => { - try { - const output = await transformer.process(dataPoint.input); - // anonId is being set dynamically by the transformer. - // so removing it before json comparison. - // Note: the anonymousId field is removed from the output json as well. - delete output.anonymousId; - expect(output).toEqual(dataPoint.output); - } catch (error) { - expect(error.message).toEqual(dataPoint.output.error); - } - }); - }); - }); -}); diff --git a/test/__tests__/signl4_source.test.js b/test/__tests__/signl4_source.test.js deleted file mode 100644 index 2bdec5aedf..0000000000 --- a/test/__tests__/signl4_source.test.js +++ /dev/null @@ -1,30 +0,0 @@ -const integration = "signl4"; -const name = "SIGNL4"; - -const fs = require("fs"); -const path = require("path"); -const version = "v0"; - -const transformer = require(`../../src/${version}/sources/${integration}/transform`); - -const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_input.json`) -); -const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_source_output.json`) -); - -const inputData = JSON.parse(inputDataFile); -const expectedData = JSON.parse(outputDataFile); - -inputData.forEach((input, index) => { - it(`${name} Tests: payload: ${index}`, async () => { - try { - const output = await transformer.process(input); - delete output.anonymousId; - expect(output).toEqual(expectedData[index]); - } catch (error) { - expect(error.message).toEqual(expectedData[index].message); - } - }); -}); diff --git a/test/__tests__/utilities/test-utils.js b/test/__tests__/utilities/test-utils.js deleted file mode 100644 index 4d5d7fc909..0000000000 --- a/test/__tests__/utilities/test-utils.js +++ /dev/null @@ -1,135 +0,0 @@ -const fs = require("fs"); -const _ = require("lodash"); -const path = require("path"); -const { ConfigFactory, Executor } = require("rudder-transformer-cdk"); -const { assertRouterOutput } = require('../../testHelper'); - -// TODO: separate this out later as the list grows -const cdkEnabledDestinations = { - variance: true, - autopilot: true, - heap: true, - userlist: true, - lytics: true, - kochava: true, - statsig: true, - new_relic: true, - zapier: true, - vitally: true -}; - -function getDestFromTestFile(filePath) { - const filePathArr = filePath.split("/"); - return filePathArr[filePathArr.length - 1].replace(".test.js", ""); -} - -function formTestParams(dest, transformAt) { - //for router test - let trCat = ""; - if (transformAt === "router") { - trCat += "router_"; - } - const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `../data/${dest}_${trCat}input.json`) - ); - const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `../data/${dest}_${trCat}output.json`) - ); - const inputData = JSON.parse(inputDataFile); - const expected = JSON.parse(outputDataFile); - return { - input: inputData, - expected, - iscdkDest: cdkEnabledDestinations[dest] - }; -} - -function routerCommonformTestParams() { - const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `../data/routerCommonInput.json`) - ); - const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `../data/routerCommonOutput.json`) - ); - - const inputData = JSON.parse(inputDataFile); - const expected = JSON.parse(outputDataFile); - return { - commonInput: inputData, - commonExpected: expected - }; -} - -function fetchCdkStageFromConfig(destination) { - let cdkEnabled = false; - if ( - destination.DestinationDefinition && - destination.DestinationDefinition.Config && - destination.DestinationDefinition.Config.cdkEnabled - ) { - cdkEnabled = destination.DestinationDefinition.Config.cdkEnabled; - } - return cdkEnabled; -} - -function executeTransformationTest(dest, transformAt) { - const testParams = formTestParams(dest, transformAt); - const routerCommonTestParams = routerCommonformTestParams(); - const { iscdkDest, expected, input } = testParams; - const { commonInput, commonExpected } = routerCommonTestParams; - const basePath = path.resolve(__dirname, "../../../src/cdk/v1"); - ConfigFactory.init({ basePath, loggingMode: "production" }); - - describe(`${dest} ${transformAt} tests`, () => { - input.map((tcInput, index) => { - const cdkEnabled = fetchCdkStageFromConfig(tcInput.destination); - return it(`${dest} ${transformAt} tests - ${index}`, async () => { - let actualData; - try { - if ((iscdkDest || cdkEnabled) && transformAt === "processor") { - const baseConfig = await ConfigFactory.getConfig(dest); - // We currently support processor transformation only in CDK - actualData = await Executor.execute(tcInput, baseConfig); - } else { - const version = "v0"; - const transformer = require(`../../../src/${version}/destinations/${dest}/transform`); - if (transformAt == "processor") { - actualData = await transformer.process(tcInput); - } else { - actual = await transformer.processRouterDest([tcInput]) - assertRouterOutput(actual, [tcInput]); - actualData = (actual)[0]; - } - } - // Compare actual and expected data - expect(actualData).toEqual(expected[index]); - } catch (error) { - // Force fail the test case if the expected exception is not raised - expect(error.message).toEqual(expected[index].error); - } - }); - }); - }); - if (transformAt == "router") { - describe(`${dest} ${transformAt} Common tests`, () => { - it(`${dest} ${transformAt} Common tests`, async () => { - let actualData; - try { - const version = "v0"; - const transformer = require(`../../../src/${version}/destinations/${dest}/transform`); - actualData = await transformer.processRouterDest(commonInput); - assertRouterOutput(actualData, commonInput); - const cloneActual = _.cloneDeep(actualData); - cloneActual[0].statTags = "undefined"; - // Compare actual and expected data - expect(cloneActual).toEqual(commonExpected); - } catch (error) { - // Force fail the test case if the expected exception is not raised - expect(error.message).toEqual(commonExpected); - } - }); - }); - } -} - -module.exports = { getDestFromTestFile, executeTransformationTest }; diff --git a/test/apitests/data_scenarios/cdk_v1/failure.json b/test/apitests/data_scenarios/cdk_v1/failure.json deleted file mode 100644 index df45006d84..0000000000 --- a/test/apitests/data_scenarios/cdk_v1/failure.json +++ /dev/null @@ -1,164 +0,0 @@ -{ - "input": [ - { - "message": { - "anonymousId": "2073230", - "channel": "offline", - "context": { - "traits": { - "email": "test.c97@gmail.com", - "firstName": "test", - "gender": "Male", - "lastName": "Rudderlabs", - "phone": "+919876543210" - } - }, - "event": "Product Added", - "messageId": "2af9f397-eef2-407f-bd95-e61867c0bfd0", - "originalTimestamp": "2022-12-30T21:12:23.295+05:30", - "properties": { - "brand": "Gamepro", - "category": "Games", - "coupon": "DISC21", - "image_url": "https://www.website.com/product/path.png", - "name": "Game", - "position": 1, - "price": 13.49, - "product_id": "123", - "quantity": 11, - "sku": "F15", - "url": "https://www.website.com/product/path", - "variant": "111" - }, - "receivedAt": "2022-12-30T21:12:19.720+05:30", - "request_ip": "[::1]", - "rudderId": "c6bac0d9-5ed4-45d8-a937-bf9e62060b78", - "sentAt": "2022-12-30T21:12:23.295+05:30", - "timestamp": "2022-12-30T21:12:19.719+05:30", - "type": "track", - "userId": "2564871" - }, - "metadata": { - "sourceId": "27O0bmEEx3GgfmEhZHUcPwJQVWC", - "workspaceId": "27O0bhB6p5ehfOWeeZlOSsSDTLg", - "namespace": "", - "instanceId": "1", - "sourceType": "HTTP", - "sourceCategory": "", - "trackingPlanId": "", - "trackingPlanVersion": 0, - "sourceTpConfig": null, - "mergedTpConfig": null, - "destinationId": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "jobRunId": "", - "jobId": 1, - "sourceBatchId": "", - "sourceJobId": "", - "sourceJobRunId": "", - "sourceTaskId": "", - "sourceTaskRunId": "", - "recordId": null, - "destinationType": "ZAPIER", - "messageId": "2af9f397-eef2-407f-bd95-e61867c0bfd0", - "oauthAccessToken": "", - "messageIds": null, - "rudderId": "<<>>2073230<<>>2564871", - "receivedAt": "2022-12-30T21:12:19.720+05:30", - "eventName": "Product Added", - "eventType": "track", - "sourceDefinitionId": "1b6gJdqOPOCadT3cddw8eidV591", - "destinationDefinitionId": "" - }, - "destination": { - "ID": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "Name": "Zapier-dev", - "DestinationDefinition": { - "ID": "2EAFTAOU0JrG8tHwYB5ZlV7yzo6", - "Name": "ZAPIER", - "DisplayName": "Zapier", - "Config": { - "cdkEnabled": true, - "destConfig": { - "defaultConfig": ["zapUrl", "trackEventsToZap", "pageScreenEventsToZap"] - }, - "excludeKeys": [], - "includeKeys": ["zapUrl", "trackEventsToZap", "pageScreenEventsToZap"], - "saveDestinationResponse": true, - "secretKeys": ["zapUrl"], - "supportedMessageTypes": ["track", "page", "screen"], - "supportedSourceTypes": [ - "android", - "ios", - "web", - "unity", - "amp", - "cloud", - "reactnative", - "flutter", - "cordova", - "warehouse" - ], - "transformAt": "processor", - "transformAtV1": "processor" - }, - "ResponseRules": {} - }, - "Config": { - "zapUrl": "https://hooks.zapier.com/hooks/catch/14157843/b7l4oz2/" - }, - "Enabled": true, - "WorkspaceID": "27O0bhB6p5ehfOWeeZlOSsSDTLg", - "Transformations": [], - "IsProcessorEnabled": true, - "RevisionID": "2JdjA2o6s9AfokHcz6bX0SPCdJZ" - }, - "libraries": null - } - ], - "output": [ - { - "metadata": { - "sourceId": "27O0bmEEx3GgfmEhZHUcPwJQVWC", - "workspaceId": "27O0bhB6p5ehfOWeeZlOSsSDTLg", - "namespace": "", - "instanceId": "1", - "sourceType": "HTTP", - "sourceCategory": "", - "trackingPlanId": "", - "trackingPlanVersion": 0, - "sourceTpConfig": null, - "mergedTpConfig": null, - "destinationId": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "jobRunId": "", - "jobId": 1, - "sourceBatchId": "", - "sourceJobId": "", - "sourceJobRunId": "", - "sourceTaskId": "", - "sourceTaskRunId": "", - "recordId": null, - "destinationType": "ZAPIER", - "messageId": "2af9f397-eef2-407f-bd95-e61867c0bfd0", - "oauthAccessToken": "", - "messageIds": null, - "rudderId": "<<>>2073230<<>>2564871", - "receivedAt": "2022-12-30T21:12:19.720+05:30", - "eventName": "Product Added", - "eventType": "track", - "sourceDefinitionId": "1b6gJdqOPOCadT3cddw8eidV591", - "destinationDefinitionId": "" - }, - "statusCode": 400, - "error": "Unknown error occurred. Original error: Unsupported \"channel\": \"offline\". It must be one of: web,server,mobile,sources", - "statTags": { - "errorCategory": "transformation", - "destType": "ZAPIER", - "module": "destination", - "implementation": "cdkV1", - "feature": "processor", - "destinationId": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "workspaceId": "27O0bhB6p5ehfOWeeZlOSsSDTLg" - } - } - ] -} diff --git a/test/apitests/data_scenarios/cdk_v1/success.json b/test/apitests/data_scenarios/cdk_v1/success.json deleted file mode 100644 index 68d68a2b5f..0000000000 --- a/test/apitests/data_scenarios/cdk_v1/success.json +++ /dev/null @@ -1,208 +0,0 @@ -{ - "input": [ - { - "message": { - "anonymousId": "2073230", - "channel": "web", - "context": { - "traits": { - "email": "test.c97@gmail.com", - "firstName": "test", - "gender": "Male", - "lastName": "Rudderlabs", - "phone": "+919876543210" - } - }, - "event": "Product Added", - "messageId": "ace693c0-79c3-47b8-9e7f-6a894672597f", - "originalTimestamp": "2022-12-31T20:30:35.282+05:30", - "properties": { - "brand": "Gamepro", - "category": "Games", - "coupon": "DISC21", - "image_url": "https://www.website.com/product/path.png", - "name": "Game", - "position": 1, - "price": 13.49, - "product_id": "123", - "quantity": 11, - "sku": "F15", - "url": "https://www.website.com/product/path", - "variant": "111" - }, - "receivedAt": "2022-12-31T20:30:34.567+05:30", - "request_ip": "[::1]", - "rudderId": "c6bac0d9-5ed4-45d8-a937-bf9e62060b78", - "sentAt": "2022-12-31T20:30:35.282+05:30", - "timestamp": "2022-12-31T20:30:34.566+05:30", - "type": "track", - "userId": "2564871" - }, - "metadata": { - "sourceId": "27O0bmEEx3GgfmEhZHUcPwJQVWC", - "workspaceId": "27O0bhB6p5ehfOWeeZlOSsSDTLg", - "namespace": "", - "instanceId": "1", - "sourceType": "HTTP", - "sourceCategory": "", - "trackingPlanId": "", - "trackingPlanVersion": 0, - "sourceTpConfig": null, - "mergedTpConfig": null, - "destinationId": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "jobRunId": "", - "jobId": 1, - "sourceBatchId": "", - "sourceJobId": "", - "sourceJobRunId": "", - "sourceTaskId": "", - "sourceTaskRunId": "", - "recordId": null, - "destinationType": "ZAPIER", - "messageId": "ace693c0-79c3-47b8-9e7f-6a894672597f", - "oauthAccessToken": "", - "messageIds": null, - "rudderId": "<<>>2073230<<>>2564871", - "receivedAt": "2022-12-31T20:30:34.567+05:30", - "eventName": "Product Added", - "eventType": "track", - "sourceDefinitionId": "1b6gJdqOPOCadT3cddw8eidV591", - "destinationDefinitionId": "" - }, - "destination": { - "ID": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "Name": "Zapier-dev", - "DestinationDefinition": { - "ID": "2EAFTAOU0JrG8tHwYB5ZlV7yzo6", - "Name": "ZAPIER", - "DisplayName": "Zapier", - "Config": { - "cdkEnabled": true, - "destConfig": { - "defaultConfig": ["zapUrl", "trackEventsToZap", "pageScreenEventsToZap"] - }, - "excludeKeys": [], - "includeKeys": ["zapUrl", "trackEventsToZap", "pageScreenEventsToZap"], - "saveDestinationResponse": true, - "secretKeys": ["zapUrl"], - "supportedMessageTypes": ["track", "page", "screen"], - "supportedSourceTypes": [ - "android", - "ios", - "web", - "unity", - "amp", - "cloud", - "reactnative", - "flutter", - "cordova", - "warehouse" - ], - "transformAt": "processor", - "transformAtV1": "processor" - }, - "ResponseRules": {} - }, - "Config": { - "zapUrl": "https://hooks.zapier.com/hooks/catch/test/abc/" - }, - "Enabled": true, - "WorkspaceID": "27O0bhB6p5ehfOWeeZlOSsSDTLg", - "Transformations": [], - "IsProcessorEnabled": true, - "RevisionID": "2JdjA2o6s9AfokHcz6bX0SPCdJZ" - }, - "libraries": null - } - ], - "output": [ - { - "output": { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://hooks.zapier.com/hooks/catch/test/abc/", - "headers": { - "content-type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "anonymousId": "2073230", - "channel": "web", - "context": { - "traits": { - "email": "test.c97@gmail.com", - "firstName": "test", - "gender": "Male", - "lastName": "Rudderlabs", - "phone": "+919876543210" - } - }, - "event": "Product Added", - "messageId": "ace693c0-79c3-47b8-9e7f-6a894672597f", - "originalTimestamp": "2022-12-31T20:30:35.282+05:30", - "properties": { - "brand": "Gamepro", - "category": "Games", - "coupon": "DISC21", - "image_url": "https://www.website.com/product/path.png", - "name": "Game", - "position": 1, - "price": 13.49, - "product_id": "123", - "quantity": 11, - "sku": "F15", - "url": "https://www.website.com/product/path", - "variant": "111" - }, - "receivedAt": "2022-12-31T20:30:34.567+05:30", - "request_ip": "[::1]", - "rudderId": "c6bac0d9-5ed4-45d8-a937-bf9e62060b78", - "sentAt": "2022-12-31T20:30:35.282+05:30", - "timestamp": "2022-12-31T20:30:34.566+05:30", - "type": "track", - "userId": "2564871" - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {}, - "userId": "" - }, - "metadata": { - "sourceId": "27O0bmEEx3GgfmEhZHUcPwJQVWC", - "workspaceId": "27O0bhB6p5ehfOWeeZlOSsSDTLg", - "namespace": "", - "instanceId": "1", - "sourceType": "HTTP", - "sourceCategory": "", - "trackingPlanId": "", - "trackingPlanVersion": 0, - "sourceTpConfig": null, - "mergedTpConfig": null, - "destinationId": "2JVZ3owjdCdDajoiZwWgJbR9y0q", - "jobRunId": "", - "jobId": 1, - "sourceBatchId": "", - "sourceJobId": "", - "sourceJobRunId": "", - "sourceTaskId": "", - "sourceTaskRunId": "", - "recordId": null, - "destinationType": "ZAPIER", - "messageId": "ace693c0-79c3-47b8-9e7f-6a894672597f", - "oauthAccessToken": "", - "messageIds": null, - "rudderId": "<<>>2073230<<>>2564871", - "receivedAt": "2022-12-31T20:30:34.567+05:30", - "eventName": "Product Added", - "eventType": "track", - "sourceDefinitionId": "1b6gJdqOPOCadT3cddw8eidV591", - "destinationDefinitionId": "" - }, - "statusCode": 200 - } - ] -} diff --git a/test/apitests/data_scenarios/source/v1/successful.json b/test/apitests/data_scenarios/source/v1/successful.json index c42d723800..bb93e72fcd 100644 --- a/test/apitests/data_scenarios/source/v1/successful.json +++ b/test/apitests/data_scenarios/source/v1/successful.json @@ -29,7 +29,8 @@ "fulfillment_id": "1234567890", "status": "pending" } - } + }, + "context": {} } ] } diff --git a/test/apitests/service.api.test.ts b/test/apitests/service.api.test.ts index e46357f824..30d2c568a6 100644 --- a/test/apitests/service.api.test.ts +++ b/test/apitests/service.api.test.ts @@ -359,8 +359,8 @@ describe('Api tests with a mock source/destination', () => { .send(getData()); const expected = [ - { output: { batch: [{ event: 'clicked', type: 'track' }] } }, - { output: { batch: [{ event: 'clicked', type: 'track' }] } }, + { output: { batch: [{ event: 'clicked', type: 'track', context: {} }] } }, + { output: { batch: [{ event: 'clicked', type: 'track', context: {} }] } }, ]; expect(response.status).toEqual(200); @@ -398,8 +398,8 @@ describe('Api tests with a mock source/destination', () => { .send(getData()); const expected = [ - { output: { batch: [{ event: 'clicked', type: 'track' }] } }, - { output: { batch: [{ event: 'clicked', type: 'track' }] } }, + { output: { batch: [{ event: 'clicked', type: 'track', context: {} }] } }, + { output: { batch: [{ event: 'clicked', type: 'track', context: {} }] } }, ]; expect(response.status).toEqual(200); @@ -604,28 +604,6 @@ describe('Source api tests', () => { }); }); -describe('CDK V1 api tests', () => { - test('(zapier) successful transform', async () => { - const data = getDataFromPath('./data_scenarios/cdk_v1/success.json'); - const response = await request(server) - .post('/v0/destinations/zapier') - .set('Accept', 'application/json') - .send(data.input); - expect(response.status).toEqual(200); - expect(JSON.parse(response.text)).toEqual(data.output); - }); - - test('(zapier) failure transform', async () => { - const data = getDataFromPath('./data_scenarios/cdk_v1/failure.json'); - const response = await request(server) - .post('/v0/destinations/zapier') - .set('Accept', 'application/json') - .send(data.input); - expect(response.status).toEqual(200); - expect(JSON.parse(response.text)).toEqual(data.output); - }); -}); - describe('CDK V2 api tests', () => { test('(pinterest_tag) successful transform', async () => { const data = getDataFromPath('./data_scenarios/cdk_v2/success.json'); diff --git a/test/integrations/component.test.ts b/test/integrations/component.test.ts index 388c283c61..e7645db64d 100644 --- a/test/integrations/component.test.ts +++ b/test/integrations/component.test.ts @@ -28,7 +28,7 @@ import _ from 'lodash'; // To run single destination test cases // npm run test:ts -- component --destination=adobe_analytics // npm run test:ts -- component --destination=adobe_analytics --feature=router -// npm run test:ts -- component --destination=adobe_analytics --feature=router --index=0 +// npm run test:ts -- component --destination=adobe_analytics --feature=dataDelivery --index=0 // Use below command to generate mocks // npm run test:ts -- component --destination=zendesk --generate=true @@ -101,6 +101,8 @@ if (!opts.generate || opts.generate === 'false') { // END const rootDir = __dirname; +console.log('rootDir', rootDir); +console.log('opts', opts); const allTestDataFilePaths = getTestDataFilePaths(rootDir, opts); const DEFAULT_VERSION = 'v0'; @@ -209,6 +211,7 @@ const sourceTestHandler = async (tcData) => { // Trigger the test suites describe.each(allTestDataFilePaths)('%s Tests', (testDataPath) => { beforeEach(() => { + jest.resetAllMocks(); jest.clearAllMocks(); }); // add special mocks for specific destinations diff --git a/test/integrations/destinations/af/deleteUsers/data.ts b/test/integrations/destinations/af/deleteUsers/data.ts index c552b79f67..608e7e5586 100644 --- a/test/integrations/destinations/af/deleteUsers/data.ts +++ b/test/integrations/destinations/af/deleteUsers/data.ts @@ -7,7 +7,7 @@ import utils from '../../../../../src/v0/util'; const defaultMockFns = () => { jest.spyOn(Date.prototype, 'toISOString').mockReturnValue('2023-09-24T11:22:24.018Z'); - jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); + jest.spyOn(utils, 'generateUUID').mockReturnValueOnce('97fcd7b2-cc24-47d7-b776-057b7b199513'); }; const requests = [ diff --git a/test/integrations/destinations/airship/processor/data.ts b/test/integrations/destinations/airship/processor/data.ts index cafbd02e74..3a6c5394cb 100644 --- a/test/integrations/destinations/airship/processor/data.ts +++ b/test/integrations/destinations/airship/processor/data.ts @@ -2381,4 +2381,9 @@ export const data = [ }, }, }, -]; +].map((tc) => ({ + ...tc, + mockFns: (_) => { + jest.spyOn(Date.prototype, 'toISOString').mockReturnValue('2015-02-23T22:28:55Z'); + }, +})); diff --git a/test/integrations/destinations/airship/router/data.ts b/test/integrations/destinations/airship/router/data.ts index 8ed6f57a42..df500d7413 100644 --- a/test/integrations/destinations/airship/router/data.ts +++ b/test/integrations/destinations/airship/router/data.ts @@ -465,4 +465,10 @@ export const data = [ }, }, }, -]; +].map((tc) => ({ + ...tc, + mockFns: (_) => { + jest.spyOn(Date.prototype, 'toISOString').mockReturnValue('2015-02-23T22:28:55Z'); + // jest.spyOn(Date, 'now').mockReturnValue(new Date('2023-10-14T12:34:56.789Z').valueOf()); + }, +})); diff --git a/test/integrations/destinations/algolia/processor/data.ts b/test/integrations/destinations/algolia/processor/data.ts index d239c8de70..b37b6e4246 100644 --- a/test/integrations/destinations/algolia/processor/data.ts +++ b/test/integrations/destinations/algolia/processor/data.ts @@ -2429,4 +2429,145 @@ export const data = [ }, }, }, + { + name: 'algolia', + description: 'queryID and queryId inconsistency test', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + channel: 'web', + context: { + app: { + build: '1.0.0', + name: 'RudderLabs JavaScript SDK', + namespace: 'com.rudderlabs.javascript', + version: '1.0.0', + }, + traits: { + email: 'testone@gmail.com', + firstName: 'test', + lastName: 'one', + }, + library: { + name: 'RudderLabs JavaScript SDK', + version: '1.0.0', + }, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36', + locale: 'en-US', + ip: '0.0.0.0', + os: { + name: '', + version: '', + }, + screen: { + density: 2, + }, + page: { + path: '/destinations/ometria', + referrer: '', + search: '', + title: '', + url: 'https://docs.rudderstack.com/destinations/ometria', + category: 'destination', + initial_referrer: 'https://docs.rudderstack.com', + initial_referring_domain: 'docs.rudderstack.com', + }, + }, + type: 'track', + messageId: '84e26acc-56a5-4835-8233-591137fca468', + session_id: '3049dc4c-5a95-4ccd-a3e7-d74a7e411f22', + originalTimestamp: '2019-10-14T09:03:17.562Z', + anonymousId: '123456', + event: 'product list viewed', + userId: 'testuserId1', + properties: { + index: 'products', + eventSubtype: 'purchase', + filters: ['field1:hello', 'val1:val2'], + queryId: '43b15df305339e827f0ac0bdc5ebcaa7', + }, + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + destinationId: 'destId', + workspaceId: 'wspId', + }, + destination: { + DestinationDefinition: { + Config: { + cdkV2Enabled: true, + excludeKeys: [], + includeKeys: [], + }, + }, + Config: { + apiKey: 'dummyApiKey', + applicationId: 'O2YARRI15I', + eventTypeSettings: [ + { + from: 'product list viewed', + to: 'conversion', + }, + ], + }, + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + body: { + JSON: { + events: [ + { + index: 'products', + queryID: '43b15df305339e827f0ac0bdc5ebcaa7', + filters: ['field1:hello', 'val1:val2'], + userToken: 'testuserId1', + eventName: 'product list viewed', + eventType: 'conversion', + eventSubtype: 'purchase', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://insights.algolia.io/1/events', + headers: { + 'X-Algolia-Application-Id': 'O2YARRI15I', + 'X-Algolia-API-Key': 'dummyApiKey', + }, + params: {}, + files: {}, + userId: '', + }, + statusCode: 200, + metadata: { + destinationId: 'destId', + workspaceId: 'wspId', + }, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/attentive_tag/processor/data.ts b/test/integrations/destinations/attentive_tag/processor/data.ts index f585fb58d8..137a9aee9a 100644 --- a/test/integrations/destinations/attentive_tag/processor/data.ts +++ b/test/integrations/destinations/attentive_tag/processor/data.ts @@ -1,5 +1,5 @@ export const mockFns = (_) => { - jest.useFakeTimers().setSystemTime(new Date('2023-10-14')); + jest.spyOn(Date, 'now').mockReturnValue(new Date('2023-10-14T00:00:00.000Z').valueOf()); }; export const data = [ @@ -1458,7 +1458,7 @@ export const data = [ body: [ { statusCode: 400, - error: '[Attentive Tag]:The event name contains characters which is not allowed', + error: '[Attentive Tag]:The properties contains characters which is not allowed', statTags: { destType: 'ATTENTIVE_TAG', errorCategory: 'dataValidation', @@ -1678,4 +1678,95 @@ export const data = [ }, }, }, -]; + { + name: 'attentive_tag', + description: 'Test 16', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + channel: 'web', + context: { + app: { + build: '1.0.0', + name: 'RudderLabs JavaScript SDK', + namespace: 'com.rudderlabs.javascript', + version: '1.0.0', + }, + traits: {}, + library: { + name: 'RudderLabs JavaScript SDK', + version: '1.0.0', + }, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36', + locale: 'en-US', + ip: '0.0.0.0', + os: { + id: '72e528f869711c3d', + manufacturer: 'Google', + model: 'sdk_gphone_x86', + name: 'generic_x86_arm', + token: 'some_device_token', + type: 'android', + }, + screen: { + density: 2, + }, + }, + type: 'track', + event: 'Application Backgrounded', + anonymousId: '00000000000000000000000000', + userId: '123456', + integrations: { + All: true, + }, + }, + destination: { + Config: { + apiKey: 'dummyApiKey', + signUpSourceId: '240654', + }, + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + userId: '', + endpoint: 'https://api.attentivemobile.com/v1/events/custom', + headers: { + Authorization: 'Bearer dummyApiKey', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + user: {}, + type: 'Application Backgrounded', + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + statusCode: 200, + }, + ], + }, + }, + }, +].map((d) => ({ ...d, mockFns })); diff --git a/test/integrations/destinations/bloomreach_catalog/common.ts b/test/integrations/destinations/bloomreach_catalog/common.ts new file mode 100644 index 0000000000..2b4266837b --- /dev/null +++ b/test/integrations/destinations/bloomreach_catalog/common.ts @@ -0,0 +1,81 @@ +import { Destination } from '../../../../src/types'; + +const destType = 'bloomreach_catalog'; +const destTypeInUpperCase = 'BLOOMREACH_CATALOG'; +const displayName = 'bloomreach catalog'; +const channel = 'web'; +const destination: Destination = { + Config: { + apiBaseUrl: 'https://demoapp-api.bloomreach.com', + apiKey: 'test-api-key', + apiSecret: 'test-api-secret', + projectToken: 'test-project-token', + catalogID: 'test-catalog-id', + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', +}; + +const insertEndpoint = + 'https://demoapp-api.bloomreach.com/data/v2/projects/test-project-token/catalogs/test-catalog-id/items'; +const updateEndpoint = + 'https://demoapp-api.bloomreach.com/data/v2/projects/test-project-token/catalogs/test-catalog-id/items/partial-update'; +const deleteEndpoint = + 'https://demoapp-api.bloomreach.com/data/v2/projects/test-project-token/catalogs/test-catalog-id/items/bulk-delete'; + +const processorInstrumentationErrorStatTags = { + destType: destTypeInUpperCase, + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'cdkV2', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', +}; + +const RouterInstrumentationErrorStatTags = { + ...processorInstrumentationErrorStatTags, + feature: 'router', +}; + +const proxyV1RetryableErrorStatTags = { + ...RouterInstrumentationErrorStatTags, + errorCategory: 'network', + errorType: 'retryable', + feature: 'dataDelivery', + implementation: 'native', +}; + +const headers = { + 'Content-Type': 'application/json', + Authorization: 'Basic dGVzdC1hcGkta2V5OnRlc3QtYXBpLXNlY3JldA==', +}; + +const sampleContext = { + destinationFields: 'item_id, title, status, unprinted', + mappedToDestination: 'true', +}; + +export { + destType, + channel, + destination, + processorInstrumentationErrorStatTags, + RouterInstrumentationErrorStatTags, + headers, + proxyV1RetryableErrorStatTags, + insertEndpoint, + updateEndpoint, + deleteEndpoint, + sampleContext, +}; diff --git a/test/integrations/destinations/bloomreach_catalog/dataDelivery/data.ts b/test/integrations/destinations/bloomreach_catalog/dataDelivery/data.ts new file mode 100644 index 0000000000..f8cccd04ed --- /dev/null +++ b/test/integrations/destinations/bloomreach_catalog/dataDelivery/data.ts @@ -0,0 +1,197 @@ +import { ProxyV1TestData } from '../../../testTypes'; +import { destType, headers, updateEndpoint } from '../common'; +import { generateMetadata, generateProxyV1Payload } from '../../../testUtils'; + +export const data: ProxyV1TestData[] = [ + { + id: 'bloomreach_catalog_v1_business_scenario_1', + name: destType, + description: + '[Proxy v1 API] :: Test for a valid record request - where the destination responds with 200 with error for request 2 in a batch', + successCriteria: 'Should return 200 with partial failures within the response payload', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + headers, + params: {}, + JSON: {}, + JSON_ARRAY: { + batch: + '[{"item_id":"test-item-id","properties":{"unprinted":"1"}},{"item_id":"test-item-id-faulty","properties":{"unprinted1":"1"}}]', + }, + endpoint: updateEndpoint, + }, + [generateMetadata(1), generateMetadata(2)], + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 200, + message: '[BLOOMREACH_CATALOG Response V1 Handler] - Request Processed Successfully', + destinationResponse: { + response: [ + { + success: true, + queued: true, + }, + { + success: false, + queued: false, + errors: { + properties: ['Fields [unprinted1] are not properly defined.'], + }, + }, + ], + status: 200, + }, + response: [ + { + statusCode: 200, + metadata: generateMetadata(1), + error: 'success', + }, + { + statusCode: 400, + metadata: generateMetadata(2), + error: 'Fields [unprinted1] are not properly defined.', + }, + ], + }, + }, + }, + }, + }, + { + id: 'bloomreach_catalog_v1_business_scenario_2', + name: destType, + description: + '[Proxy v1 API] :: Test for a valid rETL request - where the destination responds with 200 without any error', + successCriteria: 'Should return 200 with no error with destination response', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + headers, + params: {}, + JSON: {}, + JSON_ARRAY: { + batch: + '[{"item_id":"test-item-id-1","properties":{"unprinted":"1"}},{"item_id":"test-item-id-2","properties":{"unprinted":"2"}}]', + }, + endpoint: updateEndpoint, + }, + [generateMetadata(3), generateMetadata(4)], + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 200, + message: '[BLOOMREACH_CATALOG Response V1 Handler] - Request Processed Successfully', + destinationResponse: { + response: [ + { + success: true, + queued: true, + }, + { + success: true, + queued: true, + }, + ], + status: 200, + }, + response: [ + { + statusCode: 200, + metadata: generateMetadata(3), + error: 'success', + }, + { + statusCode: 200, + metadata: generateMetadata(4), + error: 'success', + }, + ], + }, + }, + }, + }, + }, + { + id: 'bloomreach_catalog_v1_business_scenario_3', + name: destType, + description: + '[Proxy v1 API] :: Test for a valid rETL request - where the destination responds with 200 with error', + successCriteria: 'Should return 400 with error message', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + headers, + params: {}, + JSON: {}, + JSON_ARRAY: { + batch: '[{"item_id":"test-item-id-faulty","properties":{"unprinted1":"1"}}]', + }, + endpoint: updateEndpoint, + }, + [generateMetadata(5)], + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 200, + message: '[BLOOMREACH_CATALOG Response V1 Handler] - Request Processed Successfully', + destinationResponse: { + response: [ + { + success: false, + queued: false, + errors: { + properties: ['Fields [unprinted1] are not properly defined.'], + }, + }, + ], + status: 200, + }, + response: [ + { + statusCode: 400, + metadata: generateMetadata(5), + error: 'Fields [unprinted1] are not properly defined.', + }, + ], + }, + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/bloomreach_catalog/mocks.ts b/test/integrations/destinations/bloomreach_catalog/mocks.ts new file mode 100644 index 0000000000..bb07c0ea72 --- /dev/null +++ b/test/integrations/destinations/bloomreach_catalog/mocks.ts @@ -0,0 +1,5 @@ +import * as config from '../../../../src/cdk/v2/destinations/bloomreach_catalog/config'; + +export const defaultMockFns = () => { + jest.replaceProperty(config, 'MAX_ITEMS', 2 as typeof config.MAX_ITEMS); +}; diff --git a/test/integrations/destinations/bloomreach_catalog/network.ts b/test/integrations/destinations/bloomreach_catalog/network.ts new file mode 100644 index 0000000000..b8ae078498 --- /dev/null +++ b/test/integrations/destinations/bloomreach_catalog/network.ts @@ -0,0 +1,108 @@ +import { destType, headers, updateEndpoint } from './common'; + +export const networkCallsData = [ + { + httpReq: { + url: updateEndpoint, + data: [ + { + item_id: 'test-item-id', + properties: { + unprinted: '1', + }, + }, + { + item_id: 'test-item-id-faulty', + properties: { + unprinted1: '1', + }, + }, + ], + params: { destination: destType }, + headers, + method: 'POST', + }, + httpRes: { + data: [ + { + success: true, + queued: true, + }, + { + success: false, + queued: false, + errors: { + properties: ['Fields [unprinted1] are not properly defined.'], + }, + }, + ], + status: 200, + statusText: 'Ok', + }, + }, + { + httpReq: { + url: updateEndpoint, + data: [ + { + item_id: 'test-item-id-1', + properties: { + unprinted: '1', + }, + }, + { + item_id: 'test-item-id-2', + properties: { + unprinted: '2', + }, + }, + ], + params: { destination: destType }, + headers, + method: 'POST', + }, + httpRes: { + data: [ + { + success: true, + queued: true, + }, + { + success: true, + queued: true, + }, + ], + status: 200, + statusText: 'Ok', + }, + }, + { + httpReq: { + url: updateEndpoint, + data: [ + { + item_id: 'test-item-id-faulty', + properties: { + unprinted1: '1', + }, + }, + ], + params: { destination: destType }, + headers, + method: 'POST', + }, + httpRes: { + data: [ + { + success: false, + queued: false, + errors: { + properties: ['Fields [unprinted1] are not properly defined.'], + }, + }, + ], + status: 200, + statusText: 'Ok', + }, + }, +]; diff --git a/test/integrations/destinations/bloomreach_catalog/router/data.ts b/test/integrations/destinations/bloomreach_catalog/router/data.ts new file mode 100644 index 0000000000..68ab422444 --- /dev/null +++ b/test/integrations/destinations/bloomreach_catalog/router/data.ts @@ -0,0 +1,328 @@ +import { generateMetadata } from '../../../testUtils'; +import { defaultMockFns } from '../mocks'; +import { + destType, + destination, + headers, + RouterInstrumentationErrorStatTags, + insertEndpoint, + updateEndpoint, + deleteEndpoint, + sampleContext, +} from '../common'; + +const routerRequest = { + input: [ + { + message: { + type: 'record', + action: 'insert', + fields: { + item_id: 'test-item-id', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 1, + }, + channel: 'sources', + context: sampleContext, + recordId: '1', + }, + metadata: generateMetadata(1), + destination, + }, + { + message: { + type: 'record', + action: 'insert', + fields: { + item_id: 'test-item-id-7', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 1, + test_empty: '', + test_null: null, + test_empty_array: [], + }, + channel: 'sources', + context: sampleContext, + recordId: '2', + }, + metadata: generateMetadata(2), + destination, + }, + { + message: { + type: 'record', + action: 'update', + fields: { + item_id: 'test-item-id', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 3, + }, + channel: 'sources', + context: sampleContext, + recordId: '3', + }, + metadata: generateMetadata(3), + destination, + }, + { + message: { + type: 'record', + action: 'update', + fields: { + item_id: 'test-item-id', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 2, + }, + channel: 'sources', + context: sampleContext, + recordId: '4', + }, + metadata: generateMetadata(4), + destination, + }, + { + message: { + type: 'record', + action: 'delete', + fields: { + item_id: 'test-item-id-1', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 1, + }, + channel: 'sources', + context: sampleContext, + recordId: '5', + }, + metadata: generateMetadata(5), + destination, + }, + { + message: { + type: 'record', + action: 'delete', + fields: { + item_id: 'test-item-id-2', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 1, + }, + channel: 'sources', + context: sampleContext, + recordId: '6', + }, + metadata: generateMetadata(6), + destination, + }, + { + message: { + type: 'record', + action: 'delete', + fields: { + item_id: 'test-item-id-3', + title: 'Hardcover Monthbooks', + status: 'up to date', + unprinted: 1, + }, + channel: 'sources', + context: sampleContext, + recordId: '7', + }, + metadata: generateMetadata(7), + destination, + }, + { + message: { + type: 'record', + action: 'insert', + fields: {}, + channel: 'sources', + context: sampleContext, + recordId: '8', + }, + metadata: generateMetadata(8), + destination, + }, + { + message: { + type: 'record', + action: 'dummy-action', + fields: { + item_id: 'test-item-id', + }, + channel: 'sources', + context: sampleContext, + recordId: '9', + }, + metadata: generateMetadata(9), + destination, + }, + { + message: { + type: 'record', + action: 'insert', + fields: { + item_id: null, + }, + channel: 'sources', + context: sampleContext, + recordId: '10', + }, + metadata: generateMetadata(10), + destination, + }, + ], + destType, +}; + +export const data = [ + { + id: 'bloomreach-catalog-router-test-1', + name: destType, + description: 'Basic Router Test to test record payloads', + scenario: 'Framework', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: routerRequest, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'PUT', + endpoint: insertEndpoint, + headers, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: { + batch: + '[{"item_id":"test-item-id","properties":{"title":"Hardcover Monthbooks","status":"up to date","unprinted":1}},{"item_id":"test-item-id-7","properties":{"title":"Hardcover Monthbooks","status":"up to date","unprinted":1,"test_empty":"","test_null":null,"test_empty_array":[]}}]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(1), generateMetadata(2)], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: updateEndpoint, + headers, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: { + batch: + '[{"item_id":"test-item-id","properties":{"title":"Hardcover Monthbooks","status":"up to date","unprinted":3}},{"item_id":"test-item-id","properties":{"title":"Hardcover Monthbooks","status":"up to date","unprinted":2}}]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(3), generateMetadata(4)], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'DELETE', + endpoint: deleteEndpoint, + headers, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: { + batch: '["test-item-id-1","test-item-id-2"]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(5), generateMetadata(6)], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'DELETE', + endpoint: deleteEndpoint, + headers, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: { + batch: '["test-item-id-3"]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(7)], + batched: true, + statusCode: 200, + destination, + }, + { + metadata: [generateMetadata(8)], + batched: false, + statusCode: 400, + error: '`fields` cannot be empty', + statTags: RouterInstrumentationErrorStatTags, + destination, + }, + { + metadata: [generateMetadata(9)], + batched: false, + statusCode: 400, + error: + 'Invalid action type dummy-action. You can only add, update or remove items from the catalog', + statTags: RouterInstrumentationErrorStatTags, + destination, + }, + { + metadata: [generateMetadata(10)], + batched: false, + statusCode: 400, + error: '`item_id` cannot be empty', + statTags: RouterInstrumentationErrorStatTags, + destination, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, +]; diff --git a/test/integrations/destinations/braze/processor/data.ts b/test/integrations/destinations/braze/processor/data.ts index 644bebace1..240206791e 100644 --- a/test/integrations/destinations/braze/processor/data.ts +++ b/test/integrations/destinations/braze/processor/data.ts @@ -309,6 +309,7 @@ export const data = [ name: 'braze revenue test', time: '2020-01-24T11:59:02.403+05:30', properties: { + currency: 'USD', revenue: 50, }, external_id: 'mickeyMouse', @@ -437,6 +438,7 @@ export const data = [ time: '2020-01-24T11:59:02.403+05:30', properties: { revenue: 50, + currency: 'USD', }, external_id: 'mickeyMouse', }, @@ -772,6 +774,7 @@ export const data = [ properties: { currency: 'USD', revenue: 50, + event_name: 'braze revenue test 2', }, receivedAt: '2020-01-24T11:59:02.403+05:30', request_ip: '[::1]:53710', @@ -823,6 +826,7 @@ export const data = [ time: '2020-01-24T11:59:02.403+05:30', properties: { revenue: 50, + currency: 'USD', }, _update_existing_only: false, user_alias: { @@ -993,6 +997,7 @@ export const data = [ affiliation: 'Google Store', checkout_id: 'fksdjfsdjfisjf9sdfjsd9f', coupon: 'hasbros', + currency: 'USD', discount: 2.5, order_id: '50314b8e9bcf000000000000', products: [ @@ -1976,6 +1981,7 @@ export const data = [ properties: { mergeObjectsUpdateOperation: false, revenue: 50, + currency: 'USD', }, external_id: 'finalUserTestCA', }, @@ -2192,6 +2198,7 @@ export const data = [ properties: { mergeObjectsUpdateOperation: false, revenue: 50, + currency: 'USD', }, external_id: 'finalUserTestCA', }, @@ -3398,6 +3405,7 @@ export const data = [ time: '2020-01-24T11:59:02.403+05:30', properties: { revenue: 50, + currency: 'USD', }, external_id: 'mickeyMouse', app_id: '123', @@ -3985,6 +3993,7 @@ export const data = [ subtotal: 22.5, tax: 2, total: 27.5, + currency: 'USD', }, _update_existing_only: false, user_alias: { @@ -4036,7 +4045,6 @@ export const data = [ Transformations: [], }, message: { - anonymousId: 'e6ab2c5e-2cda-44a9-a962-e2f67df78bca', channel: 'web', context: { traits: { diff --git a/test/integrations/destinations/clevertap/processor/data.ts b/test/integrations/destinations/clevertap/processor/data.ts index 1d7bdd7e78..f15fc409fb 100644 --- a/test/integrations/destinations/clevertap/processor/data.ts +++ b/test/integrations/destinations/clevertap/processor/data.ts @@ -2550,4 +2550,886 @@ export const data = [ }, }, }, + { + name: 'clevertap', + description: 'Test 22: device token type via integrations object takes precedence over os type', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + passcode: 'sample_passcode', + accountId: '476550467', + trackAnonymous: true, + enableObjectIdMapping: true, + }, + }, + message: { + type: 'identify', + event: 'identify', + sentAt: '2021-05-24T08:53:38.762Z', + userId: 'useran4', + channel: 'mobile', + context: { + os: { + name: 'Android', + version: '10', + }, + app: { + name: 'myfirstapp', + build: '1', + version: '1.0', + namespace: 'com.example.myfirstapp', + }, + device: { + id: 'f54bb572361c4fd1', + name: 'whyred', + type: 'Android', + model: 'Redmi Note 5 Pro', + manufacturer: 'Xiaomi', + token: 'frfsgvrwe:APfdsafsgdfsgghfgfgjkhfsfgdhjhbvcvnetry767456fxsasdf', + }, + locale: 'en-IN', + screen: { + width: 1080, + height: 2118, + density: 420, + }, + traits: { + id: 'useran4', + email: 'tony4an@testmail.com', + phone: '4444457700', + userId: 'useran4', + lastname: 'Stark', + firstname: 'Tony4AN', + anonymousId: 'f54bb572361c4fd1', + }, + library: { + name: 'com.rudderstack.android.sdk.core', + version: '1.0.12', + }, + network: { + wifi: true, + carrier: 'airtel', + cellular: true, + bluetooth: false, + }, + timezone: 'Asia/Kolkata', + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 10; Redmi Note 5 Pro Build/QQ3A.200805.001)', + }, + rudderId: 'd8dd4917-bdb2-4c17-8f62-24c79d87a937', + messageId: '1621846417928-7fbb739f-5f96-48ca-9ebb-5bfc4076a687', + anonymousId: 'f54bb572361c4fd1', + integrations: { + All: true, + clevertap: { + deviceTokenType: 'chrome', + }, + }, + originalTimestamp: '2021-05-24T08:53:37.929Z', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'profile', + profileData: { + Email: 'tony4an@testmail.com', + Phone: '4444457700', + Name: 'Tony4AN Stark', + identity: 'useran4', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'token', + tokenData: { + id: 'frfsgvrwe:APfdsafsgdfsgghfgfgjkhfsfgdhjhbvcvnetry767456fxsasdf', + type: 'chrome', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'clevertap', + description: + 'Test 23: device token type via integrations object does not take precedence over os type when the token type is not within the allowed types ', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + passcode: 'sample_passcode', + accountId: '476550467', + trackAnonymous: true, + enableObjectIdMapping: true, + }, + }, + message: { + type: 'identify', + event: 'identify', + sentAt: '2021-05-24T08:53:38.762Z', + userId: 'useran4', + channel: 'mobile', + context: { + os: { + name: 'Android', + version: '10', + }, + app: { + name: 'myfirstapp', + build: '1', + version: '1.0', + namespace: 'com.example.myfirstapp', + }, + device: { + id: 'f54bb572361c4fd1', + name: 'whyred', + type: 'Android', + model: 'Redmi Note 5 Pro', + manufacturer: 'Xiaomi', + token: 'frfsgvrwe:APfdsafsgdfsgghfgfgjkhfsfgdhjhbvcvnetry767456fxsasdf', + }, + locale: 'en-IN', + screen: { + width: 1080, + height: 2118, + density: 420, + }, + traits: { + id: 'useran4', + email: 'tony4an@testmail.com', + phone: '4444457700', + userId: 'useran4', + lastname: 'Stark', + firstname: 'Tony4AN', + anonymousId: 'f54bb572361c4fd1', + }, + library: { + name: 'com.rudderstack.android.sdk.core', + version: '1.0.12', + }, + network: { + wifi: true, + carrier: 'airtel', + cellular: true, + bluetooth: false, + }, + timezone: 'Asia/Kolkata', + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 10; Redmi Note 5 Pro Build/QQ3A.200805.001)', + }, + rudderId: 'd8dd4917-bdb2-4c17-8f62-24c79d87a937', + messageId: '1621846417928-7fbb739f-5f96-48ca-9ebb-5bfc4076a687', + anonymousId: 'f54bb572361c4fd1', + integrations: { + All: true, + clevertap: { + deviceTokenType: 'random', + }, + }, + originalTimestamp: '2021-05-24T08:53:37.929Z', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'profile', + profileData: { + Email: 'tony4an@testmail.com', + Phone: '4444457700', + Name: 'Tony4AN Stark', + identity: 'useran4', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'token', + tokenData: { + id: 'frfsgvrwe:APfdsafsgdfsgghfgfgjkhfsfgdhjhbvcvnetry767456fxsasdf', + type: 'fcm', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'clevertap', + description: 'Test 24: chrome auth keys to be mapped via integrations object', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + passcode: 'sample_passcode', + accountId: '476550467', + trackAnonymous: true, + enableObjectIdMapping: true, + }, + }, + message: { + type: 'identify', + event: 'identify', + sentAt: '2021-05-24T08:53:38.762Z', + userId: 'useran4', + channel: 'mobile', + context: { + os: { name: 'Android', version: '10' }, + app: { + name: 'myfirstapp', + build: '1', + version: '1.0', + namespace: 'com.example.myfirstapp', + }, + device: { + id: 'f54bb572361c4fd1', + name: 'whyred', + type: 'Android', + model: 'Redmi Note 5 Pro', + manufacturer: 'Xiaomi', + token: + 'dR7jSUNlQ_qr_maG7Qd4R-:APA91bEuIZUlyF2Or7FzDp9slk2LTVoUIucV4hL7dvUqJzl6yWAfIFTBaU2uec9broasHAHAvga9ha1tszSEJobuAC-Zbh6l3DoXO4vnSrN4LcllybmGr_lIw5k8CgFoNuvSb8BWEb90', + }, + locale: 'en-IN', + screen: { width: 1080, height: 2118, density: 420 }, + traits: { + id: 'useran4', + email: 'tony4an@testmail.com', + phone: '+919432240789', + userId: 'useran4', + lastname: 'Stark', + firstname: 'Tony4AN', + anonymousId: 'f54bb572361c4fd1', + }, + library: { name: 'com.rudderstack.android.sdk.core', version: '1.0.12' }, + network: { wifi: true, carrier: 'airtel', cellular: true, bluetooth: false }, + timezone: 'Asia/Kolkata', + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 10; Redmi Note 5 Pro Build/QQ3A.200805.001)', + }, + rudderId: 'd8dd4917-bdb2-4c17-8f62-24c79d87a937', + messageId: '1621846417928-7fbb739f-5f96-48ca-9ebb-5bfc4076a687', + anonymousId: 'f54bb572361c4fd1', + integrations: { + All: true, + clevertap: { + deviceTokenType: 'chrome', + chromeKeys: { auth: '5I2Bu2oKdyy9CwL8QVF0NQ==' }, + }, + }, + originalTimestamp: '2021-05-24T08:53:37.929Z', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'profile', + profileData: { + Email: 'tony4an@testmail.com', + Phone: '+919432240789', + Name: 'Tony4AN Stark', + identity: 'useran4', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + { + output: { + version: '1', + type: 'REST', + userId: '', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'token', + tokenData: { + id: 'dR7jSUNlQ_qr_maG7Qd4R-:APA91bEuIZUlyF2Or7FzDp9slk2LTVoUIucV4hL7dvUqJzl6yWAfIFTBaU2uec9broasHAHAvga9ha1tszSEJobuAC-Zbh6l3DoXO4vnSrN4LcllybmGr_lIw5k8CgFoNuvSb8BWEb90', + type: 'chrome', + keys: { + auth: '5I2Bu2oKdyy9CwL8QVF0NQ==', + }, + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'clevertap', + description: + 'Test 25: chrome auth key with only p256dh key to be mapped via integrations object', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + passcode: 'sample_passcode', + accountId: '476550467', + trackAnonymous: true, + enableObjectIdMapping: true, + }, + }, + message: { + type: 'identify', + event: 'identify', + sentAt: '2021-05-24T08:53:38.762Z', + userId: 'useran4', + channel: 'mobile', + context: { + os: { name: 'Android', version: '10' }, + app: { + name: 'myfirstapp', + build: '1', + version: '1.0', + namespace: 'com.example.myfirstapp', + }, + device: { + id: 'f54bb572361c4fd1', + name: 'whyred', + type: 'Android', + model: 'Redmi Note 5 Pro', + manufacturer: 'Xiaomi', + token: + 'dR7jSUNlQ_qr_maG7Qd4R-:APA91bEuIZUlyF2Or7FzDp9slk2LTVoUIucV4hL7dvUqJzl6yWAfIFTBaU2uec9broasHAHAvga9ha1tszSEJobuAC-Zbh6l3DoXO4vnSrN4LcllybmGr_lIw5k8CgFoNuvSb8BWEb90', + }, + locale: 'en-IN', + screen: { width: 1080, height: 2118, density: 420 }, + traits: { + id: 'useran4', + email: 'tony4an@testmail.com', + phone: '+919432240789', + userId: 'useran4', + lastname: 'Stark', + firstname: 'Tony4AN', + anonymousId: 'f54bb572361c4fd1', + }, + library: { name: 'com.rudderstack.android.sdk.core', version: '1.0.12' }, + network: { wifi: true, carrier: 'airtel', cellular: true, bluetooth: false }, + timezone: 'Asia/Kolkata', + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 10; Redmi Note 5 Pro Build/QQ3A.200805.001)', + }, + rudderId: 'd8dd4917-bdb2-4c17-8f62-24c79d87a937', + messageId: '1621846417928-7fbb739f-5f96-48ca-9ebb-5bfc4076a687', + anonymousId: 'f54bb572361c4fd1', + integrations: { + All: true, + clevertap: { + deviceTokenType: 'chrome', + chromeKeys: { + p256dh: + 'BLc4xRzKlKORKWlbdgFaBrrPK3ydWAHo4M0gs0i1oEKgPpWC5cW8OCzVrOQRv-1npXRWk8udnW3oYhIO4475rds=', + }, + }, + }, + originalTimestamp: '2021-05-24T08:53:37.929Z', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'profile', + profileData: { + Email: 'tony4an@testmail.com', + Phone: '+919432240789', + Name: 'Tony4AN Stark', + identity: 'useran4', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + { + output: { + version: '1', + type: 'REST', + userId: '', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'token', + tokenData: { + id: 'dR7jSUNlQ_qr_maG7Qd4R-:APA91bEuIZUlyF2Or7FzDp9slk2LTVoUIucV4hL7dvUqJzl6yWAfIFTBaU2uec9broasHAHAvga9ha1tszSEJobuAC-Zbh6l3DoXO4vnSrN4LcllybmGr_lIw5k8CgFoNuvSb8BWEb90', + type: 'chrome', + keys: { + p256dh: + 'BLc4xRzKlKORKWlbdgFaBrrPK3ydWAHo4M0gs0i1oEKgPpWC5cW8OCzVrOQRv-1npXRWk8udnW3oYhIO4475rds=', + }, + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'clevertap', + description: + 'Test 25: chrome auth key object can have any random field and to be mapped via integrations object', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + passcode: 'sample_passcode', + accountId: '476550467', + trackAnonymous: true, + enableObjectIdMapping: true, + }, + }, + message: { + type: 'identify', + event: 'identify', + sentAt: '2021-05-24T08:53:38.762Z', + userId: 'useran4', + channel: 'mobile', + context: { + os: { name: 'Android', version: '10' }, + app: { + name: 'myfirstapp', + build: '1', + version: '1.0', + namespace: 'com.example.myfirstapp', + }, + device: { + id: 'f54bb572361c4fd1', + name: 'whyred', + type: 'Android', + model: 'Redmi Note 5 Pro', + manufacturer: 'Xiaomi', + token: + 'dR7jSUNlQ_qr_maG7Qd4R-:APA91bEuIZUlyF2Or7FzDp9slk2LTVoUIucV4hL7dvUqJzl6yWAfIFTBaU2uec9broasHAHAvga9ha1tszSEJobuAC-Zbh6l3DoXO4vnSrN4LcllybmGr_lIw5k8CgFoNuvSb8BWEb90', + }, + locale: 'en-IN', + screen: { width: 1080, height: 2118, density: 420 }, + traits: { + id: 'useran4', + email: 'tony4an@testmail.com', + phone: '+919432240789', + userId: 'useran4', + lastname: 'Stark', + firstname: 'Tony4AN', + anonymousId: 'f54bb572361c4fd1', + }, + library: { name: 'com.rudderstack.android.sdk.core', version: '1.0.12' }, + network: { wifi: true, carrier: 'airtel', cellular: true, bluetooth: false }, + timezone: 'Asia/Kolkata', + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 10; Redmi Note 5 Pro Build/QQ3A.200805.001)', + }, + rudderId: 'd8dd4917-bdb2-4c17-8f62-24c79d87a937', + messageId: '1621846417928-7fbb739f-5f96-48ca-9ebb-5bfc4076a687', + anonymousId: 'f54bb572361c4fd1', + integrations: { + All: true, + clevertap: { + deviceTokenType: 'chrome', + chromeKeys: { + random: 'random key', + }, + }, + }, + originalTimestamp: '2021-05-24T08:53:37.929Z', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'profile', + profileData: { + Email: 'tony4an@testmail.com', + Phone: '+919432240789', + Name: 'Tony4AN Stark', + identity: 'useran4', + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + { + output: { + version: '1', + type: 'REST', + userId: '', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + type: 'token', + tokenData: { + id: 'dR7jSUNlQ_qr_maG7Qd4R-:APA91bEuIZUlyF2Or7FzDp9slk2LTVoUIucV4hL7dvUqJzl6yWAfIFTBaU2uec9broasHAHAvga9ha1tszSEJobuAC-Zbh6l3DoXO4vnSrN4LcllybmGr_lIw5k8CgFoNuvSb8BWEb90', + type: 'chrome', + keys: { + random: 'random key', + }, + }, + objectId: 'f54bb572361c4fd1', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'clevertap', + description: 'Should not throw bugsnag error if event is not of type string', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + passcode: 'sample_passcode', + accountId: '476550467', + trackAnonymous: true, + enableObjectIdMapping: false, + }, + }, + message: { + type: 'track', + userId: 'user123', + event: 'Product Purchased', + properties: { + name: "Rubik's Cube", + revenue: 4.99, + }, + context: { + ip: '14.5.67.21', + }, + timestamp: '2020-02-02T00:23:09.544Z', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.clevertap.com/1/upload', + headers: { + 'X-CleverTap-Account-Id': '476550467', + 'X-CleverTap-Passcode': 'sample_passcode', + 'Content-Type': 'application/json', + }, + params: {}, + body: { + JSON: { + d: [ + { + evtName: 'Product Purchased', + evtData: { + name: "Rubik's Cube", + revenue: 4.99, + }, + type: 'event', + identity: 'user123', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/cordial/common.ts b/test/integrations/destinations/cordial/common.ts new file mode 100644 index 0000000000..1ebd0db34b --- /dev/null +++ b/test/integrations/destinations/cordial/common.ts @@ -0,0 +1,90 @@ +import { Destination } from '../../../../src/types'; + +const destType = 'cordial'; +const destTypeInUpperCase = 'CORDIAL'; +const displayName = 'Cordial'; +const destination: Destination = { + Config: { + apiBaseUrl: 'https://abc.example.com', + apiKey: 'test-api-key', + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', +}; +const traits = { + email: 'johndoe@example.com', + first_name: 'John', + last_name: 'Doe', + phone: '1234567890', + address: { + city: 'New York', + country: 'USA', + pin_code: '123456', + }, + subscribeStatus: 'subscribed', +}; +const endpoint = 'https://abc.example.com/v2/contacts'; +const updateContactEmailEndpoint = 'https://abc.example.com/v2/contacts/email:johndoe@example.com'; +const updateContactIdEndpoint = 'https://abc.example.com/v2/contacts/6690fe3655e334d6270287b5'; +const eventsEndpoint = 'https://abc.example.com/v2/contactactivities'; +const context = { + externalId: [ + { + type: 'cordialContactId', + id: '6690fe3655e334d6270287b5', + }, + ], +}; +const headers = { + 'Content-Type': 'application/json', + Authorization: 'Basic dGVzdC1hcGkta2V5Og==', +}; +const properties = { + product_id: '622c6f5d5cf86a4c77358033', + sku: '8472-998-0112', + category: 'Games', + name: 'Cones of Dunshire', + brand: 'Wyatt Games', + variant: 'expansion pack', + price: 49.99, + quantity: 5, + coupon: 'PREORDER15', + currency: 'USD', + position: 1, + url: 'https://www.website.com/product/path', + image_url: 'https://www.website.com/product/path.webp', + key1: 'value1', +}; +const processorInstrumentationErrorStatTags = { + destType: destTypeInUpperCase, + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'cdkV2', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', +}; + +export { + destType, + destination, + traits, + endpoint, + updateContactEmailEndpoint, + updateContactIdEndpoint, + eventsEndpoint, + context, + headers, + properties, + processorInstrumentationErrorStatTags, +}; diff --git a/test/integrations/destinations/cordial/network.ts b/test/integrations/destinations/cordial/network.ts new file mode 100644 index 0000000000..9cc6f42408 --- /dev/null +++ b/test/integrations/destinations/cordial/network.ts @@ -0,0 +1,71 @@ +import { destination } from './common'; +export const networkCallsData = [ + { + httpReq: { + url: `${destination.Config.apiBaseUrl}/v2/contacts/email:johndoe@example.com`, + headers: { + Authorization: 'Basic dGVzdC1hcGkta2V5Og==', + }, + method: 'GET', + }, + httpRes: { + data: { + _id: '6690fe3655e334d6270287b5', + attributes: { + createdAt: '2024-07-12T09:58:14+0000', + address: { + city: 'San Miego', + }, + first_name: 'John', + last_name: 'Doe', + lastUpdateSource: 'api', + lastModified: '2024-07-12T13:00:49+0000', + cID: '6690fe3655e334d6270287b5', + }, + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'subscribed', + subscribedAt: '2024-07-12T09:58:14+0000', + }, + }, + }, + status: 200, + statusText: 'Ok', + }, + }, + { + httpReq: { + url: `${destination.Config.apiBaseUrl}/v2/contacts/6690fe3655e334d6270287b5`, + headers: { + Authorization: 'Basic dGVzdC1hcGkta2V5Og==', + }, + method: 'GET', + }, + httpRes: { + data: { + _id: '6690fe3655e334d6270287b5', + attributes: { + createdAt: '2024-07-12T09:58:14+0000', + address: { + city: 'San Miego', + }, + first_name: 'John', + last_name: 'Doe', + lastUpdateSource: 'api', + lastModified: '2024-07-12T13:00:49+0000', + cID: '6690fe3655e334d6270287b5', + }, + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'subscribed', + subscribedAt: '2024-07-12T09:58:14+0000', + }, + }, + }, + status: 200, + statusText: 'Ok', + }, + }, +]; diff --git a/test/integrations/destinations/cordial/processor/data.ts b/test/integrations/destinations/cordial/processor/data.ts new file mode 100644 index 0000000000..5c89c89a08 --- /dev/null +++ b/test/integrations/destinations/cordial/processor/data.ts @@ -0,0 +1,4 @@ +import { identify } from './identify'; +import { track } from './track'; +import { validation } from './validation'; +export const data = [...identify, ...track, ...validation]; diff --git a/test/integrations/destinations/cordial/processor/identify.ts b/test/integrations/destinations/cordial/processor/identify.ts new file mode 100644 index 0000000000..074852b199 --- /dev/null +++ b/test/integrations/destinations/cordial/processor/identify.ts @@ -0,0 +1,205 @@ +import { ProcessorTestData } from '../../../testTypes'; +import { generateMetadata, transformResultBuilder } from '../../../testUtils'; +import { + destType, + destination, + traits, + headers, + endpoint, + updateContactEmailEndpoint, + updateContactIdEndpoint, + context, +} from '../common'; + +export const identify: ProcessorTestData[] = [ + { + id: 'cordial-identify-test-1', + name: destType, + description: 'Identify call to create contact', + scenario: 'Framework+Business', + successCriteria: 'Response should contain all the mapping and status code should be 200', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'identify', + userId: 'userId123', + anonymousId: 'anonId123', + traits: { ...traits, email: 'abc@example.com' }, + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + userId: '', + endpoint, + headers, + JSON: { + channels: { + email: { + address: 'abc@example.com', + subscribeStatus: 'subscribed', + }, + }, + first_name: 'John', + last_name: 'Doe', + phone: '1234567890', + address: { + city: 'New York', + country: 'USA', + pin_code: '123456', + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'cordial-identify-test-2', + name: destType, + description: 'Identify call to update contact using email', + scenario: 'Framework+Business', + successCriteria: 'Response should contain all the mapping and status code should be 200', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'identify', + userId: 'userId123', + anonymousId: 'anonId123', + traits, + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'PUT', + userId: '', + endpoint: updateContactEmailEndpoint, + headers, + JSON: { + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'subscribed', + }, + }, + first_name: 'John', + last_name: 'Doe', + phone: '1234567890', + address: { + city: 'New York', + country: 'USA', + pin_code: '123456', + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'cordial-identify-test-3', + name: destType, + description: 'Identify call to update contact using contact id', + scenario: 'Framework+Business', + successCriteria: 'Response should contain all the mapping and status code should be 200', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'identify', + userId: 'userId123', + anonymousId: 'anonId123', + traits, + integrations: { + All: true, + }, + context, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'PUT', + userId: '', + endpoint: updateContactIdEndpoint, + headers, + JSON: { + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'subscribed', + }, + }, + first_name: 'John', + last_name: 'Doe', + phone: '1234567890', + address: { + city: 'New York', + country: 'USA', + pin_code: '123456', + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/cordial/processor/track.ts b/test/integrations/destinations/cordial/processor/track.ts new file mode 100644 index 0000000000..3e7a560a52 --- /dev/null +++ b/test/integrations/destinations/cordial/processor/track.ts @@ -0,0 +1,125 @@ +import { ProcessorTestData } from '../../../testTypes'; +import { generateMetadata, transformResultBuilder } from '../../../testUtils'; +import { + destType, + destination, + traits, + headers, + eventsEndpoint, + context, + properties, +} from '../common'; + +export const track: ProcessorTestData[] = [ + { + id: 'cordial-track-test-1', + name: destType, + description: 'Track event with exiting contact using email', + scenario: 'Framework+Business', + successCriteria: 'Response should contain all the mapping and status code should be 200', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'track', + userId: 'userId123', + anonymousId: 'anonId123', + event: 'test event', + properties, + traits, + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + userId: '', + endpoint: eventsEndpoint, + headers, + JSON: { + a: 'test event', + email: 'johndoe@example.com', + ats: '2024-03-04T15:32:56.409Z', + properties, + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'cordial-track-test-2', + name: destType, + description: 'Track event with existing contact using contact id', + scenario: 'Framework+Business', + successCriteria: 'Response should contain all the mapping and status code should be 200', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'track', + userId: 'userId123', + anonymousId: 'anonId123', + event: 'test event', + properties, + traits, + context, + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + userId: '', + endpoint: eventsEndpoint, + headers, + JSON: { + a: 'test event', + cID: '6690fe3655e334d6270287b5', + ats: '2024-03-04T15:32:56.409Z', + properties, + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/cordial/processor/validation.ts b/test/integrations/destinations/cordial/processor/validation.ts new file mode 100644 index 0000000000..61f2e1cbed --- /dev/null +++ b/test/integrations/destinations/cordial/processor/validation.ts @@ -0,0 +1,91 @@ +import { ProcessorTestData } from '../../../testTypes'; +import { generateMetadata } from '../../../testUtils'; +import { destType, destination, processorInstrumentationErrorStatTags } from '../common'; + +export const validation: ProcessorTestData[] = [ + { + id: 'cordial-validation-test-1', + name: destType, + description: 'All of the required fields — cordial contact id, email — are missing.', + scenario: 'Framework', + successCriteria: 'Instrumentation Error', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'identify', + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: + 'Either one of cordial contact id or email is required. Aborting: Workflow: procWorkflow, Step: validateEventPayload, ChildStep: undefined, OriginalError: Either one of cordial contact id or email is required. Aborting', + metadata: generateMetadata(1), + statTags: processorInstrumentationErrorStatTags, + statusCode: 400, + }, + ], + }, + }, + }, + { + id: 'cordial-validation-test-2', + name: destType, + description: 'Unsupported message type -> group', + scenario: 'Framework', + successCriteria: 'Instrumentation Error for Unsupported message type', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'group', + userId: 'userId123', + channel: 'mobile', + anonymousId: 'anon_123', + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: + 'message type group is not supported: Workflow: procWorkflow, Step: validateMessageType, ChildStep: undefined, OriginalError: message type group is not supported', + metadata: generateMetadata(1), + statTags: processorInstrumentationErrorStatTags, + statusCode: 400, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/cordial/router/data.ts b/test/integrations/destinations/cordial/router/data.ts new file mode 100644 index 0000000000..43d366d873 --- /dev/null +++ b/test/integrations/destinations/cordial/router/data.ts @@ -0,0 +1,134 @@ +import { generateMetadata } from '../../../testUtils'; +import { + destType, + destination, + traits, + properties, + headers, + eventsEndpoint, + updateContactEmailEndpoint, +} from '../common'; + +export const data = [ + { + id: 'cordial-router-test-1', + name: destType, + description: 'Basic Router Test to test multiple payloads', + scenario: 'Framework', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + type: 'identify', + userId: 'userId123', + anonymousId: 'anonId123', + traits, + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(1), + destination, + }, + { + message: { + type: 'track', + userId: 'userId123', + anonymousId: 'anonId123', + event: 'test event', + properties, + traits, + integrations: { + All: true, + }, + originalTimestamp: '2024-03-04T15:32:56.409Z', + }, + metadata: generateMetadata(2), + destination, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + body: { + XML: {}, + JSON_ARRAY: {}, + JSON: { + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'subscribed', + }, + }, + first_name: 'John', + last_name: 'Doe', + phone: '1234567890', + address: { + city: 'New York', + country: 'USA', + pin_code: '123456', + }, + }, + FORM: {}, + }, + files: {}, + endpoint: updateContactEmailEndpoint, + headers, + version: '1', + params: {}, + type: 'REST', + method: 'PUT', + }, + metadata: [generateMetadata(1)], + batched: false, + statusCode: 200, + destination, + }, + { + batchedRequest: { + body: { + XML: {}, + JSON_ARRAY: {}, + JSON: { + a: 'test event', + email: 'johndoe@example.com', + ats: '2024-03-04T15:32:56.409Z', + properties, + }, + FORM: {}, + }, + files: {}, + endpoint: eventsEndpoint, + headers, + version: '1', + params: {}, + type: 'REST', + method: 'POST', + }, + metadata: [generateMetadata(2)], + batched: false, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/customerio/processor/data.ts b/test/integrations/destinations/customerio/processor/data.ts index 5bbbfe7b10..92cea4250d 100644 --- a/test/integrations/destinations/customerio/processor/data.ts +++ b/test/integrations/destinations/customerio/processor/data.ts @@ -8275,4 +8275,58 @@ export const data = [ }, }, }, + { + name: 'customerio', + description: 'Test 66 -> Invalid Page call', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + channel: 'web', + context: { + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36', + locale: 'en-US', + }, + type: 'page', + anonymousId: 'c82cbdff-e5be-4009-ac78-cdeea09ab4b1', + integrations: { + All: true, + }, + }, + destination: { + Config: { + datacenter: 'US', + siteID: '46be54768e7d49ab2628', + apiKey: 'dummyApiKey', + }, + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Event Name type should be a string', + statTags: { + destType: 'CUSTOMERIO', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'native', + module: 'destination', + }, + statusCode: 400, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/emarsys/deleteUsers/data.ts b/test/integrations/destinations/emarsys/deleteUsers/data.ts index 2bafe58a4c..96b27cad0d 100644 --- a/test/integrations/destinations/emarsys/deleteUsers/data.ts +++ b/test/integrations/destinations/emarsys/deleteUsers/data.ts @@ -1,10 +1,10 @@ +import crypto from 'crypto'; + +const buf = Buffer.from('5398e214ae99c2e50afb709a3bc423f9', 'hex'); export const mockFns = (_) => { + jest.spyOn(Date.prototype, 'toISOString').mockReturnValueOnce('2023-10-14T00:00:00.000Z'); // @ts-ignore - jest.useFakeTimers().setSystemTime(new Date('2023-10-14')); - jest.mock('crypto', () => ({ - ...jest.requireActual('crypto'), - randomBytes: jest.fn().mockReturnValue(Buffer.from('5398e214ae99c2e50afb709a3bc423f9', 'hex')), - })); + jest.spyOn(crypto, 'randomBytes').mockReturnValue(buf); }; const commonEventMap = [ diff --git a/test/integrations/destinations/emarsys/processor/data.ts b/test/integrations/destinations/emarsys/processor/data.ts index cfa53fd4f6..badd14e7cc 100644 --- a/test/integrations/destinations/emarsys/processor/data.ts +++ b/test/integrations/destinations/emarsys/processor/data.ts @@ -1,10 +1,12 @@ +import crypto from 'crypto'; + +const buf = Buffer.from('5398e214ae99c2e50afb709a3bc423f9', 'hex'); + export const mockFns = (_) => { // @ts-ignore - jest.useFakeTimers().setSystemTime(new Date('2023-10-14')); - jest.mock('crypto', () => ({ - ...jest.requireActual('crypto'), - randomBytes: jest.fn().mockReturnValue(Buffer.from('5398e214ae99c2e50afb709a3bc423f9', 'hex')), - })); + jest.spyOn(Date.prototype, 'toISOString').mockReturnValueOnce('2023-10-14T00:00:00.000Z'); + // @ts-ignore + jest.spyOn(crypto, 'randomBytes').mockReturnValue(buf); }; const comonHeader = { diff --git a/test/integrations/destinations/emarsys/router/data.ts b/test/integrations/destinations/emarsys/router/data.ts index 8f449bd351..5f6dad1077 100644 --- a/test/integrations/destinations/emarsys/router/data.ts +++ b/test/integrations/destinations/emarsys/router/data.ts @@ -53,13 +53,13 @@ const commonDestination = { Enabled: true, }; +const buf = Buffer.from('5398e214ae99c2e50afb709a3bc423f9', 'hex'); + export const mockFns = (_) => { // @ts-ignore - jest.useFakeTimers().setSystemTime(new Date('2019-10-14')); - jest.mock('crypto', () => ({ - ...jest.requireActual('crypto'), - randomBytes: jest.fn().mockReturnValue(Buffer.from('5398e214ae99c2e50afb709a3bc423f9', 'hex')), - })); + jest.spyOn(Date.prototype, 'toISOString').mockReturnValueOnce('2019-10-14T00:00:00.000Z'); + // @ts-ignore + jest.spyOn(crypto, 'randomBytes').mockReturnValue(buf); }; export const data = [ diff --git a/test/integrations/destinations/facebook_conversions/mocks.ts b/test/integrations/destinations/facebook_conversions/mocks.ts index c155897bc4..ea2c8f8205 100644 --- a/test/integrations/destinations/facebook_conversions/mocks.ts +++ b/test/integrations/destinations/facebook_conversions/mocks.ts @@ -1,3 +1,3 @@ export const defaultMockFns = () => { - jest.spyOn(Date, 'now').mockImplementation(() => new Date('2023-11-12T15:46:51.000Z').valueOf()); + jest.spyOn(Date, 'now').mockReturnValue(new Date('2023-11-12T15:46:51.000Z').valueOf()); }; diff --git a/test/integrations/destinations/facebook_conversions/processor/data.ts b/test/integrations/destinations/facebook_conversions/processor/data.ts index 3224a15771..d72114c15b 100644 --- a/test/integrations/destinations/facebook_conversions/processor/data.ts +++ b/test/integrations/destinations/facebook_conversions/processor/data.ts @@ -314,7 +314,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -433,7 +433,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -552,7 +552,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -671,7 +671,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -797,7 +797,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -917,7 +917,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -1036,7 +1036,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -1155,7 +1155,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -1283,7 +1283,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -1411,7 +1411,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -1511,7 +1511,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -1632,7 +1632,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { diff --git a/test/integrations/destinations/facebook_conversions/router/data.ts b/test/integrations/destinations/facebook_conversions/router/data.ts index 9c6759df61..5a9c0c513f 100644 --- a/test/integrations/destinations/facebook_conversions/router/data.ts +++ b/test/integrations/destinations/facebook_conversions/router/data.ts @@ -112,7 +112,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { @@ -150,7 +150,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyID/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyID/events?access_token=09876', headers: {}, params: {}, body: { diff --git a/test/integrations/destinations/facebook_pixel/processor/ecommTestData.ts b/test/integrations/destinations/facebook_pixel/processor/ecommTestData.ts index 5d429d297d..8e7f50ec2d 100644 --- a/test/integrations/destinations/facebook_pixel/processor/ecommTestData.ts +++ b/test/integrations/destinations/facebook_pixel/processor/ecommTestData.ts @@ -218,7 +218,7 @@ export const ecommTestData: ProcessorTestData[] = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyPixelId/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyPixelId/events?access_token=09876', headers: {}, params: {}, FORM: { @@ -572,7 +572,7 @@ export const ecommTestData: ProcessorTestData[] = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyPixelId/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyPixelId/events?access_token=09876', headers: {}, params: {}, FORM: { @@ -890,7 +890,7 @@ export const ecommTestData: ProcessorTestData[] = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyPixelId/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyPixelId/events?access_token=09876', headers: {}, params: {}, FORM: { diff --git a/test/integrations/destinations/facebook_pixel/processor/validationTestData.ts b/test/integrations/destinations/facebook_pixel/processor/validationTestData.ts index a0f85e45e3..d242ac990d 100644 --- a/test/integrations/destinations/facebook_pixel/processor/validationTestData.ts +++ b/test/integrations/destinations/facebook_pixel/processor/validationTestData.ts @@ -444,7 +444,7 @@ export const validationTestData = [ JSON_ARRAY: {}, XML: {}, }, - endpoint: 'https://graph.facebook.com/v18.0/dummyPixelId/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyPixelId/events?access_token=09876', files: {}, headers: {}, method: 'POST', diff --git a/test/integrations/destinations/facebook_pixel/router/data.ts b/test/integrations/destinations/facebook_pixel/router/data.ts index c754ffdc61..f3df4506a5 100644 --- a/test/integrations/destinations/facebook_pixel/router/data.ts +++ b/test/integrations/destinations/facebook_pixel/router/data.ts @@ -126,7 +126,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyPixelId/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyPixelId/events?access_token=09876', headers: {}, params: {}, body: { @@ -165,7 +165,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/dummyPixelId/events?access_token=09876', + endpoint: 'https://graph.facebook.com/v20.0/dummyPixelId/events?access_token=09876', headers: {}, params: {}, body: { diff --git a/test/integrations/destinations/fb_custom_audience/router/data.ts b/test/integrations/destinations/fb_custom_audience/router/data.ts index 72438e74b0..ab9bfee973 100644 --- a/test/integrations/destinations/fb_custom_audience/router/data.ts +++ b/test/integrations/destinations/fb_custom_audience/router/data.ts @@ -28,7 +28,7 @@ export const data = [ version: '1', type: 'REST', method: 'DELETE', - endpoint: 'https://graph.facebook.com/v18.0/aud1/users', + endpoint: 'https://graph.facebook.com/v20.0/aud1/users', headers: {}, params: { access_token: 'ABC', @@ -79,7 +79,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/aud1/users', + endpoint: 'https://graph.facebook.com/v20.0/aud1/users', headers: {}, params: { access_token: 'ABC', @@ -187,7 +187,7 @@ export const data = [ version: '1', type: 'REST', method: 'DELETE', - endpoint: 'https://graph.facebook.com/v18.0/aud1/users', + endpoint: 'https://graph.facebook.com/v20.0/aud1/users', headers: {}, params: { access_token: 'ABC', @@ -238,7 +238,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/aud1/users', + endpoint: 'https://graph.facebook.com/v20.0/aud1/users', headers: {}, params: { access_token: 'ABC', @@ -369,7 +369,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', @@ -558,7 +558,7 @@ export const data = [ version: '1', type: 'REST', method: 'DELETE', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', @@ -647,7 +647,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', @@ -720,7 +720,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', @@ -877,7 +877,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', @@ -907,7 +907,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://graph.facebook.com/v18.0/23848494844100489/users', + endpoint: 'https://graph.facebook.com/v20.0/23848494844100489/users', headers: {}, params: { access_token: 'ABC', diff --git a/test/integrations/destinations/ga4/mocks.ts b/test/integrations/destinations/ga4/mocks.ts index 3a27349ff7..19bb0c8ff4 100644 --- a/test/integrations/destinations/ga4/mocks.ts +++ b/test/integrations/destinations/ga4/mocks.ts @@ -1,5 +1,3 @@ -export const defaultMockFns = () => { - return jest - .spyOn(Date, 'now') - .mockImplementation(() => new Date('2022-04-29T05:17:09Z').valueOf()); +export const defaultMockFns = (_) => { + return jest.spyOn(Date, 'now').mockReturnValueOnce(new Date('2022-04-29T05:17:09Z').valueOf()); }; diff --git a/test/integrations/destinations/ga4/processor/validationTestData.ts b/test/integrations/destinations/ga4/processor/validationTestData.ts index 4e5d09bfcf..0030ee178e 100644 --- a/test/integrations/destinations/ga4/processor/validationTestData.ts +++ b/test/integrations/destinations/ga4/processor/validationTestData.ts @@ -151,6 +151,7 @@ export const validationTestData: ProcessorTestData[] = [ ], }, }, + // @ts-ignore mockFns: defaultMockFns, }, { @@ -208,7 +209,11 @@ export const validationTestData: ProcessorTestData[] = [ ], }, }, - mockFns: defaultMockFns, + mockFns: (_) => { + return jest + .spyOn(Date, 'now') + .mockReturnValueOnce(new Date('2012-04-29T05:17:09Z').valueOf()); + }, }, { id: 'ga4-validation-test-3', @@ -756,6 +761,11 @@ export const validationTestData: ProcessorTestData[] = [ ], }, }, + mockFns: (_) => { + return jest + .spyOn(Date, 'now') + .mockReturnValueOnce(new Date('2023-04-29T05:17:09Z').valueOf()); + }, }, { id: 'ga4-validation-test-14', @@ -801,6 +811,11 @@ export const validationTestData: ProcessorTestData[] = [ ], }, }, + mockFns: (_) => { + return jest + .spyOn(Date, 'now') + .mockReturnValueOnce(new Date('2021-04-29T05:17:09Z').valueOf()); + }, }, { id: 'ga4-validation-test-15', diff --git a/test/integrations/destinations/ga4_v2/mocks.ts b/test/integrations/destinations/ga4_v2/mocks.ts index 3a27349ff7..e7f5e144eb 100644 --- a/test/integrations/destinations/ga4_v2/mocks.ts +++ b/test/integrations/destinations/ga4_v2/mocks.ts @@ -1,5 +1,3 @@ export const defaultMockFns = () => { - return jest - .spyOn(Date, 'now') - .mockImplementation(() => new Date('2022-04-29T05:17:09Z').valueOf()); + return jest.spyOn(Date, 'now').mockReturnValue(new Date('2022-04-29T05:17:09Z').valueOf()); }; diff --git a/test/integrations/destinations/ga4_v2/processor/customMappings.ts b/test/integrations/destinations/ga4_v2/processor/customMappings.ts index b1db2121ea..28e8c5a5b4 100644 --- a/test/integrations/destinations/ga4_v2/processor/customMappings.ts +++ b/test/integrations/destinations/ga4_v2/processor/customMappings.ts @@ -1,3 +1,5 @@ +import { Destination } from '../../../../../src/types'; +import { overrideDestination } from '../../../testUtils'; import { defaultMockFns } from '../mocks'; const traits = { @@ -65,7 +67,10 @@ const properties = { }; const integrations = { - GA4: { + 'Google Analytics 4 (GA4) V2': { + clientId: '6d374e5d-78d3-4169-991d-2573ec0d1c67', + sessionId: '123', + sessionNumber: 3, consents: { ad_personalization: 'GRANTED', ad_user_data: 'DENIED', @@ -212,7 +217,7 @@ const eventsMapping = [ }, ]; -const destination = { +const destination: Destination = { Config: { apiSecret: 'dummyApiSecret', measurementId: 'G-T40PE6KET4', @@ -224,6 +229,19 @@ const destination = { eventFilteringOption: 'disable', eventsMapping, }, + ID: 'ga4_v2', + Name: 'Google Analytics 4', + Enabled: true, + WorkspaceID: '123', + DestinationDefinition: { + ID: '123', + Name: 'Google Analytics 4', + DisplayName: 'Google Analytics 4', + Config: {}, + }, + IsProcessorEnabled: true, + Transformations: [], + IsConnectionEnabled: true, }; export const customMappingTestCases = [ { @@ -297,6 +315,7 @@ export const customMappingTestCases = [ }, ], prices: 456, + session_number: 3, }, }, ], @@ -398,6 +417,7 @@ export const customMappingTestCases = [ }, ], prices: 456, + session_number: 3, }, }, ], @@ -461,6 +481,7 @@ export const customMappingTestCases = [ }, ], prices: 456, + session_number: 3, }, }, ], @@ -540,6 +561,7 @@ export const customMappingTestCases = [ }, body: { JSON: { + client_id: 'root_anonId', user_id: 'root_user', timestamp_micros: 1651105389000000, non_personalized_ads: false, @@ -594,6 +616,7 @@ export const customMappingTestCases = [ products_1_item_category2: 'regulars', products_1_item_category3: 'grocery', products_1_some_data: 'someValue', + session_number: 3, }, }, ], @@ -668,6 +691,111 @@ export const customMappingTestCases = [ timestamp_micros: 1651105389000000, non_personalized_ads: false, client_id: 'root_anonId', + events: [ + { + name: 'join_group', + params: { + city: 'London', + engagement_time_msec: 1, + firstName: 'John', + group: 'test group', + lastName: 'Gomes', + session_number: 3, + state: 'UK', + streetAddress: '71 Cherry Court SOUTHAMPTON SO53 5PD UK', + }, + }, + ], + user_properties: { + firstName: { + value: 'John', + }, + lastName: { + value: 'Gomes', + }, + city: { + value: 'London', + }, + state: { + value: 'UK', + }, + group: { + value: 'test group', + }, + }, + consent: { + ad_user_data: 'DENIED', + ad_personalization: 'GRANTED', + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + ], + }, + }, + mockFns: defaultMockFns, + }, + { + name: 'ga4_v2', + id: 'ga4_custom_mapping_test_4', + description: 'Custom Mapping Test For Hybrid mode', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + type: 'group', + userId: 'root_user', + anonymousId: 'root_anonId', + context: { + device, + traits, + }, + properties, + originalTimestamp: '2022-04-28T00:23:09.544Z', + integrations, + }, + destination: overrideDestination(destination, { + connectionMode: 'hybrid', + }), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.google-analytics.com/mp/collect', + headers: { + HOST: 'www.google-analytics.com', + 'Content-Type': 'application/json', + }, + params: { + api_secret: 'dummyApiSecret', + measurement_id: 'G-T40PE6KET4', + }, + body: { + JSON: { + user_id: 'root_user', + timestamp_micros: 1651105389000000, + non_personalized_ads: false, + client_id: '6d374e5d-78d3-4169-991d-2573ec0d1c67', events: [ { name: 'join_group', @@ -679,6 +807,8 @@ export const customMappingTestCases = [ lastName: 'Gomes', state: 'UK', streetAddress: '71 Cherry Court SOUTHAMPTON SO53 5PD UK', + session_id: '123', + session_number: 3, }, }, ], diff --git a/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/business.ts b/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/business.ts index 0cee1418e1..d318066e7d 100644 --- a/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/business.ts +++ b/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/business.ts @@ -4,6 +4,7 @@ import { generateProxyV1Payload, } from '../../../testUtils'; import { ProxyV1TestData } from '../../../testTypes'; +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_enhanced_conversions/config'; const headers = { Authorization: 'Bearer abcd1234', @@ -82,8 +83,7 @@ export const testScenariosForV0API = [ request: { body: generateProxyV0Payload({ ...commonRequestParameters, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567899:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567899:uploadConversionAdjustments`, }), method: 'POST', }, @@ -138,8 +138,7 @@ export const testScenariosForV0API = [ customerId: '1234567888', destination: 'google_adwords_enhanced_conversions', }, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567888:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567888:uploadConversionAdjustments`, }), method: 'POST', }, @@ -177,7 +176,7 @@ export const testScenariosForV0API = [ 'Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]', }, message: - '[Google Adwords Enhanced Conversions]:: partialFailureError - {"code":3,"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]","details":[{"@type":"type.googleapis.com/google.ads.googleads.v15.errors.GoogleAdsFailure","errors":[{"errorCode":{"conversionAdjustmentUploadError":"CONVERSION_ALREADY_ENHANCED"},"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again.","location":{"fieldPathElements":[{"fieldName":"conversion_adjustments","index":0}]}}]}]}', + '{"code":3,"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]","details":[{"@type":"type.googleapis.com/google.ads.googleads.v15.errors.GoogleAdsFailure","errors":[{"errorCode":{"conversionAdjustmentUploadError":"CONVERSION_ALREADY_ENHANCED"},"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again.","location":{"fieldPathElements":[{"fieldName":"conversion_adjustments","index":0}]}}]}]}', statTags: expectedStatTags, status: 400, }, @@ -203,8 +202,7 @@ export const testScenariosForV1API: ProxyV1TestData[] = [ body: generateProxyV1Payload( { ...commonRequestParameters, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567899:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567899:uploadConversionAdjustments`, }, [generateMetadata(1)], ), @@ -251,8 +249,7 @@ export const testScenariosForV1API: ProxyV1TestData[] = [ customerId: '1234567888', destination: 'google_adwords_enhanced_conversions', }, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567888:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567888:uploadConversionAdjustments`, }, [generateMetadata(1)], ), @@ -265,11 +262,11 @@ export const testScenariosForV1API: ProxyV1TestData[] = [ body: { output: { message: - '[Google Adwords Enhanced Conversions]:: partialFailureError - {"code":3,"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]","details":[{"@type":"type.googleapis.com/google.ads.googleads.v15.errors.GoogleAdsFailure","errors":[{"errorCode":{"conversionAdjustmentUploadError":"CONVERSION_ALREADY_ENHANCED"},"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again.","location":{"fieldPathElements":[{"fieldName":"conversion_adjustments","index":0}]}}]}]}', + '{"code":3,"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]","details":[{"@type":"type.googleapis.com/google.ads.googleads.v15.errors.GoogleAdsFailure","errors":[{"errorCode":{"conversionAdjustmentUploadError":"CONVERSION_ALREADY_ENHANCED"},"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again.","location":{"fieldPathElements":[{"fieldName":"conversion_adjustments","index":0}]}}]}]}', response: [ { error: - '[Google Adwords Enhanced Conversions]:: partialFailureError - {"code":3,"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]","details":[{"@type":"type.googleapis.com/google.ads.googleads.v15.errors.GoogleAdsFailure","errors":[{"errorCode":{"conversionAdjustmentUploadError":"CONVERSION_ALREADY_ENHANCED"},"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again.","location":{"fieldPathElements":[{"fieldName":"conversion_adjustments","index":0}]}}]}]}', + '{"code":3,"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again., at conversion_adjustments[0]","details":[{"@type":"type.googleapis.com/google.ads.googleads.v15.errors.GoogleAdsFailure","errors":[{"errorCode":{"conversionAdjustmentUploadError":"CONVERSION_ALREADY_ENHANCED"},"message":"Conversion already has enhancements with the same Order ID and conversion action. Make sure your data is correctly configured and try again.","location":{"fieldPathElements":[{"fieldName":"conversion_adjustments","index":0}]}}]}]}', metadata: generateMetadata(1), statusCode: 400, }, diff --git a/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/oauth.ts b/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/oauth.ts index 70d9eeaf33..c6e29925dd 100644 --- a/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/oauth.ts +++ b/test/integrations/destinations/google_adwords_enhanced_conversions/dataDelivery/oauth.ts @@ -1,4 +1,4 @@ -import { ProxyV1TestData } from '../../../testTypes'; +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_enhanced_conversions/config'; import { generateProxyV1Payload, generateProxyV0Payload, @@ -83,8 +83,7 @@ export const v0oauthScenarios = [ request: { body: generateProxyV0Payload({ ...commonRequestParameters, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, }), method: 'POST', }, @@ -137,8 +136,7 @@ export const v0oauthScenarios = [ customerId: '1234567910', destination: 'google_adwords_enhanced_conversions', }, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567910/googleAds:searchStream', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567910/googleAds:searchStream`, }), method: 'POST', }, @@ -192,8 +190,7 @@ export const v1oauthScenarios = [ request: { body: generateProxyV1Payload({ ...commonRequestParameters, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, }), method: 'POST', }, @@ -244,8 +241,7 @@ export const v1oauthScenarios = [ customerId: '1234567910', destination: 'google_adwords_enhanced_conversions', }, - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567910/googleAds:searchStream', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567910/googleAds:searchStream`, }), method: 'POST', }, diff --git a/test/integrations/destinations/google_adwords_enhanced_conversions/network.ts b/test/integrations/destinations/google_adwords_enhanced_conversions/network.ts index 69b3a6103a..270ec2dc77 100644 --- a/test/integrations/destinations/google_adwords_enhanced_conversions/network.ts +++ b/test/integrations/destinations/google_adwords_enhanced_conversions/network.ts @@ -1,7 +1,8 @@ +import { API_VERSION } from '../../../../src/v0/destinations/google_adwords_enhanced_conversions/config'; export const networkCallsData = [ { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567890/googleAds:searchStream', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890/googleAds:searchStream`, data: { query: `SELECT conversion_action.id FROM conversion_action WHERE conversion_action.name = 'Product Added'`, }, @@ -29,7 +30,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567899/googleAds:searchStream', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567899/googleAds:searchStream`, data: { query: `SELECT conversion_action.id FROM conversion_action WHERE conversion_action.name = 'Product Added'`, }, @@ -59,7 +60,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567899:uploadConversionAdjustments', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567899:uploadConversionAdjustments`, data: { conversionAdjustments: [ { @@ -123,7 +124,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567891/googleAds:searchStream', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567891/googleAds:searchStream`, data: { query: `SELECT conversion_action.id FROM conversion_action WHERE conversion_action.name = 'Product Added'`, }, @@ -153,7 +154,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567891:uploadConversionAdjustments', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567891:uploadConversionAdjustments`, data: { conversionAdjustments: [ { @@ -214,7 +215,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567891:uploadClickConversions', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567891:uploadClickConversions`, data: { conversionAdjustments: [ { @@ -275,7 +276,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567888/googleAds:searchStream', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567888/googleAds:searchStream`, data: { query: `SELECT conversion_action.id FROM conversion_action WHERE conversion_action.name = 'Product Added'`, }, @@ -305,7 +306,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567888:uploadConversionAdjustments', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567888:uploadConversionAdjustments`, data: { conversionAdjustments: [ { @@ -382,7 +383,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/1234567910/googleAds:searchStream', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567910/googleAds:searchStream`, data: { query: `SELECT conversion_action.id FROM conversion_action WHERE conversion_action.name = 'Product Added'`, }, diff --git a/test/integrations/destinations/google_adwords_enhanced_conversions/processor/data.ts b/test/integrations/destinations/google_adwords_enhanced_conversions/processor/data.ts index 13b2609bf8..40d8370fcb 100644 --- a/test/integrations/destinations/google_adwords_enhanced_conversions/processor/data.ts +++ b/test/integrations/destinations/google_adwords_enhanced_conversions/processor/data.ts @@ -1,3 +1,4 @@ +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_enhanced_conversions/config'; export const data = [ { name: 'google_adwords_enhanced_conversions', @@ -128,8 +129,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, headers: { Authorization: 'Bearer abcd1234', 'Content-Type': 'application/json', @@ -616,8 +616,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, headers: { Authorization: 'Bearer abcd1234', 'Content-Type': 'application/json', @@ -1328,8 +1327,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, headers: { Authorization: 'Bearer abcd1234', 'Content-Type': 'application/json', @@ -1519,8 +1517,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, headers: { Authorization: 'Bearer abcd1234', 'Content-Type': 'application/json', diff --git a/test/integrations/destinations/google_adwords_enhanced_conversions/router/data.ts b/test/integrations/destinations/google_adwords_enhanced_conversions/router/data.ts index dff0f772d3..1d77b5d774 100644 --- a/test/integrations/destinations/google_adwords_enhanced_conversions/router/data.ts +++ b/test/integrations/destinations/google_adwords_enhanced_conversions/router/data.ts @@ -1,3 +1,5 @@ +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_enhanced_conversions/config'; + const events = [ { metadata: { @@ -357,8 +359,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v15/customers/1234567890:uploadConversionAdjustments', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/1234567890:uploadConversionAdjustments`, headers: { Authorization: 'Bearer abcd1234', 'Content-Type': 'application/json', diff --git a/test/integrations/destinations/google_adwords_offline_conversions/dataDelivery/oauth.ts b/test/integrations/destinations/google_adwords_offline_conversions/dataDelivery/oauth.ts index e14e4109f0..4437ebb912 100644 --- a/test/integrations/destinations/google_adwords_offline_conversions/dataDelivery/oauth.ts +++ b/test/integrations/destinations/google_adwords_offline_conversions/dataDelivery/oauth.ts @@ -260,4 +260,148 @@ export const v1oauthScenarios = [ }, }, }, + { + id: 'gaoc_v1_oauth_scenario_3', + name: 'google_adwords_offline_conversions', + description: + "[Proxy v1 API] :: Oauth when the user doesn't enabled 2 factor authentication but the google ads account has it enabled", + successCriteria: 'The proxy should return 401 with authErrorCategory as AUTH_STATUS_INACTIVE', + scenario: 'Oauth', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + ...commonRequestParameters, + headers: { + Authorization: 'Bearer invalidabcd1234', + 'Content-Type': 'application/json', + 'developer-token': 'ijkl91011', + 'login-customer-id': 'logincustomerid', + }, + endpoint: + 'https://googleads.googleapis.com/v16/customers/customerid/offlineUserDataJobs', + }, + metadataArray, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'AUTH_STATUS_INACTIVE', + message: + '[Google Ads Offline Conversions]:: Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project. during google_ads_offline_store_conversions Job Creation', + response: [ + { + error: + '[Google Ads Offline Conversions]:: Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project. during google_ads_offline_store_conversions Job Creation', + metadata: { + attemptNum: 1, + destinationId: 'default-destinationId', + dontBatch: false, + jobId: 1, + secret: { + accessToken: 'default-accessToken', + }, + sourceId: 'default-sourceId', + userId: 'default-userId', + workspaceId: 'default-workspaceId', + }, + statusCode: 401, + }, + ], + statTags: { + destType: 'GOOGLE_ADWORDS_OFFLINE_CONVERSIONS', + destinationId: 'default-destinationId', + errorCategory: 'network', + errorType: 'aborted', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', + workspaceId: 'default-workspaceId', + }, + status: 401, + }, + }, + }, + }, + }, + { + id: 'gaoc_v1_oauth_scenario_4', + name: 'google_adwords_offline_conversions', + description: + "[Proxy v1 API] :: Oauth when the user doesn't enabled 2 factor authentication but the google ads account has it enabled for not store sales conversion", + successCriteria: 'The proxy should return 401 with authErrorCategory as AUTH_STATUS_INACTIVE', + scenario: 'Oauth', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + ...{ ...commonRequestParameters, JSON: { isStoreConversion: false } }, + headers: { + Authorization: 'Bearer invalidabcd1234', + 'Content-Type': 'application/json', + 'developer-token': 'ijkl91011', + 'login-customer-id': 'logincustomerid', + }, + endpoint: + 'https://googleads.googleapis.com/v16/customers/customerid/offlineUserDataJobs', + }, + metadataArray, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'AUTH_STATUS_INACTIVE', + message: + '[Google Ads Offline Conversions]:: [{"error":{"code":401,"details":[{"@type":"type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure","errors":[{"errorCode":{"authenticationError":"TWO_STEP_VERIFICATION_NOT_ENROLLED"},"message":"An account administrator changed this account\'s authentication settings. To access this Google Ads account, enable 2-Step Verification in your Google account at https://www.google.com/landing/2step."}],"requestId":"wy4ZYbsjWcgh6uC2Ruc_Zg"}],"message":"Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED"}}] during google_ads_offline_conversions response transformation', + response: [ + { + error: + '[Google Ads Offline Conversions]:: [{"error":{"code":401,"details":[{"@type":"type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure","errors":[{"errorCode":{"authenticationError":"TWO_STEP_VERIFICATION_NOT_ENROLLED"},"message":"An account administrator changed this account\'s authentication settings. To access this Google Ads account, enable 2-Step Verification in your Google account at https://www.google.com/landing/2step."}],"requestId":"wy4ZYbsjWcgh6uC2Ruc_Zg"}],"message":"Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED"}}] during google_ads_offline_conversions response transformation', + metadata: { + attemptNum: 1, + destinationId: 'default-destinationId', + dontBatch: false, + jobId: 1, + secret: { + accessToken: 'default-accessToken', + }, + sourceId: 'default-sourceId', + userId: 'default-userId', + workspaceId: 'default-workspaceId', + }, + statusCode: 401, + }, + ], + statTags: { + destType: 'GOOGLE_ADWORDS_OFFLINE_CONVERSIONS', + destinationId: 'default-destinationId', + errorCategory: 'network', + errorType: 'aborted', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', + workspaceId: 'default-workspaceId', + }, + status: 401, + }, + }, + }, + }, + }, ]; diff --git a/test/integrations/destinations/google_adwords_offline_conversions/network.ts b/test/integrations/destinations/google_adwords_offline_conversions/network.ts index 4dad9e0d1b..0ab6bef1db 100644 --- a/test/integrations/destinations/google_adwords_offline_conversions/network.ts +++ b/test/integrations/destinations/google_adwords_offline_conversions/network.ts @@ -1,3 +1,32 @@ +const commonResponse = { + status: 401, + data: [ + { + error: { + code: 401, + details: [ + { + '@type': 'type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure', + errors: [ + { + errorCode: { + authenticationError: 'TWO_STEP_VERIFICATION_NOT_ENROLLED', + }, + message: + "An account administrator changed this account's authentication settings. To access this Google Ads account, enable 2-Step Verification in your Google account at https://www.google.com/landing/2step.", + }, + ], + requestId: 'wy4ZYbsjWcgh6uC2Ruc_Zg', + }, + ], + message: + 'Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.', + status: 'UNAUTHENTICATED', + }, + }, + ], +}; + export const networkCallsData = [ { httpReq: { @@ -645,4 +674,49 @@ export const networkCallsData = [ }, }, }, + { + description: + 'Mock response from destination depicting a request from user who has not enabled 2 factor authentication', + httpReq: { + url: 'https://googleads.googleapis.com/v16/customers/customerid/offlineUserDataJobs:create', + data: { + job: { + storeSalesMetadata: { + custom_key: 'CUSTOM_KEY', + loyaltyFraction: 1, + transaction_upload_fraction: '1', + }, + type: 'STORE_SALES_UPLOAD_FIRST_PARTY', + }, + }, + params: { destination: 'google_adwords_offline_conversion' }, + headers: { + Authorization: 'Bearer invalidabcd1234', + 'Content-Type': 'application/json', + 'developer-token': 'ijkl91011', + 'login-customer-id': 'logincustomerid', + }, + method: 'POST', + }, + httpRes: commonResponse, + }, + { + description: + 'Mock response from destination depicting a request from user who has not enabled 2 factor authentication', + httpReq: { + url: 'https://googleads.googleapis.com/v16/customers/1112223333/googleAds:searchStream', + data: { + query: + "SELECT conversion_action.id FROM conversion_action WHERE conversion_action.name = 'Sign-up - click'", + }, + headers: { + Authorization: 'Bearer invalidabcd1234', + 'Content-Type': 'application/json', + 'developer-token': 'ijkl91011', + 'login-customer-id': 'logincustomerid', + }, + method: 'POST', + }, + httpRes: commonResponse, + }, ]; diff --git a/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/business.ts b/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/business.ts index a036da149d..9fea895a9f 100644 --- a/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/business.ts +++ b/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/business.ts @@ -4,20 +4,22 @@ import { generateProxyV1Payload, } from '../../../testUtils'; -const commonHeaders = { +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_remarketing_lists/config'; + +export const commonHeaders = { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', 'developer-token': 'dummy-dev-token', }; -const commonParams = { +export const commonParams = { destination: 'google_adwords_remarketing_lists', listId: '709078448', customerId: '7693729833', consent: { adPersonalization: 'UNSPECIFIED', adUserData: 'UNSPECIFIED' }, }; -const validRequestPayload1 = { +export const validRequestPayload1 = { enablePartialFailure: true, operations: [ { @@ -92,7 +94,7 @@ const invalidArgumentRequestPayload = { const metadataArray = [generateGoogleOAuthMetadata(1)]; -const expectedStatTags = { +export const expectedStatTags = { destType: 'GOOGLE_ADWORDS_REMARKETING_LISTS', destinationId: 'default-destinationId', errorCategory: 'network', @@ -120,7 +122,7 @@ export const testScenariosForV0API = [ headers: commonHeaders, params: commonParams, JSON: validRequestPayload1, - endpoint: 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, }), method: 'POST', }, @@ -154,7 +156,7 @@ export const testScenariosForV0API = [ headers: commonHeaders, params: commonParams, JSON: invalidArgumentRequestPayload, - endpoint: 'https://googleads.googleapis.com/v15/customers/7693729834/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729834/offlineUserDataJobs`, }), method: 'POST', }, @@ -166,7 +168,7 @@ export const testScenariosForV0API = [ output: { status: 400, message: - 'Request contains an invalid argument. during ga_audience response transformation', + '{"error":{"code":400,"details":[{"@type":"type.googleapis.com/google.ads.googleads.v9.errors.GoogleAdsFailure","errors":[{"errorCode":{"offlineUserDataJobError":"INVALID_SHA256_FORMAT"},"message":"The SHA256 encoded value is malformed.","location":{"fieldPathElements":[{"fieldName":"operations","index":0},{"fieldName":"remove"},{"fieldName":"user_identifiers","index":0},{"fieldName":"hashed_email"}]}}]}],"message":"Request contains an invalid argument.","status":"INVALID_ARGUMENT"}} during ga_audience response transformation', destinationResponse: { error: { code: 400, @@ -217,7 +219,7 @@ export const testScenariosForV0API = [ headers: commonHeaders, params: commonParams, JSON: validRequestPayload2, - endpoint: 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, }), method: 'POST', }, @@ -255,8 +257,7 @@ export const testScenariosForV1API = [ headers: commonHeaders, params: commonParams, JSON: validRequestPayload1, - endpoint: - 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, }, metadataArray, ), @@ -299,8 +300,7 @@ export const testScenariosForV1API = [ headers: commonHeaders, params: commonParams, JSON: invalidArgumentRequestPayload, - endpoint: - 'https://googleads.googleapis.com/v15/customers/7693729834/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729834/offlineUserDataJobs`, }, metadataArray, ), @@ -313,11 +313,11 @@ export const testScenariosForV1API = [ body: { output: { message: - 'Request contains an invalid argument. during ga_audience response transformation', + '{"error":{"code":400,"details":[{"@type":"type.googleapis.com/google.ads.googleads.v9.errors.GoogleAdsFailure","errors":[{"errorCode":{"offlineUserDataJobError":"INVALID_SHA256_FORMAT"},"message":"The SHA256 encoded value is malformed.","location":{"fieldPathElements":[{"fieldName":"operations","index":0},{"fieldName":"remove"},{"fieldName":"user_identifiers","index":0},{"fieldName":"hashed_email"}]}}]}],"message":"Request contains an invalid argument.","status":"INVALID_ARGUMENT"}} during ga_audience response transformation', response: [ { error: - 'Request contains an invalid argument. during ga_audience response transformation', + '{"error":{"code":400,"details":[{"@type":"type.googleapis.com/google.ads.googleads.v9.errors.GoogleAdsFailure","errors":[{"errorCode":{"offlineUserDataJobError":"INVALID_SHA256_FORMAT"},"message":"The SHA256 encoded value is malformed.","location":{"fieldPathElements":[{"fieldName":"operations","index":0},{"fieldName":"remove"},{"fieldName":"user_identifiers","index":0},{"fieldName":"hashed_email"}]}}]}],"message":"Request contains an invalid argument.","status":"INVALID_ARGUMENT"}} during ga_audience response transformation', metadata: generateGoogleOAuthMetadata(1), statusCode: 400, }, @@ -346,8 +346,7 @@ export const testScenariosForV1API = [ headers: commonHeaders, params: commonParams, JSON: validRequestPayload2, - endpoint: - 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, }, metadataArray, ), @@ -373,4 +372,71 @@ export const testScenariosForV1API = [ }, }, }, + { + id: 'garl_v1_scenario_4', + name: 'google_adwords_remarketing_lists', + description: + '[Proxy v1 API] :: getting concurrent_modification error code while sending request to GA audience API', + successCriteria: 'Should return 500 with destination response', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + headers: commonHeaders, + params: { ...commonParams, customerId: 'wrongCustomerId' }, + JSON: validRequestPayload2, + endpoint: + 'https://googleads.googleapis.com/v15/customers/wrongCustomerId/offlineUserDataJobs', + }, + metadataArray, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + '{"error":{"code":400,"message":"Request contains an invalid argument.","status":"INVALID_ARGUMENT","details":[{"@type":"type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure","errors":[{"errorCode":{"databaseError":"CONCURRENT_MODIFICATION"},"message":"Multiple requests were attempting to modify the same resource at once. Retry the request."}],"requestId":"08X6xmM1WJPf_lW1ppYfsA"}]}} during ga_audience response transformation', + response: [ + { + error: + '{"error":{"code":400,"message":"Request contains an invalid argument.","status":"INVALID_ARGUMENT","details":[{"@type":"type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure","errors":[{"errorCode":{"databaseError":"CONCURRENT_MODIFICATION"},"message":"Multiple requests were attempting to modify the same resource at once. Retry the request."}],"requestId":"08X6xmM1WJPf_lW1ppYfsA"}]}} during ga_audience response transformation', + metadata: { + attemptNum: 1, + destinationId: 'default-destinationId', + dontBatch: false, + jobId: 1, + secret: { + access_token: 'default-accessToken', + }, + sourceId: 'default-sourceId', + userId: 'default-userId', + workspaceId: 'default-workspaceId', + }, + statusCode: 500, + }, + ], + statTags: { + destType: 'GOOGLE_ADWORDS_REMARKETING_LISTS', + destinationId: 'default-destinationId', + errorCategory: 'network', + errorType: 'retryable', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', + workspaceId: 'default-workspaceId', + }, + status: 500, + }, + }, + }, + }, + }, ]; diff --git a/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/data.ts b/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/data.ts index 51827a38e2..8bde58c780 100644 --- a/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/data.ts +++ b/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/data.ts @@ -1,3 +1,4 @@ import { testScenariosForV0API, testScenariosForV1API } from './business'; +import { oauthError } from './oauth'; -export const data = [...testScenariosForV0API, ...testScenariosForV1API]; +export const data = [...testScenariosForV0API, ...testScenariosForV1API, ...oauthError]; diff --git a/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/oauth.ts b/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/oauth.ts new file mode 100644 index 0000000000..e8a1cfc07e --- /dev/null +++ b/test/integrations/destinations/google_adwords_remarketing_lists/dataDelivery/oauth.ts @@ -0,0 +1,117 @@ +import { generateMetadata, generateProxyV1Payload } from '../../../testUtils'; +import { commonHeaders, commonParams, validRequestPayload1 } from './business'; +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_remarketing_lists/config'; + +const commonStatTags = { + destType: 'GOOGLE_ADWORDS_REMARKETING_LISTS', + destinationId: 'default-destinationId', + errorCategory: 'network', + errorType: 'aborted', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', + workspaceId: 'default-workspaceId', +}; + +export const oauthError = [ + { + id: 'garl_oauth_scenario', + name: 'google_adwords_remarketing_lists', + description: + '[Proxy v1 API] :: Oauth where valid credentials are missing as mock response from destination', + successCriteria: 'The proxy should return 401 with authErrorCategory as REFRESH_TOKEN', + scenario: 'Oauth', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload({ + headers: commonHeaders, + params: commonParams, + JSON: validRequestPayload1, + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/customerid/offlineUserDataJobs`, + accessToken: 'dummy-access', + }), + method: 'POST', + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'REFRESH_TOKEN', + message: + '{"error":{"code":401,"message":"Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED"}} during ga_audience response transformation', + response: [ + { + error: + '{"error":{"code":401,"message":"Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED"}} during ga_audience response transformation', + metadata: { + attemptNum: 1, + destinationId: 'default-destinationId', + dontBatch: false, + jobId: 1, + secret: { + accessToken: 'dummy-access', + }, + sourceId: 'default-sourceId', + userId: 'default-userId', + workspaceId: 'default-workspaceId', + }, + statusCode: 401, + }, + ], + statTags: commonStatTags, + status: 401, + }, + }, + }, + }, + }, + { + id: 'garl_oauth_scenario_with_wrong_customer_id', + name: 'google_adwords_remarketing_lists', + description: '[Proxy v1 API] :: Oauth where customer has provided wrong customerId', + successCriteria: 'The proxy should return 401 with authErrorCategory as AUTH_STATUS_INACTIVE', + scenario: 'Oauth', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload({ + headers: { ...commonHeaders, Authorization: 'Bearer wrongCustomerID' }, + params: { ...commonParams, customerId: 'wrongCustomerID' }, + JSON: validRequestPayload1, + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/customerid/offlineUserDataJobs`, + accessToken: 'wrongCustomerID', + }), + method: 'POST', + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'AUTH_STATUS_INACTIVE', + message: + '{"error":{"code":401,"message":"Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED","details":[{"@type":"type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure","errors":[{"errorCode":{"authenticationError":"CUSTOMER_NOT_FOUND"},"message":"No customer found for the provided customer id."}],"requestId":"lvB3KOjGHsgduHjt0wCglQ"}]}} during ga_audience response transformation', + response: [ + { + error: + '{"error":{"code":401,"message":"Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED","details":[{"@type":"type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure","errors":[{"errorCode":{"authenticationError":"CUSTOMER_NOT_FOUND"},"message":"No customer found for the provided customer id."}],"requestId":"lvB3KOjGHsgduHjt0wCglQ"}]}} during ga_audience response transformation', + metadata: { ...generateMetadata(1), secret: { accessToken: 'wrongCustomerID' } }, + statusCode: 401, + }, + ], + statTags: commonStatTags, + status: 401, + }, + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/google_adwords_remarketing_lists/network.ts b/test/integrations/destinations/google_adwords_remarketing_lists/network.ts index 8e7c0acbcf..a367c18737 100644 --- a/test/integrations/destinations/google_adwords_remarketing_lists/network.ts +++ b/test/integrations/destinations/google_adwords_remarketing_lists/network.ts @@ -1,9 +1,9 @@ -import { enhanceRequestOptions, getFormData } from '../../../../src/adapters/network'; +import { API_VERSION } from '../../../../src/v0/destinations/google_adwords_remarketing_lists/config'; export const networkCallsData = [ { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs:create', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs:create`, data: { job: { type: 'CUSTOMER_MATCH_USER_LIST', @@ -29,7 +29,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs/18025019461:addOperations', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs/18025019461:addOperations`, data: { enablePartialFailure: true, operations: [ @@ -71,7 +71,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs/18025019461:run', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs/18025019461:run`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -85,7 +85,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/7693729834/offlineUserDataJobs:create', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729834/offlineUserDataJobs:create`, data: { job: { type: 'CUSTOMER_MATCH_USER_LIST', @@ -111,7 +111,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/7693729834/offlineUserDataJobs/18025019462:addOperations', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729834/offlineUserDataJobs/18025019462:addOperations`, data: { enablePartialFailure: true, operations: [{ create: { userIdentifiers: [{ hashedEmail: 'abcd@testmail.com' }] } }], @@ -167,7 +167,7 @@ export const networkCallsData = [ }, { httpReq: { - url: 'https://googleads.googleapis.com/v15/customers/7693729833/offlineUserDataJobs/18025019461:addOperations', + url: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs/18025019461:addOperations`, data: { enablePartialFailure: true, operations: [ @@ -207,4 +207,134 @@ export const networkCallsData = [ data: {}, }, }, + { + httpReq: { + url: `https://googleads.googleapis.com/${API_VERSION}/customers/customerid/offlineUserDataJobs:create`, + data: { + job: { + type: 'CUSTOMER_MATCH_USER_LIST', + customerMatchUserListMetadata: { + userList: 'customers/7693729833/userLists/709078448', + consent: { + adPersonalization: 'UNSPECIFIED', + adUserData: 'UNSPECIFIED', + }, + }, + }, + }, + headers: { + Authorization: 'Bearer dummy-access', + 'Content-Type': 'application/json', + 'developer-token': 'dummy-dev-token', + }, + method: 'POST', + }, + httpRes: { + status: 401, + data: { + error: { + code: 401, + message: + 'Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.', + status: 'UNAUTHENTICATED', + }, + }, + }, + }, + { + httpReq: { + url: `https://googleads.googleapis.com/${API_VERSION}/customers/customerid/offlineUserDataJobs:create`, + data: { + job: { + type: 'CUSTOMER_MATCH_USER_LIST', + customerMatchUserListMetadata: { + userList: 'customers/wrongCustomerID/userLists/709078448', + consent: { + adPersonalization: 'UNSPECIFIED', + adUserData: 'UNSPECIFIED', + }, + }, + }, + }, + headers: { + Authorization: 'Bearer wrongCustomerID', + 'Content-Type': 'application/json', + 'developer-token': 'dummy-dev-token', + }, + method: 'POST', + }, + httpRes: { + status: 401, + data: { + error: { + code: 401, + message: + 'Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.', + status: 'UNAUTHENTICATED', + details: [ + { + '@type': 'type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure', + errors: [ + { + errorCode: { + authenticationError: 'CUSTOMER_NOT_FOUND', + }, + message: 'No customer found for the provided customer id.', + }, + ], + requestId: 'lvB3KOjGHsgduHjt0wCglQ', + }, + ], + }, + }, + }, + }, + { + httpReq: { + url: 'https://googleads.googleapis.com/v15/customers/wrongCustomerId/offlineUserDataJobs:create', + data: { + job: { + type: 'CUSTOMER_MATCH_USER_LIST', + customerMatchUserListMetadata: { + userList: 'customers/wrongCustomerId/userLists/709078448', + consent: { + adPersonalization: 'UNSPECIFIED', + adUserData: 'UNSPECIFIED', + }, + }, + }, + }, + headers: { + Authorization: 'Bearer dummy-access', + 'Content-Type': 'application/json', + 'developer-token': 'dummy-dev-token', + }, + method: 'POST', + }, + httpRes: { + status: 400, + data: { + error: { + code: 400, + message: 'Request contains an invalid argument.', + status: 'INVALID_ARGUMENT', + details: [ + { + '@type': 'type.googleapis.com/google.ads.googleads.v16.errors.GoogleAdsFailure', + errors: [ + { + errorCode: { + databaseError: 'CONCURRENT_MODIFICATION', + }, + message: + 'Multiple requests were attempting to modify the same resource at once. Retry the request.', + }, + ], + requestId: '08X6xmM1WJPf_lW1ppYfsA', + }, + ], + }, + }, + }, + }, ]; diff --git a/test/integrations/destinations/google_adwords_remarketing_lists/processor/data.ts b/test/integrations/destinations/google_adwords_remarketing_lists/processor/data.ts index 83eae90aea..e20ed89545 100644 --- a/test/integrations/destinations/google_adwords_remarketing_lists/processor/data.ts +++ b/test/integrations/destinations/google_adwords_remarketing_lists/processor/data.ts @@ -1,3 +1,4 @@ +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_remarketing_lists/config'; export const data = [ { name: 'google_adwords_remarketing_lists', @@ -69,8 +70,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -202,8 +202,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -322,8 +321,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -1424,8 +1422,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -2819,8 +2816,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -2899,8 +2895,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -4112,8 +4107,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -5412,8 +5406,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -6789,8 +6782,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -8099,8 +8091,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -9399,8 +9390,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -10794,8 +10784,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -10874,8 +10863,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11049,8 +11037,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11127,8 +11114,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11271,8 +11257,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11478,8 +11463,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11617,8 +11601,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11755,8 +11738,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -11895,8 +11877,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', @@ -12038,8 +12019,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer dummy-access', 'Content-Type': 'application/json', diff --git a/test/integrations/destinations/google_adwords_remarketing_lists/router/data.ts b/test/integrations/destinations/google_adwords_remarketing_lists/router/data.ts index a282b0a56c..f5789bf7ef 100644 --- a/test/integrations/destinations/google_adwords_remarketing_lists/router/data.ts +++ b/test/integrations/destinations/google_adwords_remarketing_lists/router/data.ts @@ -1,5 +1,6 @@ import { rETLAudienceRouterRequest } from './audience'; import { rETLRecordRouterRequest } from './record'; +import { API_VERSION } from '../../../../../src/v0/destinations/google_adwords_remarketing_lists/config'; export const data = [ { @@ -25,8 +26,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', @@ -121,8 +121,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', @@ -217,8 +216,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', @@ -268,8 +266,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', @@ -386,8 +383,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', @@ -484,8 +480,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', @@ -612,8 +607,7 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: - 'https://googleads.googleapis.com/v16/customers/7693729833/offlineUserDataJobs', + endpoint: `https://googleads.googleapis.com/${API_VERSION}/customers/7693729833/offlineUserDataJobs`, headers: { Authorization: 'Bearer default-accessToken', 'Content-Type': 'application/json', diff --git a/test/integrations/destinations/googlepubsub/processor/data.ts b/test/integrations/destinations/googlepubsub/processor/data.ts index 0dffa57839..6746e5b765 100644 --- a/test/integrations/destinations/googlepubsub/processor/data.ts +++ b/test/integrations/destinations/googlepubsub/processor/data.ts @@ -1314,4 +1314,72 @@ export const data = [ }, }, }, + { + name: 'googlepubsub', + description: 'Test 13', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + sentAt: '2020-08-28T15:11:56.167Z', + category: 'Food', + messageId: + 'node-cfc5fb7ec83b82bc29e16336a11331e2-0ba97212-0f6e-44cd-a0f1-c20b8b7a7cba', + anonymousId: 'abcdeeeeeeeexxxx111', + originalTimestamp: '2020-08-28T15:11:56.162Z', + name: 'Pizza', + _metadata: { + nodeVersion: '10.22.0', + }, + }, + destination: { + Config: { + credentials: 'abc', + eventToTopicMap: [ + { + from: 'track', + to: 'Test-Topic', + }, + { + from: '*', + to: 'test', + }, + ], + eventToAttributesMap: [ + { + from: 'track', + to: 'properties.nestedObject.this', + }, + ], + }, + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: 'type is required for event', + statTags: { + destType: 'GOOGLEPUBSUB', + errorCategory: 'dataValidation', + errorType: 'configuration', + feature: 'processor', + implementation: 'native', + meta: 'accessTokenExpired', + module: 'destination', + }, + statusCode: 400, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/hs/dataDelivery/business.ts b/test/integrations/destinations/hs/dataDelivery/business.ts new file mode 100644 index 0000000000..2239abfb95 --- /dev/null +++ b/test/integrations/destinations/hs/dataDelivery/business.ts @@ -0,0 +1,593 @@ +import { generateMetadata, generateProxyV1Payload } from '../../../testUtils'; + +const commonStatTags = { + destType: 'HS', + destinationId: 'default-destinationId', + errorCategory: 'network', + errorType: 'retryable', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', + workspaceId: 'default-workspaceId', +}; +export const businessData = [ + { + name: 'hs', + description: 'successfully creating users from a batch with legacy api', + feature: 'dataDelivery', + module: 'destination', + id: 'successWithLegacyApi', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/contacts/v1/contact/batch/', + JSON_ARRAY: { + batch: + '[{"email":"identify111051@test.com","properties":[{"property":"firstname","value":"John1051"},{"property":"lastname","value":"Sparrow1051"}]},{"email":"identify111052@test.com","properties":[{"property":"firstname","value":"John1052"},{"property":"lastname","value":"Sparrow1052"}]},{"email":"identify111053@test.com","properties":[{"property":"firstname","value":"John1053"},{"property":"lastname","value":"Sparrow1053"}]}]', + }, + headers: { + Authorization: 'Bearer validApiKey', + 'Content-Type': 'application/json', + }, + }, + [generateMetadata(1), generateMetadata(2)], + { + apiVersion: 'legacyApi', + }, + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: 'success', + metadata: generateMetadata(1), + statusCode: 200, + }, + { + error: 'success', + metadata: generateMetadata(2), + statusCode: 200, + }, + ], + status: 200, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'failed to create users from a batch with legacy api', + feature: 'dataDelivery', + module: 'destination', + id: 'failureWithLegacyApi', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/contacts/v1/contact/batch/', + JSON_ARRAY: { + batch: + '[{"email":"identify111051@test.com","properties":[{"property":"firstname","value":"John1051"},{"property":"lastname","value":"Sparrow1051"}]},{"email":"identify111052@test.con","properties":[{"property":"firstname","value":"John1052"},{"property":"lastname","value":"Sparrow1052"}]},{"email":"identify111053@test.com","properties":[{"property":"firstname","value":"John1053"},{"property":"lastname","value":"Sparrow1053"}]}]', + }, + headers: { + Authorization: 'Bearer inValidApiKey', + 'Content-Type': 'application/json', + }, + }, + [generateMetadata(1), generateMetadata(2)], + { + apiVersion: 'legacyApi', + }, + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: + '{"status":"error","message":"Errors found processing batch update","correlationId":"a716ef20-79df-44d4-98bd-9136af7bdefc","invalidEmails":["identify111052@test.con"],"failureMessages":[{"index":1,"error":{"status":"error","message":"Email address identify111052@test.con is invalid"}}]}', + metadata: { ...generateMetadata(1), dontBatch: true }, + statusCode: 500, + }, + { + error: + '{"status":"error","message":"Errors found processing batch update","correlationId":"a716ef20-79df-44d4-98bd-9136af7bdefc","invalidEmails":["identify111052@test.con"],"failureMessages":[{"index":1,"error":{"status":"error","message":"Email address identify111052@test.con is invalid"}}]}', + metadata: { ...generateMetadata(2), dontBatch: true }, + statusCode: 500, + }, + ], + status: 500, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'successfully deliver events with legacy api', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + id: 'successEventsWithLegacyApi', + input: { + request: { + body: generateProxyV1Payload( + { + headers: { + 'Content-Type': 'application/json', + }, + method: 'GET', + params: { + _a: 'dummy-hubId', + _n: 'test track event HS', + _m: 4.99, + email: 'testhubspot2@email.com', + firstname: 'Test Hubspot', + }, + endpoint: 'https://track.hubspot.com/v1/event', + }, + [generateMetadata(1)], + { + apiVersion: 'legacyApi', + }, + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: '{}', + metadata: generateMetadata(1), + statusCode: 200, + }, + ], + status: 200, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'successfully creating users from a batch with new api', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + id: 'successCreatingBatchOfUsersWithNewApi', + input: { + request: { + body: generateProxyV1Payload( + { + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer validAccessToken', + }, + method: 'POST', + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/create', + JSON: { + inputs: [ + { + properties: { + email: 'testuser31848@testmail.com', + }, + }, + { + properties: { + email: 'testuser31847@testmail.com', + }, + }, + ], + }, + }, + [generateMetadata(1), generateMetadata(2)], + { + apiVersion: 'newApi', + }, + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: + '{"id":"44188066992","properties":{"createdate":"2024-07-31T03:21:03.176Z","email":"testuser31848@testmail.com","hs_all_contact_vids":"44188066992","hs_email_domain":"testmail.com","hs_is_contact":"true","hs_is_unworked":"true","hs_lifecyclestage_lead_date":"2024-07-31T03:21:03.176Z","hs_membership_has_accessed_private_content":"0","hs_object_id":"44188066992","hs_object_source":"INTEGRATION","hs_object_source_id":"3209723","hs_object_source_label":"INTEGRATION","hs_pipeline":"contacts-lifecycle-pipeline","hs_registered_member":"0","lastmodifieddate":"2024-07-31T03:21:03.176Z","lifecyclestage":"lead"},"createdAt":"2024-07-31T03:21:03.176Z","updatedAt":"2024-07-31T03:21:03.176Z","archived":false}', + metadata: generateMetadata(1), + statusCode: 200, + }, + { + error: + '{"id":"44188066993","properties":{"createdate":"2024-07-31T03:21:03.176Z","email":"testuser31847@testmail.com","hs_all_contact_vids":"44188066993","hs_email_domain":"testmail.com","hs_is_contact":"true","hs_is_unworked":"true","hs_lifecyclestage_lead_date":"2024-07-31T03:21:03.176Z","hs_membership_has_accessed_private_content":"0","hs_object_id":"44188066993","hs_object_source":"INTEGRATION","hs_object_source_id":"3209723","hs_object_source_label":"INTEGRATION","hs_pipeline":"contacts-lifecycle-pipeline","hs_registered_member":"0","lastmodifieddate":"2024-07-31T03:21:03.176Z","lifecyclestage":"lead"},"createdAt":"2024-07-31T03:21:03.176Z","updatedAt":"2024-07-31T03:21:03.176Z","archived":false}', + metadata: generateMetadata(2), + statusCode: 200, + }, + ], + status: 200, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'successfully updating users from a batch with new api', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + JSON: { + inputs: [ + { + properties: { + firstname: 'testmail1217', + }, + id: '12877907024', + }, + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + }, + [generateMetadata(1), generateMetadata(2)], + { + apiVersion: 'newApi', + }, + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 200, + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: + '{"id":"12877907025","properties":{"createdate":"2024-04-16T09:50:16.034Z","email":"test1@mail.com","firstname":"test1","hs_is_unworked":"true","hs_object_id":"12877907025","hs_pipeline":"contacts-lifecycle-pipeline","lastmodifieddate":"2024-04-23T11:52:03.723Z","lifecyclestage":"lead"},"createdAt":"2024-04-16T09:50:16.034Z","updatedAt":"2024-04-23T11:52:03.723Z","archived":false}', + metadata: generateMetadata(1), + statusCode: 200, + }, + { + error: + '{"id":"12877907024","properties":{"createdate":"2024-04-16T09:50:16.034Z","firstname":"testmail1217","hs_is_unworked":"true","hs_object_id":"12877907024","hs_pipeline":"contacts-lifecycle-pipeline","lastmodifieddate":"2024-04-23T11:52:03.723Z","lifecyclestage":"lead"},"createdAt":"2024-04-16T09:50:16.034Z","updatedAt":"2024-04-23T11:52:03.723Z","archived":false}', + metadata: generateMetadata(2), + statusCode: 200, + }, + ], + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'failed due to duplicate in a batch', + id: 'hs_datadelivery_01', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + JSON: { + inputs: [ + { + properties: { + firstname: 'test5', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + { + properties: { + firstname: 'testmail1217', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + }, + [generateMetadata(1), generateMetadata(2)], + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: + '{"status":"error","message":"Duplicate IDs found in batch input: [12877907025]. IDs must be unique","correlationId":"d24ec5cd-8998-4674-a928-59603ae6b0eb","context":{"ids":["12877907025"]},"category":"VALIDATION_ERROR"}', + metadata: { + ...generateMetadata(1), + dontBatch: true, + }, + statusCode: 500, + }, + { + error: + '{"status":"error","message":"Duplicate IDs found in batch input: [12877907025]. IDs must be unique","correlationId":"d24ec5cd-8998-4674-a928-59603ae6b0eb","context":{"ids":["12877907025"]},"category":"VALIDATION_ERROR"}', + metadata: { + ...generateMetadata(2), + dontBatch: true, + }, + statusCode: 500, + }, + ], + status: 500, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'failed due to wrong email format in a batch', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + JSON: { + inputs: [ + [ + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + }, + { + properties: { + firstname: 'testmail1217', + email: 'testmail1217@testmail.com', + }, + }, + { + properties: { + firstname: 'test5', + email: 'test5@xmail.con', + }, + }, + ], + ], + }, + }, + [generateMetadata(1), generateMetadata(2), generateMetadata(3)], + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: + '{"status":"error","message":"Invalid input JSON on line 3, column 9: Cannot deserialize value of type `com.hubspot.inbounddb.publicobject.core.v2.SimplePublicObjectBatchInput$Json` from Array value (token `JsonToken.START_ARRAY`)","correlationId":"99df04b9-da11-4504-bd97-2c15f58d0943"}', + metadata: { + ...generateMetadata(1), + dontBatch: true, + }, + statusCode: 500, + }, + { + error: + '{"status":"error","message":"Invalid input JSON on line 3, column 9: Cannot deserialize value of type `com.hubspot.inbounddb.publicobject.core.v2.SimplePublicObjectBatchInput$Json` from Array value (token `JsonToken.START_ARRAY`)","correlationId":"99df04b9-da11-4504-bd97-2c15f58d0943"}', + metadata: { + ...generateMetadata(2), + dontBatch: true, + }, + statusCode: 500, + }, + { + error: + '{"status":"error","message":"Invalid input JSON on line 3, column 9: Cannot deserialize value of type `com.hubspot.inbounddb.publicobject.core.v2.SimplePublicObjectBatchInput$Json` from Array value (token `JsonToken.START_ARRAY`)","correlationId":"99df04b9-da11-4504-bd97-2c15f58d0943"}', + metadata: { + ...generateMetadata(3), + dontBatch: true, + }, + statusCode: 500, + }, + ], + status: 500, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'succeed to send a custom event', + feature: 'dataDelivery', + module: 'destination', + id: 'succeedEventWithNewApi', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/events/v3/send', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + JSON: { + email: 'osvaldocostaferreira98@gmail.com', + eventName: 'pe22315509_rs_hub_test', + properties: { + value: 'name1', + }, + }, + }, + [generateMetadata(1)], + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: '{}', + metadata: generateMetadata(1), + statusCode: 200, + }, + ], + status: 200, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'succeed to send a custom event', + feature: 'dataDelivery', + module: 'destination', + id: 'failedEventWithNewApi', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/events/v3/send', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer invalid-dummy-access-token', + }, + JSON: { + email: 'osvaldocostaferreira98@gmail.com', + eventName: 'pe22315509_rs_hub_test', + properties: { + value: 'name1', + }, + }, + }, + [generateMetadata(1)], + ), + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'REFRESH_TOKEN', + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: + '{"status":"error","message":"Authentication credentials not found. This API supports OAuth 2.0 authentication and you can find more details at https://developers.hubspot.com/docs/methods/auth/oauth-overview","correlationId":"501651f6-bb90-40f1-b0db-349f62916993","category":"INVALID_AUTHENTICATION"}', + metadata: generateMetadata(1), + statusCode: 401, + }, + ], + statTags: { ...commonStatTags, errorType: 'aborted' }, + status: 401, + }, + }, + }, + }, + }, + { + name: 'hs', + description: 'succeed to send an event with association', + feature: 'dataDelivery', + module: 'destination', + id: 'succeedAssociationWithNewApi', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://api.hubapi.com/crm/v3/associations/companies/contacts/batch/create', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + JSON: { + inputs: [{ to: { id: 1 }, from: { id: 9405415215 }, type: 'contact_to_company' }], + }, + }, + [generateMetadata(1)], + ), + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: + '{"completedAt":"2024-07-31T04:46:34.391Z","requestedAt":"2024-07-31T04:46:34.391Z","startedAt":"2024-07-31T04:46:34.391Z","results":[{"from":{"id":"9405415215"},"to":{"id":"1"},"type":"contact_to_company"}],"status":"PENDING"}', + metadata: generateMetadata(1), + statusCode: 201, + }, + ], + status: 201, + }, + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/hs/dataDelivery/data.ts b/test/integrations/destinations/hs/dataDelivery/data.ts new file mode 100644 index 0000000000..5b2060d001 --- /dev/null +++ b/test/integrations/destinations/hs/dataDelivery/data.ts @@ -0,0 +1,4 @@ +import { businessData } from './business'; +import { otherData } from './other'; + +export const data = [...businessData, ...otherData]; diff --git a/test/integrations/destinations/hs/dataDelivery/other.ts b/test/integrations/destinations/hs/dataDelivery/other.ts new file mode 100644 index 0000000000..202b665a51 --- /dev/null +++ b/test/integrations/destinations/hs/dataDelivery/other.ts @@ -0,0 +1,245 @@ +import { generateMetadata } from '../../../testUtils'; + +const commonStatTags = { + destType: 'HS', + destinationId: 'default-destinationId', + errorCategory: 'network', + errorType: 'retryable', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', + workspaceId: 'default-workspaceId', +}; + +const commonBody = { + version: '1', + type: 'REST', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummyAccessToken', + }, + params: {}, + files: {}, + metadata: [generateMetadata(1), generateMetadata(2)], + body: { + JSON: { + inputs: [ + { + properties: { + firstname: 'testmail1217', + }, + id: '12877907024', + }, + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, +}; + +export const otherData = [ + { + name: 'hs', + id: 'hs_datadelivery_other_00', + description: 'failed due to gateway timeout from hubspot', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: { + endpoint: 'https://random_test_url/test_for_gateway_time_out', + ...commonBody, + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: '"Gateway Timeout"', + metadata: generateMetadata(1), + statusCode: 504, + }, + { + error: '"Gateway Timeout"', + metadata: generateMetadata(2), + statusCode: 504, + }, + ], + statTags: commonStatTags, + status: 504, + }, + }, + }, + }, + }, + { + name: 'hs', + id: 'hs_datadelivery_other_01', + description: 'failed due to internal server error from hubspot', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: { + endpoint: 'https://random_test_url/test_for_internal_server_error', + ...commonBody, + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: '"Internal Server Error"', + metadata: generateMetadata(1), + statusCode: 500, + }, + { + error: '"Internal Server Error"', + metadata: generateMetadata(2), + statusCode: 500, + }, + ], + statTags: commonStatTags, + status: 500, + }, + }, + }, + }, + }, + { + name: 'hs', + id: 'hs_datadelivery_other_02', + description: 'failed due to service unavailable error from hubspot', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: { + endpoint: 'https://random_test_url/test_for_service_not_available', + ...commonBody, + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: + 'HUBSPOT: Error in transformer proxy v1 during HUBSPOT response transformation', + response: [ + { + error: + '{"error":{"message":"Service Unavailable","description":"The server is currently unable to handle the request due to temporary overloading or maintenance of the server. Please try again later."}}', + metadata: generateMetadata(1), + statusCode: 503, + }, + { + error: + '{"error":{"message":"Service Unavailable","description":"The server is currently unable to handle the request due to temporary overloading or maintenance of the server. Please try again later."}}', + metadata: generateMetadata(2), + statusCode: 503, + }, + ], + statTags: commonStatTags, + status: 503, + }, + }, + }, + }, + }, + { + name: 'hs', + id: 'hs_datadelivery_other_03', + description: 'getting success response but not in the expected format', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: { + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + version: '1', + type: 'REST', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummyAccessToken', + }, + params: {}, + files: {}, + metadata: [generateMetadata(1), generateMetadata(2)], + body: { + JSON: { + inputs: [ + { + properties: { + firstname: 'testmail12178', + }, + id: '12877907024', + }, + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: { + message: '[HUBSPOT Response V1 Handler] - Request Processed Successfully', + response: [ + { + error: 'success', + metadata: generateMetadata(1), + statusCode: 200, + }, + { + error: 'success', + metadata: generateMetadata(2), + statusCode: 200, + }, + ], + status: 200, + }, + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/hs/network.ts b/test/integrations/destinations/hs/network.ts index 3d3b8fd83f..9d8658ff6b 100644 --- a/test/integrations/destinations/hs/network.ts +++ b/test/integrations/destinations/hs/network.ts @@ -692,4 +692,380 @@ export const networkCallsData = [ status: 200, }, }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + method: 'POST', + data: { + inputs: [ + { + properties: { + firstname: 'testmail1217', + }, + id: '12877907024', + }, + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + }, + httpRes: { + status: 200, + data: { + status: 'COMPLETE', + results: [ + { + id: '12877907025', + properties: { + createdate: '2024-04-16T09:50:16.034Z', + email: 'test1@mail.com', + firstname: 'test1', + hs_is_unworked: 'true', + hs_object_id: '12877907025', + hs_pipeline: 'contacts-lifecycle-pipeline', + lastmodifieddate: '2024-04-23T11:52:03.723Z', + lifecyclestage: 'lead', + }, + createdAt: '2024-04-16T09:50:16.034Z', + updatedAt: '2024-04-23T11:52:03.723Z', + archived: false, + }, + { + id: '12877907024', + properties: { + createdate: '2024-04-16T09:50:16.034Z', + firstname: 'testmail1217', + hs_is_unworked: 'true', + hs_object_id: '12877907024', + hs_pipeline: 'contacts-lifecycle-pipeline', + lastmodifieddate: '2024-04-23T11:52:03.723Z', + lifecyclestage: 'lead', + }, + createdAt: '2024-04-16T09:50:16.034Z', + updatedAt: '2024-04-23T11:52:03.723Z', + archived: false, + }, + ], + startedAt: '2024-04-24T05:11:51.090Z', + completedAt: '2024-04-24T05:11:51.190Z', + }, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + method: 'POST', + data: { + inputs: [ + { + properties: { + firstname: 'test5', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + { + properties: { + firstname: 'testmail1217', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + }, + httpRes: { + status: 400, + data: { + status: 'error', + message: 'Duplicate IDs found in batch input: [12877907025]. IDs must be unique', + correlationId: 'd24ec5cd-8998-4674-a928-59603ae6b0eb', + context: { + ids: ['12877907025'], + }, + category: 'VALIDATION_ERROR', + }, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + method: 'POST', + data: { + inputs: [ + [ + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + }, + { + properties: { + firstname: 'testmail1217', + email: 'testmail1217@testmail.com', + }, + }, + { + properties: { + firstname: 'test5', + email: 'test5@xmail.con', + }, + }, + ], + ], + }, + }, + httpRes: { + status: 400, + data: { + status: 'error', + message: + 'Invalid input JSON on line 3, column 9: Cannot deserialize value of type `com.hubspot.inbounddb.publicobject.core.v2.SimplePublicObjectBatchInput$Json` from Array value (token `JsonToken.START_ARRAY`)', + correlationId: '99df04b9-da11-4504-bd97-2c15f58d0943', + }, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/update', + method: 'POST', + data: { + inputs: [ + { + properties: { + firstname: 'testmail12178', + }, + id: '12877907024', + }, + { + properties: { + firstname: 'test1', + email: 'test1@mail.com', + }, + id: '12877907025', + }, + ], + }, + }, + httpRes: { + status: 200, + data: { + message: 'unknown response', + }, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/objects/contacts/search', + method: 'POST', + headers: { + Authorization: 'Bearer dontbatchtrueaccesstoken', + }, + }, + httpRes: { + data: { + total: 0, + results: [], + }, + status: 200, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/contacts/v1/contact/batch/', + method: 'POST', + headers: { + 'User-Agent': 'RudderLabs', + 'Content-Type': 'application/json', + Authorization: 'Bearer validApiKey', + }, + }, + httpRes: { + status: 200, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/contacts/v1/contact/batch/', + method: 'POST', + headers: { + 'User-Agent': 'RudderLabs', + 'Content-Type': 'application/json', + Authorization: 'Bearer inValidApiKey', + }, + }, + httpRes: { + status: 400, + data: { + status: 'error', + message: 'Errors found processing batch update', + correlationId: 'a716ef20-79df-44d4-98bd-9136af7bdefc', + invalidEmails: ['identify111052@test.con'], + failureMessages: [ + { + index: 1, + error: { + status: 'error', + message: 'Email address identify111052@test.con is invalid', + }, + }, + ], + }, + }, + }, + { + httpReq: { + url: 'https://track.hubspot.com/v1/event', + method: 'GET', + params: { + _a: 'dummy-hubId', + _n: 'test track event HS', + _m: 4.99, + email: 'testhubspot2@email.com', + firstname: 'Test Hubspot', + }, + }, + httpRes: { + status: 200, + data: {}, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/create', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer validAccessToken', + }, + }, + httpRes: { + status: 200, + data: { + status: 'COMPLETE', + results: [ + { + id: '44188066992', + properties: { + createdate: '2024-07-31T03:21:03.176Z', + email: 'testuser31848@testmail.com', + hs_all_contact_vids: '44188066992', + hs_email_domain: 'testmail.com', + hs_is_contact: 'true', + hs_is_unworked: 'true', + hs_lifecyclestage_lead_date: '2024-07-31T03:21:03.176Z', + hs_membership_has_accessed_private_content: '0', + hs_object_id: '44188066992', + hs_object_source: 'INTEGRATION', + hs_object_source_id: '3209723', + hs_object_source_label: 'INTEGRATION', + hs_pipeline: 'contacts-lifecycle-pipeline', + hs_registered_member: '0', + lastmodifieddate: '2024-07-31T03:21:03.176Z', + lifecyclestage: 'lead', + }, + createdAt: '2024-07-31T03:21:03.176Z', + updatedAt: '2024-07-31T03:21:03.176Z', + archived: false, + }, + { + id: '44188066993', + properties: { + createdate: '2024-07-31T03:21:03.176Z', + email: 'testuser31847@testmail.com', + hs_all_contact_vids: '44188066993', + hs_email_domain: 'testmail.com', + hs_is_contact: 'true', + hs_is_unworked: 'true', + hs_lifecyclestage_lead_date: '2024-07-31T03:21:03.176Z', + hs_membership_has_accessed_private_content: '0', + hs_object_id: '44188066993', + hs_object_source: 'INTEGRATION', + hs_object_source_id: '3209723', + hs_object_source_label: 'INTEGRATION', + hs_pipeline: 'contacts-lifecycle-pipeline', + hs_registered_member: '0', + lastmodifieddate: '2024-07-31T03:21:03.176Z', + lifecyclestage: 'lead', + }, + createdAt: '2024-07-31T03:21:03.176Z', + updatedAt: '2024-07-31T03:21:03.176Z', + archived: false, + }, + ], + startedAt: '2024-07-31T03:21:03.133Z', + completedAt: '2024-07-31T03:21:03.412Z', + }, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/events/v3/send', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + }, + httpRes: { + status: 200, + data: {}, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/events/v3/send', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer invalid-dummy-access-token', + }, + }, + httpRes: { + status: 401, + data: { + status: 'error', + message: + 'Authentication credentials not found. This API supports OAuth 2.0 authentication and you can find more details at https://developers.hubspot.com/docs/methods/auth/oauth-overview', + correlationId: '501651f6-bb90-40f1-b0db-349f62916993', + category: 'INVALID_AUTHENTICATION', + }, + }, + }, + { + httpReq: { + url: 'https://api.hubapi.com/crm/v3/associations/companies/contacts/batch/create', + method: 'POST', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + }, + httpRes: { + status: 201, + data: { + completedAt: '2024-07-31T04:46:34.391Z', + requestedAt: '2024-07-31T04:46:34.391Z', + startedAt: '2024-07-31T04:46:34.391Z', + results: [ + { + from: { + id: '9405415215', + }, + to: { + id: '1', + }, + type: 'contact_to_company', + }, + ], + status: 'PENDING', + }, + }, + }, ]; diff --git a/test/integrations/destinations/hs/router/config.ts b/test/integrations/destinations/hs/router/config.ts new file mode 100644 index 0000000000..89a0c13d1a --- /dev/null +++ b/test/integrations/destinations/hs/router/config.ts @@ -0,0 +1,57 @@ +export const destination = { + Config: { + accessToken: 'dummy-access-token', + hubID: 'dummy-hubId', + authorizationType: 'newPrivateAppApi', + apiVersion: 'newApi', + lookupField: 'email', + hubspotEvents: [ + { + rsEventName: 'Purchase', + hubspotEventName: 'pedummy-hubId_rs_hub_test', + eventProperties: [ + { + from: 'Revenue', + to: 'value', + }, + { + from: 'Price', + to: 'cost', + }, + ], + }, + { + rsEventName: 'Purchase2', + hubspotEventName: 'pedummy-hubId_rs_hub_test', + eventProperties: [ + { + from: 'Revenue', + to: 'value', + }, + { + from: 'Price', + to: 'cost', + }, + ], + }, + { + rsEventName: 'Order Complete', + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + eventProperties: [ + { + from: 'firstName', + to: 'first_name', + }, + { + from: 'lastName', + to: 'last_name', + }, + ], + }, + ], + }, + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + }, + transformations: [], +}; diff --git a/test/integrations/destinations/hs/router/data.ts b/test/integrations/destinations/hs/router/data.ts index ab3ca8cba8..b47d6b7f07 100644 --- a/test/integrations/destinations/hs/router/data.ts +++ b/test/integrations/destinations/hs/router/data.ts @@ -1,3 +1,4 @@ +import { destination } from './config'; export const data = [ { name: 'hs', @@ -100,6 +101,235 @@ export const data = [ }, }, }, + { + name: 'hs', + description: 'legacy router retl tests', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + channel: 'web', + context: { + mappedToDestination: true, + externalId: [ + { identifierType: 'email', id: 'testhubspot2@email.com', type: 'HS-lead' }, + ], + sources: { + job_id: '24c5HJxHomh6YCngEOCgjS5r1KX/Syncher', + task_id: 'vw_rs_mailchimp_mocked_hg_data', + version: 'v1.8.1', + batch_id: 'f252c69d-c40d-450e-bcd2-2cf26cb62762', + job_run_id: 'c8el40l6e87v0c4hkbl0', + task_run_id: 'c8el40l6e87v0c4hkblg', + }, + }, + type: 'identify', + traits: { firstname: 'Test Hubspot', anonymousId: '12345', country: 'India' }, + messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', + originalTimestamp: '2019-10-15T09:35:31.288Z', + anonymousId: '00000000000000000000000000', + userId: '12345', + integrations: { All: true }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + destination: { + Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, + secretConfig: {}, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + name: 'Hubspot', + enabled: true, + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + deleted: false, + createdAt: '2020-12-30T08:39:32.005Z', + updatedAt: '2021-02-03T16:22:31.374Z', + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + displayName: 'Hubspot', + createdAt: '2020-04-09T09:24:31.794Z', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + transformations: [], + isConnectionEnabled: true, + isProcessorEnabled: true, + }, + metadata: { jobId: 2, userId: 'u1' }, + }, + { + message: { + channel: 'web', + context: { + mappedToDestination: true, + externalId: [ + { identifierType: 'email', id: 'testhubspot@email.com', type: 'HS-lead' }, + ], + sources: { + job_id: '24c5HJxHomh6YCngEOCgjS5r1KX/Syncher', + task_id: 'vw_rs_mailchimp_mocked_hg_data', + version: 'v1.8.1', + batch_id: 'f252c69d-c40d-450e-bcd2-2cf26cb62762', + job_run_id: 'c8el40l6e87v0c4hkbl0', + task_run_id: 'c8el40l6e87v0c4hkblg', + }, + }, + type: 'identify', + traits: { firstname: 'Test Hubspot 1', anonymousId: '123451', country: 'India 1' }, + messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', + originalTimestamp: '2019-10-15T09:35:31.288Z', + anonymousId: '00000000000000000000000000', + userId: '12345', + integrations: { All: true }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + destination: { + Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, + secretConfig: {}, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + name: 'Hubspot', + enabled: true, + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + deleted: false, + createdAt: '2020-12-30T08:39:32.005Z', + updatedAt: '2021-02-03T16:22:31.374Z', + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + displayName: 'Hubspot', + createdAt: '2020-04-09T09:24:31.794Z', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + transformations: [], + isConnectionEnabled: true, + isProcessorEnabled: true, + }, + metadata: { jobId: 3, userId: 'u1' }, + }, + ], + destType: 'hs', + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/crm/v3/objects/lead/batch/create', + headers: { 'Content-Type': 'application/json' }, + params: { hapikey: 'dummy-apikey' }, + body: { + JSON: { + inputs: [ + { + properties: { + firstname: 'Test Hubspot 1', + anonymousId: '123451', + country: 'India 1', + email: 'testhubspot@email.com', + }, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [{ jobId: 3, userId: 'u1' }], + batched: true, + statusCode: 200, + destination: { + Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, + secretConfig: {}, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + name: 'Hubspot', + enabled: true, + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + deleted: false, + createdAt: '2020-12-30T08:39:32.005Z', + updatedAt: '2021-02-03T16:22:31.374Z', + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + displayName: 'Hubspot', + createdAt: '2020-04-09T09:24:31.794Z', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + transformations: [], + isConnectionEnabled: true, + isProcessorEnabled: true, + }, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/crm/v3/objects/lead/batch/update', + headers: { 'Content-Type': 'application/json' }, + params: { hapikey: 'dummy-apikey' }, + body: { + JSON: { + inputs: [ + { + properties: { + firstname: 'Test Hubspot', + anonymousId: '12345', + country: 'India', + email: 'testhubspot2@email.com', + }, + id: '103605', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [{ jobId: 2, userId: 'u1' }], + batched: true, + statusCode: 200, + destination: { + Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, + secretConfig: {}, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + name: 'Hubspot', + enabled: true, + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + deleted: false, + createdAt: '2020-12-30T08:39:32.005Z', + updatedAt: '2021-02-03T16:22:31.374Z', + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + displayName: 'Hubspot', + createdAt: '2020-04-09T09:24:31.794Z', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + transformations: [], + isConnectionEnabled: true, + isProcessorEnabled: true, + }, + }, + ], + }, + }, + }, + }, { name: 'hs', description: 'legacy router tests', @@ -299,7 +529,7 @@ export const data = [ }, metadata: { jobId: 4, userId: 'u1' }, destination: { - Config: { apiKey: 'rate-limit-id', hubID: 'dummy-hubId' }, + Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, secretConfig: {}, ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', name: 'Hubspot', @@ -343,18 +573,14 @@ export const data = [ JSON: {}, JSON_ARRAY: { batch: - '[{"email":"testhubspot3@email.com","properties":[{"property":"firstname","value":"Test Hubspot3"}]},{"email":"testhubspot1@email.com","properties":[{"property":"firstname","value":"Test Hubspot1"}]},{"email":"testhubspot4@email.com","properties":[{"property":"firstname","value":"Test Hubspot4"}]}]', + '[{"email":"testhubspot1@email.com","properties":[{"property":"firstname","value":"Test Hubspot1"}]}]', }, XML: {}, FORM: {}, }, files: {}, }, - metadata: [ - { jobId: 3, userId: 'u1' }, - { jobId: 1, userId: 'u1' }, - { jobId: 4, userId: 'u1' }, - ], + metadata: [{ jobId: 1, userId: 'u1' }], batched: true, statusCode: 200, destination: { @@ -420,152 +646,20 @@ export const data = [ isProcessorEnabled: true, }, }, - ], - }, - }, - }, - }, - { - name: 'hs', - description: 'legacy router retl tests', - feature: 'router', - module: 'destination', - version: 'v0', - input: { - request: { - body: { - input: [ - { - message: { - channel: 'web', - context: { - mappedToDestination: true, - externalId: [ - { identifierType: 'email', id: 'testhubspot2@email.com', type: 'HS-lead' }, - ], - sources: { - job_id: '24c5HJxHomh6YCngEOCgjS5r1KX/Syncher', - task_id: 'vw_rs_mailchimp_mocked_hg_data', - version: 'v1.8.1', - batch_id: 'f252c69d-c40d-450e-bcd2-2cf26cb62762', - job_run_id: 'c8el40l6e87v0c4hkbl0', - task_run_id: 'c8el40l6e87v0c4hkblg', - }, - }, - type: 'identify', - traits: { firstname: 'Test Hubspot', anonymousId: '12345', country: 'India' }, - messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', - originalTimestamp: '2019-10-15T09:35:31.288Z', - anonymousId: '00000000000000000000000000', - userId: '12345', - integrations: { All: true }, - sentAt: '2019-10-14T09:03:22.563Z', - }, - destination: { - Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, - secretConfig: {}, - ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', - name: 'Hubspot', - enabled: true, - workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', - deleted: false, - createdAt: '2020-12-30T08:39:32.005Z', - updatedAt: '2021-02-03T16:22:31.374Z', - destinationDefinition: { - id: '1aIXqM806xAVm92nx07YwKbRrO9', - name: 'HS', - displayName: 'Hubspot', - createdAt: '2020-04-09T09:24:31.794Z', - updatedAt: '2021-01-11T11:03:28.103Z', - }, - transformations: [], - isConnectionEnabled: true, - isProcessorEnabled: true, - }, - metadata: { jobId: 2, userId: 'u1' }, - }, - { - message: { - channel: 'web', - context: { - mappedToDestination: true, - externalId: [ - { identifierType: 'email', id: 'testhubspot@email.com', type: 'HS-lead' }, - ], - sources: { - job_id: '24c5HJxHomh6YCngEOCgjS5r1KX/Syncher', - task_id: 'vw_rs_mailchimp_mocked_hg_data', - version: 'v1.8.1', - batch_id: 'f252c69d-c40d-450e-bcd2-2cf26cb62762', - job_run_id: 'c8el40l6e87v0c4hkbl0', - task_run_id: 'c8el40l6e87v0c4hkblg', - }, - }, - type: 'identify', - traits: { firstname: 'Test Hubspot 1', anonymousId: '123451', country: 'India 1' }, - messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', - originalTimestamp: '2019-10-15T09:35:31.288Z', - anonymousId: '00000000000000000000000000', - userId: '12345', - integrations: { All: true }, - sentAt: '2019-10-14T09:03:22.563Z', - }, - destination: { - Config: { apiKey: 'dummy-apikey', hubID: 'dummy-hubId' }, - secretConfig: {}, - ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', - name: 'Hubspot', - enabled: true, - workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', - deleted: false, - createdAt: '2020-12-30T08:39:32.005Z', - updatedAt: '2021-02-03T16:22:31.374Z', - destinationDefinition: { - id: '1aIXqM806xAVm92nx07YwKbRrO9', - name: 'HS', - displayName: 'Hubspot', - createdAt: '2020-04-09T09:24:31.794Z', - updatedAt: '2021-01-11T11:03:28.103Z', - }, - transformations: [], - isConnectionEnabled: true, - isProcessorEnabled: true, - }, - metadata: { jobId: 3, userId: 'u1' }, - }, - ], - destType: 'hs', - }, - method: 'POST', - }, - }, - output: { - response: { - status: 200, - body: { - output: [ { batchedRequest: { version: '1', type: 'REST', method: 'POST', - endpoint: 'https://api.hubapi.com/crm/v3/objects/lead/batch/create', + endpoint: 'https://api.hubapi.com/contacts/v1/contact/batch/', headers: { 'Content-Type': 'application/json' }, params: { hapikey: 'dummy-apikey' }, body: { - JSON: { - inputs: [ - { - properties: { - firstname: 'Test Hubspot 1', - anonymousId: '123451', - country: 'India 1', - email: 'testhubspot@email.com', - }, - }, - ], + JSON: {}, + JSON_ARRAY: { + batch: + '[{"email":"testhubspot3@email.com","properties":[{"property":"firstname","value":"Test Hubspot3"}]}]', }, - JSON_ARRAY: {}, XML: {}, FORM: {}, }, @@ -601,30 +695,21 @@ export const data = [ version: '1', type: 'REST', method: 'POST', - endpoint: 'https://api.hubapi.com/crm/v3/objects/lead/batch/update', + endpoint: 'https://api.hubapi.com/contacts/v1/contact/batch/', headers: { 'Content-Type': 'application/json' }, params: { hapikey: 'dummy-apikey' }, body: { - JSON: { - inputs: [ - { - properties: { - firstname: 'Test Hubspot', - anonymousId: '12345', - country: 'India', - email: 'testhubspot2@email.com', - }, - id: '103605', - }, - ], + JSON: {}, + JSON_ARRAY: { + batch: + '[{"email":"testhubspot4@email.com","properties":[{"property":"firstname","value":"Test Hubspot4"}]}]', }, - JSON_ARRAY: {}, XML: {}, FORM: {}, }, files: {}, }, - metadata: [{ jobId: 2, userId: 'u1' }], + metadata: [{ jobId: 4, userId: 'u1' }], batched: true, statusCode: 200, destination: { @@ -1280,21 +1365,37 @@ export const data = [ }, { message: { - type: 'track', - traits: {}, + channel: 'web', context: { - externalId: [ - { - id: 'osvaldocostaferreira98@gmail.com', - type: 'HS-contacts', - identifierType: 'email', - }, - ], + app: { + build: '1.0.0', + name: 'RudderLabs JavaScript SDK', + namespace: 'com.rudderlabs.javascript', + version: '1.0.0', + }, + traits: { + email: 'testhubspot@email.com', + firstname: 'Test Hubspot22', + anonymousId: '4444', + }, + library: { name: 'RudderLabs JavaScript SDK', version: '1.0.0' }, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36', + locale: 'en-GB', + ip: '0.0.0.0', + os: { name: '', version: '' }, + screen: { density: 2 }, + page: { path: '', referrer: '', search: '', title: '', url: '' }, }, - event: 'Purchase', - properties: { Revenue: 'name1' }, + type: 'identify', + messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', + originalTimestamp: '2019-10-15T09:35:31.288Z', + anonymousId: '00000000000000000000000000', + userId: '12345', + integrations: { All: true }, + sentAt: '2019-10-14T09:03:22.563Z', }, - metadata: { jobId: 3, userId: 'u1' }, + metadata: { jobId: 4, userId: 'u1' }, destination: { Config: { authorizationType: 'newPrivateAppApi', @@ -1302,7 +1403,7 @@ export const data = [ hubID: 'dummy-hubId', apiKey: 'dummy-apikey', apiVersion: 'newApi', - lookupField: 'lookupField', + lookupField: 'email', hubspotEvents: [ { rsEventName: 'Purchase', @@ -1357,7 +1458,7 @@ export const data = [ }, traits: { email: 'testhubspot@email.com', - firstname: 'Test Hubspot22', + firstname: 'Test Hubspot44', anonymousId: '4444', }, library: { name: 'RudderLabs JavaScript SDK', version: '1.0.0' }, @@ -1377,7 +1478,7 @@ export const data = [ integrations: { All: true }, sentAt: '2019-10-14T09:03:22.563Z', }, - metadata: { jobId: 4, userId: 'u1' }, + metadata: { jobId: 5, userId: 'u1' }, destination: { Config: { authorizationType: 'newPrivateAppApi', @@ -1430,37 +1531,21 @@ export const data = [ }, { message: { - channel: 'web', + type: 'track', + traits: {}, context: { - app: { - build: '1.0.0', - name: 'RudderLabs JavaScript SDK', - namespace: 'com.rudderlabs.javascript', - version: '1.0.0', - }, - traits: { - email: 'testhubspot@email.com', - firstname: 'Test Hubspot44', - anonymousId: '4444', - }, - library: { name: 'RudderLabs JavaScript SDK', version: '1.0.0' }, - userAgent: - 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36', - locale: 'en-GB', - ip: '0.0.0.0', - os: { name: '', version: '' }, - screen: { density: 2 }, - page: { path: '', referrer: '', search: '', title: '', url: '' }, + externalId: [ + { + id: 'osvaldocostaferreira98@gmail.com', + type: 'HS-contacts', + identifierType: 'email', + }, + ], }, - type: 'identify', - messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', - originalTimestamp: '2019-10-15T09:35:31.288Z', - anonymousId: '00000000000000000000000000', - userId: '12345', - integrations: { All: true }, - sentAt: '2019-10-14T09:03:22.563Z', + event: 'Purchase', + properties: { Revenue: 'name1' }, }, - metadata: { jobId: 5, userId: 'u1' }, + metadata: { jobId: 3, userId: 'u1' }, destination: { Config: { authorizationType: 'newPrivateAppApi', @@ -1468,7 +1553,7 @@ export const data = [ hubID: 'dummy-hubId', apiKey: 'dummy-apikey', apiVersion: 'newApi', - lookupField: 'email', + lookupField: 'lookupField', hubspotEvents: [ { rsEventName: 'Purchase', @@ -1639,7 +1724,7 @@ export const data = [ hubID: 'dummy-hubId', apiKey: 'dummy-apikey', apiVersion: 'newApi', - lookupField: 'email', + lookupField: 'lookupField', hubspotEvents: [ { rsEventName: 'Purchase', @@ -1828,4 +1913,1698 @@ export const data = [ }, }, }, + { + name: 'hs', + description: 'if dontBatch is true we are not going to create a batch out of those events', + feature: 'router', + module: 'destination', + version: 'v0', + scenario: 'buisness', + id: 'dontbatchtrue', + successCriteria: + 'should not create a batch with the events if that events contains dontBatch true', + input: { + request: { + body: { + input: [ + { + message: { + type: 'identify', + sentAt: '2024-05-23T16:49:57.461+05:30', + userId: 'sample_user_id425', + channel: 'mobile', + context: { + traits: { + age: '30', + name: 'John Sparrow', + email: 'identify425@test.com', + phone: '9112340425', + lastname: 'Sparrow', + firstname: 'John', + }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + timestamp: '2024-05-23T16:49:57.070+05:30', + receivedAt: '2024-05-23T16:49:57.071+05:30', + anonymousId: '8d872292709c6fbe', + }, + metadata: { + jobId: 1, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + dontBatch: true, + }, + destination: { + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + Name: 'hs-1', + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + Transformations: [], + IsProcessorEnabled: true, + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + }, + request: { + query: {}, + }, + }, + { + message: { + type: 'identify', + sentAt: '2024-05-23T16:49:57.461+05:30', + userId: 'sample_user_id738', + channel: 'mobile', + context: { + traits: { + age: '30', + name: 'John Sparrow738', + email: 'identify425@test.con', + phone: '9112340738', + lastname: 'Sparrow738', + firstname: 'John', + }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + timestamp: '2024-05-23T16:49:57.071+05:30', + anonymousId: '8d872292709c6fbe738', + }, + metadata: { + userId: '<<>>8d872292709c6fbe738<<>>sample_user_id738', + jobId: 2, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + workerAssignedTime: '2024-05-23T16:49:58.569269+05:30', + dontBatch: true, + }, + destination: { + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + Name: 'hs-1', + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + Transformations: [], + IsProcessorEnabled: true, + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + }, + request: { + query: {}, + }, + }, + { + message: { + type: 'identify', + sentAt: '2024-05-23T16:49:57.462+05:30', + userId: 'sample_user_id803', + channel: 'mobile', + context: { + traits: { + age: '30', + name: 'John Sparrow803', + email: 'identify803@test.com', + phone: '9112340803', + lastname: 'Sparrow803', + firstname: 'John', + }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + anonymousId: '8d872292709c6fbe803', + originalTimestamp: '2024-05-23T16:49:57.462+05:30', + }, + metadata: { + userId: '<<>>8d872292709c6fbe803<<>>sample_user_id803', + jobId: 3, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + destination: { + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + Name: 'hs-1', + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + Transformations: [], + IsProcessorEnabled: true, + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + }, + request: { + query: {}, + }, + }, + { + message: { + type: 'identify', + sentAt: '2024-05-23T16:49:57.462+05:30', + userId: 'sample_user_id804', + channel: 'mobile', + context: { + traits: { + age: '30', + name: 'John Sparrow804', + email: 'identify804@test.con', + phone: '9112340804', + lastname: 'Sparrow804', + firstname: 'John', + }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + anonymousId: '8d872292709c6fbe804', + originalTimestamp: '2024-05-23T16:49:57.462+05:30', + }, + metadata: { + userId: '<<>>8d872292709c6fbe804<<>>sample_user_id804', + jobId: 4, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + dontBatch: false, + }, + destination: { + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + Name: 'hs-1', + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + Transformations: [], + IsProcessorEnabled: true, + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + }, + request: { + query: {}, + }, + }, + ], + destType: 'hs', + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batched: true, + batchedRequest: { + body: { + FORM: {}, + JSON: { + inputs: [ + { + properties: { + email: 'identify803@test.com', + firstname: 'John', + lastname: 'Sparrow803', + phone: '9112340803', + }, + }, + { + properties: { + email: 'identify804@test.con', + firstname: 'John', + lastname: 'Sparrow804', + phone: '9112340804', + }, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/create', + files: {}, + headers: { + Authorization: 'Bearer dontbatchtrueaccesstoken', + 'Content-Type': 'application/json', + }, + method: 'POST', + params: {}, + type: 'REST', + version: '1', + }, + destination: { + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + IsProcessorEnabled: true, + Name: 'hs-1', + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + Transformations: [], + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + metadata: [ + { + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + jobId: 3, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + transformAt: 'router', + userId: '<<>>8d872292709c6fbe803<<>>sample_user_id803', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + { + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + dontBatch: false, + jobId: 4, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + transformAt: 'router', + userId: '<<>>8d872292709c6fbe804<<>>sample_user_id804', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + ], + statusCode: 200, + }, + { + batched: false, + batchedRequest: { + body: { + FORM: {}, + JSON: { + properties: { + email: 'identify425@test.com', + firstname: 'John', + lastname: 'Sparrow', + phone: '9112340425', + }, + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts', + files: {}, + headers: { + Authorization: 'Bearer dontbatchtrueaccesstoken', + 'Content-Type': 'application/json', + }, + method: 'POST', + params: {}, + type: 'REST', + version: '1', + }, + destination: { + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + IsProcessorEnabled: true, + Name: 'hs-1', + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + Transformations: [], + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + metadata: [ + { + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + dontBatch: true, + jobId: 1, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + ], + statusCode: 200, + }, + { + batched: false, + batchedRequest: { + body: { + FORM: {}, + JSON: { + properties: { + email: 'identify425@test.con', + firstname: 'John', + lastname: 'Sparrow738', + phone: '9112340738', + }, + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts', + files: {}, + headers: { + Authorization: 'Bearer dontbatchtrueaccesstoken', + 'Content-Type': 'application/json', + }, + method: 'POST', + params: {}, + type: 'REST', + version: '1', + }, + destination: { + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + IsProcessorEnabled: true, + Name: 'hs-1', + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + Transformations: [], + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + metadata: [ + { + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + dontBatch: true, + jobId: 2, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + transformAt: 'router', + userId: '<<>>8d872292709c6fbe738<<>>sample_user_id738', + workerAssignedTime: '2024-05-23T16:49:58.569269+05:30', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + ], + statusCode: 200, + }, + ], + }, + }, + }, + }, + { + name: 'hs', + description: 'if dontBatch is not available we are considering those as dontbatch false', + feature: 'router', + module: 'destination', + version: 'v0', + scenario: 'buisness', + id: 'dontbatchundefined', + successCriteria: 'all events should be batched', + input: { + request: { + body: { + input: [ + { + message: { + type: 'identify', + sentAt: '2024-05-23T16:49:57.461+05:30', + userId: 'sample_user_id425', + channel: 'mobile', + context: { + traits: { + age: '30', + name: 'John Sparrow', + email: 'identify425@test.com', + phone: '9112340425', + lastname: 'Sparrow', + firstname: 'John', + }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + timestamp: '2024-05-23T16:49:57.070+05:30', + receivedAt: '2024-05-23T16:49:57.071+05:30', + anonymousId: '8d872292709c6fbe', + }, + metadata: { + jobId: 1, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + destination: { + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + Name: 'hs-1', + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + Transformations: [], + IsProcessorEnabled: true, + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + }, + request: { + query: {}, + }, + }, + { + message: { + type: 'identify', + sentAt: '2024-05-23T16:49:57.461+05:30', + userId: 'sample_user_id738', + channel: 'mobile', + context: { + traits: { + age: '30', + name: 'John Sparrow738', + email: 'identify425@test.con', + phone: '9112340738', + lastname: 'Sparrow738', + firstname: 'John', + }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + timestamp: '2024-05-23T16:49:57.071+05:30', + anonymousId: '8d872292709c6fbe738', + }, + metadata: { + userId: '<<>>8d872292709c6fbe738<<>>sample_user_id738', + jobId: 2, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + workerAssignedTime: '2024-05-23T16:49:58.569269+05:30', + }, + destination: { + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + Name: 'hs-1', + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + Transformations: [], + IsProcessorEnabled: true, + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + }, + request: { + query: {}, + }, + }, + ], + destType: 'hs', + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batched: true, + batchedRequest: { + body: { + FORM: {}, + JSON: { + inputs: [ + { + properties: { + email: 'identify425@test.com', + firstname: 'John', + lastname: 'Sparrow', + phone: '9112340425', + }, + }, + { + properties: { + email: 'identify425@test.con', + firstname: 'John', + lastname: 'Sparrow738', + phone: '9112340738', + }, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/create', + files: {}, + headers: { + Authorization: 'Bearer dontbatchtrueaccesstoken', + 'Content-Type': 'application/json', + }, + method: 'POST', + params: {}, + type: 'REST', + version: '1', + }, + destination: { + Config: { + accessToken: 'dontbatchtrueaccesstoken', + apiKey: '', + apiVersion: 'newApi', + authorizationType: 'newPrivateAppApi', + blacklistedEvents: [], + connectionMode: 'cloud', + doAssociation: false, + eventDelivery: false, + eventDeliveryTS: 1687884567403, + eventFilteringOption: 'disable', + hubID: '25092171', + hubspotEvents: [ + { + eventProperties: [ + { + from: 'first_name', + to: 'first_name', + }, + { + from: 'last_name', + to: 'last_name', + }, + ], + hubspotEventName: 'pedummy-hubId_rs_hub_chair', + rsEventName: 'Order Complete', + }, + ], + ketchConsentPurposes: [ + { + purpose: '', + }, + ], + lookupField: 'email', + oneTrustCookieCategories: [], + useNativeSDK: false, + whitelistedEvents: [], + }, + Enabled: true, + ID: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + IsProcessorEnabled: true, + Name: 'hs-1', + RevisionID: '2gqf7Mc7WEwqQtQy3G105O22s3D', + Transformations: [], + WorkspaceID: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + metadata: [ + { + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + jobId: 1, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + transformAt: 'router', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + { + destinationId: '2RnSBhn4zPTOF8NdqAIrnVPPnfr', + jobId: 2, + sourceId: '2RnN36pc7p5lzoApxZnDfRnYFx0', + transformAt: 'router', + userId: '<<>>8d872292709c6fbe738<<>>sample_user_id738', + workerAssignedTime: '2024-05-23T16:49:58.569269+05:30', + workspaceId: '2QapBTEvZYwuf6O9KB5AEvvBt8j', + }, + ], + statusCode: 200, + }, + ], + }, + }, + }, + }, + { + name: 'hs', + description: 'router job ordering ', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + channel: 'web', + context: { + traits: { + email: 'testhubspot1@email.com', + firstname: 'Test Hubspot1', + }, + }, + type: 'identify', + userId: 'user1', + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + jobId: 1, + userId: 'user1', + }, + destination, + }, + { + message: { + channel: 'web', + context: { + traits: { email: 'user1@a.com' }, + }, + type: 'track', + anonymousId: '', + userId: 'user1', + event: 'purchase', + properties: { + user_actual_role: 'system_admin, system_user', + user_actual_id: 12345, + }, + sentAt: '2019-10-14T11:15:53.296Z', + }, + metadata: { + jobId: 2, + userId: 'user1', + }, + destination, + }, + { + message: { + channel: 'web', + context: { traits: { email: 'user2@a.com' } }, + type: 'track', + anonymousId: '', + userId: 'user2', + event: 'purchase2', + properties: { + user_actual_role: 'system_admin_2, system_user', + user_actual_id: 12345, + }, + sentAt: '2019-10-14T11:15:53.296Z', + }, + metadata: { + jobId: 3, + userId: 'user2', + }, + destination, + }, + { + message: { + channel: 'web', + context: { + traits: { + email: 'testhubspot2@email.com', + firstname: 'Test Hubspot1', + anonymousId: '1111', + }, + }, + type: 'identify', + anonymousId: '', + userId: 'user2', + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + jobId: 4, + userId: 'user2', + }, + destination, + }, + { + message: { + channel: 'web', + context: { traits: { email: 'user3@a.com' } }, + type: 'track', + anonymousId: '', + userId: 'user3', + event: 'purchase', + properties: { + user_actual_role: 'system_admin, system_user', + user_actual_id: 12345, + }, + sentAt: '2019-10-14T11:15:53.296Z', + }, + metadata: { + jobId: 5, + userId: 'user3', + }, + destination, + }, + { + message: { + channel: 'web', + context: { + traits: { + email: 'testhubspot3@email.com', + firstname: 'Test Hubspot1', + anonymousId: '1111', + }, + }, + type: 'identify', + anonymousId: '', + userId: 'user3', + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + jobId: 6, + userId: 'user3', + }, + destination, + }, + { + message: { + channel: 'web', + context: { traits: { email: 'user4@a.com' } }, + type: 'track', + anonymousId: '', + userId: 'user4', + event: 'purchase', + properties: { + user_actual_role: 'system_admin, system_user', + user_actual_id: 12345, + }, + sentAt: '2019-10-14T11:15:53.296Z', + }, + metadata: { + jobId: 7, + userId: 'user4', + }, + destination, + }, + { + message: { + channel: 'web', + context: { + traits: { + email: 'testhubspot4@email.com', + firstname: 'Test Hubspot4', + anonymousId: '1111', + }, + }, + type: 'identify', + anonymousId: '', + userId: 'user4', + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + jobId: 8, + userId: 'user4', + }, + destination, + }, + { + message: { + channel: 'web', + context: { + traits: { + email: 'testhubspot5@email.com', + firstname: 'Test Hubspot51', + anonymousId: '1111', + }, + }, + type: 'identify', + anonymousId: '', + userId: 'user5', + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + jobId: 9, + userId: 'user5', + }, + destination, + }, + { + message: { + channel: 'web', + context: { traits: { email: 'user5@a.com' } }, + type: 'track', + anonymousId: '', + userId: 'user5', + event: 'purchase', + properties: { + user_actual_role: 'system_admin, system_user', + user_actual_id: 12345, + }, + sentAt: '2019-10-14T11:15:53.296Z', + }, + metadata: { + jobId: 10, + userId: 'user5', + }, + destination, + }, + { + message: { + channel: 'web', + context: { + traits: { + email: 'testhubspot5@email.com', + firstname: 'Test Hubspot5', + anonymousId: '1111', + }, + }, + type: 'identify', + anonymousId: '', + userId: 'user5', + integrations: { + All: true, + }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + metadata: { + jobId: 11, + userId: 'user5', + }, + destination, + }, + ], + destType: 'hs', + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/create', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + inputs: [ + { + properties: { + email: 'testhubspot1@email.com', + firstname: 'Test Hubspot1', + }, + }, + { + properties: { + email: 'testhubspot5@email.com', + firstname: 'Test Hubspot51', + }, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'user1', + }, + { + jobId: 9, + userId: 'user5', + }, + ], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/events/v3/send', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + email: 'user1@a.com', + eventName: 'pedummy-hubId_rs_hub_test', + properties: {}, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 2, + userId: 'user1', + }, + ], + batched: false, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/events/v3/send', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + email: 'user2@a.com', + eventName: 'pedummy-hubId_rs_hub_test', + properties: {}, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 3, + userId: 'user2', + }, + ], + batched: false, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/events/v3/send', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + email: 'user3@a.com', + eventName: 'pedummy-hubId_rs_hub_test', + properties: {}, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 5, + userId: 'user3', + }, + ], + batched: false, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/events/v3/send', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + email: 'user4@a.com', + eventName: 'pedummy-hubId_rs_hub_test', + properties: {}, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 7, + userId: 'user4', + }, + ], + batched: false, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/events/v3/send', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + email: 'user5@a.com', + eventName: 'pedummy-hubId_rs_hub_test', + properties: {}, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 10, + userId: 'user5', + }, + ], + batched: false, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.hubapi.com/crm/v3/objects/contacts/batch/create', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer dummy-access-token', + }, + params: {}, + body: { + JSON: { + inputs: [ + { + properties: { + email: 'testhubspot2@email.com', + firstname: 'Test Hubspot1', + }, + }, + { + properties: { + email: 'testhubspot3@email.com', + firstname: 'Test Hubspot1', + }, + }, + { + properties: { + email: 'testhubspot4@email.com', + firstname: 'Test Hubspot4', + }, + }, + { + properties: { + email: 'testhubspot5@email.com', + firstname: 'Test Hubspot5', + }, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 4, + userId: 'user2', + }, + { + jobId: 6, + userId: 'user3', + }, + { + jobId: 8, + userId: 'user4', + }, + { + jobId: 11, + userId: 'user5', + }, + ], + batched: true, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, + { + name: 'hs', + description: 'test when get properties call failed', + feature: 'router', + module: 'destination', + id: 'routerGetPropertiesCallFailed', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + channel: 'web', + context: { + mappedToDestination: true, + externalId: [ + { identifierType: 'email', id: 'testhubspot2@email.com', type: 'HS-lead' }, + ], + sources: { + job_id: '24c5HJxHomh6YCngEOCgjS5r1KX/Syncher', + task_id: 'vw_rs_mailchimp_mocked_hg_data', + version: 'v1.8.1', + batch_id: 'f252c69d-c40d-450e-bcd2-2cf26cb62762', + job_run_id: 'c8el40l6e87v0c4hkbl0', + task_run_id: 'c8el40l6e87v0c4hkblg', + }, + }, + type: 'identify', + traits: { firstname: 'Test Hubspot', anonymousId: '12345', country: 'India' }, + messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', + originalTimestamp: '2019-10-15T09:35:31.288Z', + anonymousId: '00000000000000000000000000', + userId: '12345', + integrations: { All: true }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + destination: { + Config: { apiKey: 'invalid-api-key', hubID: 'dummy-hubId' }, + secretConfig: {}, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + name: 'Hubspot', + enabled: true, + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + deleted: false, + createdAt: '2020-12-30T08:39:32.005Z', + updatedAt: '2021-02-03T16:22:31.374Z', + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + displayName: 'Hubspot', + createdAt: '2020-04-09T09:24:31.794Z', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + transformations: [], + isConnectionEnabled: true, + isProcessorEnabled: true, + }, + metadata: { jobId: 2, userId: 'u1' }, + }, + { + message: { + channel: 'web', + context: { + mappedToDestination: true, + externalId: [ + { identifierType: 'email', id: 'testhubspot@email.com', type: 'HS-lead' }, + ], + sources: { + job_id: '24c5HJxHomh6YCngEOCgjS5r1KX/Syncher', + task_id: 'vw_rs_mailchimp_mocked_hg_data', + version: 'v1.8.1', + batch_id: 'f252c69d-c40d-450e-bcd2-2cf26cb62762', + job_run_id: 'c8el40l6e87v0c4hkbl0', + task_run_id: 'c8el40l6e87v0c4hkblg', + }, + }, + type: 'identify', + traits: { firstname: 'Test Hubspot 1', anonymousId: '123451', country: 'India 1' }, + messageId: '50360b9c-ea8d-409c-b672-c9230f91cce5', + originalTimestamp: '2019-10-15T09:35:31.288Z', + anonymousId: '00000000000000000000000000', + userId: '12345', + integrations: { All: true }, + sentAt: '2019-10-14T09:03:22.563Z', + }, + destination: { + Config: { apiKey: 'invalid-api-key', hubID: 'dummy-hubId' }, + secretConfig: {}, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + name: 'Hubspot', + enabled: true, + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + deleted: false, + createdAt: '2020-12-30T08:39:32.005Z', + updatedAt: '2021-02-03T16:22:31.374Z', + destinationDefinition: { + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + displayName: 'Hubspot', + createdAt: '2020-04-09T09:24:31.794Z', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + transformations: [], + isConnectionEnabled: true, + isProcessorEnabled: true, + }, + metadata: { jobId: 3, userId: 'u1' }, + }, + ], + destType: 'hs', + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batched: false, + destination: { + Config: { + apiKey: 'invalid-api-key', + hubID: 'dummy-hubId', + }, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + createdAt: '2020-12-30T08:39:32.005Z', + deleted: false, + destinationDefinition: { + createdAt: '2020-04-09T09:24:31.794Z', + displayName: 'Hubspot', + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + enabled: true, + isConnectionEnabled: true, + isProcessorEnabled: true, + name: 'Hubspot', + secretConfig: {}, + transformations: [], + updatedAt: '2021-02-03T16:22:31.374Z', + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + }, + error: + '{"message":"Failed to get hubspot properties: {\\"status\\":\\"error\\",\\"message\\":\\"The API key provided is invalid. View or manage your API key here: https://app.hubspot.com/l/api-key/\\",\\"correlationId\\":\\"4d39ff11-e121-4514-bcd8-132a9dd1ff50\\",\\"category\\":\\"INVALID_AUTHENTICATION\\",\\"links\\":{\\"api key\\":\\"https://app.hubspot.com/l/api-key/\\"}}","destinationResponse":{"response":{"status":"error","message":"The API key provided is invalid. View or manage your API key here: https://app.hubspot.com/l/api-key/","correlationId":"4d39ff11-e121-4514-bcd8-132a9dd1ff50","category":"INVALID_AUTHENTICATION","links":{"api key":"https://app.hubspot.com/l/api-key/"}},"status":401}}', + metadata: [ + { + jobId: 2, + userId: 'u1', + }, + ], + statTags: { + destType: 'HS', + errorCategory: 'network', + errorType: 'aborted', + feature: 'router', + implementation: 'native', + module: 'destination', + }, + statusCode: 401, + }, + { + batched: false, + destination: { + Config: { + apiKey: 'invalid-api-key', + hubID: 'dummy-hubId', + }, + ID: '1mMy5cqbtfuaKZv1IhVQKnBdVwe', + createdAt: '2020-12-30T08:39:32.005Z', + deleted: false, + destinationDefinition: { + createdAt: '2020-04-09T09:24:31.794Z', + displayName: 'Hubspot', + id: '1aIXqM806xAVm92nx07YwKbRrO9', + name: 'HS', + updatedAt: '2021-01-11T11:03:28.103Z', + }, + enabled: true, + isConnectionEnabled: true, + isProcessorEnabled: true, + name: 'Hubspot', + secretConfig: {}, + transformations: [], + updatedAt: '2021-02-03T16:22:31.374Z', + workspaceId: '1TSN08muJTZwH8iCDmnnRt1pmLd', + }, + error: + '{"message":"Failed to get hubspot properties: {\\"status\\":\\"error\\",\\"message\\":\\"The API key provided is invalid. View or manage your API key here: https://app.hubspot.com/l/api-key/\\",\\"correlationId\\":\\"4d39ff11-e121-4514-bcd8-132a9dd1ff50\\",\\"category\\":\\"INVALID_AUTHENTICATION\\",\\"links\\":{\\"api key\\":\\"https://app.hubspot.com/l/api-key/\\"}}","destinationResponse":{"response":{"status":"error","message":"The API key provided is invalid. View or manage your API key here: https://app.hubspot.com/l/api-key/","correlationId":"4d39ff11-e121-4514-bcd8-132a9dd1ff50","category":"INVALID_AUTHENTICATION","links":{"api key":"https://app.hubspot.com/l/api-key/"}},"status":401}}', + metadata: [ + { + jobId: 3, + userId: 'u1', + }, + ], + statTags: { + destType: 'HS', + errorCategory: 'network', + errorType: 'aborted', + feature: 'router', + implementation: 'native', + module: 'destination', + }, + statusCode: 401, + }, + ], + }, + }, + }, + }, ]; diff --git a/test/integrations/destinations/intercom/network.ts b/test/integrations/destinations/intercom/network.ts index d98e447824..2f90beac40 100644 --- a/test/integrations/destinations/intercom/network.ts +++ b/test/integrations/destinations/intercom/network.ts @@ -959,5 +959,87 @@ const deliveryCallsData = [ }, }, }, + { + httpReq: { + method: 'get', + url: 'https://api.eu.intercom.io/companies?company_id=company id', + data: {}, + headers: commonHeaders, + }, + httpRes: { + status: 200, + data: { + id: '123', + }, + }, + }, + { + httpReq: { + method: 'delete', + url: 'https://api.eu.intercom.io/contacts/70701240741e45d040/companies/123', + data: {}, + headers: commonHeaders, + }, + httpRes: { + status: 200, + data: {}, + }, + }, + { + httpReq: { + method: 'get', + url: 'https://api.eu.intercom.io/companies?company_id=unavailable company id', + data: {}, + headers: commonHeaders, + }, + httpRes: { + status: 404, + data: { + type: 'error.list', + request_id: 'req123', + errors: [ + { + code: 'company_not_found', + message: 'Company Not Found', + }, + ], + }, + }, + }, + { + httpReq: { + method: 'get', + url: 'https://api.eu.intercom.io/companies?company_id=other company id', + data: {}, + headers: commonHeaders, + }, + httpRes: { + status: 200, + data: { + id: 'other123', + }, + }, + }, + { + httpReq: { + method: 'delete', + url: 'https://api.eu.intercom.io/contacts/70701240741e45d040/companies/other123', + data: {}, + headers: commonHeaders, + }, + httpRes: { + status: 404, + data: { + type: 'error.list', + request_id: 'req123', + errors: [ + { + code: 'company_not_found', + message: 'Company Not Found', + }, + ], + }, + }, + }, ]; export const networkCallsData = [...deleteNwData, ...deliveryCallsData]; diff --git a/test/integrations/destinations/intercom/router/data.ts b/test/integrations/destinations/intercom/router/data.ts index 17245fb65b..cc89d3f1e2 100644 --- a/test/integrations/destinations/intercom/router/data.ts +++ b/test/integrations/destinations/intercom/router/data.ts @@ -466,6 +466,78 @@ const routerRequest2: RouterTransformationRequest = { }, metadata: generateMetadata(3), }, + { + destination: destination4, + message: { + anonymousId: '58b21c2d-f8d5-4410-a2d0-b268a26b7e33', + channel: 'mobile', + context: { + app: { + build: '1.0', + name: 'Test_Example', + namespace: 'com.example.testapp', + version: '1.0', + }, + device: { + id: '58b21c2d-f8d5-4410-a2d0-b268a26b7e33', + manufacturer: 'Apple', + model: 'iPhone', + name: 'iPod touch (7th generation)', + type: 'iOS', + }, + library: { + name: 'test-ios-library', + version: '1.0.7', + }, + locale: 'en-US', + network: { + bluetooth: false, + carrier: 'unavailable', + cellular: false, + wifi: true, + }, + os: { + name: 'iOS', + version: '14.0', + }, + screen: { + density: 2, + height: 320, + width: 568, + }, + timezone: 'Asia/Kolkata', + traits: { + anonymousId: '58b21c2d-f8d5-4410-a2d0-b268a26b7e33', + name: 'Test Name', + firstName: 'Test', + lastName: 'Name', + createdAt: '2020-09-30T19:11:00.337Z', + userId: 'test_user_id_1', + email: 'test_1@test.com', + phone: '9876543210', + key1: 'value1', + company: { + id: 'company id', + name: 'Test Company', + remove: true, + }, + }, + userAgent: 'unknown', + }, + event: 'Test Event 2', + integrations: { + All: true, + }, + messageId: '1601493060-39010c49-e6e4-4626-a75c-0dbf1925c9e8', + originalTimestamp: '2020-09-30T19:11:00.337Z', + receivedAt: '2020-10-01T00:41:11.369+05:30', + request_ip: '2405:201:8005:9856:7911:25e7:5603:5e18', + sentAt: '2020-09-30T19:11:10.382Z', + timestamp: '2020-10-01T00:41:01.324+05:30', + type: 'identify', + }, + metadata: generateMetadata(4), + }, ], destType: 'intercom', }; @@ -636,6 +708,96 @@ const routerRequest3: RouterTransformationRequest = { destType: 'intercom', }; +const routerRequest4: RouterTransformationRequest = { + input: [ + { + destination: destination3, + message: { + userId: 'user@1', + channel: 'web', + context: { + traits: { + age: 23, + email: 'test+5@rudderlabs.com', + phone: '+91 9599999999', + firstName: 'John', + lastName: 'Snow', + address: 'california usa', + ownerId: '13', + company: { + id: 'company id', + name: 'Test Company', + remove: true, + }, + }, + }, + type: 'identify', + integrations: { All: true }, + originalTimestamp: '2023-11-10T14:42:44.724Z', + timestamp: '2023-11-22T10:12:44.757+05:30', + }, + metadata: generateMetadata(1), + }, + { + destination: destination3, + message: { + userId: 'user@1', + channel: 'web', + context: { + traits: { + age: 23, + email: 'test+5@rudderlabs.com', + phone: '+91 9599999999', + firstName: 'John', + lastName: 'Snow', + address: 'california usa', + ownerId: '13', + company: { + id: 'unavailable company id', + name: 'Test Company', + remove: true, + }, + }, + }, + type: 'identify', + integrations: { All: true }, + originalTimestamp: '2023-11-10T14:42:44.724Z', + timestamp: '2023-11-22T10:12:44.757+05:30', + }, + metadata: generateMetadata(2), + }, + { + destination: destination3, + message: { + userId: 'user@1', + channel: 'web', + context: { + traits: { + age: 23, + email: 'test+5@rudderlabs.com', + phone: '+91 9599999999', + firstName: 'John', + lastName: 'Snow', + address: 'california usa', + ownerId: '13', + company: { + id: 'other company id', + name: 'Test Company', + remove: true, + }, + }, + }, + type: 'identify', + integrations: { All: true }, + originalTimestamp: '2023-11-10T14:42:44.724Z', + timestamp: '2023-11-22T10:12:44.757+05:30', + }, + metadata: generateMetadata(3), + }, + ], + destType: 'intercom', +}; + export const data: RouterTestData[] = [ { id: 'Intercom-router-test-1', @@ -983,6 +1145,153 @@ export const data: RouterTestData[] = [ metadata: [generateMetadata(3)], statusCode: 299, }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://api.intercom.io/users', + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer testApiKey', + Accept: 'application/json', + 'Intercom-Version': '1.4', + 'User-Agent': 'RudderStack', + }, + params: {}, + body: { + JSON: { + email: 'test_1@test.com', + phone: '9876543210', + name: 'Test Name', + signed_up_at: 1601493060, + last_seen_user_agent: 'unknown', + update_last_request_at: false, + user_id: 'test_user_id_1', + companies: [ + { + company_id: 'company id', + custom_attributes: {}, + name: 'Test Company', + remove: true, + }, + ], + custom_attributes: { + anonymousId: '58b21c2d-f8d5-4410-a2d0-b268a26b7e33', + key1: 'value1', + }, + }, + XML: {}, + JSON_ARRAY: {}, + FORM: {}, + }, + files: {}, + userId: '58b21c2d-f8d5-4410-a2d0-b268a26b7e33', + }, + metadata: [generateMetadata(4)], + batched: false, + statusCode: 200, + destination: destination4, + }, + ], + }, + }, + }, + }, + { + id: 'Intercom-router-test-3', + scenario: 'Framework', + successCriteria: + 'Some identify events should be transformed successfully and some should fail for apiVersion v2', + name: 'intercom', + description: + 'Intercom router tests for detaching contact from company in intercom for apiVersion v2', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: routerRequest4, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batched: false, + batchedRequest: { + body: { + JSON: { + email: 'test+5@rudderlabs.com', + external_id: 'user@1', + name: 'John Snow', + owner_id: 13, + phone: '+91 9599999999', + custom_attributes: { + address: 'california usa', + age: 23, + }, + }, + XML: {}, + FORM: {}, + JSON_ARRAY: {}, + }, + endpoint: 'https://api.eu.intercom.io/contacts/70701240741e45d040', + files: {}, + headers: { + Authorization: 'Bearer testApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + 'Intercom-Version': '2.10', + 'User-Agent': 'RudderStack', + }, + method: 'PUT', + params: {}, + type: 'REST', + version: '1', + }, + destination: destination3, + metadata: [generateMetadata(1)], + statusCode: 200, + }, + { + batched: false, + error: + 'Unable to get company id due to : {"type":"error.list","request_id":"req123","errors":[{"code":"company_not_found","message":"Company Not Found"}]}', + statTags: { + destType: 'INTERCOM', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'router', + implementation: 'cdkV2', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + destination: destination3, + metadata: [generateMetadata(2)], + statusCode: 400, + }, + { + batched: false, + error: + 'Unable to detach contact and company due to : {"type":"error.list","request_id":"req123","errors":[{"code":"company_not_found","message":"Company Not Found"}]}', + statTags: { + destType: 'INTERCOM', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'router', + implementation: 'cdkV2', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + destination: destination3, + metadata: [generateMetadata(3)], + statusCode: 400, + }, ], }, }, diff --git a/test/integrations/destinations/klaviyo/processor/data.ts b/test/integrations/destinations/klaviyo/processor/data.ts index 06c4a3e530..71a10fc39c 100644 --- a/test/integrations/destinations/klaviyo/processor/data.ts +++ b/test/integrations/destinations/klaviyo/processor/data.ts @@ -4,8 +4,10 @@ import { identifyData } from './identifyTestData'; import { screenTestData } from './screenTestData'; import { trackTestData } from './trackTestData'; import { validationTestData } from './validationTestData'; +import { dataV2 } from './dataV2'; export const data = [ + ...dataV2, ...identifyData, ...trackTestData, ...screenTestData, diff --git a/test/integrations/destinations/klaviyo/processor/dataV2.ts b/test/integrations/destinations/klaviyo/processor/dataV2.ts new file mode 100644 index 0000000000..32c3c4206a --- /dev/null +++ b/test/integrations/destinations/klaviyo/processor/dataV2.ts @@ -0,0 +1,13 @@ +import { groupTestData } from './groupTestDataV2'; +import { identifyData } from './identifyTestDataV2'; +import { screenTestData } from './screenTestDataV2'; +import { trackTestData } from './trackTestDataV2'; +import { validationTestData } from './validationTestData'; + +export const dataV2 = [ + ...identifyData, + ...trackTestData, + ...screenTestData, + ...groupTestData, + ...validationTestData, +]; diff --git a/test/integrations/destinations/klaviyo/processor/groupTestDataV2.ts b/test/integrations/destinations/klaviyo/processor/groupTestDataV2.ts new file mode 100644 index 0000000000..da7769b110 --- /dev/null +++ b/test/integrations/destinations/klaviyo/processor/groupTestDataV2.ts @@ -0,0 +1,256 @@ +import { Destination } from '../../../../../src/types'; +import { ProcessorTestData } from '../../../testTypes'; +import { + generateMetadata, + generateSimplifiedGroupPayload, + transformResultBuilder, +} from '../../../testUtils'; + +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + apiVersion: 'v2', + privateApiKey: 'dummyPrivateApiKey', + consent: ['email'], + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; + +const headers = { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2024-06-15', +}; + +const subscriptionEndpoint = 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs'; + +const commonOutputSubscriptionProps = { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 678 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, +}; +const commonOutputUnsubscriptionProps = { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 678 900', + }, + }, + ], + }, +}; + +const subscriptionRelations = { + list: { + data: { + type: 'list', + id: 'group_list_id', + }, + }, +}; +const unsubscriptionEndpoint = 'https://a.klaviyo.com/api/profile-subscription-bulk-delete-jobs'; + +export const groupTestData: ProcessorTestData[] = [ + { + id: 'klaviyo-group-test-1', + name: 'klaviyo', + description: 'Simple group call for subscription', + scenario: 'Business', + successCriteria: + 'Response should contain only group payload and status code should be 200, for the group payload a subscription payload should be present in the final payload with email and phone', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: generateSimplifiedGroupPayload({ + userId: 'user123', + groupId: 'group_list_id', + traits: { + subscribe: true, + }, + context: { + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + consent: ['email'], + }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }), + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: commonOutputSubscriptionProps, + relationships: subscriptionRelations, + }, + }, + endpoint: subscriptionEndpoint, + headers: headers, + method: 'POST', + userId: '', + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'klaviyo-group-test-1', + name: 'klaviyo', + description: 'Simple group call for subscription', + scenario: 'Business', + successCriteria: + 'Response should contain only group payload and status code should be 200, for the group payload a unsubscription payload should be present in the final payload with email and phone', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: generateSimplifiedGroupPayload({ + userId: 'user123', + groupId: 'group_list_id', + traits: { + subscribe: false, + }, + context: { + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + consent: ['email'], + }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }), + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + JSON: { + data: { + type: 'profile-subscription-bulk-delete-job', + attributes: commonOutputUnsubscriptionProps, + relationships: subscriptionRelations, + }, + }, + endpoint: unsubscriptionEndpoint, + headers: headers, + method: 'POST', + userId: '', + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'klaviyo-group-test-3', + name: 'klaviyo', + description: 'Simple group call without groupId', + scenario: 'Business', + successCriteria: + 'Response should contain error message and status code should be 400, as we are not sending groupId in the payload and groupId is a required field for group events', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: generateSimplifiedGroupPayload({ + userId: 'user123', + groupId: '', + traits: { + subscribe: true, + }, + context: { + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + consent: 'email', + }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }), + metadata: generateMetadata(2), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: 'groupId is a required field for group events', + statTags: { + destType: 'KLAVIYO', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'native', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + statusCode: 400, + metadata: generateMetadata(2), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/klaviyo/processor/identifyTestDataV2.ts b/test/integrations/destinations/klaviyo/processor/identifyTestDataV2.ts new file mode 100644 index 0000000000..612bfe88f8 --- /dev/null +++ b/test/integrations/destinations/klaviyo/processor/identifyTestDataV2.ts @@ -0,0 +1,481 @@ +import { removeUndefinedAndNullValues } from '@rudderstack/integrations-lib'; +import { + overrideDestination, + transformResultBuilder, + generateSimplifiedIdentifyPayload, + generateMetadata, +} from '../../../testUtils'; +import { ProcessorTestData } from '../../../testTypes'; +import { Destination } from '../../../../../src/types'; + +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + apiVersion: 'v2', + privateApiKey: 'dummyPrivateApiKey', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; + +const commonTraits = { + firstName: 'Test', + lastName: 'Rudderlabs', + email: 'test@rudderstack.com', + phone: '+12 345 578 900', + userId: 'user@1', + title: 'Developer', + organization: 'Rudder', + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + Flagged: false, + Residence: 'Shibuya', + street: '63, Shibuya', + properties: { + listId: 'XUepkK', + subscribe: true, + consent: ['email', 'sms'], + }, +}; + +const commonOutputUserProps = { + external_id: 'user@1', + anonymous_id: '97c46c81-3140-456d-b2a9-690d70aaca35', + email: 'test@rudderstack.com', + first_name: 'Test', + last_name: 'Rudderlabs', + phone_number: '+12 345 578 900', + title: 'Developer', + organization: 'Rudder', + location: { + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + address1: '63, Shibuya', + }, + properties: { + Flagged: false, + Residence: 'Shibuya', + }, +}; + +const commonOutputSubscriptionProps = { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 578 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + sms: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, +}; +const commonOutputUnsubscriptionProps = { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 578 900', + }, + }, + ], + }, +}; +const subscriptionRelations = { + list: { + data: { + type: 'list', + id: 'XUepkK', + }, + }, +}; + +const commonOutputHeaders = { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2024-06-15', +}; + +const anonymousId = '97c46c81-3140-456d-b2a9-690d70aaca35'; +const userId = 'user@1'; +const sentAt = '2021-01-03T17:02:53.195Z'; +const originalTimestamp = '2021-01-03T17:02:53.193Z'; +const userProfileCommonEndpoint = 'https://a.klaviyo.com/api/profile-import'; +const subscribeEndpoint = 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs'; +const unsubscribeEndpoint = 'https://a.klaviyo.com/api/profile-subscription-bulk-delete-jobs'; + +export const identifyData: ProcessorTestData[] = [ + { + id: 'klaviyo-identify-150624-test-1', + name: 'klaviyo', + description: + '150624 -> Identify call with flattenProperties enabled in destination config and subscribe', + scenario: 'Business', + successCriteria: + 'The profile response should contain the flattened properties of the friend object and one request object for subscribe', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: overrideDestination(destination, { flattenProperties: true }), + message: generateSimplifiedIdentifyPayload({ + sentAt, + userId, + context: { + traits: { + ...commonTraits, + friend: { + names: { + first: 'Alice', + last: 'Smith', + }, + age: 25, + }, + }, + }, + anonymousId, + originalTimestamp, + }), + metadata: generateMetadata(2), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + userId: '', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile', + attributes: { + ...commonOutputUserProps, + properties: { + ...commonOutputUserProps.properties, + 'friend.age': 25, + 'friend.names.first': 'Alice', + 'friend.names.last': 'Smith', + }, + }, + meta: { + patch_properties: {}, + }, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(2), + }, + { + output: transformResultBuilder({ + userId: '', + method: 'POST', + endpoint: subscribeEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: commonOutputSubscriptionProps, + relationships: subscriptionRelations, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(2), + }, + ], + }, + }, + }, + { + id: 'klaviyo-identify-150624-test-2', + name: 'klaviyo', + description: + '150624 -> Identify call with flattenProperties enabled in destination config and unsubscribe', + scenario: 'Business', + successCriteria: + 'The profile response should contain the flattened properties of the friend object and one request object for subscribe', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: overrideDestination(destination, { flattenProperties: true }), + message: generateSimplifiedIdentifyPayload({ + sentAt, + userId, + context: { + traits: { + ...commonTraits, + properties: { ...commonTraits.properties, subscribe: false }, + friend: { + names: { + first: 'Alice', + last: 'Smith', + }, + age: 25, + }, + }, + }, + anonymousId, + originalTimestamp, + }), + metadata: generateMetadata(2), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + userId: '', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile', + attributes: { + ...commonOutputUserProps, + properties: { + ...commonOutputUserProps.properties, + 'friend.age': 25, + 'friend.names.first': 'Alice', + 'friend.names.last': 'Smith', + }, + }, + meta: { + patch_properties: {}, + }, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(2), + }, + { + output: transformResultBuilder({ + userId: '', + method: 'POST', + endpoint: unsubscribeEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile-subscription-bulk-delete-job', + attributes: commonOutputUnsubscriptionProps, + relationships: subscriptionRelations, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(2), + }, + ], + }, + }, + }, + { + id: 'klaviyo-identify-150624-test-3', + name: 'klaviyo', + description: + '150624 -> Profile without subscribing/unsubscribing the user and get klaviyo id from externalId', + scenario: 'Business', + successCriteria: + 'Response should contain only profile update payload and status code should be 200 as subscribe is set to false in the payload', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: generateSimplifiedIdentifyPayload({ + sentAt, + userId, + context: { + externalId: [ + { + type: 'klaviyo-profileId', + id: '12345678', + }, + ], + traits: { + ...commonTraits, + appendList1: 'New Value 1', + appendList2: 'New Value 2', + unappendList1: 'Old Value 1', + unappendList2: 'Old Value 2', + properties: { ...commonTraits.properties, subscribe: undefined }, + }, + }, + integrations: { + Klaviyo: { + fieldsToUnset: ['Unset1', 'Unset2'], + fieldsToAppend: ['appendList1', 'appendList2'], + fieldsToUnappend: ['unappendList1', 'unappendList2'], + }, + All: true, + }, + anonymousId, + originalTimestamp, + }), + metadata: generateMetadata(4), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile', + id: '12345678', + attributes: commonOutputUserProps, + meta: { + patch_properties: { + append: { + appendList1: 'New Value 1', + appendList2: 'New Value 2', + }, + unappend: { + unappendList1: 'Old Value 1', + unappendList2: 'Old Value 2', + }, + unset: ['Unset1', 'Unset2'], + }, + }, + }, + }, + userId: '', + }), + statusCode: 200, + metadata: generateMetadata(4), + }, + ], + }, + }, + }, + { + id: 'klaviyo-identify-150624-test-4', + name: 'klaviyo', + description: '150624 -> Identify call with enforceEmailAsPrimary enabled in destination config', + scenario: 'Business', + successCriteria: + 'Response should contain two payloads one for profile and other for subscription, response status code should be 200, for the profile updation payload there should be no external_id field in the payload as enforceEmailAsPrimary is set to true in the destination config and the userId should be mapped to _id field in the properties object', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: overrideDestination(destination, { enforceEmailAsPrimary: true }), + message: generateSimplifiedIdentifyPayload({ + sentAt, + userId, + context: { + traits: commonTraits, + }, + anonymousId, + originalTimestamp, + }), + metadata: generateMetadata(5), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + userId: '', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile', + attributes: removeUndefinedAndNullValues({ + ...commonOutputUserProps, + properties: { + ...commonOutputUserProps.properties, + _id: userId, + }, + // remove external_id from the payload + external_id: undefined, + }), + meta: { + patch_properties: {}, + }, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(5), + }, + { + output: transformResultBuilder({ + userId: '', + method: 'POST', + endpoint: subscribeEndpoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: commonOutputSubscriptionProps, + relationships: subscriptionRelations, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(5), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/klaviyo/processor/screenTestDataV2.ts b/test/integrations/destinations/klaviyo/processor/screenTestDataV2.ts new file mode 100644 index 0000000000..5ccbed600c --- /dev/null +++ b/test/integrations/destinations/klaviyo/processor/screenTestDataV2.ts @@ -0,0 +1,148 @@ +import { Destination } from '../../../../../src/types'; +import { ProcessorTestData } from '../../../testTypes'; +import { + generateMetadata, + generateSimplifiedPageOrScreenPayload, + transformResultBuilder, +} from '../../../testUtils'; + +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + apiVersion: 'v2', + privateApiKey: 'dummyPrivateApiKey', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; + +export const screenTestData: ProcessorTestData[] = [ + { + id: 'klaviyo-screen-150624-test-1', + name: 'klaviyo', + description: '150624 -> Screen event call with properties and contextual traits', + scenario: 'Business', + successCriteria: + 'Response should contain only event payload and status code should be 200, for the event payload should contain properties and contextual traits in the payload', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: generateSimplifiedPageOrScreenPayload( + { + name: 'Viewed Screen', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'sajal12', + integrations: { + klaviyo: { + fieldsToAppend: ['append1'], + }, + }, + context: { + traits: { + id: 'user@1', + age: '22', + email: 'test@rudderstack.com', + phone: '9112340375', + anonymousId: '9c6bd77ea9da3e68', + append1: 'value1', + }, + }, + properties: { + value: 9.99, + currency: 'USD', + PreviouslyVicePresident: true, + YearElected: 1801, + VicePresidents: ['Aaron Burr', 'George Clinton'], + }, + anonymousId: '9c6bd77ea9da3e68', + originalTimestamp: '2021-01-25T15:32:56.409Z', + }, + 'screen', + ), + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Accept: 'application/json', + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + JSON: { + data: { + type: 'event', + attributes: { + time: '2021-01-25T15:32:56.409Z', + value: 9.99, + value_currency: 'USD', + metric: { + data: { + type: 'metric', + attributes: { + name: 'Viewed Screen', + }, + }, + }, + properties: { + PreviouslyVicePresident: true, + YearElected: 1801, + VicePresidents: ['Aaron Burr', 'George Clinton'], + }, + profile: { + data: { + attributes: { + anonymous_id: '9c6bd77ea9da3e68', + external_id: 'sajal12', + email: 'test@rudderstack.com', + meta: { + patch_properties: { + append: { + append1: 'value1', + }, + }, + }, + phone_number: '9112340375', + properties: { + id: 'user@1', + age: '22', + }, + }, + type: 'profile', + }, + }, + }, + }, + }, + userId: '', + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/klaviyo/processor/trackTestDataV2.ts b/test/integrations/destinations/klaviyo/processor/trackTestDataV2.ts new file mode 100644 index 0000000000..ecea141d38 --- /dev/null +++ b/test/integrations/destinations/klaviyo/processor/trackTestDataV2.ts @@ -0,0 +1,293 @@ +import { Destination } from '../../../../../src/types'; +import { ProcessorTestData } from '../../../testTypes'; +import { + generateMetadata, + generateSimplifiedTrackPayload, + generateTrackPayload, + overrideDestination, + transformResultBuilder, +} from '../../../testUtils'; + +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + privateApiKey: 'dummyPrivateApiKey', + apiVersion: 'v2', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; + +const commonTraits = { + id: 'user@1', + age: '22', + anonymousId: '9c6bd77ea9da3e68', +}; + +const commonProps = { + PreviouslVicePresident: true, + YearElected: 1801, + VicePresidents: ['AaronBurr', 'GeorgeClinton'], +}; + +const commonOutputHeaders = { + Accept: 'application/json', + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + revision: '2024-06-15', +}; +const profileAttributes = { + email: 'test@rudderstack.com', + phone_number: '9112340375', + anonymous_id: '9c6bd77ea9da3e68', + properties: { + age: '22', + name: 'Test', + description: 'Sample description', + id: 'user@1', + }, + meta: { + patch_properties: {}, + }, +}; +const eventEndPoint = 'https://a.klaviyo.com/api/events'; + +export const trackTestData: ProcessorTestData[] = [ + { + id: 'klaviyo-track-150624-test-1', + name: 'klaviyo', + description: '150624 -> Simple track event call', + scenario: 'Business', + successCriteria: + 'Response should contain profile and event payload and status code should be 200, for the event payload should contain contextual traits and properties in the payload', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: generateSimplifiedTrackPayload({ + type: 'track', + event: 'TestEven002', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'sajal12', + context: { + traits: { + ...commonTraits, + name: 'Test', + email: 'test@rudderstack.com', + phone: '9112340375', + description: 'Sample description', + }, + }, + properties: { + ...commonProps, + revenue: 3000, + currency: 'USD', + }, + anonymousId: '9c6bd77ea9da3e68', + originalTimestamp: '2021-01-25T15:32:56.409Z', + }), + metadata: generateMetadata(2), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + endpoint: eventEndPoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'event', + attributes: { + metric: { + data: { + type: 'metric', + attributes: { + name: 'TestEven002', + }, + }, + }, + profile: { + data: { + type: 'profile', + attributes: { ...profileAttributes, external_id: 'sajal12' }, + }, + }, + properties: commonProps, + value: 3000, + value_currency: 'USD', + time: '2021-01-25T15:32:56.409Z', + }, + }, + }, + userId: '', + }), + statusCode: 200, + metadata: generateMetadata(2), + }, + ], + }, + }, + }, + { + id: 'klaviyo-track-150624-test-2', + name: 'klaviyo', + description: + '150624 -> Track event call, with make email or phone as primary identifier toggle on', + scenario: 'Business', + successCriteria: + 'Response should contain only event payload with profile object and status code should be 200, for the event payload should contain contextual traits and properties in the payload, and email should be mapped to email and userId should be mapped to external_id as usual', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: overrideDestination(destination, { enforceEmailAsPrimary: true }), + message: generateSimplifiedTrackPayload({ + type: 'track', + event: 'TestEven001', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'sajal12', + context: { + traits: { + ...commonTraits, + description: 'Sample description', + name: 'Test', + email: 'test@rudderstack.com', + phone: '9112340375', + }, + }, + properties: commonProps, + anonymousId: '9c6bd77ea9da3e68', + originalTimestamp: '2021-01-25T15:32:56.409Z', + }), + metadata: generateMetadata(3), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + endpoint: eventEndPoint, + headers: commonOutputHeaders, + JSON: { + data: { + type: 'event', + attributes: { + metric: { + data: { + type: 'metric', + attributes: { + name: 'TestEven001', + }, + }, + }, + properties: commonProps, + profile: { + data: { + type: 'profile', + attributes: { + ...profileAttributes, + properties: { ...profileAttributes.properties, _id: 'sajal12' }, + }, + }, + }, + time: '2021-01-25T15:32:56.409Z', + }, + }, + }, + userId: '', + }), + statusCode: 200, + metadata: generateMetadata(3), + }, + ], + }, + }, + }, + { + id: 'klaviyo-track-150624-test-3', + name: 'klaviyo', + description: '150624 -> Invalid `value` Field Format', + scenario: 'Business', + successCriteria: + 'Response should contain only event payload with vallue field as object and status code should be 200', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: overrideDestination(destination, { enforceEmailAsPrimary: true }), + message: generateSimplifiedTrackPayload({ + type: 'track', + event: 'TestEven001', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'sajal12', + context: { + traits: { + ...commonTraits, + description: 'Sample description', + name: 'Test', + email: 'test@rudderstack.com', + phone: '9112340375', + }, + }, + properties: { ...commonProps, value: { price: 9.99 } }, + anonymousId: '9c6bd77ea9da3e68', + originalTimestamp: '2021-01-25T15:32:56.409Z', + }), + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Invalid float value', + statTags: { + destType: 'KLAVIYO', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'native', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + statusCode: 400, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/klaviyo/processor/validationTestDataV2.ts b/test/integrations/destinations/klaviyo/processor/validationTestDataV2.ts new file mode 100644 index 0000000000..10e2d15db0 --- /dev/null +++ b/test/integrations/destinations/klaviyo/processor/validationTestDataV2.ts @@ -0,0 +1,83 @@ +import { Destination } from '../../../../../src/types'; +import { ProcessorTestData } from '../../../testTypes'; +import { generateMetadata } from '../../../testUtils'; + +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + privateApiKey: 'dummyPrivateApiKey', + apiVersion: 'v2', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; + +export const validationTestData: ProcessorTestData[] = [ + { + id: 'klaviyo-validation-150624-test-1', + name: 'klaviyo', + description: '150624->[Error]: Check for unsupported message type', + scenario: 'Framework', + successCriteria: + 'Response should contain error message and status code should be 400, as we are sending a message type which is not supported by Klaviyo destination and the error message should be Event type random is not supported', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + userId: 'user123', + type: 'random', + groupId: 'XUepkK', + traits: { + subscribe: true, + }, + context: { + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + consent: 'email', + }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Event type random is not supported', + statTags: { + destType: 'KLAVIYO', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'native', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + statusCode: 400, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/klaviyo/router/commonConfig.ts b/test/integrations/destinations/klaviyo/router/commonConfig.ts new file mode 100644 index 0000000000..a1297635eb --- /dev/null +++ b/test/integrations/destinations/klaviyo/router/commonConfig.ts @@ -0,0 +1,199 @@ +import { generateMetadata } from '../../../testUtils'; +import { Destination, RouterTransformationRequest } from '../../../../../src/types'; +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + privateApiKey: 'dummyPrivateApiKey', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; +const destinationV2: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + privateApiKey: 'dummyPrivateApiKey', + apiVersion: 'v2', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; +const getRequest = (apiVersion) => { + return [ + { + destination: apiVersion === 'v2' ? destinationV2 : destination, + metadata: generateMetadata(1), + message: { + type: 'identify', + sentAt: '2021-01-03T17:02:53.195Z', + userId: 'test', + channel: 'web', + context: { + os: { name: '', version: '' }, + app: { + name: 'RudderLabs JavaScript SDK', + build: '1.0.0', + version: '1.1.11', + namespace: 'com.rudderlabs.javascript', + }, + traits: { + firstName: 'Test', + lastName: 'Rudderlabs', + email: 'test_1@rudderstack.com', + phone: '+12 345 578 900', + userId: 'Testc', + title: 'Developer', + organization: 'Rudder', + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + Flagged: false, + Residence: 'Shibuya', + properties: { consent: ['email', 'sms'] }, + }, + locale: 'en-US', + screen: { density: 2 }, + library: { name: 'RudderLabs JavaScript SDK', version: '1.1.11' }, + campaign: {}, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0', + }, + rudderId: '8f8fa6b5-8e24-489c-8e22-61f23f2e364f', + messageId: '2116ef8c-efc3-4ca4-851b-02ee60dad6ff', + anonymousId: '97c46c81-3140-456d-b2a9-690d70aaca35', + integrations: { All: true }, + originalTimestamp: '2021-01-03T17:02:53.193Z', + }, + }, + { + destination: apiVersion === 'v2' ? destinationV2 : destination, + metadata: generateMetadata(2), + message: { + type: 'identify', + sentAt: '2021-01-03T17:02:53.195Z', + userId: 'test', + channel: 'web', + context: { + os: { name: '', version: '' }, + app: { + name: 'RudderLabs JavaScript SDK', + build: '1.0.0', + version: '1.1.11', + namespace: 'com.rudderlabs.javascript', + }, + traits: { + firstName: 'Test', + lastName: 'Rudderlabs', + email: 'test@rudderstack.com', + phone: '+12 345 578 900', + userId: 'test', + title: 'Developer', + organization: 'Rudder', + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + Flagged: false, + Residence: 'Shibuya', + properties: { listId: 'XUepkK', subscribe: true, consent: ['email', 'sms'] }, + }, + locale: 'en-US', + screen: { density: 2 }, + library: { name: 'RudderLabs JavaScript SDK', version: '1.1.11' }, + campaign: {}, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0', + }, + rudderId: '8f8fa6b5-8e24-489c-8e22-61f23f2e364f', + messageId: '2116ef8c-efc3-4ca4-851b-02ee60dad6ff', + anonymousId: '97c46c81-3140-456d-b2a9-690d70aaca35', + integrations: { All: true }, + originalTimestamp: '2021-01-03T17:02:53.193Z', + }, + }, + { + destination: apiVersion === 'v2' ? destinationV2 : destination, + metadata: generateMetadata(3), + message: { + userId: 'user123', + type: 'group', + groupId: 'XUepkK', + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + subscribe: true, + consent: ['email'], + }, + context: { + ip: '14.5.67.21', + library: { name: 'http' }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }, + }, + { + destination: apiVersion === 'v2' ? destinationV2 : destination, + metadata: generateMetadata(4), + message: { + userId: 'user123', + type: 'random', + groupId: 'XUepkK', + traits: { subscribe: true }, + context: { + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + consent: 'email', + }, + ip: '14.5.67.21', + library: { name: 'http' }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }, + }, + { + destination: apiVersion === 'v2' ? destinationV2 : destination, + metadata: generateMetadata(5), + message: { + userId: 'user123', + type: 'group', + groupId: '', + traits: { subscribe: true }, + context: { + traits: { + email: 'test@rudderstack.com', + phone: '+12 345 678 900', + consent: 'email', + }, + ip: '14.5.67.21', + library: { name: 'http' }, + }, + timestamp: '2020-01-21T00:21:34.208Z', + }, + }, + ]; +}; +export const routerRequest: RouterTransformationRequest = { + input: getRequest('v1'), + destType: 'klaviyo', +}; +export const routerRequestV2: RouterTransformationRequest = { + input: getRequest('v2'), + destType: 'klaviyo', +}; diff --git a/test/integrations/destinations/klaviyo/router/data.ts b/test/integrations/destinations/klaviyo/router/data.ts index 8866a8a546..1b3f7f39ad 100644 --- a/test/integrations/destinations/klaviyo/router/data.ts +++ b/test/integrations/destinations/klaviyo/router/data.ts @@ -1,6 +1,8 @@ import { Destination, RouterTransformationRequest } from '../../../../../src/types'; import { RouterTestData } from '../../../testTypes'; +import { routerRequest } from './commonConfig'; import { generateMetadata } from '../../../testUtils'; +import { dataV2 } from './dataV2'; const destination: Destination = { ID: '123', @@ -12,7 +14,6 @@ const destination: Destination = { Config: {}, }, Config: { - publicApiKey: 'dummyPublicApiKey', privateApiKey: 'dummyPrivateApiKey', }, Enabled: true, @@ -20,164 +21,6 @@ const destination: Destination = { Transformations: [], }; -const routerRequest: RouterTransformationRequest = { - input: [ - { - destination, - metadata: generateMetadata(1), - message: { - type: 'identify', - sentAt: '2021-01-03T17:02:53.195Z', - userId: 'test', - channel: 'web', - context: { - os: { name: '', version: '' }, - app: { - name: 'RudderLabs JavaScript SDK', - build: '1.0.0', - version: '1.1.11', - namespace: 'com.rudderlabs.javascript', - }, - traits: { - firstName: 'Test', - lastName: 'Rudderlabs', - email: 'test@rudderstack.com', - phone: '+12 345 578 900', - userId: 'Testc', - title: 'Developer', - organization: 'Rudder', - city: 'Tokyo', - region: 'Kanto', - country: 'JP', - zip: '100-0001', - Flagged: false, - Residence: 'Shibuya', - properties: { consent: ['email', 'sms'] }, - }, - locale: 'en-US', - screen: { density: 2 }, - library: { name: 'RudderLabs JavaScript SDK', version: '1.1.11' }, - campaign: {}, - userAgent: - 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0', - }, - rudderId: '8f8fa6b5-8e24-489c-8e22-61f23f2e364f', - messageId: '2116ef8c-efc3-4ca4-851b-02ee60dad6ff', - anonymousId: '97c46c81-3140-456d-b2a9-690d70aaca35', - integrations: { All: true }, - originalTimestamp: '2021-01-03T17:02:53.193Z', - }, - }, - { - destination, - metadata: generateMetadata(2), - message: { - type: 'identify', - sentAt: '2021-01-03T17:02:53.195Z', - userId: 'test', - channel: 'web', - context: { - os: { name: '', version: '' }, - app: { - name: 'RudderLabs JavaScript SDK', - build: '1.0.0', - version: '1.1.11', - namespace: 'com.rudderlabs.javascript', - }, - traits: { - firstName: 'Test', - lastName: 'Rudderlabs', - email: 'test@rudderstack.com', - phone: '+12 345 578 900', - userId: 'test', - title: 'Developer', - organization: 'Rudder', - city: 'Tokyo', - region: 'Kanto', - country: 'JP', - zip: '100-0001', - Flagged: false, - Residence: 'Shibuya', - properties: { listId: 'XUepkK', subscribe: true, consent: ['email', 'sms'] }, - }, - locale: 'en-US', - screen: { density: 2 }, - library: { name: 'RudderLabs JavaScript SDK', version: '1.1.11' }, - campaign: {}, - userAgent: - 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0', - }, - rudderId: '8f8fa6b5-8e24-489c-8e22-61f23f2e364f', - messageId: '2116ef8c-efc3-4ca4-851b-02ee60dad6ff', - anonymousId: '97c46c81-3140-456d-b2a9-690d70aaca35', - integrations: { All: true }, - originalTimestamp: '2021-01-03T17:02:53.193Z', - }, - }, - { - destination, - metadata: generateMetadata(3), - message: { - userId: 'user123', - type: 'group', - groupId: 'XUepkK', - traits: { subscribe: true }, - context: { - traits: { - email: 'test@rudderstack.com', - phone: '+12 345 678 900', - consent: ['email'], - }, - ip: '14.5.67.21', - library: { name: 'http' }, - }, - timestamp: '2020-01-21T00:21:34.208Z', - }, - }, - { - destination, - metadata: generateMetadata(4), - message: { - userId: 'user123', - type: 'random', - groupId: 'XUepkK', - traits: { subscribe: true }, - context: { - traits: { - email: 'test@rudderstack.com', - phone: '+12 345 678 900', - consent: 'email', - }, - ip: '14.5.67.21', - library: { name: 'http' }, - }, - timestamp: '2020-01-21T00:21:34.208Z', - }, - }, - { - destination, - metadata: generateMetadata(5), - message: { - userId: 'user123', - type: 'group', - groupId: '', - traits: { subscribe: true }, - context: { - traits: { - email: 'test@rudderstack.com', - phone: '+12 345 678 900', - consent: 'email', - }, - ip: '14.5.67.21', - library: { name: 'http' }, - }, - timestamp: '2020-01-21T00:21:34.208Z', - }, - }, - ], - destType: 'klaviyo', -}; - export const data: RouterTestData[] = [ { id: 'klaviyo-router-test-1', @@ -220,6 +63,43 @@ export const data: RouterTestData[] = [ list_id: 'XUepkK', subscriptions: [ { email: 'test@rudderstack.com', phone_number: '+12 345 678 900' }, + ], + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(3)], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2023-02-22', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + list_id: 'XUepkK', + subscriptions: [ { email: 'test@rudderstack.com', phone_number: '+12 345 578 900', @@ -277,7 +157,7 @@ export const data: RouterTestData[] = [ files: {}, }, ], - metadata: [generateMetadata(3), generateMetadata(2)], + metadata: [generateMetadata(2)], batched: true, statusCode: 200, destination, @@ -301,7 +181,7 @@ export const data: RouterTestData[] = [ type: 'profile', attributes: { external_id: 'test', - email: 'test@rudderstack.com', + email: 'test_1@rudderstack.com', first_name: 'Test', last_name: 'Rudderlabs', phone_number: '+12 345 578 900', @@ -368,4 +248,5 @@ export const data: RouterTestData[] = [ }, }, }, + ...dataV2, ]; diff --git a/test/integrations/destinations/klaviyo/router/dataV2.ts b/test/integrations/destinations/klaviyo/router/dataV2.ts new file mode 100644 index 0000000000..5a0a06fad1 --- /dev/null +++ b/test/integrations/destinations/klaviyo/router/dataV2.ts @@ -0,0 +1,2047 @@ +import { Destination } from '../../../../../src/types'; +import { RouterTestData } from '../../../testTypes'; +import { routerRequestV2 } from './commonConfig'; +import { generateMetadata, transformResultBuilder } from '../../../testUtils'; + +const destination: Destination = { + ID: '123', + Name: 'klaviyo', + DestinationDefinition: { + ID: '123', + Name: 'klaviyo', + DisplayName: 'klaviyo', + Config: {}, + }, + Config: { + privateApiKey: 'dummyPrivateApiKey', + apiVersion: 'v2', + }, + Enabled: true, + WorkspaceID: '123', + Transformations: [], +}; +const userProfileCommonEndpoint = 'https://a.klaviyo.com/api/profile-import'; + +const headers = { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2024-06-15', +}; +const subscriptionRelations = { + list: { + data: { + type: 'list', + id: 'XUepkK', + }, + }, +}; + +const commonOutputSubscriptionProps = { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 678 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, +}; + +const alreadyTransformedEvent = { + message: { + output: transformResultBuilder({ + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: commonOutputSubscriptionProps, + relationships: subscriptionRelations, + }, + }, + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: headers, + method: 'POST', + userId: '', + }), + statusCode: 200, + }, + metadata: generateMetadata(10), + destination, +}; + +export const dataV2: RouterTestData[] = [ + { + id: 'klaviyo-router-150624-test-1', + name: 'klaviyo', + description: '150624 -> Basic Router Test to test multiple payloads', + scenario: 'Framework', + successCriteria: + 'All the subscription events from same type of call should be batched. This case does not contain any events which can be batched', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: routerRequestV2, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + // identify 2 with subscriptipon request + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'test', + email: 'test@rudderstack.com', + first_name: 'Test', + last_name: 'Rudderlabs', + phone_number: '+12 345 578 900', + anonymous_id: '97c46c81-3140-456d-b2a9-690d70aaca35', + title: 'Developer', + organization: 'Rudder', + location: { + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + }, + properties: { Flagged: false, Residence: 'Shibuya' }, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 578 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + sms: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, + }, + relationships: subscriptionRelations, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(2)], + batched: true, + statusCode: 200, + destination, + }, + { + // identify 1 + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'test', + email: 'test_1@rudderstack.com', + first_name: 'Test', + last_name: 'Rudderlabs', + phone_number: '+12 345 578 900', + anonymous_id: '97c46c81-3140-456d-b2a9-690d70aaca35', + title: 'Developer', + organization: 'Rudder', + location: { + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + }, + properties: { Flagged: false, Residence: 'Shibuya' }, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(1)], + batched: true, + statusCode: 200, + destination, + }, + { + // group call subscription request + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 678 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, + }, + relationships: subscriptionRelations, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(3)], + batched: true, + statusCode: 200, + destination, + }, + { + metadata: [generateMetadata(4)], + batched: false, + statusCode: 400, + error: 'Event type random is not supported', + statTags: { + destType: 'KLAVIYO', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'router', + implementation: 'native', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + destination, + }, + { + metadata: [generateMetadata(5)], + batched: false, + statusCode: 400, + error: 'groupId is a required field for group events', + statTags: { + destType: 'KLAVIYO', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'router', + implementation: 'native', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + }, + destination, + }, + ], + }, + }, + }, + }, + { + id: 'klaviyo-router-150624-test-2', + name: 'klaviyo', + description: '150624 -> Router Test to test batching based upon same message type', + scenario: 'Framework', + successCriteria: + 'All the subscription events from same type of call should be batched. This case does not contain any events which can be batched', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + destination, + metadata: generateMetadata(1), + message: { + type: 'identify', + sentAt: '2021-01-03T17:02:53.195Z', + userId: 'test', + channel: 'web', + context: { + os: { name: '', version: '' }, + app: { + name: 'RudderLabs JavaScript SDK', + build: '1.0.0', + version: '1.1.11', + namespace: 'com.rudderlabs.javascript', + }, + traits: { + firstName: 'Test', + lastName: 'Rudderlabs', + email: 'test_1@rudderstack.com', + phone: '+12 345 578 900', + userId: 'Testc', + title: 'Developer', + organization: 'Rudder', + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + Flagged: false, + Residence: 'Shibuya', + properties: { listId: 'XUepkK', subscribe: true, consent: ['email'] }, + }, + locale: 'en-US', + screen: { density: 2 }, + library: { name: 'RudderLabs JavaScript SDK', version: '1.1.11' }, + campaign: {}, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0', + }, + rudderId: '8f8fa6b5-8e24-489c-8e22-61f23f2e364f', + messageId: '2116ef8c-efc3-4ca4-851b-02ee60dad6ff', + anonymousId: '97c46c81-3140-456d-b2a9-690d70aaca35', + integrations: { All: true }, + originalTimestamp: '2021-01-03T17:02:53.193Z', + }, + }, + { + destination, + metadata: generateMetadata(2), + message: { + type: 'identify', + sentAt: '2021-01-03T17:02:53.195Z', + userId: 'test', + channel: 'web', + context: { + os: { name: '', version: '' }, + app: { + name: 'RudderLabs JavaScript SDK', + build: '1.0.0', + version: '1.1.11', + namespace: 'com.rudderlabs.javascript', + }, + traits: { + firstName: 'Test', + lastName: 'Rudderlabs', + email: 'test@rudderstack.com', + phone: '+12 345 578 900', + userId: 'test', + title: 'Developer', + organization: 'Rudder', + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + Flagged: false, + Residence: 'Shibuya', + properties: { listId: 'XUepkK', subscribe: true, consent: ['email', 'sms'] }, + }, + locale: 'en-US', + screen: { density: 2 }, + library: { name: 'RudderLabs JavaScript SDK', version: '1.1.11' }, + campaign: {}, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0', + }, + rudderId: '8f8fa6b5-8e24-489c-8e22-61f23f2e364f', + messageId: '2116ef8c-efc3-4ca4-851b-02ee60dad6ff', + anonymousId: '97c46c81-3140-456d-b2a9-690d70aaca35', + integrations: { All: true }, + originalTimestamp: '2021-01-03T17:02:53.193Z', + }, + }, + ], + destType: 'klaviyo', + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + // profile for identify 1 + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'test', + email: 'test_1@rudderstack.com', + first_name: 'Test', + last_name: 'Rudderlabs', + phone_number: '+12 345 578 900', + anonymous_id: '97c46c81-3140-456d-b2a9-690d70aaca35', + title: 'Developer', + organization: 'Rudder', + location: { + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + }, + properties: { Flagged: false, Residence: 'Shibuya' }, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + // profile for identify 2 + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'test', + email: 'test@rudderstack.com', + first_name: 'Test', + last_name: 'Rudderlabs', + phone_number: '+12 345 578 900', + anonymous_id: '97c46c81-3140-456d-b2a9-690d70aaca35', + title: 'Developer', + organization: 'Rudder', + location: { + city: 'Tokyo', + region: 'Kanto', + country: 'JP', + zip: '100-0001', + }, + properties: { Flagged: false, Residence: 'Shibuya' }, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + // subscriptiopn for both identify 1 and 2 + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'test_1@rudderstack.com', + phone_number: '+12 345 578 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + { + type: 'profile', + attributes: { + email: 'test@rudderstack.com', + phone_number: '+12 345 578 900', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + sms: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, + }, + relationships: subscriptionRelations, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(1), generateMetadata(2)], + batched: true, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, + { + id: 'klaviyo-router-150624-test-3', + name: 'klaviyo', + description: + '150624 -> Router tests to have some anonymous track event, some identify events with subscription and some identified track event', + scenario: 'Framework', + successCriteria: + 'All the subscription events under same message type should be batched and respective profile requests should also be placed in same batched request', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + alreadyTransformedEvent, + { + message: { + // user 1 track call with userId and anonymousId + channel: 'web', + context: { + traits: { + email: 'testklaviyo1@email.com', + firstname: 'Test Klaviyo 1', + }, + }, + type: 'track', + anonymousId: 'anonTestKlaviyo1', + userId: 'testKlaviyo1', + event: 'purchase', + properties: { + price: '12', + }, + }, + metadata: generateMetadata(1, 'testKlaviyo1'), + destination, + }, + { + message: { + // Anonymous Tracking -> user 2 track call with anonymousId only + channel: 'web', + context: { + traits: {}, + }, + type: 'track', + anonymousId: 'anonTestKlaviyo2', + event: 'viewed product', + properties: { + price: '120', + }, + }, + metadata: generateMetadata(2), + destination, + }, + { + message: { + // user 2 idenitfy call with anonymousId and subscription + channel: 'web', + traits: { + email: 'testklaviyo2@rs.com', + firstname: 'Test Klaviyo 2', + properties: { + subscribe: true, + listId: 'configListId', + consent: ['email'], + }, + }, + context: {}, + anonymousId: 'anonTestKlaviyo2', + type: 'identify', + userId: 'testKlaviyo2', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(3, 'testKlaviyo2'), + destination, + }, + { + message: { + // user 2 track call with email only + channel: 'web', + context: { + traits: { + email: 'testklaviyo2@email.com', + firstname: 'Test Klaviyo 2', + }, + }, + type: 'track', + userId: 'testKlaviyo2', + event: 'purchase', + properties: { + price: '120', + }, + }, + metadata: generateMetadata(4, 'testKlaviyo2'), + destination, + }, + { + message: { + // for user 3 identify call without anonymousId and subscriptiontraits: + channel: 'web', + traits: { + email: 'testklaviyo3@rs.com', + firstname: 'Test Klaviyo 3', + properties: { + subscribe: true, + listId: 'configListId', + consent: ['email', 'sms'], + }, + }, + context: {}, + type: 'identify', + userId: 'testKlaviyo3', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(5, 'testKlaviyo3'), + destination, + }, + ], + destType: 'klaviyo', + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: transformResultBuilder({ + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: commonOutputSubscriptionProps, + relationships: subscriptionRelations, + }, + }, + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: headers, + method: 'POST', + userId: '', + }), + metadata: [generateMetadata(10)], + batched: false, + statusCode: 200, + destination, + }, + { + // user 1 track call with userId and anonymousId + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'event', + attributes: { + properties: { + price: '12', + }, + profile: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo1', + anonymous_id: 'anonTestKlaviyo1', + email: 'testklaviyo1@email.com', + first_name: 'Test Klaviyo 1', + properties: {}, + meta: { + patch_properties: {}, + }, + }, + }, + }, + metric: { + data: { + type: 'metric', + attributes: { + name: 'purchase', + }, + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(1, 'testKlaviyo1')], + batched: false, + statusCode: 200, + destination, + }, + { + // anonn event for user 2 + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'event', + attributes: { + properties: { + price: '120', + }, + profile: { + data: { + type: 'profile', + attributes: { + anonymous_id: 'anonTestKlaviyo2', + properties: {}, + meta: { + patch_properties: {}, + }, + }, + }, + }, + metric: { + data: { + type: 'metric', + attributes: { + name: 'viewed product', + }, + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(2)], + batched: false, + statusCode: 200, + destination, + }, + { + // identify call for user 2 and user 3 with subscription + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-import', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo2', + anonymous_id: 'anonTestKlaviyo2', + email: 'testklaviyo2@rs.com', + first_name: 'Test Klaviyo 2', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-import', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo3', + email: 'testklaviyo3@rs.com', + first_name: 'Test Klaviyo 3', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'testklaviyo2@rs.com', + subscriptions: { + email: { + marketing: { + consent: 'SUBSCRIBED', + }, + }, + }, + }, + }, + { + type: 'profile', + attributes: { + email: 'testklaviyo3@rs.com', + subscriptions: { + email: { + marketing: { + consent: 'SUBSCRIBED', + }, + }, + }, + }, + }, + ], + }, + }, + relationships: { + list: { + data: { + type: 'list', + id: 'configListId', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(3, 'testKlaviyo2'), generateMetadata(5, 'testKlaviyo3')], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'event', + attributes: { + properties: { + price: '120', + }, + profile: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo2', + email: 'testklaviyo2@email.com', + first_name: 'Test Klaviyo 2', + properties: {}, + meta: { + patch_properties: {}, + }, + }, + }, + }, + metric: { + data: { + type: 'metric', + attributes: { + name: 'purchase', + }, + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(4, 'testKlaviyo2')], + batched: false, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, + { + id: 'klaviyo-router-150624-test-4', + name: 'klaviyo', + description: '150624 -> Retl Router tests to have retl ', + scenario: 'Framework', + successCriteria: + 'All the subscription events with same message type should be batched and respective profile requests should also be placed in same batched request', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + channel: 'web', + context: { + mappedToDestination: 'true', + externalId: [ + { + id: 'testklaviyo1@email.com', + identifierType: 'email', + type: 'KLAVIYO-profile_v2', + }, + ], + traits: { + properties: { + subscribe: false, + }, + email: 'testklaviyo1@email.com', + firstname: 'Test Klaviyo 1', + }, + }, + type: 'identify', + anonymousId: 'anonTestKlaviyo1', + userId: 'testKlaviyo1', + }, + metadata: generateMetadata(1), + destination, + }, + { + message: { + channel: 'web', + traits: { + email: 'testklaviyo2@rs.com', + firstname: 'Test Klaviyo 2', + properties: { + subscribe: true, + listId: 'configListId', + consent: ['email'], + }, + }, + context: { + mappedToDestination: 'true', + externalId: [ + { + id: 'testklaviyo2@rs.com', + identifierType: 'email', + type: 'KLAVIYO-profile_v2', + }, + ], + }, + anonymousId: 'anonTestKlaviyo2', + type: 'identify', + userId: 'testKlaviyo2', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(2), + destination, + }, + ], + destType: 'klaviyo', + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-import', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testklaviyo2@rs.com', + anonymous_id: 'anonTestKlaviyo2', + email: 'testklaviyo2@rs.com', + first_name: 'Test Klaviyo 2', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'testklaviyo2@rs.com', + subscriptions: { + email: { + marketing: { + consent: 'SUBSCRIBED', + }, + }, + }, + }, + }, + ], + }, + }, + relationships: { + list: { + data: { + type: 'list', + id: 'configListId', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(2)], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-import', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testklaviyo1@email.com', + anonymous_id: 'anonTestKlaviyo1', + email: 'testklaviyo1@email.com', + first_name: 'Test Klaviyo 1', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(1)], + batched: true, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, + { + id: 'klaviyo-router-150624-test-5', + name: 'klaviyo', + description: '150624 -> Only Identify calls with some subcribe and some unsubscribe operation', + scenario: 'Framework', + successCriteria: + 'All the subscription events with same listId should be batched and same for unsubscribe as well.', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + // user 1 idenitfy call with anonymousId and subscription as true + channel: 'web', + traits: { + email: 'testklaviyo1@rs.com', + firstname: 'Test Klaviyo 1', + properties: { + subscribe: true, + listId: 'configListId', + consent: ['email'], + }, + }, + context: {}, + anonymousId: 'anonTestKlaviyo1', + type: 'identify', + userId: 'testKlaviyo1', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(1, 'testKlaviyo1'), + destination, + }, + { + message: { + // user 2 idenitfy call with no anonymousId and subscription as true + channel: 'web', + traits: { + email: 'testklaviyo2@rs.com', + firstname: 'Test Klaviyo 2', + properties: { + subscribe: true, + listId: 'configListId', + consent: ['email'], + }, + }, + context: {}, + type: 'identify', + userId: 'testKlaviyo2', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(2, 'testKlaviyo2'), + destination, + }, + { + message: { + // user 3 idenitfy call with no anonymousId and subscription as false + channel: 'web', + traits: { + email: 'testklaviyo3@rs.com', + firstname: 'Test Klaviyo 3', + properties: { + subscribe: false, + listId: 'configListId', + consent: ['email'], + }, + }, + context: {}, + type: 'identify', + userId: 'testKlaviyo3', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(3, 'testKlaviyo3'), + destination, + }, + { + message: { + // user 4 idenitfy call with anonymousId and subscription as false + channel: 'web', + traits: { + email: 'testklaviyo4@rs.com', + firstname: 'Test Klaviyo 4', + properties: { + subscribe: false, + listId: 'configListId', + consent: ['email'], + }, + }, + context: {}, + type: 'identify', + anonymousId: 'anon id 4', + userId: 'testKlaviyo4', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(4, 'testKlaviyo4'), + destination, + }, + ], + destType: 'klaviyo', + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + // 2 identify calls and one batched subscription request for user 1 and user 2 + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo1', + email: 'testklaviyo1@rs.com', + first_name: 'Test Klaviyo 1', + anonymous_id: 'anonTestKlaviyo1', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo2', + email: 'testklaviyo2@rs.com', + first_name: 'Test Klaviyo 2', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-create-jobs', + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-create-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'testklaviyo1@rs.com', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + { + type: 'profile', + attributes: { + email: 'testklaviyo2@rs.com', + subscriptions: { + email: { marketing: { consent: 'SUBSCRIBED' } }, + }, + }, + }, + ], + }, + }, + relationships: { + list: { + data: { + type: 'list', + id: 'configListId', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(1, 'testKlaviyo1'), generateMetadata(2, 'testKlaviyo2')], + batched: true, + statusCode: 200, + destination, + }, + { + // 2 identify calls and one batched unsubscription request for user 3 and user 4 + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo3', + email: 'testklaviyo3@rs.com', + first_name: 'Test Klaviyo 3', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: userProfileCommonEndpoint, + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo4', + email: 'testklaviyo4@rs.com', + first_name: 'Test Klaviyo 4', + anonymous_id: 'anon id 4', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-delete-jobs', + headers, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-delete-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'testklaviyo3@rs.com', + }, + }, + { + type: 'profile', + attributes: { + email: 'testklaviyo4@rs.com', + }, + }, + ], + }, + }, + relationships: { + list: { + data: { + type: 'list', + id: 'configListId', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(3, 'testKlaviyo3'), generateMetadata(4, 'testKlaviyo4')], + batched: true, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, + { + id: 'klaviyo-router-150624-test-6', + name: 'klaviyo', + description: + '150624 -> Router tests to have some anonymous track event, some identify events with unsubscription and some identified track event', + scenario: 'Framework', + successCriteria: + 'All the unsubscription events under same message type should be batched and respective profile requests should also be placed in same batched request', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + // user 1 track call with userId and anonymousId + channel: 'web', + context: { + traits: { + email: 'testklaviyo1@email.com', + firstname: 'Test Klaviyo 1', + }, + }, + type: 'track', + anonymousId: 'anonTestKlaviyo1', + userId: 'testKlaviyo1', + event: 'purchase', + properties: { + price: '12', + }, + }, + metadata: generateMetadata(1, 'testKlaviyo1'), + destination, + }, + { + message: { + // Anonymous Tracking -> user 2 track call with anonymousId only + channel: 'web', + context: { + traits: {}, + }, + type: 'track', + anonymousId: 'anonTestKlaviyo2', + event: 'viewed product', + properties: { + price: '120', + }, + }, + metadata: generateMetadata(2), + destination, + }, + { + message: { + // user 2 idenitfy call with anonymousId and subscription + channel: 'web', + traits: { + email: 'testklaviyo2@rs.com', + firstname: 'Test Klaviyo 2', + properties: { + subscribe: false, + listId: 'configListId', + consent: ['email'], + }, + }, + context: {}, + anonymousId: 'anonTestKlaviyo2', + type: 'identify', + userId: 'testKlaviyo2', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(3, 'testKlaviyo2'), + destination, + }, + { + message: { + // user 2 track call with email only + channel: 'web', + context: { + traits: { + email: 'testklaviyo2@email.com', + firstname: 'Test Klaviyo 2', + }, + }, + type: 'track', + userId: 'testKlaviyo2', + event: 'purchase', + properties: { + price: '120', + }, + }, + metadata: generateMetadata(4, 'testKlaviyo2'), + destination, + }, + { + message: { + // for user 3 identify call without anonymousId and subscriptiontraits: + channel: 'web', + traits: { + email: 'testklaviyo3@rs.com', + firstname: 'Test Klaviyo 3', + properties: { + subscribe: false, + listId: 'configListId', + consent: ['email', 'sms'], + }, + }, + context: {}, + type: 'identify', + userId: 'testKlaviyo3', + integrations: { + All: true, + }, + }, + metadata: generateMetadata(5, 'testKlaviyo3'), + destination, + }, + ], + destType: 'klaviyo', + }, + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + // user 1 track call with userId and anonymousId + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'event', + attributes: { + properties: { + price: '12', + }, + profile: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo1', + anonymous_id: 'anonTestKlaviyo1', + email: 'testklaviyo1@email.com', + first_name: 'Test Klaviyo 1', + properties: {}, + meta: { + patch_properties: {}, + }, + }, + }, + }, + metric: { + data: { + type: 'metric', + attributes: { + name: 'purchase', + }, + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(1, 'testKlaviyo1')], + batched: false, + statusCode: 200, + destination, + }, + { + // anonn event for user 2 + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'event', + attributes: { + properties: { + price: '120', + }, + profile: { + data: { + type: 'profile', + attributes: { + anonymous_id: 'anonTestKlaviyo2', + properties: {}, + meta: { + patch_properties: {}, + }, + }, + }, + }, + metric: { + data: { + type: 'metric', + attributes: { + name: 'viewed product', + }, + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(2)], + batched: false, + statusCode: 200, + destination, + }, + { + // identify call for user 2 and user 3 with subscription + batchedRequest: [ + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-import', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo2', + anonymous_id: 'anonTestKlaviyo2', + email: 'testklaviyo2@rs.com', + first_name: 'Test Klaviyo 2', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-import', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo3', + email: 'testklaviyo3@rs.com', + first_name: 'Test Klaviyo 3', + properties: {}, + }, + meta: { + patch_properties: {}, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/profile-subscription-bulk-delete-jobs', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + 'Content-Type': 'application/json', + Accept: 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'profile-subscription-bulk-delete-job', + attributes: { + profiles: { + data: [ + { + type: 'profile', + attributes: { + email: 'testklaviyo2@rs.com', + }, + }, + { + type: 'profile', + attributes: { + email: 'testklaviyo3@rs.com', + }, + }, + ], + }, + }, + relationships: { + list: { + data: { + type: 'list', + id: 'configListId', + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + ], + metadata: [generateMetadata(3, 'testKlaviyo2'), generateMetadata(5, 'testKlaviyo3')], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://a.klaviyo.com/api/events', + headers: { + Authorization: 'Klaviyo-API-Key dummyPrivateApiKey', + Accept: 'application/json', + 'Content-Type': 'application/json', + revision: '2024-06-15', + }, + params: {}, + body: { + JSON: { + data: { + type: 'event', + attributes: { + properties: { + price: '120', + }, + profile: { + data: { + type: 'profile', + attributes: { + external_id: 'testKlaviyo2', + email: 'testklaviyo2@email.com', + first_name: 'Test Klaviyo 2', + properties: {}, + meta: { + patch_properties: {}, + }, + }, + }, + }, + metric: { + data: { + type: 'metric', + attributes: { + name: 'purchase', + }, + }, + }, + }, + }, + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(4, 'testKlaviyo2')], + batched: false, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/koala/processor/data.ts b/test/integrations/destinations/koala/processor/data.ts index b866353066..ec1fcd3477 100644 --- a/test/integrations/destinations/koala/processor/data.ts +++ b/test/integrations/destinations/koala/processor/data.ts @@ -159,6 +159,7 @@ export const data = [ { type: 'identify', sent_at: '2024-01-23T08:35:17.342Z', + source: 'rudderstack-cloud', traits: { FirstName: 'John', LastName: 'Doe', diff --git a/test/integrations/destinations/mailchimp/network.ts b/test/integrations/destinations/mailchimp/network.ts index b036bf566c..a29712ce9a 100644 --- a/test/integrations/destinations/mailchimp/network.ts +++ b/test/integrations/destinations/mailchimp/network.ts @@ -77,4 +77,42 @@ export const networkCallsData = [ status: 200, }, }, + { + httpReq: { + url: 'https://usXX.api.mailchimp.com/3.0/lists/aud111/members/5587981bdf09024971ff9ddfb2590a6d', + method: 'GET', + headers: { + Authorization: 'Basic YXBpS2V5OmFwaUtleS1kdW1teUFwaUtleQ==', + }, + }, + httpRes: { + data: { + type: 'https://mailchimp.com/developer/marketing/docs/errors/', + title: 'API Key Invalid', + status: 401, + detail: "Your API key may be invalid, or you've attempted to access the wrong datacenter.", + instance: 'd2e09e5b-7c28-8585-68db-8feaf57ee0f7', + }, + status: 401, + }, + }, + { + httpReq: { + url: 'https://usXX.api.mailchimp.com/3.0/lists/aud111', + method: 'GET', + headers: { + Authorization: 'Basic YXBpS2V5OmFwaUtleS1kdW1teUFwaUtleQ==', + }, + }, + httpRes: { + data: { + type: 'https://mailchimp.com/developer/marketing/docs/errors/', + title: 'API Key Invalid', + status: 401, + detail: "Your API key may be invalid, or you've attempted to access the wrong datacenter.", + instance: 'd2e09e5b-7c28-8585-68db-8feaf57ee0f7', + }, + status: 401, + }, + }, ]; diff --git a/test/integrations/destinations/mailchimp/processor/data.ts b/test/integrations/destinations/mailchimp/processor/data.ts index a0ee5de3d3..bf3cb6ad06 100644 --- a/test/integrations/destinations/mailchimp/processor/data.ts +++ b/test/integrations/destinations/mailchimp/processor/data.ts @@ -345,7 +345,7 @@ export const data = [ implementation: 'native', module: 'destination', }, - statusCode: 400, + statusCode: 401, }, ], }, diff --git a/test/integrations/destinations/moengage/processor/data.ts b/test/integrations/destinations/moengage/processor/data.ts index 1ce8705f53..df6e1226b6 100644 --- a/test/integrations/destinations/moengage/processor/data.ts +++ b/test/integrations/destinations/moengage/processor/data.ts @@ -1,3 +1,7 @@ +const mockFns = (_) => { + jest.spyOn(Date, 'now').mockReturnValueOnce(new Date('2023-10-14T00:00:00.000Z').valueOf()); +}; + export const data = [ { name: 'moengage', @@ -295,6 +299,7 @@ export const data = [ ], }, }, + mockFns, }, { name: 'moengage', @@ -1629,6 +1634,7 @@ export const data = [ ], }, }, + mockFns, }, { name: 'moengage', diff --git a/test/integrations/destinations/moengage/router/data.ts b/test/integrations/destinations/moengage/router/data.ts index 0f8a3de41b..b24453fd34 100644 --- a/test/integrations/destinations/moengage/router/data.ts +++ b/test/integrations/destinations/moengage/router/data.ts @@ -1,3 +1,7 @@ +const mockFns = (_) => { + jest.spyOn(Date, 'now').mockReturnValueOnce(new Date('2023-10-14T00:00:00.000Z').valueOf()); +}; + export const data = [ { name: 'moengage', @@ -432,5 +436,6 @@ export const data = [ }, }, }, + mockFns, }, ]; diff --git a/test/integrations/destinations/mp/common.ts b/test/integrations/destinations/mp/common.ts index d40afa0c02..f8aae81780 100644 --- a/test/integrations/destinations/mp/common.ts +++ b/test/integrations/destinations/mp/common.ts @@ -1,7 +1,7 @@ import { Destination } from '../../../../src/types'; const defaultMockFns = () => { - jest.spyOn(Date, 'now').mockImplementation(() => new Date(Date.UTC(2020, 0, 25)).valueOf()); + jest.spyOn(Date, 'now').mockReturnValue(new Date(Date.UTC(2020, 0, 25)).valueOf()); }; const sampleDestination: Destination = { diff --git a/test/integrations/destinations/mp/processor/data.ts b/test/integrations/destinations/mp/processor/data.ts index db5bc840c2..d13cf64cae 100644 --- a/test/integrations/destinations/mp/processor/data.ts +++ b/test/integrations/destinations/mp/processor/data.ts @@ -3670,6 +3670,9 @@ export const data = [ ], }, }, + mockFns: (_) => { + jest.spyOn(Date, 'now').mockReturnValueOnce(new Date('2018-12-20T10:26:33.451Z').valueOf()); + }, }, { name: 'mp', diff --git a/test/integrations/destinations/optimizely_fullstack/processor/data.ts b/test/integrations/destinations/optimizely_fullstack/processor/data.ts index 52fbdfe5fe..fb514bc6b8 100644 --- a/test/integrations/destinations/optimizely_fullstack/processor/data.ts +++ b/test/integrations/destinations/optimizely_fullstack/processor/data.ts @@ -1,7 +1,7 @@ import utils from '../../../../../src/v0/util'; export const mockFns = (_) => { // @ts-ignore - jest.spyOn(utils, 'generateUUID').mockImplementation(() => 'generated_uuid'); + jest.spyOn(utils, 'generateUUID').mockReturnValueOnce('generated_uuid'); }; export const data = [ { diff --git a/test/integrations/destinations/pagerduty/processor/data.ts b/test/integrations/destinations/pagerduty/processor/data.ts index 97fe22daa0..bfa924c3bd 100644 --- a/test/integrations/destinations/pagerduty/processor/data.ts +++ b/test/integrations/destinations/pagerduty/processor/data.ts @@ -1,287 +1,287 @@ export const data = [ - { - name: 'pagerduty', - description: 'No Message type', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - sentAt: '2022-10-11T13:10:54.877+05:30', - userId: 'user@45', - rudderId: 'caae04c5-959f-467b-a293-86f6c62d59e6', - messageId: 'b6ce7f31-5d76-4240-94d2-3eea020ef791', - timestamp: '2022-10-11T13:10:52.137+05:30', - receivedAt: '2022-10-11T13:10:52.138+05:30', - request_ip: '[::1]', - originalTimestamp: '2022-10-11T13:10:54.877+05:30', - }, - destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - error: 'Event type is required', - statTags: { - destType: 'PAGERDUTY', - errorCategory: 'dataValidation', - errorType: 'instrumentation', - feature: 'processor', - implementation: 'native', - module: 'destination', - }, - statusCode: 400, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'Routing Key is not present', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - sentAt: '2022-10-11T13:10:54.877+05:30', - userId: 'user@45', - context: {}, - rudderId: 'caae04c5-959f-467b-a293-86f6c62d59e6', - messageId: 'b6ce7f31-5d76-4240-94d2-3eea020ef791', - timestamp: '2022-10-11T13:10:52.137+05:30', - receivedAt: '2022-10-11T13:10:52.138+05:30', - request_ip: '[::1]', - originalTimestamp: '2022-10-11T13:10:54.877+05:30', - }, - destination: { Config: {} }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - error: 'Routing Key Is Required', - statTags: { - destType: 'PAGERDUTY', - errorCategory: 'dataValidation', - errorType: 'configuration', - feature: 'processor', - implementation: 'native', - module: 'destination', - }, - statusCode: 400, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'Unsupported Event type', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - type: 'alias', - sentAt: '2022-10-11T13:10:54.877+05:30', - userId: 'user@45', - context: {}, - rudderId: 'caae04c5-959f-467b-a293-86f6c62d59e6', - messageId: 'b6ce7f31-5d76-4240-94d2-3eea020ef791', - timestamp: '2022-10-11T13:10:52.137+05:30', - receivedAt: '2022-10-11T13:10:52.138+05:30', - request_ip: '[::1]', - originalTimestamp: '2022-10-11T13:10:54.877+05:30', - }, - destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - error: 'Event type alias is not supported', - statTags: { - destType: 'PAGERDUTY', - errorCategory: 'dataValidation', - errorType: 'instrumentation', - feature: 'processor', - implementation: 'native', - module: 'destination', - }, - statusCode: 400, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'event name is not present', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: {}, - }, - destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - error: 'Event name is required', - statTags: { - destType: 'PAGERDUTY', - errorCategory: 'dataValidation', - errorType: 'instrumentation', - feature: 'processor', - implementation: 'native', - module: 'destination', - }, - statusCode: 400, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'Parameter source is not present', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - event: 'Event name is required', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: { dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e' }, - }, - destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - error: 'Missing required value from "properties.source"', - statTags: { - destType: 'PAGERDUTY', - errorCategory: 'dataValidation', - errorType: 'instrumentation', - feature: 'processor', - implementation: 'native', - module: 'destination', - }, - statusCode: 400, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'dedup_key is not present', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - event: 'Event name is required', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: { action: 'resolve' }, - }, - destination: { - Config: { - routingKey: '9552b56325dc490bd0139be85f7b8fac', - dedupKeyFieldIdentifier: 'properties.dedupKey', - }, - }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - error: 'dedup_key required for resolve events', - statTags: { - destType: 'PAGERDUTY', - errorCategory: 'dataValidation', - errorType: 'instrumentation', - feature: 'processor', - implementation: 'native', - module: 'destination', - }, - statusCode: 400, - }, - ], - }, - }, - }, + // { + // name: 'pagerduty', + // description: 'No Message type', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // sentAt: '2022-10-11T13:10:54.877+05:30', + // userId: 'user@45', + // rudderId: 'caae04c5-959f-467b-a293-86f6c62d59e6', + // messageId: 'b6ce7f31-5d76-4240-94d2-3eea020ef791', + // timestamp: '2022-10-11T13:10:52.137+05:30', + // receivedAt: '2022-10-11T13:10:52.138+05:30', + // request_ip: '[::1]', + // originalTimestamp: '2022-10-11T13:10:54.877+05:30', + // }, + // destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // error: 'Event type is required', + // statTags: { + // destType: 'PAGERDUTY', + // errorCategory: 'dataValidation', + // errorType: 'instrumentation', + // feature: 'processor', + // implementation: 'native', + // module: 'destination', + // }, + // statusCode: 400, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'Routing Key is not present', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // sentAt: '2022-10-11T13:10:54.877+05:30', + // userId: 'user@45', + // context: {}, + // rudderId: 'caae04c5-959f-467b-a293-86f6c62d59e6', + // messageId: 'b6ce7f31-5d76-4240-94d2-3eea020ef791', + // timestamp: '2022-10-11T13:10:52.137+05:30', + // receivedAt: '2022-10-11T13:10:52.138+05:30', + // request_ip: '[::1]', + // originalTimestamp: '2022-10-11T13:10:54.877+05:30', + // }, + // destination: { Config: {} }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // error: 'Routing Key Is Required', + // statTags: { + // destType: 'PAGERDUTY', + // errorCategory: 'dataValidation', + // errorType: 'configuration', + // feature: 'processor', + // implementation: 'native', + // module: 'destination', + // }, + // statusCode: 400, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'Unsupported Event type', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // type: 'alias', + // sentAt: '2022-10-11T13:10:54.877+05:30', + // userId: 'user@45', + // context: {}, + // rudderId: 'caae04c5-959f-467b-a293-86f6c62d59e6', + // messageId: 'b6ce7f31-5d76-4240-94d2-3eea020ef791', + // timestamp: '2022-10-11T13:10:52.137+05:30', + // receivedAt: '2022-10-11T13:10:52.138+05:30', + // request_ip: '[::1]', + // originalTimestamp: '2022-10-11T13:10:54.877+05:30', + // }, + // destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // error: 'Event type alias is not supported', + // statTags: { + // destType: 'PAGERDUTY', + // errorCategory: 'dataValidation', + // errorType: 'instrumentation', + // feature: 'processor', + // implementation: 'native', + // module: 'destination', + // }, + // statusCode: 400, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'event name is not present', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: {}, + // }, + // destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // error: 'Event name is required', + // statTags: { + // destType: 'PAGERDUTY', + // errorCategory: 'dataValidation', + // errorType: 'instrumentation', + // feature: 'processor', + // implementation: 'native', + // module: 'destination', + // }, + // statusCode: 400, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'Parameter source is not present', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // event: 'Event name is required', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: { dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e' }, + // }, + // destination: { Config: { routingKey: '9552b56325dc490bd0139be85f7b8fac' } }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // error: 'Missing required value from "properties.source"', + // statTags: { + // destType: 'PAGERDUTY', + // errorCategory: 'dataValidation', + // errorType: 'instrumentation', + // feature: 'processor', + // implementation: 'native', + // module: 'destination', + // }, + // statusCode: 400, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'dedup_key is not present', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // event: 'Event name is required', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: { action: 'resolve' }, + // }, + // destination: { + // Config: { + // routingKey: '9552b56325dc490bd0139be85f7b8fac', + // dedupKeyFieldIdentifier: 'properties.dedupKey', + // }, + // }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // error: 'dedup_key required for resolve events', + // statTags: { + // destType: 'PAGERDUTY', + // errorCategory: 'dataValidation', + // errorType: 'instrumentation', + // feature: 'processor', + // implementation: 'native', + // module: 'destination', + // }, + // statusCode: 400, + // }, + // ], + // }, + // }, + // }, { name: 'pagerduty', description: 'Timestamp older then 90 days', @@ -363,420 +363,425 @@ export const data = [ ], }, }, - }, - { - name: 'pagerduty', - description: 'Trigger event', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - event: 'apiSecret is not present', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: { - action: 'trigger', - dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e', - severity: 'critical', - component: 'ui', - source: 'rudder-webapp', - group: 'destination', - class: 'connection settings', - customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, - imageURLs: [ - { - src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', - alt: 'first image', - }, - { - src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', - alt: 'second image', - }, - { alt: 'third image' }, - ], - linkURLs: [ - { - href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', - text: 'Js Object Error', - }, - { - href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', - text: 'Stack Overflow Error', - }, - { text: 'Destructure Error' }, - ], - }, - }, - destination: { - Config: { - routingKey: '9552b56325dc490bd0139be85f7b8fac', - dedupKeyFieldIdentifier: 'properties.dedupKey', - }, - }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - output: { - body: { - XML: {}, - FORM: {}, - JSON: { - links: [ - { - href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', - text: 'Js Object Error', - }, - { - href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', - text: 'Stack Overflow Error', - }, - ], - images: [ - { - alt: 'first image', - src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', - }, - { - alt: 'second image', - src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', - }, - ], - payload: { - class: 'connection settings', - group: 'destination', - source: 'rudder-webapp', - summary: 'apiSecret is not present', - severity: 'critical', - component: 'ui', - custom_details: { 'ping time': '1500ms', 'load avg': 0.75 }, - }, - dedup_key: '9116b734-7e6b-4497-ab51-c16744d4487e', - routing_key: '9552b56325dc490bd0139be85f7b8fac', - event_action: 'trigger', - }, - JSON_ARRAY: {}, - }, - type: 'REST', - files: {}, - method: 'POST', - params: {}, - headers: { 'Content-Type': 'application/json' }, - version: '1', - endpoint: 'https://events.pagerduty.com/v2/enqueue', - userId: '', - }, - statusCode: 200, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'Acknowledge event', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - event: 'apiSecret is not present', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: { - action: 'acknowledge', - dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e', - severity: 'critical', - component: 'ui', - source: 'rudder-webapp', - group: 'destination', - class: 'connection settings', - customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, - imageURLs: [ - { - src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', - alt: 'first image', - }, - { - src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', - alt: 'second image', - }, - { alt: 'third image' }, - ], - linkURLs: [ - { - href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', - text: 'Js Object Error', - }, - { - href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', - text: 'Stack Overflow Error', - }, - { text: 'Destructure Error' }, - ], - }, - }, - destination: { - Config: { - routingKey: '9552b56325dc490bd0139be85f7b8fac', - dedupKeyFieldIdentifier: 'properties.dedupKey', - }, - }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - output: { - body: { - XML: {}, - FORM: {}, - JSON: { - dedup_key: '9116b734-7e6b-4497-ab51-c16744d4487e', - routing_key: '9552b56325dc490bd0139be85f7b8fac', - event_action: 'acknowledge', - }, - JSON_ARRAY: {}, - }, - type: 'REST', - files: {}, - method: 'POST', - params: {}, - headers: { 'Content-Type': 'application/json' }, - version: '1', - endpoint: 'https://events.pagerduty.com/v2/enqueue', - userId: '', - }, - statusCode: 200, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'Resolve event', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - event: 'apiSecret is not present', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: { - action: 'resolve', - dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e', - severity: 'critical', - component: 'ui', - source: 'rudder-webapp', - group: 'destination', - class: 'connection settings', - customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, - imageURLs: [ - { - src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', - alt: 'first image', - }, - { - src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', - alt: 'second image', - }, - { alt: 'third image' }, - ], - linkURLs: [ - { - href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', - text: 'Js Object Error', - }, - { - href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', - text: 'Stack Overflow Error', - }, - { text: 'Destructure Error' }, - ], - }, - }, - destination: { - Config: { - routingKey: '9552b56325dc490bd0139be85f7b8fac', - dedupKeyFieldIdentifier: 'properties.dedupKey', - }, - }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - output: { - body: { - XML: {}, - FORM: {}, - JSON: { - dedup_key: '9116b734-7e6b-4497-ab51-c16744d4487e', - routing_key: '9552b56325dc490bd0139be85f7b8fac', - event_action: 'resolve', - }, - JSON_ARRAY: {}, - }, - type: 'REST', - files: {}, - method: 'POST', - params: {}, - headers: { 'Content-Type': 'application/json' }, - version: '1', - endpoint: 'https://events.pagerduty.com/v2/enqueue', - userId: '', - }, - statusCode: 200, - }, - ], - }, - }, - }, - { - name: 'pagerduty', - description: 'Change event', - feature: 'processor', - module: 'destination', - version: 'v0', - input: { - request: { - body: [ - { - message: { - channel: 'web', - type: 'track', - event: 'Github CI/CD Triggered', - messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', - userId: 'user@45', - properties: { - source: 'rudder-webapp', - customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, - imageURLs: [ - { - src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', - alt: 'first image', - }, - { - src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', - alt: 'second image', - }, - { alt: 'third image' }, - ], - linkURLs: [ - { - href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', - text: 'Js Object Error', - }, - { - href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', - text: 'Stack Overflow Error', - }, - { text: 'Destructure Error' }, - ], - }, - integrations: { pagerduty: { type: 'changeEvent' } }, - }, - destination: { - Config: { - routingKey: '9552b56325dc490bd0139be85f7b8fac', - dedupKeyFieldIdentifier: 'properties.dedupKey', - }, - }, - }, - ], - method: 'POST', - }, - pathSuffix: '', - }, - output: { - response: { - status: 200, - body: [ - { - output: { - body: { - XML: {}, - FORM: {}, - JSON: { - links: [ - { - href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', - text: 'Js Object Error', - }, - { - href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', - text: 'Stack Overflow Error', - }, - ], - images: [ - { - alt: 'first image', - src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', - }, - { - alt: 'second image', - src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', - }, - ], - payload: { - source: 'rudder-webapp', - summary: 'Github CI/CD Triggered', - custom_details: { 'load avg': 0.75, 'ping time': '1500ms' }, - }, - routing_key: '9552b56325dc490bd0139be85f7b8fac', - }, - JSON_ARRAY: {}, - }, - type: 'REST', - files: {}, - method: 'POST', - params: {}, - headers: { 'Content-Type': 'application/json' }, - version: '1', - endpoint: 'https://events.pagerduty.com/v2/change/enqueue', - userId: '', - }, - statusCode: 200, - }, - ], - }, + mockFns: (_) => { + jest.spyOn(Date, 'now').mockImplementation(() => { + return new Date('2022-11-12T15:46:51.000Z').valueOf(); + }); }, }, + // { + // name: 'pagerduty', + // description: 'Trigger event', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // event: 'apiSecret is not present', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: { + // action: 'trigger', + // dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e', + // severity: 'critical', + // component: 'ui', + // source: 'rudder-webapp', + // group: 'destination', + // class: 'connection settings', + // customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, + // imageURLs: [ + // { + // src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', + // alt: 'first image', + // }, + // { + // src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', + // alt: 'second image', + // }, + // { alt: 'third image' }, + // ], + // linkURLs: [ + // { + // href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', + // text: 'Js Object Error', + // }, + // { + // href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', + // text: 'Stack Overflow Error', + // }, + // { text: 'Destructure Error' }, + // ], + // }, + // }, + // destination: { + // Config: { + // routingKey: '9552b56325dc490bd0139be85f7b8fac', + // dedupKeyFieldIdentifier: 'properties.dedupKey', + // }, + // }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // output: { + // body: { + // XML: {}, + // FORM: {}, + // JSON: { + // links: [ + // { + // href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', + // text: 'Js Object Error', + // }, + // { + // href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', + // text: 'Stack Overflow Error', + // }, + // ], + // images: [ + // { + // alt: 'first image', + // src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', + // }, + // { + // alt: 'second image', + // src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', + // }, + // ], + // payload: { + // class: 'connection settings', + // group: 'destination', + // source: 'rudder-webapp', + // summary: 'apiSecret is not present', + // severity: 'critical', + // component: 'ui', + // custom_details: { 'ping time': '1500ms', 'load avg': 0.75 }, + // }, + // dedup_key: '9116b734-7e6b-4497-ab51-c16744d4487e', + // routing_key: '9552b56325dc490bd0139be85f7b8fac', + // event_action: 'trigger', + // }, + // JSON_ARRAY: {}, + // }, + // type: 'REST', + // files: {}, + // method: 'POST', + // params: {}, + // headers: { 'Content-Type': 'application/json' }, + // version: '1', + // endpoint: 'https://events.pagerduty.com/v2/enqueue', + // userId: '', + // }, + // statusCode: 200, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'Acknowledge event', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // event: 'apiSecret is not present', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: { + // action: 'acknowledge', + // dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e', + // severity: 'critical', + // component: 'ui', + // source: 'rudder-webapp', + // group: 'destination', + // class: 'connection settings', + // customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, + // imageURLs: [ + // { + // src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', + // alt: 'first image', + // }, + // { + // src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', + // alt: 'second image', + // }, + // { alt: 'third image' }, + // ], + // linkURLs: [ + // { + // href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', + // text: 'Js Object Error', + // }, + // { + // href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', + // text: 'Stack Overflow Error', + // }, + // { text: 'Destructure Error' }, + // ], + // }, + // }, + // destination: { + // Config: { + // routingKey: '9552b56325dc490bd0139be85f7b8fac', + // dedupKeyFieldIdentifier: 'properties.dedupKey', + // }, + // }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // output: { + // body: { + // XML: {}, + // FORM: {}, + // JSON: { + // dedup_key: '9116b734-7e6b-4497-ab51-c16744d4487e', + // routing_key: '9552b56325dc490bd0139be85f7b8fac', + // event_action: 'acknowledge', + // }, + // JSON_ARRAY: {}, + // }, + // type: 'REST', + // files: {}, + // method: 'POST', + // params: {}, + // headers: { 'Content-Type': 'application/json' }, + // version: '1', + // endpoint: 'https://events.pagerduty.com/v2/enqueue', + // userId: '', + // }, + // statusCode: 200, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'Resolve event', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // event: 'apiSecret is not present', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: { + // action: 'resolve', + // dedupKey: '9116b734-7e6b-4497-ab51-c16744d4487e', + // severity: 'critical', + // component: 'ui', + // source: 'rudder-webapp', + // group: 'destination', + // class: 'connection settings', + // customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, + // imageURLs: [ + // { + // src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', + // alt: 'first image', + // }, + // { + // src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', + // alt: 'second image', + // }, + // { alt: 'third image' }, + // ], + // linkURLs: [ + // { + // href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', + // text: 'Js Object Error', + // }, + // { + // href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', + // text: 'Stack Overflow Error', + // }, + // { text: 'Destructure Error' }, + // ], + // }, + // }, + // destination: { + // Config: { + // routingKey: '9552b56325dc490bd0139be85f7b8fac', + // dedupKeyFieldIdentifier: 'properties.dedupKey', + // }, + // }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // output: { + // body: { + // XML: {}, + // FORM: {}, + // JSON: { + // dedup_key: '9116b734-7e6b-4497-ab51-c16744d4487e', + // routing_key: '9552b56325dc490bd0139be85f7b8fac', + // event_action: 'resolve', + // }, + // JSON_ARRAY: {}, + // }, + // type: 'REST', + // files: {}, + // method: 'POST', + // params: {}, + // headers: { 'Content-Type': 'application/json' }, + // version: '1', + // endpoint: 'https://events.pagerduty.com/v2/enqueue', + // userId: '', + // }, + // statusCode: 200, + // }, + // ], + // }, + // }, + // }, + // { + // name: 'pagerduty', + // description: 'Change event', + // feature: 'processor', + // module: 'destination', + // version: 'v0', + // input: { + // request: { + // body: [ + // { + // message: { + // channel: 'web', + // type: 'track', + // event: 'Github CI/CD Triggered', + // messageId: '9116b734-7e6b-4497-ab51-c16744d4487e', + // userId: 'user@45', + // properties: { + // source: 'rudder-webapp', + // customDetails: { 'ping time': '1500ms', 'load avg': 0.75 }, + // imageURLs: [ + // { + // src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', + // alt: 'first image', + // }, + // { + // src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', + // alt: 'second image', + // }, + // { alt: 'third image' }, + // ], + // linkURLs: [ + // { + // href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', + // text: 'Js Object Error', + // }, + // { + // href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', + // text: 'Stack Overflow Error', + // }, + // { text: 'Destructure Error' }, + // ], + // }, + // integrations: { pagerduty: { type: 'changeEvent' } }, + // }, + // destination: { + // Config: { + // routingKey: '9552b56325dc490bd0139be85f7b8fac', + // dedupKeyFieldIdentifier: 'properties.dedupKey', + // }, + // }, + // }, + // ], + // method: 'POST', + // }, + // pathSuffix: '', + // }, + // output: { + // response: { + // status: 200, + // body: [ + // { + // output: { + // body: { + // XML: {}, + // FORM: {}, + // JSON: { + // links: [ + // { + // href: 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error', + // text: 'Js Object Error', + // }, + // { + // href: 'https://www.techtarget.com/whatis/definition/stack-overflow#:~:text=A%20stack%20overflow%20is%20a,been%20allocated%20to%20that%20stack', + // text: 'Stack Overflow Error', + // }, + // ], + // images: [ + // { + // alt: 'first image', + // src: 'https://static.s4be.cochrane.org/app/uploads/2017/04/shutterstock_531145954.jpg', + // }, + // { + // alt: 'second image', + // src: 'https://chart.googleapis.com/chart?chs=600x400&chd=t:6,2,9,5,2,5,7,4,8,2,1&cht=lc&chds=a&chxt=y&chm=D,0033FF,0,0,5,1', + // }, + // ], + // payload: { + // source: 'rudder-webapp', + // summary: 'Github CI/CD Triggered', + // custom_details: { 'load avg': 0.75, 'ping time': '1500ms' }, + // }, + // routing_key: '9552b56325dc490bd0139be85f7b8fac', + // }, + // JSON_ARRAY: {}, + // }, + // type: 'REST', + // files: {}, + // method: 'POST', + // params: {}, + // headers: { 'Content-Type': 'application/json' }, + // version: '1', + // endpoint: 'https://events.pagerduty.com/v2/change/enqueue', + // userId: '', + // }, + // statusCode: 200, + // }, + // ], + // }, + // }, + // }, ]; diff --git a/test/integrations/destinations/pagerduty/router/data.ts b/test/integrations/destinations/pagerduty/router/data.ts index 87761656f9..26efa4a232 100644 --- a/test/integrations/destinations/pagerduty/router/data.ts +++ b/test/integrations/destinations/pagerduty/router/data.ts @@ -267,5 +267,10 @@ export const data = [ }, }, }, + mockFns: (_) => { + jest.spyOn(Date, 'now').mockImplementation(() => { + return new Date('2023-12-20T10:26:33.451Z').valueOf(); + }); + }, }, ]; diff --git a/test/integrations/destinations/rakuten/processor/track.ts b/test/integrations/destinations/rakuten/processor/track.ts index 74d09b8d4c..8c6bc4863d 100644 --- a/test/integrations/destinations/rakuten/processor/track.ts +++ b/test/integrations/destinations/rakuten/processor/track.ts @@ -45,8 +45,8 @@ export const trackSuccess = [ { sku: 'custom sku 2', name: 'SampleProduct', - quantity: 1, - amount: 30, + quantity: 2, + price: 30.99, coupon: 'SALE50', }, ], @@ -82,7 +82,7 @@ export const trackSuccess = [ mid: 'dummyMarketingId', xml: 1, source: 'rudderstack', - amtlist: '2000|2500|3000', + amtlist: '2000|2500|6198', brandlist: 'SampleBrand||', catidlist: '12345||', catlist: 'Electronics||', @@ -93,7 +93,7 @@ export const trackSuccess = [ sequencelist: '123||', shipbylist: 'Express||', shipidlist: 'SHIP123||', - qlist: '5|5|1', + qlist: '5|5|2', marginlist: '0.15||', markdownlist: '5||', taxexemptlist: 'N||', diff --git a/test/integrations/destinations/reddit/dataDelivery/oauth.ts b/test/integrations/destinations/reddit/dataDelivery/oauth.ts index 90368cd60b..8c0d486a7a 100644 --- a/test/integrations/destinations/reddit/dataDelivery/oauth.ts +++ b/test/integrations/destinations/reddit/dataDelivery/oauth.ts @@ -81,7 +81,7 @@ export const v0oauthScenarios = [ }, output: { response: { - status: 500, + status: 401, body: { output: { authErrorCategory: 'REFRESH_TOKEN', @@ -90,9 +90,53 @@ export const v0oauthScenarios = [ status: 401, }, message: - "Request failed due to Authorization Required 'during reddit response transformation'", + 'Request failed due to Authorization Required during reddit response transformation', statTags: expectedStatTags, - status: 500, + status: 401, + }, + }, + }, + }, + }, + { + id: 'reddit_v0_oauth_scenario_2', + name: 'reddit', + description: '[Proxy v0 API] :: Oauth where error response is an object from destination', + successCriteria: 'Should return 401 with authErrorCategory as REFRESH_TOKEN', + scenario: 'Oauth', + feature: 'dataDelivery', + module: 'destination', + version: 'v0', + input: { + request: { + body: generateProxyV0Payload({ + ...commonRequestParameters, + endpoint: 'https://ads-api.reddit.com/api/v2.0/conversions/events/a2_objResp_401', + }), + method: 'POST', + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'REFRESH_TOKEN', + destinationResponse: { + response: { + success: false, + error: { + reason: 'UNAUTHORIZED', + explanation: + 'This server could not verify that you are authorized to access the document you requested.', + }, + }, + status: 401, + }, + message: + 'This server could not verify that you are authorized to access the document you requested. during reddit response transformation', + statTags: expectedStatTags, + status: 401, }, }, }, @@ -124,21 +168,65 @@ export const v1oauthScenarios = [ }, output: { response: { - status: 500, + status: 401, body: { output: { authErrorCategory: 'REFRESH_TOKEN', message: - "Request failed due to Authorization Required 'during reddit response transformation'", + 'Request failed due to Authorization Required during reddit response transformation', response: [ { error: '"Authorization Required"', metadata: generateMetadata(1), - statusCode: 500, + statusCode: 401, + }, + ], + statTags: expectedStatTags, + status: 401, + }, + }, + }, + }, + }, + { + id: 'reddit_v1_oauth_scenario_2', + name: 'reddit', + description: '[Proxy v1 API] :: Oauth where error response is an object from destination', + successCriteria: 'Should return 401 with authErrorCategory as REFRESH_TOKEN', + scenario: 'Oauth', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + ...commonRequestParameters, + endpoint: 'https://ads-api.reddit.com/api/v2.0/conversions/events/a2_objResp_401', + }, + [generateMetadata(1)], + ), + method: 'POST', + }, + }, + output: { + response: { + status: 401, + body: { + output: { + authErrorCategory: 'REFRESH_TOKEN', + message: + 'This server could not verify that you are authorized to access the document you requested. during reddit response transformation', + response: [ + { + error: + '{"success":false,"error":{"reason":"UNAUTHORIZED","explanation":"This server could not verify that you are authorized to access the document you requested."}}', + metadata: generateMetadata(1), + statusCode: 401, }, ], statTags: expectedStatTags, - status: 500, + status: 401, }, }, }, diff --git a/test/integrations/destinations/reddit/network.ts b/test/integrations/destinations/reddit/network.ts index 7c436e8fb8..562c8e95ad 100644 --- a/test/integrations/destinations/reddit/network.ts +++ b/test/integrations/destinations/reddit/network.ts @@ -97,4 +97,61 @@ export const networkCallsData = [ }, httpRes: { data: 'Authorization Required', status: 401, statusText: 'Unauthorized' }, }, + { + httpReq: { + url: 'https://ads-api.reddit.com/api/v2.0/conversions/events/a2_objResp_401', + data: { + events: [ + { + event_at: '2019-10-14T09:03:17.562Z', + event_type: { + tracking_type: 'ViewContent', + }, + user: { + aaid: 'c12d34889302d3c656b5699fa9190b51c50d6f62fce57e13bd56b503d66c487a', + email: 'ac144532d9e4efeab19475d9253a879173ea12a3d2238d1cb8a332a7b3a105f2', + external_id: '7b023241a3132b792a5a33915a5afb3133cbb1e13d72879689bf6504de3b036d', + ip_address: 'e80bd55a3834b7c2a34ade23c7ecb54d2a49838227080f50716151e765a619db', + user_agent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36', + screen_dimensions: {}, + }, + event_metadata: { + item_count: 3, + products: [ + { + id: '123', + name: 'Monopoly', + category: 'Games', + }, + { + id: '345', + name: 'UNO', + category: 'Games', + }, + ], + }, + }, + ], + }, + params: { destination: 'reddit' }, + headers: { + Authorization: 'Bearer dummyAccessToken', + 'Content-Type': 'application/json', + }, + method: 'POST', + }, + httpRes: { + data: { + success: false, + error: { + reason: 'UNAUTHORIZED', + explanation: + 'This server could not verify that you are authorized to access the document you requested.', + }, + }, + status: 401, + statusText: 'Unauthorized', + }, + }, ]; diff --git a/test/integrations/destinations/sendgrid/processor/data.ts b/test/integrations/destinations/sendgrid/processor/data.ts index b1550787b5..4c5ca7f48f 100644 --- a/test/integrations/destinations/sendgrid/processor/data.ts +++ b/test/integrations/destinations/sendgrid/processor/data.ts @@ -1541,4 +1541,137 @@ export const data = [ }, }, }, + { + name: 'sendgrid', + description: 'Identify call traits at root and listId given', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + ID: '2HOQOO6wWKaKjeQrEABXgiH6cmU', + Config: { + IPPoolName: '', + apiKey: 'apikey', + attachments: [ + { + content: '', + contentId: '', + disposition: '', + filename: '', + type: '', + }, + ], + clickTracking: true, + listId: 'list123', + clickTrackingEnableText: true, + contents: [ + { + type: 'text/html', + value: + '

Hello from Twilio SendGrid!

Sending with the email service trusted by developers and marketers for time-savings, scalability, and delivery expertise.

%open-track%

', + }, + ], + customFieldsMapping: [ + { + from: 'name', + to: 'user_name', + }, + ], + eventDelivery: false, + eventDeliveryTS: 1668424218224, + eventNamesSettings: [ + { + event: 'open', + }, + ], + footer: false, + fromEmail: 'a@g.com', + fromName: '', + ganalytics: false, + group: '', + groupsToDisplay: [ + { + groupId: '', + }, + ], + html: '', + mailFromTraits: false, + openTracking: false, + openTrackingSubstitutionTag: '', + replyToEmail: '', + replyToName: '', + sandboxMode: false, + subject: 'hello there from webflow', + subscriptionTracking: false, + substitutionTag: '', + templateId: '', + text: '', + }, + }, + message: { + type: 'identify', + userId: 'user@1', + context: { + traits: { + age: '25', + city: 'Surat', + name: 'rudder test', + email: 'test@rudderstack.com', + phone: '+91 9876543210', + lastName: 'test', + firstName: 'rudder', + state: 'Gujarat', + }, + }, + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + body: { + XML: {}, + FORM: {}, + JSON: { + contactDetails: { + email: 'test@rudderstack.com', + last_name: 'test', + first_name: 'rudder', + unique_name: 'rudder test', + phone_number: '+91 9876543210', + custom_fields: { + w1_T: 'rudder test', + }, + }, + contactListIds: 'list123', + }, + JSON_ARRAY: {}, + }, + type: 'REST', + userId: '', + files: {}, + method: 'PUT', + params: {}, + headers: { + 'Content-Type': 'application/json', + Authorization: 'Bearer apikey', + }, + version: '1', + endpoint: 'https://api.sendgrid.com/v3/marketing/contacts', + }, + statusCode: 200, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/sfmc/processor/data.ts b/test/integrations/destinations/sfmc/processor/data.ts index 883032d223..e8d9375e43 100644 --- a/test/integrations/destinations/sfmc/processor/data.ts +++ b/test/integrations/destinations/sfmc/processor/data.ts @@ -2216,4 +2216,182 @@ export const data = [ }, }, }, + { + name: 'sfmc', + description: 'success scenario for rETL use case', + feature: 'processor', + id: 'sfmcRetlTestCase-1', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + type: 'identify', + traits: { + key2: 'value2', + key3: 'value3', + key4: 'value4', + }, + userId: 'someRandomEmail@test.com', + channel: 'sources', + context: { + sources: { + job_id: '2kbW13URkJ6jfeo5SbFcC7ecP6d', + version: 'v1.53.1', + job_run_id: 'cqtl6pfqskjtoh6t24i0', + task_run_id: 'cqtl6pfqskjtoh6t24ig', + }, + externalId: [ + { + id: 'someRandomEmail@test.com', + type: 'SFMC-data extension', + identifierType: 'key1', + }, + ], + mappedToDestination: 'true', + }, + recordId: '3', + rudderId: 'c5741aa5-b038-4079-99ec-e4169eb0d9e2', + messageId: '95a1b214-03d9-4824-8ada-bc6ef2398100', + }, + destination: { + ID: '1pYpzzvcn7AQ2W9GGIAZSsN6Mfq', + Name: 'SFMC', + Config: { + clientId: 'dummyClientId', + clientSecret: 'dummyClientSecret', + subDomain: 'vcn7AQ2W9GGIAZSsN6Mfq', + createOrUpdateContacts: false, + externalKey: 'externalKey', + }, + Enabled: true, + Transformations: [], + }, + metadata: { + destinationId: 'destId', + jobId: 'jobid1', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + metadata: { + destinationId: 'destId', + jobId: 'jobid1', + }, + output: { + body: { + FORM: {}, + JSON: { + values: { + key2: 'value2', + key3: 'value3', + key4: 'value4', + }, + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: + 'https://vcn7AQ2W9GGIAZSsN6Mfq.rest.marketingcloudapis.com/hub/v1/dataevents/key:externalKey/rows/key1:someRandomEmail@test.com', + files: {}, + headers: { + Authorization: 'Bearer yourAuthToken', + 'Content-Type': 'application/json', + }, + method: 'PUT', + params: {}, + type: 'REST', + userId: '', + version: '1', + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'sfmc', + description: 'failure scenario for rETL use case when wrong object type is used', + feature: 'processor', + id: 'sfmcRetlTestCase-2', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + type: 'identify', + traits: { + key2: 'value2', + key3: 'value3', + key4: 'value4', + }, + userId: 'someRandomEmail@test.com', + channel: 'sources', + context: { + externalId: [ + { + id: 'someRandomEmail@test.com', + type: 'SFMC-contacts', + identifierType: 'key1', + }, + ], + mappedToDestination: 'true', + }, + }, + destination: { + ID: '1pYpzzvcn7AQ2W9GGIAZSsN6Mfq', + Name: 'SFMC', + Config: { + clientId: 'dummyClientId', + clientSecret: 'dummyClientSecret', + subDomain: 'vcn7AQ2W9GGIAZSsN6Mfq', + createOrUpdateContacts: false, + externalKey: 'externalKey', + }, + Enabled: true, + Transformations: [], + }, + metadata: { + destinationId: 'destId', + jobId: 'jobid1', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Unsupported object type for rETL use case', + metadata: { + destinationId: 'destId', + jobId: 'jobid1', + }, + statTags: { + destType: 'SFMC', + destinationId: 'destId', + errorCategory: 'platform', + feature: 'processor', + implementation: 'native', + module: 'destination', + }, + statusCode: 400, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/smartly/commonConfig.ts b/test/integrations/destinations/smartly/commonConfig.ts new file mode 100644 index 0000000000..f5b0a6f4d4 --- /dev/null +++ b/test/integrations/destinations/smartly/commonConfig.ts @@ -0,0 +1,40 @@ +export const destination = { + ID: 'random_id', + Name: 'smartly', + DestinationDefinition: { + Config: { + cdkV2Enabled: true, + }, + }, + Config: { + apiToken: 'testAuthToken', + eventsMapping: [ + { + from: 'product list viewed', + to: 'event1', + }, + { + from: 'product list viewed', + to: 'event2', + }, + ], + }, +}; + +export const routerInstrumentationErrorStatTags = { + destType: 'SMARTLY', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'router', + implementation: 'cdkV2', + module: 'destination', +}; +export const processInstrumentationErrorStatTags = { + destType: 'SMARTLY', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'cdkV2', + module: 'destination', + destinationId: 'dummyDestId', +}; diff --git a/test/integrations/destinations/smartly/mocks.ts b/test/integrations/destinations/smartly/mocks.ts new file mode 100644 index 0000000000..78773d8853 --- /dev/null +++ b/test/integrations/destinations/smartly/mocks.ts @@ -0,0 +1,6 @@ +import config from '../../../../src/cdk/v2/destinations/smartly/config'; + +export const defaultMockFns = () => { + jest.useFakeTimers().setSystemTime(new Date('2024-02-01')); + jest.replaceProperty(config, 'MAX_BATCH_SIZE', 2); +}; diff --git a/test/integrations/destinations/smartly/processor/data.ts b/test/integrations/destinations/smartly/processor/data.ts new file mode 100644 index 0000000000..a94f6b220f --- /dev/null +++ b/test/integrations/destinations/smartly/processor/data.ts @@ -0,0 +1,9 @@ +import { trackTestData } from './track'; +import { validationFailures } from './validation'; + +export const mockFns = (_) => { + // @ts-ignore + jest.useFakeTimers().setSystemTime(new Date('2024-02-01')); +}; + +export const data = [...trackTestData, ...validationFailures].map((d) => ({ ...d, mockFns })); diff --git a/test/integrations/destinations/smartly/processor/track.ts b/test/integrations/destinations/smartly/processor/track.ts new file mode 100644 index 0000000000..944327fce3 --- /dev/null +++ b/test/integrations/destinations/smartly/processor/track.ts @@ -0,0 +1,71 @@ +import { destination } from '../commonConfig'; + +export const trackTestData = [ + { + name: 'smartly', + description: 'Test 0', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + event: 'Add to cart', + properties: { + platform: 'meta', + ad_unit_id: '228287', + ad_interaction_time: 1735680000, + email: 'eventIdn01@sample.com', + }, + type: 'track', + userId: 'eventIdn01', + }, + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + output: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://s2s.smartly.io/events', + headers: {}, + params: {}, + body: { + JSON: { + platform: 'meta', + ad_unit_id: '228287', + ad_interaction_time: 1735680000, + conversions: '1', + event_name: 'Add to cart', + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + userId: '', + }, + statusCode: 200, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/smartly/processor/validation.ts b/test/integrations/destinations/smartly/processor/validation.ts new file mode 100644 index 0000000000..996afc34b3 --- /dev/null +++ b/test/integrations/destinations/smartly/processor/validation.ts @@ -0,0 +1,174 @@ +import { processInstrumentationErrorStatTags, destination } from '../commonConfig'; + +export const validationFailures = [ + { + id: 'Smartly-validation-test-1', + name: 'smartly', + description: 'Required field anonymousId not present', + scenario: 'Framework', + successCriteria: 'Transformationn Error for anonymousId not present', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'track', + event: 'product purchased', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'john123', + properties: { + products: [{}], + ad_unit_id: '22123387', + ad_interaction_time: '1690867200', + }, + integrations: { + All: true, + }, + originalTimestamp: '2021-01-25T15:32:56.409Z', + }, + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: + 'Missing required value from ["properties.platform"]: Workflow: procWorkflow, Step: preparePayload, ChildStep: undefined, OriginalError: Missing required value from ["properties.platform"]', + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + statTags: processInstrumentationErrorStatTags, + statusCode: 400, + }, + ], + }, + }, + }, + { + id: 'Smartly-test-2', + name: 'smartly', + description: 'Unsupported message type -> group', + scenario: 'Framework', + successCriteria: 'Transformationn Error for Unsupported message type', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'group', + event_name: 'purchase', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'john67', + channel: 'mobile', + rudderId: 'b7b24f86-cccx-46d8-b2b4-ccaxxx80239c', + messageId: 'dummy_msg_id', + properties: { + platform: 'snapchat', + ad_unit_id: '2653387', + ad_interaction_time: '1690867200', + }, + anonymousId: 'anon_123', + integrations: { + All: true, + }, + }, + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: + 'message type group is not supported: Workflow: procWorkflow, Step: validateInput, ChildStep: undefined, OriginalError: message type group is not supported', + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + statTags: processInstrumentationErrorStatTags, + statusCode: 400, + }, + ], + }, + }, + }, + { + id: 'Smartly-test-3', + name: 'smartly', + description: 'Event name not defined', + scenario: 'Framework', + successCriteria: 'Transformationn Error for Undefined Event', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination, + message: { + type: 'track', + sentAt: '2021-01-25T16:12:02.048Z', + userId: 'john67', + channel: 'mobile', + rudderId: 'b7b24f86-cccx-46d8-b2b4-ccaxxx80239c', + messageId: 'dummy_msg_id', + properties: { + platform: 'snapchat', + ad_unit_id: '2653387', + ad_interaction_time: 1675094400, + }, + anonymousId: 'anon_123', + integrations: { + All: true, + }, + }, + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + error: + 'Event is not defined or is not String: Workflow: procWorkflow, Step: preparePayload, ChildStep: undefined, OriginalError: Event is not defined or is not String', + metadata: { + destinationId: 'dummyDestId', + jobId: '1', + }, + statTags: processInstrumentationErrorStatTags, + statusCode: 400, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/smartly/router/data.ts b/test/integrations/destinations/smartly/router/data.ts new file mode 100644 index 0000000000..7c2d74e6f0 --- /dev/null +++ b/test/integrations/destinations/smartly/router/data.ts @@ -0,0 +1,329 @@ +import { destination, routerInstrumentationErrorStatTags } from '../commonConfig'; +import { defaultMockFns } from '../mocks'; + +export const data = [ + { + name: 'smartly', + id: 'Test 0 - router', + description: 'Track call with multiplexing and batching', + scenario: 'Framework+Buisness', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + type: 'track', + event: 'product list viewed', + properties: { + platform: 'meta', + conversions: 1, + ad_unit_id: '221187', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 2, userId: 'u2' }, + destination, + }, + { + message: { + type: 'track', + event: 'add to cart', + properties: { + conversions: 3, + platform: 'snapchat', + ad_unit_id: '77187', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 3, userId: 'u3' }, + destination, + }, + ], + destType: 'smartly', + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + body: { + JSON: { + events: [ + { + conversions: 1, + ad_unit_id: '221187', + platform: 'meta', + ad_interaction_time: 1690867200, + event_name: 'event1', + }, + { + conversions: 1, + ad_unit_id: '221187', + platform: 'meta', + ad_interaction_time: 1690867200, + event_name: 'event2', + }, + { + conversions: 3, + ad_unit_id: '77187', + platform: 'snapchat', + ad_interaction_time: 1690867200, + event_name: 'add to cart', + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://s2s.smartly.io/events/batch', + headers: { + 'Content-Type': 'application/json', + Authorization: `Bearer testAuthToken`, + }, + params: {}, + files: {}, + }, + metadata: [ + { + jobId: 2, + userId: 'u2', + }, + { + jobId: 3, + userId: 'u3', + }, + ], + batched: true, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + mockFns: () => { + jest.useFakeTimers().setSystemTime(new Date('2024-02-01')); + }, + }, + { + name: 'smartly', + id: 'Test 1 - router', + description: 'Batch calls with 4 succesfull events including multiplexing and 2 failed events', + scenario: 'Framework+Buisness', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + type: 'track', + event: 'product list viewed', + properties: { + platform: 'meta', + conversions: 1, + ad_unit_id: '221187', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 11, userId: 'u1' }, + destination, + }, + { + message: { + type: 'track', + event: 'purchase', + userId: 'testuserId1', + integrations: { All: true }, + properties: { + conversions: 3, + platform: 'snapchat', + ad_unit_id: '77187', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 13, userId: 'u1' }, + destination, + }, + { + message: { + type: 'track', + userId: 'testuserId1', + integrations: { All: true }, + properties: { + conversions: 3, + platform: 'snapchat', + ad_unit_id: '12387', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 14, userId: 'u1' }, + destination, + }, + { + message: { + type: 'track', + event: 'random event', + userId: 'testuserId1', + integrations: { All: true }, + properties: { + conversions: 3, + ad_unit_id: '77187', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 15, userId: 'u1' }, + destination, + }, + { + message: { + type: 'track', + event: 'add to cart', + userId: 'testuserId1', + integrations: { All: true }, + properties: { + conversions: 3, + platform: 'tiktok', + ad_unit_id: '789187', + ad_interaction_time: 1690867200, + }, + }, + metadata: { jobId: 16, userId: 'u1' }, + destination, + }, + ], + destType: 'smartly', + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batched: false, + destination, + error: 'Event is not defined or is not String', + metadata: [{ jobId: 14, userId: 'u1' }], + statTags: routerInstrumentationErrorStatTags, + statusCode: 400, + }, + { + batched: false, + destination, + error: 'Missing required value from ["properties.platform"]', + metadata: [{ jobId: 15, userId: 'u1' }], + statTags: routerInstrumentationErrorStatTags, + statusCode: 400, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://s2s.smartly.io/events/batch', + params: {}, + body: { + FORM: {}, + JSON: { + events: [ + { + platform: 'meta', + conversions: 1, + event_name: 'event1', + ad_unit_id: '221187', + ad_interaction_time: 1690867200, + }, + { + platform: 'meta', + conversions: 1, + event_name: 'event2', + ad_unit_id: '221187', + ad_interaction_time: 1690867200, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + }, + headers: { + 'Content-Type': 'application/json', + Authorization: `Bearer testAuthToken`, + }, + files: {}, + }, + metadata: [{ jobId: 11, userId: 'u1' }], + batched: true, + statusCode: 200, + destination, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://s2s.smartly.io/events/batch', + params: {}, + body: { + FORM: {}, + JSON: { + events: [ + { + conversions: 3, + event_name: 'purchase', + platform: 'snapchat', + ad_unit_id: '77187', + ad_interaction_time: 1690867200, + }, + { + conversions: 3, + event_name: 'add to cart', + platform: 'tiktok', + ad_unit_id: '789187', + ad_interaction_time: 1690867200, + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + }, + headers: { + 'Content-Type': 'application/json', + Authorization: `Bearer testAuthToken`, + }, + files: {}, + }, + metadata: [ + { jobId: 13, userId: 'u1' }, + { jobId: 16, userId: 'u1' }, + ], + batched: true, + statusCode: 200, + destination, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, +]; diff --git a/test/integrations/destinations/snapchat_conversion/processor/data.ts b/test/integrations/destinations/snapchat_conversion/processor/data.ts index 7de7ed9b8d..b7fde67c4e 100644 --- a/test/integrations/destinations/snapchat_conversion/processor/data.ts +++ b/test/integrations/destinations/snapchat_conversion/processor/data.ts @@ -4734,6 +4734,120 @@ export const data = [ }, }, }, + { + name: 'snapchat_conversion', + description: "Test case non string event doesn't match with snapchat events", + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + message: { + messageId: 'ec5481b6-a926-4d2e-b293-0b3a77c4d3be', + originalTimestamp: '2022-04-22T10:57:58Z', + anonymousId: 'ea5cfab2-3961-4d8a-8187-3d1858c99090', + context: { + traits: { + email: 'test@email.com', + phone: '+91 2111111 ', + }, + app: { + build: '1.0.0', + name: 'RudderLabs JavaScript SDK', + namespace: 'com.rudderlabs.javascript', + version: '1.0.0', + }, + device: { + advertisingId: 'T0T0T072-5e28-45a1-9eda-ce22a3e36d1a', + id: '3f034872-5e28-45a1-9eda-ce22a3e36d1a', + manufacturer: 'Google', + name: 'generic_x86_arm', + type: 'ios', + attTrackingStatus: 3, + }, + library: { + name: 'RudderLabs JavaScript SDK', + version: '1.0.0', + }, + locale: 'en-US', + os: { + name: 'iOS', + version: '14.4.1', + }, + screen: { + density: 2, + }, + externalId: [ + { + type: 'ga4AppInstanceId', + id: 'f0dd99v4f979fb997ce453373900f891', + }, + ], + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.88 Safari/537.36', + }, + type: 'track', + event: 1234, + properties: { + query: 't-shirts', + event_conversion_type: 'web', + }, + integrations: { + All: true, + }, + sentAt: '2022-04-22T10:57:58Z', + }, + destination: { + DestinationDefinition: { + Config: { + cdkV2Enabled: false, + }, + }, + Config: { + pixelId: 'dummyPixelId', + apiKey: 'dummyApiKey', + rudderEventsToSnapEvents: [], + }, + }, + metadata: { + jobId: 45, + destinationId: 'd2', + workspaceId: 'w2', + }, + }, + ], + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: [ + { + metadata: { + jobId: 45, + destinationId: 'd2', + workspaceId: 'w2', + }, + error: "Event 1234 doesn't match with Snapchat Events!", + statTags: { + destType: 'SNAPCHAT_CONVERSION', + destinationId: 'd2', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'native', + module: 'destination', + workspaceId: 'w2', + }, + statusCode: 400, + }, + ], + }, + }, + }, ].map((tc) => ({ ...tc, mockFns: (_) => { diff --git a/test/integrations/destinations/statsig/processor/data.ts b/test/integrations/destinations/statsig/processor/data.ts index c76ce506dc..2602764032 100644 --- a/test/integrations/destinations/statsig/processor/data.ts +++ b/test/integrations/destinations/statsig/processor/data.ts @@ -312,7 +312,7 @@ export const data = [ destination: { DestinationDefinition: { Config: { - cdkEnabled: true, + cdkV2Enabled: true, }, }, Config: { @@ -734,7 +734,7 @@ export const data = [ destination: { DestinationDefinition: { Config: { - cdkEnabled: true, + cdkV2Enabled: true, }, }, Config: { @@ -1142,7 +1142,7 @@ export const data = [ destination: { DestinationDefinition: { Config: { - cdkEnabled: true, + cdkV2Enabled: true, }, }, Config: { @@ -1466,7 +1466,7 @@ export const data = [ destination: { DestinationDefinition: { Config: { - cdkEnabled: true, + cdkV2Enabled: true, }, }, Config: { @@ -1488,13 +1488,13 @@ export const data = [ { statusCode: 400, error: - 'Bad event. Original error: message type "NOT_A_TYPE" not supported for "statsig"', + 'message type NOT_A_TYPE is not supported: Workflow: procWorkflow, Step: validateInput, ChildStep: undefined, OriginalError: message type NOT_A_TYPE is not supported', statTags: { errorCategory: 'dataValidation', errorType: 'instrumentation', destType: 'STATSIG', module: 'destination', - implementation: 'cdkV1', + implementation: 'cdkV2', destinationId: 'd1', workspaceId: 'w1', feature: 'processor', diff --git a/test/integrations/destinations/the_trade_desk/router/data.ts b/test/integrations/destinations/the_trade_desk/router/data.ts index f095f561db..d2dbf9a7cc 100644 --- a/test/integrations/destinations/the_trade_desk/router/data.ts +++ b/test/integrations/destinations/the_trade_desk/router/data.ts @@ -45,7 +45,7 @@ export const data = [ action: 'insert', fields: { DAID: 'test-daid-2', - UID2: null, + UID2: 'test-uid2-2', }, channel: 'sources', context: sampleContext, @@ -117,6 +117,35 @@ export const data = [ }, files: {}, }, + { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://sin-data.adsrvr.org/data/advertiser', + headers: {}, + params: {}, + body: { + JSON: { + DataProviderId: dataProviderId, + AdvertiserId: advertiserId, + Items: [ + { + UID2: 'test-uid2-2', + Data: [ + { + Name: segmentName, + TTLInMinutes: 43200, + }, + ], + }, + ], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, ], metadata: [ { @@ -727,6 +756,8 @@ export const data = [ action: 'insert', fields: { DAID: 'test-daid-1', + UID2: 'test-uid2-1', + EUID: 'test-euid-1', }, channel: 'sources', context: sampleContext, @@ -737,6 +768,24 @@ export const data = [ jobId: 2, }, }, + { + message: { + type: 'record', + action: 'insert', + fields: { + DAID: 'test-daid-2', + UID2: null, + EUID: null, + }, + channel: 'sources', + context: sampleContext, + recordId: '3', + }, + destination: sampleDestination, + metadata: { + jobId: 3, + }, + }, ], destType, }, @@ -771,6 +820,24 @@ export const data = [ }, ], }, + { + UID2: 'test-uid2-1', + Data: [ + { + Name: segmentName, + TTLInMinutes: 43200, + }, + ], + }, + { + EUID: 'test-euid-1', + Data: [ + { + Name: segmentName, + TTLInMinutes: 43200, + }, + ], + }, ], }, JSON_ARRAY: {}, @@ -804,6 +871,21 @@ export const data = [ }, destination: sampleDestination, }, + { + batched: false, + metadata: [{ jobId: 3 }], + statusCode: 400, + error: '`fields` cannot be empty', + statTags: { + destType: destTypeInUpperCase, + implementation: 'cdkV2', + feature: 'router', + module: 'destination', + errorCategory: 'dataValidation', + errorType: 'instrumentation', + }, + destination: sampleDestination, + }, ], }, }, diff --git a/test/integrations/destinations/tiktok_ads/processor/data.ts b/test/integrations/destinations/tiktok_ads/processor/data.ts index f459e68681..e6fe407381 100644 --- a/test/integrations/destinations/tiktok_ads/processor/data.ts +++ b/test/integrations/destinations/tiktok_ads/processor/data.ts @@ -4619,6 +4619,7 @@ export const data = [ content_name: 'Monopoly', price: 14, quantity: 1, + brand: 'brand_name', }, { content_type: 'product_group', @@ -6354,6 +6355,12 @@ export const data = [ context: { traits: { email: 'abc@xyz.com', + firstName: ' test', + lastName: 'user ', + country: 'dummycountry', + city: 'dummycity', + state: 'dummystate', + zip: ' US - 1234-', }, page: { url: 'http://demo.mywebsite.com/purchase', @@ -6474,6 +6481,7 @@ export const data = [ { price: 14, quantity: 1, + brand: 'adidas', content_category: 'Games', content_id: '123', content_name: 'Monopoly', @@ -6493,6 +6501,15 @@ export const data = [ referrer: 'http://demo.mywebsite.com', }, user: { + first_name: + '9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08', + last_name: + '04f8996da763b7a969b1028ee3007569eaf3a635486ddab211d512c85b9df8fb', + country: 'dummycountry', + zip_code: + '2a29b91aca86ff48c3defb1bbc2d33bf1da5ee5a235391322478fe7ff4503b77', + city: 'dummycity', + state: 'dummystate', email: 'ee278943de84e5d6243578ee1a1057bcce0e50daad9755f45dfa64b60b13bc5d', external_id: [ '3e0c7a51acd326b87f29596e38c22cbeb732df37bc5c8f5f524c14b55d3472db', diff --git a/test/integrations/destinations/variance/processor/data.ts b/test/integrations/destinations/variance/processor/data.ts index ae33b75e5f..f4f3054296 100644 --- a/test/integrations/destinations/variance/processor/data.ts +++ b/test/integrations/destinations/variance/processor/data.ts @@ -350,7 +350,7 @@ export const data = [ destination: { DestinationDefinition: { Config: { - cdkEnabled: true, + cdkV2Enabled: true, }, }, Config: { @@ -819,7 +819,7 @@ export const data = [ destination: { DestinationDefinition: { Config: { - cdkEnabled: true, + cdkV2Enabled: true, }, }, Config: { diff --git a/test/integrations/destinations/webengage/processor/data.ts b/test/integrations/destinations/webengage/processor/data.ts index 4a5be9d550..e4cc9bfd3d 100644 --- a/test/integrations/destinations/webengage/processor/data.ts +++ b/test/integrations/destinations/webengage/processor/data.ts @@ -2106,4 +2106,118 @@ export const data = [ }, }, }, + { + name: 'webengage', + description: 'Test 21', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: { + Config: { + apiKey: 'dummyApiKey', + licenseCode: '3bjsjdbh7', + dataCenter: 'ind', + }, + }, + message: { + type: 'page', + sentAt: '2022-01-20T13:39:21.033Z', + userId: 'user123456001', + channel: 'web', + context: { + os: { + name: '', + version: '', + }, + app: { + name: 'RudderLabs JavaScript SDK', + build: '1.0.0', + version: '1.2.20', + namespace: 'com.rudderlabs.javascript', + }, + page: { + url: 'http://127.0.0.1:7307/Testing/App_for_LaunchDarkly/ourSdk.html', + path: '/Testing/App_for_LaunchDarkly/ourSdk.html', + title: 'Document', + search: '', + tab_url: 'http://127.0.0.1:7307/Testing/App_for_LaunchDarkly/ourSdk.html', + referrer: 'http://127.0.0.1:7307/Testing/App_for_LaunchDarkly/', + initial_referrer: '$direct', + referring_domain: '127.0.0.1:7307', + initial_referring_domain: '', + }, + locale: 'en-US', + screen: { + width: 1440, + height: 900, + density: 2, + innerWidth: 536, + innerHeight: 689, + }, + traits: { + city: 'Pune', + email: 'firstUser@testmail.com', + title: 'VP', + gender: 'female', + }, + library: { + name: 'RudderLabs JavaScript SDK', + version: '1.2.20', + }, + campaign: {}, + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/97.0.4692.71 Safari/537.36', + }, + rudderId: '553b5522-c575-40a7-8072-9741c5f9a647', + messageId: '831f1fa5-de84-4f22-880a-4c3f23fc3f04', + anonymousId: 'bf412108-0357-4330-b119-7305e767823c', + integrations: { + All: true, + }, + originalTimestamp: '2022-01-20T13:39:21.032Z', + }, + }, + ], + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: { + body: { + FORM: {}, + JSON: { + anonymousId: 'bf412108-0357-4330-b119-7305e767823c', + eventName: 'Viewed a page', + eventTime: '2022-01-20T13:39:21+0000', + userId: 'user123456001', + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: 'https://api.in.webengage.com/v1/accounts/3bjsjdbh7/events', + files: {}, + headers: { + Authorization: 'Bearer dummyApiKey', + 'Content-Type': 'application/json', + }, + method: 'POST', + params: {}, + type: 'REST', + userId: '', + version: '1', + }, + statusCode: 200, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/webhook/processor/data.ts b/test/integrations/destinations/webhook/processor/data.ts index e9629041fe..3add4629bf 100644 --- a/test/integrations/destinations/webhook/processor/data.ts +++ b/test/integrations/destinations/webhook/processor/data.ts @@ -1684,6 +1684,8 @@ export const data = [ 'content-type': 'application/json', test2: 'value2', dynamic_header_key_string: 'dynamic_header_value_string', + dynamic_header_key_num: '10', + dynamic_header_key_object: '{"k1":"v1"}', }, params: {}, files: {}, @@ -2975,4 +2977,147 @@ export const data = [ }, }, }, + { + name: 'webhook', + description: 'Test with different datatype on headers', + feature: 'processor', + module: 'destination', + version: 'v0', + id: 'webhook-headers', + input: { + request: { + body: [ + { + message: { + type: 'track', + userId: 'testUser273421', + anonymousId: 'anon-testUser27342', + event: 'Submit', + header: { + key1: 'abcd', + key2: { + key1: '', + key2: '', + }, + ijkl: { + int: 1234, + string: 'abcd', + array: [1, 2, 'a', true], + object: { key1: 'value' }, + }, + key3: true, + key4: null, + key5: 'undefined', + key6: function log() { + console.log('abcd'); + }, + }, + properties: { + name: 'Shirt', + revenue: 4.99, + }, + context: { + traits: { + email: 'testuser@testmail.com', + }, + ip: '14.5.67.21', + library: { + name: 'http', + }, + }, + }, + destination: { + id: '1uNlE1KpXEzslgnehFArr9cMf7g', + Config: { + webhookUrl: 'https://webhook.site/81dc2730-807f-4bbc-8914-5b37d21c8a55', + webhookMethod: 'POST', + oneTrustCookieCategories: [], + connectionMode: 'cloud', + eventDelivery: false, + eventDeliveryTS: 1720497286192, + }, + DestinationDefinition: { + Config: { + secretKeys: ['headers.to'], + excludeKeys: [], + includeKeys: ['oneTrustCookieCategories', 'consentManagement'], + cdkV2Enabled: true, + transformAtV1: 'processor', + isAudienceSupported: true, + }, + configSchema: {}, + responseRules: null, + options: null, + uiConfig: {}, + id: '1aIXpUrvpGno4gEuF2GvI3O9dOe', + name: 'WEBHOOK', + displayName: 'Webhook', + category: null, + createdAt: '2020-04-09T09:24:24.089Z', + updatedAt: '2024-05-30T11:57:04.889Z', + }, + }, + metadata: { + destinationId: '1234', + }, + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + metadata: { + destinationId: '1234', + }, + output: { + body: { + FORM: {}, + JSON: { + anonymousId: 'anon-testUser27342', + context: { + ip: '14.5.67.21', + library: { + name: 'http', + }, + traits: { + email: 'testuser@testmail.com', + }, + }, + event: 'Submit', + properties: { + name: 'Shirt', + revenue: 4.99, + }, + type: 'track', + userId: 'testUser273421', + }, + JSON_ARRAY: {}, + XML: {}, + }, + endpoint: 'https://webhook.site/81dc2730-807f-4bbc-8914-5b37d21c8a55', + files: {}, + headers: { + 'content-type': 'application/json', + ijkl: '{"int":1234,"string":"abcd","array":[1,2,"a",true],"object":{"key1":"value"}}', + key1: 'abcd', + key2: '{"key1":"","key2":""}', + key3: 'true', + key4: 'null', + key5: 'undefined', + }, + method: 'POST', + params: {}, + type: 'REST', + userId: 'anon-testUser27342', + version: '1', + }, + statusCode: 200, + }, + ], + }, + }, + }, ]; diff --git a/test/integrations/destinations/webhook_v2/common.ts b/test/integrations/destinations/webhook_v2/common.ts new file mode 100644 index 0000000000..c31a7aabad --- /dev/null +++ b/test/integrations/destinations/webhook_v2/common.ts @@ -0,0 +1,321 @@ +import { Destination } from '../../../../src/types'; + +const destType = 'webhook_v2'; +const destTypeInUpperCase = 'WEBHOOK_V2'; +const displayName = 'Webhook V2'; +const destinations: Destination[] = [ + { + Config: { + webhookUrl: 'http://abc.com/contacts', + auth: 'noAuth', + method: 'POST', + format: 'JSON', + isBatchingEnabled: true, + maxBatchSize: '2', + propertiesMapping: [ + { + from: '$.traits.firstName', + to: '$.contacts.first_name', + }, + { + from: '$.traits.email', + to: '$.contacts.email', + }, + { + from: '$.traits.address.pinCode', + to: '$.contacts.address.pin_code', + }, + ], + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', + }, + { + Config: { + webhookUrl: 'http://abc.com/contact/$traits.userId', + auth: 'basicAuth', + username: 'test-user', + password: '', + method: 'GET', + format: 'JSON', + isBatchingEnabled: true, + maxBatchSize: 2, + headers: [ + { + to: '$.h1', + from: "'val1'", + }, + { + to: '$.h2', + from: '2', + }, + { + to: "$.'content-type'", + from: "'application/json'", + }, + { + to: '$.h3', + from: '$.traits.firstName', + }, + ], + queryParams: [ + { + to: '$.q1', + from: "'val1'", + }, + { + to: '$.q2', + from: '$.traits.email', + }, + ], + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', + }, + { + Config: { + webhookUrl: 'http://abc.com/contacts/$.traits.userId/', + auth: 'apiKeyAuth', + apiKeyName: 'x-api-key', + apiKeyValue: 'test-api-key', + method: 'DELETE', + isBatchingEnabled: true, + maxBatchSize: 4, + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', + }, + { + Config: { + webhookUrl: 'http://abc.com/contacts/$.traits.userId/', + auth: 'apiKeyAuth', + apiKeyName: 'x-api-key', + apiKeyValue: 'test-api-key', + method: 'GET', + isBatchingEnabled: true, + maxBatchSize: 4, + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', + }, + { + Config: { + webhookUrl: 'http://abc.com/events', + auth: 'bearerTokenAuth', + bearerToken: 'test-token', + method: 'POST', + format: 'XML', + headers: [ + { + to: '$.h1', + from: "'val1'", + }, + { + to: '$.h2', + from: '$.key1', + }, + { + to: "$.'content-type'", + from: "'application/json'", + }, + ], + propertiesMapping: [ + { + from: '$.event', + to: '$.event', + }, + { + from: '$.properties.currency', + to: '$.currency', + }, + { + from: '$.userId', + to: '$.userId', + }, + { + from: '$.properties.products[*].product_id', + to: '$.properties.items[*].item_id', + }, + { + from: '$.properties.products[*].name', + to: '$.properties.items[*].name', + }, + { + from: '$.properties.products[*].price', + to: '$.properties.items[*].price', + }, + ], + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', + }, + { + Config: { + webhookUrl: 'http://abc.com/events', + auth: 'noAuth', + method: 'POST', + format: 'JSON', + isBatchingEnabled: true, + maxBatchSize: '4', + headers: [ + { + to: "$.'content-type'", + from: "'application/json'", + }, + ], + propertiesMapping: [ + { + from: '$.event', + to: '$.event', + }, + { + from: '$.properties.currency', + to: '$.currency', + }, + { + from: '$.userId', + to: '$.userId', + }, + { + from: '$.properties.products[*].product_id', + to: '$.properties.items[*].item_id', + }, + { + from: '$.properties.products[*].name', + to: '$.properties.items[*].name', + }, + { + from: '$.properties.products[*].price', + to: '$.properties.items[*].price', + }, + ], + }, + DestinationDefinition: { + DisplayName: displayName, + ID: '123', + Name: destTypeInUpperCase, + Config: { cdkV2Enabled: true }, + }, + Enabled: true, + ID: '123', + Name: destTypeInUpperCase, + Transformations: [], + WorkspaceID: 'test-workspace-id', + }, +]; + +const traits = { + email: 'john.doe@example.com', + firstName: 'John', + lastName: 'Doe', + phone: '1234567890', + address: { + city: 'New York', + country: 'USA', + pinCode: '123456', + }, +}; + +const properties = { + checkout_id: '70324a1f0eaf000000000000', + order_id: '40684e8f0eaf000000000000', + affiliation: 'Vandelay Games', + total: 52.0, + subtotal: 45.0, + revenue: 50.0, + shipping: 4.0, + tax: 3.0, + discount: 5.0, + coupon: 'NEWCUST5', + currency: 'USD', + products: [ + { + product_id: '622c6f5d5cf86a4c77358033', + sku: '8472-998-0112', + name: 'Cones of Dunshire', + price: 40, + position: 1, + category: 'Games', + url: 'https://www.website.com/product/path', + image_url: 'https://www.website.com/product/path.jpg', + }, + { + product_id: '577c6f5d5cf86a4c7735ba03', + sku: '3309-483-2201', + name: 'Five Crowns', + price: 5, + position: 2, + category: 'Games', + }, + ], +}; + +const processorInstrumentationErrorStatTags = { + destType: destTypeInUpperCase, + errorCategory: 'dataValidation', + errorType: 'instrumentation', + feature: 'processor', + implementation: 'cdkV2', + module: 'destination', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', +}; + +const RouterInstrumentationErrorStatTags = { + ...processorInstrumentationErrorStatTags, + feature: 'router', +}; + +export { + destType, + destinations, + processorInstrumentationErrorStatTags, + RouterInstrumentationErrorStatTags, + traits, + properties, +}; diff --git a/test/integrations/destinations/webhook_v2/processor/configuration.ts b/test/integrations/destinations/webhook_v2/processor/configuration.ts new file mode 100644 index 0000000000..7a1c105ed0 --- /dev/null +++ b/test/integrations/destinations/webhook_v2/processor/configuration.ts @@ -0,0 +1,206 @@ +import { ProcessorTestData } from '../../../testTypes'; +import { generateMetadata, transformResultBuilder } from '../../../testUtils'; +import { destType, destinations, properties, traits } from '../common'; + +export const configuration: ProcessorTestData[] = [ + { + id: 'webhook_v2-configuration-test-1', + name: destType, + description: 'Identify call with properties mapping', + scenario: 'Business', + successCriteria: 'Response should be in json format with properties mapping', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: destinations[0], + message: { + type: 'identify', + userId: 'userId123', + anonymousId: 'anonId123', + traits, + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + userId: '', + endpoint: destinations[0].Config.webhookUrl, + JSON: { + contacts: { + first_name: 'John', + email: 'john.doe@example.com', + address: { + pin_code: '123456', + }, + }, + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'webhook_v2-configuration-test-2', + name: destType, + description: 'Identify call with api key auth, delete method and path params', + scenario: 'Business', + successCriteria: 'Response should contain delete method and api key auth', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: destinations[2], + message: { + type: 'identify', + userId: 'userId123', + anonymousId: 'anonId123', + traits, + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'DELETE', + userId: '', + endpoint: 'http://abc.com/contacts/$.traits.userId/', + headers: { + 'x-api-key': 'test-api-key', + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'webhook_v2-configuration-test-3', + name: destType, + description: 'Track call with basic auth, get method, headers and query params mapping', + scenario: 'Business', + successCriteria: 'Response should contain get method, headers and query params mapping', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: destinations[1], + message: { + type: 'track', + userId: 'userId123', + event: 'Order Completed', + properties, + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'GET', + userId: '', + endpoint: destinations[1].Config.webhookUrl, + headers: { + Authorization: 'Basic dGVzdC11c2VyOg==', + h1: 'val1', + h2: 2, + 'content-type': 'application/json', + }, + params: { + q1: 'val1', + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + { + id: 'webhook_v2-configuration-test-4', + name: destType, + description: + 'Track call with bearer token, xml format, post method, additional headers and properties mapping', + scenario: 'Business', + successCriteria: + 'Response should be in xml format with post method, headers and properties mapping', + feature: 'processor', + module: 'destination', + version: 'v0', + input: { + request: { + body: [ + { + destination: destinations[4], + message: { + type: 'track', + userId: 'userId123', + event: 'Order Completed', + properties, + }, + metadata: generateMetadata(1), + }, + ], + }, + }, + output: { + response: { + status: 200, + body: [ + { + output: transformResultBuilder({ + method: 'POST', + userId: '', + endpoint: destinations[4].Config.webhookUrl, + headers: { + Authorization: 'Bearer test-token', + h1: 'val1', + 'content-type': 'application/json', + }, + XML: { + payload: + 'Order CompletedUSDuserId123622c6f5d5cf86a4c77358033Cones of Dunshire40577c6f5d5cf86a4c7735ba03Five Crowns5', + }, + }), + statusCode: 200, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/destinations/webhook_v2/processor/data.ts b/test/integrations/destinations/webhook_v2/processor/data.ts new file mode 100644 index 0000000000..bb4e7ffa0d --- /dev/null +++ b/test/integrations/destinations/webhook_v2/processor/data.ts @@ -0,0 +1,2 @@ +import { configuration } from './configuration'; +export const data = [...configuration]; diff --git a/test/integrations/destinations/webhook_v2/router/data.ts b/test/integrations/destinations/webhook_v2/router/data.ts new file mode 100644 index 0000000000..44c9f0e6fe --- /dev/null +++ b/test/integrations/destinations/webhook_v2/router/data.ts @@ -0,0 +1,350 @@ +import { generateMetadata } from '../../../testUtils'; +import { + destType, + destinations, + traits, + properties, + RouterInstrumentationErrorStatTags, +} from '../common'; + +const routerRequest1 = { + input: [ + { + message: { + type: 'identify', + userId: 'userId1', + traits, + }, + metadata: generateMetadata(1), + destination: destinations[3], + }, + { + message: { + type: 'identify', + userId: 'userId2', + traits, + }, + metadata: generateMetadata(2), + destination: destinations[3], + }, + { + message: { + type: 'identify', + userId: 'userId1', + traits, + }, + metadata: generateMetadata(3), + destination: destinations[3], + }, + ], + destType, +}; + +const routerRequest2 = { + input: [ + { + message: { + type: 'identify', + userId: 'userId1', + traits, + }, + metadata: generateMetadata(1, 'userId1'), + destination: destinations[1], + }, + { + message: { + type: 'identify', + userId: 'userId2', + traits: { ...traits, firstName: 'Alex', lastName: 'T', email: 'alex.t@example.com' }, + }, + metadata: generateMetadata(2, 'userId2'), + destination: destinations[1], + }, + { + message: { + type: 'identify', + userId: 'userId1', + traits: { ...traits, phone: '2234567890' }, + }, + metadata: generateMetadata(3, 'userId1'), + destination: destinations[1], + }, + { + message: { + type: 'identify', + userId: 'userId1', + traits: { ...traits, phone: '3234567890' }, + }, + metadata: generateMetadata(4, 'userId1'), + destination: destinations[1], + }, + ], + destType, +}; + +const routerRequest3 = { + input: [ + { + message: { + type: 'track', + userId: 'userId1', + event: 'Product Viewed', + context: { traits }, + }, + metadata: generateMetadata(1, 'userId1'), + destination: destinations[5], + }, + { + message: { + type: 'track', + userId: 'userId2', + event: 'Order Completed', + context: { traits }, + properties, + }, + metadata: generateMetadata(2, 'userId2'), + destination: destinations[5], + }, + { + message: { + type: 'track', + userId: 'userId3', + event: 'Product Added', + context: { traits }, + properties, + }, + metadata: generateMetadata(3, 'userId3'), + destination: destinations[5], + }, + ], + destType, +}; + +// TODO: add failure testcases +export const data = [ + { + id: 'webhook_v2-router-test-1', + name: destType, + description: 'Batch multiple GET requests in a single batch with given batch size', + scenario: 'Framework', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: routerRequest1, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'GET', + endpoint: 'http://abc.com/contacts/$.traits.userId/', + headers: { + 'x-api-key': 'test-api-key', + }, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: { batch: '[]' }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(1), generateMetadata(2), generateMetadata(3)], + batched: true, + statusCode: 200, + destination: destinations[3], + }, + ], + }, + }, + }, + }, + { + id: 'webhook_v2-router-test-2', + name: destType, + description: + 'Batch multiple GET requests in multiple batches when number of requests are greater then given batch size', + scenario: 'Framework', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: routerRequest2, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'GET', + endpoint: 'http://abc.com/contact/$traits.userId', + headers: { + Authorization: 'Basic dGVzdC11c2VyOg==', + 'content-type': 'application/json', + h1: 'val1', + h2: 2, + h3: 'John', + }, + params: { + q1: 'val1', + q2: 'john.doe@example.com', + }, + body: { + JSON: {}, + JSON_ARRAY: { + batch: '[]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(1, 'userId1'), generateMetadata(3, 'userId1')], + batched: true, + statusCode: 200, + destination: destinations[1], + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'GET', + endpoint: 'http://abc.com/contact/$traits.userId', + headers: { + Authorization: 'Basic dGVzdC11c2VyOg==', + 'content-type': 'application/json', + h1: 'val1', + h2: 2, + h3: 'John', + }, + params: { + q1: 'val1', + q2: 'john.doe@example.com', + }, + body: { + JSON: {}, + JSON_ARRAY: { + batch: '[]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(4, 'userId1')], + batched: true, + statusCode: 200, + destination: destinations[1], + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'GET', + endpoint: 'http://abc.com/contact/$traits.userId', + headers: { + Authorization: 'Basic dGVzdC11c2VyOg==', + 'content-type': 'application/json', + h1: 'val1', + h2: 2, + h3: 'Alex', + }, + params: { + q1: 'val1', + q2: 'alex.t@example.com', + }, + body: { + JSON: {}, + JSON_ARRAY: { + batch: '[]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [generateMetadata(2, 'userId2')], + batched: true, + statusCode: 200, + destination: destinations[1], + }, + ], + }, + }, + }, + }, + { + id: 'webhook_v2-router-test-3', + name: destType, + description: 'Batch multiple POST requests with properties mappings', + scenario: 'Framework', + successCriteria: 'All events should be transformed successfully and status code should be 200', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: routerRequest3, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'http://abc.com/events', + params: {}, + headers: { + 'content-type': 'application/json', + }, + body: { + JSON: {}, + JSON_ARRAY: { + batch: + '[{"event":"Product Viewed","userId":"userId1","properties":{"items":[]}},{"event":"Order Completed","currency":"USD","userId":"userId2","properties":{"items":[{"item_id":"622c6f5d5cf86a4c77358033","name":"Cones of Dunshire","price":40},{"item_id":"577c6f5d5cf86a4c7735ba03","name":"Five Crowns","price":5}]}},{"event":"Product Added","currency":"USD","userId":"userId3","properties":{"items":[{"item_id":"622c6f5d5cf86a4c77358033","name":"Cones of Dunshire","price":40},{"item_id":"577c6f5d5cf86a4c7735ba03","name":"Five Crowns","price":5}]}}]', + }, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + generateMetadata(1, 'userId1'), + generateMetadata(2, 'userId2'), + generateMetadata(3, 'userId3'), + ], + batched: true, + statusCode: 200, + destination: destinations[5], + }, + ], + }, + }, + }, + }, +]; diff --git a/test/integrations/destinations/zoho/common.ts b/test/integrations/destinations/zoho/common.ts new file mode 100644 index 0000000000..bea4437e6f --- /dev/null +++ b/test/integrations/destinations/zoho/common.ts @@ -0,0 +1,334 @@ +import { Destination } from '../../../../src/types'; + +const destType = 'zoho'; +const destTypeInUpperCase = 'ZOHO'; +const advertiserId = 'test-advertiser-id'; +const dataProviderId = 'rudderstack'; +const segmentName = 'test-segment'; +const leadUpsertEndpoint = 'https://www.zohoapis.in/crm/v6/Leads/upsert'; + +const deletionPayload1 = { + action: 'delete', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'tobedeleted@gmail.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + type: 'record', +}; + +const commonDeletionDestConfig: Destination = { + ID: '345', + Name: 'Test', + Enabled: true, + WorkspaceID: '', + Transformations: [], + DestinationDefinition: { + ID: '345', + Name: 'Test', + DisplayName: 'ZOHO', + Config: { + cdkV2Enabled: true, + excludeKeys: [], + includeKeys: [], + }, + }, + Config: { + region: 'IN', + module: 'Leads', + trigger: 'None', + addDefaultDuplicateCheck: true, + multiSelectFieldLevelDecision: [ + { + from: 'multi-language', + to: 'true', + }, + { + from: 'multi class', + to: 'false', + }, + ], + oneTrustCookieCategories: [ + { + oneTrustCookieCategory: 'Marketing', + }, + ], + }, +}; + +const upsertPayload1 = { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + type: 'record', +}; + +const upsertPayload2 = { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + 'multi-language': 'Bengali', + }, + type: 'record', +}; + +const upsertPayload3 = { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'Email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + type: 'record', +}; + +const commonUpsertDestConfig: Destination = { + ID: '345', + Name: 'Test', + Enabled: true, + WorkspaceID: '', + Transformations: [], + DestinationDefinition: { + ID: '345', + Name: 'Test', + DisplayName: 'ZOHO', + Config: { + cdkV2Enabled: true, + excludeKeys: [], + includeKeys: [], + }, + }, + Config: { + region: 'US', + module: 'Leads', + trigger: 'workflow', + addDefaultDuplicateCheck: true, + multiSelectFieldLevelDecision: [ + { + from: 'multi-language', + to: 'true', + }, + { + from: 'multi class', + to: 'false', + }, + ], + oneTrustCookieCategories: [ + { + oneTrustCookieCategory: 'Marketing', + }, + ], + }, +}; + +const commonUpsertDestConfig2: Destination = { + ID: '345', + Name: 'Test', + Enabled: true, + WorkspaceID: '', + Transformations: [], + DestinationDefinition: { + ID: '345', + Name: 'Test', + DisplayName: 'ZOHO', + Config: { + cdkV2Enabled: true, + excludeKeys: [], + includeKeys: [], + }, + }, + Config: { + region: 'US', + module: 'Leads', + trigger: 'None', + addDefaultDuplicateCheck: true, + multiSelectFieldLevelDecision: [ + { + from: 'multi-language', + to: 'true', + }, + { + from: 'multi class', + to: 'false', + }, + ], + oneTrustCookieCategories: [ + { + oneTrustCookieCategory: 'Marketing', + }, + ], + }, +}; + +const commonUpsertDestConfig2CustomModule: Destination = { + ID: '345', + Name: 'Test', + Enabled: true, + WorkspaceID: '', + Transformations: [], + DestinationDefinition: { + ID: '345', + Name: 'Test', + DisplayName: 'ZOHO', + Config: { + cdkV2Enabled: true, + excludeKeys: [], + includeKeys: [], + }, + }, + Config: { + region: 'US', + module: 'CUSTOM', + trigger: 'None', + addDefaultDuplicateCheck: true, + multiSelectFieldLevelDecision: [ + { + from: 'multi-language', + to: 'true', + }, + { + from: 'multi class', + to: 'false', + }, + ], + oneTrustCookieCategories: [ + { + oneTrustCookieCategory: 'Marketing', + }, + ], + }, +}; + +const commonUpsertDestConfig3: Destination = { + ID: '345', + Name: 'Test', + Enabled: true, + WorkspaceID: '', + Transformations: [], + DestinationDefinition: { + ID: '345', + Name: 'Test', + DisplayName: 'ZOHO', + Config: { + cdkV2Enabled: true, + excludeKeys: [], + includeKeys: [], + }, + }, + Config: { + region: 'US', + module: 'Leads', + trigger: 'workflow', + addDefaultDuplicateCheck: true, + oneTrustCookieCategories: [ + { + oneTrustCookieCategory: 'Marketing', + }, + ], + }, +}; + +const commonOutput1 = { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], +}; + +export { + destType, + destTypeInUpperCase, + advertiserId, + dataProviderId, + segmentName, + leadUpsertEndpoint, + deletionPayload1, + commonDeletionDestConfig, + upsertPayload1, + upsertPayload2, + upsertPayload3, + commonUpsertDestConfig, + commonUpsertDestConfig2, + commonOutput1, + commonUpsertDestConfig3, + commonUpsertDestConfig2CustomModule, +}; diff --git a/test/integrations/destinations/zoho/dataDelivery/business.ts b/test/integrations/destinations/zoho/dataDelivery/business.ts new file mode 100644 index 0000000000..89c3ca214b --- /dev/null +++ b/test/integrations/destinations/zoho/dataDelivery/business.ts @@ -0,0 +1,401 @@ +import { generateMetadata, generateProxyV1Payload } from '../../../testUtils'; +import { ProxyV1TestData } from '../../../testTypes'; + +export const headerBlockWithCorrectAccessToken = { + 'Content-Type': 'application/json', + Authorization: 'Zoho-oauthtoken dummy-key', +}; + +export const contactPayload = { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], +}; + +export const statTags = { + destType: 'ZOHO', + errorCategory: 'network', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + errorType: 'aborted', + feature: 'dataDelivery', + implementation: 'native', + module: 'destination', +}; + +export const metadata = [ + { + jobId: 1, + attemptNum: 1, + userId: 'default-userId', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + sourceId: 'default-sourceId', + secret: { + accessToken: 'default-accessToken', + }, + dontBatch: false, + }, + { + jobId: 2, + attemptNum: 1, + userId: 'default-userId', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + sourceId: 'default-sourceId', + secret: { + accessToken: 'default-accessToken', + }, + dontBatch: false, + }, + { + jobId: 3, + attemptNum: 1, + userId: 'default-userId', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + sourceId: 'default-sourceId', + secret: { + accessToken: 'default-accessToken', + }, + dontBatch: false, + }, +]; + +export const singleMetadata = [ + { + jobId: 1, + attemptNum: 1, + userId: 'default-userId', + destinationId: 'default-destinationId', + workspaceId: 'default-workspaceId', + sourceId: 'default-sourceId', + secret: { + accessToken: 'default-accessToken', + }, + dontBatch: false, + }, +]; + +const commonRecordParameters = { + method: 'POST', + headers: headerBlockWithCorrectAccessToken, + JSON: { ...contactPayload }, +}; + +const commonRecordParametersWithWrongToken = { + method: 'POST', + headers: { 'Content-Type': 'application/json', Authorization: 'Zoho-oauthtoken wrong-token' }, + JSON: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], + }, +}; + +const multiContactPayload = { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Random: 'subscribed@eewrfrd.com', + }, + ], + $append_values: {}, + trigger: ['workflow'], +}; + +const commonMultiRecordParameters = { + method: 'POST', + headers: headerBlockWithCorrectAccessToken, + JSON: { ...multiContactPayload }, +}; + +export const testScenariosForV1API: ProxyV1TestData[] = [ + { + id: 'zoho_v1_scenario_1', + name: 'zoho', + description: 'Upserting Leads successfully', + successCriteria: 'Should return 200 and success', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://www.zohoapis.in/crm/v6/Leads/upsert', + ...commonRecordParameters, + }, + singleMetadata, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 200, + message: '[ZOHO Response V1 Handler] - Request Processed Successfully', + destinationResponse: { + response: { + data: [ + { + code: 'SUCCESS', + duplicate_field: null, + action: 'insert', + details: { + Modified_Time: '2024-07-16T09:39:27+05:30', + Modified_By: { + name: 'Dummy-User', + id: '724445000000323001', + }, + Created_Time: '2024-07-16T09:39:27+05:30', + id: '724445000000424003', + Created_By: { + name: 'Dummy-User', + id: '724445000000323001', + }, + $approval_state: 'approved', + }, + message: 'record added', + status: 'success', + }, + ], + }, + status: 200, + }, + response: [ + { + statusCode: 200, + metadata: generateMetadata(1), + error: 'success', + }, + ], + }, + }, + }, + }, + }, + { + id: 'zoho_v1_scenario_2', + name: 'zoho', + description: 'Trying to upsert in wrong module name', + successCriteria: 'Should return 400 and should be aborted', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://www.zohoapis.in/crm/v6/Wrong/upsert', + ...commonRecordParameters, + }, + singleMetadata, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 400, + statTags, + message: 'ZOHO: Error encountered in transformer proxy V1', + response: [ + { + statusCode: 400, + metadata: generateMetadata(1), + error: + '{"code":"INVALID_MODULE","details":{"resource_path_index":0},"message":"the module name given seems to be invalid","status":"error"}', + }, + ], + }, + }, + }, + }, + }, + { + id: 'zoho_v1_scenario_3', + name: 'zoho', + description: 'Trying to upsert using invalid access token', + successCriteria: 'Should return 500 and try for refreshed token', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://www.zohoapis.in/crm/v6/Leads/upsert', + ...commonRecordParametersWithWrongToken, + }, + singleMetadata, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 500, + body: { + output: { + status: 500, + statTags: { ...statTags, errorType: 'retryable' }, + message: + 'Zoho: Error transformer proxy v1 during Zoho response transformation. invalid oauth token', + authErrorCategory: 'REFRESH_TOKEN', + response: [ + { + error: + '{"code":"INVALID_TOKEN","details":{},"message":"invalid oauth token","status":"error"}', + statusCode: 500, + metadata: generateMetadata(1), + }, + ], + }, + }, + }, + }, + }, + { + id: 'zoho_v1_scenario_4', + name: 'zoho', + description: 'testing partial failure', + successCriteria: 'Should return 200 and success for successful and 400 for failed payloads', + scenario: 'Business', + feature: 'dataDelivery', + module: 'destination', + version: 'v1', + input: { + request: { + body: generateProxyV1Payload( + { + endpoint: 'https://www.zohoapis.in/crm/v6/Leads/upsert', + ...commonMultiRecordParameters, + }, + metadata, + ), + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: { + status: 200, + message: '[ZOHO Response V1 Handler] - Request Processed Successfully', + destinationResponse: { + response: { + data: [ + { + code: 'SUCCESS', + duplicate_field: 'Email', + action: 'update', + details: { + Modified_Time: '2024-07-16T15:01:02+05:30', + Modified_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + Created_Time: '2024-07-16T09:39:27+05:30', + id: '724445000000424003', + Created_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + }, + message: 'record updated', + status: 'success', + }, + { + code: 'SUCCESS', + duplicate_field: 'Email', + action: 'update', + details: { + Modified_Time: '2024-07-16T15:01:02+05:30', + Modified_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + Created_Time: '2024-07-16T09:39:27+05:30', + id: '724445000000424003', + Created_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + }, + message: 'record updated', + status: 'success', + }, + { + code: 'MANDATORY_NOT_FOUND', + details: { + api_name: 'Last_Name', + json_path: '$.data[2].Last_Name', + }, + message: 'required field not found', + status: 'error', + }, + ], + }, + status: 200, + }, + response: [ + { + statusCode: 200, + metadata: generateMetadata(1), + error: 'success', + }, + { + error: 'success', + metadata: generateMetadata(2), + statusCode: 200, + }, + { + error: + 'message: undefined {"api_name":"Last_Name","json_path":"$.data[2].Last_Name"}', + metadata: generateMetadata(3), + statusCode: 400, + }, + ], + }, + }, + }, + }, + }, +]; + +export const data = [...testScenariosForV1API]; diff --git a/test/integrations/destinations/zoho/dataDelivery/data.ts b/test/integrations/destinations/zoho/dataDelivery/data.ts new file mode 100644 index 0000000000..fc969bb8e1 --- /dev/null +++ b/test/integrations/destinations/zoho/dataDelivery/data.ts @@ -0,0 +1,3 @@ +import { testScenariosForV1API } from './business'; + +export const data = [...testScenariosForV1API]; diff --git a/test/integrations/destinations/zoho/mocks.ts b/test/integrations/destinations/zoho/mocks.ts new file mode 100644 index 0000000000..1e4c7d18c7 --- /dev/null +++ b/test/integrations/destinations/zoho/mocks.ts @@ -0,0 +1,5 @@ +import config from '../../../../src/cdk/v2/destinations/zoho/config'; + +export const defaultMockFns = () => { + jest.replaceProperty(config, 'MAX_BATCH_SIZE', 2); +}; diff --git a/test/integrations/destinations/zoho/network.ts b/test/integrations/destinations/zoho/network.ts new file mode 100644 index 0000000000..b37a56d123 --- /dev/null +++ b/test/integrations/destinations/zoho/network.ts @@ -0,0 +1,421 @@ +import { destType } from './common'; + +export const networkCallsData = [ + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Leads/upsert', + data: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], + }, + params: { destination: destType }, + headers: { + 'Content-Type': 'application/json', + Authorization: 'Zoho-oauthtoken dummy-key', + }, + method: 'POST', + }, + httpRes: { + data: { + data: [ + { + code: 'SUCCESS', + duplicate_field: null, + action: 'insert', + details: { + Modified_Time: '2024-07-16T09:39:27+05:30', + Modified_By: { + name: 'Dummy-User', + id: '724445000000323001', + }, + Created_Time: '2024-07-16T09:39:27+05:30', + id: '724445000000424003', + Created_By: { + name: 'Dummy-User', + id: '724445000000323001', + }, + $approval_state: 'approved', + }, + message: 'record added', + status: 'success', + }, + ], + }, + status: 200, + statusText: 'OK', + }, + }, + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Wrong/upsert', + data: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], + }, + params: { destination: destType }, + headers: { + 'Content-Type': 'application/json', + Authorization: 'Zoho-oauthtoken dummy-key', + }, + method: 'POST', + }, + httpRes: { + data: { + code: 'INVALID_MODULE', + details: { + resource_path_index: 0, + }, + message: 'the module name given seems to be invalid', + status: 'error', + }, + status: 400, + statusText: 'Bad Request', + }, + }, + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Leads/upsert', + data: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], + }, + params: { destination: destType }, + headers: { + 'Content-Type': 'application/json', + Authorization: 'Zoho-oauthtoken wrong-token', + }, + method: 'POST', + }, + httpRes: { + data: { + code: 'INVALID_TOKEN', + details: {}, + message: 'invalid oauth token', + status: 'error', + }, + status: 401, + statusText: 'Bad Request', + }, + }, + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Leads/upsert', + data: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Random: 'subscribed@eewrfrd.com', + }, + ], + $append_values: {}, + trigger: ['workflow'], + }, + params: { destination: destType }, + headers: { + 'Content-Type': 'application/json', + Authorization: 'Zoho-oauthtoken dummy-key', + }, + method: 'POST', + }, + httpRes: { + data: { + data: [ + { + code: 'SUCCESS', + duplicate_field: 'Email', + action: 'update', + details: { + Modified_Time: '2024-07-16T15:01:02+05:30', + Modified_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + Created_Time: '2024-07-16T09:39:27+05:30', + id: '724445000000424003', + Created_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + }, + message: 'record updated', + status: 'success', + }, + { + code: 'SUCCESS', + duplicate_field: 'Email', + action: 'update', + details: { + Modified_Time: '2024-07-16T15:01:02+05:30', + Modified_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + Created_Time: '2024-07-16T09:39:27+05:30', + id: '724445000000424003', + Created_By: { + name: 'dummy-user', + id: '724445000000323001', + }, + }, + message: 'record updated', + status: 'success', + }, + { + code: 'MANDATORY_NOT_FOUND', + details: { + api_name: 'Last_Name', + json_path: '$.data[2].Last_Name', + }, + message: 'required field not found', + status: 'error', + }, + ], + // }, + }, + status: 200, + statusText: 'OK', + }, + }, + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Leads/search?criteria=(Email:equals:tobedeleted3%40gmail.com)and(First_Name:equals:subcribed3)and(Last_Name:equals:%20User3)', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + method: 'GET', + }, + httpRes: { + data: { + data: '', + }, + status: 204, + statusText: 'OK', + }, + }, + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Leads/search?criteria=(Email:equals:tobedeleted%40gmail.com)and(First_Name:equals:subcribed)and(Last_Name:equals:%20User)', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + method: 'GET', + }, + httpRes: { + data: { + data: [ + { + Owner: { + name: 'dummy-user', + id: '724445000000323001', + email: 'dummy@gmail.com', + }, + Company: null, + Email: 'tobedeleted@gmail.com', + $currency_symbol: '$', + $field_states: null, + $sharing_permission: 'full_access', + Last_Activity_Time: '2024-07-18T23:55:42+05:30', + Industry: null, + Unsubscribed_Mode: null, + $process_flow: false, + Street: null, + Zip_Code: null, + id: '', + $approval: { + delegate: false, + approve: false, + reject: false, + resubmit: false, + }, + Created_Time: '2024-07-18T19:34:50+05:30', + $editable: true, + City: null, + No_of_Employees: null, + Converted_Account: null, + State: null, + Country: null, + Created_By: { + name: 'dummy-user', + id: '724445000000323001', + email: 'dummy@gmail.com', + }, + $zia_owner_assignment: 'owner_recommendation_unavailable', + Annual_Revenue: null, + Secondary_Email: null, + Description: null, + Rating: null, + $review_process: { + approve: false, + reject: false, + resubmit: false, + }, + Website: null, + Twitter: null, + Salutation: null, + First_Name: 'subcribed', + Full_Name: 'subcribed User', + Lead_Status: null, + Record_Image: null, + Modified_By: { + name: 'dummy-user', + id: '724445000000323001', + email: 'dummy@gmail.com', + }, + Converted_Deal: null, + $review: null, + Lead_Conversion_Time: null, + Skype_ID: null, + Phone: null, + Email_Opt_Out: false, + $zia_visions: null, + Designation: null, + Modified_Time: '2024-07-18T23:55:42+05:30', + $converted_detail: {}, + Unsubscribed_Time: null, + Converted_Contact: null, + Mobile: null, + $orchestration: null, + Last_Name: 'User', + $in_merge: false, + Lead_Source: null, + Fax: null, + $approval_state: 'approved', + $pathfinder: null, + }, + ], + }, + status: 200, + statusText: 'OK', + }, + }, + { + httpReq: { + url: 'https://www.zohoapis.in/crm/v6/Leads/search?criteria=(Email:equals:tobedeleted2%40gmail.com)and(First_Name:equals:subcribed2)and(Last_Name:equals:%20User2)', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + method: 'GET', + }, + httpRes: { + data: { + data: [ + { + Owner: { + name: 'dummy-user', + id: '724445000000323001', + email: 'dummy@gmail.com', + }, + Company: null, + Email: 'tobedeleted2@gmail.com', + $currency_symbol: '$', + $field_states: null, + $sharing_permission: 'full_access', + Last_Activity_Time: '2024-07-18T23:55:42+05:30', + Industry: null, + Unsubscribed_Mode: null, + $process_flow: false, + Street: null, + Zip_Code: null, + id: '', + $approval: { + delegate: false, + approve: false, + reject: false, + resubmit: false, + }, + Created_Time: '2024-07-18T19:34:50+05:30', + $editable: true, + City: null, + No_of_Employees: null, + Converted_Account: null, + State: null, + Country: null, + Created_By: { + name: 'dummy-user', + id: '724445000000323001', + email: 'dummy@gmail.com', + }, + $zia_owner_assignment: 'owner_recommendation_unavailable', + Annual_Revenue: null, + Secondary_Email: null, + Description: null, + Rating: null, + $review_process: { + approve: false, + reject: false, + resubmit: false, + }, + Website: null, + Twitter: null, + Salutation: null, + First_Name: 'subcribed2', + Full_Name: 'subcribed2 User', + Lead_Status: null, + Record_Image: null, + Modified_By: { + name: 'dummy-user', + id: '724445000000323001', + email: 'dummy@gmail.com', + }, + Converted_Deal: null, + $review: null, + Lead_Conversion_Time: null, + Skype_ID: null, + Phone: null, + Email_Opt_Out: false, + $zia_visions: null, + Designation: null, + Modified_Time: '2024-07-18T23:55:42+05:30', + $converted_detail: {}, + Unsubscribed_Time: null, + Converted_Contact: null, + Mobile: null, + $orchestration: null, + Last_Name: 'User2', + $in_merge: false, + Lead_Source: null, + Fax: null, + $approval_state: 'approved', + $pathfinder: null, + }, + ], + }, + status: 200, + statusText: 'OK', + }, + }, +]; diff --git a/test/integrations/destinations/zoho/router/data.ts b/test/integrations/destinations/zoho/router/data.ts new file mode 100644 index 0000000000..7340fd18c8 --- /dev/null +++ b/test/integrations/destinations/zoho/router/data.ts @@ -0,0 +1,4 @@ +import { upsertData } from './upsert'; +import { deleteData } from './deletion'; + +export const data = [...upsertData, ...deleteData]; diff --git a/test/integrations/destinations/zoho/router/deletion.ts b/test/integrations/destinations/zoho/router/deletion.ts new file mode 100644 index 0000000000..5e922bc794 --- /dev/null +++ b/test/integrations/destinations/zoho/router/deletion.ts @@ -0,0 +1,249 @@ +import { defaultMockFns } from '../mocks'; +import { commonDeletionDestConfig, deletionPayload1, destType } from '../common'; + +export const deleteData = [ + { + name: destType, + id: 'zoho_deletion_1', + description: 'Happy flow record deletion with Leads module', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: deletionPayload1, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonDeletionDestConfig, + }, + { + message: { + action: 'delete', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'tobedeleted2@gmail.com', + First_Name: 'subcribed2', + Last_Name: ' User2', + }, + type: 'record', + }, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonDeletionDestConfig, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'DELETE', + endpoint: + 'https://www.zohoapis.in/crm/v6/Leads?ids=,&wf_trigger=false', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonDeletionDestConfig, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, + { + name: destType, + id: 'zoho_deletion_2', + description: 'Batch containing already existing and non existing records for deletion', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: deletionPayload1, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonDeletionDestConfig, + }, + { + message: { + action: 'delete', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'tobedeleted3@gmail.com', + First_Name: 'subcribed3', + Last_Name: ' User3', + }, + type: 'record', + }, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonDeletionDestConfig, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'DELETE', + endpoint: 'https://www.zohoapis.in/crm/v6/Leads?ids=&wf_trigger=false', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: {}, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonDeletionDestConfig, + }, + { + metadata: [ + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: false, + statusCode: 400, + error: + 'failed to fetch zoho id for record for "No contact is found with record details"', + statTags: { + errorCategory: 'dataValidation', + errorType: 'configuration', + destType: 'ZOHO', + module: 'destination', + implementation: 'cdkV2', + feature: 'router', + }, + destination: commonDeletionDestConfig, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, +]; diff --git a/test/integrations/destinations/zoho/router/upsert.ts b/test/integrations/destinations/zoho/router/upsert.ts new file mode 100644 index 0000000000..a2b898970d --- /dev/null +++ b/test/integrations/destinations/zoho/router/upsert.ts @@ -0,0 +1,771 @@ +import { defaultMockFns } from '../mocks'; +import { + commonOutput1, + commonUpsertDestConfig, + commonUpsertDestConfig2, + commonUpsertDestConfig2CustomModule, + commonUpsertDestConfig3, + destType, + upsertPayload1, + upsertPayload2, + upsertPayload3, +} from '../common'; + +export const upsertData = [ + { + name: destType, + description: 'Happy flow with Leads module', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: upsertPayload1, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig, + }, + { + message: upsertPayload2, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/Leads/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: { + duplicate_check_fields: ['email', 'Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + 'multi-language': ['Bengali'], + }, + ], + $append_values: { + 'multi-language': 'true', + 'multi class': 'false', + }, + trigger: ['workflow'], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, + { + name: destType, + description: 'Happy flow with Trigger None', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: upsertPayload1, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig2, + }, + { + message: upsertPayload2, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig2, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/Leads/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: { + duplicate_check_fields: ['email', 'Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + 'multi-language': ['Bengali'], + }, + ], + $append_values: { + 'multi-language': 'true', + 'multi class': 'false', + }, + trigger: [], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig2, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, + { + name: destType, + description: 'Happy flow with custom Module', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-CUSTOM', + identifierType: 'Email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + Name: 'ABC', + }, + type: 'record', + }, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig2CustomModule, + }, + { + message: { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-CUSTOM', + identifierType: 'Email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + 'multi-language': 'Bengali', + Name: 'ABC', + }, + type: 'record', + }, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig2, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/CUSTOM/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: { + duplicate_check_fields: ['Email', 'Name'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + Name: 'ABC', + }, + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + 'multi-language': ['Bengali'], + Name: 'ABC', + }, + ], + $append_values: { + 'multi-language': 'true', + 'multi class': 'false', + }, + trigger: [], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig2CustomModule, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, + { + name: destType, + description: 'If module specific mandatory field is absent, event will fail', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'Email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + type: 'record', + }, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig, + }, + { + message: { + action: 'insert', + context: { + externalId: [ + { + type: 'ZOHO-Leads', + identifierType: 'Email', + }, + ], + mappedToDestination: 'true', + sources: { + job_run_id: 'cgiiurt8um7k7n5dq480', + task_run_id: 'cgiiurt8um7k7n5dq48g', + job_id: '2MUWghI7u85n91dd1qzGyswpZan', + version: '895/merge', + }, + }, + recordId: '2', + rudderId: '2', + fields: { + 'multi-language': 'Bengali', + }, + type: 'record', + }, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/Leads/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: { + 'multi-language': 'true', + 'multi class': 'false', + }, + trigger: ['workflow'], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig, + }, + { + metadata: [ + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: false, + statusCode: 400, + error: 'Leads object must have the Last_Name property(ies).', + statTags: { + errorCategory: 'dataValidation', + errorType: 'configuration', + destType: 'ZOHO', + module: 'destination', + implementation: 'cdkV2', + feature: 'router', + }, + destination: commonUpsertDestConfig, + }, + ], + }, + }, + }, + }, + { + name: destType, + description: + 'If multiselect key decision is not set from UI, Rudderstack will consider those as normal fields', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: upsertPayload3, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig3, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/Leads/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: commonOutput1, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig3, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, + { + name: destType, + description: 'Test Batching', + feature: 'router', + module: 'destination', + version: 'v0', + input: { + request: { + body: { + input: [ + { + message: upsertPayload3, + metadata: { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig3, + }, + { + message: upsertPayload3, + metadata: { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig3, + }, + { + message: upsertPayload3, + metadata: { + jobId: 3, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + destination: commonUpsertDestConfig3, + }, + ], + destType, + }, + method: 'POST', + }, + }, + output: { + response: { + status: 200, + body: { + output: [ + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/Leads/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: { + duplicate_check_fields: ['Email'], + data: [ + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + { + Email: 'subscribed@eewrfrd.com', + First_Name: 'subcribed', + Last_Name: ' User', + }, + ], + $append_values: {}, + trigger: ['workflow'], + }, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 1, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + { + jobId: 2, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig3, + }, + { + batchedRequest: { + version: '1', + type: 'REST', + method: 'POST', + endpoint: 'https://www.zohoapis.com/crm/v6/Leads/upsert', + headers: { + Authorization: 'Zoho-oauthtoken correct-access-token', + }, + params: {}, + body: { + JSON: commonOutput1, + JSON_ARRAY: {}, + XML: {}, + FORM: {}, + }, + files: {}, + }, + metadata: [ + { + jobId: 3, + userId: 'u1', + secret: { + accessToken: 'correct-access-token', + }, + }, + ], + batched: true, + statusCode: 200, + destination: commonUpsertDestConfig3, + }, + ], + }, + }, + }, + mockFns: defaultMockFns, + }, +]; diff --git a/test/integrations/sources/adjust/data.ts b/test/integrations/sources/adjust/data.ts index 975543fbec..e57feb45d4 100644 --- a/test/integrations/sources/adjust/data.ts +++ b/test/integrations/sources/adjust/data.ts @@ -1,7 +1,8 @@ +import { skip } from 'node:test'; import utils from '../../../../src/v0/util'; const defaultMockFns = () => { - jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); + jest.spyOn(utils, 'generateUUID').mockReturnValueOnce('97fcd7b2-cc24-47d7-b776-057b7b199513'); }; export const data = [ @@ -43,6 +44,7 @@ export const data = [ output: { batch: [ { + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', context: { library: { name: 'unknown', @@ -68,7 +70,6 @@ export const data = [ custom: 'custom', tracker_name: 'dummy', }, - anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', }, ], }, @@ -85,6 +86,7 @@ export const data = [ description: 'Simple track call with no query parameters', module: 'source', version: 'v0', + skipGo: 'FIXME', input: { request: { body: [ @@ -104,15 +106,19 @@ export const data = [ output: { response: { status: 200, - error: 'Query_parameters is missing', - statTags: { - destinationId: 'Non determinable', - errorCategory: 'transformation', - implementation: 'native', - module: 'source', - workspaceId: 'Non determinable', - }, - statusCode: 400, + body: [ + { + error: 'Query_parameters is missing', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], }, }, mockFns: () => { diff --git a/test/integrations/sources/appcenter/data.ts b/test/integrations/sources/appcenter/data.ts new file mode 100644 index 0000000000..0342b622d2 --- /dev/null +++ b/test/integrations/sources/appcenter/data.ts @@ -0,0 +1,372 @@ +import utils from '../../../../src/v0/util'; + +export const data = [ + { + name: 'appcenter', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + text: 'Hello from your abc-test app in App Center!', + sent_at: '2023-01-02T07: 53: 28.3117824Z', + url: 'https://appcenter.ms/users/abc-rudderstack.com/apps/abc-test', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + outputToSource: { + body: 'eyJ0ZXh0IjoiSGVsbG8gZnJvbSB5b3VyIGFiYy10ZXN0IGFwcCBpbiBBcHAgQ2VudGVyISIsInNlbnRfYXQiOiIyMDIzLTAxLTAyVDA3OiA1MzogMjguMzExNzgyNFoiLCJ1cmwiOiJodHRwczovL2FwcGNlbnRlci5tcy91c2Vycy9hYmMtcnVkZGVyc3RhY2suY29tL2FwcHMvYWJjLXRlc3QifQ==', + contentType: 'application/json', + }, + statusCode: 200, + }, + ], + }, + }, + }, + { + name: 'appcenter', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + app_name: 'MSAppCenterTesting', + branch: 'master', + build_status: 'Succeeded', + build_id: '1', + build_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/1', + build_reason: 'manual', + finish_time: '2021-03-02T16:41:29.891411Z', + icon_link: null, + notification_settings_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications', + os: 'Android', + start_time: '2021-03-02T16:34:13.9184874Z', + source_version: '7ed5c7b279316f19e9a0c45bb0fb49c0655471af', + sent_at: '2021-03-02T16:41:55.8819564Z', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'APPCENTER' }, + app: { name: 'MSAppCenterTesting', build: '1' }, + device: { type: 'Android' }, + + os: { name: 'Android' }, + }, + integrations: { APPCENTER: false }, + properties: { + app_name: 'MSAppCenterTesting', + branch: 'master', + build_status: 'Succeeded', + build_id: '1', + build_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/1', + build_reason: 'manual', + finish_time: '2021-03-02T16:41:29.891411Z', + icon_link: null, + notification_settings_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications', + os: 'Android', + start_time: '2021-03-02T16:34:13.9184874Z', + source_version: '7ed5c7b279316f19e9a0c45bb0fb49c0655471af', + sent_at: '2021-03-02T16:41:55.8819564Z', + }, + type: 'track', + event: 'Build Succeeded', + originalTimeStamp: '2021-03-02T16:34:13.9184874Z', + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + sentAt: '2021-03-02T16:41:55.8819564Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appcenter', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + app_name: 'MSAppCenterTesting', + branch: 'master', + build_status: 'Broken', + build_id: '2', + build_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/2', + build_reason: 'automatic', + finish_time: '2021-03-02T16:52:04.2587506Z', + icon_link: null, + notification_settings_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications', + os: 'Android', + start_time: '2021-03-02T16:50:52.2584107Z', + source_version: '0624e1e3e48eaf2371c37316208ff83bdd5c123b', + sent_at: '2021-03-02T16:52:35.8848052Z', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'APPCENTER' }, + app: { name: 'MSAppCenterTesting', build: '2' }, + device: { type: 'Android' }, + + os: { name: 'Android' }, + }, + integrations: { APPCENTER: false }, + properties: { + app_name: 'MSAppCenterTesting', + branch: 'master', + build_status: 'Broken', + build_id: '2', + build_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/build/branches/master/builds/2', + build_reason: 'automatic', + finish_time: '2021-03-02T16:52:04.2587506Z', + icon_link: null, + notification_settings_link: + 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/settings/notifications', + os: 'Android', + start_time: '2021-03-02T16:50:52.2584107Z', + source_version: '0624e1e3e48eaf2371c37316208ff83bdd5c123b', + sent_at: '2021-03-02T16:52:35.8848052Z', + }, + type: 'track', + event: 'Build Failed', + originalTimeStamp: '2021-03-02T16:50:52.2584107Z', + sentAt: '2021-03-02T16:52:35.8848052Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appcenter', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + app_name: 'MSAppCenterTesting', + app_display_name: 'MSAppCenterTesting', + release_id: '1', + platform: 'Android', + uploaded_at: '2021-03-02T17:49:35.463Z', + fingerprint: '9cbdc86d96c5359d2af3972fdda46624', + release_notes: 'Degraded to 4.0.0', + version: '1614707021', + short_version: '1.0', + min_os: '7.1', + mandatory_update: true, + size: 2919106, + provisioning_profile_name: null, + provisioning_profile_type: null, + bundle_identifier: 'tech.desusai.msappcentertesting', + install_link: + 'https://install.appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/releases/1?source=email', + icon_link: + 'https://appcenter-filemanagement-distrib2ede6f06e.azureedge.net/dbbd3d57-9c09-448b-9782-0d57200f7c9b/ic_launcher.png?sv=2019-02-02&sr=c&sig=BNzQcMcvTbwf4fv59ByGiYXsr%2BA9PYDFyGJCqsE2RO0%3D&se=2021-03-09T17%3A49%3A35Z&sp=r', + distribution_group_id: '00000000-0000-0000-0000-000000000000', + installable: true, + sent_at: '2021-03-02T17:49:37.127635Z', + app_id: 'ce8b5280-4605-4c1c-8c48-bd54c8fdda31', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'APPCENTER' }, + app: { + name: 'MSAppCenterTesting', + version: '1.0', + namespace: 'tech.desusai.msappcentertesting', + }, + device: { type: 'Android' }, + + os: { name: 'Android' }, + }, + integrations: { APPCENTER: false }, + properties: { + app_name: 'MSAppCenterTesting', + app_display_name: 'MSAppCenterTesting', + release_id: '1', + platform: 'Android', + uploaded_at: '2021-03-02T17:49:35.463Z', + fingerprint: '9cbdc86d96c5359d2af3972fdda46624', + release_notes: 'Degraded to 4.0.0', + version: '1614707021', + short_version: '1.0', + min_os: '7.1', + mandatory_update: true, + size: 2919106, + provisioning_profile_name: null, + provisioning_profile_type: null, + bundle_identifier: 'tech.desusai.msappcentertesting', + install_link: + 'https://install.appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/releases/1?source=email', + icon_link: + 'https://appcenter-filemanagement-distrib2ede6f06e.azureedge.net/dbbd3d57-9c09-448b-9782-0d57200f7c9b/ic_launcher.png?sv=2019-02-02&sr=c&sig=BNzQcMcvTbwf4fv59ByGiYXsr%2BA9PYDFyGJCqsE2RO0%3D&se=2021-03-09T17%3A49%3A35Z&sp=r', + distribution_group_id: '00000000-0000-0000-0000-000000000000', + installable: true, + sent_at: '2021-03-02T17:49:37.127635Z', + app_id: 'ce8b5280-4605-4c1c-8c48-bd54c8fdda31', + }, + type: 'track', + event: 'Released Version 1.0', + sentAt: '2021-03-02T17:49:37.127635Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appcenter', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + id: '1139624368u', + name: 'tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25)', + reason: 'java.lang.ArithmeticException: divide by zero', + file_name: null, + line_number: null, + url: 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/crashes/errors/1139624368u', + app_display_name: 'MSAppCenterTesting', + app_platform: 'Java', + app_version: '1.0(1)', + stack_trace: [ + 'tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25);', + ], + affected_users: 0, + crash_count: 0, + sent_at: '2021-03-02T18:14:33.9713246Z', + app_id: 'ce8b5280-4605-4c1c-8c48-bd54c8fdda31', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'APPCENTER' }, + app: { name: 'MSAppCenterTesting', version: '1.0(1)' }, + }, + integrations: { APPCENTER: false }, + properties: { + id: '1139624368u', + name: 'tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25)', + reason: 'java.lang.ArithmeticException: divide by zero', + file_name: null, + line_number: null, + url: 'https://appcenter.ms/users/venkat-rudderstack.com/apps/MSAppCenterTesting/crashes/errors/1139624368u', + app_display_name: 'MSAppCenterTesting', + app_platform: 'Java', + app_version: '1.0(1)', + stack_trace: [ + 'tech.desusai.msappcentertesting.MainActivity$1.onClick (MainActivity.java:25);', + ], + affected_users: 0, + crash_count: 0, + sent_at: '2021-03-02T18:14:33.9713246Z', + app_id: 'ce8b5280-4605-4c1c-8c48-bd54c8fdda31', + }, + type: 'track', + event: 'App Crashed', + sentAt: '2021-03-02T18:14:33.9713246Z', + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns: () => { + jest.spyOn(utils, 'generateUUID').mockReturnValueOnce('97fcd7b2-cc24-47d7-b776-057b7b199513'); + }, +})); diff --git a/test/integrations/sources/appsflyer/data.ts b/test/integrations/sources/appsflyer/data.ts new file mode 100644 index 0000000000..5ec64a07a8 --- /dev/null +++ b/test/integrations/sources/appsflyer/data.ts @@ -0,0 +1,2050 @@ +import utils from '../../../../src/v0/util'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data = [ + { + name: 'appsflyer', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + device_type: 'iPhoneXR', + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'ios', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + model: 'iPhoneXR', + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'ios', version: '12.3.1' }, + traits: { + address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' }, + userId: 'hi.from@appsflyer.example.com', + }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + type: 'track', + event: 'My Apps', + userId: 'hi.from@appsflyer.example.com', + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'ios', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + device_type: 'Nokia 5.3', + idfa: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'android', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + model: 'Nokia 5.3', + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'android', version: '12.3.1' }, + traits: { + address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' }, + userId: 'hi.from@appsflyer.example.com', + }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + type: 'track', + event: 'My Apps', + userId: 'hi.from@appsflyer.example.com', + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'android', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + device_type: 'iPhoneXR', + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'ios', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Unknwon event type from Appsflyer', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + device_type: 'iPhoneXR', + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'ios', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + model: 'iPhoneXR', + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'ios', version: '12.3.1' }, + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + type: 'track', + event: 'My Apps', + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'ios', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'ios', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'ios', version: '12.3.1' }, + traits: { + address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' }, + userId: 'hi.from@appsflyer.example.com', + }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + type: 'track', + event: 'My Apps', + userId: 'hi.from@appsflyer.example.com', + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'ios', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'watchos', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'watchos', version: '12.3.1' }, + traits: { + address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' }, + userId: 'hi.from@appsflyer.example.com', + }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + type: 'track', + event: 'My Apps', + userId: 'hi.from@appsflyer.example.com', + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'watchos', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-6', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'ipados', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'ipados', version: '12.3.1' }, + traits: { + address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' }, + userId: 'hi.from@appsflyer.example.com', + }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + type: 'track', + event: 'My Apps', + userId: 'hi.from@appsflyer.example.com', + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'ipados', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'appsflyer', + description: 'test-7', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + customer_user_id: 'hi.from@appsflyer.example.com', + is_lat: null, + contributor_2_af_prt: null, + bundle_id: 'com.appsflyer.AppsFlyer', + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + app_version: '1.4.1', + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + city: 'Khu Pho Binh Hoa', + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + app_name: 'AppsFlyer', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + postal_code: '823941', + wifi: true, + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + country_code: 'VN', + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + appsflyer_id: '1547985076649-5309999', + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + ip: '1.1.1.1', + oaid: null, + event_time: '2020-01-15 14:57:24.898', + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + android_id: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + idfa: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + carrier: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + os_version: '12.3.1', + platform: 'tvos', + af_sub3: null, + contributor_3_match_type: null, + selected_timezone: 'UTC', + af_ad_id: null, + contributor_3_touch_time: null, + user_agent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'AF' }, + ip: '1.1.1.1', + timezone: 'UTC', + userAgent: 'AppsFlyer/1 CFNetwork/978.0.7 Darwin/18.6.0', + app: { + namespace: 'com.appsflyer.AppsFlyer', + version: '1.4.1', + name: 'AppsFlyer', + }, + device: { + advertisingId: 'A7071198-3848-40A5-B3D0-94578D9BZZZZ', + adTrackingEnabled: true, + }, + network: { wifi: true }, + os: { name: 'tvos', version: '12.3.1' }, + traits: { + address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' }, + userId: 'hi.from@appsflyer.example.com', + }, + externalId: [{ type: 'appsflyerExternalId', value: '1547985076649-5309999' }], + }, + integrations: { AF: false }, + properties: { + idfv: '868049A3-4B2F-4A11-9B00-CFFC362XXXXX', + device_category: 'phone', + af_sub1: null, + is_lat: null, + contributor_2_af_prt: null, + gp_broadcast_referrer: '', + contributor_2_touch_time: null, + contributor_3_touch_type: null, + event_source: 'SDK', + af_cost_value: null, + contributor_1_match_type: null, + contributor_3_af_prt: null, + custom_data: null, + contributor_2_touch_type: null, + gp_install_begin: null, + amazon_aid: null, + gp_referrer: null, + af_cost_model: null, + af_c_id: null, + attributed_touch_time_selected_timezone: null, + selected_currency: 'USD', + install_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + install_time: '2019-01-20 04:51:16.000', + operator: null, + attributed_touch_type: null, + af_attribution_lookback: null, + campaign_type: null, + keyword_match_type: null, + af_adset_id: null, + device_download_time_selected_timezone: '2019-01-20 04:51:16.000+0000', + contributor_2_media_source: null, + conversion_type: null, + contributor_2_match_type: null, + api_version: '2.0', + attributed_touch_time: null, + revenue_in_selected_currency: null, + is_retargeting: false, + gp_click_time: null, + contributor_1_af_prt: null, + match_type: null, + dma: 'None', + http_referrer: null, + af_sub5: null, + af_prt: null, + event_revenue_currency: 'USD', + store_reinstall: null, + install_app_store: null, + media_source: 'organic', + deeplink_url: null, + campaign: null, + af_keywords: null, + region: 'AS', + cost_in_selected_currency: null, + event_value: '{}', + oaid: null, + is_receipt_validated: null, + contributor_1_campaign: null, + af_sub4: null, + imei: null, + contributor_3_campaign: null, + event_revenue_usd: null, + af_sub2: null, + original_url: null, + contributor_2_campaign: null, + contributor_3_media_source: null, + af_adset: null, + af_ad: null, + state: '57', + network_account_id: null, + retargeting_conversion_type: null, + af_channel: null, + af_cost_currency: null, + contributor_1_media_source: null, + keyword_id: null, + device_download_time: '2019-01-20 04:51:16.000', + contributor_1_touch_type: null, + af_reengagement_window: null, + af_siteid: null, + language: 'en-US', + app_id: 'id1217828636', + contributor_1_touch_time: null, + event_revenue: null, + af_ad_type: null, + event_name: 'My Apps', + af_sub_siteid: null, + advertising_id: null, + af_sub3: null, + contributor_3_match_type: null, + af_ad_id: null, + contributor_3_touch_time: null, + is_primary_attribution: true, + sdk_version: 'v4.10.0', + event_time_selected_timezone: '2020-01-15 14:57:24.898+0000', + }, + type: 'track', + event: 'My Apps', + userId: 'hi.from@appsflyer.example.com', + timestamp: '2020-01-15 14:57:24.898', + originalTimestamp: '2020-01-15 14:57:24.898', + platform: 'tvos', + traits: { address: { city: 'Khu Pho Binh Hoa', zip: '823941', country: 'VN' } }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns: () => { + defaultMockFns(); + }, +})); diff --git a/test/integrations/sources/auth0/data.ts b/test/integrations/sources/auth0/data.ts index 44b511cad2..b012887bc4 100644 --- a/test/integrations/sources/auth0/data.ts +++ b/test/integrations/sources/auth0/data.ts @@ -10,6 +10,7 @@ export const data = [ description: 'successful signup', module: 'source', version: 'v0', + input: { request: { body: [ @@ -532,6 +533,7 @@ export const data = [ description: 'add member to an organization', module: 'source', version: 'v0', + input: { request: { body: [ @@ -671,6 +673,7 @@ export const data = [ description: 'update tenant settings', module: 'source', version: 'v0', + input: { request: { body: [ @@ -1242,6 +1245,7 @@ export const data = [ description: 'missing userId', module: 'source', version: 'v0', + input: { request: { body: [ @@ -1348,6 +1352,7 @@ export const data = [ description: 'missing userId for all the requests in a batch', module: 'source', version: 'v0', + input: { request: { body: [ @@ -1503,6 +1508,7 @@ export const data = [ description: 'empty batch', module: 'source', version: 'v0', + skipGo: 'Created this case manually', input: { request: { body: [], diff --git a/test/integrations/sources/braze/common.ts b/test/integrations/sources/braze/common.ts new file mode 100644 index 0000000000..a8271e3e9c --- /dev/null +++ b/test/integrations/sources/braze/common.ts @@ -0,0 +1,30 @@ +export const commonSourceDefinition = { + ID: '1lh9senY3vrBg4JQXswWzyYBTOO', + Name: 'Braze', + Category: 'webhook', + Type: 'cloud', +}; + +export const DgSourceTrackingPlanConfig = { + sourceId: '', + version: 0, + config: null, + mergedConfig: null, + deleted: false, + trackingPlan: { + id: '', + version: 0, + }, +}; + +export const commonSourceConfigProperties = { + Enabled: true, + WorkspaceID: '2hSS1hZ8kuCpUZAAYsQucAFdob9', + Destinations: null, + WriteKey: '2hgvYykpvMaE5Eg47Au8RWC9Yza', + DgSourceTrackingPlanConfig: DgSourceTrackingPlanConfig, + Transient: false, + GeoEnrichment: { + Enabled: false, + }, +}; diff --git a/test/integrations/sources/braze/data.ts b/test/integrations/sources/braze/data.ts new file mode 100644 index 0000000000..a4031e1bd0 --- /dev/null +++ b/test/integrations/sources/braze/data.ts @@ -0,0 +1,1275 @@ +import utils from '../../../../src/v0/util'; +import { commonSourceConfigProperties, commonSourceDefinition } from './common'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data = [ + { + name: 'braze', + description: 'event mapping done in UI', + module: 'source', + version: 'v1', + skipGo: 'Custom source config', + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.inappmessage.Click', + properties: { + device_model: 'samsung', + }, + user: { + user_id: 'user_id', + external_user_id: 'externalUserId', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'users.messages.inappmessage.Click', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: 'user_id', + context: { + device: { + model: 'samsung', + }, + integration: { + name: 'Braze', + }, + library: { + name: 'unknown', + version: 'unknown', + }, + }, + event: 'In-App Message Clicked', + integrations: { + Braze: false, + }, + type: 'track', + userId: 'externalUserId', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'The event is not mapped in the UI', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.inappmessage.Click', + properties: { + device_model: 'samsung', + }, + user: { + user_id: 'user_id', + external_user_id: 'externalUserId', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: 'user_id', + context: { + device: { + model: 'samsung', + }, + integration: { + name: 'Braze', + }, + library: { + name: 'unknown', + version: 'unknown', + }, + }, + event: 'users.messages.inappmessage.Click', + integrations: { + Braze: false, + }, + type: 'track', + userId: 'externalUserId', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.inappmessage.Click event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.inappmessage.Click', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1607988752, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + timezone: 'America/Chicago', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + platform: 'android', + os_version: 'Android (N)', + device_model: 'Nexus 5X', + button_id: '0', + send_id: 'f123456789abcdef01234567', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { + id: 'fedcba87-6543-210f-edc-ba9876543210', + model: 'Nexus 5X', + }, + timezone: 'America/Chicago', + os: { version: 'Android (N)', name: 'android' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.inappmessage.Click', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + button_id: '0', + send_id: 'f123456789abcdef01234567', + }, + timestamp: '2020-12-14T23:32:32.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.pushnotification.Send event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.pushnotification.Send', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + timezone: 'America/Chicago', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + platform: 'ios', + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + send_id: 'f123456789abcdef01234567', + dispatch_id: '01234567-89ab-cdef-0123-456789abcdef', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { id: 'fedcba87-6543-210f-edc-ba9876543210' }, + timezone: 'America/Chicago', + os: { name: 'ios' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.pushnotification.Send', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + send_id: 'f123456789abcdef01234567', + dispatch_id: '01234567-89ab-cdef-0123-456789abcdef', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.email.Open event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.email.Open', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + timezone: 'America/Chicago', + }, + properties: { + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + dispatch_id: '12345qwert', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + email_address: 'test@test.com', + send_id: 'f123456789abcdef01234567', + user_agent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Safari/537.36', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + timezone: 'America/Chicago', + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Safari/537.36', + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.email.Open', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + traits: { email: 'test@test.com' }, + properties: { + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + dispatch_id: '12345qwert', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + send_id: 'f123456789abcdef01234567', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.sms.Delivery send', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.sms.Delivery', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + timezone: 'America/Chicago', + }, + properties: { + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + dispatch_id: '12345qwert', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + to_phone_number: '+16462345678', + subscription_group_id: '41234567-89ab-cdef-0123-456789abcdef', + from_phone_number: '+12123470922', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + timezone: 'America/Chicago', + integration: { name: 'Braze' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.sms.Delivery', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + traits: { phone: '+16462345678' }, + properties: { + campaign_id: '11234567-89ab-cdef-0123-456789abcdef', + campaign_name: 'Test Campaign', + dispatch_id: '12345qwert', + message_variation_id: 'c1234567-89ab-cdef-0123-456789abcdef', + subscription_group_id: '41234567-89ab-cdef-0123-456789abcdef', + from_phone_number: '+12123470922', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.inappmessage.Click event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.inappmessage.Click', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + timezone: 'America/Chicago', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'My Cool Campaign', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + platform: 'android', + os_version: 'Android (N)', + device_model: 'Nexus 5X', + button_id: '0', + send_id: 'f123456789abcdef01234567', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { + id: 'fedcba87-6543-210f-edc-ba9876543210', + model: 'Nexus 5X', + }, + timezone: 'America/Chicago', + os: { version: 'Android (N)', name: 'android' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.inappmessage.Click', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'My Cool Campaign', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + button_id: '0', + send_id: 'f123456789abcdef01234567', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.pushnotification.Send event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.pushnotification.Send', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + timezone: 'America/Chicago', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + platform: 'ios', + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'My Cool Campaign', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + send_id: 'f123456789abcdef01234567', + dispatch_id: '01234567-89ab-cdef-0123-456789abcdef', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { id: 'fedcba87-6543-210f-edc-ba9876543210' }, + timezone: 'America/Chicago', + os: { name: 'ios' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.pushnotification.Send', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'My Cool Campaign', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + send_id: 'f123456789abcdef01234567', + dispatch_id: '01234567-89ab-cdef-0123-456789abcdef', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.email.Open event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.email.Open', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + timezone: 'America/Chicago', + }, + properties: { + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'My Cool Canvas', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + dispatch_id: '12345qwert', + email_address: 'test@test.com', + send_id: 'f123456789abcdef01234567', + user_agent: + 'Mozilla/5.0(Macintosh;IntelMacOSX10_13_5)AppleWebKit/537.36(KHTML,likeGecko)Chrome/67.0.3396.99Safari/537.36', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + timezone: 'America/Chicago', + userAgent: + 'Mozilla/5.0(Macintosh;IntelMacOSX10_13_5)AppleWebKit/537.36(KHTML,likeGecko)Chrome/67.0.3396.99Safari/537.36', + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.email.Open', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + traits: { email: 'test@test.com' }, + properties: { + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'My Cool Canvas', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + dispatch_id: '12345qwert', + send_id: 'f123456789abcdef01234567', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.messages.sms.Delivery event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.messages.sms.Delivery', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + timezone: 'America/Chicago', + }, + properties: { + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'MyCoolCanvas', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + dispatch_id: '12345qwert', + to_phone_number: '+16462345678', + subscription_group_id: '41234567-89ab-cdef-0123-456789abcdef', + from_phone_number: '+12123470922', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + timezone: 'America/Chicago', + integration: { name: 'Braze' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.messages.sms.Delivery', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + traits: { phone: '+16462345678' }, + properties: { + canvas_id: '11234567-89ab-cdef-0123-456789abcdef', + canvas_name: 'MyCoolCanvas', + canvas_variation_id: '31234567-89ab-cdef-0123-456789abcdef', + canvas_step_id: '41234567-89ab-cdef-0123-456789abcdef', + dispatch_id: '12345qwert', + subscription_group_id: '41234567-89ab-cdef-0123-456789abcdef', + from_phone_number: '+12123470922', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.behaviors.CustomEvent any custom event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.behaviors.CustomEvent', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + timezone: 'America/Chicago', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + platform: 'ios', + os_version: 'iOS10.3.1', + device_model: 'iPhone7Plus', + name: 'customeventname', + ad_id: '01234567-89ab-cdef-0123-456789abcdef', + ad_id_type: 'roku_ad_id', + ad_tracking_enabled: true, + custom_properties: { + stringpropertyname: 'a', + numberpropertyname: 1, + listpropertyname: ['a', 'b'], + }, + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { + id: 'fedcba87-6543-210f-edc-ba9876543210', + model: 'iPhone7Plus', + advertisingId: '01234567-89ab-cdef-0123-456789abcdef', + adTrackingEnabled: true, + }, + timezone: 'America/Chicago', + os: { version: 'iOS10.3.1', name: 'ios' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.behaviors.CustomEvent', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + name: 'customeventname', + ad_id_type: 'roku_ad_id', + custom_properties: { + stringpropertyname: 'a', + numberpropertyname: 1, + listpropertyname: ['a', 'b'], + }, + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.behaviors.Purchase event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.behaviors.Purchase', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + timezone: 'America/Chicago', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + platform: 'ios', + os_version: 'iOS10.3.1', + device_model: 'iPhone7Plus', + product_id: '1234', + price: 12.34, + currency: 'AED', + ad_id: '01234567-89ab-cdef-0123-456789abcdef', + ad_id_type: 'roku_ad_id', + ad_tracking_enabled: true, + purchase_properties: { + stringpropertyname: 'a', + numberpropertyname: 1, + listpropertyname: ['a', 'b'], + }, + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { + id: 'fedcba87-6543-210f-edc-ba9876543210', + model: 'iPhone7Plus', + advertisingId: '01234567-89ab-cdef-0123-456789abcdef', + adTrackingEnabled: true, + }, + timezone: 'America/Chicago', + os: { version: 'iOS10.3.1', name: 'ios' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.behaviors.Purchase', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + product_id: '1234', + price: 12.34, + currency: 'AED', + ad_id_type: 'roku_ad_id', + purchase_properties: { + stringpropertyname: 'a', + numberpropertyname: 1, + listpropertyname: ['a', 'b'], + }, + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'braze', + description: 'users.behaviors.app.SessionStart event', + module: 'source', + version: 'v1', + + input: { + request: { + body: [ + { + event: { + events: [ + { + event_type: 'users.behaviors.app.SessionStart', + id: 'a1234567-89ab-cdef-0123-456789abcdef', + time: 1477502783, + user: { + user_id: '0123456789abcdef01234567', + external_user_id: 'user_id', + device_id: 'fedcba87-6543-210f-edc-ba9876543210', + }, + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + platform: 'ios', + os_version: 'iOS10.3.1', + device_model: 'iPhone7Plus', + session_id: 'b1234567-89ab-cdef-0123-456789abcdef', + }, + }, + ], + }, + source: { + ID: '2hgvYyU5TYaFvVzBge6tF2UKoeG', + OriginalID: '', + Name: 'Braze source', + SourceDefinition: commonSourceDefinition, + Config: { + customMapping: [ + { + from: 'randomEvent', + to: 'In-App Message Clicked', + }, + ], + }, + ...commonSourceConfigProperties, + }, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Braze' }, + device: { + id: 'fedcba87-6543-210f-edc-ba9876543210', + model: 'iPhone7Plus', + }, + os: { version: 'iOS10.3.1', name: 'ios' }, + }, + integrations: { Braze: false }, + type: 'track', + event: 'users.behaviors.app.SessionStart', + messageId: 'a1234567-89ab-cdef-0123-456789abcdef', + anonymousId: '0123456789abcdef01234567', + userId: 'user_id', + properties: { + app_id: '01234567-89ab-cdef-0123-456789abcdef', + session_id: 'b1234567-89ab-cdef-0123-456789abcdef', + }, + timestamp: '2016-10-26T17:26:23.000Z', + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns: () => { + defaultMockFns(); + }, +})); diff --git a/test/integrations/sources/canny/data.ts b/test/integrations/sources/canny/data.ts new file mode 100644 index 0000000000..ac471904f9 --- /dev/null +++ b/test/integrations/sources/canny/data.ts @@ -0,0 +1,1665 @@ +import utils from '../../../../src/v0/util'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data = [ + { + name: 'canny', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-28T10:52:46.294Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 13, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-28T10:52:46.172Z', + customFields: [{ id: '62e13820d7949d44b92d3876', name: 'abc', value: '123' }], + details: 'Array of images', + eta: null, + id: '62e26a7e1d4ea13c124337bd', + imageURLs: [ + 'https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg', + 'https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg', + ], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Custom Fields Testing', + url: 'https://rudder.canny.io/admin/board/features/p/custom-fields-testing', + }, + objectType: 'post', + type: 'post.created', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'post.created', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-28T10:52:46.294Z', + originalTimestamp: '2022-07-28T10:52:46.294Z', + type: 'track', + properties: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 13, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-28T10:52:46.172Z', + customFields: [{ id: '62e13820d7949d44b92d3876', name: 'abc', value: '123' }], + details: 'Array of images', + eta: null, + id: '62e26a7e1d4ea13c124337bd', + imageURLs: [ + 'https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg', + 'https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg', + ], + objectType: 'post', + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Custom Fields Testing', + url: 'https://rudder.canny.io/admin/board/features/p/custom-fields-testing', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T10:35:16.390Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 10, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-26T08:18:52.459Z', + deletedBy: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + details: "This is the post's details", + eta: null, + id: '62dfa36c9950e94655320fe7', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-4', + }, + objectType: 'post', + type: 'post.deleted', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'post.deleted', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T10:35:16.390Z', + originalTimestamp: '2022-07-26T10:35:16.390Z', + type: 'track', + properties: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 10, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-26T08:18:52.459Z', + deletedBy: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + details: "This is the post's details", + eta: null, + id: '62dfa36c9950e94655320fe7', + imageURLs: [], + objectType: 'post', + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-4', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T18:32:28.337Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + category: null, + commentCount: 0, + created: '2022-07-26T10:43:43.752Z', + details: "This is the post's details", + eta: null, + id: '62dfc55ffe7f6f465b9b4568', + imageURLs: [], + issue: { + description: + "This is the post's details\n\nhttps://rudder.canny.io/admin/board/features/p/post-title-8", + id: '10001', + key: 'TES-2', + status: 'To Do', + summary: 'Canny Source Testing', + url: 'https://rudderstack-user.atlassian.net/browse/TES-2', + }, + owner: null, + score: 2, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-8', + }, + objectType: 'post', + type: 'post.jira_issue_linked', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'post.jira_issue_linked', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T18:32:28.337Z', + originalTimestamp: '2022-07-26T18:32:28.337Z', + type: 'track', + properties: { + by: null, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + category: null, + commentCount: 0, + created: '2022-07-26T10:43:43.752Z', + details: "This is the post's details", + eta: null, + id: '62dfc55ffe7f6f465b9b4568', + imageURLs: [], + issue: { + description: + "This is the post's details\n\nhttps://rudder.canny.io/admin/board/features/p/post-title-8", + id: '10001', + key: 'TES-2', + status: 'To Do', + summary: 'Canny Source Testing', + url: 'https://rudderstack-user.atlassian.net/browse/TES-2', + }, + objectType: 'post', + owner: null, + score: 2, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-8', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-27T04:08:24.377Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + category: null, + commentCount: 0, + created: '2022-07-26T11:32:31.228Z', + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + issue: { + description: + 'Array of images\n\nhttps://rudder.canny.io/admin/board/features/p/images-testing-2', + id: '10002', + key: 'TES-3', + status: 'To Do', + summary: 'Images testing', + url: 'https://rudderstack-user.atlassian.net/browse/TES-3', + }, + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + objectType: 'post', + type: 'post.jira_issue_unlinked', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'post.jira_issue_unlinked', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-27T04:08:24.377Z', + originalTimestamp: '2022-07-27T04:08:24.377Z', + type: 'track', + properties: { + objectType: 'post', + by: null, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + category: null, + commentCount: 0, + created: '2022-07-26T11:32:31.228Z', + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + issue: { + description: + 'Array of images\n\nhttps://rudder.canny.io/admin/board/features/p/images-testing-2', + id: '10002', + key: 'TES-3', + status: 'To Do', + summary: 'Images testing', + url: 'https://rudderstack-user.atlassian.net/browse/TES-3', + }, + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T18:07:03.143Z', + object: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + changeComment: { + imageURLs: ['https://canny.io/images/0a4b1c6a967ad9fc17f0c71dc11d1de2.webp'], + value: '', + }, + changedAt: '2022-07-26T18:07:03.143Z', + changer: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + commentCount: 1, + created: '2022-07-26T08:22:31.089Z', + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + jira: { linkedIssues: [], linkedIssueIDs: [] }, + owner: null, + score: 2, + status: 'planned', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + objectType: 'post', + type: 'post.status_changed', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'post.status_changed', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T18:07:03.143Z', + originalTimestamp: '2022-07-26T18:07:03.143Z', + type: 'track', + properties: { + objectType: 'post', + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + changeComment: { + imageURLs: ['https://canny.io/images/0a4b1c6a967ad9fc17f0c71dc11d1de2.webp'], + value: '', + }, + changedAt: '2022-07-26T18:07:03.143Z', + changer: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + commentCount: 1, + created: '2022-07-26T08:22:31.089Z', + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + jira: { linkedIssues: [], linkedIssueIDs: [] }, + owner: null, + score: 2, + status: 'planned', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T10:52:17.712Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 11, + url: 'https://rudder.canny.io/admin/board/features', + }, + created: '2022-07-26T10:52:17.618Z', + id: '62dfc761af6e2b467381b103', + imageURLs: ['https://canny.io/images/59ef1b731f87d1c84bbdc078d0b9221e.webp'], + internal: true, + mentions: [], + parentID: null, + post: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 1, + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + owner: null, + score: 2, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + private: false, + value: 'webhook-test', + }, + objectType: 'comment', + type: 'comment.created', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'comment.created', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T10:52:17.712Z', + originalTimestamp: '2022-07-26T10:52:17.712Z', + type: 'track', + properties: { + objectType: 'comment', + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 11, + url: 'https://rudder.canny.io/admin/board/features', + }, + created: '2022-07-26T10:52:17.618Z', + id: '62dfc761af6e2b467381b103', + imageURLs: ['https://canny.io/images/59ef1b731f87d1c84bbdc078d0b9221e.webp'], + internal: true, + mentions: [], + parentID: null, + post: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 1, + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + owner: null, + score: 2, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + private: false, + value: 'webhook-test', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-6', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-27T04:12:09.290Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + created: '2022-07-27T04:11:59.942Z', + id: '62e0bb0faf6e2b467328b133', + imageURLs: [], + parentID: null, + post: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 0, + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + private: false, + value: 'good', + }, + objectType: 'comment', + type: 'comment.deleted', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'comment.deleted', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-27T04:12:09.290Z', + originalTimestamp: '2022-07-27T04:12:09.290Z', + type: 'track', + properties: { + objectType: 'comment', + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + created: '2022-07-27T04:11:59.942Z', + id: '62e0bb0faf6e2b467328b133', + imageURLs: [], + parentID: null, + post: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 0, + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + private: false, + value: 'good', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-7', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T11:32:31.378Z', + object: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T11:32:31.263Z', + id: '62dfd0cfb2870d468c9618f5', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 0, + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + score: 1, + voter: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + }, + objectType: 'vote', + type: 'vote.created', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'vote.created', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T11:32:31.378Z', + originalTimestamp: '2022-07-26T11:32:31.378Z', + type: 'track', + properties: { + objectType: 'vote', + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T11:32:31.263Z', + id: '62dfd0cfb2870d468c9618f5', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 0, + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + score: 1, + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-8', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T18:09:27.358Z', + object: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T08:22:31.109Z', + id: '62dfa4479950e9465532a338', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 1, + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + owner: null, + score: 1, + status: 'planned', + tags: [ + { + id: '62e02db67ad24c46bc175f56', + name: 'abc-tag', + postCount: 1, + url: 'https://rudder.canny.io/admin/board/features?tags=abc-tag', + }, + ], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + score: 0, + voter: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + }, + objectType: 'vote', + type: 'vote.deleted', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + event: 'vote.deleted', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T18:09:27.358Z', + originalTimestamp: '2022-07-26T18:09:27.358Z', + type: 'track', + properties: { + objectType: 'vote', + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T08:22:31.109Z', + id: '62dfa4479950e9465532a338', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 1, + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + owner: null, + score: 1, + status: 'planned', + tags: [ + { + id: '62e02db67ad24c46bc175f56', + name: 'abc-tag', + postCount: 1, + url: 'https://rudder.canny.io/admin/board/features?tags=abc-tag', + }, + ], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + score: 0, + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-9', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-28T10:52:46.294Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: 'sampleuserId', + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 13, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-28T10:52:46.172Z', + customFields: [{ id: '62e13820d7949d44b92d3876', name: 'abc', value: '123' }], + details: 'Array of images', + eta: null, + id: '62e26a7e1d4ea13c124337bd', + imageURLs: [ + 'https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg', + 'https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg', + ], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Custom Fields Testing', + url: 'https://rudder.canny.io/admin/board/features/p/custom-fields-testing', + }, + objectType: 'post', + type: 'post.created', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: 'sampleuserId', + event: 'post.created', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-28T10:52:46.294Z', + originalTimestamp: '2022-07-28T10:52:46.294Z', + type: 'track', + properties: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 13, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-28T10:52:46.172Z', + customFields: [{ id: '62e13820d7949d44b92d3876', name: 'abc', value: '123' }], + details: 'Array of images', + eta: null, + id: '62e26a7e1d4ea13c124337bd', + imageURLs: [ + 'https://canny.io/images/6371453a825c79351c52a6063c3af476.jpg', + 'https://canny.io/images/47db6ee5035bfb45ea87a74f2eb17928.jpg', + ], + objectType: 'post', + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Custom Fields Testing', + url: 'https://rudder.canny.io/admin/board/features/p/custom-fields-testing', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-10', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T11:32:31.378Z', + object: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T11:32:31.263Z', + id: '62dfd0cfb2870d468c9618f5', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 0, + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + score: 1, + voter: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: '123', + }, + }, + objectType: 'vote', + type: 'vote.created', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '123', + event: 'vote.created', + integrations: { Canny: false }, + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Canny', version: '1.0.0' }, + traits: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + }, + externalId: [{ type: 'cannyUserId', id: '62d14c90fff7c80d0ec08375' }], + }, + timestamp: '2022-07-26T11:32:31.378Z', + originalTimestamp: '2022-07-26T11:32:31.378Z', + type: 'track', + properties: { + objectType: 'vote', + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T11:32:31.263Z', + id: '62dfd0cfb2870d468c9618f5', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 0, + details: 'Array of images', + eta: null, + id: '62dfd0cfb2870d468c9618dd', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Images testing', + url: 'https://rudder.canny.io/admin/board/features/p/images-testing-2', + }, + score: 1, + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-11', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T18:09:27.358Z', + object: { + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 12, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + created: '2022-07-26T08:22:31.109Z', + id: '62dfa4479950e9465532a338', + post: { + author: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + by: null, + category: null, + commentCount: 1, + details: "This is the post's details", + eta: null, + id: '62dfa4479950e9465532a31e', + imageURLs: [], + owner: null, + score: 1, + status: 'planned', + tags: [ + { + id: '62e02db67ad24c46bc175f56', + name: 'abc-tag', + postCount: 1, + url: 'https://rudder.canny.io/admin/board/features?tags=abc-tag', + }, + ], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-7', + }, + score: 0, + voter: { + avatarURL: 'https://canny.io/images/cddfd145056cd4bc04132ee0e7de04ee.png', + created: '2022-07-15T11:16:32.648Z', + email: null, + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + }, + objectType: 'vote', + type: 'vote.deleted', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + statusCode: 400, + error: + 'Missing essential fields from Canny. Error: (TypeError [ERR_INVALID_ARG_TYPE]: The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received null)', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + }, + ], + }, + }, + }, + { + name: 'canny', + description: 'test-12', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + created: '2022-07-26T10:35:16.390Z', + object: { + author: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + board: { + created: '2022-07-25T12:11:19.895Z', + id: '62de88676bc28b44aaaf25cc', + name: 'features', + postCount: 10, + url: 'https://rudder.canny.io/admin/board/features', + }, + by: null, + category: null, + commentCount: 0, + created: '2022-07-26T08:18:52.459Z', + deletedBy: { + created: '2022-07-15T11:16:32.648Z', + email: 'test@rudderstack.com', + id: '62d14c90fff7c80d0ec08375', + isAdmin: true, + name: 'Rudder Test', + url: 'https://rudder.canny.io/admin/users/dummyUser', + userID: null, + }, + details: "This is the post's details", + eta: null, + id: '62dfa36c9950e94655320fe7', + imageURLs: [], + owner: null, + score: 1, + status: 'open', + tags: [], + title: 'Post Title', + url: 'https://rudder.canny.io/admin/board/features/p/post-title-4', + }, + objectType: 'post', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + statusCode: 400, + error: 'Missing essential fields from Canny', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns: () => { + defaultMockFns(); + }, +})); diff --git a/test/integrations/sources/cordial/data.ts b/test/integrations/sources/cordial/data.ts new file mode 100644 index 0000000000..acb02e9fbf --- /dev/null +++ b/test/integrations/sources/cordial/data.ts @@ -0,0 +1,628 @@ +import utils from '../../../../src/v0/util'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data = [ + { + name: 'cordial', + description: 'Simple Single object Input event with normal channel and action', + module: 'source', + version: 'v1', + input: { + request: { + body: [ + { + event: { + contact: { + _id: '6690fe3655e334xx028xxx', + channels: { + email: { + address: 'jondoe@example.com', + subscribeStatus: 'subscribed', + subscribedAt: '2024-07-12T09:58:14+0000', + }, + }, + createdAt: '2024-07-12T09:58:14+0000', + address: { + city: 'San Miego', + }, + first_name: 'John', + last_name: 'Doe', + lastUpdateSource: 'api', + lastModified: '2024-07-12T13:00:49+0000', + cID: '6690fe3655e334xx028xxx', + }, + event: { + _id: '669141857b8cxxx1ba0da2xx', + cID: '6690fe3655e334xx028xxx', + ts: '2024-07-12T14:45:25+00:00', + ats: '2024-07-12T14:45:25+0000', + a: 'browse', + tzo: -7, + rl: 'a', + UID: '4934ee07118197xx3f74d5xxxx7b0076', + time: '2024-07-12T14:45:25+0000', + action: 'browse', + bmID: '', + first: 0, + properties: { + category: 'Shirts', + url: 'http://example.com/shirts', + description: 'A really cool khaki shirt.', + price: 9.99, + title: 'Khaki Shirt', + test_key: 'value', + }, + }, + }, + source: {}, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { + name: 'unknown', + version: 'unknown', + }, + integration: { + name: 'Cordial', + }, + traits: { + userId: '6690fe3655e334xx028xxx', + email: 'jondoe@example.com', + _id: '6690fe3655e334xx028xxx', + channels: { + email: { + address: 'jondoe@example.com', + subscribeStatus: 'subscribed', + subscribedAt: '2024-07-12T09:58:14+0000', + }, + }, + createdAt: '2024-07-12T09:58:14+0000', + address: { + city: 'San Miego', + }, + first_name: 'John', + last_name: 'Doe', + lastUpdateSource: 'api', + lastModified: '2024-07-12T13:00:49+0000', + cID: '6690fe3655e334xx028xxx', + }, + externalId: [{ id: '6690fe3655e334xx028xxx', type: 'cordialContactId' }], + }, + integrations: { + Cordial: false, + }, + type: 'track', + event: 'browse', + originalTimestamp: '2024-07-12T14:45:25+00:00', + properties: { + event_id: '669141857b8cxxx1ba0da2xx', + category: 'Shirts', + url: 'http://example.com/shirts', + description: 'A really cool khaki shirt.', + price: 9.99, + title: 'Khaki Shirt', + test_key: 'value', + cID: '6690fe3655e334xx028xxx', + ts: '2024-07-12T14:45:25+00:00', + ats: '2024-07-12T14:45:25+0000', + a: 'browse', + tzo: -7, + rl: 'a', + UID: '4934ee07118197xx3f74d5xxxx7b0076', + time: '2024-07-12T14:45:25+0000', + action: 'browse', + bmID: '', + first: 0, + }, + userId: '6690fe3655e334xx028xxx', + timestamp: '2024-07-12T14:45:25+00:00', + sentAt: '2024-07-12T14:45:25+00:00', + }, + ], + }, + }, + ], + }, + }, + mockFns: () => { + defaultMockFns(); + }, + }, + { + name: 'cordial', + description: 'Multiple object Input event with batched payload', + module: 'source', + version: 'v1', + input: { + request: { + body: [ + { + event: [ + { + contact: { + _id: '633b2fd70a12be027e0b0xxx', + lang_locale: 'EN-US', + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'none', + }, + }, + createdAt: '2022-10-03T18:54:15+0000', + email_sha256_hash: + 'f959bdf883831ebb96612eb9xxxx1e0c9481780adf5f70xxx862155531bf61df', + first_name: 'john', + last_name: 'doe', + lastUpdateSource: 'cordial', + lastModified: '2024-07-24T07:52:46+0000', + cID: '633b2fd70a12be027e0b0xxx', + }, + event: { + _id: '66a0b2ce5344b55fxxxc5a64', + cID: '633b2fd70a12be027e0b0xxx', + ts: '2024-07-24T07:52:46+00:00', + ats: '2024-07-24T07:52:39+0000', + g: { + countryISO: 'PL', + country: 'Poland', + state: 'MZ', + city: 'Warszawa', + postalCode: '00-686', + geoLoc: { + lat: 52.22744369506836, + lon: 21.009017944335938, + }, + tz: 'Europe/Warsaw', + }, + d: { + type: 'computer', + device: 'Macintosh', + platform: 'OS X', + browser: 'Chrome', + robot: false, + }, + a: 'browse', + UID: '471af949fffe749c2ebfxxx950ea73c', + sp: { + bid: 'cf6de7f1-cce5-40xx-ac9c-7c82a2xxc09e', + }, + tzo: -7, + rl: '6', + time: '2024-07-24T07:52:39+0000', + action: 'browse', + bmID: '', + first: 0, + properties: { + url: 'https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart', + product_item_group_id: ['1094269'], + product_category: ['allproducts'], + product_name: ['wtp ab'], + product_group: ['women'], + }, + }, + }, + { + contact: { + _id: '633b2fd12312be027e0b0xxx', + lang_locale: 'EN-US', + channels: { + email: { + address: 'johndoe1@example.com', + subscribeStatus: 'none', + }, + }, + createdAt: '2022-10-03T18:54:15+0000', + email_sha256_hash: + 'f95912b883831eab11612eb9xxxx1e0c9481780ad45770xxx862155531bf61df', + first_name: 'john', + last_name: 'doe', + lastUpdateSource: 'cordial', + lastModified: '2024-07-24T07:52:46+0000', + cID: '633b2fd12312be027e0b0xxx', + }, + event: { + _id: '66aku0b2ce527b55fx1xc5a64', + cID: '633b2fd12312be027e0b0xxx', + ts: '2024-07-24T07:52:46+00:00', + ats: '2024-07-24T07:52:39+0000', + g: { + countryISO: 'PL', + country: 'Poland', + state: 'MZ', + city: 'Warszawa', + postalCode: '00-686', + geoLoc: { + lat: 52.22744369506836, + lon: 21.009017944335938, + }, + tz: 'Europe/Warsaw', + }, + d: { + type: 'computer', + device: 'Macintosh', + platform: 'OS X', + browser: 'Chrome', + robot: false, + }, + a: 'browse', + UID: '471af949fffe74sdh382ebfxxx950ea73c', + sp: { + bid: 'cf6de7f1-123ce5-20xx-ac9c-7c82a2xxc09e', + }, + tzo: -7, + rl: '6', + time: '2024-07-24T07:52:39+0000', + action: 'browse', + bmID: '', + first: 0, + properties: { + url: 'https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart', + product_item_group_id: ['1094269'], + product_category: ['allproducts'], + product_name: ['wtp ab'], + product_group: ['women'], + }, + }, + }, + ], + source: {}, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { + name: 'unknown', + version: 'unknown', + }, + integration: { + name: 'Cordial', + }, + traits: { + userId: '633b2fd70a12be027e0b0xxx', + email: 'johndoe@example.com', + _id: '633b2fd70a12be027e0b0xxx', + lang_locale: 'EN-US', + channels: { + email: { + address: 'johndoe@example.com', + subscribeStatus: 'none', + }, + }, + createdAt: '2022-10-03T18:54:15+0000', + email_sha256_hash: + 'f959bdf883831ebb96612eb9xxxx1e0c9481780adf5f70xxx862155531bf61df', + first_name: 'john', + last_name: 'doe', + lastUpdateSource: 'cordial', + lastModified: '2024-07-24T07:52:46+0000', + cID: '633b2fd70a12be027e0b0xxx', + }, + device: { + type: 'computer', + device: 'Macintosh', + platform: 'OS X', + browser: 'Chrome', + robot: false, + }, + externalId: [{ id: '633b2fd70a12be027e0b0xxx', type: 'cordialContactId' }], + }, + integrations: { + Cordial: false, + }, + type: 'track', + event: 'browse', + properties: { + event_id: '66a0b2ce5344b55fxxxc5a64', + url: 'https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart', + product_item_group_id: ['1094269'], + product_category: ['allproducts'], + product_name: ['wtp ab'], + product_group: ['women'], + cID: '633b2fd70a12be027e0b0xxx', + ts: '2024-07-24T07:52:46+00:00', + ats: '2024-07-24T07:52:39+0000', + g: { + countryISO: 'PL', + country: 'Poland', + state: 'MZ', + city: 'Warszawa', + postalCode: '00-686', + geoLoc: { + lat: 52.22744369506836, + lon: 21.009017944335938, + }, + tz: 'Europe/Warsaw', + }, + a: 'browse', + UID: '471af949fffe749c2ebfxxx950ea73c', + sp: { + bid: 'cf6de7f1-cce5-40xx-ac9c-7c82a2xxc09e', + }, + tzo: -7, + rl: '6', + time: '2024-07-24T07:52:39+0000', + action: 'browse', + bmID: '', + first: 0, + }, + userId: '633b2fd70a12be027e0b0xxx', + timestamp: '2024-07-24T07:52:46+00:00', + sentAt: '2024-07-24T07:52:46+00:00', + originalTimestamp: '2024-07-24T07:52:46+00:00', + }, + { + context: { + library: { + name: 'unknown', + version: 'unknown', + }, + integration: { + name: 'Cordial', + }, + traits: { + userId: '633b2fd12312be027e0b0xxx', + email: 'johndoe1@example.com', + _id: '633b2fd12312be027e0b0xxx', + lang_locale: 'EN-US', + channels: { + email: { + address: 'johndoe1@example.com', + subscribeStatus: 'none', + }, + }, + createdAt: '2022-10-03T18:54:15+0000', + email_sha256_hash: + 'f95912b883831eab11612eb9xxxx1e0c9481780ad45770xxx862155531bf61df', + first_name: 'john', + last_name: 'doe', + lastUpdateSource: 'cordial', + lastModified: '2024-07-24T07:52:46+0000', + cID: '633b2fd12312be027e0b0xxx', + }, + device: { + type: 'computer', + device: 'Macintosh', + platform: 'OS X', + browser: 'Chrome', + robot: false, + }, + externalId: [{ id: '633b2fd12312be027e0b0xxx', type: 'cordialContactId' }], + }, + integrations: { + Cordial: false, + }, + type: 'track', + event: 'browse', + properties: { + event_id: '66aku0b2ce527b55fx1xc5a64', + url: 'https://aaff-008.dx.commercecloud.salesforce.com/s/UGG-US/cart', + product_item_group_id: ['1094269'], + product_category: ['allproducts'], + product_name: ['wtp ab'], + product_group: ['women'], + cID: '633b2fd12312be027e0b0xxx', + ts: '2024-07-24T07:52:46+00:00', + ats: '2024-07-24T07:52:39+0000', + g: { + countryISO: 'PL', + country: 'Poland', + state: 'MZ', + city: 'Warszawa', + postalCode: '00-686', + geoLoc: { + lat: 52.22744369506836, + lon: 21.009017944335938, + }, + tz: 'Europe/Warsaw', + }, + a: 'browse', + UID: '471af949fffe74sdh382ebfxxx950ea73c', + sp: { + bid: 'cf6de7f1-123ce5-20xx-ac9c-7c82a2xxc09e', + }, + tzo: -7, + rl: '6', + time: '2024-07-24T07:52:39+0000', + action: 'browse', + bmID: '', + first: 0, + }, + userId: '633b2fd12312be027e0b0xxx', + timestamp: '2024-07-24T07:52:46+00:00', + sentAt: '2024-07-24T07:52:46+00:00', + originalTimestamp: '2024-07-24T07:52:46+00:00', + }, + ], + }, + }, + ], + }, + }, + mockFns: () => { + defaultMockFns(); + }, + }, + { + name: 'cordial', + description: 'Simple Single object Input event with no CId', + module: 'source', + version: 'v1', + input: { + request: { + body: [ + { + event: { + contact: { + _id: '6690fe3655e334xx028xx1', + channels: { + email: { + address: 'jondoe@example.com', + subscribeStatus: 'subscribed', + subscribedAt: '2024-07-12T09:58:14+0000', + }, + }, + createdAt: '2024-07-12T09:58:14+0000', + address: { + city: 'San Miego', + }, + first_name: 'John', + last_name: 'Doe', + lastUpdateSource: 'api', + lastModified: '2024-07-12T13:00:49+0000', + }, + event: { + _id: '669141857b8cxxx1ba0da2x1', + ts: '2024-07-12T14:45:25+00:00', + ats: '2024-07-12T14:45:25+0000', + d: { + type: 'computer', + device: false, + platform: false, + browser: false, + robot: true, + }, + a: 'browse', + tzo: -7, + rl: 'a', + UID: '4934ee07197xx3f74d5xxxx7b0076', + time: '2024-07-12T14:45:25+0000', + action: 'browse', + bmID: '', + first: 0, + properties: { + category: 'Shirts', + url: 'http://example.com/shirts', + description: 'A really cool khaki shirt.', + price: 9.99, + title: 'Khaki Shirt', + test_key: 'value', + }, + }, + }, + source: {}, + }, + ], + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { + name: 'unknown', + version: 'unknown', + }, + integration: { + name: 'Cordial', + }, + traits: { + userId: '6690fe3655e334xx028xx1', + email: 'jondoe@example.com', + _id: '6690fe3655e334xx028xx1', + channels: { + email: { + address: 'jondoe@example.com', + subscribeStatus: 'subscribed', + subscribedAt: '2024-07-12T09:58:14+0000', + }, + }, + createdAt: '2024-07-12T09:58:14+0000', + address: { + city: 'San Miego', + }, + first_name: 'John', + last_name: 'Doe', + lastUpdateSource: 'api', + lastModified: '2024-07-12T13:00:49+0000', + }, + device: { + type: 'computer', + device: false, + platform: false, + browser: false, + robot: true, + }, + externalId: [], + }, + integrations: { + Cordial: false, + }, + type: 'track', + event: 'browse', + originalTimestamp: '2024-07-12T14:45:25+00:00', + properties: { + event_id: '669141857b8cxxx1ba0da2x1', + category: 'Shirts', + url: 'http://example.com/shirts', + description: 'A really cool khaki shirt.', + price: 9.99, + title: 'Khaki Shirt', + test_key: 'value', + ts: '2024-07-12T14:45:25+00:00', + ats: '2024-07-12T14:45:25+0000', + a: 'browse', + tzo: -7, + rl: 'a', + UID: '4934ee07197xx3f74d5xxxx7b0076', + time: '2024-07-12T14:45:25+0000', + action: 'browse', + bmID: '', + first: 0, + }, + userId: '6690fe3655e334xx028xx1', + timestamp: '2024-07-12T14:45:25+00:00', + sentAt: '2024-07-12T14:45:25+00:00', + }, + ], + }, + }, + ], + }, + }, + mockFns: () => { + defaultMockFns(); + }, + }, +]; diff --git a/test/integrations/sources/customerio/data.ts b/test/integrations/sources/customerio/data.ts new file mode 100644 index 0000000000..b831b1d0b0 --- /dev/null +++ b/test/integrations/sources/customerio/data.ts @@ -0,0 +1,1492 @@ +import utils from '../../../../src/v0/util'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data = [ + { + name: 'customerio', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + customer_id: '0200102', + identifiers: { id: '0200102' }, + email_address: 'test@example.com', + }, + event_id: '01E4C4CT6YDC7Y5M7FE1GWWPQJ', + object_type: 'customer', + metric: 'subscribed', + timestamp: 'abc', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Customer Subscribed', + properties: { eventId: '01E4C4CT6YDC7Y5M7FE1GWWPQJ' }, + userId: '0200102', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + customer_id: '0200102', + identifiers: { id: '0200102' }, + email_address: 'test@example.com', + }, + event_id: '01E4C4CT6YDC7Y5M7FE1GWWPQJ', + object_type: 'customer', + metric: 'subscribed', + timestamp: '1585250199', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Customer Subscribed', + properties: { eventId: '01E4C4CT6YDC7Y5M7FE1GWWPQJ' }, + userId: '0200102', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + customer_id: '0200102', + identifiers: { id: '0200102' }, + email_address: 'test@example.com', + }, + event_id: '01E4C4CT6YDC7Y5M7FE1GWWPQJ', + object_type: 'customer', + metric: 'subscribed', + timestamp: 1585250199, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Customer Subscribed', + properties: { eventId: '01E4C4CT6YDC7Y5M7FE1GWWPQJ' }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:16:39.000Z', + sentAt: '2020-03-26T19:16:39.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + customer_id: '0200102', + identifiers: { id: '0200102' }, + email_address: 'test@example.com', + }, + event_id: '01E4C4C6P79C12J5A6KPE6XNFD', + object_type: 'customer', + metric: 'unsubscribed', + timestamp: 1585250179, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Customer Unsubscribed', + properties: { eventId: '01E4C4C6P79C12J5A6KPE6XNFD' }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:16:19.000Z', + sentAt: '2020-03-26T19:16:19.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 36, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgABcRhIBqSp7kiPekGBIeVh', + }, + event_id: '01E4C4G1S0AMNG0XVF2M7RPH5S', + object_type: 'email', + metric: 'drafted', + timestamp: 1585250305, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Email Drafted', + properties: { + eventId: '01E4C4G1S0AMNG0XVF2M7RPH5S', + deliveryId: 'RPILAgABcRhIBqSp7kiPekGBIeVh', + actionId: 36, + broadcastId: 9, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:18:25.000Z', + sentAt: '2020-03-26T19:18:25.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + content_id: 1146, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=', + failure_message: '550 5.5.0 Requested action not taken: mailbox unavailable', + newsletter_id: 736, + recipient: 'test@example.com', + subject: 'Thanks for joining!', + }, + event_id: '12ASDG7S9P6MAZPTJ78DAND9GDC', + object_type: 'email', + metric: 'bounced', + timestamp: 1234567890, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Email Bounced', + properties: { + eventId: '12ASDG7S9P6MAZPTJ78DAND9GDC', + deliveryId: 'RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=', + contentId: 1146, + emailSubject: 'Thanks for joining!', + reason: '550 5.5.0 Requested action not taken: mailbox unavailable', + newsletterId: 736, + }, + userId: '0200102', + originalTimestamp: '2009-02-13T23:31:30.000Z', + sentAt: '2009-02-13T23:31:30.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-6', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 36, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgABcRhIBqSp7kiPekGBIeVh', + href: 'http://google.com', + link_id: 1, + recipient: 'test@example.com', + subject: 'hello', + }, + event_id: '01E4C8BES5XT87ZWRJFTB35YJ3', + object_type: 'email', + metric: 'clicked', + timestamp: 1585254348, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Email Link Clicked', + properties: { + eventId: '01E4C8BES5XT87ZWRJFTB35YJ3', + deliveryId: 'RPILAgABcRhIBqSp7kiPekGBIeVh', + actionId: 36, + broadcastId: 9, + emailSubject: 'hello', + link: { url: 'http://google.com', id: 1 }, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T20:25:48.000Z', + sentAt: '2020-03-26T20:25:48.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-7', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 42, + campaign_id: 23, + content: 'Welcome to the club, we are with you.', + customer_id: 'user-123', + delivery_id: 'RAECAAFwnUSneIa0ZXkmq8EdkAM==', + headers: { 'Custom-Header': ['custom-value'] }, + identifiers: { id: 'user-123' }, + recipient: 'test@example.com', + subject: 'Thanks for signing up', + }, + event_id: '01E2EMRMM6TZ12TF9WGZN0WJQT', + metric: 'sent', + object_type: 'email', + timestamp: 1644227937, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Email Sent', + properties: { + eventId: '01E2EMRMM6TZ12TF9WGZN0WJQT', + deliveryId: 'RAECAAFwnUSneIa0ZXkmq8EdkAM==', + actionId: 42, + content: 'Welcome to the club, we are with you.', + emailSubject: 'Thanks for signing up', + campaignId: 23, + }, + userId: 'user-123', + originalTimestamp: '2022-02-07T09:58:57.000Z', + sentAt: '2022-02-07T09:58:57.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-8', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + customer_id: 'user-123', + delivery_id: 'REAC4wUAAYYJgQgkyRqwwEPeOA6Nfv==', + identifiers: { cio_id: '7ef807109981', id: 'user-123' }, + recipient: 'test@example.com', + subject: 'Thanks for signing up', + transactional_message_id: 2, + }, + event_id: '01ER4R5WB62QWCNREKFB4DYXGR', + metric: 'delivered', + object_type: 'email', + timestamp: 1675196819, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { cioId: '7ef807109981', email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Email Delivered', + properties: { + eventId: '01ER4R5WB62QWCNREKFB4DYXGR', + deliveryId: 'REAC4wUAAYYJgQgkyRqwwEPeOA6Nfv==', + emailSubject: 'Thanks for signing up', + transactionalMessageId: 2, + }, + userId: 'user-123', + originalTimestamp: '2023-01-31T20:26:59.000Z', + sentAt: '2023-01-31T20:26:59.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-9', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 38, + campaign_id: 6, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RAEABQFxN56fWzydfV4_EGvfobI=', + failure_message: 'NoDevicesSynced', + }, + event_id: '01E4VSX8SZ0T9AQMH4Q16NRB89', + object_type: 'push', + metric: 'attempted', + timestamp: 1585776075, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Push Attempted', + properties: { + eventId: '01E4VSX8SZ0T9AQMH4Q16NRB89', + deliveryId: 'RAEABQFxN56fWzydfV4_EGvfobI=', + actionId: 38, + reason: 'NoDevicesSynced', + campaignId: 6, + }, + userId: '0200102', + originalTimestamp: '2020-04-01T21:21:15.000Z', + sentAt: '2020-04-01T21:21:15.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-10', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 37, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgUBcRhIBqSfeiIwdIYJKxTY', + recipients: [ + { + device_id: + 'eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof', + device_platform: 'android', + }, + ], + }, + event_id: '01E4C4HDQ7P1X9KTKF0ZX7PWHE', + object_type: 'push', + metric: 'sent', + timestamp: 1585250350, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Push Sent', + properties: { + eventId: '01E4C4HDQ7P1X9KTKF0ZX7PWHE', + deliveryId: 'RPILAgUBcRhIBqSfeiIwdIYJKxTY', + actionId: 37, + broadcastId: 9, + recipients: [ + { + device_id: + 'eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof', + device_platform: 'android', + }, + ], + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:19:10.000Z', + sentAt: '2020-03-26T19:19:10.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-11', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 37, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgUBcRhIBqSfeiIwdIYJKxTY', + href: 'ciosas://product/2', + link_id: 1, + recipients: [ + { + device_id: + 'eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof', + }, + ], + }, + event_id: '01E4V2SBHYK4TNTG8WKMP39G9R', + object_type: 'push', + metric: 'clicked', + timestamp: 1585751829, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Push Link Clicked', + properties: { + eventId: '01E4V2SBHYK4TNTG8WKMP39G9R', + deliveryId: 'RPILAgUBcRhIBqSfeiIwdIYJKxTY', + actionId: 37, + broadcastId: 9, + link: { url: 'ciosas://product/2', id: 1 }, + recipients: [ + { + device_id: + 'eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof', + }, + ], + }, + userId: '0200102', + originalTimestamp: '2020-04-01T14:37:09.000Z', + sentAt: '2020-04-01T14:37:09.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-12', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 41, + campaign_id: 7, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'ROk1AAIBcR4iT6mueuxiDtzO8HXv', + failure_message: + "Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309.", + }, + event_id: '01E4F3DCS83P8HT7R3E6DWQN1X', + object_type: 'sms', + metric: 'attempted', + timestamp: 1234567890, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'SMS Attempted', + properties: { + eventId: '01E4F3DCS83P8HT7R3E6DWQN1X', + deliveryId: 'ROk1AAIBcR4iT6mueuxiDtzO8HXv', + actionId: 41, + reason: + "Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309.", + campaignId: 7, + }, + userId: '0200102', + originalTimestamp: '2009-02-13T23:31:30.000Z', + sentAt: '2009-02-13T23:31:30.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-13', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 38, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgIBcRh6qzHz-8gKvscP2UZa', + href: 'https://app.com/verify', + link_id: 1, + recipient: '+18008675309', + }, + event_id: '01E4XXPN42JDF4B1ATQKTZ8WHV', + object_type: 'sms', + metric: 'clicked', + timestamp: 1585847161, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: '+18008675309' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'SMS Link Clicked', + properties: { + eventId: '01E4XXPN42JDF4B1ATQKTZ8WHV', + deliveryId: 'RPILAgIBcRh6qzHz-8gKvscP2UZa', + actionId: 38, + broadcastId: 9, + link: { url: 'https://app.com/verify', id: 1 }, + }, + userId: '0200102', + originalTimestamp: '2020-04-02T17:06:01.000Z', + sentAt: '2020-04-02T17:06:01.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-14', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 39, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgQBcRhNAufb0s30bmz5HD7Y', + recipient: '#signups', + }, + event_id: '01E4C4TQKD6KJ274870J5DE2HB', + object_type: 'slack', + metric: 'sent', + timestamp: 1585250655, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: '#signups' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Slack Message Sent', + properties: { + eventId: '01E4C4TQKD6KJ274870J5DE2HB', + deliveryId: 'RPILAgQBcRhNAufb0s30bmz5HD7Y', + actionId: 39, + broadcastId: 9, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:24:15.000Z', + sentAt: '2020-03-26T19:24:15.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-15', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 39, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgQBcRhocpCJE3mFfwvRzNe6', + href: 'http://bing.com', + link_id: 1, + recipient: '#signups', + }, + event_id: '01E4C6HJTBNDX18XC4B88M3Y2G', + object_type: 'slack', + metric: 'clicked', + timestamp: 1585252451, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: '#signups' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Slack Message Link Clicked', + properties: { + eventId: '01E4C6HJTBNDX18XC4B88M3Y2G', + deliveryId: 'RPILAgQBcRhocpCJE3mFfwvRzNe6', + actionId: 39, + broadcastId: 9, + link: { url: 'http://bing.com', id: 1 }, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:54:11.000Z', + sentAt: '2020-03-26T19:54:11.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-16', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 39, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgQBcRhIBqRiZAc0fyQiLvkC', + failure_message: 'value passed for channel was invalid', + }, + event_id: '01E4C4HDQ77BCN0X23Z3WBE764', + object_type: 'slack', + metric: 'failed', + timestamp: 1585250350, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Slack Message Failed', + properties: { + eventId: '01E4C4HDQ77BCN0X23Z3WBE764', + deliveryId: 'RPILAgQBcRhIBqRiZAc0fyQiLvkC', + actionId: 39, + broadcastId: 9, + reason: 'value passed for channel was invalid', + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:19:10.000Z', + sentAt: '2020-03-26T19:19:10.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-17', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 40, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgEBcRhIBqSrYcXDr2ks6Pj9', + }, + event_id: '01E4C4G1S04QCV1NASF4NWMQNR', + object_type: 'webhook', + metric: 'drafted', + timestamp: 1585250305, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Webhook Message Drafted', + properties: { + eventId: '01E4C4G1S04QCV1NASF4NWMQNR', + deliveryId: 'RPILAgEBcRhIBqSrYcXDr2ks6Pj9', + actionId: 40, + broadcastId: 9, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:18:25.000Z', + sentAt: '2020-03-26T19:18:25.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-18', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 38, + broadcast_id: 6, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RAECAQFxNeUBx6LqgjqrN1j-BJc=', + failure_message: "Variable 'customer.test' is missing", + }, + event_id: '01E4TYA2KA9T0XGHCRJ784B774', + object_type: 'webhook', + metric: 'attempted', + timestamp: 1585747134, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Webhook Message Attempted', + properties: { + eventId: '01E4TYA2KA9T0XGHCRJ784B774', + deliveryId: 'RAECAQFxNeUBx6LqgjqrN1j-BJc=', + actionId: 38, + broadcastId: 6, + reason: "Variable 'customer.test' is missing", + }, + userId: '0200102', + originalTimestamp: '2020-04-01T13:18:54.000Z', + sentAt: '2020-04-01T13:18:54.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-19', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 40, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgEBcRhNAufr2aU82jtDZEh6', + recipient: 'https://test.example.com/process', + }, + event_id: '01E4C6EP0HCKRHKFARMZ5XEH7A', + object_type: 'webhook', + metric: 'sent', + timestamp: 1585252357, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'https://test.example.com/process' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Webhook Message Sent', + properties: { + eventId: '01E4C6EP0HCKRHKFARMZ5XEH7A', + deliveryId: 'RPILAgEBcRhNAufr2aU82jtDZEh6', + actionId: 40, + broadcastId: 9, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:52:37.000Z', + sentAt: '2020-03-26T19:52:37.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-20', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 40, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgEBcRhNAufr2aU82jtDZEh6', + href: 'http://bing.com', + link_id: 1, + recipient: 'https://test.example.com/process', + }, + event_id: '01E4C6F5N1Y54TVGJTN64Y1ZS9', + object_type: 'webhook', + metric: 'clicked', + timestamp: 1585252373, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'https://test.example.com/process' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Webhook Message Link Clicked', + properties: { + eventId: '01E4C6F5N1Y54TVGJTN64Y1ZS9', + deliveryId: 'RPILAgEBcRhNAufr2aU82jtDZEh6', + actionId: 40, + broadcastId: 9, + link: { url: 'http://bing.com', id: 1 }, + }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:52:53.000Z', + sentAt: '2020-03-26T19:52:53.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-21', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 38, + broadcast_id: 6, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RAECAQFxNeK3bC4SYqhQqFGBQrQ=', + failure_message: 'HTTP 404 Not Found []', + }, + event_id: '01E4TY5FVB0ZQ4KVDKRME0XSYZ', + object_type: 'webhook', + metric: 'failed', + timestamp: 1585746984, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Webhook Message Failed', + properties: { + eventId: '01E4TY5FVB0ZQ4KVDKRME0XSYZ', + deliveryId: 'RAECAQFxNeK3bC4SYqhQqFGBQrQ=', + actionId: 38, + broadcastId: 6, + reason: 'HTTP 404 Not Found []', + }, + userId: '0200102', + originalTimestamp: '2020-04-01T13:16:24.000Z', + sentAt: '2020-04-01T13:16:24.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-22', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + action_id: 37, + broadcast_id: 9, + customer_id: '0200102', + identifiers: { id: '0200102' }, + delivery_id: 'RPILAgUBcRhIBqSfeiIwdIYJKxTY', + href: 'ciosas://product/2', + link_id: 1, + recipients: [ + { + device_id: + 'eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof', + }, + ], + }, + event_id: '01E4V2SBHYK4TNTG8WKMP39G9S', + object_type: 'push', + metric: 'delivered', + timestamp: 1585751830, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Push Delivered', + properties: { + eventId: '01E4V2SBHYK4TNTG8WKMP39G9S', + deliveryId: 'RPILAgUBcRhIBqSfeiIwdIYJKxTY', + actionId: 37, + broadcastId: 9, + link: { url: 'ciosas://product/2', id: 1 }, + recipients: [ + { + device_id: + 'eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof', + }, + ], + }, + userId: '0200102', + originalTimestamp: '2020-04-01T14:37:10.000Z', + sentAt: '2020-04-01T14:37:10.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'customerio', + description: 'test-23: email subscribed', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + data: { + customer_id: '0200102', + identifiers: { id: '0200102' }, + email_address: 'test@example.com', + }, + event_id: '01E4C4C6P79C12J5A6KPE6XNFD', + object_type: 'email', + metric: 'subscribed', + timestamp: 1585250179, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Customer.io' }, + traits: { email: 'test@example.com' }, + }, + integrations: { 'Customer.io': false }, + type: 'track', + event: 'Email Subscribed', + properties: { eventId: '01E4C4C6P79C12J5A6KPE6XNFD' }, + userId: '0200102', + originalTimestamp: '2020-03-26T19:16:19.000Z', + sentAt: '2020-03-26T19:16:19.000Z', + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns: () => { + defaultMockFns(); + }, +})); diff --git a/test/integrations/sources/formsort/data.ts b/test/integrations/sources/formsort/data.ts new file mode 100644 index 0000000000..ef275f6c1c --- /dev/null +++ b/test/integrations/sources/formsort/data.ts @@ -0,0 +1,126 @@ +export const data = [ + { + name: 'formsort', + description: 'when we receive finalized as false', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + answers: { + yes: true, + enter_email: 'test@user.com', + enter_name: '2022-11-17', + yes_or_no: false, + }, + responder_uuid: '66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7', + flow_label: 'new-flow-2022-11-25', + variant_label: 'main', + variant_uuid: '0828efa7-7215-4e7d-a7ab-6c1079010cea', + finalized: false, + created_at: '2022-11-25T14:41:22+00:00', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Formsort' }, + page: { title: 'new-flow-2022-11-25' }, + variantLabel: 'main', + variantUuid: '0828efa7-7215-4e7d-a7ab-6c1079010cea', + }, + integrations: { Formsort: false }, + type: 'track', + userId: '66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7', + originalTimestamp: '2022-11-25T14:41:22+00:00', + properties: { + yes: true, + enter_email: 'test@user.com', + enter_name: '2022-11-17', + yes_or_no: false, + }, + event: 'FlowLoaded', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'formsort', + description: 'when we receive finalized as true', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + answers: { + yes: true, + enter_email: 'test@user.com', + enter_name: '2022-11-17', + yes_or_no: false, + }, + responder_uuid: '66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7', + flow_label: 'new-flow-2022-11-25', + variant_label: 'main', + variant_uuid: '0828efa7-7215-4e7d-a7ab-6c1079010cea', + finalized: true, + created_at: '2022-11-25T14:41:22+00:00', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Formsort' }, + page: { title: 'new-flow-2022-11-25' }, + variantLabel: 'main', + variantUuid: '0828efa7-7215-4e7d-a7ab-6c1079010cea', + }, + integrations: { Formsort: false }, + type: 'track', + userId: '66a8e5bb-67e1-47ec-b55f-a26fd4be2dc7', + originalTimestamp: '2022-11-25T14:41:22+00:00', + properties: { + yes: true, + enter_email: 'test@user.com', + enter_name: '2022-11-17', + yes_or_no: false, + }, + event: 'FlowFinalized', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/gainsightpx/data.ts b/test/integrations/sources/gainsightpx/data.ts new file mode 100644 index 0000000000..b038001580 --- /dev/null +++ b/test/integrations/sources/gainsightpx/data.ts @@ -0,0 +1,1625 @@ +export const data = [ + { + name: 'gainsightpx', + description: 'Identify Call', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'SIGN_UP', + eventId: '1283c08b-f290-4bc4-9deb-75c7867d69ee', + propertyKey: 'AP-EOXPSEZGC5LA-2-1', + date: 1665582808376, + sessionId: 'AP-EOXPSEZGC5LA-2-1665582441084-16821368', + globalContext: {}, + userType: 'USER', + }, + configId: '32f07727-d231-4c9d-881e-fb50b80bad63', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'identify', + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + score: 0, + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + id: 'New!', + country: 'India', + account: { + id: 'IBM', + name: 'International Business Machine', + numberOfEmployees: 0, + numberOfUsers: 0, + }, + }, + userId: 'New!', + createdAt: '2022-10-12T13:53:11.753Z', + originalTimestamp: '2022-10-12T13:53:11.753Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Custom Track Call ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'CUSTOM', + eventId: 'df58cbd6-2736-4f8a-ad26-6049eac2e150', + propertyKey: 'AP-EOXPSEZGC5LA-2-1', + date: 1665656881448, + sessionId: 'AP-EOXPSEZGC5LA-2-1665656622955-48127533', + globalContext: {}, + userType: 'USER', + eventName: 'Product Clicked', + attributes: { + 'Audience Size': 5000, + name: 'TESTing TRACK CALL FIRST', + 'Launched date': 1520532660000, + Launched: true, + }, + url: 'http://127.0.0.1:5501/GPXTEST2.html', + referrer: '', + remoteHost: '122.161.66.140', + }, + configId: '32f07727-d231-4c9d-881e-fb50b80bad63', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + ip: '122.161.66.140', + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-EOXPSEZGC5LA-2-1', + 'Audience Size': 5000, + name: 'TESTing TRACK CALL FIRST', + 'Launched date': 1520532660000, + Launched: true, + ip: '122.161.66.140', + url: 'http://127.0.0.1:5501/GPXTEST2.html', + }, + userId: 'New!', + category: 'CUSTOM', + event: 'Product Clicked', + sentAt: '2022-10-13T10:28:01.448Z', + originalTimestamp: '2022-10-13T10:28:01.448Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Feedback Track Call ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'FEEDBACK', + eventId: 'd007bd76-decb-4a77-8456-d84fb15c6a83', + propertyKey: 'AP-E9VUBBLZ6BIS-2-1', + date: 1665415753621, + sessionId: 'AP-E9VUBBLZ6BIS-2-1665415678379-45445457', + globalContext: null, + userType: 'USER', + subject: 'feedback title', + category: 'Labels test', + description: 'feedback body', + labels: ['492120f5-3573-11ec-bef0-42010a800545'], + remoteHost: '122.161.66.140', + source: 'Knowledge Center Bot', + }, + configId: '32f07727-d231-4c9d-881e-fb50b80bad63', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + ip: '122.161.66.140', + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-E9VUBBLZ6BIS-2-1', + feedback: { + labels: ['492120f5-3573-11ec-bef0-42010a800545'], + description: 'feedback body', + subject: 'feedback title', + source: 'Knowledge Center Bot', + }, + ip: '122.161.66.140', + }, + userId: 'New!', + category: 'FEEDBACK', + event: 'Labels test', + sentAt: '2022-10-10T15:29:13.621Z', + originalTimestamp: '2022-10-10T15:29:13.621Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Feature Match Track Call ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'FEATURE_MATCH', + eventId: 'ae1e5538-1736-4088-86d1-e90a10ffe901-05951b40-944f-4052-9a4a-51c74683f658', + propertyKey: 'AP-8MF5LPSWUBFW-2-1', + date: 1665582808376, + sessionId: 'AP-8MF5LPSWUBFW-2-1601303023809-98881162', + globalContext: { role: 'Admin' }, + userType: 'USER', + featureId: '05951b40-944f-4052-9a4a-51c74683f658', + featureName: 'Charts', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-8MF5LPSWUBFW-2-1', + globalContext: { role: 'Admin' }, + featureId: '05951b40-944f-4052-9a4a-51c74683f658', + }, + userId: 'New!', + category: 'FEATURE_MATCH', + event: 'Charts', + sentAt: '2022-10-12T13:53:28.376Z', + originalTimestamp: '2022-10-12T13:53:28.376Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Segment Match Track Call and no userId and yes anonymousId as event.sessionId', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'SEGMENT', + eventId: 'ddb9ca94-beb1-449c-bdcd-b53190f8e784', + propertyKey: 'AP-8MF5LPSWUBFW-2-1', + date: 1665582808376, + sessionId: 'AP-8MF5LPSWUBFW-2-1601303023809-98881162', + globalContext: { role: 'Admin' }, + userType: 'USER', + segmentId: 'e3ab2e48-24f9-4602-ab92-b9f1f4343845', + segmentName: 'Linux User', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: 'AP-8MF5LPSWUBFW-2-1601303023809-98881162', + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-8MF5LPSWUBFW-2-1', + globalContext: { role: 'Admin' }, + segmentId: 'e3ab2e48-24f9-4602-ab92-b9f1f4343845', + }, + category: 'SEGMENT', + event: 'Linux User', + sentAt: '2022-10-12T13:53:28.376Z', + originalTimestamp: '2022-10-12T13:53:28.376Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'No Match Track Call ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + eventType: 'Unavailable', + eventId: 'ddb9ca94-beb1-449c-bdcd-b53190f8e784', + propertyKey: 'AP-8MF5LPSWUBFW-2-1', + date: 1601303075964, + sessionId: 'AP-8MF5LPSWUBFW-2-1601303023809-98881162', + globalContext: { role: 'Admin' }, + userType: 'USER', + segmentId: 'e3ab2e48-24f9-4602-ab92-b9f1f4343845', + segmentName: 'Linux User', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Event type Unavailable not supported', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Survey Track Call -> Multi Question Survey ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'SURVEY', + eventId: 'c9883e3b-05d4-4f96-8b9c-e2ce10430493', + propertyKey: 'AP-N6SV00EVMR1E-2-1', + date: 1601303075964, + sessionId: 'AP-N6SV00EVMR1E-2-1605265939566-23853426', + globalContext: { role: 'Admin' }, + userType: 'EMPTY_USER_TYPE', + contentType: 'IN_APP_MULTIPLE_QUESTION_SURVEY', + engagementId: 'e5362226-75da-4ef6-999a-823727e3d7a7', + engagementName: 'Quarterly Survey', + surveyType: 'Multi Question', + interaction: 'SINGLE_STEP_SURVEY_RESPONDED', + score: 0, + activation: 'Auto', + executionId: '1ad2d383-d1fa-425d-84f0-2a531e17a5d9', + executionDate: 1605265939965, + questionType: 'Multi choice', + questionId: 'de9e6bf1-351c-46ec-907d-c985bd420c2b', + questionHtml: + '
Favorite travel destinations
', + questionText: 'Favorite travel destinations', + answers: [ + { + answerId: '563e2103-2906-4088-869f-bcccd185f288', + answerHtml: '
Europe
', + answerText: 'Europe', + }, + ], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-N6SV00EVMR1E-2-1', + globalContext: { role: 'Admin' }, + engagementId: 'e5362226-75da-4ef6-999a-823727e3d7a7', + contentType: 'IN_APP_MULTIPLE_QUESTION_SURVEY', + surveyType: 'Multi Question', + interaction: 'SINGLE_STEP_SURVEY_RESPONDED', + survey: { + activation: 'Auto', + questionType: 'Multi choice', + score: 0, + questionId: 'de9e6bf1-351c-46ec-907d-c985bd420c2b', + questionHtml: + '
Favorite travel destinations
', + questionText: 'Favorite travel destinations', + answers: [ + { + answerId: '563e2103-2906-4088-869f-bcccd185f288', + answerHtml: '
Europe
', + answerText: 'Europe', + }, + ], + }, + }, + userId: 'New!', + category: 'SURVEY', + event: 'Quarterly Survey', + sentAt: '2020-09-28T14:24:35.964Z', + originalTimestamp: '2020-09-28T14:24:35.964Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Survey Track Call -> NPS ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'SURVEY', + eventId: 'c9883e3b-05d4-4f96-8b9c-e2ce10430493', + propertyKey: 'AP-N6SV00EVMR1E-2-1', + date: 1601303075964, + sessionId: 'AP-N6SV00EVMR1E-2-1605265939566-23853426', + globalContext: { role: 'Admin' }, + userType: 'EMPTY_USER_TYPE', + contentType: 'IN_APP_MULTIPLE_QUESTION_SURVEY', + engagementId: 'e5362226-75da-4ef6-999a-823727e3d7a7', + engagementName: 'Quarterly Survey', + surveyType: 'Multi Question', + interaction: 'SINGLE_STEP_SURVEY_RESPONDED', + score: 0, + scoreType: null, + stepNumber: null, + userInput: 'I like new features', + activation: 'Auto', + executionId: '1ad2d383-d1fa-425d-84f0-2a531e17a5d9', + executionDate: 1605265939965, + questionType: 'Open text question', + questionHtml: + '
\n
\n How was your experience?\n
\n
\n', + questionText: 'How was your experience?', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-N6SV00EVMR1E-2-1', + globalContext: { role: 'Admin' }, + engagementId: 'e5362226-75da-4ef6-999a-823727e3d7a7', + contentType: 'IN_APP_MULTIPLE_QUESTION_SURVEY', + surveyType: 'Multi Question', + interaction: 'SINGLE_STEP_SURVEY_RESPONDED', + survey: { + activation: 'Auto', + userInput: 'I like new features', + questionType: 'Open text question', + score: 0, + questionHtml: + '
\n
\n How was your experience?\n
\n
\n', + questionText: 'How was your experience?', + }, + }, + userId: 'New!', + category: 'SURVEY', + event: 'Quarterly Survey', + sentAt: '2020-09-28T14:24:35.964Z', + originalTimestamp: '2020-09-28T14:24:35.964Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'Engagement Track Call ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'ENGAGEMENT', + eventId: '6494e73a-976b-4ee5-b8a8-de9effff7e80', + propertyKey: 'AP-N6SV00EVMR1E-2-1', + date: 1605262539389, + sessionId: 'AP-N6SV00EVMR1E-2-1605262502068-24197555', + globalContext: { role: 'Admin' }, + userType: 'EMPTY_USER_TYPE', + contentType: 'IN_APP_DIALOG', + engagementId: '83c30d4e-88c3-4054-a0fa-33451a6ea7fc', + engagementType: 'Dialog', + engagementName: 'Release Announcement', + interaction: 'VIEWED', + stepNumber: 1, + activation: 'Auto', + executionId: 'b633945f-d4a5-404a-ae39-5ced5b542240', + executionDate: 1605262539389, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-N6SV00EVMR1E-2-1', + engagementId: '83c30d4e-88c3-4054-a0fa-33451a6ea7fc', + contentType: 'IN_APP_DIALOG', + engagementType: 'Dialog', + interaction: 'VIEWED', + globalContext: { role: 'Admin' }, + engagement: { stepNumber: 1, activation: 'Auto' }, + }, + userId: 'New!', + category: 'ENGAGEMENT', + event: 'Release Announcement', + sentAt: '2020-11-13T10:15:39.389Z', + originalTimestamp: '2020-11-13T10:15:39.389Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'gainsightpx', + description: 'SegmentIO S2S Track Call ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + user: { + aptrinsicId: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + identifyId: 'New!', + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + lastSeenDate: 1665582808669, + signUpDate: 1665582791753, + firstVisitDate: 1665582791753, + title: 'Mr.', + phone: '', + score: 0, + role: '', + subscriptionId: '', + accountId: 'IBM', + numberOfVisits: 1, + location: { + countryName: 'India', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665582808376, + lastModifiedDate: 1665582808717, + customAttributes: null, + globalUnsubscribe: false, + sfdcContactId: '', + lastVisitedUserAgentData: null, + id: 'New!', + lastInferredLocation: null, + }, + account: { + id: 'IBM', + name: 'International Business Machine', + trackedSubscriptionId: '', + sfdcId: '', + lastSeenDate: 1665582808669, + dunsNumber: '', + industry: '', + numberOfEmployees: 0, + sicCode: '', + website: '', + naicsCode: '', + plan: '', + location: { + countryName: '', + countryCode: '', + stateName: '', + stateCode: '', + city: '', + street: '', + postalCode: '', + continent: '', + regionName: '', + timeZone: '', + coordinates: { latitude: 0, longitude: 0 }, + }, + numberOfUsers: 0, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + createDate: 1665578567565, + lastModifiedDate: 1665582808669, + customAttributes: null, + parentGroupId: '', + }, + event: { + eventType: 'SEGMENT_IO', + eventId: 'ajs-next-69810a17571dc115ccead5281cc3fb7d', + propertyKey: 'AP-EOXPSEZGC5LA-2-1', + date: 1666687235178, + sessionId: '31a524fa-1490-48db-9600-adfb1fa95333', + globalContext: {}, + userType: 'USER', + segmentIOEvent: { + pxPropertyKey: 'AP-EOXPSEZGC5LA-2', + type: 'group', + userId: '1001', + anonymousId: 'a4303a13-eb10-46d8-8935-d787daf1cfbd', + context: { + ip: '122.161.67.121', + library: { name: 'analytics.js', version: 'next-1.45.0' }, + locale: 'en-GB', + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', + page: { + path: '/abc.html', + title: 'Engage Testing', + url: 'http://127.0.0.1:5501/abc.html', + }, + }, + messageId: 'ajs-next-69810a17571dc115ccead5281cc3fb7d', + receivedAt: '2022-10-25T08:40:35.184Z', + sentAt: '2022-10-25T08:40:34.809Z', + timestamp: '2022-10-25T08:40:35.178Z', + traits: { name: 'International Business Machine' }, + version: 2, + channel: 'client', + groupId: 'IBM', + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'GAINSIGHTPX' }, + traits: { + type: 'USER', + gender: 'EMPTY_GENDER', + email: 'userEmail@address.com', + firstName: 'test', + lastName: 'rudderlabs', + title: 'Mr.', + globalUnsubscribe: false, + accountId: 'IBM', + numberOfVisits: 1, + propertyKeys: ['AP-EOXPSEZGC5LA-2-1'], + score: 0, + id: 'New!', + country: 'India', + account: { + numberOfEmployees: 0, + numberOfUsers: 0, + id: 'IBM', + name: 'International Business Machine', + }, + }, + externalId: [ + { + type: 'gainsightpxAptrinsicId', + id: 'cab9c469-8602-4933-acdb-68338fbb9ab1', + }, + ], + }, + integrations: { GAINSIGHTPX: false }, + type: 'track', + properties: { + propertyKey: 'AP-EOXPSEZGC5LA-2-1', + pxPropertyKey: 'AP-EOXPSEZGC5LA-2', + type: 'group', + userId: '1001', + anonymousId: 'a4303a13-eb10-46d8-8935-d787daf1cfbd', + context: { + ip: '122.161.67.121', + library: { name: 'analytics.js', version: 'next-1.45.0' }, + locale: 'en-GB', + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', + page: { + path: '/abc.html', + title: 'Engage Testing', + url: 'http://127.0.0.1:5501/abc.html', + }, + }, + messageId: 'ajs-next-69810a17571dc115ccead5281cc3fb7d', + receivedAt: '2022-10-25T08:40:35.184Z', + sentAt: '2022-10-25T08:40:34.809Z', + timestamp: '2022-10-25T08:40:35.178Z', + traits: { name: 'International Business Machine' }, + version: 2, + channel: 'client', + groupId: 'IBM', + }, + userId: 'New!', + category: 'SEGMENT_IO', + event: 'SegmentIO Cloud Server', + sentAt: '2022-10-25T08:40:35.178Z', + originalTimestamp: '2022-10-25T08:40:35.178Z', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/iterable/data.ts b/test/integrations/sources/iterable/data.ts new file mode 100644 index 0000000000..8912c83434 --- /dev/null +++ b/test/integrations/sources/iterable/data.ts @@ -0,0 +1,2222 @@ +export const data = [ + { + name: 'iterable', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'test@rudderstack.com', + eventName: 'emailSubscribe', + dataFields: { + profileUpdatedAt: '2022-04-19 03:33:50 +00:00', + publicIdString: 'ad474bf7-e785-480f-b9d0-861b85ab5bf5', + signupSource: 'WebForm', + email: 'test@rudderstack.com', + createdAt: '2022-04-19 03:33:50 +00:00', + messageTypeIds: [], + emailListIds: [1589748], + channelIds: [], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'test@rudderstack.com' }, + }, + event: 'emailSubscribe', + integrations: { Iterable: false }, + properties: { + channelIds: [], + createdAt: '2022-04-19 03:33:50 +00:00', + emailListIds: [1589748], + messageTypeIds: [], + profileUpdatedAt: '2022-04-19 03:33:50 +00:00', + publicIdString: 'ad474bf7-e785-480f-b9d0-861b85ab5bf5', + signupSource: 'WebForm', + }, + receivedAt: '2022-04-19T03:33:50.000Z', + timestamp: '2022-04-19T03:33:50.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventName: 'emailSubscribe', + dataFields: { + profileUpdatedAt: '2022-04-19 03:33:50 +00:00', + publicIdString: 'ad474bf7-e785-480f-b9d0-861b85ab5bf5', + signupSource: 'WebForm', + email: 'test@abcd.com', + createdAt: '2022-04-19 03:33:50 +00:00', + messageTypeIds: [], + emailListIds: [1589748], + channelIds: [], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Unknwon event type from Iterable', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'test@ruddstack.com', + eventTitle: 'smsReceived', + dataFields: { + fromPhoneNumber: '+16503926753', + toPhoneNumber: '+14155824541', + smsMessage: 'Message text', + email: 'docs@iterable.com', + createdAt: '2016-12-05 22:51:25 +00:00', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Unknwon event type from Iterable', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [{ email: 'test@rudderstack.com', eventName: 'inAppSendSkip' }], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'test@rudderstack.com' }, + }, + event: 'inAppSendSkip', + integrations: { Iterable: false }, + type: 'track', + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'test@rudderstack.com', + eventName: 'emailSend', + dataFields: { + contentId: 331201, + email: 'test@rudderstack.com', + createdAt: '2016-12-02 20:21:04 +00:00', + campaignId: 59667, + templateId: 93849, + messageId: 'd0aa7801f91f4824997a631f3ed583c3', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c59667:t93849:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'test@rudderstack.com' }, + }, + event: 'emailSend', + integrations: { Iterable: false }, + properties: { + contentId: 331201, + createdAt: '2016-12-02 20:21:04 +00:00', + campaignId: 59667, + templateId: 93849, + messageId: 'd0aa7801f91f4824997a631f3ed583c3', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c59667:t93849:docs@iterable.com', + }, + receivedAt: '2016-12-02T20:21:04.000Z', + timestamp: '2016-12-02T20:21:04.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'invalid_email@iterable.com', + eventName: 'emailBounce', + dataFields: { + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2598, + messageTypeId: 2870, + experimentId: null, + recipientState: 'HardBounce', + templateId: 167484, + email: 'invalid_email@iterable.com', + createdAt: '2017-05-15 23:59:47 +00:00', + campaignId: 114746, + messageId: 'd0aa7801f91f4824997a631f3ed583c3', + emailId: 'c114746:t167484:invalid_email@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: 'b053765f5d0d23b0d5e4dd960be9513f', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'invalid_email@iterable.com' }, + }, + event: 'emailBounce', + integrations: { Iterable: false }, + properties: { + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2598, + messageTypeId: 2870, + experimentId: null, + recipientState: 'HardBounce', + templateId: 167484, + createdAt: '2017-05-15 23:59:47 +00:00', + campaignId: 114746, + messageId: 'd0aa7801f91f4824997a631f3ed583c3', + emailId: 'c114746:t167484:invalid_email@iterable.com', + }, + receivedAt: '2017-05-15T23:59:47.000Z', + timestamp: '2017-05-15T23:59:47.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-6', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'emailClick', + dataFields: { + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36', + ip: '162.245.22.184', + templateId: 93849, + userAgentDevice: 'Mac', + url: 'https://www.iterable.com', + canonicalUrlId: '3145668988', + city: 'San Francisco', + region: 'CA', + email: 'docs@iterable.com', + createdAt: '2016-12-02 20:31:39 +00:00', + campaignId: 59667, + messageId: 'd0aa7801f91f4824997a631f3ed583c3', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + linkUrl: 'https://www.iterable.com', + linkId: '3145668988', + emailId: 'c59667:t93849:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'emailClick', + integrations: { Iterable: false }, + properties: { + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36', + ip: '162.245.22.184', + templateId: 93849, + userAgentDevice: 'Mac', + url: 'https://www.iterable.com', + canonicalUrlId: '3145668988', + city: 'San Francisco', + region: 'CA', + createdAt: '2016-12-02 20:31:39 +00:00', + campaignId: 59667, + messageId: 'd0aa7801f91f4824997a631f3ed583c3', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + linkUrl: 'https://www.iterable.com', + linkId: '3145668988', + emailId: 'c59667:t93849:docs@iterable.com', + }, + receivedAt: '2016-12-02T20:31:39.000Z', + timestamp: '2016-12-02T20:31:39.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-7', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'emailComplaint', + dataFields: { + recipientState: 'Complaint', + templateId: 79190, + email: 'docs@iterable.com', + createdAt: '2016-12-09 18:52:19 +00:00', + campaignId: 49313, + messageId: 'd3c44d47b4994306b4db8d16a94db025', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'test template', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c49313:t79190:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'emailComplaint', + integrations: { Iterable: false }, + properties: { + recipientState: 'Complaint', + templateId: 79190, + createdAt: '2016-12-09 18:52:19 +00:00', + campaignId: 49313, + messageId: 'd3c44d47b4994306b4db8d16a94db025', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'test template', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c49313:t79190:docs@iterable.com', + }, + receivedAt: '2016-12-09T18:52:19.000Z', + timestamp: '2016-12-09T18:52:19.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-8', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'emailOpen', + dataFields: { + userAgent: + 'Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)', + proxySource: 'Gmail', + ip: '66.249.84.204', + templateId: 79190, + device: 'Gmail', + email: 'docs@iterable.com', + createdAt: '2016-12-02 18:51:45 +00:00', + campaignId: 49313, + messageId: '210badf49fe54f2591d64ad0d055f4fb', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c49313:t79190:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'emailOpen', + integrations: { Iterable: false }, + properties: { + userAgent: + 'Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)', + proxySource: 'Gmail', + ip: '66.249.84.204', + templateId: 79190, + device: 'Gmail', + createdAt: '2016-12-02 18:51:45 +00:00', + campaignId: 49313, + messageId: '210badf49fe54f2591d64ad0d055f4fb', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c49313:t79190:docs@iterable.com', + }, + receivedAt: '2016-12-02T18:51:45.000Z', + timestamp: '2016-12-02T18:51:45.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-9', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'emailSendSkip', + dataFields: { + createdAt: '2019-08-07 18:56:10 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 721398, + messageId: '98430abe1b9842c991ce221010121553', + email: 'docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'emailSendSkip', + integrations: { Iterable: false }, + properties: { + createdAt: '2019-08-07 18:56:10 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 721398, + messageId: '98430abe1b9842c991ce221010121553', + }, + receivedAt: '2019-08-07T18:56:10.000Z', + timestamp: '2019-08-07T18:56:10.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-10', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'test@rudderstack.com', + eventName: 'emailSubscribe', + dataFields: { + profileUpdatedAt: '2022-04-19 03:33:50 +00:00', + publicIdString: 'ad474bf7-e785-480f-b9d0-861b85ab5bf5', + signupSource: 'WebForm', + email: 'test@abcd.com', + createdAt: '2022-04-19 03:33:50 +00:00', + messageTypeIds: [], + emailListIds: [1589748], + channelIds: [], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'test@rudderstack.com' }, + }, + event: 'emailSubscribe', + integrations: { Iterable: false }, + properties: { + channelIds: [], + createdAt: '2022-04-19 03:33:50 +00:00', + emailListIds: [1589748], + messageTypeIds: [], + profileUpdatedAt: '2022-04-19 03:33:50 +00:00', + publicIdString: 'ad474bf7-e785-480f-b9d0-861b85ab5bf5', + signupSource: 'WebForm', + }, + receivedAt: '2022-04-19T03:33:50.000Z', + timestamp: '2022-04-19T03:33:50.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-11', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'emailUnSubscribe', + dataFields: { + campaignId: 1089024, + messageId: 'bf008db8ab194b65816398c05bf30f99', + emailId: 'c1089024:t1526112:docs@iterable.com', + workflowName: 'My test workflow', + messageTypeIds: [], + locale: null, + templateId: 1526112, + emailSubject: 'Upcoming events!', + labels: [], + unsubSource: 'EmailLink', + createdAt: '2020-03-20 23:34:15 +00:00', + templateName: 'My test template', + emailListIds: [], + messageTypeId: 31082, + experimentId: null, + channelIds: [27447], + campaignName: 'My test campaign', + workflowId: 76786, + email: 'docs@iterable.com', + channelId: 27447, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'emailUnSubscribe', + integrations: { Iterable: false }, + properties: { + campaignId: 1089024, + messageId: 'bf008db8ab194b65816398c05bf30f99', + emailId: 'c1089024:t1526112:docs@iterable.com', + workflowName: 'My test workflow', + messageTypeIds: [], + locale: null, + templateId: 1526112, + emailSubject: 'Upcoming events!', + labels: [], + unsubSource: 'EmailLink', + createdAt: '2020-03-20 23:34:15 +00:00', + templateName: 'My test template', + emailListIds: [], + messageTypeId: 31082, + experimentId: null, + channelIds: [27447], + campaignName: 'My test campaign', + workflowId: 76786, + channelId: 27447, + }, + receivedAt: '2020-03-20T23:34:15.000Z', + timestamp: '2020-03-20T23:34:15.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-12', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + userId: '1', + eventName: 'hostedUnsubscribeClick', + dataFields: { + country: 'United States', + city: 'San Jose', + campaignId: 1074721, + ip: '192.168.0.1', + userAgentDevice: 'Mac', + messageId: 'ceb3d4d929fc406ca93b28a0ef1efff1', + emailId: 'c1074721:t1506266:docs@iterable.com', + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36', + workflowName: 'My workflow', + locale: null, + templateId: 1506266, + emailSubject: 'My email subject', + url: 'https://iterable.com', + labels: [], + createdAt: '2020-03-21 00:24:08 +00:00', + templateName: 'My email template', + messageTypeId: 13406, + experimentId: null, + region: 'CA', + campaignName: 'My email campaign', + workflowId: 60102, + email: 'docs@iterable.com', + channelId: 12466, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '1', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'hostedUnsubscribeClick', + integrations: { Iterable: false }, + properties: { + country: 'United States', + city: 'San Jose', + campaignId: 1074721, + ip: '192.168.0.1', + userAgentDevice: 'Mac', + messageId: 'ceb3d4d929fc406ca93b28a0ef1efff1', + emailId: 'c1074721:t1506266:docs@iterable.com', + userAgent: + 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36', + workflowName: 'My workflow', + locale: null, + templateId: 1506266, + emailSubject: 'My email subject', + url: 'https://iterable.com', + labels: [], + createdAt: '2020-03-21 00:24:08 +00:00', + templateName: 'My email template', + messageTypeId: 13406, + experimentId: null, + region: 'CA', + campaignName: 'My email campaign', + workflowId: 60102, + channelId: 12466, + }, + receivedAt: '2020-03-21T00:24:08.000Z', + timestamp: '2020-03-21T00:24:08.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-13', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'inAppClick', + dataFields: { + email: 'docs@iterable.com', + createdAt: '2018-03-27 00:44:40 +00:00', + campaignId: 269450, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'inAppClick', + integrations: { Iterable: false }, + properties: { createdAt: '2018-03-27 00:44:40 +00:00', campaignId: 269450 }, + receivedAt: '2018-03-27T00:44:40.000Z', + timestamp: '2018-03-27T00:44:40.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-14', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'inAppOpen', + dataFields: { + email: 'docs@iterable.com', + createdAt: '2018-03-27 00:44:30 +00:00', + campaignId: 269450, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'inAppOpen', + integrations: { Iterable: false }, + properties: { createdAt: '2018-03-27 00:44:30 +00:00', campaignId: 269450 }, + receivedAt: '2018-03-27T00:44:30.000Z', + timestamp: '2018-03-27T00:44:30.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-15', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'inAppSend', + dataFields: { + messageContext: { saveToInbox: false, trigger: 'immediate' }, + campaignId: 732678, + contentId: 18997, + messageId: 'vA16d48VVi4LQ5hMuZuquKzL0BXTdQJJUMJRjKnL1', + workflowName: null, + emailId: 'c732678:t1032729:docs@iterable.com', + locale: null, + templateId: 1032729, + inAppBody: '', + email: 'docs@iterable.com', + createdAt: '2016-12-10 01:00:38 +00:00', + campaignId: 74768, + templateId: 113554, + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2203, + messageTypeId: 2439, + experimentId: null, + payload: { path: 'yourpath/subpath' }, + sound: '', + badge: null, + contentAvailable: false, + deeplink: null, + locale: null, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'pushBounce', + integrations: { Iterable: false }, + properties: { + platformEndpoint: '', + createdAt: '2016-12-10 01:00:38 +00:00', + campaignId: 74768, + templateId: 113554, + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2203, + messageTypeId: 2439, + experimentId: null, + payload: { path: 'yourpath/subpath' }, + sound: '', + badge: null, + contentAvailable: false, + deeplink: null, + locale: null, + }, + receivedAt: '2016-12-10T01:00:38.000Z', + timestamp: '2016-12-10T01:00:38.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-18', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'pushOpen', + dataFields: { + appAlreadyRunning: false, + email: 'docs@iterable.com', + createdAt: '2016-12-08 01:25:22 +00:00', + campaignId: 74768, + templateId: 113554, + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2203, + messageTypeId: 2439, + experimentId: null, + payload: { path: 'shop_home' }, + sound: null, + badge: null, + contentAvailable: false, + deeplink: null, + locale: null, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'pushOpen', + integrations: { Iterable: false }, + properties: { + appAlreadyRunning: false, + createdAt: '2016-12-08 01:25:22 +00:00', + campaignId: 74768, + templateId: 113554, + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2203, + messageTypeId: 2439, + experimentId: null, + payload: { path: 'shop_home' }, + sound: null, + badge: null, + contentAvailable: false, + deeplink: null, + locale: null, + }, + receivedAt: '2016-12-08T01:25:22.000Z', + timestamp: '2016-12-08T01:25:22.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-19', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'pushSend', + dataFields: { + contentId: 6724, + platformEndpoint: '', + email: 'docs@iterable.com', + createdAt: '2016-12-08 00:53:11 +00:00', + campaignId: 74758, + templateId: 113541, + messageId: '73f2d3f13cd04db0b56c6143b179adc5', + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 1744, + messageTypeId: 1759, + experimentId: null, + payload: { a: '2' }, + sound: '', + badge: '', + contentAvailable: false, + deeplink: null, + locale: null, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'pushSend', + integrations: { Iterable: false }, + properties: { + contentId: 6724, + platformEndpoint: '', + createdAt: '2016-12-08 00:53:11 +00:00', + campaignId: 74758, + templateId: 113541, + messageId: '73f2d3f13cd04db0b56c6143b179adc5', + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 1744, + messageTypeId: 1759, + experimentId: null, + payload: { a: '2' }, + sound: '', + badge: '', + contentAvailable: false, + deeplink: null, + locale: null, + }, + receivedAt: '2016-12-08T00:53:11.000Z', + timestamp: '2016-12-08T00:53:11.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-20', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'pushSendSkip', + dataFields: { + createdAt: '2019-08-07 22:28:51 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 732667, + messageId: '8306ae0c74324635b7554947c5ec0e56', + email: 'docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'pushSendSkip', + integrations: { Iterable: false }, + properties: { + createdAt: '2019-08-07 22:28:51 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 732667, + messageId: '8306ae0c74324635b7554947c5ec0e56', + }, + receivedAt: '2019-08-07T22:28:51.000Z', + timestamp: '2019-08-07T22:28:51.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-21', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'pushUninstall', + dataFields: { + isGhostPush: false, + platformEndpoint: '', + email: 'docs@iterable.com', + createdAt: '2016-12-09 20:50:54 +00:00', + campaignId: 74768, + templateId: 113554, + messageId: '73f2d3f13cd04db0b56c6143b179adc5', + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2203, + messageTypeId: 2439, + experimentId: null, + payload: { path: 'your_folder/30' }, + sound: '', + badge: null, + contentAvailable: false, + deeplink: null, + locale: null, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'pushUninstall', + integrations: { Iterable: false }, + properties: { + isGhostPush: false, + platformEndpoint: '', + createdAt: '2016-12-09 20:50:54 +00:00', + campaignId: 74768, + templateId: 113554, + messageId: '73f2d3f13cd04db0b56c6143b179adc5', + pushMessage: 'Push message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 2203, + messageTypeId: 2439, + experimentId: null, + payload: { path: 'your_folder/30' }, + sound: '', + badge: null, + contentAvailable: false, + deeplink: null, + locale: null, + }, + receivedAt: '2016-12-09T20:50:54.000Z', + timestamp: '2016-12-09T20:50:54.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-22', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'smsBounce', + dataFields: { + smsProviderResponse: { + status: 404, + message: + 'The requested resource /2010-04-01/Accounts/ACCOUNT_NUMBER/Messages.json was not found', + code: 20404, + more_info: 'https://www.twilio.com/docs/errors/20404', + }, + email: 'docs@iterable.com', + createdAt: '2016-12-05 22:43:24 +00:00', + campaignId: 74003, + templateId: 112561, + smsMessage: "Here is example message, please respond with 'received'", + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 4270, + messageTypeId: 4769, + experimentId: null, + fromPhoneNumberId: 268, + imageUrl: null, + locale: null, + emailId: 'c74003:t112561:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'smsBounce', + integrations: { Iterable: false }, + properties: { + smsProviderResponse: { + status: 404, + message: + 'The requested resource /2010-04-01/Accounts/ACCOUNT_NUMBER/Messages.json was not found', + code: 20404, + more_info: 'https://www.twilio.com/docs/errors/20404', + }, + createdAt: '2016-12-05 22:43:24 +00:00', + campaignId: 74003, + templateId: 112561, + smsMessage: "Here is example message, please respond with 'received'", + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 4270, + messageTypeId: 4769, + experimentId: null, + fromPhoneNumberId: 268, + imageUrl: null, + locale: null, + emailId: 'c74003:t112561:docs@iterable.com', + }, + receivedAt: '2016-12-05T22:43:24.000Z', + timestamp: '2016-12-05T22:43:24.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-23', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'smsClick', + dataFields: { + campaignId: 1234567, + campaignName: 'My test campaign', + workflowId: null, + workflowName: null, + templateName: 'My template', + locale: null, + channelId: 98765, + messageTypeId: 43210, + experimentId: null, + labels: [], + smsMessage: 'Test SMS! https://www.example.com', + fromPhoneNumberId: 1234, + imageUrl: null, + clickedUrl: 'https://www.example.com', + email: 'docs@iterable.com', + createdAt: '2022-03-10 05:00:14 +00:00', + templateId: 1112222, + messageId: 'ebd8f3cfc1f74353b423c5e0f3dd8b39', + emailId: 'c1234567:t9876543:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'smsClick', + integrations: { Iterable: false }, + properties: { + campaignId: 1234567, + campaignName: 'My test campaign', + workflowId: null, + workflowName: null, + templateName: 'My template', + locale: null, + channelId: 98765, + messageTypeId: 43210, + experimentId: null, + labels: [], + smsMessage: 'Test SMS! https://www.example.com', + fromPhoneNumberId: 1234, + imageUrl: null, + clickedUrl: 'https://www.example.com', + createdAt: '2022-03-10 05:00:14 +00:00', + templateId: 1112222, + messageId: 'ebd8f3cfc1f74353b423c5e0f3dd8b39', + emailId: 'c1234567:t9876543:docs@iterable.com', + }, + receivedAt: '2022-03-10T05:00:14.000Z', + timestamp: '2022-03-10T05:00:14.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-24', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'smsReceived', + dataFields: { + fromPhoneNumber: '+16503926753', + toPhoneNumber: '+14155824541', + smsMessage: 'Message text', + email: 'docs@iterable.com', + createdAt: '2016-12-05 22:51:25 +00:00', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'smsReceived', + integrations: { Iterable: false }, + properties: { + fromPhoneNumber: '+16503926753', + toPhoneNumber: '+14155824541', + smsMessage: 'Message text', + createdAt: '2016-12-05 22:51:25 +00:00', + }, + receivedAt: '2016-12-05T22:51:25.000Z', + timestamp: '2016-12-05T22:51:25.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-25', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'smsSend', + dataFields: { + toPhoneNumber: '+16503926753', + fromSMSSenderId: 258, + contentId: 2086, + email: 'docs@iterable.com', + createdAt: '2016-12-05 21:50:32 +00:00', + campaignId: 73974, + templateId: 112523, + smsMessage: 'Message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 4270, + messageTypeId: 4769, + experimentId: null, + fromPhoneNumberId: 258, + imageUrl: null, + locale: null, + emailId: 'c73974:t112523:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'smsSend', + integrations: { Iterable: false }, + properties: { + toPhoneNumber: '+16503926753', + fromSMSSenderId: 258, + contentId: 2086, + createdAt: '2016-12-05 21:50:32 +00:00', + campaignId: 73974, + templateId: 112523, + smsMessage: 'Message text', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 4270, + messageTypeId: 4769, + experimentId: null, + fromPhoneNumberId: 258, + imageUrl: null, + locale: null, + emailId: 'c73974:t112523:docs@iterable.com', + }, + receivedAt: '2016-12-05T21:50:32.000Z', + timestamp: '2016-12-05T21:50:32.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-26', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'smsSendSkip', + dataFields: { + createdAt: '2019-08-07 18:49:48 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 729390, + messageId: '2c780bf42f26485db0fc6571d2e0f6a0', + email: 'docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'smsSendSkip', + integrations: { Iterable: false }, + properties: { + createdAt: '2019-08-07 18:49:48 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 729390, + messageId: '2c780bf42f26485db0fc6571d2e0f6a0', + }, + receivedAt: '2019-08-07T18:49:48.000Z', + timestamp: '2019-08-07T18:49:48.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-27', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'emailSend', + dataFields: { + contentId: 274222, + email: 'docs@iterable.com', + createdAt: '2016-12-02 18:51:40 +00:00', + campaignId: 49313, + transactionalData: { + __comment: + 'transactionalData lists the fields contained in the dataFields property of the API call or event used to trigger the email, campaign, or workflow. transactionalData must contain no more than 12k characters in total.', + }, + templateId: 79190, + messageId: '210badf49fe54f2591d64ad0d055f4fb', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c49313:t79190:docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'emailSend', + integrations: { Iterable: false }, + properties: { + contentId: 274222, + createdAt: '2016-12-02 18:51:40 +00:00', + campaignId: 49313, + transactionalData: { + __comment: + 'transactionalData lists the fields contained in the dataFields property of the API call or event used to trigger the email, campaign, or workflow. transactionalData must contain no more than 12k characters in total.', + }, + templateId: 79190, + messageId: '210badf49fe54f2591d64ad0d055f4fb', + emailSubject: 'My subject', + campaignName: 'My campaign name', + workflowId: null, + workflowName: null, + templateName: 'My template name', + channelId: 3420, + messageTypeId: 3866, + experimentId: null, + emailId: 'c49313:t79190:docs@iterable.com', + }, + receivedAt: '2016-12-02T18:51:40.000Z', + timestamp: '2016-12-02T18:51:40.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-28', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'webPushSend', + dataFields: { + campaignId: 723636, + browserToken: + 'cZn_inqLGPk:APA91bHsn5jo0-4V55RB38eCeLHj8ZXVJYciU7k6Kipbit3lrRlEe2Dt6bNzR4lSf6r2YNVdWY8l90hV0jmb_Y7y5ufcJ68xNI7wbsH6Q2jbEghA_Qo4kWbtu6A4NZN4gxc1xsEbyh7b', + contentId: 3681, + messageId: 'af4c726ae76b48c7871b6d0d7760d47c', + workflowName: 'My workflow name', + emailId: 'c723636:t1020396:docs@iterable.com', + locale: null, + webPushIcon: null, + templateId: 1020396, + labels: [], + createdAt: '2019-08-07 23:43:02 +00:00', + templateName: 'My template name', + webPushMessage: '', + messageTypeId: 9106, + webPushBody: null, + experimentId: null, + webPushClickAction: null, + campaignName: 'My campaign name', + workflowId: 53505, + channelId: 8539, + email: 'docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'webPushSend', + integrations: { Iterable: false }, + properties: { + campaignId: 723636, + browserToken: + 'cZn_inqLGPk:APA91bHsn5jo0-4V55RB38eCeLHj8ZXVJYciU7k6Kipbit3lrRlEe2Dt6bNzR4lSf6r2YNVdWY8l90hV0jmb_Y7y5ufcJ68xNI7wbsH6Q2jbEghA_Qo4kWbtu6A4NZN4gxc1xsEbyh7b', + contentId: 3681, + messageId: 'af4c726ae76b48c7871b6d0d7760d47c', + workflowName: 'My workflow name', + emailId: 'c723636:t1020396:docs@iterable.com', + locale: null, + webPushIcon: null, + templateId: 1020396, + labels: [], + createdAt: '2019-08-07 23:43:02 +00:00', + templateName: 'My template name', + webPushMessage: '', + messageTypeId: 9106, + webPushBody: null, + experimentId: null, + webPushClickAction: null, + campaignName: 'My campaign name', + workflowId: 53505, + channelId: 8539, + }, + receivedAt: '2019-08-07T23:43:02.000Z', + timestamp: '2019-08-07T23:43:02.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'iterable', + description: 'test-29', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + email: 'docs@iterable.com', + eventName: 'webPushSendSkip', + dataFields: { + createdAt: '2019-08-07 23:43:48 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 723636, + messageId: '4238c918b20a41dfbe9a910275b76f12', + email: 'docs@iterable.com', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '0e13848b1c7e27eb5d88c5d35b70783e', + context: { + integration: { name: 'Iterable', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'docs@iterable.com' }, + }, + event: 'webPushSendSkip', + integrations: { Iterable: false }, + properties: { + createdAt: '2019-08-07 23:43:48 +00:00', + reason: 'DuplicateMarketingMessage', + campaignId: 723636, + messageId: '4238c918b20a41dfbe9a910275b76f12', + }, + receivedAt: '2019-08-07T23:43:48.000Z', + timestamp: '2019-08-07T23:43:48.000Z', + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + overrideReceivedAt: true, +})); diff --git a/test/integrations/sources/mailjet/data.ts b/test/integrations/sources/mailjet/data.ts new file mode 100644 index 0000000000..2a8f3eaf46 --- /dev/null +++ b/test/integrations/sources/mailjet/data.ts @@ -0,0 +1,394 @@ +export const data = [ + { + name: 'mailjet', + description: 'MailJet email open event', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: 'open', + time: 1664443614, + MessageID: 94857068804950690, + Message_GUID: '54d6cdec-f659-4547-8926-13d9c4126b82', + email: 'test@rudderstack.com', + mj_campaign_id: 108760, + mj_contact_id: 399962859, + customcampaign: 'mj.nl=58424', + ip: '66.249.84.231', + geo: 'US', + agent: + 'Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)', + CustomID: '', + Payload: '', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'MailJet' }, + traits: { email: 'test@rudderstack.com' }, + ip: '66.249.84.231', + userAgent: + 'Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko Firefox/11.0 (via ggpht.com GoogleImageProxy)', + externalId: [{ type: 'mailjetContactId', id: 399962859 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'open', + properties: { + ip: '66.249.84.231', + customcampaign: 'mj.nl=58424', + mj_campaign_id: 108760, + Payload: '', + }, + originalTimestamp: '2022-09-29T09:26:54.000Z', + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailjet', + description: 'MailJet email bounce event where input event is of type ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: 'bounce', + time: 1664444171, + MessageID: 55169098999352350, + Message_GUID: '447d7eab-3335-4aba-9a51-09454bc14b81', + email: 'test@rudderstack.com', + mj_campaign_id: 108892, + mj_contact_id: 373142816, + customcampaign: 'mj.nl=58486', + blocked: false, + hard_bounce: false, + error_related_to: 'system', + error: 'connection issue', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'MailJet' }, + traits: { email: 'test@rudderstack.com' }, + externalId: [{ type: 'mailjetContactId', id: 373142816 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'bounce', + properties: { customcampaign: 'mj.nl=58486', mj_campaign_id: 108892 }, + originalTimestamp: '2022-09-29T09:36:11.000Z', + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailjet', + description: 'MailJet email sent event', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: 'sent', + time: 1664444171, + MessageID: 92886743924596480, + Message_GUID: '0230c73a-2b77-4aea-8ef2-ed15d0edc5fd', + email: 'test@rudderstack.com', + mj_campaign_id: 108892, + mj_contact_id: 372651182, + customcampaign: 'mj.nl=58486', + smtp_reply: + '250 2.0.0 OK DMARC:Quarantine 1664444171 u17-20020adfdd51000000b0022cc3f2bf13si3225188wrm.271 - gsmtp', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'MailJet' }, + traits: { email: 'test@rudderstack.com' }, + externalId: [{ type: 'mailjetContactId', id: 372651182 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'sent', + properties: { customcampaign: 'mj.nl=58486', mj_campaign_id: 108892 }, + originalTimestamp: '2022-09-29T09:36:11.000Z', + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailjet', + description: 'MailJet email bounce event', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: 'bounce', + time: 1664444170, + MessageID: 56013522696710744, + Message_GUID: 'dbe4f0a3-4a5a-4784-a724-a9794d3c0444', + email: 'test@rudderstack.com', + mj_campaign_id: 108892, + mj_contact_id: 373142182, + customcampaign: 'mj.nl=58486', + blocked: false, + hard_bounce: false, + error_related_to: 'system', + error: 'connection issue', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'MailJet' }, + traits: { email: 'test@rudderstack.com' }, + externalId: [{ type: 'mailjetContactId', id: 373142182 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'bounce', + properties: { customcampaign: 'mj.nl=58486', mj_campaign_id: 108892 }, + originalTimestamp: '2022-09-29T09:36:10.000Z', + userId: '5b6a3426dba2cb24e4f0aeec43bee9d7', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailjet', + description: 'MailJet when no email is present', + module: 'source', + version: 'v0', + skipGo: 'FIXME', + input: { + request: { + body: [ + { + event: 'bounce', + time: 1664444170, + MessageID: 56013522696710744, + Message_GUID: 'dbe4f0a3-4a5a-4784-a724-a9794d3c0444', + mj_campaign_id: 108892, + mj_contact_id: 373142182, + customcampaign: 'mj.nl=58486', + blocked: false, + hard_bounce: false, + error_related_to: 'system', + error: 'connection issue', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'MailJet' }, + externalId: [{ type: 'mailjetContactId', id: 373142182 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'bounce', + properties: { customcampaign: 'mj.nl=58486', mj_campaign_id: 108892 }, + originalTimestamp: '2022-09-29T09:36:10.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailjet', + description: 'MailJet Multiple payloads in single request', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: 'open', + time: 1704458040, + MessageID: 987654, + Message_GUID: '876r-oihugyf-7tfygh', + email: 'abc@r.com', + mj_campaign_id: 321, + mj_contact_id: 123, + customcampaign: 'test_campaign', + url: 'https://www.example.com/', + ip: 'ip_info', + geo: 'some geo info', + agent: 'mailjet api test', + }, + { + event: 'click', + time: 1704458041, + MessageID: 12345234567, + Message_GUID: '12345-kjhgfd-2efv', + email: 'abc@r.com', + mj_campaign_id: 12, + mj_contact_id: 32532, + customcampaign: 'test_campaign', + url: 'https://www.example.com/', + ip: 'ip_info', + geo: 'some geo info', + agent: 'mailjet api test', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + ip: 'ip_info', + integration: { name: 'MailJet' }, + traits: { email: 'abc@r.com' }, + page: { url: 'https://www.example.com/' }, + userAgent: 'mailjet api test', + externalId: [{ type: 'mailjetContactId', id: 123 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'open', + properties: { + customcampaign: 'test_campaign', + mj_campaign_id: 321, + ip: 'ip_info', + url: 'https://www.example.com/', + }, + userId: '593a5aff0b445b3b77a6d9676b7ec86e', + originalTimestamp: '2024-01-05T12:34:00.000Z', + }, + ], + }, + }, + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + page: { url: 'https://www.example.com/' }, + integration: { name: 'MailJet' }, + traits: { email: 'abc@r.com' }, + userAgent: 'mailjet api test', + ip: 'ip_info', + externalId: [{ type: 'mailjetContactId', id: 32532 }], + }, + integrations: { MailJet: false }, + type: 'track', + event: 'click', + properties: { + customcampaign: 'test_campaign', + mj_campaign_id: 12, + ip: 'ip_info', + url: 'https://www.example.com/', + }, + userId: '593a5aff0b445b3b77a6d9676b7ec86e', + originalTimestamp: '2024-01-05T12:34:01.000Z', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/mailmodo/data.ts b/test/integrations/sources/mailmodo/data.ts new file mode 100644 index 0000000000..aa34363831 --- /dev/null +++ b/test/integrations/sources/mailmodo/data.ts @@ -0,0 +1,589 @@ +export const data = [ + { + name: 'mailmodo', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + triggerData: { + data: {}, + triggerSource: 'CsvList', + email: 'gouhgc@mailmodo.com', + triggerDetails: + 'file:1a69df39hfbfg4e0b-8b5c-73776157aa37/7647792f-4ebc-4f9d-ac79-05fb0356137e', + userId: 'd3775892hvh4f2f-b9d5-e49810eb2cae', + journeyId: '1a69df39hgvh4e0b-8b5c-73776157aa37', + eventProperty: {}, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: 'f43848cce166e51b097cbed2851adc16ed9d4c341928f1c790215c50cefb59b0', + context: { + externalId: [ + { id: 'd3775892hvh4f2f-b9d5-e49810eb2cae', type: 'mailmodoUserId' }, + ], + traits: { email: 'gouhgc@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'CsvList', + integrations: { Mailmodo: false }, + properties: { + 'triggerData.triggerSource': 'CsvList', + 'triggerData.triggerDetails': + 'file:1a69df39hfbfg4e0b-8b5c-73776157aa37/7647792f-4ebc-4f9d-ac79-05fb0356137e', + 'triggerData.journeyId': '1a69df39hgvh4e0b-8b5c-73776157aa37', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + fuuid: '27905', + 'next-step-id': 'success', + 'total-steps': '3', + responseId: 'b9a5d224-cc5a-4e64-9800-5a3db9515fdf', + recipientEmail: 'test.rudderlabs21997@gmail.com', + formId: 'formosztd5', + recordedAt: { ts: 1662695704, date: '2022-09-09', hour: 9, minute: 25 }, + submissionSource: 'amp', + elementjbtz42: 'Everything ', + element8jzo13: ['Reliable', 'High Quality', 'Useful'], + recipientData: { email: 'test.rudderlabs21997@gmail.com' }, + recommend: '9', + liking: 'upvote', + satisfaction: '4', + campaignId: '0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd', + campaignName: 'Campaign-testing', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: 'a80b34ec43ca959c7b8e5116ac626c3cf8561f62616e000a01729a8a900cc0a0', + context: { + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'test.rudderlabs21997@gmail.com' }, + }, + event: 'Form Submitted', + integrations: { Mailmodo: false }, + originalTimestamp: '2022-09-09T03:55:04.000Z', + properties: { + campaignId: '0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd', + campaignName: 'Campaign-testing', + 'element8jzo13[0]': 'Reliable', + 'element8jzo13[1]': 'High Quality', + 'element8jzo13[2]': 'Useful', + elementjbtz42: 'Everything ', + formId: 'formosztd5', + fuuid: '27905', + liking: 'upvote', + 'next-step-id': 'success', + recommend: '9', + responseId: 'b9a5d224-cc5a-4e64-9800-5a3db9515fdf', + satisfaction: '4', + submissionSource: 'amp', + 'total-steps': '3', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + triggerData: { + data: {}, + triggerSource: 'Manual Add To List', + email: 'gou****@mailmodo.com', + userId: 'd3775892-****-4f2f-b9d5-e49810eb2cae', + journeyId: '349e986e-f56c-****-bc3b-b5f13c3e34da', + eventProperty: {}, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92', + context: { + externalId: [ + { id: 'd3775892-****-4f2f-b9d5-e49810eb2cae', type: 'mailmodoUserId' }, + ], + traits: { email: 'gou****@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'Manual Add To List', + integrations: { Mailmodo: false }, + properties: { + 'triggerData.triggerSource': 'Manual Add To List', + 'triggerData.journeyId': '349e986e-f56c-****-bc3b-b5f13c3e34da', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + triggerData: { + data: {}, + triggerSource: 'Dashboard-change in property: first_name', + email: 'gou****@mailmodo.com', + userId: 'cc56708d-****-****-8c07-a4bfa5a7b79b', + journeyId: 'a78d7221-de34-47d8-81c6-5ad70cf4ee38', + eventProperty: {}, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92', + context: { + externalId: [ + { id: 'cc56708d-****-****-8c07-a4bfa5a7b79b', type: 'mailmodoUserId' }, + ], + traits: { email: 'gou****@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'Dashboard-change in property: first_name', + integrations: { Mailmodo: false }, + properties: { + 'triggerData.triggerSource': 'Dashboard-change in property: first_name', + 'triggerData.journeyId': 'a78d7221-de34-47d8-81c6-5ad70cf4ee38', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + triggerData: { + data: {}, + formSubmissionData: { + element6ehxt3: 'Te**', + element6jkcy4: 'Bang****', + fuuid: '47949', + 'next-step-id': 'step7tr7n2', + 'total-steps': '3', + responseId: '4a8bfda7-****-4a8c-9cd1-a30d30a6dab9', + recipientEmail: 'gou****@mailmodo.com', + formId: 'formmqxnu2', + recordedAt: { ts: 1657097786, date: '2022-07-06', hour: 14, minute: 26 }, + submissionSource: 'amp', + }, + email: 'gou****@mailmodo.com', + triggerSource: 'form submission', + userId: '11bff3e8-****-4e93-a533-fd8f9defc768', + journeyId: '03664747-****-412e-8790-de9e9abe96a5', + eventProperty: {}, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92', + context: { + externalId: [ + { id: '11bff3e8-****-4e93-a533-fd8f9defc768', type: 'mailmodoUserId' }, + ], + traits: { email: 'gou****@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'form submission', + integrations: { Mailmodo: false }, + originalTimestamp: '2022-07-06T08:56:26.000Z', + properties: { + 'triggerData.triggerSource': 'form submission', + 'triggerData.formSubmissionData.element6ehxt3': 'Te**', + 'triggerData.formSubmissionData.element6jkcy4': 'Bang****', + 'triggerData.formSubmissionData.formId': 'formmqxnu2', + 'triggerData.formSubmissionData.fuuid': '47949', + 'triggerData.formSubmissionData.next-step-id': 'step7tr7n2', + 'triggerData.formSubmissionData.responseId': + '4a8bfda7-****-4a8c-9cd1-a30d30a6dab9', + 'triggerData.formSubmissionData.submissionSource': 'amp', + 'triggerData.formSubmissionData.total-steps': '3', + 'triggerData.journeyId': '03664747-****-412e-8790-de9e9abe96a5', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + triggerData: { + data: {}, + eventProperty: { + Name: 'APPLE iPhone 13 (Blue, 128 GB)', + Category: 'Mobiles', + 'Is Purchased': 'false', + Price: '829', + Currency: 'USD', + }, + triggerSource: 'New Custom Event Trigger - Product Viewed', + email: 'gou****@mailmodo.com', + userId: 'd3775892-****-4f2f-b9d5-e49810eb2cae', + journeyId: '3f135bf7-****-4e31-b265-f61cfe1bd423', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92', + context: { + externalId: [ + { id: 'd3775892-****-4f2f-b9d5-e49810eb2cae', type: 'mailmodoUserId' }, + ], + traits: { email: 'gou****@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'New Custom Event Trigger - Product Viewed', + integrations: { Mailmodo: false }, + properties: { + 'triggerData.eventProperty.Category': 'Mobiles', + 'triggerData.eventProperty.Currency': 'USD', + 'triggerData.eventProperty.Is Purchased': 'false', + 'triggerData.eventProperty.Name': 'APPLE iPhone 13 (Blue, 128 GB)', + 'triggerData.eventProperty.Price': '829', + 'triggerData.journeyId': '3f135bf7-****-4e31-b265-f61cfe1bd423', + 'triggerData.triggerSource': 'New Custom Event Trigger - Product Viewed', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-6', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + triggerData: { + email: 'gou****@mailmodo.com', + data: {}, + userId: 'd3775892-****-4f2f-b9d5-e49810eb2cae', + journeyId: 'b1ee6bf6-****-4b5a-b7b5-0637853cd8c3', + triggerSource: 'Api', + eventProperty: {}, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92', + context: { + externalId: [ + { id: 'd3775892-****-4f2f-b9d5-e49810eb2cae', type: 'mailmodoUserId' }, + ], + traits: { email: 'gou****@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'Api', + integrations: { Mailmodo: false }, + properties: { + 'triggerData.triggerSource': 'Api', + 'triggerData.journeyId': 'b1ee6bf6-****-4b5a-b7b5-0637853cd8c3', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-7', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventData: { type: 'html' }, + triggerData: { + data: {}, + triggerSource: 'CsvList', + email: 'gou****@mailmodo.com', + triggerDetails: + 'file:5d31c2b4-****-4a84-acd3-834cae80231b/5a61e0b8-b6f6-4d7d-abf2-90357d6638af', + userId: 'cc56708d-****-4fea-8c07-a4bfa5a7b79b', + journeyId: '5d31c2b4-****-4a84-acd3-834cae80231b', + eventProperty: {}, + }, + lastCampaignEmailRef: '064c76e7-****-4780-a001-226c066aaa12', + lastCampaignId: '31422f76-****-4a72-a630-dd6f9f615bc3', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '26c9ad4b531287858155ffa834be13dddc2c45df6e29af7230408953d732dd92', + context: { + externalId: [ + { id: 'cc56708d-****-4fea-8c07-a4bfa5a7b79b', type: 'mailmodoUserId' }, + ], + traits: { email: 'gou****@mailmodo.com' }, + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + }, + event: 'CsvList', + integrations: { Mailmodo: false }, + properties: { + 'eventData.type': 'html', + lastCampaignEmailRef: '064c76e7-****-4780-a001-226c066aaa12', + lastCampaignId: '31422f76-****-4a72-a630-dd6f9f615bc3', + 'triggerData.journeyId': '5d31c2b4-****-4a84-acd3-834cae80231b', + 'triggerData.triggerDetails': + 'file:5d31c2b4-****-4a84-acd3-834cae80231b/5a61e0b8-b6f6-4d7d-abf2-90357d6638af', + 'triggerData.triggerSource': 'CsvList', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'mailmodo', + description: 'test-8', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + fuuid: '98255', + 'next-step-id': 'success', + 'total-steps': '3', + responseId: 'ad20a980-4fce-44b6-887d-2236df514a76', + recipientEmail: 'test@rudderstack.com', + formId: 'formosztd5', + recordedAt: { ts: 1662695887, date: '2022-09-09', hour: 9, minute: 28 }, + submissionSource: 'amp', + elementjbtz42: 'peace', + element8jzo13: ['Useful'], + recipientData: { email: 'test@rudderstack.com', first_name: 'abcda' }, + recommend: '1', + liking: 'downvote', + satisfaction: '1', + campaignId: '0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd', + campaignName: 'Campaign-testing', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '1c5e54849f5c711ce38fa60716fbbe44bff478f9ca250897b39cdfc2438cd1bd', + context: { + integration: { name: 'Mailmodo', version: '1.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + traits: { email: 'test@rudderstack.com', first_name: 'abcda' }, + }, + event: 'Form Submitted', + integrations: { Mailmodo: false }, + originalTimestamp: '2022-09-09T03:58:07.000Z', + properties: { + fuuid: '98255', + 'next-step-id': 'success', + 'total-steps': '3', + responseId: 'ad20a980-4fce-44b6-887d-2236df514a76', + formId: 'formosztd5', + submissionSource: 'amp', + elementjbtz42: 'peace', + 'element8jzo13[0]': 'Useful', + recommend: '1', + liking: 'downvote', + satisfaction: '1', + campaignId: '0b53e1bf-84ae-4198-9184-8a4d6e1fa3dd', + campaignName: 'Campaign-testing', + }, + type: 'track', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/moengage/data.ts b/test/integrations/sources/moengage/data.ts index e8160ae08b..c307959121 100644 --- a/test/integrations/sources/moengage/data.ts +++ b/test/integrations/sources/moengage/data.ts @@ -264,6 +264,8 @@ const data = [ description: 'Batch of events', module: 'source', version: 'v0', + overrideReceivedAt: true, + overrideRequestIP: true, input: { request: { body: [ diff --git a/test/integrations/sources/monday/data.ts b/test/integrations/sources/monday/data.ts new file mode 100644 index 0000000000..1bb2693090 --- /dev/null +++ b/test/integrations/sources/monday/data.ts @@ -0,0 +1,454 @@ +export const data = [ + { + name: 'monday', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + userId: 33556506, + originalTriggerUuid: null, + boardId: 3139815405, + pulseId: 3160188786, + pulseName: 'New Sprint Item', + groupId: 'topics', + groupName: 'Group Title', + groupColor: '#579bfc', + isTopGroup: true, + columnValues: {}, + app: 'monday', + type: 'create_pulse', + triggerTime: '2022-08-30T09:02:39.191Z', + subscriptionId: 150881106, + triggerUuid: '049869226bf6711705c62e301a2c3eee', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Create Pulse', + context: { + library: { name: 'unknown', version: 'unknown' }, + externalId: [{ id: 33556506, type: 'mondayUserId' }], + integration: { name: 'MONDAY' }, + }, + timestamp: '2022-08-30T09:02:39.191Z', + properties: { + app: 'monday', + type: 'create_pulse', + boardId: 3139815405, + groupId: 'topics', + pulseId: 3160188786, + groupName: 'Group Title', + pulseName: 'New Sprint Item', + groupColor: '#579bfc', + isTopGroup: true, + triggerUuid: '049869226bf6711705c62e301a2c3eee', + columnValues: {}, + subscriptionId: 150881106, + originalTriggerUuid: null, + }, + anonymousId: '6f0a3dc76a335860e17fa1d8ab779742e2ca', + integrations: { MONDAY: false }, + originalTimestamp: '2022-08-30T09:02:39.191Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'monday', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + userId: 33556506, + originalTriggerUuid: null, + boardId: 3139815405, + itemId: 3160188786, + itemName: 'New Sprint Item', + app: 'monday', + type: 'delete_pulse', + triggerTime: '2022-08-30T09:06:09.176Z', + subscriptionId: 150882006, + triggerUuid: '4e4f87c8255c4ba4ba2f5e9934cb6d40', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Delete Pulse', + context: { + library: { name: 'unknown', version: 'unknown' }, + externalId: [{ id: 33556506, type: 'mondayUserId' }], + integration: { name: 'MONDAY' }, + }, + timestamp: '2022-08-30T09:06:09.176Z', + properties: { + app: 'monday', + type: 'delete_pulse', + itemId: 3160188786, + boardId: 3139815405, + itemName: 'New Sprint Item', + triggerUuid: '4e4f87c8255c4ba4ba2f5e9934cb6d40', + subscriptionId: 150882006, + originalTriggerUuid: null, + }, + anonymousId: '6f0a3dc76a335860e17fa1d8ab779742e2ca', + integrations: { MONDAY: false }, + originalTimestamp: '2022-08-30T09:06:09.176Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'monday', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + userId: 33556506, + originalTriggerUuid: null, + boardId: 3139815405, + groupId: 'topics', + pulseId: 3160181387, + pulseName: 'New Sprint Item', + columnId: 'status', + columnType: 'color', + columnTitle: 'Status', + value: { + label: { + index: 1, + text: 'Done', + style: { color: '#00c875', border: '#00B461', var_name: 'green-shadow' }, + is_done: true, + }, + post_id: null, + }, + previousValue: null, + changedAt: 1661859406.8970098, + isTopGroup: true, + app: 'monday', + type: 'update_column_value', + triggerTime: '2022-08-30T11:36:47.406Z', + subscriptionId: 150894742, + triggerUuid: '51730730740a9d00ec45203bd392a9bd', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Update Column Value', + context: { + library: { name: 'unknown', version: 'unknown' }, + externalId: [{ id: 33556506, type: 'mondayUserId' }], + integration: { name: 'MONDAY' }, + }, + timestamp: '2022-08-30T11:36:47.406Z', + properties: { + app: 'monday', + type: 'update_column_value', + value: { + label: { + text: 'Done', + index: 1, + style: { color: '#00c875', border: '#00B461', var_name: 'green-shadow' }, + is_done: true, + }, + post_id: null, + }, + boardId: 3139815405, + groupId: 'topics', + pulseId: 3160181387, + columnId: 'status', + changedAt: 1661859406.8970098, + pulseName: 'New Sprint Item', + columnType: 'color', + isTopGroup: true, + columnTitle: 'Status', + triggerUuid: '51730730740a9d00ec45203bd392a9bd', + previousValue: null, + subscriptionId: 150894742, + originalTriggerUuid: null, + }, + anonymousId: '6f0a3dc76a335860e17fa1d8ab779742e2ca', + integrations: { MONDAY: false }, + originalTimestamp: '2022-08-30T11:36:47.406Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'monday', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + userId: 33556506, + originalTriggerUuid: null, + boardId: 3139815405, + groupId: 'topics', + pulseId: 3160181387, + value: { name: 'New Sprint Item renamed' }, + previousValue: { name: 'New Sprint Item' }, + app: 'monday', + type: 'update_name', + triggerTime: '2022-08-30T11:40:17.351Z', + subscriptionId: 150910867, + triggerUuid: '05ce13d32d0256c4fb7dd5de25b1a1ba', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Update Name', + context: { + library: { name: 'unknown', version: 'unknown' }, + externalId: [{ id: 33556506, type: 'mondayUserId' }], + integration: { name: 'MONDAY' }, + }, + timestamp: '2022-08-30T11:40:17.351Z', + properties: { + app: 'monday', + type: 'update_name', + value: { name: 'New Sprint Item renamed' }, + boardId: 3139815405, + groupId: 'topics', + pulseId: 3160181387, + triggerUuid: '05ce13d32d0256c4fb7dd5de25b1a1ba', + previousValue: { name: 'New Sprint Item' }, + subscriptionId: 150910867, + originalTriggerUuid: null, + }, + anonymousId: '6f0a3dc76a335860e17fa1d8ab779742e2ca', + integrations: { MONDAY: false }, + originalTimestamp: '2022-08-30T11:40:17.351Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'monday', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + userId: 33556506, + originalTriggerUuid: null, + boardId: 3160805239, + pulseId: 3161163765, + pulseName: 'new subitem', + groupId: 'topics', + groupName: 'Subitems', + groupColor: '#579bfc', + isTopGroup: true, + columnValues: {}, + app: 'monday', + type: 'create_pulse', + triggerTime: '2022-08-30T12:56:27.281Z', + subscriptionId: 150911592, + triggerUuid: '70a2219427804e47a508a91b5c244543', + parentItemId: '3160181387', + parentItemBoardId: '3139815405', + itemId: 3161163765, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Create Pulse', + context: { + library: { name: 'unknown', version: 'unknown' }, + externalId: [{ id: 33556506, type: 'mondayUserId' }], + integration: { name: 'MONDAY' }, + }, + timestamp: '2022-08-30T12:56:27.281Z', + properties: { + app: 'monday', + type: 'create_pulse', + itemId: 3161163765, + boardId: 3160805239, + groupId: 'topics', + pulseId: 3161163765, + groupName: 'Subitems', + pulseName: 'new subitem', + groupColor: '#579bfc', + isTopGroup: true, + triggerUuid: '70a2219427804e47a508a91b5c244543', + columnValues: {}, + parentItemId: '3160181387', + subscriptionId: 150911592, + parentItemBoardId: '3139815405', + originalTriggerUuid: null, + }, + anonymousId: '6f0a3dc76a335860e17fa1d8ab779742e2ca', + integrations: { MONDAY: false }, + originalTimestamp: '2022-08-30T12:56:27.281Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'monday', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + userId: 33556506, + originalTriggerUuid: null, + boardId: 3139815405, + itemId: 3160181387, + itemName: 'New Sprint Item renamed', + app: 'monday', + type: 'archive_pulse', + triggerTime: '2022-08-30T12:58:15.844Z', + subscriptionId: 150925947, + triggerUuid: 'aa8bd5dbb6fd592aedd57322dd776379', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Archive Pulse', + context: { + library: { name: 'unknown', version: 'unknown' }, + externalId: [{ id: 33556506, type: 'mondayUserId' }], + integration: { name: 'MONDAY' }, + }, + timestamp: '2022-08-30T12:58:15.844Z', + properties: { + app: 'monday', + type: 'archive_pulse', + itemId: 3160181387, + boardId: 3139815405, + itemName: 'New Sprint Item renamed', + triggerUuid: 'aa8bd5dbb6fd592aedd57322dd776379', + subscriptionId: 150925947, + originalTriggerUuid: null, + }, + anonymousId: '6f0a3dc76a335860e17fa1d8ab779742e2ca', + integrations: { MONDAY: false }, + originalTimestamp: '2022-08-30T12:58:15.844Z', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/olark/data.ts b/test/integrations/sources/olark/data.ts new file mode 100644 index 0000000000..3486e84907 --- /dev/null +++ b/test/integrations/sources/olark/data.ts @@ -0,0 +1,301 @@ +export const data = [ + { + name: 'olark', + description: 'Olark webhook response', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + kind: 'Conversation', + id: 'ho6HrHxoabmm6q0G103JU0JFaor0BobA', + manuallySubmitted: false, + items: [ + { + kind: 'OfflineMessage', + timestamp: '1669285628.796693', + body: 'name: test rudderlabs\nemail: ruddertest@gmail.com\nMessage: I am Fine', + }, + ], + tags: [], + visitor: { + kind: 'Visitor', + id: '45WjM9eMYwJ7cJMo103JU0JaForAA6Db', + fullName: 'test', + emailAddress: 'ruddertest@gmail.com', + ip: '', + country: 'India', + countryCode: 'IN', + browser: 'Chrome 105.0.0.0', + operatingSystem: 'Macintosh', + conversationBeginPage: 'http://localhost:5503/', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Conversation', + traits: {}, + userId: '45WjM9eMYwJ7cJMo103JU0JaForAA6Db', + context: { + os: { name: 'Macintosh' }, + page: { url: 'http://localhost:5503/' }, + traits: { name: 'test', email: 'ruddertest@gmail.com', country: 'India' }, + browser: { name: 'Chrome', version: '105.0.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Olark' }, + }, + properties: { + tags: [], + items: [ + { + body: 'name: test rudderlabs\nemail: ruddertest@gmail.com\nMessage: I am Fine', + kind: 'OfflineMessage', + timestamp: '1669285628.796693', + }, + ], + }, + integrations: { Olark: false }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'olark', + description: 'Olark webhook response', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + kind: 'Conversation', + id: 'NOTAREALTRANSCRIPT5LGcbVTa3hKBRB', + manuallySubmitted: false, + items: [ + { + kind: 'MessageToVisitor', + nickname: 'Olark operator', + operatorId: '6208911878914048', + timestamp: '1473774819.263083', + body: 'Hi from an operator', + }, + { + kind: 'MessageToOperator', + nickname: 'Returning Visitor | USA (San Francisco, CA) #7617', + timestamp: '1473774821.411154', + body: 'Hi from a visitor', + visitor_nickname: 'Olark Visitor', + }, + ], + tags: ['test_example'], + visitor: { + kind: 'Visitor', + id: 'NOTAREALVISITORIDS5LGl6QUrK2OaPP', + fullName: 'Olark', + phoneNumber: '5555555555', + emailAddress: 'support+integrationtest@olark.com', + ip: '', + city: 'San Francisco', + region: 'CA', + country: 'United States', + countryCode: 'US', + organization: 'Visitor Organization', + browser: 'Internet Explorer 11', + operatingSystem: 'Windows', + referrer: 'http://www.olark.com', + conversationBeginPage: 'http://www.olark.com', + chat_feedback: { overall_chat: 4, responsiveness: 5, knowledge: 4, friendliness: 5 }, + }, + operators: { + '6208911878914048': { + kind: 'Operator', + id: '6208911878914048', + nickname: 'integration', + emailAddress: 'integration-accounts@rudderstack.com', + username: 'integration-accounts-92750bc547', + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Conversation', + traits: { + organization: 'Visitor Organization', + chat_feedback: { + knowledge: 4, + friendliness: 5, + overall_chat: 4, + responsiveness: 5, + }, + }, + userId: 'NOTAREALVISITORIDS5LGl6QUrK2OaPP', + context: { + os: { name: 'Windows' }, + page: { url: 'http://www.olark.com', referrer: 'http://www.olark.com' }, + traits: { + city: 'San Francisco', + name: 'Olark', + email: 'support+integrationtest@olark.com', + phone: '5555555555', + region: 'CA', + country: 'United States', + }, + browser: { name: 'Internet Explorer', version: '11' }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Olark' }, + }, + properties: { + tags: ['test_example'], + items: [ + { + body: 'Hi from an operator', + kind: 'MessageToVisitor', + nickname: 'Olark operator', + timestamp: '1473774819.263083', + operatorId: '6208911878914048', + }, + { + body: 'Hi from a visitor', + kind: 'MessageToOperator', + nickname: 'Returning Visitor | USA (San Francisco, CA) #7617', + timestamp: '1473774821.411154', + visitor_nickname: 'Olark Visitor', + }, + ], + }, + integrations: { Olark: false }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'olark', + description: 'Olark webhook response', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + kind: 'Conversation', + id: 'ho6HrHxoabmm6q0G103JU0JFaor0BobA', + manuallySubmitted: false, + items: [ + { + kind: 'OfflineMessage', + timestamp: '1669288532.567071', + body: 'name: test rudderstack\nemail: rudder14@gmail.com\nMessage: veavv', + }, + ], + tags: [], + groups: [{ kind: 'Group', id: 'ca77f4296fb7568909ad864aebf48201', name: 'Group 1' }], + visitor: { + kind: 'Visitor', + id: '45WjM9eMYwJ7cJMo103JU0JaForAA6Db', + fullName: 'test rudderstack', + emailAddress: 'rudder14@gmail.com', + ip: '', + country: 'India', + countryCode: 'IN', + browser: 'Chrome 105.0.0.0', + operatingSystem: 'Macintosh', + conversationBeginPage: 'http://localhost:5503/', + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Conversation', + traits: {}, + userId: '45WjM9eMYwJ7cJMo103JU0JaForAA6Db', + context: { + os: { name: 'Macintosh' }, + page: { url: 'http://localhost:5503/' }, + traits: { + name: 'test rudderstack', + email: 'rudder14@gmail.com', + country: 'India', + }, + browser: { name: 'Chrome', version: '105.0.0.0' }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Olark' }, + }, + properties: { + tags: [], + items: [ + { + body: 'name: test rudderstack\nemail: rudder14@gmail.com\nMessage: veavv', + kind: 'OfflineMessage', + timestamp: '1669288532.567071', + }, + ], + }, + integrations: { Olark: false }, + }, + { + name: 'Group 1', + type: 'group', + traits: { kind: 'Group' }, + userId: '45WjM9eMYwJ7cJMo103JU0JaForAA6Db', + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Olark' }, + }, + groupId: 'ca77f4296fb7568909ad864aebf48201', + integrations: { Olark: false }, + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/pagerduty/data.ts b/test/integrations/sources/pagerduty/data.ts new file mode 100644 index 0000000000..fdfee6fc0d --- /dev/null +++ b/test/integrations/sources/pagerduty/data.ts @@ -0,0 +1,725 @@ +export const data = [ + { + name: 'pagerduty', + description: 'Incident Triggered', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + id: '01DEN0V2VIFEN5871PQGX72URP', + event_type: 'incident.triggered', + resource_type: 'incident', + occurred_at: '2022-12-07T10:56:52.337Z', + agent: { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + client: { name: 'Monitoring Service', url: 'https://monitoring.service.com' }, + data: { + id: 'Q3S7IX2U5KTCOY', + type: 'incident', + self: 'https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + number: 2, + status: 'triggered', + incident_key: 'faaecfc0aca04b6ea07154188b5d3c6c', + created_at: '2022-12-07T10:56:52Z', + title: 'Server Crashed', + service: { + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + summary: 'Database', + type: 'service_reference', + }, + assignees: [ + { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + ], + escalation_policy: { + html_url: 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + summary: 'Default', + type: 'escalation_policy_reference', + }, + teams: [], + priority: { + html_url: 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + id: 'PPMNDVQ', + self: 'https://api.pagerduty.com/priorities/PPMNDVQ', + summary: 'P1', + type: 'priority_reference', + }, + urgency: 'high', + conference_bridge: null, + resolve_reason: null, + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Incident Triggered', + userId: 'PXZZD2E', + context: { + traits: { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'PagerDuty' }, + }, + messageId: '01DEN0V2VIFEN5871PQGX72URP', + properties: { + data: { + id: 'Q3S7IX2U5KTCOY', + self: 'https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + type: 'incident', + teams: [], + title: 'Server Crashed', + number: 2, + status: 'triggered', + service: { + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + type: 'service_reference', + summary: 'Database', + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + }, + urgency: 'high', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + priority: { + id: 'PPMNDVQ', + self: 'https://api.pagerduty.com/priorities/PPMNDVQ', + type: 'priority_reference', + summary: 'P1', + html_url: + 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + }, + assignees: [ + { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + ], + created_at: '2022-12-07T10:56:52Z', + incident_key: 'faaecfc0aca04b6ea07154188b5d3c6c', + resolve_reason: null, + conference_bridge: null, + escalation_policy: { + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + type: 'escalation_policy_reference', + summary: 'Default', + html_url: + 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + }, + }, + client: { url: 'https://monitoring.service.com', name: 'Monitoring Service' }, + resourceType: 'incident', + }, + integrations: { PagerDuty: false }, + originalTimestamp: '2022-12-07T10:56:52.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pagerduty', + description: 'Incident Priority Updated', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + id: '01DFU6P4VDDZCIHVQ5Q0ME99OE', + event_type: 'incident.priority_updated', + resource_type: 'incident', + occurred_at: '2022-12-20T11:43:24.342Z', + agent: { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + client: null, + data: { + id: 'Q1KRTY75EUMGM0', + type: 'incident', + self: 'https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0', + number: 7, + status: 'acknowledged', + incident_key: 'a3e0e442f8b74a8c94298f19de0dcbed', + created_at: '2022-12-20T11:37:19Z', + title: 'Event Stream Failure', + service: { + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + summary: 'Database', + type: 'service_reference', + }, + assignees: [ + { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + ], + escalation_policy: { + html_url: 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + summary: 'Default', + type: 'escalation_policy_reference', + }, + teams: [], + priority: { + html_url: 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + id: 'PPMNDVQ', + self: 'https://api.pagerduty.com/priorities/PPMNDVQ', + summary: 'P1', + type: 'priority_reference', + }, + urgency: 'high', + conference_bridge: null, + resolve_reason: null, + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Incident Priority Updated', + userId: 'PXZZD2E', + context: { + traits: { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'PagerDuty' }, + }, + messageId: '01DFU6P4VDDZCIHVQ5Q0ME99OE', + properties: { + data: { + id: 'Q1KRTY75EUMGM0', + self: 'https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0', + type: 'incident', + teams: [], + title: 'Event Stream Failure', + number: 7, + status: 'acknowledged', + service: { + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + type: 'service_reference', + summary: 'Database', + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + }, + urgency: 'high', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0', + priority: { + id: 'PPMNDVQ', + self: 'https://api.pagerduty.com/priorities/PPMNDVQ', + type: 'priority_reference', + summary: 'P1', + html_url: + 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + }, + assignees: [ + { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + ], + created_at: '2022-12-20T11:37:19Z', + incident_key: 'a3e0e442f8b74a8c94298f19de0dcbed', + resolve_reason: null, + conference_bridge: null, + escalation_policy: { + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + type: 'escalation_policy_reference', + summary: 'Default', + html_url: + 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + }, + }, + resourceType: 'incident', + }, + integrations: { PagerDuty: false }, + originalTimestamp: '2022-12-20T11:43:24.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pagerduty', + description: 'Incident Responder Added', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + id: '01DFU6Z1ZCLMV9SEK3X5JZ5WLW', + event_type: 'incident.responder.added', + resource_type: 'incident', + occurred_at: '2022-12-20T11:46:44.213Z', + agent: { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + client: null, + data: { + incident: { + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0', + id: 'Q1KRTY75EUMGM0', + self: 'https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0', + summary: 'Event Stream Failure', + type: 'incident_reference', + }, + user: { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + escalation_policy: null, + message: 'Please help with "Event Stream Failure"', + state: 'pending', + type: 'incident_responder', + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Incident Responder Added', + userId: 'PXZZD2E', + context: { + traits: { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'PagerDuty' }, + }, + messageId: '01DFU6Z1ZCLMV9SEK3X5JZ5WLW', + properties: { + data: { + type: 'incident_responder', + user: { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + state: 'pending', + message: 'Please help with "Event Stream Failure"', + incident: { + id: 'Q1KRTY75EUMGM0', + self: 'https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0', + type: 'incident_reference', + summary: 'Event Stream Failure', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0', + }, + escalation_policy: null, + }, + resourceType: 'incident', + }, + integrations: { PagerDuty: false }, + originalTimestamp: '2022-12-20T11:46:44.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pagerduty', + description: 'Incident Escalated', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + id: '01DFU77KTKK9UUYX779UX0N1ZP', + event_type: 'incident.escalated', + resource_type: 'incident', + occurred_at: '2022-12-20T11:49:35.385Z', + agent: { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + client: null, + data: { + id: 'Q1KRTY75EUMGM0', + type: 'incident', + self: 'https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0', + number: 7, + status: 'triggered', + incident_key: 'a3e0e442f8b74a8c94298f19de0dcbed', + created_at: '2022-12-20T11:37:19Z', + title: 'Event Stream Failure', + service: { + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + summary: 'Database', + type: 'service_reference', + }, + assignees: [ + { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + ], + escalation_policy: { + html_url: 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + summary: 'Default', + type: 'escalation_policy_reference', + }, + teams: [], + priority: { + html_url: 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + id: 'PPMNDVQ', + self: 'https://api.pagerduty.com/priorities/PPMNDVQ', + summary: 'P1', + type: 'priority_reference', + }, + urgency: 'high', + conference_bridge: null, + resolve_reason: null, + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Incident Escalated', + userId: 'PXZZD2E', + context: { + traits: { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'PagerDuty' }, + }, + messageId: '01DFU77KTKK9UUYX779UX0N1ZP', + properties: { + data: { + id: 'Q1KRTY75EUMGM0', + self: 'https://api.pagerduty.com/incidents/Q1KRTY75EUMGM0', + type: 'incident', + teams: [], + title: 'Event Stream Failure', + number: 7, + status: 'triggered', + service: { + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + type: 'service_reference', + summary: 'Database', + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + }, + urgency: 'high', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q1KRTY75EUMGM0', + priority: { + id: 'PPMNDVQ', + self: 'https://api.pagerduty.com/priorities/PPMNDVQ', + type: 'priority_reference', + summary: 'P1', + html_url: + 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + }, + assignees: [ + { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + ], + created_at: '2022-12-20T11:37:19Z', + incident_key: 'a3e0e442f8b74a8c94298f19de0dcbed', + resolve_reason: null, + conference_bridge: null, + escalation_policy: { + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + type: 'escalation_policy_reference', + summary: 'Default', + html_url: + 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + }, + }, + resourceType: 'incident', + }, + integrations: { PagerDuty: false }, + originalTimestamp: '2022-12-20T11:49:35.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pagerduty', + description: 'Incident Resolved', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: { + id: '01DEN1HNLBC1VITK192ETJ1MPJ', + event_type: 'incident.resolved', + resource_type: 'incident', + occurred_at: '2022-12-07T11:04:27.459Z', + agent: { + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + summary: 'rudder test', + type: 'user_reference', + }, + client: null, + data: { + id: 'Q3S7IX2U5KTCOY', + type: 'incident', + self: 'https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + number: 2, + status: 'resolved', + incident_key: 'faaecfc0aca04b6ea07154188b5d3c6c', + created_at: '2022-12-07T10:56:52Z', + title: 'Server Crashed', + service: { + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + summary: 'Database', + type: 'service_reference', + }, + assignees: [], + escalation_policy: { + html_url: 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + summary: 'Default', + type: 'escalation_policy_reference', + }, + teams: [], + priority: { + html_url: 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + id: 'P5DBC3A', + self: 'https://api.pagerduty.com/priorities/P5DBC3A', + summary: 'P3', + type: 'priority_reference', + }, + urgency: 'high', + conference_bridge: { conference_number: '', conference_url: '' }, + resolve_reason: null, + }, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'track', + event: 'Incident Resolved', + userId: 'PXZZD2E', + context: { + traits: { + id: 'PXZZD2E', + self: 'https://api.pagerduty.com/users/user@1', + type: 'user_reference', + summary: 'rudder test', + html_url: 'https://rudderlabs-com.pagerduty.com/users/PXZZD2E', + }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'PagerDuty' }, + }, + messageId: '01DEN1HNLBC1VITK192ETJ1MPJ', + properties: { + data: { + id: 'Q3S7IX2U5KTCOY', + self: 'https://api.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + type: 'incident', + teams: [], + title: 'Server Crashed', + number: 2, + status: 'resolved', + service: { + id: 'PAJBUTT', + self: 'https://api.pagerduty.com/services/PAJBUTT', + type: 'service_reference', + summary: 'Database', + html_url: 'https://rudderlabs-com.pagerduty.com/services/PAJBUTT', + }, + urgency: 'high', + html_url: 'https://rudderlabs-com.pagerduty.com/incidents/Q3S7IX2U5KTCOY', + priority: { + id: 'P5DBC3A', + self: 'https://api.pagerduty.com/priorities/P5DBC3A', + type: 'priority_reference', + summary: 'P3', + html_url: + 'https://rudderlabs-com.pagerduty.com/account/incident_priorities', + }, + assignees: [], + created_at: '2022-12-07T10:56:52Z', + incident_key: 'faaecfc0aca04b6ea07154188b5d3c6c', + resolve_reason: null, + conference_bridge: { conference_url: '', conference_number: '' }, + escalation_policy: { + id: 'PB7HKU4', + self: 'https://api.pagerduty.com/escalation_policies/PB7HKU4', + type: 'escalation_policy_reference', + summary: 'Default', + html_url: + 'https://rudderlabs-com.pagerduty.com/escalation_policies/PB7HKU4', + }, + }, + resourceType: 'incident', + }, + integrations: { PagerDuty: false }, + originalTimestamp: '2022-12-07T11:04:27.000Z', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/pipedream/data.ts b/test/integrations/sources/pipedream/data.ts new file mode 100644 index 0000000000..a4b5c33e0d --- /dev/null +++ b/test/integrations/sources/pipedream/data.ts @@ -0,0 +1,350 @@ +export const data = [ + { + name: 'pipedream', + description: 'No type or userId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + anonymousId: '63767499ca6fb1b7c988d5bb', + artist: 'Gautam', + genre: 'Jazz', + song: 'Take Five', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + event: 'pipedream_source_event', + anonymousId: '63767499ca6fb1b7c988d5bb', + context: { + integration: { name: 'PIPEDREAM' }, + library: { name: 'unknown', version: 'unknown' }, + }, + integrations: { PIPEDREAM: false }, + type: 'track', + properties: { + anonymousId: '63767499ca6fb1b7c988d5bb', + artist: 'Gautam', + genre: 'Jazz', + song: 'Take Five', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pipedream', + description: 'No type or anonymousId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [{ userId: '12', artist: 'Gautam', genre: 'Jazz', song: 'Take Five' }], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + event: 'pipedream_source_event', + anonymousId: '12', + context: { + integration: { name: 'PIPEDREAM' }, + library: { name: 'unknown', version: 'unknown' }, + }, + integrations: { PIPEDREAM: false }, + type: 'track', + properties: { userId: '12', artist: 'Gautam', genre: 'Jazz', song: 'Take Five' }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pipedream', + description: 'Track Call -> type and userId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + event: 'Song Played', + userId: 'R1234', + context: { + library: { name: 'unknown', version: 'unknown' }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + userDeleted: false, + }, + locale: 'en', + location: { country: 'IN', countryName: 'India', short: 'India', long: 'India' }, + device: { os: 'macOS', type: 'desktop' }, + page: { referrer: 'http://127.0.0.1:5500/testSm.html' }, + }, + type: 'track', + properties: { artist: 'John', Album: 'ABCD' }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + event: 'Song Played', + userId: 'R1234', + context: { + library: { name: 'unknown', version: 'unknown' }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + userDeleted: false, + }, + locale: 'en', + location: { + country: 'IN', + countryName: 'India', + short: 'India', + long: 'India', + }, + device: { os: 'macOS', type: 'desktop' }, + page: { referrer: 'http://127.0.0.1:5500/testSm.html' }, + }, + type: 'track', + properties: { artist: 'John', Album: 'ABCD' }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pipedream', + description: 'Identify type -> type and userId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + userId: '1', + originalTimestamp: '2020-09-28T19:53:31.900Z', + traits: { + firstName: 'John', + lastName: 'doe', + email: 'John@r.com', + hasPurchased: 'yes', + address: { Home: { city: 'iudcb' }, Office: { abc: 'jbc' } }, + state: 'Delhi', + title: 'Mr', + }, + timestamp: '2020-09-29T14:50:29.907+05:30', + type: 'identify', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: '1', + originalTimestamp: '2020-09-28T19:53:31.900Z', + context: {}, + traits: { + firstName: 'John', + lastName: 'doe', + email: 'John@r.com', + hasPurchased: 'yes', + address: { Home: { city: 'iudcb' }, Office: { abc: 'jbc' } }, + state: 'Delhi', + title: 'Mr', + }, + timestamp: '2020-09-29T14:50:29.907+05:30', + type: 'identify', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pipedream', + description: 'Group type -> type and userId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + userId: 'user123', + groupId: '17', + context: {}, + traits: { operation: 'add' }, + type: 'group', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + userId: 'user123', + groupId: '17', + context: {}, + traits: { operation: 'add' }, + type: 'group', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pipedream', + description: 'Page type -> type and userId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + anonymousId: '21e13f4bc7ceddad', + channel: 'mobile', + context: { + os: { name: 'Android', version: '9' }, + timezone: 'Asia/Kolkata', + traits: { customProp: 'customValue' }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + name: 'Home', + properties: { title: 'Home | RudderStack', url: 'http://www.rudderstack.com' }, + receivedAt: '2020-09-29T14:50:43.005+05:30', + type: 'page', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + anonymousId: '21e13f4bc7ceddad', + channel: 'mobile', + context: { + os: { name: 'Android', version: '9' }, + timezone: 'Asia/Kolkata', + traits: { customProp: 'customValue' }, + userAgent: + 'Dalvik/2.1.0 (Linux; U; Android 9; AOSP on IA Emulator Build/PSR1.180720.117)', + }, + name: 'Home', + properties: { title: 'Home | RudderStack', url: 'http://www.rudderstack.com' }, + receivedAt: '2020-09-29T14:50:43.005+05:30', + type: 'page', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'pipedream', + description: 'Alias type -> type and userId is given', + module: 'source', + version: 'v0', + input: { + request: { + body: [{ type: 'alias', previousId: 'name@surname.com', userId: '12345' }], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { type: 'alias', previousId: 'name@surname.com', userId: '12345', context: {} }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/refiner/data.ts b/test/integrations/sources/refiner/data.ts new file mode 100644 index 0000000000..255004322c --- /dev/null +++ b/test/integrations/sources/refiner/data.ts @@ -0,0 +1,391 @@ +export const data = [ + { + name: 'refiner', + description: 'Refiner webhook response', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + uuid: 'd769e130-49cf-11ed-968d-936a69fadf81', + project_uuid: '0d8759d0-401c-11ed-8ded-9757c4929b55', + remote_id: 'user@17', + email: 'test17@user.com', + display_name: 'test user', + first_seen_at: '2022-10-12T01:47:33.000000Z', + last_seen_at: '2022-10-12T02:00:00.000000Z', + attributes: { + address: null, + address_city: null, + address_state: null, + age: null, + another_attribute: null, + city: null, + country: null, + created_at: null, + email: 'test17@user.com', + event: null, + first_name: null, + first_seen_at: '2022-10-12T01:47:33.000000Z', + form_submissions_count: '1', + form_views_count: '2', + gender: null, + last_form_submission_at: '2022-10-12T02:05:55.000000Z', + last_form_view_at: '2022-10-12T02:03:46.000000Z', + last_name: null, + last_seen_at: '2022-10-12T02:00:00.000000Z', + name: 'test user', + phone: null, + some_attribute: null, + status: null, + student: null, + tag: null, + trait1: null, + trait2: null, + trait3: null, + url: null, + user_address_city: null, + user_address_state: null, + user_country: null, + user_id: null, + username: null, + useroccupation: null, + why_did_you_cancel_your_subscription: 'Pricing', + }, + segments: [ + { + uuid: '0d91d7a0-401c-11ed-8898-bb1ee0c23ae5', + name: 'All Users', + created_at: '2022-10-12T01:47:34.000000Z', + updated_at: '2022-10-12T01:47:34.000000Z', + }, + { + uuid: 'f71ad940-455c-11ed-85e0-bf25f168b224', + name: 'test-segment', + created_at: '2022-10-12T01:47:34.000000Z', + updated_at: '2022-10-12T01:47:34.000000Z', + }, + ], + account: { + uuid: 'd76c9e80-49cf-11ed-a783-6317eca951a6', + remote_id: 'ACCOUNT-ID-ABC-1', + domain: null, + display_name: 'Awesome Inc.', + first_seen_at: '2022-10-12T01:47:33.000000Z', + last_seen_at: '2022-10-12T02:00:00.000000Z', + attributes: { + a_date_at: '2022-10-01T00:00:00.000000Z', + business_email: null, + company: null, + email: null, + isfunded: null, + name: 'Awesome Inc.', + revenue: null, + some_account_data: 'something', + trait1: null, + trait2: null, + trait3: null, + }, + }, + triggered_event: 'Completed Survey', + form: { uuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', name: 'Customer Churn Survey' }, + response: { + uuid: 'eb117cb0-49cf-11ed-b050-03a44b32151c', + first_shown_at: '2022-10-12T01:48:06.000000Z', + last_shown_at: '2022-10-12T02:03:46.000000Z', + show_counter: null, + first_data_reception_at: '2022-10-12T02:05:55.000000Z', + last_data_reception_at: '2022-10-12T02:05:55.000000Z', + completed_at: '2022-10-12T02:05:55.000000Z', + dismissed_at: null, + received_at: '2022-10-12T02:05:55.000000Z', + data: { why_did_you_cancel_your_subscription: 'Pricing' }, + tags: [], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + traits: { + email: 'test17@user.com', + segments: [ + { + name: 'All Users', + uuid: '0d91d7a0-401c-11ed-8898-bb1ee0c23ae5', + created_at: '2022-10-12T01:47:34.000000Z', + updated_at: '2022-10-12T01:47:34.000000Z', + }, + { + name: 'test-segment', + uuid: 'f71ad940-455c-11ed-85e0-bf25f168b224', + created_at: '2022-10-12T01:47:34.000000Z', + updated_at: '2022-10-12T01:47:34.000000Z', + }, + ], + }, + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Refiner' }, + formUuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', + formName: 'Customer Churn Survey', + }, + integrations: { Refiner: false }, + type: 'identify', + userId: 'user@17', + traits: { why_did_you_cancel_your_subscription: 'Pricing' }, + originalTimestamp: '2022-10-12T02:05:55.000000Z', + }, + { + type: 'track', + event: 'Completed Survey', + userId: 'user@17', + context: { + library: { name: 'unknown', version: 'unknown' }, + formName: 'Customer Churn Survey', + formUuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', + integration: { name: 'Refiner' }, + }, + properties: { + response: { + data: { why_did_you_cancel_your_subscription: 'Pricing' }, + tags: [], + uuid: 'eb117cb0-49cf-11ed-b050-03a44b32151c', + received_at: '2022-10-12T02:05:55.000000Z', + completed_at: '2022-10-12T02:05:55.000000Z', + last_shown_at: '2022-10-12T02:03:46.000000Z', + first_shown_at: '2022-10-12T01:48:06.000000Z', + last_data_reception_at: '2022-10-12T02:05:55.000000Z', + first_data_reception_at: '2022-10-12T02:05:55.000000Z', + }, + refiner_form_name: 'Customer Churn Survey', + refiner_form_uuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', + }, + integrations: { Refiner: false }, + originalTimestamp: '2022-10-12T02:05:55.000000Z', + }, + { + type: 'group', + traits: { + name: 'Awesome Inc.', + a_date_at: '2022-10-01T00:00:00.000000Z', + some_account_data: 'something', + }, + userId: 'user@17', + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Refiner' }, + }, + groupId: 'ACCOUNT-ID-ABC-1', + integrations: { Refiner: false }, + originalTimestamp: '2022-10-12T02:05:55.000000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'refiner', + description: 'Refiner webhook response', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + uuid: '69b83e20-4ea2-11ed-941c-e1cb6c7a3870', + cookie_uuid: '2f9b7e6a-9ba8-1c68-d474-48d719d92a60', + project_uuid: '0d8759d0-401c-11ed-8ded-9757c4929b55', + remote_id: 'sdk@30', + email: 'sdk30@gmail.com', + display_name: '', + first_seen_at: '2022-10-18T05:04:58.000000Z', + last_seen_at: '2022-10-18T05:04:58.000000Z', + attributes: { + address: null, + address_city: null, + address_state: null, + age: null, + another_attribute: null, + city: null, + country: null, + created_at: null, + email: 'sdk30@gmail.com', + event: null, + first_name: null, + first_seen_at: '2022-10-18T05:04:58.000000Z', + form_submissions_count: '1', + form_views_count: '1', + gender: null, + last_form_submission_at: '2022-10-18T05:05:45.000000Z', + last_form_view_at: '2022-10-18T05:05:29.000000Z', + last_name: null, + last_seen_at: '2022-10-18T05:04:58.000000Z', + name: null, + phone: null, + some_attribute: null, + status: null, + student: null, + tag: null, + trait1: null, + trait2: null, + trait3: null, + url: null, + user_address_city: null, + user_address_state: null, + user_country: null, + user_id: null, + username: null, + useroccupation: null, + why_did_you_cancel_your_subscription: 'Missing features', + }, + segments: [ + { + uuid: '0d91d7a0-401c-11ed-8898-bb1ee0c23ae5', + name: 'All Users', + created_at: '2022-10-18T05:04:58.000000Z', + updated_at: '2022-10-18T05:04:58.000000Z', + }, + { + uuid: 'f71ad940-455c-11ed-85e0-bf25f168b224', + name: 'test-segment', + created_at: '2022-10-18T05:04:58.000000Z', + updated_at: '2022-10-18T05:04:58.000000Z', + }, + ], + account: { + uuid: '69ba2030-4ea2-11ed-adfc-595e70c7ab07', + remote_id: null, + domain: null, + display_name: '', + first_seen_at: '2022-10-18T05:04:58.000000Z', + last_seen_at: '2022-10-18T05:04:58.000000Z', + attributes: { + '1': null, + '2': null, + '3': null, + '4': null, + a_date_at: null, + business_email: null, + company: null, + email: null, + isfunded: null, + location: null, + name: null, + revenue: null, + some_account_data: null, + trait1: null, + trait2: null, + trait3: null, + user_id: null, + }, + }, + triggered_event: 'Completed Survey', + form: { uuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', name: 'Customer Churn Survey' }, + response: { + uuid: '7c508c60-4ea2-11ed-9302-57708fe11d26', + first_shown_at: '2022-10-18T05:05:29.000000Z', + last_shown_at: '2022-10-18T05:05:29.000000Z', + show_counter: null, + first_data_reception_at: '2022-10-18T05:05:45.000000Z', + last_data_reception_at: '2022-10-18T05:05:45.000000Z', + completed_at: '2022-10-18T05:05:45.000000Z', + dismissed_at: null, + received_at: '2022-10-18T05:05:45.000000Z', + data: { why_did_you_cancel_your_subscription: 'Missing features' }, + tags: [], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + type: 'identify', + traits: { why_did_you_cancel_your_subscription: 'Missing features' }, + userId: 'sdk@30', + context: { + traits: { + email: 'sdk30@gmail.com', + segments: [ + { + name: 'All Users', + uuid: '0d91d7a0-401c-11ed-8898-bb1ee0c23ae5', + created_at: '2022-10-18T05:04:58.000000Z', + updated_at: '2022-10-18T05:04:58.000000Z', + }, + { + name: 'test-segment', + uuid: 'f71ad940-455c-11ed-85e0-bf25f168b224', + created_at: '2022-10-18T05:04:58.000000Z', + updated_at: '2022-10-18T05:04:58.000000Z', + }, + ], + }, + library: { name: 'unknown', version: 'unknown' }, + formName: 'Customer Churn Survey', + formUuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', + integration: { name: 'Refiner' }, + }, + integrations: { Refiner: false }, + originalTimestamp: '2022-10-18T05:05:45.000000Z', + }, + { + type: 'track', + event: 'Completed Survey', + userId: 'sdk@30', + context: { + library: { name: 'unknown', version: 'unknown' }, + formName: 'Customer Churn Survey', + formUuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', + integration: { name: 'Refiner' }, + }, + properties: { + response: { + data: { why_did_you_cancel_your_subscription: 'Missing features' }, + tags: [], + uuid: '7c508c60-4ea2-11ed-9302-57708fe11d26', + received_at: '2022-10-18T05:05:45.000000Z', + completed_at: '2022-10-18T05:05:45.000000Z', + last_shown_at: '2022-10-18T05:05:29.000000Z', + first_shown_at: '2022-10-18T05:05:29.000000Z', + last_data_reception_at: '2022-10-18T05:05:45.000000Z', + first_data_reception_at: '2022-10-18T05:05:45.000000Z', + }, + refiner_form_name: 'Customer Churn Survey', + refiner_form_uuid: '0d94c790-401c-11ed-bb27-e31f6832c5ae', + }, + integrations: { Refiner: false }, + originalTimestamp: '2022-10-18T05:05:45.000000Z', + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/satismeter/data.ts b/test/integrations/sources/satismeter/data.ts new file mode 100644 index 0000000000..713f527f2c --- /dev/null +++ b/test/integrations/sources/satismeter/data.ts @@ -0,0 +1,426 @@ +export const data = [ + { + name: 'satismeter', + description: ' All fields Check with event as completed', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + response: { + id: '63767499ca6fb1b7c988d5bb', + created: '2022-11-17T17:51:21.764Z', + rating: 5, + feedback: 'Many things to imporve\n', + dismissed: false, + pending: false, + answers: [ + { + label: 'How likely are you to recommend us to your friends and colleagues?', + id: '7ddb22b0-64a8-11ed-a4c7-b3bed73771cd', + value: 5, + name: 'SM_rating', + type: 'scale', + metric: 'nps', + }, + { + label: 'What could we do to improve?', + id: '7ddb22b1-64a8-11ed-a4c7-b3bed73771cd', + value: 'Many things to imporve\n', + name: 'SM_comment', + type: 'long-text', + }, + { + label: 'The company made it easy for me to handle my issue.', + id: '1dc53f60-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'scale', + metric: 'ces', + }, + { + label: 'How satisfied were you with the service you received?', + id: '24c5b290-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'smiley', + metric: 'csat', + }, + { + label: 'How you like to rate the surevy?', + id: '27b3d1d0-66a0-11ed-856c-6f39711bf041', + value: 4, + type: 'scale', + }, + { + label: 'Your Name (Single Answer)', + id: '37a8c000-66a0-11ed-856c-6f39711bf041', + value: 'a', + type: 'single-choice', + }, + { + label: 'Your Name (Multiple Answer)', + id: '4b435da0-66a0-11ed-856c-6f39711bf041', + value: ['a1', 'b1'], + type: 'multiple-choice', + }, + ], + category: 'detractor', + score: -100, + user: { + id: '63766fbb7ac7b72676145338', + name: 'John Doe', + email: 'john@doe.com', + userId: 'No response', + deleted: false, + groups: { group1: 'grooupId' }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + }, + }, + device: { os: 'macOS', type: 'desktop' }, + location: { + country: 'IN', + countryName: 'India', + region: '', + city: '', + short: 'India', + long: 'India', + }, + referrer: 'http://127.0.0.1:5500/testSm.html', + method: 'In-app', + language: 'en', + project: '6372247a764986ebee62bf66', + campaign: '6373271b764986ebee62bfca', + }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + }, + campaign: { id: '6373271b764986ebee62bfca', name: 'NPS Survey' }, + event: 'completed', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + event: 'Survey completed', + anonymousId: '63766fbb7ac7b72676145338', + context: { + library: { name: 'unknown', version: 'unknown' }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + userDeleted: false, + }, + locale: 'en', + campaign: { id: '6373271b764986ebee62bfca', name: 'NPS Survey' }, + integration: { name: 'SATISMETER' }, + location: { + country: 'IN', + countryName: 'India', + short: 'India', + long: 'India', + }, + device: { os: 'macOS', type: 'desktop' }, + page: { referrer: 'http://127.0.0.1:5500/testSm.html' }, + }, + integrations: { SATISMETER: false }, + type: 'track', + traits: { groups: { group1: 'grooupId' } }, + userId: 'No response', + properties: { + category: 'detractor', + answers: [ + { + label: 'How likely are you to recommend us to your friends and colleagues?', + id: '7ddb22b0-64a8-11ed-a4c7-b3bed73771cd', + value: 5, + name: 'SM_rating', + type: 'scale', + metric: 'nps', + }, + { + label: 'What could we do to improve?', + id: '7ddb22b1-64a8-11ed-a4c7-b3bed73771cd', + value: 'Many things to imporve\n', + name: 'SM_comment', + type: 'long-text', + }, + { + label: 'The company made it easy for me to handle my issue.', + id: '1dc53f60-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'scale', + metric: 'ces', + }, + { + label: 'How satisfied were you with the service you received?', + id: '24c5b290-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'smiley', + metric: 'csat', + }, + { + label: 'How you like to rate the surevy?', + id: '27b3d1d0-66a0-11ed-856c-6f39711bf041', + value: 4, + type: 'scale', + }, + { + label: 'Your Name (Single Answer)', + id: '37a8c000-66a0-11ed-856c-6f39711bf041', + value: 'a', + type: 'single-choice', + }, + { + label: 'Your Name (Multiple Answer)', + id: '4b435da0-66a0-11ed-856c-6f39711bf041', + value: ['a1', 'b1'], + type: 'multiple-choice', + }, + ], + surveyDismissed: false, + surveyPending: false, + receivedAt: '2022-11-17T17:51:21.764Z', + }, + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'satismeter', + description: + ' Neither reponse.user.id or response.user.userId is provided in payload then mapping response.id to anonymousId', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + response: { + id: '63767499ca6fb1b7c988d5bb', + created: '2022-11-17T17:51:21.764Z', + rating: 5, + feedback: 'Many things to imporve\n', + dismissed: false, + pending: false, + answers: [ + { + label: 'How likely are you to recommend us to your friends and colleagues?', + id: '7ddb22b0-64a8-11ed-a4c7-b3bed73771cd', + value: 5, + name: 'SM_rating', + type: 'scale', + metric: 'nps', + }, + { + label: 'What could we do to improve?', + id: '7ddb22b1-64a8-11ed-a4c7-b3bed73771cd', + value: 'Many things to imporve\n', + name: 'SM_comment', + type: 'long-text', + }, + { + label: 'The company made it easy for me to handle my issue.', + id: '1dc53f60-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'scale', + metric: 'ces', + }, + { + label: 'How satisfied were you with the service you received?', + id: '24c5b290-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'smiley', + metric: 'csat', + }, + { + label: 'How you like to rate the surevy?', + id: '27b3d1d0-66a0-11ed-856c-6f39711bf041', + value: 4, + type: 'scale', + }, + { + label: 'Your Name (Single Answer)', + id: '37a8c000-66a0-11ed-856c-6f39711bf041', + value: 'a', + type: 'single-choice', + }, + { + label: 'Your Name (Multiple Answer)', + id: '4b435da0-66a0-11ed-856c-6f39711bf041', + value: ['a1', 'b1'], + type: 'multiple-choice', + }, + ], + category: 'detractor', + score: -100, + user: { + name: 'John Doe', + email: 'john@doe.com', + deleted: false, + groups: { group1: 'grooupId' }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + }, + }, + device: { os: 'macOS', type: 'desktop' }, + location: { + country: 'IN', + countryName: 'India', + region: '', + city: '', + short: 'India', + long: 'India', + }, + referrer: 'http://127.0.0.1:5500/testSm.html', + method: 'In-app', + language: 'en', + project: '6372247a764986ebee62bf66', + campaign: '6373271b764986ebee62bfca', + }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + }, + campaign: { id: '6373271b764986ebee62bfca', name: 'NPS Survey' }, + event: 'completed', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + event: 'Survey completed', + anonymousId: '63767499ca6fb1b7c988d5bb', + context: { + library: { name: 'unknown', version: 'unknown' }, + traits: { + createdAt: '2022-10-15T05:41:06.016Z', + custom: { key1: 'v1', key2: 'V2' }, + email: 'john@doe.com', + name: 'John Doe', + userDeleted: false, + }, + locale: 'en', + campaign: { id: '6373271b764986ebee62bfca', name: 'NPS Survey' }, + integration: { name: 'SATISMETER' }, + location: { + country: 'IN', + countryName: 'India', + short: 'India', + long: 'India', + }, + device: { os: 'macOS', type: 'desktop' }, + page: { referrer: 'http://127.0.0.1:5500/testSm.html' }, + }, + integrations: { SATISMETER: false }, + type: 'track', + traits: { groups: { group1: 'grooupId' } }, + properties: { + category: 'detractor', + answers: [ + { + label: 'How likely are you to recommend us to your friends and colleagues?', + id: '7ddb22b0-64a8-11ed-a4c7-b3bed73771cd', + value: 5, + name: 'SM_rating', + type: 'scale', + metric: 'nps', + }, + { + label: 'What could we do to improve?', + id: '7ddb22b1-64a8-11ed-a4c7-b3bed73771cd', + value: 'Many things to imporve\n', + name: 'SM_comment', + type: 'long-text', + }, + { + label: 'The company made it easy for me to handle my issue.', + id: '1dc53f60-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'scale', + metric: 'ces', + }, + { + label: 'How satisfied were you with the service you received?', + id: '24c5b290-66a0-11ed-856c-6f39711bf041', + value: 4, + name: null, + type: 'smiley', + metric: 'csat', + }, + { + label: 'How you like to rate the surevy?', + id: '27b3d1d0-66a0-11ed-856c-6f39711bf041', + value: 4, + type: 'scale', + }, + { + label: 'Your Name (Single Answer)', + id: '37a8c000-66a0-11ed-856c-6f39711bf041', + value: 'a', + type: 'single-choice', + }, + { + label: 'Your Name (Multiple Answer)', + id: '4b435da0-66a0-11ed-856c-6f39711bf041', + value: ['a1', 'b1'], + type: 'multiple-choice', + }, + ], + surveyDismissed: false, + surveyPending: false, + receivedAt: '2022-11-17T17:51:21.764Z', + }, + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/segment/data.ts b/test/integrations/sources/segment/data.ts new file mode 100644 index 0000000000..780a65c119 --- /dev/null +++ b/test/integrations/sources/segment/data.ts @@ -0,0 +1,245 @@ +import utils from '../../../../src/v0/util'; +import { SrcTestCaseData } from '../../testTypes'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data: SrcTestCaseData[] = [ + { + name: 'segment', + description: 'test-0', + module: 'source', + version: 'v0', + skipGo: 'NoAnonID error', + input: { + request: { + body: [ + { + date: '2020-07-10T07:43:07.766Z', + type: 's', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + user_agent: 'Chrome Mobile 69.0.3497 / Android 0.0.0', + details: { + prompts: [], + completedAt: 1594366987765, + elapsedTime: null, + session_id: '**************_***************', + }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { name: 'Auth0.Android', env: { android: '28' }, version: '1.23.0' }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: true, + }, + { + date: '2020-07-10T07:43:09.620Z', + type: 'seacft', + description: '', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + user_agent: 'okhttp 2.7.5 / Other 0.0.0', + details: { code: '*************Xst' }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { name: 'Auth0.Android', env: { android: '28' }, version: '1.23.0' }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: false, + }, + { + date: '2020-07-10T07:43:07.766Z', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + user_agent: 'Chrome Mobile 69.0.3497 / Android 0.0.0', + details: { + prompts: [], + completedAt: 1594366987765, + elapsedTime: null, + session_id: '**************_***************', + }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { name: 'Auth0.Android', env: { android: '28' }, version: '1.23.0' }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: true, + }, + { + type: 's', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + user_agent: 'Chrome Mobile 69.0.3497 / Android 0.0.0', + details: { + prompts: [], + completedAt: 1594366987765, + elapsedTime: null, + session_id: '**************_***************', + }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { name: 'Auth0.Android', env: { android: '28' }, version: '1.23.0' }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: true, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + date: '2020-07-10T07:43:07.766Z', + type: 's', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + user_agent: 'Chrome Mobile 69.0.3497 / Android 0.0.0', + details: { + prompts: [], + completedAt: 1594366987765, + elapsedTime: null, + session_id: '**************_***************', + }, + context: {}, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { + name: 'Auth0.Android', + env: { android: '28' }, + version: '1.23.0', + }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: true, + }, + ], + }, + }, + { + output: { + batch: [ + { + date: '2020-07-10T07:43:09.620Z', + type: 'seacft', + context: {}, + description: '', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + user_agent: 'okhttp 2.7.5 / Other 0.0.0', + details: { code: '*************Xst' }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { + name: 'Auth0.Android', + env: { android: '28' }, + version: '1.23.0', + }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: false, + }, + ], + }, + }, + { + output: { + batch: [ + { + date: '2020-07-10T07:43:07.766Z', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + context: {}, + user_agent: 'Chrome Mobile 69.0.3497 / Android 0.0.0', + details: { + prompts: [], + completedAt: 1594366987765, + elapsedTime: null, + session_id: '**************_***************', + }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { + name: 'Auth0.Android', + env: { android: '28' }, + version: '1.23.0', + }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: true, + }, + ], + }, + }, + { + output: { + batch: [ + { + type: 's', + connection_id: '', + client_id: '********************************', + client_name: 'My App', + ip: '47.15.6.58', + context: {}, + user_agent: 'Chrome Mobile 69.0.3497 / Android 0.0.0', + details: { + prompts: [], + completedAt: 1594366987765, + elapsedTime: null, + session_id: '**************_***************', + }, + hostname: '************.us.auth0.com', + user_id: 'auth0|************************', + user_name: 'example@test.com', + auth0_client: { + name: 'Auth0.Android', + env: { android: '28' }, + version: '1.23.0', + }, + log_id: '********************************************************', + _id: '********************************************************', + isMobile: true, + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns(_) { + defaultMockFns(); + }, +})); diff --git a/test/integrations/sources/shopify/data.ts b/test/integrations/sources/shopify/data.ts new file mode 100644 index 0000000000..f5eb3c148b --- /dev/null +++ b/test/integrations/sources/shopify/data.ts @@ -0,0 +1,609 @@ +import { skip } from 'node:test'; + +export const data = [ + { + name: 'shopify', + description: 'Track Call -> carts_create ', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + id: 'shopify_test3', + query_parameters: { topic: ['carts_create'] }, + token: 'shopify_test3', + line_items: [], + note: null, + updated_at: '2023-02-10T12:16:07.251Z', + created_at: '2023-02-10T12:05:04.402Z', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [{ outputToSource: { body: 'T0s=', contentType: 'text/plain' }, statusCode: 200 }], + }, + }, + }, + { + name: 'shopify', + description: 'No Query Parameters', + module: 'source', + version: 'v0', + skipGo: 'not possible', + input: { + request: { body: [{}], method: 'POST', headers: { 'Content-Type': 'application/json' } }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Query_parameters is missing', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'shopify', + description: 'Invalid topic', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { query_parameters: { signature: ['rudderstack'], writeKey: ['sample-write-key'] } }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Invalid topic in query_parameters', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'shopify', + description: 'Topic Not found', + module: 'source', + version: 'v0', + skipGo: 'not possible', + input: { + request: { + body: [ + { + query_parameters: { + topic: [], + signature: ['rudderstack'], + writeKey: ['sample-write-key'], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + error: 'Topic not found', + statTags: { + destinationId: 'Non determinable', + errorCategory: 'transformation', + implementation: 'native', + module: 'source', + workspaceId: 'Non determinable', + }, + statusCode: 400, + }, + ], + }, + }, + }, + { + name: 'shopify', + description: 'Unsupported Event Type', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + query_parameters: { + topic: ['random_event'], + signature: ['rudderstack'], + writeKey: ['sample-write-key'], + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [{ outputToSource: { body: 'T0s=', contentType: 'text/plain' }, statusCode: 200 }], + }, + }, + }, + { + name: 'shopify', + description: 'Identify Call for customers create event', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + query_parameters: { + topic: ['customers_create'], + signature: ['rudderstack'], + writeKey: ['sample-write-key'], + }, + id: 5747017285820, + email: 'anuraj@rudderstack.com', + accepts_marketing: false, + created_at: '2021-12-29T15:15:19+05:30', + updated_at: '2021-12-29T15:15:20+05:30', + first_name: 'Anuraj', + last_name: 'Guha', + orders_count: 0, + state: 'disabled', + total_spent: '0.00', + last_order_id: null, + note: '', + verified_email: true, + multipass_identifier: null, + tax_exempt: false, + phone: '+919876543210', + tags: '', + last_order_name: null, + currency: 'INR', + addresses: [ + { + id: 6947581821116, + customer_id: 5747017285820, + first_name: 'Anuraj', + last_name: 'Guha', + company: 'Rudderstack', + address1: 'Home', + address2: 'Apartment', + city: 'Kolkata', + province: 'West Bengal', + country: 'India', + zip: '708091', + phone: '+919876543210', + name: 'Anuraj Guha', + province_code: 'WB', + country_code: 'IN', + country_name: 'India', + default: true, + }, + ], + accepts_marketing_updated_at: '2021-12-29T15:15:20+05:30', + marketing_opt_in_level: null, + tax_exemptions: [], + sms_marketing_consent: { + state: 'not_subscribed', + opt_in_level: 'single_opt_in', + consent_updated_at: null, + consent_collected_from: 'SHOPIFY', + }, + admin_graphql_api_id: 'gid://shopify/Customer/5747017285820', + default_address: { + id: 6947581821116, + customer_id: 5747017285820, + first_name: 'Anuraj', + last_name: 'Guha', + company: 'Rudderstack', + address1: 'Home', + address2: 'Apartment', + city: 'Kolkata', + province: 'West Bengal', + country: 'India', + zip: '708091', + phone: '+919876543210', + name: 'Anuraj Guha', + province_code: 'WB', + country_code: 'IN', + country_name: 'India', + default: true, + }, + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'RudderStack Shopify Cloud', version: '1.0.0' }, + integration: { name: 'SHOPIFY' }, + topic: 'customers_create', + }, + integrations: { SHOPIFY: true }, + type: 'identify', + userId: '5747017285820', + traits: { + email: 'anuraj@rudderstack.com', + firstName: 'Anuraj', + lastName: 'Guha', + phone: '+919876543210', + addressList: [ + { + id: 6947581821116, + customer_id: 5747017285820, + first_name: 'Anuraj', + last_name: 'Guha', + company: 'Rudderstack', + address1: 'Home', + address2: 'Apartment', + city: 'Kolkata', + province: 'West Bengal', + country: 'India', + zip: '708091', + phone: '+919876543210', + name: 'Anuraj Guha', + province_code: 'WB', + country_code: 'IN', + country_name: 'India', + default: true, + }, + ], + address: { + id: 6947581821116, + customer_id: 5747017285820, + first_name: 'Anuraj', + last_name: 'Guha', + company: 'Rudderstack', + address1: 'Home', + address2: 'Apartment', + city: 'Kolkata', + province: 'West Bengal', + country: 'India', + zip: '708091', + phone: '+919876543210', + name: 'Anuraj Guha', + province_code: 'WB', + country_code: 'IN', + country_name: 'India', + default: true, + }, + acceptsMarketing: false, + orderCount: 0, + state: 'disabled', + totalSpent: '0.00', + note: '', + verifiedEmail: true, + taxExempt: false, + tags: '', + currency: 'INR', + taxExemptions: [], + smsMarketingConsent: { + state: 'not_subscribed', + opt_in_level: 'single_opt_in', + consent_updated_at: null, + consent_collected_from: 'SHOPIFY', + }, + adminGraphqlApiId: 'gid://shopify/Customer/5747017285820', + acceptsMarketingUpdatedAt: '2021-12-29T15:15:20+05:30', + }, + timestamp: '2021-12-29T09:45:20.000Z', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'shopify', + description: 'Unsupported checkout event', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + query_parameters: { + topic: ['checkout_delete'], + writeKey: ['sample-write-key'], + signature: ['rudderstack'], + }, + admin_graphql_api_id: 'gid://shopify/Fulfillment/4124667937024', + created_at: '2022-01-05T18:13:02+05:30', + destination: null, + id: 4124667937024, + line_items: [], + customer: { email: 'test_person@email.com', first_name: 'Test', last_name: 'Person' }, + billing_address: { address1: '11 Rani Sankari Lane Patuapara Bhowanipore' }, + shipping_address: { address1: '11 Rani Sankari Lane Patuapara Bhowanipore' }, + location_id: 66855371008, + name: '#1002.1', + order_id: 4617255092480, + origin_address: null, + receipt: {}, + service: 'manual', + shipment_status: null, + status: 'success', + tracking_company: 'Amazon Logistics UK', + tracking_number: 'Sample001test', + tracking_numbers: ['Sample001test'], + tracking_url: 'https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530', + tracking_urls: [ + 'https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530', + ], + updated_at: '2022-01-05T18:16:48+05:30', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [{ outputToSource: { body: 'T0s=', contentType: 'text/plain' }, statusCode: 200 }], + }, + }, + }, + { + name: 'shopify', + description: 'Track Call -> Fullfillments updated event', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + query_parameters: { + topic: ['fulfillments_update'], + writeKey: ['sample-write-key'], + signature: ['rudderstack'], + }, + shipping_address: { address1: '11 Rani Sankari Lane Patuapara Bhowanipore' }, + billing_address: { address1: '11 Rani Sankari Lane Patuapara Bhowanipore' }, + admin_graphql_api_id: 'gid://shopify/Fulfillment/4124667937024', + created_at: '2022-01-05T18:13:02+05:30', + destination: null, + email: 'test_person@email.com', + id: 4124667937024, + line_items: [ + { + admin_graphql_api_id: 'gid://shopify/LineItem/11896203149568', + discount_allocations: [], + duties: [], + fulfillable_quantity: 0, + fulfillment_service: 'manual', + fulfillment_status: 'fulfilled', + gift_card: false, + grams: 0, + id: 11896203149568, + name: 'p1', + origin_location: { + address1: '74 CC/7, Anupama Housing Estate - II', + address2: '', + city: 'Kolkatta', + country_code: 'IN', + id: 3373642219776, + name: '74 CC/7, Anupama Housing Estate - II', + province_code: 'WB', + zip: '700052', + }, + price: '5000.00', + price_set: { + presentment_money: { amount: '5000.00', currency_code: 'INR' }, + shop_money: { amount: '5000.00', currency_code: 'INR' }, + }, + product_exists: true, + product_id: 7510929801472, + properties: [], + quantity: 1, + requires_shipping: true, + sku: '15', + tax_lines: [ + { + channel_liable: false, + price: '900.00', + price_set: { + presentment_money: { amount: '900.00', currency_code: 'INR' }, + shop_money: { amount: '900.00', currency_code: 'INR' }, + }, + rate: 0.18, + title: 'IGST', + }, + ], + taxable: true, + title: 'p1', + total_discount: '0.00', + total_discount_set: { + presentment_money: { amount: '0.00', currency_code: 'INR' }, + shop_money: { amount: '0.00', currency_code: 'INR' }, + }, + variant_id: 42211160228096, + variant_inventory_management: 'shopify', + variant_title: '', + vendor: 'rudderstack-store', + }, + ], + location_id: 66855371008, + name: '#1002.1', + order_id: 4617255092480, + origin_address: null, + receipt: {}, + service: 'manual', + shipment_status: null, + status: 'success', + tracking_company: 'Amazon Logistics UK', + tracking_number: 'Sample001test', + tracking_numbers: ['Sample001test'], + tracking_url: 'https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530', + tracking_urls: [ + 'https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530', + ], + updated_at: '2022-01-05T18:16:48+05:30', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'RudderStack Shopify Cloud', version: '1.0.0' }, + integration: { name: 'SHOPIFY' }, + topic: 'fulfillments_update', + }, + integrations: { SHOPIFY: true }, + type: 'track', + userId: 'shopify-admin', + event: 'Fulfillments Update', + properties: { + admin_graphql_api_id: 'gid://shopify/Fulfillment/4124667937024', + created_at: '2022-01-05T18:13:02+05:30', + destination: null, + email: 'test_person@email.com', + id: 4124667937024, + location_id: 66855371008, + name: '#1002.1', + order_id: 4617255092480, + origin_address: null, + receipt: {}, + service: 'manual', + shipment_status: null, + status: 'success', + tracking_company: 'Amazon Logistics UK', + tracking_number: 'Sample001test', + tracking_numbers: ['Sample001test'], + tracking_url: + 'https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530', + tracking_urls: [ + 'https://www.amazon.co.uk/gp/help/customer/display.html?nodeId=201910530', + ], + updated_at: '2022-01-05T18:16:48+05:30', + products: [ + { + product_id: 7510929801472, + sku: '15', + title: 'p1', + price: '5000.00', + brand: 'rudderstack-store', + quantity: 1, + admin_graphql_api_id: 'gid://shopify/LineItem/11896203149568', + discount_allocations: [], + duties: [], + fulfillable_quantity: 0, + fulfillment_service: 'manual', + fulfillment_status: 'fulfilled', + gift_card: false, + grams: 0, + id: 11896203149568, + origin_location: { + address1: '74 CC/7, Anupama Housing Estate - II', + address2: '', + city: 'Kolkatta', + country_code: 'IN', + id: 3373642219776, + name: '74 CC/7, Anupama Housing Estate - II', + province_code: 'WB', + zip: '700052', + }, + price_set: { + presentment_money: { amount: '5000.00', currency_code: 'INR' }, + shop_money: { amount: '5000.00', currency_code: 'INR' }, + }, + product_exists: true, + properties: [], + requires_shipping: true, + tax_lines: [ + { + channel_liable: false, + price: '900.00', + price_set: { + presentment_money: { amount: '900.00', currency_code: 'INR' }, + shop_money: { amount: '900.00', currency_code: 'INR' }, + }, + rate: 0.18, + title: 'IGST', + }, + ], + taxable: true, + total_discount: '0.00', + total_discount_set: { + presentment_money: { amount: '0.00', currency_code: 'INR' }, + shop_money: { amount: '0.00', currency_code: 'INR' }, + }, + variant_inventory_management: 'shopify', + variant: '42211160228096 ', + }, + ], + }, + traits: { + shippingAddress: { address1: '11 Rani Sankari Lane Patuapara Bhowanipore' }, + billingAddress: { address1: '11 Rani Sankari Lane Patuapara Bhowanipore' }, + email: 'test_person@email.com', + }, + }, + ], + }, + }, + ], + }, + }, + }, +]; diff --git a/test/integrations/sources/signl4/data.ts b/test/integrations/sources/signl4/data.ts new file mode 100644 index 0000000000..b318bfb6df --- /dev/null +++ b/test/integrations/sources/signl4/data.ts @@ -0,0 +1,550 @@ +import utils from '../../../../src/v0/util'; + +const defaultMockFns = () => { + jest.spyOn(utils, 'generateUUID').mockReturnValue('97fcd7b2-cc24-47d7-b776-057b7b199513'); +}; + +export const data = [ + { + name: 'signl4', + description: 'test-0', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 200, + eventRaisedUtc: '2017-09-01T08:11:37.4815663Z', + subscription: { id: '0acf8014-22f2-4503-88d7-f7d05b46744f' }, + alert: { + statusCode: 1, + eventId: '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + externalEventId: 'INC091210', + id: '2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685', + }, + id: 'dd209a2d-e037-41ee-b37d-f605cc0a39fb', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'dd209a2d-e037-41ee-b37d-f605cc0a39fb', + originalTimestamp: '2017-09-01T08:11:37.000Z', + event: 'New Alert Created', + properties: { + eventType: 200, + 'subscription.id': '0acf8014-22f2-4503-88d7-f7d05b46744f', + 'alert.statusCode': 1, + 'alert.eventId': '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + 'alert.externalEventId': 'INC091210', + 'alert.id': '2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685', + }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-1', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 201, + eventRaisedUtc: '2017-09-01T08:11:37.4815663Z', + subscription: { id: '0acf8014-22f2-4503-88d7-f7d05b46744f' }, + user: { + username: 'Rene', + mailaddress: 'rene@signl4.com', + id: 'f0bd5063-9588-51cf-b3d9-94e5647dedc5', + }, + alert: { + statusCode: 2, + eventId: '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + externalEventId: 'Content you passed in the X-S4-ExternalID parameter', + acknowledgedUserIds: ['f0bd5063-9588-51cf-b3d9-94e5647dedc5'], + id: '2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685', + }, + id: 'dd209a2d-e037-41ee-b37d-f605cc0a39fb', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + externalId: [ + { type: 'signl4UserId', id: 'f0bd5063-9588-51cf-b3d9-94e5647dedc5' }, + ], + traits: { email: 'rene@signl4.com', name: 'Rene' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'dd209a2d-e037-41ee-b37d-f605cc0a39fb', + originalTimestamp: '2017-09-01T08:11:37.000Z', + event: 'Alert Confirmed', + properties: { + eventType: 201, + 'subscription.id': '0acf8014-22f2-4503-88d7-f7d05b46744f', + 'alert.statusCode': 2, + 'alert.eventId': '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + 'alert.externalEventId': 'Content you passed in the X-S4-ExternalID parameter', + 'alert.acknowledgedUserIds[0]': 'f0bd5063-9588-51cf-b3d9-94e5647dedc5', + 'alert.id': '2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685', + }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-2', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 201, + eventRaisedUtc: '2017-09-01T08:11:37.4815663Z', + subscription: { id: '0acf8014-22f2-4503-88d7-f7d05b46744f' }, + user: { + username: 'Rene', + mailaddress: 'rene@signl4.com', + id: 'f0bd5063-9588-51cf-b3d9-94e5647dedc5', + }, + alert: { + statusCode: 4, + eventId: '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + externalEventId: 'Content you passed in the X-S4-ExternalID parameter', + acknowledgedUserIds: ['f0bd5063-9588-51cf-b3d9-94e5647dedc5'], + id: '2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685', + }, + id: 'dd209a2d-e037-41ee-b37d-f605cc0a39fb', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + externalId: [ + { type: 'signl4UserId', id: 'f0bd5063-9588-51cf-b3d9-94e5647dedc5' }, + ], + traits: { email: 'rene@signl4.com', name: 'Rene' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'dd209a2d-e037-41ee-b37d-f605cc0a39fb', + originalTimestamp: '2017-09-01T08:11:37.000Z', + event: 'Alert Resolved', + properties: { + eventType: 201, + 'subscription.id': '0acf8014-22f2-4503-88d7-f7d05b46744f', + 'alert.statusCode': 4, + 'alert.eventId': '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + 'alert.externalEventId': 'Content you passed in the X-S4-ExternalID parameter', + 'alert.acknowledgedUserIds[0]': 'f0bd5063-9588-51cf-b3d9-94e5647dedc5', + 'alert.id': '2518981069381242800_2ab1b5e0-f1b7-4c3e-9adf-6c157eeb4685', + }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-3', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 202, + eventRaisedUtc: '2020-01-10T12:27:19Z', + subscription: { id: 'b8fdd850-e2ad-45ff-924d-9c332a063200' }, + team: { id: '0e8979f7-0c6a-472d-8918-ecfd339252f8' }, + alert: { + statusCode: 1, + eventId: '2518236416806594587_0e67b746-6c88-4ddf-8872-99690b0457d9', + externalEventId: 'INC091210', + acknowledgedUserIds: [], + id: '2518236416804564453_12ea0f6f-948c-43d0-9034-f9565d7b6bd2', + }, + id: '27283793-47c8-4da2-9767-d37be224338d', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: '27283793-47c8-4da2-9767-d37be224338d', + originalTimestamp: '2020-01-10T12:27:19.000Z', + event: 'Alert Escalated', + properties: { + eventType: 202, + 'subscription.id': 'b8fdd850-e2ad-45ff-924d-9c332a063200', + 'team.id': '0e8979f7-0c6a-472d-8918-ecfd339252f8', + 'alert.statusCode': 1, + 'alert.eventId': '2518236416806594587_0e67b746-6c88-4ddf-8872-99690b0457d9', + 'alert.externalEventId': 'INC091210', + 'alert.id': '2518236416804564453_12ea0f6f-948c-43d0-9034-f9565d7b6bd2', + 'alert.acknowledgedUserIds': [], + }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-4', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 203, + eventRaisedUtc: '2018-04-17T15:00:32Z', + subscription: { id: '1578ebd9-0a27-44ab-bc8e-52cd7d32e81d' }, + user: { + username: 'Rene', + mailaddress: 'rene@signl4.com', + id: 'f0bd5063-9588-51cf-b3d9-94e5647dedc5', + }, + alert: { + statusCode: 0, + eventId: '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + externalEventId: 'Content you passed in the X-S4-ExternalID parameter', + id: '2518783235958846071_4e2dfab2-4717-42bc-8d37-8682402309c2', + }, + annotation: { + message: "OK, I'll take care about it.", + id: '2518783235661483318_99ebffe0-1b90-40ef-990a-fbd842484761', + }, + id: '141c0f88-7831-4d5e-b055-f6e83c269770', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + externalId: [ + { type: 'signl4UserId', id: 'f0bd5063-9588-51cf-b3d9-94e5647dedc5' }, + ], + traits: { email: 'rene@signl4.com', name: 'Rene' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: '141c0f88-7831-4d5e-b055-f6e83c269770', + originalTimestamp: '2018-04-17T15:00:32.000Z', + event: 'Alert Annotated', + properties: { + eventType: 203, + 'subscription.id': '1578ebd9-0a27-44ab-bc8e-52cd7d32e81d', + 'alert.statusCode': 0, + 'alert.eventId': '2518783235949759942_fbc7b4a4-badd-47b8-9e1d-702fb6a1a0b2', + 'alert.externalEventId': 'Content you passed in the X-S4-ExternalID parameter', + 'alert.id': '2518783235958846071_4e2dfab2-4717-42bc-8d37-8682402309c2', + 'annotation.message': "OK, I'll take care about it.", + 'annotation.id': '2518783235661483318_99ebffe0-1b90-40ef-990a-fbd842484761', + }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-5', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 300, + eventRaisedUtc: '2017-09-01T09:16:17.3717355Z', + team: { id: 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + id: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + originalTimestamp: '2017-09-01T09:16:17.000Z', + event: 'Duty Period Started', + properties: { eventType: 300, 'team.id': 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-6', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 301, + eventRaisedUtc: '2017-09-01T09:16:17.3717355Z', + team: { id: 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + id: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + originalTimestamp: '2017-09-01T09:16:17.000Z', + event: 'Duty Period Ended', + properties: { eventType: 301, 'team.id': 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-7', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 302, + eventRaisedUtc: '2017-09-01T09:16:17.3717355Z', + team: { id: 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + user: { id: 'e31da15f-7e13-43f1-b4a5-1ce3b470a504' }, + id: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + externalId: [ + { type: 'signl4UserId', id: 'e31da15f-7e13-43f1-b4a5-1ce3b470a504' }, + ], + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + originalTimestamp: '2017-09-01T09:16:17.000Z', + event: 'Somebody Punched-In', + properties: { eventType: 302, 'team.id': 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, + { + name: 'signl4', + description: 'test-8', + module: 'source', + version: 'v0', + input: { + request: { + body: [ + { + eventType: 303, + eventRaisedUtc: '2017-09-01T09:16:17.3717355Z', + team: { id: 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + user: { id: 'e31da15f-7e13-43f1-b4a5-1ce3b470a504' }, + id: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + }, + ], + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + }, + pathSuffix: '', + }, + output: { + response: { + status: 200, + body: [ + { + output: { + batch: [ + { + context: { + library: { name: 'unknown', version: 'unknown' }, + integration: { name: 'Signl4' }, + externalId: [ + { type: 'signl4UserId', id: 'e31da15f-7e13-43f1-b4a5-1ce3b470a504' }, + ], + }, + integrations: { Signl4: false }, + type: 'track', + messageId: 'f56a6b59-1197-4e7d-8eca-8d21a4b57ec3', + originalTimestamp: '2017-09-01T09:16:17.000Z', + event: 'Somebody Punched-Out', + properties: { eventType: 303, 'team.id': 'f1801955-4724-44de-902a-f6f02ba9e10f' }, + anonymousId: '97fcd7b2-cc24-47d7-b776-057b7b199513', + }, + ], + }, + }, + ], + }, + }, + }, +].map((tc) => ({ + ...tc, + mockFns: () => { + defaultMockFns(); + }, +})); diff --git a/test/integrations/testTypes.ts b/test/integrations/testTypes.ts index 3df732d84f..3c5cf60600 100644 --- a/test/integrations/testTypes.ts +++ b/test/integrations/testTypes.ts @@ -18,6 +18,8 @@ export interface requestType { export interface responseType { status: number; + statusCode?: number; + error?: any; body?: any; headers?: Record; } @@ -40,6 +42,7 @@ export interface TestCaseData { id?: string; name: string; description: string; + skipGo?: string; scenario?: string; successCriteria?: string; comment?: string; @@ -49,9 +52,29 @@ export interface TestCaseData { input: inputType; output: outputType; mock?: mockType[]; + overrideReceivedAt?: string; + overrideRequestIP?: string; mockFns?: (mockAdapter: MockAdapter) => {}; } +export type MockFns = (mockAdapter: MockAdapter) => void; + +export interface SrcTestCaseData { + id?: string; + name: string; + description: string; + scenario?: string; + successCriteria?: string; + comment?: string; + feature?: string; + module: string; + version?: string; + input: inputType; + output: outputType; + mock?: mockType[]; + mockFns?: MockFns; +} + export type MockHttpCallsData = { httpReq: Record; httpRes: Partial; diff --git a/test/integrations/testUtils.ts b/test/integrations/testUtils.ts index 5e0df874f8..6eaf662c78 100644 --- a/test/integrations/testUtils.ts +++ b/test/integrations/testUtils.ts @@ -24,8 +24,11 @@ const generateAlphanumericId = (size = 36) => export const getTestDataFilePaths = (dirPath: string, opts: OptionValues): string[] => { const globPattern = join(dirPath, '**', 'data.ts'); let testFilePaths = globSync(globPattern); - if (opts.destination) { - testFilePaths = testFilePaths.filter((testFile) => testFile.includes(opts.destination)); + + if (opts.destination || opts.source) { + testFilePaths = testFilePaths.filter((testFile) => + testFile.includes(`${opts.destination}/` || opts.source), + ); } if (opts.feature) { testFilePaths = testFilePaths.filter((testFile) => testFile.includes(opts.feature)); @@ -563,11 +566,11 @@ export const validateTestWithZOD = (testPayload: TestCaseData, response: any) => // ----------------------------- // Helper functions -export const generateMetadata = (jobId: number): any => { +export const generateMetadata = (jobId: number, userId?: string): any => { return { jobId, attemptNum: 1, - userId: 'default-userId', + userId: userId || 'default-userId', sourceId: 'default-sourceId', destinationId: 'default-destinationId', workspaceId: 'default-workspaceId', diff --git a/test/scripts/generateJson.ts b/test/scripts/generateJson.ts new file mode 100644 index 0000000000..388c81477d --- /dev/null +++ b/test/scripts/generateJson.ts @@ -0,0 +1,201 @@ +import { Command, OptionValues } from 'commander'; +import path from 'path'; +import fs from 'fs'; +import get from 'get-value'; +import { getTestData, getTestDataFilePaths, produceTestData } from '../integrations/testUtils'; +import { head, isNumber } from 'lodash'; +import { responseType } from '../integrations/testTypes'; +import { isDefinedAndNotNull } from '@rudderstack/integrations-lib'; + +interface TestCaseData { + name: string; + description: string; + skip?: string; + input: Input; + output: Output; +} + +interface Input { + request: { + query: string; + body: any; + headers?: Record; + method?: string; + }; +} + +interface Output { + response: { + status: number; + body: any; + }; + queue: any[]; + errQueue: any[]; +} + +const jsonGenerator = new Command(); +jsonGenerator + .name('json-generator') + .description('CLI to some JavaScript string utilities') + .version('0.8.0'); + +jsonGenerator + .command('sources') + .description('generator JSON test cases for source') + .argument('', 'output path') + .option('-s, --source ', 'source', '') + .action(generateSources); + +jsonGenerator.parse(); + +function getStatusCode(outputResponse?: responseType): number { + const statusCodeKeys = ['body.0.statusCode', 'statusCode', 'status']; + const stCode = statusCodeKeys + .map((statusKey) => get(outputResponse, statusKey)) + .find((stCode) => isNumber(stCode)); + return stCode || 200; +} + +function getErrorResponse(outputResponse?: responseType) { + const bodyKeys = ['body.0.error', 'error']; + const errorResponse = bodyKeys + .map((statusKey) => get(outputResponse, statusKey)) + .find(isDefinedAndNotNull); + if (errorResponse) { + return errorResponse + '\n'; + } + return errorResponse; +} + +function getSourceRequestBody(testCase: any, version?: string) { + const bodyElement = + testCase.input.request.body.length === 1 + ? testCase.input.request.body[0] + : testCase.input.request.body; + if (version === 'v0') { + return bodyElement; + } + if (Array.isArray(bodyElement?.event)) { + return bodyElement.event.map((e) => ({ ...e, source: bodyElement.source })); + } + return { ...bodyElement.event, source: bodyElement.source }; +} + +function generateSources(outputFolder: string, options: OptionValues) { + const rootDir = __dirname; + const resolvedpath = path.resolve(rootDir, '../integrations/sources'); + + const files = getTestDataFilePaths(resolvedpath, options); + + files.forEach((testDataPath) => { + const testData = getTestData(testDataPath); + testData.forEach(({ version, ...testCase }) => { + let statusCode: number = getStatusCode(testCase.output.response); + + let responseBody: any = 'OK'; + if (statusCode == 200) { + if (testCase.output.response?.body[0]?.outputToSource?.body) { + let rawBody = Buffer.from( + testCase.output.response?.body[0]?.outputToSource?.body, + 'base64', + ).toString(); + if ( + testCase.output.response?.body[0]?.outputToSource?.contentType === 'application/json' + ) { + responseBody = JSON.parse(rawBody); + } else { + responseBody = rawBody; + } + } + } else { + responseBody = getErrorResponse(testCase.output.response); + } + + testCase.input.request.body.forEach((body) => { + delete body['receivedAt']; + delete body['request_ip']; + }); + + let errorQueue: any[] = []; + if (statusCode !== 200) { + errorQueue = Array.isArray(testCase.input.request?.body) + ? testCase.input.request?.body + : [testCase.input.request?.body]; + } + + let goTest: TestCaseData = { + name: testCase.name, + description: testCase.description, + input: { + request: { + query: JSON.stringify(testCase.input.request.params), + body: getSourceRequestBody(testCase, version), + headers: testCase.input.request.headers || { + 'Content-Type': 'application/json', + }, + }, + }, + output: { + response: { + status: statusCode, + body: responseBody, + }, + // TODO flatten nested array + queue: + statusCode == 200 + ? testCase.output.response?.body + .filter((i) => i.output) + .map((i) => i.output.batch) + .flat() + : [], + errQueue: errorQueue, + }, + }; + if (testCase.input.request.method && testCase.input.request.method.toLowerCase() !== 'post') { + goTest.input.request.method = testCase.input.request.method; + } + const dirPath = path.join(outputFolder, goTest.name); + const safeName = toSnakeCase(goTest.description) + .replace(/[^a-z0-9]/gi, '_') + .toLowerCase(); + const filePath = path.join(dirPath, `${safeName}.json`); + + if (testCase.skipGo) { + goTest.skip = testCase.skipGo; + } + + goTest.output.queue.forEach((queueItem, i) => { + queueItem['receivedAt'] = + testCase?.overrideReceivedAt && + testCase.output.response?.body?.[0]?.output?.batch?.[i]?.receivedAt + ? testCase.output.response?.body?.[0]?.output?.batch?.[i]?.receivedAt + : '2024-03-03T04:48:29.000Z'; + queueItem['request_ip'] = + testCase?.overrideRequestIP && + testCase.output.response?.body?.[0]?.output?.batch?.[i]?.request_ip + ? testCase.output.response?.body?.[0]?.output?.batch?.[i]?.request_ip + : '192.0.2.30'; + if (!queueItem['messageId']) { + queueItem['messageId'] = '00000000-0000-0000-0000-000000000000'; + } + }); + + fs.mkdirSync(dirPath, { recursive: true }); + + fs.writeFileSync(filePath, JSON.stringify(goTest, null, 2)); + }); + }); +} + +function toSnakeCase(str: string): string { + return ( + str + // Replace spaces with underscores + .replace(/\s+/g, '_') + // Insert underscores before uppercase letters, handle acronyms correctly + .replace(/\.?([A-Z]+)/g, (x, y) => '_' + y.toLowerCase()) + // Remove leading underscores and handle consecutive underscores + .replace(/^_+/, '') + .replace(/_{2,}/g, '_') + ); +} diff --git a/tsconfig.json b/tsconfig.json index 926831b612..2c00e6482e 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -102,6 +102,6 @@ // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */ "skipLibCheck": true /* Skip type checking all .d.ts files. */, }, - "exclude": ["./src/**/*.test.js", "./src/**/*.test.ts", "./test"], + "exclude": ["./src/**/*.test.js", "./src/**/*.test.ts", "./test", "./go"], "include": ["./src", "./src/**/*.json"], }