diff --git a/.github/workflows/release-clients.yml b/.github/workflows/release-clients.yml new file mode 100644 index 0000000000..e07395bdde --- /dev/null +++ b/.github/workflows/release-clients.yml @@ -0,0 +1,54 @@ +name: Publish prism-agent clients + +on: + push: + tags: + - "prism-agent-v*" + +jobs: + publish-clients: + name: 'Build and publish Prism-Agent clients' + runs-on: ubuntu-latest + env: + VERSION_TAG: ${{github.ref_name}} + ATALA_GITHUB_ACTOR: ${{secrets.ATALA_GITHUB_ACTOR}} + ATALA_GITHUB_TOKEN: ${{secrets.ATALA_GITHUB_TOKEN}} + NODE_AUTH_TOKEN: ${{ secrets.ATALA_GITHUB_TOKEN }} + + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Setup Node.js + uses: actions/setup-node@v3 + with: + node-version: "lts/*" + registry-url: https://npm.pkg.github.com/ + scope: "@input-output-hk" + + - name: Setup Python + uses: actions/setup-python@v4 + with: + python-version: '3.10' + + - name: Setup Gradle + uses: gradle/gradle-build-action@v2 + + - name: Login to Github Hub + uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ secrets.ATALA_GITHUB_ACTOR }} + password: ${{ secrets.ATALA_GITHUB_TOKEN }} + + - name: Install generator dependencies + working-directory: prism-agent/client/generator + run: yarn install + + - name: Generate clients + working-directory: prism-agent/client/generator + run: yarn generate:all + + - name: Publish clients + working-directory: prism-agent/client/generator + run: yarn publish:clients diff --git a/connect/lib/sql-doobie/src/test/resources/logback.xml b/connect/lib/sql-doobie/src/test/resources/logback.xml index a1b00f1c8e..4eee19c9b4 100644 --- a/connect/lib/sql-doobie/src/test/resources/logback.xml +++ b/connect/lib/sql-doobie/src/test/resources/logback.xml @@ -10,10 +10,15 @@ + - + + - \ No newline at end of file + diff --git a/connect/lib/sql-doobie/src/test/scala/io/iohk/atala/connect/sql/repository/JdbcConnectionRepositorySpec.scala b/connect/lib/sql-doobie/src/test/scala/io/iohk/atala/connect/sql/repository/JdbcConnectionRepositorySpec.scala index 7cd1122aed..f4cd0aea6d 100644 --- a/connect/lib/sql-doobie/src/test/scala/io/iohk/atala/connect/sql/repository/JdbcConnectionRepositorySpec.scala +++ b/connect/lib/sql-doobie/src/test/scala/io/iohk/atala/connect/sql/repository/JdbcConnectionRepositorySpec.scala @@ -36,4 +36,5 @@ object JdbcConnectionRepositorySpec extends ZIOSpecDefault { ) @@ TestAspect.sequential @@ TestAspect.before( ZIO.serviceWithZIO[Migrations](_.migrate) )).provide(testEnvironmentLayer) + .provide(Runtime.removeDefaultLoggers) } diff --git a/infrastructure/local/.env b/infrastructure/local/.env index 9c7c5f7251..247f06a6f3 100644 --- a/infrastructure/local/.env +++ b/infrastructure/local/.env @@ -1,7 +1,5 @@ -MERCURY_MEDIATOR_VERSION=0.3.0 -IRIS_SERVICE_VERSION=0.1.0 -PRISM_AGENT_VERSION=1.6.0 -PRISM_NODE_VERSION=v2.1.3 +PRISM_AGENT_VERSION=1.9.2 +PRISM_NODE_VERSION=2.2.1 PORT=80 NETWORK=prism VAULT_DEV_ROOT_TOKEN_ID=root diff --git a/infrastructure/shared/docker-compose.yml b/infrastructure/shared/docker-compose.yml index cf124b2a2b..1783c7514d 100644 --- a/infrastructure/shared/docker-compose.yml +++ b/infrastructure/shared/docker-compose.yml @@ -100,8 +100,8 @@ services: SECRET_STORAGE_BACKEND: postgres DEV_MODE: true WALLET_SEED: - WEBHOOK_URL: ${WEBHOOK_URL} - WEBHOOK_API_KEY: ${WEBHOOK_API_KEY} + WEBHOOK_URL: + WEBHOOK_API_KEY: depends_on: db: condition: service_healthy diff --git a/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcCredentialRepositorySpec.scala b/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcCredentialRepositorySpec.scala index 01d2172505..64e588f343 100644 --- a/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcCredentialRepositorySpec.scala +++ b/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcCredentialRepositorySpec.scala @@ -34,5 +34,6 @@ object JdbcCredentialRepositorySpec extends ZIOSpecDefault { ) @@ TestAspect.before( ZIO.serviceWithZIO[Migrations](_.migrate) )).provide(testEnvironmentLayer) + .provide(Runtime.removeDefaultLoggers) } diff --git a/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcPresentationRepositorySpec.scala b/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcPresentationRepositorySpec.scala index 9c129a29cc..01314c3d7e 100644 --- a/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcPresentationRepositorySpec.scala +++ b/pollux/lib/sql-doobie/src/test/scala/io/iohk/atala/pollux/sql/repository/JdbcPresentationRepositorySpec.scala @@ -34,5 +34,6 @@ object JdbcPresentationRepositorySpec extends ZIOSpecDefault { ) @@ TestAspect.before( ZIO.serviceWithZIO[Migrations](_.migrate) )).provide(testEnvironmentLayer) + .provide(Runtime.removeDefaultLoggers) } diff --git a/prism-agent/client/.gitignore b/prism-agent/client/.gitignore new file mode 100644 index 0000000000..5e746f5642 --- /dev/null +++ b/prism-agent/client/.gitignore @@ -0,0 +1,45 @@ +.gradle +build/ +!gradle/wrapper/gradle-wrapper.jar +!**/src/main/**/build/ +!**/src/test/**/build/ +target +node_modules/ + +### IntelliJ IDEA ### +.idea/modules.xml +.idea/jarRepositories.xml +.idea/compiler.xml +.idea/libraries/ +*.iws +*.iml +*.ipr +out/ +!**/src/main/**/out/ +!**/src/test/**/out/ +.idea + +### Eclipse ### +.apt_generated +.classpath +.factorypath +.project +.settings +.springBeans +.sts4-cache +bin/ +!**/src/main/**/bin/ +!**/src/test/**/bin/ + +### NetBeans ### +/nbproject/private/ +/nbbuild/ +/dist/ +/nbdist/ +/.nb-gradle/ + +### VS Code ### +.vscode/ + +### Mac OS ### +.DS_Store \ No newline at end of file diff --git a/prism-agent/client/README.md b/prism-agent/client/README.md new file mode 100644 index 0000000000..4eb67fc31c --- /dev/null +++ b/prism-agent/client/README.md @@ -0,0 +1,38 @@ +# Prism-agent client generator + +This project goal is to generate the models based on the OpenAPI Specification. + +## Generating models + +Then run the generator scripts: + +```bash +cd generator +yarn generate +``` + +To publish the clients: + +```bash +cd generator +yarn publish:clients +``` + +## Prism-agent lifecycle + +`prism-client-generator` creates the clients after the `prism-agent-v*` tag is created. + +## Supported clients + +1. Kotlin +2. Typescript + +### Work in progress + +1. Python + +# Caution note + +Some of the OAS3 schema types are not fully supported. + +The generated files that are not supported were fixed manually and ignored from the generation, in the `.openapi-generator-ignore` file, therefore it requires a diligence work to keep them updated. diff --git a/prism-agent/client/generator/clean.sh b/prism-agent/client/generator/clean.sh new file mode 100755 index 0000000000..110c754e25 --- /dev/null +++ b/prism-agent/client/generator/clean.sh @@ -0,0 +1,6 @@ +#!/bin/bash +set -e + +git clean -dfx ../kotlin +git clean -dfx ../python +git clean -dfx ../typescript diff --git a/prism-agent/client/generator/generate-clients.sh b/prism-agent/client/generator/generate-clients.sh new file mode 100755 index 0000000000..3c0aea1c1d --- /dev/null +++ b/prism-agent/client/generator/generate-clients.sh @@ -0,0 +1,20 @@ +#!/bin/bash +set -e + +# generate kotlin models +yarn openapi-generator-cli generate \ + -g kotlin \ + -i ../../service/api/http/prism-agent-openapi-spec.yaml \ + -o ../kotlin \ + --ignore-file-override ../kotlin/.openapi-generator-ignore \ + --additional-properties=packageName=io.iohk.atala.prism,serializationLibrary=gson + +# generate typescript models +yarn openapi-generator-cli generate \ + -g typescript \ + -i ../../service/api/http/prism-agent-openapi-spec.yaml \ + -o ../typescript \ + --ignore-file-override ../typescript/.openapi-generator-ignore + +# generate python models +# yarn openapi-generator-cli generate -g python -i oas.yml --skip-validate-spec -o ../python --ignore-file-override ../python/.openapi-generator-ignore diff --git a/prism-agent/client/generator/openapitools.json b/prism-agent/client/generator/openapitools.json new file mode 100644 index 0000000000..cd53ff4cad --- /dev/null +++ b/prism-agent/client/generator/openapitools.json @@ -0,0 +1,7 @@ +{ + "$schema": "./node_modules/@openapitools/openapi-generator-cli/config.schema.json", + "spaces": 2, + "generator-cli": { + "version": "6.6.0" + } +} diff --git a/prism-agent/client/generator/package.json b/prism-agent/client/generator/package.json new file mode 100644 index 0000000000..12a07a2520 --- /dev/null +++ b/prism-agent/client/generator/package.json @@ -0,0 +1,19 @@ +{ + "name": "prism-agent-clients-generator", + "version": "1.0.0", + "description": "Generates the clients based on the OAS for many languages", + "author": "Allain Magyar", + "license": "Apache-2.0", + "private": true, + "type": "module", + "scripts": { + "generate": "npm-run-all clean:all generate:all", + "generate:all": "./generate-clients.sh", + "clean:all": "./clean.sh", + "publish:clients": "./publish-clients.sh" + }, + "dependencies": { + "@openapitools/openapi-generator-cli": "2.7.0", + "npm-run-all": "^4.1.5" + } +} diff --git a/prism-agent/client/generator/publish-clients.sh b/prism-agent/client/generator/publish-clients.sh new file mode 100755 index 0000000000..4cc96205c7 --- /dev/null +++ b/prism-agent/client/generator/publish-clients.sh @@ -0,0 +1,16 @@ +#!/bin/bash +set -e + +PRISM_AGENT_VERSION=${VERSION_TAG:13} + +# install dependencies +yarn + +# kotlin +gradle -p ../kotlin -Pversion=${PRISM_AGENT_VERSION} publish + +# typescript +yarn --cwd ../typescript +yarn --cwd ../typescript publish --new-version ${PRISM_AGENT_VERSION} --no-git-tag-version + +# python diff --git a/prism-agent/client/generator/yarn.lock b/prism-agent/client/generator/yarn.lock new file mode 100644 index 0000000000..cc43396b3c --- /dev/null +++ b/prism-agent/client/generator/yarn.lock @@ -0,0 +1,1490 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@babel/runtime@^7.21.0": + version "7.22.6" + resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.22.6.tgz" + integrity sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ== + dependencies: + regenerator-runtime "^0.13.11" + +"@lukeed/csprng@^1.0.0": + version "1.1.0" + resolved "https://registry.npmjs.org/@lukeed/csprng/-/csprng-1.1.0.tgz" + integrity sha512-Z7C/xXCiGWsg0KuKsHTKJxbWhpI3Vs5GwLfOean7MGyVFGqdRgBbAjOCh6u4bbjPc/8MJ2pZmK/0DLdCbivLDA== + +"@nestjs/axios@0.1.0": + version "0.1.0" + resolved "https://registry.npmjs.org/@nestjs/axios/-/axios-0.1.0.tgz" + integrity sha512-b2TT2X6BFbnNoeteiaxCIiHaFcSbVW+S5yygYqiIq5i6H77yIU3IVuLdpQkHq8/EqOWFwMopLN8jdkUT71Am9w== + dependencies: + axios "0.27.2" + +"@nestjs/common@9.3.11": + version "9.3.11" + resolved "https://registry.npmjs.org/@nestjs/common/-/common-9.3.11.tgz" + integrity sha512-IFZ2G/5UKWC2Uo7tJ4SxGed2+aiA+sJyWeWsGTogKVDhq90oxVBToh+uCDeI31HNUpqYGoWmkletfty42zUd8A== + dependencies: + uid "2.0.1" + iterare "1.2.1" + tslib "2.5.0" + +"@nestjs/core@9.3.11": + version "9.3.11" + resolved "https://registry.npmjs.org/@nestjs/core/-/core-9.3.11.tgz" + integrity sha512-CI27a2JFd5rvvbgkalWqsiwQNhcP4EAG5BUK8usjp29wVp1kx30ghfBT8FLqIgmkRVo65A0IcEnWsxeXMntkxQ== + dependencies: + uid "2.0.1" + "@nuxtjs/opencollective" "0.3.2" + fast-safe-stringify "2.1.1" + iterare "1.2.1" + path-to-regexp "3.2.0" + tslib "2.5.0" + +"@nuxtjs/opencollective@0.3.2": + version "0.3.2" + resolved "https://registry.npmjs.org/@nuxtjs/opencollective/-/opencollective-0.3.2.tgz" + integrity sha512-um0xL3fO7Mf4fDxcqx9KryrB7zgRM5JSlvGN5AGkP6JLM5XEKyjeAiPbNxdXVXQ16isuAhYpvP88NgL2BGd6aA== + dependencies: + chalk "^4.1.0" + consola "^2.15.0" + node-fetch "^2.6.1" + +"@openapitools/openapi-generator-cli@2.7.0": + version "2.7.0" + resolved "https://registry.npmjs.org/@openapitools/openapi-generator-cli/-/openapi-generator-cli-2.7.0.tgz" + integrity sha512-ieEpHTA/KsDz7ANw03lLPYyjdedDEXYEyYoGBRWdduqXWSX65CJtttjqa8ZaB1mNmIjMtchUHwAYQmTLVQ8HYg== + dependencies: + "@nestjs/axios" "0.1.0" + "@nestjs/common" "9.3.11" + "@nestjs/core" "9.3.11" + "@nuxtjs/opencollective" "0.3.2" + chalk "4.1.2" + commander "8.3.0" + compare-versions "4.1.4" + concurrently "6.5.1" + console.table "0.10.0" + fs-extra "10.1.0" + glob "7.1.6" + inquirer "8.2.5" + lodash "4.17.21" + reflect-metadata "0.1.13" + rxjs "7.8.0" + tslib "2.0.3" + +ansi-escapes@^4.2.1: + version "4.3.2" + resolved "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz" + integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== + dependencies: + type-fest "^0.21.3" + +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" + integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== + +ansi-styles@^3.2.1: + 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== + dependencies: + color-convert "^1.9.0" + +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== + dependencies: + color-convert "^2.0.1" + +array-buffer-byte-length@^1.0.0: + 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== + dependencies: + call-bind "^1.0.2" + is-array-buffer "^3.0.1" + +arraybuffer.prototype.slice@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.1.tgz" + integrity sha512-09x0ZWFEjj4WD8PDbykUwo3t9arLn8NIzmmYEJFpYekOAQjpkGSyrQhNoRTcwwcFRu+ycWF78QZ63oWTqSjBcw== + dependencies: + array-buffer-byte-length "^1.0.0" + call-bind "^1.0.2" + define-properties "^1.2.0" + get-intrinsic "^1.2.1" + is-array-buffer "^3.0.2" + is-shared-array-buffer "^1.0.2" + +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz" + integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== + +available-typed-arrays@^1.0.5: + version "1.0.5" + resolved "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz" + integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== + +axios@0.27.2: + version "0.27.2" + resolved "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz" + integrity sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ== + dependencies: + follow-redirects "^1.14.9" + form-data "^4.0.0" + +balanced-match@^1.0.0: + version "1.0.2" + resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" + integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== + +base64-js@^1.3.1: + version "1.5.1" + resolved "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" + integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== + +bl@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz" + integrity sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w== + dependencies: + buffer "^5.5.0" + inherits "^2.0.4" + readable-stream "^3.4.0" + +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== + dependencies: + balanced-match "^1.0.0" + concat-map "0.0.1" + +buffer@^5.5.0: + version "5.7.1" + resolved "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz" + integrity sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ== + dependencies: + base64-js "^1.3.1" + ieee754 "^1.1.13" + +call-bind@^1.0.0, call-bind@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + +chalk@4.1.2, chalk@^4.1.0, chalk@^4.1.1: + version "4.1.2" + resolved "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" + integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +chalk@^2.4.1: + version "2.4.2" + resolved "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chardet@^0.7.0: + version "0.7.0" + resolved "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz" + integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== + +cli-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz" + integrity sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw== + dependencies: + restore-cursor "^3.1.0" + +cli-spinners@^2.5.0: + version "2.9.0" + resolved "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.0.tgz" + integrity sha512-4/aL9X3Wh0yiMQlE+eeRhWP6vclO3QRtw1JHKIT0FFUs5FjpFmESqtMvYZ0+lbzBw900b95mS0hohy+qn2VK/g== + +cli-width@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/cli-width/-/cli-width-3.0.0.tgz" + integrity sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw== + +cliui@^7.0.2: + version "7.0.4" + resolved "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz" + integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^7.0.0" + +clone@^1.0.2: + version "1.0.4" + resolved "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz" + integrity sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg== + +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== + dependencies: + color-name "1.1.3" + +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" + integrity sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw== + +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== + +combined-stream@^1.0.8: + version "1.0.8" + resolved "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== + dependencies: + delayed-stream "~1.0.0" + +commander@8.3.0: + version "8.3.0" + resolved "https://registry.npmjs.org/commander/-/commander-8.3.0.tgz" + integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== + +compare-versions@4.1.4: + version "4.1.4" + resolved "https://registry.npmjs.org/compare-versions/-/compare-versions-4.1.4.tgz" + integrity sha512-FemMreK9xNyL8gQevsdRMrvO4lFCkQP7qbuktn1q8ndcNk1+0mz7lgE7b/sNvbhVgY4w6tMN1FDp6aADjqw2rw== + +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" + integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== + +concurrently@6.5.1: + version "6.5.1" + resolved "https://registry.npmjs.org/concurrently/-/concurrently-6.5.1.tgz" + integrity sha512-FlSwNpGjWQfRwPLXvJ/OgysbBxPkWpiVjy1042b0U7on7S7qwwMIILRj7WTN1mTgqa582bG6NFuScOoh6Zgdag== + dependencies: + chalk "^4.1.0" + date-fns "^2.16.1" + lodash "^4.17.21" + rxjs "^6.6.3" + spawn-command "^0.0.2-1" + supports-color "^8.1.0" + tree-kill "^1.2.2" + yargs "^16.2.0" + +consola@^2.15.0: + version "2.15.3" + resolved "https://registry.npmjs.org/consola/-/consola-2.15.3.tgz" + integrity sha512-9vAdYbHj6x2fLKC4+oPH0kFzY/orMZyG2Aj+kNylHxKGJ/Ed4dpNyAQYwJOdqO4zdM7XpVHmyejQDcQHrnuXbw== + +console.table@0.10.0: + version "0.10.0" + resolved "https://registry.npmjs.org/console.table/-/console.table-0.10.0.tgz" + integrity sha512-dPyZofqggxuvSf7WXvNjuRfnsOk1YazkVP8FdxH4tcH2c37wc79/Yl6Bhr7Lsu00KMgy2ql/qCMuNu8xctZM8g== + dependencies: + easy-table "1.1.0" + +cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + +date-fns@^2.16.1: + version "2.30.0" + resolved "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz" + integrity sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw== + dependencies: + "@babel/runtime" "^7.21.0" + +defaults@^1.0.3: + version "1.0.4" + resolved "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz" + integrity sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A== + dependencies: + clone "^1.0.2" + +define-properties@^1.1.3, define-properties@^1.1.4, define-properties@^1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/define-properties/-/define-properties-1.2.0.tgz" + integrity sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA== + dependencies: + has-property-descriptors "^1.0.0" + object-keys "^1.1.1" + +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz" + integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ== + +easy-table@1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/easy-table/-/easy-table-1.1.0.tgz" + integrity sha512-oq33hWOSSnl2Hoh00tZWaIPi1ievrD9aFG82/IgjlycAnW9hHx5PkJiXpxPsgEE+H7BsbVQXFVFST8TEXS6/pA== + optionalDependencies: + wcwidth ">=1.0.1" + +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + +error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== + dependencies: + is-arrayish "^0.2.1" + +es-abstract@^1.19.0, es-abstract@^1.20.4: + version "1.22.1" + resolved "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.1.tgz" + integrity sha512-ioRRcXMO6OFyRpyzV3kE1IIBd4WG5/kltnzdxSCqoP8CMGs/Li+M1uF5o7lOkZVFjDs+NLesthnF66Pg/0q0Lw== + dependencies: + array-buffer-byte-length "^1.0.0" + arraybuffer.prototype.slice "^1.0.1" + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + es-set-tostringtag "^2.0.1" + es-to-primitive "^1.2.1" + function.prototype.name "^1.1.5" + get-intrinsic "^1.2.1" + get-symbol-description "^1.0.0" + globalthis "^1.0.3" + gopd "^1.0.1" + has "^1.0.3" + has-property-descriptors "^1.0.0" + has-proto "^1.0.1" + has-symbols "^1.0.3" + internal-slot "^1.0.5" + is-array-buffer "^3.0.2" + is-callable "^1.2.7" + is-negative-zero "^2.0.2" + is-regex "^1.1.4" + is-shared-array-buffer "^1.0.2" + is-string "^1.0.7" + is-typed-array "^1.1.10" + is-weakref "^1.0.2" + object-inspect "^1.12.3" + object-keys "^1.1.1" + object.assign "^4.1.4" + regexp.prototype.flags "^1.5.0" + safe-array-concat "^1.0.0" + safe-regex-test "^1.0.0" + string.prototype.trim "^1.2.7" + string.prototype.trimend "^1.0.6" + string.prototype.trimstart "^1.0.6" + typed-array-buffer "^1.0.0" + typed-array-byte-length "^1.0.0" + typed-array-byte-offset "^1.0.0" + typed-array-length "^1.0.4" + unbox-primitive "^1.0.2" + which-typed-array "^1.1.10" + +es-set-tostringtag@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz" + integrity sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg== + dependencies: + get-intrinsic "^1.1.3" + has "^1.0.3" + has-tostringtag "^1.0.0" + +es-to-primitive@^1.2.1: + version "1.2.1" + resolved "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz" + integrity sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA== + dependencies: + is-callable "^1.1.4" + is-date-object "^1.0.1" + is-symbol "^1.0.2" + +escalade@^3.1.1: + version "3.1.1" + resolved "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" + integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== + +escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" + integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== + +external-editor@^3.0.3: + version "3.1.0" + resolved "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz" + integrity sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew== + dependencies: + chardet "^0.7.0" + iconv-lite "^0.4.24" + tmp "^0.0.33" + +fast-safe-stringify@2.1.1: + 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== + +figures@^3.0.0: + version "3.2.0" + resolved "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz" + integrity sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg== + dependencies: + escape-string-regexp "^1.0.5" + +follow-redirects@^1.14.9: + version "1.15.2" + resolved "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz" + integrity sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA== + +for-each@^0.3.3: + version "0.3.3" + resolved "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz" + integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== + dependencies: + is-callable "^1.1.3" + +form-data@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz" + integrity sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.8" + mime-types "^2.1.12" + +fs-extra@10.1.0: + version "10.1.0" + resolved "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz" + integrity sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ== + dependencies: + graceful-fs "^4.2.0" + jsonfile "^6.0.1" + universalify "^2.0.0" + +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" + integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + +function.prototype.name@^1.1.5: + version "1.1.5" + resolved "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz" + integrity sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.0" + functions-have-names "^1.2.2" + +functions-have-names@^1.2.2, functions-have-names@^1.2.3: + version "1.2.3" + resolved "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz" + integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== + +get-caller-file@^2.0.5: + version "2.0.5" + resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== + +get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@^1.2.0, get-intrinsic@^1.2.1: + version "1.2.1" + resolved "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz" + integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-proto "^1.0.1" + has-symbols "^1.0.3" + +get-symbol-description@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz" + integrity sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.1" + +glob@7.1.6: + version "7.1.6" + resolved "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz" + integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + +globalthis@^1.0.3: + version "1.0.3" + resolved "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz" + integrity sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA== + dependencies: + define-properties "^1.1.3" + +gopd@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz" + integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== + dependencies: + get-intrinsic "^1.1.3" + +graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0: + 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== + +has-bigints@^1.0.1, has-bigints@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz" + integrity sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ== + +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" + integrity sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw== + +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + +has-property-descriptors@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz" + integrity sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ== + dependencies: + get-intrinsic "^1.1.1" + +has-proto@^1.0.1: + 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== + +has-symbols@^1.0.2, has-symbols@^1.0.3: + version "1.0.3" + resolved "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz" + integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== + +has-tostringtag@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz" + integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== + dependencies: + has-symbols "^1.0.2" + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.npmjs.org/has/-/has-1.0.3.tgz" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + +hosted-git-info@^2.1.4: + 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== + +iconv-lite@^0.4.24: + version "0.4.24" + resolved "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz" + integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== + dependencies: + safer-buffer ">= 2.1.2 < 3" + +ieee754@^1.1.13: + version "1.2.1" + resolved "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" + integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== + +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" + integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== + dependencies: + once "^1.3.0" + wrappy "1" + +inherits@2, inherits@^2.0.3, inherits@^2.0.4: + version "2.0.4" + resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== + +inquirer@8.2.5: + version "8.2.5" + resolved "https://registry.npmjs.org/inquirer/-/inquirer-8.2.5.tgz" + integrity sha512-QAgPDQMEgrDssk1XiwwHoOGYF9BAbUcc1+j+FhEvaOt8/cKRqyLn0U5qA6F74fGhTMGxf92pOvPBeh29jQJDTQ== + dependencies: + ansi-escapes "^4.2.1" + chalk "^4.1.1" + cli-cursor "^3.1.0" + cli-width "^3.0.0" + external-editor "^3.0.3" + figures "^3.0.0" + lodash "^4.17.21" + mute-stream "0.0.8" + ora "^5.4.1" + run-async "^2.4.0" + rxjs "^7.5.5" + string-width "^4.1.0" + strip-ansi "^6.0.0" + through "^2.3.6" + wrap-ansi "^7.0.0" + +internal-slot@^1.0.5: + version "1.0.5" + resolved "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz" + integrity sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ== + dependencies: + get-intrinsic "^1.2.0" + has "^1.0.3" + side-channel "^1.0.4" + +is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: + 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== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.2.0" + is-typed-array "^1.1.10" + +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz" + integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== + +is-bigint@^1.0.1: + version "1.0.4" + resolved "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz" + integrity sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg== + dependencies: + has-bigints "^1.0.1" + +is-boolean-object@^1.1.0: + version "1.1.2" + resolved "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz" + integrity sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.2.7: + version "1.2.7" + resolved "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz" + integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== + +is-core-module@^2.11.0: + version "2.12.1" + resolved "https://registry.npmjs.org/is-core-module/-/is-core-module-2.12.1.tgz" + integrity sha512-Q4ZuBAe2FUsKtyQJoQHlvP8OvBERxO3jEmy1I7hcRXcJBGGHFh/aJBswbXuS9sgrDH2QUO8ilkwNPHvHMd8clg== + dependencies: + has "^1.0.3" + +is-date-object@^1.0.1: + version "1.0.5" + resolved "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz" + integrity sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ== + dependencies: + has-tostringtag "^1.0.0" + +is-fullwidth-code-point@^3.0.0: + 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== + +is-interactive@^1.0.0: + 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== + +is-negative-zero@^2.0.2: + version "2.0.2" + resolved "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz" + integrity sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA== + +is-number-object@^1.0.4: + version "1.0.7" + resolved "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz" + integrity sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ== + dependencies: + has-tostringtag "^1.0.0" + +is-regex@^1.1.4: + version "1.1.4" + resolved "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz" + integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-shared-array-buffer@^1.0.2: + 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== + dependencies: + call-bind "^1.0.2" + +is-string@^1.0.5, is-string@^1.0.7: + version "1.0.7" + resolved "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz" + integrity sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg== + dependencies: + has-tostringtag "^1.0.0" + +is-symbol@^1.0.2, is-symbol@^1.0.3: + version "1.0.4" + resolved "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz" + integrity sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg== + dependencies: + has-symbols "^1.0.2" + +is-typed-array@^1.1.10, is-typed-array@^1.1.9: + 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== + dependencies: + which-typed-array "^1.1.11" + +is-unicode-supported@^0.1.0: + version "0.1.0" + resolved "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz" + integrity sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw== + +is-weakref@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz" + integrity sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ== + dependencies: + call-bind "^1.0.2" + +isarray@^2.0.5: + version "2.0.5" + resolved "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz" + integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== + +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" + integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== + +iterare@1.2.1: + version "1.2.1" + resolved "https://registry.npmjs.org/iterare/-/iterare-1.2.1.tgz" + integrity sha512-RKYVTCjAnRthyJes037NX/IiqeidgN1xc3j1RjFfECFp28A1GVwK9nA+i0rJPaHqSZwygLzRnFlzUuHFoWWy+Q== + +json-parse-better-errors@^1.0.1: + 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== + +jsonfile@^6.0.1: + version "6.1.0" + resolved "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz" + integrity sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ== + dependencies: + universalify "^2.0.0" + optionalDependencies: + graceful-fs "^4.1.6" + +load-json-file@^4.0.0: + 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== + dependencies: + graceful-fs "^4.1.2" + parse-json "^4.0.0" + pify "^3.0.0" + strip-bom "^3.0.0" + +lodash@4.17.21, lodash@^4.17.21: + version "4.17.21" + resolved "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz" + integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== + +log-symbols@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" + integrity sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg== + dependencies: + chalk "^4.1.0" + is-unicode-supported "^0.1.0" + +memorystream@^0.3.1: + version "0.3.1" + resolved "https://registry.npmjs.org/memorystream/-/memorystream-0.3.1.tgz" + integrity sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw== + +mime-db@1.52.0: + version "1.52.0" + resolved "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz" + integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== + +mime-types@^2.1.12: + version "2.1.35" + resolved "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz" + integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== + dependencies: + mime-db "1.52.0" + +mimic-fn@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== + +minimatch@^3.0.4: + version "3.1.2" + resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" + integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== + dependencies: + brace-expansion "^1.1.7" + +mute-stream@0.0.8: + version "0.0.8" + resolved "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz" + integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA== + +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== + +node-fetch@^2.6.1: + version "2.6.12" + resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz" + integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== + dependencies: + whatwg-url "^5.0.0" + +normalize-package-data@^2.3.2: + 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== + dependencies: + hosted-git-info "^2.1.4" + resolve "^1.10.0" + semver "2 || 3 || 4 || 5" + validate-npm-package-license "^3.0.1" + +npm-run-all@^4.1.5: + version "4.1.5" + resolved "https://registry.npmjs.org/npm-run-all/-/npm-run-all-4.1.5.tgz" + integrity sha512-Oo82gJDAVcaMdi3nuoKFavkIHBRVqQ1qvMb+9LHk/cF4P6B2m8aP04hGf7oL6wZ9BuGwX1onlLhpuoofSyoQDQ== + dependencies: + ansi-styles "^3.2.1" + chalk "^2.4.1" + cross-spawn "^6.0.5" + memorystream "^0.3.1" + minimatch "^3.0.4" + pidtree "^0.3.0" + read-pkg "^3.0.0" + shell-quote "^1.6.1" + string.prototype.padend "^3.0.0" + +object-inspect@^1.12.3, object-inspect@^1.9.0: + version "1.12.3" + resolved "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz" + integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== + +object-keys@^1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz" + integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== + +object.assign@^4.1.4: + version "4.1.4" + resolved "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz" + integrity sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + has-symbols "^1.0.3" + object-keys "^1.1.1" + +once@^1.3.0: + version "1.4.0" + resolved "https://registry.npmjs.org/once/-/once-1.4.0.tgz" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== + dependencies: + wrappy "1" + +onetime@^5.1.0: + version "5.1.2" + resolved "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz" + integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== + dependencies: + mimic-fn "^2.1.0" + +ora@^5.4.1: + version "5.4.1" + resolved "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz" + integrity sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ== + dependencies: + bl "^4.1.0" + chalk "^4.1.0" + cli-cursor "^3.1.0" + cli-spinners "^2.5.0" + is-interactive "^1.0.0" + is-unicode-supported "^0.1.0" + log-symbols "^4.1.0" + strip-ansi "^6.0.0" + wcwidth "^1.0.1" + +os-tmpdir@~1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz" + integrity sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g== + +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz" + integrity sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw== + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== + +path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" + integrity sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw== + +path-parse@^1.0.7: + version "1.0.7" + resolved "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== + +path-to-regexp@3.2.0: + version "3.2.0" + resolved "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-3.2.0.tgz" + integrity sha512-jczvQbCUS7XmS7o+y1aEO9OBVFeZBQ1MDSEqmO7xSoPgOPoowY/SxLpZ6Vh97/8qHZOteiCKb7gkG9gA2ZUxJA== + +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz" + integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== + dependencies: + pify "^3.0.0" + +pidtree@^0.3.0: + version "0.3.1" + resolved "https://registry.npmjs.org/pidtree/-/pidtree-0.3.1.tgz" + integrity sha512-qQbW94hLHEqCg7nhby4yRC7G2+jYHY4Rguc2bjw7Uug4GIJuu1tvf2uHaZv5Q8zdt+WKJ6qK1FOI6amaWUo5FA== + +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz" + integrity sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg== + +read-pkg@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz" + integrity sha512-BLq/cCO9two+lBgiTYNqD6GdtK8s4NpaWrl6/rCO9w0TUS8oJl7cmToOZfRYllKTISY6nt1U7jQ53brmKqY6BA== + dependencies: + load-json-file "^4.0.0" + normalize-package-data "^2.3.2" + path-type "^3.0.0" + +readable-stream@^3.4.0: + version "3.6.2" + resolved "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz" + integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + +reflect-metadata@0.1.13: + version "0.1.13" + resolved "https://registry.npmjs.org/reflect-metadata/-/reflect-metadata-0.1.13.tgz" + integrity sha512-Ts1Y/anZELhSsjMcU605fU9RE4Oi3p5ORujwbIKXfWa+0Zxs510Qrmrce5/Jowq3cHSZSJqBjypxmHarc+vEWg== + +regenerator-runtime@^0.13.11: + version "0.13.11" + resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" + integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== + +regexp.prototype.flags@^1.5.0: + version "1.5.0" + resolved "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz" + integrity sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA== + dependencies: + call-bind "^1.0.2" + define-properties "^1.2.0" + functions-have-names "^1.2.3" + +require-directory@^2.1.1: + 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== + +resolve@^1.10.0: + version "1.22.2" + resolved "https://registry.npmjs.org/resolve/-/resolve-1.22.2.tgz" + integrity sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g== + dependencies: + is-core-module "^2.11.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" + +restore-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz" + integrity sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA== + dependencies: + onetime "^5.1.0" + signal-exit "^3.0.2" + +run-async@^2.4.0: + version "2.4.1" + resolved "https://registry.npmjs.org/run-async/-/run-async-2.4.1.tgz" + integrity sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ== + +rxjs@7.8.0: + version "7.8.0" + resolved "https://registry.npmjs.org/rxjs/-/rxjs-7.8.0.tgz" + integrity sha512-F2+gxDshqmIub1KdvZkaEfGDwLNpPvk9Fs6LD/MyQxNgMds/WH9OdDDXOmxUZpME+iSK3rQCctkL0DYyytUqMg== + dependencies: + tslib "^2.1.0" + +rxjs@^6.6.3: + version "6.6.7" + resolved "https://registry.npmjs.org/rxjs/-/rxjs-6.6.7.tgz" + integrity sha512-hTdwr+7yYNIT5n4AMYp85KA6yw2Va0FLa3Rguvbpa4W3I5xynaBZo41cM3XM+4Q6fRMj3sBYIR1VAmZMXYJvRQ== + dependencies: + tslib "^1.9.0" + +rxjs@^7.5.5: + version "7.8.1" + resolved "https://registry.npmjs.org/rxjs/-/rxjs-7.8.1.tgz" + integrity sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg== + dependencies: + tslib "^2.1.0" + +safe-array-concat@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz" + integrity sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.2.0" + has-symbols "^1.0.3" + isarray "^2.0.5" + +safe-buffer@~5.2.0: + version "5.2.1" + resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" + integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== + +safe-regex-test@^1.0.0: + 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== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.3" + is-regex "^1.1.4" + +"safer-buffer@>= 2.1.2 < 3": + version "2.1.2" + resolved "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + +"semver@2 || 3 || 4 || 5", semver@^5.5.0: + version "5.7.2" + resolved "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== + +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" + integrity sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg== + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" + integrity sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ== + +shell-quote@^1.6.1: + version "1.8.1" + resolved "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.1.tgz" + integrity sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA== + +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz" + integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + +signal-exit@^3.0.2: + version "3.0.7" + resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" + integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== + +spawn-command@^0.0.2-1: + version "0.0.2-1" + resolved "https://registry.npmjs.org/spawn-command/-/spawn-command-0.0.2-1.tgz" + integrity sha512-n98l9E2RMSJ9ON1AKisHzz7V42VDiBQGY6PB1BwRglz99wpVsSuGzQ+jOi6lFXBGVTCrRpltvjm+/XA+tpeJrg== + +spdx-correct@^3.0.0: + version "3.2.0" + resolved "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.2.0.tgz" + integrity sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA== + dependencies: + spdx-expression-parse "^3.0.0" + spdx-license-ids "^3.0.0" + +spdx-exceptions@^2.1.0: + version "2.3.0" + resolved "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz" + integrity sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A== + +spdx-expression-parse@^3.0.0: + version "3.0.1" + resolved "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz" + integrity sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q== + dependencies: + spdx-exceptions "^2.1.0" + spdx-license-ids "^3.0.0" + +spdx-license-ids@^3.0.0: + version "3.0.13" + resolved "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.13.tgz" + integrity sha512-XkD+zwiqXHikFZm4AX/7JSCXA98U5Db4AFd5XUg/+9UNtnH75+Z9KxtpYiJZx36mUDVOwH83pl7yvCer6ewM3w== + +string-width@^4.1.0, string-width@^4.2.0: + version "4.2.3" + resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string.prototype.padend@^3.0.0: + version "3.1.4" + resolved "https://registry.npmjs.org/string.prototype.padend/-/string.prototype.padend-3.1.4.tgz" + integrity sha512-67otBXoksdjsnXXRUq+KMVTdlVRZ2af422Y0aTyTjVaoQkGr3mxl2Bc5emi7dOQ3OGVVQQskmLEWwFXwommpNw== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + +string.prototype.trim@^1.2.7: + version "1.2.7" + resolved "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz" + integrity sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + +string.prototype.trimend@^1.0.6: + version "1.0.6" + resolved "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz" + integrity sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + +string.prototype.trimstart@^1.0.6: + version "1.0.6" + resolved "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz" + integrity sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + +string_decoder@^1.1.1: + version "1.3.0" + resolved "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz" + integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== + dependencies: + safe-buffer "~5.2.0" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + +strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz" + integrity sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA== + +supports-color@^5.3.0: + version "5.5.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== + dependencies: + has-flag "^3.0.0" + +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== + dependencies: + has-flag "^4.0.0" + +supports-color@^8.1.0: + version "8.1.1" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz" + integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== + dependencies: + has-flag "^4.0.0" + +supports-preserve-symlinks-flag@^1.0.0: + 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== + +through@^2.3.6: + version "2.3.8" + resolved "https://registry.npmjs.org/through/-/through-2.3.8.tgz" + integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== + +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz" + integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== + dependencies: + os-tmpdir "~1.0.2" + +tr46@~0.0.3: + version "0.0.3" + resolved "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz" + integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== + +tree-kill@^1.2.2: + version "1.2.2" + resolved "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz" + integrity sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A== + +tslib@2.0.3: + version "2.0.3" + resolved "https://registry.npmjs.org/tslib/-/tslib-2.0.3.tgz" + integrity sha512-uZtkfKblCEQtZKBF6EBXVZeQNl82yqtDQdv+eck8u7tdPxjLu2/lp5/uPW+um2tpuxINHWy3GhiccY7QgEaVHQ== + +tslib@2.5.0: + version "2.5.0" + resolved "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz" + integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg== + +tslib@^1.9.0: + version "1.14.1" + resolved "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz" + integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== + +tslib@^2.1.0: + version "2.6.0" + resolved "https://registry.npmjs.org/tslib/-/tslib-2.6.0.tgz" + integrity sha512-7At1WUettjcSRHXCyYtTselblcHl9PJFFVKiCAy/bY97+BPZXSQ2wbq0P9s8tK2G7dFQfNnlJnPAiArVBVBsfA== + +type-fest@^0.21.3: + 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== + +typed-array-buffer@^1.0.0: + 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== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.2.1" + is-typed-array "^1.1.10" + +typed-array-byte-length@^1.0.0: + 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== + dependencies: + call-bind "^1.0.2" + for-each "^0.3.3" + has-proto "^1.0.1" + is-typed-array "^1.1.10" + +typed-array-byte-offset@^1.0.0: + 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== + dependencies: + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + for-each "^0.3.3" + has-proto "^1.0.1" + is-typed-array "^1.1.10" + +typed-array-length@^1.0.4: + 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== + dependencies: + call-bind "^1.0.2" + for-each "^0.3.3" + is-typed-array "^1.1.9" + +uid@2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/uid/-/uid-2.0.1.tgz" + integrity sha512-PF+1AnZgycpAIEmNtjxGBVmKbZAQguaa4pBUq6KNaGEcpzZ2klCNZLM34tsjp76maN00TttiiUf6zkIBpJQm2A== + dependencies: + "@lukeed/csprng" "^1.0.0" + +unbox-primitive@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz" + integrity sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw== + dependencies: + call-bind "^1.0.2" + has-bigints "^1.0.2" + has-symbols "^1.0.3" + which-boxed-primitive "^1.0.2" + +universalify@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/universalify/-/universalify-2.0.0.tgz" + integrity sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ== + +util-deprecate@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" + integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== + +validate-npm-package-license@^3.0.1: + 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== + dependencies: + spdx-correct "^3.0.0" + spdx-expression-parse "^3.0.0" + +wcwidth@>=1.0.1, wcwidth@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz" + integrity sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg== + dependencies: + defaults "^1.0.3" + +webidl-conversions@^3.0.0: + version "3.0.1" + resolved "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz" + integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== + +whatwg-url@^5.0.0: + version "5.0.0" + resolved "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz" + integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== + dependencies: + tr46 "~0.0.3" + webidl-conversions "^3.0.0" + +which-boxed-primitive@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz" + integrity sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg== + dependencies: + is-bigint "^1.0.1" + is-boolean-object "^1.1.0" + is-number-object "^1.0.4" + is-string "^1.0.5" + is-symbol "^1.0.3" + +which-typed-array@^1.1.10, which-typed-array@^1.1.11: + version "1.1.11" + resolved "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz" + integrity sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew== + dependencies: + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + for-each "^0.3.3" + gopd "^1.0.1" + has-tostringtag "^1.0.0" + +which@^1.2.9: + version "1.3.1" + resolved "https://registry.npmjs.org/which/-/which-1.3.1.tgz" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== + dependencies: + isexe "^2.0.0" + +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + +wrappy@1: + version "1.0.2" + resolved "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== + +y18n@^5.0.5: + version "5.0.8" + resolved "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz" + integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== + +yargs-parser@^20.2.2: + version "20.2.9" + resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz" + integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== + +yargs@^16.2.0: + version "16.2.0" + resolved "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz" + integrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw== + dependencies: + cliui "^7.0.2" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.0" + y18n "^5.0.5" + yargs-parser "^20.2.2" diff --git a/prism-agent/client/kotlin/.openapi-generator-ignore b/prism-agent/client/kotlin/.openapi-generator-ignore new file mode 100644 index 0000000000..a31dd6f39f --- /dev/null +++ b/prism-agent/client/kotlin/.openapi-generator-ignore @@ -0,0 +1,11 @@ +settings.gradle +build.gradle +docs + +# igore broken files +src/main/kotlin/io/iohk/atala/prism/models/UpdateManagedDIDServiceAction.kt +src/main/kotlin/io/iohk/atala/prism/models/UpdateManagedDIDServiceActionType.kt + +src/main/kotlin/io/iohk/atala/prism/models/Service.kt +src/main/kotlin/io/iohk/atala/prism/models/ServiceType.kt + diff --git a/prism-agent/client/kotlin/build.gradle b/prism-agent/client/kotlin/build.gradle new file mode 100644 index 0000000000..45a07edc1f --- /dev/null +++ b/prism-agent/client/kotlin/build.gradle @@ -0,0 +1,61 @@ +group 'io.iohk.atala.prism' + +wrapper { + gradleVersion = '7.5' + distributionUrl = "https://services.gradle.org/distributions/gradle-$gradleVersion-all.zip" +} + +buildscript { + ext.kotlin_version = '1.7.21' + + repositories { + mavenLocal() + mavenCentral() + } + dependencies { + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + } +} + +apply plugin: 'kotlin' +apply plugin: 'maven-publish' +apply plugin: 'java' + +repositories { + mavenLocal() + mavenCentral() +} + +test { + useJUnitPlatform() +} + +dependencies { + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" + implementation "com.google.code.gson:gson:2.9.0" + implementation "com.squareup.okhttp3:okhttp:4.10.0" + testImplementation "io.kotlintest:kotlintest-runner-junit5:3.4.2" +} + +java { + withJavadocJar() + withSourcesJar() +} + +publishing { + publications { + maven(MavenPublication) { + from components.java + } + } + repositories { + maven { + name = "GitHubPackages" + url = "https://maven.pkg.github.com/input-output-hk/atala-prism-building-blocks/" + credentials { + username = System.getenv("ATALA_GITHUB_ACTOR") + password = System.getenv("ATALA_GITHUB_TOKEN") + } + } + } +} \ No newline at end of file diff --git a/prism-agent/client/kotlin/gradle.properties b/prism-agent/client/kotlin/gradle.properties new file mode 100644 index 0000000000..8796076317 --- /dev/null +++ b/prism-agent/client/kotlin/gradle.properties @@ -0,0 +1 @@ +version=0.0.1 diff --git a/prism-agent/client/kotlin/gradle/wrapper/gradle-wrapper.jar b/prism-agent/client/kotlin/gradle/wrapper/gradle-wrapper.jar new file mode 100644 index 0000000000..c1962a79e2 Binary files /dev/null and b/prism-agent/client/kotlin/gradle/wrapper/gradle-wrapper.jar differ diff --git a/prism-agent/client/kotlin/gradle/wrapper/gradle-wrapper.properties b/prism-agent/client/kotlin/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000000..8707e8b506 --- /dev/null +++ b/prism-agent/client/kotlin/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-all.zip +networkTimeout=10000 +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists diff --git a/prism-agent/client/kotlin/gradlew b/prism-agent/client/kotlin/gradlew new file mode 100755 index 0000000000..aeb74cbb43 --- /dev/null +++ b/prism-agent/client/kotlin/gradlew @@ -0,0 +1,245 @@ +#!/bin/sh + +# +# Copyright © 2015-2021 the original authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +############################################################################## +# +# Gradle start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh Gradle +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# +############################################################################## + +# Attempt to set APP_HOME + +# Resolve links: $0 may be a link +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac +done + +# This is normally unused +# shellcheck disable=SC2034 +APP_BASE_NAME=${0##*/} +APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD=maximum + +warn () { + echo "$*" +} >&2 + +die () { + echo + echo "$*" + echo + exit 1 +} >&2 + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +nonstop=false +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; +esac + +CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + + +# Determine the Java command to use to start the JVM. +if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD=$JAVA_HOME/jre/sh/java + else + JAVACMD=$JAVA_HOME/bin/java + fi + if [ ! -x "$JAVACMD" ] ; then + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +else + JAVACMD=java + which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." +fi + +# Increase the maximum file descriptors if we can. +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac +fi + +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. + +# For Cygwin or MSYS, switch paths to Windows format before running java +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) + + # Now convert the arguments - kludge to limit ourselves to /bin/sh + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) + fi + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg + done +fi + + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' + +# Collect all arguments for the java command; +# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of +# shell script including quotes and variable substitutions, so put them in +# double quotes to make sure that they get re-expanded; and +# * put everything else in single quotes, so that it's not re-expanded. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -classpath "$CLASSPATH" \ + org.gradle.wrapper.GradleWrapperMain \ + "$@" + +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" +fi + +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# + +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' + +exec "$JAVACMD" "$@" diff --git a/prism-agent/client/kotlin/gradlew.bat b/prism-agent/client/kotlin/gradlew.bat new file mode 100644 index 0000000000..93e3f59f13 --- /dev/null +++ b/prism-agent/client/kotlin/gradlew.bat @@ -0,0 +1,92 @@ +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem + +@if "%DEBUG%"=="" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +set DIRNAME=%~dp0 +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if %ERRORLEVEL% equ 0 goto execute + +echo. +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +echo. +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* + +:end +@rem End local scope for the variables with windows NT shell +if %ERRORLEVEL% equ 0 goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/prism-agent/client/kotlin/settings.gradle b/prism-agent/client/kotlin/settings.gradle new file mode 100644 index 0000000000..d936b678f8 --- /dev/null +++ b/prism-agent/client/kotlin/settings.gradle @@ -0,0 +1,2 @@ + +rootProject.name = 'prism-kotlin-client' \ No newline at end of file diff --git a/prism-agent/client/kotlin/src/main/kotlin/io/iohk/atala/prism/models/Service.kt b/prism-agent/client/kotlin/src/main/kotlin/io/iohk/atala/prism/models/Service.kt new file mode 100644 index 0000000000..95592cba35 --- /dev/null +++ b/prism-agent/client/kotlin/src/main/kotlin/io/iohk/atala/prism/models/Service.kt @@ -0,0 +1,44 @@ +/** + * + * Please note: + * This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * Do not edit this file manually. + * + */ + +@file:Suppress( + "ArrayInDataClass", + "EnumEntryName", + "RemoveRedundantQualifierName", + "UnusedImport" +) + +package io.iohk.atala.prism.models + +import io.iohk.atala.prism.models.Json + +import com.google.gson.annotations.SerializedName + +/** + * A service expressed in the DID document. https://www.w3.org/TR/did-core/#services + * + * @param id The id of the service. Requires a URI fragment when use in create / update DID. Returns the full ID (with DID prefix) when resolving DID + * @param type + * @param serviceEndpoint + */ + + +data class Service ( + + /* The id of the service. Requires a URI fragment when use in create / update DID. Returns the full ID (with DID prefix) when resolving DID */ + @SerializedName("id") + val id: kotlin.String, + + @SerializedName("type") + val type: kotlin.collections.List? = null, + + @SerializedName("serviceEndpoint") + val serviceEndpoint: Json + +) + diff --git a/prism-agent/client/kotlin/src/main/kotlin/io/iohk/atala/prism/models/UpdateManagedDIDServiceAction.kt b/prism-agent/client/kotlin/src/main/kotlin/io/iohk/atala/prism/models/UpdateManagedDIDServiceAction.kt new file mode 100644 index 0000000000..f9c1c5e2b4 --- /dev/null +++ b/prism-agent/client/kotlin/src/main/kotlin/io/iohk/atala/prism/models/UpdateManagedDIDServiceAction.kt @@ -0,0 +1,44 @@ +/** + * + * Please note: + * This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * Do not edit this file manually. + * + */ + +@file:Suppress( + "ArrayInDataClass", + "EnumEntryName", + "RemoveRedundantQualifierName", + "UnusedImport" +) + +package io.iohk.atala.prism.models + +import io.iohk.atala.prism.models.Json + +import com.google.gson.annotations.SerializedName + +/** + * A patch to existing Service. 'type' and 'serviceEndpoint' cannot both be empty. + * + * @param id The id of the service to update + * @param type + * @param serviceEndpoint + */ + + +data class UpdateManagedDIDServiceAction ( + + /* The id of the service to update */ + @SerializedName("id") + val id: kotlin.String, + + @SerializedName("type") + val type: kotlin.collections.List? = null, + + @SerializedName("serviceEndpoint") + val serviceEndpoint: Json? = null + +) + diff --git a/prism-agent/client/python/.openapi-generator-ignore b/prism-agent/client/python/.openapi-generator-ignore new file mode 100644 index 0000000000..659ddbfdf9 --- /dev/null +++ b/prism-agent/client/python/.openapi-generator-ignore @@ -0,0 +1 @@ +setup.py diff --git a/prism-agent/client/python/setup.py b/prism-agent/client/python/setup.py new file mode 100644 index 0000000000..56b366299b --- /dev/null +++ b/prism-agent/client/python/setup.py @@ -0,0 +1,41 @@ +# coding: utf-8 + +""" + Prism Agent + + No description provided + + The version of the OpenAPI document: 1.0.0 + Generated by: https://openapi-generator.tech +""" + +from setuptools import setup, find_packages # noqa: H301 + +NAME = "prism-python-client" +VERSION = "0.0.1" + +REQUIRES = [ + "certifi >= 14.5.14", + "frozendict ~= 2.3.4", + "python-dateutil ~= 2.7.0", + "setuptools >= 21.0.0", + "typing_extensions ~= 4.3.0", + "urllib3 ~= 1.26.7", +] + +setup( + name=NAME, + version=VERSION, + description="Prism Agent Client", + author="Allain Magyar", + author_email="", + url="https://github.com/input-output-iohk/prism-client-generator", + keywords=["Prism Agent"], + python_requires=">=3.7", + install_requires=REQUIRES, + packages=find_packages(exclude=["test", "tests"]), + include_package_data=True, + long_description="""\ + Prism-agent models generated from OpenAPI Specification + """ +) diff --git a/prism-agent/client/typescript/.openapi-generator-ignore b/prism-agent/client/typescript/.openapi-generator-ignore new file mode 100644 index 0000000000..fa9263023d --- /dev/null +++ b/prism-agent/client/typescript/.openapi-generator-ignore @@ -0,0 +1,6 @@ +package.json +docs + +# ignore broken files +models/Service.ts +models/UpdateManagedDIDServiceAction.ts diff --git a/prism-agent/client/typescript/models/Service.ts b/prism-agent/client/typescript/models/Service.ts new file mode 100644 index 0000000000..5446e9d0e9 --- /dev/null +++ b/prism-agent/client/typescript/models/Service.ts @@ -0,0 +1,52 @@ +/** + * Prism Agent + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { Json } from '../models/Json'; + +/** +* A service expressed in the DID document. https://www.w3.org/TR/did-core/#services +*/ +export class Service { + /** + * The id of the service. Requires a URI fragment when use in create / update DID. Returns the full ID (with DID prefix) when resolving DID + */ + 'id': string; + 'type': Array; + 'serviceEndpoint': Json; + + static readonly discriminator: string | undefined = undefined; + + static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ + { + "name": "id", + "baseName": "id", + "type": "string", + "format": "" + }, + { + "name": "type", + "baseName": "type", + "type": "ServiceType", + "format": "" + }, + { + "name": "serviceEndpoint", + "baseName": "serviceEndpoint", + "type": "Json", + "format": "" + } ]; + + static getAttributeTypeMap() { + return Service.attributeTypeMap; + } +} + diff --git a/prism-agent/client/typescript/models/UpdateManagedDIDServiceAction.ts b/prism-agent/client/typescript/models/UpdateManagedDIDServiceAction.ts new file mode 100644 index 0000000000..987d8434fd --- /dev/null +++ b/prism-agent/client/typescript/models/UpdateManagedDIDServiceAction.ts @@ -0,0 +1,52 @@ +/** + * Prism Agent + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { Json } from '../models/Json'; + +/** +* A patch to existing Service. \'type\' and \'serviceEndpoint\' cannot both be empty. +*/ +export class UpdateManagedDIDServiceAction { + /** + * The id of the service to update + */ + 'id': string; + 'type'?: Array; + 'serviceEndpoint'?: Json; + + static readonly discriminator: string | undefined = undefined; + + static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ + { + "name": "id", + "baseName": "id", + "type": "string", + "format": "" + }, + { + "name": "type", + "baseName": "type", + "type": "UpdateManagedDIDServiceActionType", + "format": "" + }, + { + "name": "serviceEndpoint", + "baseName": "serviceEndpoint", + "type": "Json", + "format": "" + } ]; + + static getAttributeTypeMap() { + return UpdateManagedDIDServiceAction.attributeTypeMap; + } +} + diff --git a/prism-agent/client/typescript/package.json b/prism-agent/client/typescript/package.json new file mode 100644 index 0000000000..7cbeb1d689 --- /dev/null +++ b/prism-agent/client/typescript/package.json @@ -0,0 +1,42 @@ +{ + "name": "@input-output-hk/prism-typescript-client", + "version": "0.0.1", + "description": "TypeScript OpenAPI client for Atala PRISM V2 Agent", + "author": "allain.magyar@iohk.io", + "repository": { + "type": "git", + "url": "https://github.com/input-output-hk/atala-prism-building-blocks/" + }, + "keywords": [ + "fetch", + "typescript", + "openapi-client", + "openapi-generator" + ], + "license": "Unlicensed", + "main": "./dist/index.js", + "type": "commonjs", + "exports": { + ".": "./dist/index.js" + }, + "files": [ + "./dist" + ], + "typings": "./dist/index.d.ts", + "scripts": { + "build": "tsc", + "prepare": "npm run build" + }, + "dependencies": { + "whatwg-fetch": "^3.0.0", + "es6-promise": "^4.2.4", + "url-parse": "^1.4.3" + }, + "devDependencies": { + "@types/url-parse": "1.4.4", + "typescript": "^4.0" + }, + "publishConfig": { + "registry": "https://npm.pkg.github.com" + } +} diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServer.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServer.scala index 030a203ab2..5102664466 100644 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServer.scala +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServer.scala @@ -2,6 +2,7 @@ package io.iohk.atala.agent.server import io.circe.* import io.circe.parser.* +import io.iohk.atala.agent.server.DidCommHttpServerError.{DIDCommMessageParsingError, RequestBodyParsingError} import io.iohk.atala.agent.walletapi.model.error.DIDSecretStorageError import io.iohk.atala.agent.walletapi.service.ManagedDIDService import io.iohk.atala.connect.core.model.error.ConnectionServiceError @@ -21,9 +22,10 @@ import zio.* import zio.http.* import zio.http.model.* -import java.io.IOException +import java.util.UUID object DidCommHttpServer { + def run(didCommServicePort: Int) = { val server = { val config = ServerConfig(address = new java.net.InetSocketAddress(didCommServicePort)) @@ -41,13 +43,13 @@ object DidCommHttpServer { private def didCommServiceEndpoint: HttpApp[ DidOps & DidAgent & CredentialService & PresentationService & ConnectionService & ManagedDIDService & HttpClient & DidAgent & DIDResolver, - Throwable + Nothing ] = Http.collectZIO[Request] { case Method.GET -> !! / "did" => for { didCommService <- ZIO.service[DidAgent] str = didCommService.id.value - } yield (Response.text(str)) + } yield Response.text(str) case req @ Method.POST -> !! if req.headersAsList @@ -56,18 +58,23 @@ object DidCommHttpServer { h.value.toString.equalsIgnoreCase(MediaTypes.contentTypeEncrypted) ) => val result = for { - data <- req.body.asString + data <- req.body.asString.mapError(e => RequestBodyParsingError(e.getMessage)) _ <- webServerProgram(data) } yield Response.ok result - .tapError { error => - ZIO.logErrorCause("Fail to POST form webServerProgram", Cause.fail(error)) - } - .mapError { - case ex: DIDSecretStorageError => ex - case ex: MercuryThrowable => mercuryErrorAsThrowable(ex) + .tapError(error => ZIO.logErrorCause("Error processing incoming DIDComm message", Cause.fail(error))) + .catchAll { + case _: RequestBodyParsingError => ZIO.succeed(Response.status(Status.BadRequest)) + case _: DIDCommMessageParsingError => ZIO.succeed(Response.status(Status.BadRequest)) + case _: ParseResponse => ZIO.succeed(Response.status(Status.BadRequest)) + case _: DIDSecretStorageError => ZIO.succeed(Response.status(Status.UnprocessableEntity)) + case _: SendMessageError => ZIO.succeed(Response.status(Status.UnprocessableEntity)) + case _: ConnectionServiceError => ZIO.succeed(Response.status(Status.UnprocessableEntity)) + case _: CredentialServiceError => ZIO.succeed(Response.status(Status.UnprocessableEntity)) + case _: PresentationError => ZIO.succeed(Response.status(Status.UnprocessableEntity)) } + } private[this] def extractFirstRecipientDid(jsonMessage: String): IO[ParsingFailure | DecodingFailure, String] = { @@ -92,211 +99,136 @@ object DidCommHttpServer { } yield msg.message } - private def webServerProgram(jsonString: String): ZIO[ - DidOps & CredentialService & PresentationService & ConnectionService & ManagedDIDService & HttpClient & DidAgent & - DIDResolver, - MercuryThrowable | DIDSecretStorageError, - Unit - ] = { - - ZIO.logAnnotate("request-id", java.util.UUID.randomUUID.toString()) { + private def webServerProgram(jsonString: String) = { + ZIO.logAnnotate("request-id", UUID.randomUUID.toString) { for { _ <- ZIO.logInfo("Received new message") _ <- ZIO.logTrace(jsonString) msg <- unpackMessage(jsonString) - credentialService <- ZIO.service[CredentialService] - connectionService <- ZIO.service[ConnectionService] - _ <- { - msg.piuri match { - // ################## - // ### Trust-Ping ### - // ################## - case s if s == TrustPing.`type` => - for { - _ <- ZIO.logInfo("*" * 100) - trustPingMsg = TrustPing.fromMessage(msg) - _ <- ZIO.logInfo(s"TrustPing from ${msg.from}: " + msg + " -> " + trustPingMsg) - trustPingResponseMsg = trustPingMsg match { - case Left(value) => None - case Right(trustPing) => - trustPing.body.response_requested match - case None => Some(trustPing.makeReply.makeMessage) - case Some(true) => Some(trustPing.makeReply.makeMessage) - case Some(false) => None - } - _ <- trustPingResponseMsg match - case None => ZIO.logWarning(s"Did not reply to the ${TrustPing.`type`}") - case Some(message) => - MessagingService - .send(message) - .flatMap(response => - response.status match - case c if c >= 200 & c < 300 => ZIO.unit - case c => ZIO.logWarning(response.toString()) - ) - } yield () - - // ######################## - // ### issue-credential ### - // ######################## - case s if s == ProposeCredential.`type` => // Issuer - for { - _ <- ZIO.logInfo("*" * 100) - _ <- ZIO.logInfo("As an Issuer in issue-credential:") - _ <- ZIO.logInfo("Got ProposeCredential: " + msg) - // TODO: Use service - _ <- ZIO.service[CredentialService] - - // TODO - } yield () - - case s if s == OfferCredential.`type` => // Holder - for { - _ <- ZIO.logInfo("*" * 100) - _ <- ZIO.logInfo("As an Holder in issue-credential:") - _ <- ZIO.logInfo("Got OfferCredential: " + msg) - offerFromIssuer = OfferCredential.readFromMessage(msg) - _ <- credentialService - .receiveCredentialOffer(offerFromIssuer) - .catchSome { case CredentialServiceError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> - ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - - } yield () - - case s if s == RequestCredential.`type` => // Issuer - for { - _ <- ZIO.logInfo("*" * 100) - _ <- ZIO.logInfo("As an Issuer in issue-credential:") - requestCredential = RequestCredential.readFromMessage(msg) - _ <- ZIO.logInfo("Got RequestCredential: " + requestCredential) - credentialService <- ZIO.service[CredentialService] - // todoTestOption - _ <- credentialService - .receiveCredentialRequest(requestCredential) - .catchSome { case CredentialServiceError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> - ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - - // TODO todoTestOption if none - } yield () - - case s if s == IssueCredential.`type` => // Holder - for { - _ <- ZIO.logInfo("*" * 100) - _ <- ZIO.logInfo("As an Holder in issue-credential:") - issueCredential = IssueCredential.readFromMessage(msg) - _ <- ZIO.logInfo("Got IssueCredential: " + issueCredential) - credentialService <- ZIO.service[CredentialService] - _ <- credentialService - .receiveCredentialIssue(issueCredential) - .catchSome { case CredentialServiceError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> - ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - } yield () - - // ##################### - // ### present-proof ### - // ##################### - - case s if s == ProposePresentation.`type` => - for { - _ <- ZIO.unit - request = ProposePresentation.readFromMessage(msg) - _ <- ZIO.logInfo("As a Verifier in present-proof got ProposePresentation: " + request) - service <- ZIO.service[PresentationService] - _ <- service - .receiveProposePresentation(request) - .catchSome { case PresentationError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - } yield () + _ <- (handleTrustPing orElse + handleConnect orElse + handleIssueCredential orElse + handlePresentProof orElse + handleUnknownMessage)(msg) + } yield () + } + } - case s if s == RequestPresentation.`type` => - for { - _ <- ZIO.unit - request = RequestPresentation.readFromMessage(msg) - _ <- ZIO.logInfo("As a Prover in present-proof got RequestPresentation: " + request) - service <- ZIO.service[PresentationService] - _ <- service - .receiveRequestPresentation(None, request) - .catchSome { case PresentationError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - } yield () - case s if s == Presentation.`type` => - for { - _ <- ZIO.unit - request = Presentation.readFromMessage(msg) - _ <- ZIO.logInfo("As a Verifier in present-proof got Presentation: " + request) - service <- ZIO.service[PresentationService] - _ <- service - .receivePresentation(request) - .catchSome { case PresentationError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - } yield () + /* + * Trust Ping + */ + private val handleTrustPing + : PartialFunction[Message, ZIO[DidOps & DidAgent & DIDResolver & HttpClient, SendMessageError, Unit]] = { + case msg if msg.piuri == TrustPing.`type` => + for { + trustPingMsg <- ZIO.succeed(TrustPing.fromMessage(msg)) + _ <- ZIO.logInfo(s"Got TrustPing from ${msg.from}: $trustPingMsg") + trustPingResponseMsg = trustPingMsg match { + case Left(value) => None + case Right(trustPing) => + trustPing.body.response_requested match + case None => Some(trustPing.makeReply.makeMessage) + case Some(true) => Some(trustPing.makeReply.makeMessage) + case Some(false) => None + } + _ <- trustPingResponseMsg match + case None => ZIO.logWarning(s"Did not reply to the ${TrustPing.`type`}") + case Some(message) => + MessagingService + .send(message) + .flatMap(response => + response.status match + case c if c >= 200 & c < 300 => ZIO.unit + case _ => ZIO.logWarning(response.toString) + ) + } yield () + } - case s if s == ConnectionRequest.`type` => - for { - _ <- ZIO.logInfo("*" * 100) - _ <- ZIO.logInfo("As an Inviter in connect:") - connectionRequest <- ConnectionRequest.fromMessage(msg) match { - case Left(error) => ZIO.fail(new RuntimeException(error)) - case Right(value) => ZIO.succeed(value) - } - _ <- ZIO.logInfo("Got ConnectionRequest: " + connectionRequest) - // Receive and store ConnectionRequest - maybeRecord <- connectionService - .receiveConnectionRequest(connectionRequest) - .catchSome { case ConnectionServiceError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> - ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - // Accept the ConnectionRequest - _ <- connectionService - .acceptConnectionRequest(maybeRecord.id) - .catchSome { case ConnectionServiceError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> - ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - } yield () + /* + * Connect + */ + private val handleConnect + : PartialFunction[Message, ZIO[ConnectionService, DIDCommMessageParsingError | ConnectionServiceError, Unit]] = { + case msg if msg.piuri == ConnectionRequest.`type` => + for { + connectionRequest <- ZIO + .fromEither(ConnectionRequest.fromMessage(msg)) + .mapError(DIDCommMessageParsingError.apply) + _ <- ZIO.logInfo("As an Inviter in connect got ConnectionRequest: " + connectionRequest) + connectionService <- ZIO.service[ConnectionService] + maybeRecord <- connectionService.receiveConnectionRequest(connectionRequest) + _ <- connectionService.acceptConnectionRequest(maybeRecord.id) + } yield () + case msg if msg.piuri == ConnectionResponse.`type` => + for { + connectionResponse <- ZIO + .fromEither(ConnectionResponse.fromMessage(msg)) + .mapError(DIDCommMessageParsingError.apply) + _ <- ZIO.logInfo("As an Invitee in connect got ConnectionResponse: " + connectionResponse) + connectionService <- ZIO.service[ConnectionService] + _ <- connectionService.receiveConnectionResponse(connectionResponse) + } yield () + } - // As an Invitee, I received a ConnectionResponse from an Inviter who replied to my ConnectionRequest. - case s if s == ConnectionResponse.`type` => - for { - _ <- ZIO.logInfo("*" * 100) - _ <- ZIO.logInfo("As an Invitee in connect:") - connectionResponse <- ConnectionResponse.fromMessage(msg) match { - case Left(error) => ZIO.fail(new RuntimeException(error)) - case Right(value) => ZIO.succeed(value) - } - _ <- ZIO.logInfo("Got ConnectionResponse: " + connectionResponse) - _ <- connectionService - .receiveConnectionResponse(connectionResponse) - .catchSome { case ConnectionServiceError.RepositoryError(cause) => - ZIO.logError(cause.getMessage()) *> - ZIO.fail(cause) - } - .catchAll { case ex: IOException => ZIO.fail(ex) } - } yield () + /* + * Issue Credential + */ + private val handleIssueCredential: PartialFunction[Message, ZIO[CredentialService, CredentialServiceError, Unit]] = { + case msg if msg.piuri == OfferCredential.`type` => + for { + offerFromIssuer <- ZIO.succeed(OfferCredential.readFromMessage(msg)) + _ <- ZIO.logInfo("As an Holder in issue-credential got OfferCredential: " + offerFromIssuer) + credentialService <- ZIO.service[CredentialService] + _ <- credentialService.receiveCredentialOffer(offerFromIssuer) + } yield () + case msg if msg.piuri == RequestCredential.`type` => + for { + requestCredential <- ZIO.succeed(RequestCredential.readFromMessage(msg)) + _ <- ZIO.logInfo("As an Issuer in issue-credential got RequestCredential: " + requestCredential) + credentialService <- ZIO.service[CredentialService] + _ <- credentialService.receiveCredentialRequest(requestCredential) + } yield () + case msg if msg.piuri == IssueCredential.`type` => + for { + issueCredential <- ZIO.succeed(IssueCredential.readFromMessage(msg)) + _ <- ZIO.logInfo("As an Holder in issue-credential got IssueCredential: " + issueCredential) + credentialService <- ZIO.service[CredentialService] + _ <- credentialService.receiveCredentialIssue(issueCredential) + } yield () + } - case _ => ZIO.succeed("Unknown Message Type") - } - } + /* + * Present Proof + */ + private val handlePresentProof: PartialFunction[Message, ZIO[PresentationService, PresentationError, Unit]] = { + case msg if msg.piuri == ProposePresentation.`type` => + for { + proposePresentation <- ZIO.succeed(ProposePresentation.readFromMessage(msg)) + _ <- ZIO.logInfo("As a Verifier in present-proof got ProposePresentation: " + proposePresentation) + service <- ZIO.service[PresentationService] + _ <- service.receiveProposePresentation(proposePresentation) } yield () - } + case msg if msg.piuri == RequestPresentation.`type` => + for { + requestPresentation <- ZIO.succeed(RequestPresentation.readFromMessage(msg)) + _ <- ZIO.logInfo("As a Prover in present-proof got RequestPresentation: " + requestPresentation) + service <- ZIO.service[PresentationService] + _ <- service.receiveRequestPresentation(None, requestPresentation) + } yield () + case msg if msg.piuri == Presentation.`type` => + for { + presentation <- ZIO.succeed(Presentation.readFromMessage(msg)) + _ <- ZIO.logInfo("As a Verifier in present-proof got Presentation: " + presentation) + service <- ZIO.service[PresentationService] + _ <- service.receivePresentation(presentation) + } yield () + } + + /* + * Unknown Message + */ + private val handleUnknownMessage: PartialFunction[Message, UIO[String]] = { case _ => + ZIO.succeed("Unknown Message Type") } } diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServerError.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServerError.scala new file mode 100644 index 0000000000..d66da61b72 --- /dev/null +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/agent/server/DidCommHttpServerError.scala @@ -0,0 +1,8 @@ +package io.iohk.atala.agent.server + +sealed trait DidCommHttpServerError + +object DidCommHttpServerError { + case class RequestBodyParsingError(error: String) extends DidCommHttpServerError + case class DIDCommMessageParsingError(error: String) extends DidCommHttpServerError +} diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/issue/controller/http/IssueCredentialRecord.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/issue/controller/http/IssueCredentialRecord.scala index 13cb6c3549..3ff3f43f46 100644 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/issue/controller/http/IssueCredentialRecord.scala +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/issue/controller/http/IssueCredentialRecord.scala @@ -4,9 +4,9 @@ import io.iohk.atala.api.http.Annotation import io.iohk.atala.issue.controller.http.IssueCredentialRecord.annotations import io.iohk.atala.mercury.model.{AttachmentDescriptor, Base64} import io.iohk.atala.pollux.core.model.IssueCredentialRecord as PolluxIssueCredentialRecord -import sttp.tapir.Schema -import sttp.tapir.Schema.annotations.{description, encodedExample} +import sttp.tapir.Schema.annotations.{description, encodedExample, validate} import sttp.tapir.json.zio.schemaForZioJsonValue +import sttp.tapir.{Schema, Validator} import zio.json.* import zio.json.ast.Json @@ -68,9 +68,11 @@ final case class IssueCredentialRecord( updatedAt: Option[OffsetDateTime] = None, @description(annotations.role.description) @encodedExample(annotations.role.example) + @validate(annotations.role.validator) role: String, @description(annotations.protocolState.description) @encodedExample(annotations.protocolState.example) + @validate(annotations.protocolState.validator) protocolState: String, @description(annotations.jwtCredential.description) @encodedExample(annotations.jwtCredential.example) @@ -175,13 +177,37 @@ object IssueCredentialRecord { object role extends Annotation[String]( description = "The role played by the Prism agent in the credential issuance flow.", - example = "Issuer" + example = "Issuer", + validator = Validator.enumeration( + List( + "Issuer", + "Holder" + ) + ) ) object protocolState - extends Annotation[String]( // TODO Support Enum + extends Annotation[String]( description = "The current state of the issue credential protocol execution.", - example = "OfferPending" + example = "OfferPending", + validator = Validator.enumeration( + List( + "OfferPending", + "OfferSent", + "OfferReceived", + "RequestPending", + "RequestGenerated", + "RequestSent", + "RequestReceived", + "CredentialPending", + "CredentialGenerated", + "CredentialSent", + "CredentialReceived", + "ProblemReportPending", + "ProblemReportSent", + "ProblemReportReceived" + ) + ) ) object jwtCredential diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofController.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofController.scala index 06643e1027..3d862f38ca 100644 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofController.scala +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofController.scala @@ -14,7 +14,7 @@ trait PresentProofController { requestPresentationInput: RequestPresentationInput )(implicit rc: RequestContext - ): IO[ErrorResponse, RequestPresentationOutput] + ): IO[ErrorResponse, PresentationStatus] def getPresentations( paginationInput: PaginationInput, diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofControllerImpl.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofControllerImpl.scala index 3c1c2849ef..0b00e7758a 100644 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofControllerImpl.scala +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofControllerImpl.scala @@ -24,8 +24,8 @@ class PresentProofControllerImpl( with ControllerHelper { override def requestPresentation(request: RequestPresentationInput)(implicit rc: RequestContext - ): IO[ErrorResponse, RequestPresentationOutput] = { - val result: IO[ConnectionServiceError | PresentationError, RequestPresentationOutput] = for { + ): IO[ErrorResponse, PresentationStatus] = { + val result: IO[ConnectionServiceError | PresentationError, PresentationStatus] = for { didIdPair <- getPairwiseDIDs(request.connectionId).provide(ZLayer.succeed(connectionService)) record <- presentationService .createPresentationRecord( @@ -42,7 +42,7 @@ class PresentProofControllerImpl( }, options = request.options.map(x => Options(x.challenge, x.domain)), ) - } yield RequestPresentationOutput.fromDomain(record) + } yield PresentationStatus.fromDomain(record) result.mapError { case e: ConnectionServiceError => ConnectionController.toHttpError(e) diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofEndpoints.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofEndpoints.scala index 53797d2d0f..3289aa2f71 100644 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofEndpoints.scala +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/PresentProofEndpoints.scala @@ -17,7 +17,7 @@ object PresentProofEndpoints { val requestPresentation: PublicEndpoint[ (RequestContext, RequestPresentationInput), ErrorResponse, - RequestPresentationOutput, + PresentationStatus, Any ] = endpoint.post @@ -33,7 +33,7 @@ object PresentProofEndpoints { "The proof presentation request was created successfully and will be sent asynchronously to the Prover." ) ) - .out(jsonBody[RequestPresentationOutput]) + .out(jsonBody[PresentationStatus]) .errorOut(basicFailures) val getAllPresentations diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/PresentationStatus.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/PresentationStatus.scala index ccec1c1fd9..df0dc162fe 100644 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/PresentationStatus.scala +++ b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/PresentationStatus.scala @@ -15,6 +15,10 @@ final case class PresentationStatus( @description(annotations.thid.description) @encodedExample(annotations.thid.example) thid: String, + @description(annotations.role.description) + @encodedExample(annotations.role.example) + @validate(annotations.role.validator) + role: String, @description(annotations.status.description) @encodedExample(annotations.status.example) @validate(annotations.status.validator) @@ -45,6 +49,7 @@ object PresentationStatus { PresentationStatus( domain.id.value, thid = domain.thid.value, + role = domain.role.toString, status = domain.protocolState.toString, proofs = Seq.empty, data = data, @@ -67,7 +72,17 @@ object PresentationStatus { "The value will identical on both sides of the presentation flow (verifier and prover)", example = "0527aea1-d131-3948-a34d-03af39aba8b4" ) - + object role + extends Annotation[String]( + description = "The role played by the Prism agent in the proof presentation flow.", + example = "Verifier", + validator = Validator.enumeration( + List( + "Verifier", + "Prover" + ) + ) + ) object status extends Annotation[String]( description = "The current state of the proof presentation record.", diff --git a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/RequestPresentationOutput.scala b/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/RequestPresentationOutput.scala deleted file mode 100644 index 03f58c1c84..0000000000 --- a/prism-agent/service/server/src/main/scala/io/iohk/atala/presentproof/controller/http/RequestPresentationOutput.scala +++ /dev/null @@ -1,35 +0,0 @@ -package io.iohk.atala.presentproof.controller.http - -import io.iohk.atala.api.http.Annotation -import io.iohk.atala.pollux.core.model.PresentationRecord -import io.iohk.atala.presentproof.controller.http.RequestPresentationOutput.annotations -import sttp.tapir.Schema -import sttp.tapir.Schema.annotations.{description, encodedExample} -import zio.json.{DeriveJsonDecoder, DeriveJsonEncoder, JsonDecoder, JsonEncoder} - -final case class RequestPresentationOutput( - @description(annotations.presentationId.description) - @encodedExample(annotations.presentationId.example) - presentationId: String -) - -object RequestPresentationOutput { - def fromDomain(domain: PresentationRecord): RequestPresentationOutput = - RequestPresentationOutput(domain.id.value) - - object annotations { - object presentationId - extends Annotation[String]( - description = "Ref to the id on the presentation (db ref)", - example = "11c91493-01b3-4c4d-ac36-b336bab5bddf" - ) - } - - given encoder: JsonEncoder[RequestPresentationOutput] = - DeriveJsonEncoder.gen[RequestPresentationOutput] - - given decoder: JsonDecoder[RequestPresentationOutput] = - DeriveJsonDecoder.gen[RequestPresentationOutput] - - given schema: Schema[RequestPresentationOutput] = Schema.derived -} diff --git a/prism-agent/service/server/src/test/resources/logback.xml b/prism-agent/service/server/src/test/resources/logback.xml index 96c43744da..4eee19c9b4 100644 --- a/prism-agent/service/server/src/test/resources/logback.xml +++ b/prism-agent/service/server/src/test/resources/logback.xml @@ -13,8 +13,12 @@ - + + - \ No newline at end of file + diff --git a/tests/performance-tests/atala-performance-tests-k6/package.json b/tests/performance-tests/atala-performance-tests-k6/package.json index e5c1a2b3f8..b0a9fa45d5 100644 --- a/tests/performance-tests/atala-performance-tests-k6/package.json +++ b/tests/performance-tests/atala-performance-tests-k6/package.json @@ -25,6 +25,7 @@ "start": "webpack" }, "dependencies": { - "@input-output-hk/prism-typescript-client": "0.1.0" + "@input-output-hk/prism-typescript-client": "1.9.2", + "uuid": "^9.0.0" } } diff --git a/tests/performance-tests/atala-performance-tests-k6/src/actors/Holder.ts b/tests/performance-tests/atala-performance-tests-k6/src/actors/Holder.ts index cd83663280..e574af988d 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/actors/Holder.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/actors/Holder.ts @@ -88,8 +88,8 @@ export class Holder extends Actor { /** * Waits for a credential offer and accepts it. */ - waitAndAcceptCredentialOffer() { - this.credential = this.credentialsService.waitForCredentialOffer(); + waitAndAcceptCredentialOffer(thid: string) { + this.credential = this.credentialsService.waitForCredentialOffer(thid); this.credentialsService.acceptCredentialOffer(this.credential, this.did!); this.credentialsService.waitForCredentialState(this.credential, "RequestSent"); } @@ -104,8 +104,8 @@ export class Holder extends Actor { /** * Waits for a proof request, accepts it, and waits for the presentation to be sent. */ - waitAndAcceptProofRequest() { - const presentation = this.proofsService.waitForProof(); + waitAndAcceptProofRequest(thid: string) { + const presentation = this.proofsService.waitForProof(thid); this.proofsService.acceptProofRequest(presentation, this.credential!.recordId); this.proofsService.waitForPresentationState(presentation.presentationId, "PresentationSent"); } diff --git a/tests/performance-tests/atala-performance-tests-k6/src/actors/Issuer.ts b/tests/performance-tests/atala-performance-tests-k6/src/actors/Issuer.ts index b65422be44..fa377774fb 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/actors/Issuer.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/actors/Issuer.ts @@ -1,4 +1,4 @@ -import { Connection, IssueCredentialRecord } from "@input-output-hk/prism-typescript-client"; +import { Connection, CredentialSchemaResponse, IssueCredentialRecord } from "@input-output-hk/prism-typescript-client"; import { Actor } from "./Actor"; import { ISSUER_AGENT_API_KEY, ISSUER_AGENT_URL } from "../common/Config"; @@ -19,6 +19,11 @@ export class Issuer extends Actor { */ credential: IssueCredentialRecord | undefined; + /** + * The schema for issued credential. + */ + schema: CredentialSchemaResponse | undefined; + /** * The DID template used to create a DID for Issuer. * assertionMethod is the only purpose for the public key required for Issuer. @@ -74,11 +79,15 @@ export class Issuer extends Actor { this.didService.waitForDidState(this.longFormDid!, "PUBLISHED"); } + createCredentialSchema() { + this.schema = this.credentialsService.createCredentialSchema(this.did!); + } + /** * Creates a credential offer for the holder. */ createCredentialOffer() { - this.credential = this.credentialsService.createCredentialOffer(this.did!, this.connectionWithHolder!); + this.credential = this.credentialsService.createCredentialOffer(this.did!, this.connectionWithHolder!, this.schema!); } /** diff --git a/tests/performance-tests/atala-performance-tests-k6/src/actors/Verifier.ts b/tests/performance-tests/atala-performance-tests-k6/src/actors/Verifier.ts index 6129b441d9..7c051719d1 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/actors/Verifier.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/actors/Verifier.ts @@ -1,4 +1,4 @@ -import { Connection } from "@input-output-hk/prism-typescript-client"; +import { Connection, PresentationStatus } from "@input-output-hk/prism-typescript-client"; import { Actor } from "./Actor"; import { VERIFIER_AGENT_API_KEY, VERIFIER_AGENT_URL } from "../common/Config"; @@ -12,7 +12,7 @@ export class Verifier extends Actor { /** * Presentation ID. */ - presentationId: string | undefined; + presentation: PresentationStatus | undefined; /** * Creates a new instance of Verifier. @@ -42,13 +42,14 @@ export class Verifier extends Actor { * Requests proof from the holder. */ requestProof() { - this.presentationId = this.proofsService.requestProof(this.connectionWithHolder!); + let presentationId = this.proofsService.requestProof(this.connectionWithHolder!); + this.presentation = this.proofsService.getPresentation(presentationId); } /** * Acknowledges the proof received from the holder. */ acknowledgeProof() { - this.proofsService.waitForPresentationState(this.presentationId!, "PresentationVerified"); + this.proofsService.waitForPresentationState(this.presentation!.presentationId!, "PresentationVerified"); } } diff --git a/tests/performance-tests/atala-performance-tests-k6/src/common/CredentialsService.ts b/tests/performance-tests/atala-performance-tests-k6/src/common/CredentialsService.ts index 6f1ee9f81a..8961b64b9a 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/common/CredentialsService.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/common/CredentialsService.ts @@ -1,8 +1,8 @@ import { sleep } from "k6"; import { HttpService } from "./HttpService"; -import { WAITING_LOOP_MAX_ITERATIONS, WAITING_LOOP_PAUSE_INTERVAL } from "./Config"; -import { IssueCredentialRecord, Connection } from "@input-output-hk/prism-typescript-client"; -import vu from "k6/execution"; +import { ISSUER_AGENT_URL, WAITING_LOOP_MAX_ITERATIONS, WAITING_LOOP_PAUSE_INTERVAL } from "./Config"; +import { IssueCredentialRecord, Connection, CredentialSchemaResponse } from "@input-output-hk/prism-typescript-client"; +import {v4 as uuidv4} from 'uuid'; /** * A service class for managing credentials in the application. @@ -16,9 +16,16 @@ export class CredentialsService extends HttpService { * @param {Connection} connection - The connection object. * @returns {IssueCredentialRecord} The created credential offer record. */ - createCredentialOffer(issuingDid: string, connection: Connection): IssueCredentialRecord { + createCredentialOffer(issuingDid: string, connection: Connection, schema: CredentialSchemaResponse): IssueCredentialRecord { const payload = `{ - "claims": { "offerId": "${vu.vu.idInInstance}-${vu.vu.idInTest}-${vu.vu.iterationInScenario}" }, + "claims": { + "emailAddress": "${uuidv4()}-@atala.io", + "familyName": "Test", + "dateOfIssuance": "${new Date()}", + "drivingLicenseID": "Test", + "drivingClass": 1 + }, + "schemaId": "${ISSUER_AGENT_URL.replace("localhost", "host.docker.internal")}/schema-registry/schemas/${schema.guid}", "issuingDID": "${issuingDid}", "connectionId": "${connection.connectionId}", "automaticIssuance": false @@ -27,6 +34,60 @@ export class CredentialsService extends HttpService { return res.json() as unknown as IssueCredentialRecord; } + createCredentialSchema(issuingDid: string): CredentialSchemaResponse { + const payload = ` + { + "name": "${uuidv4()}}", + "version": "1.0.0", + "description": "Simple credential schema for the driving licence verifiable credential.", + "type": "https://w3c-ccg.github.io/vc-json-schemas/schema/2.0/schema.json", + "schema": { + "$id": "https://example.com/driving-license-1.0", + "$schema": "https://json-schema.org/draft/2020-12/schema", + "description": "Driving License", + "type": "object", + "properties": { + "emailAddress": { + "type": "string", + "format": "email" + }, + "givenName": { + "type": "string" + }, + "familyName": { + "type": "string" + }, + "dateOfIssuance": { + "type": "string" + }, + "drivingLicenseID": { + "type": "string" + }, + "drivingClass": { + "type": "integer" + } + }, + "required": [ + "emailAddress", + "familyName", + "dateOfIssuance", + "drivingLicenseID", + "drivingClass" + ], + "additionalProperties": false + }, + "tags": [ + "driving", + "licence", + "id" + ], + "author": "${issuingDid}" + } + ` + const res = this.post("schema-registry/schemas", payload); + return res.json() as unknown as CredentialSchemaResponse; + } + /** * Retrieves a specific credential record by ID. * @param {IssueCredentialRecord} record - The credential record. @@ -41,8 +102,8 @@ export class CredentialsService extends HttpService { * Retrieves all credential records. * @returns {IssueCredentialRecord[]} An array of credential records. */ - getCredentialRecords(): IssueCredentialRecord[] { - const res = this.get("issue-credentials/records"); + getCredentialRecords(thid: string): IssueCredentialRecord[] { + const res = this.get(`issue-credentials/records?thid=${thid}`); return res.json("contents") as unknown as IssueCredentialRecord[]; } @@ -73,21 +134,21 @@ export class CredentialsService extends HttpService { * @returns {IssueCredentialRecord} The received credential offer record. * @throws {Error} If the credential offer is not received within the maximum iterations. */ - waitForCredentialOffer(): IssueCredentialRecord { + waitForCredentialOffer(thid: string): IssueCredentialRecord { let iterations = 0; let record: IssueCredentialRecord | undefined; do { - console.log(`${vu.vu.idInInstance}-${vu.vu.idInTest}-${vu.vu.iterationInScenario}`) - record = this.getCredentialRecords().find( - r => r.claims["offerId"] === `${vu.vu.idInInstance}-${vu.vu.idInTest}-${vu.vu.iterationInScenario}` - && r.protocolState === "OfferReceived"); + // console.log(`Waiting for credential offer with thid=${thid}`) + record = this.getCredentialRecords(thid).find( + r => r.thid === thid && r.protocolState === "OfferReceived" + ); if (record) { return record; } sleep(WAITING_LOOP_PAUSE_INTERVAL); iterations++; } while (iterations < WAITING_LOOP_MAX_ITERATIONS); - throw new Error(`Record with offerId=${vu.vu.idInTest} not achieved during the waiting loop`); + throw new Error(`Record with thid=${thid} not achieved during the waiting loop`); } /** @@ -102,14 +163,12 @@ export class CredentialsService extends HttpService { do { const response = this.getCredentialRecord(credentialRecord); currentState = response.protocolState; - console.log(`Credential state: ${currentState}`) sleep(WAITING_LOOP_PAUSE_INTERVAL); iterations++; } while (currentState !== state && iterations < WAITING_LOOP_MAX_ITERATIONS); if (currentState !== state) { throw new Error(`Credential is not ${state} after the waiting loop`); } - if (__ENV.DEBUG) console.log(`Credential state achieved: ${currentState}`); } } diff --git a/tests/performance-tests/atala-performance-tests-k6/src/common/ProofsService.ts b/tests/performance-tests/atala-performance-tests-k6/src/common/ProofsService.ts index 3ee0652129..b52c723a25 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/common/ProofsService.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/common/ProofsService.ts @@ -68,8 +68,8 @@ export class ProofsService extends HttpService { * Retrieves all presentations. * @returns {PresentationStatus[]} An array of presentation status objects. */ - getPresentations(): PresentationStatus[] { - const res = this.get(`present-proof/presentations`); + getPresentations(thid: string): PresentationStatus[] { + const res = this.get(`present-proof/presentations?thid=${thid}`); return res.json("contents") as unknown as PresentationStatus[]; } @@ -78,13 +78,13 @@ export class ProofsService extends HttpService { * @returns {PresentationStatus} The received presentation status object. * @throws {Error} If the proof request is not received within the maximum iterations. */ - waitForProof(): PresentationStatus { + waitForProof(thid: string): PresentationStatus { let iterations = 0; let presentation: PresentationStatus | undefined; do { - // TODO: add correct filtering here when the API is fixed - // see ATL-4665 - presentation = this.getPresentations().find(r => r.status === "RequestReceived"); + presentation = this.getPresentations(thid).find( + r => r.thid === thid && r.status === "RequestReceived" + ); if (presentation) { return presentation; } @@ -105,11 +105,10 @@ export class ProofsService extends HttpService { let state: string; do { state = this.getPresentation(presentationId).status; - if (__ENV.DEBUG) console.log(`Presentation state: ${state}, required: ${requiredState}`); sleep(WAITING_LOOP_PAUSE_INTERVAL); iterations++; } while (state !== requiredState && iterations < WAITING_LOOP_MAX_ITERATIONS); - if (state != requiredState) { + if (state !== requiredState) { throw new Error(`Presentation state is ${state}, required ${requiredState}`); } } diff --git a/tests/performance-tests/atala-performance-tests-k6/src/tests/credentials/credential-schema-test.ts b/tests/performance-tests/atala-performance-tests-k6/src/tests/credentials/credential-schema-test.ts new file mode 100644 index 0000000000..095eee806f --- /dev/null +++ b/tests/performance-tests/atala-performance-tests-k6/src/tests/credentials/credential-schema-test.ts @@ -0,0 +1,43 @@ +import { group } from 'k6'; +import { Options } from 'k6/options'; +import { Issuer } from '../../actors'; + +export let options: Options = { + scenarios: { + smoke: { + executor: 'constant-vus', + vus: 3, + duration: "1s", + }, + }, + thresholds: { + 'http_req_duration{group:::Issuer creates credential schema}': ['max >= 0'], + 'http_reqs{group:::Issuer creates credential schema}': ['count >= 0'], + 'group_duration{group:::Issuer creates credential schema}': ['max >= 0'], + checks: ['rate==1'], + http_req_duration: ['p(95)<=100'], + }, +}; + +export const issuer = new Issuer(); + +export function setup() { + group('Issuer publishes DID', function () { + issuer.createUnpublishedDid(); + issuer.publishDid(); + }); + + return { + issuerDid: issuer.did, + }; +} + +export default (data: { issuerDid: string; }) => { + + // This is the only way to pass data from setup to default + issuer.did = data.issuerDid; + + group('Issuer creates credential schema', function () { + issuer.createCredentialSchema(); + }); +}; diff --git a/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/issuance-flow-test.ts b/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/issuance-flow-test.ts index 20abb5694b..c4f52a0094 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/issuance-flow-test.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/issuance-flow-test.ts @@ -1,19 +1,24 @@ import { group } from 'k6'; import { Options } from 'k6/options'; import {issuer, holder} from '../common'; +import { CredentialSchemaResponse } from '@input-output-hk/prism-typescript-client'; export let options: Options = { - stages: [ - { duration: '1s', target: 1 }, - ], - // thresholds: { - // http_req_failed: [{ - // threshold: 'rate<=0.05', - // abortOnFail: true, - // }], - // http_req_duration: ['p(95)<=1000'], - // checks: ['rate>=0.99'], - // }, + scenarios: { + smoke: { + executor: 'constant-vus', + vus: 5, + duration: "3m", + }, + }, + thresholds: { + http_req_failed: [{ + threshold: 'rate==0', + abortOnFail: true, + }], + http_req_duration: ['p(95)<=500'], + checks: ['rate==1'], + }, }; // This is setup code. It runs once at the beginning of the test, regardless of the number of VUs. @@ -24,17 +29,22 @@ export function setup() { issuer.publishDid(); }); + group('Issuer creates credential schema', function () { + issuer.createCredentialSchema(); + }); + group('Holder creates unpublished DID', function () { holder.createUnpublishedDid(); }); - return { issuerDid: issuer.did, holderDid: holder.did }; + return { issuerDid: issuer.did, holderDid: holder.did, issuerSchema: issuer.schema }; } -export default (data: { issuerDid: string; holderDid: string; }) => { +export default (data: { issuerDid: string; holderDid: string; issuerSchema: CredentialSchemaResponse}) => { // This is the only way to pass data from setup to default issuer.did = data.issuerDid; + issuer.schema = data.issuerSchema; holder.did = data.holderDid; group('Issuer connects with Holder', function () { @@ -50,7 +60,7 @@ export default (data: { issuerDid: string; holderDid: string; }) => { }); group('Holder achieves and accepts credential offer from Issuer', function () { - holder.waitAndAcceptCredentialOffer(); + holder.waitAndAcceptCredentialOffer(issuer.credential!.thid); }); group('Issuer issues credential to Holder', function () { diff --git a/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/present-proof-flow-test.ts b/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/present-proof-flow-test.ts index fe17b7148e..667c0d4c90 100644 --- a/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/present-proof-flow-test.ts +++ b/tests/performance-tests/atala-performance-tests-k6/src/tests/flows/present-proof-flow-test.ts @@ -1,10 +1,24 @@ import { group } from 'k6'; import { Options } from 'k6/options'; import { Issuer, Holder, Verifier } from '../../actors'; +import { CredentialSchemaResponse } from '@input-output-hk/prism-typescript-client'; export let options: Options = { - vus: 1, - iterations: 1 + scenarios: { + smoke: { + executor: 'constant-vus', + vus: 5, + duration: "3m", + }, + }, + thresholds: { + http_req_failed: [{ + threshold: 'rate==0', + abortOnFail: true, + }], + http_req_duration: ['p(95)<=500'], + checks: ['rate==1'], + }, }; const issuer = new Issuer(); @@ -17,16 +31,21 @@ export function setup() { issuer.publishDid(); }); + group('Issuer creates credential schema', function () { + issuer.createCredentialSchema(); + }); + group('Holder creates unpublished DID', function () { holder.createUnpublishedDid(); }); - return { issuerDid: issuer.did, holderDid: holder.did }; + return { issuerDid: issuer.did, holderDid: holder.did, issuerSchema: issuer.schema }; } -export default (data: { issuerDid: string; holderDid: string; }) => { +export default (data: { issuerDid: string; holderDid: string; issuerSchema: CredentialSchemaResponse; }) => { issuer.did = data.issuerDid; + issuer.schema = data.issuerSchema; holder.did = data.holderDid; group('Holder connects with Issuer', function () { @@ -39,7 +58,7 @@ export default (data: { issuerDid: string; holderDid: string; }) => { group('Issuer creates credential offer for Holder', function () { issuer.createCredentialOffer(); issuer.waitForCredentialOfferToBeSent(); - holder.waitAndAcceptCredentialOffer(); + holder.waitAndAcceptCredentialOffer(issuer.credential!.thid); issuer.receiveCredentialRequest(); issuer.issueCredential(); issuer.waitForCredentialToBeSent(); @@ -55,7 +74,7 @@ export default (data: { issuerDid: string; holderDid: string; }) => { group('Verifier requests proof from Holder', function () { verifier.requestProof(); - holder.waitAndAcceptProofRequest(); + holder.waitAndAcceptProofRequest(verifier.presentation!.thid); verifier.acknowledgeProof(); }); diff --git a/tests/performance-tests/atala-performance-tests-k6/yarn.lock b/tests/performance-tests/atala-performance-tests-k6/yarn.lock index 711d66692a..594d94eda9 100644 --- a/tests/performance-tests/atala-performance-tests-k6/yarn.lock +++ b/tests/performance-tests/atala-performance-tests-k6/yarn.lock @@ -904,14 +904,17 @@ resolved "https://registry.yarnpkg.com/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz#1d572bfbbe14b7704e0ba0f39b74815b84870d70" integrity sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw== -"@input-output-hk/prism-typescript-client@0.1.0": - version "0.1.0" - resolved "https://npm.pkg.github.com/download/@input-output-hk/prism-typescript-client/0.1.0/9e88016b6237d734adff215da45b6e318b7c1af1#9e88016b6237d734adff215da45b6e318b7c1af1" - integrity sha512-9wF7tCUrusEXCBx2tJpSy02WdIxpXmwNNPS8vxNUY09sfBIWItkSl3YGS8XwcKAOpGBHIda5Q3PsL9hmdFtIwA== +"@input-output-hk/prism-typescript-client@1.9.2": + version "1.9.2" + resolved "https://npm.pkg.github.com/download/@input-output-hk/prism-typescript-client/1.9.2/f3afcb132244411035806306a6b52fd96f7d1ae1#f3afcb132244411035806306a6b52fd96f7d1ae1" + integrity sha512-pg/EdLmx5jIpZhNGLpqW/A6rCwv+BXRNgwHCARWPXlr0XYF3+6SYQhJVpOTkLmYV+ufCkAsVS28BlfZq6XHzFA== dependencies: + "@types/node" "*" + "@types/node-fetch" "^2.5.7" es6-promise "^4.2.4" + form-data "^2.5.0" + node-fetch "^2.6.0" url-parse "^1.4.3" - whatwg-fetch "^3.0.0" "@jridgewell/gen-mapping@^0.3.2": version "0.3.3" @@ -1025,6 +1028,14 @@ resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-5.1.2.tgz#07508b45797cb81ec3f273011b054cd0755eddca" integrity sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA== +"@types/node-fetch@^2.5.7": + version "2.6.4" + resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.4.tgz#1bc3a26de814f6bf466b25aeb1473fa1afe6a660" + integrity sha512-1ZX9fcN4Rvkvgv4E6PAY5WXUFWFcRWxZa3EW83UjycOB9ljJCedb2CupIP4RZMEwF/M3eTcCihbBRgwtGbg5Rg== + dependencies: + "@types/node" "*" + form-data "^3.0.0" + "@types/node@*": version "20.3.2" resolved "https://registry.yarnpkg.com/@types/node/-/node-20.3.2.tgz#fa6a90f2600e052a03c18b8cb3fd83dd4e599898" @@ -1362,6 +1373,11 @@ array-uniq@^1.0.1: resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" integrity sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q== +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" + integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== + babel-loader@8.2.2: version "8.2.2" resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-8.2.2.tgz#9363ce84c10c9a40e6c753748e1441b60c8a0b81" @@ -1488,6 +1504,13 @@ colorette@^1.2.1: resolved "https://registry.yarnpkg.com/colorette/-/colorette-1.4.0.tgz#5190fbb87276259a86ad700bff2c6d6faa3fca40" integrity sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g== +combined-stream@^1.0.6, combined-stream@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== + dependencies: + delayed-stream "~1.0.0" + commander@^2.20.0: version "2.20.3" resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" @@ -1561,6 +1584,11 @@ del@^4.1.1: pify "^4.0.1" rimraf "^2.6.3" +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" + integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ== + dir-glob@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-3.0.1.tgz#56dbf73d992a4a93ba1584f4534063fd2e41717f" @@ -1730,6 +1758,24 @@ find-up@^4.0.0: locate-path "^5.0.0" path-exists "^4.0.0" +form-data@^2.5.0: + version "2.5.1" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.5.1.tgz#f2cbec57b5e59e23716e128fe44d4e5dd23895f4" + integrity sha512-m21N3WOmEEURgk6B9GLOE4RuWOFf28Lhh9qGYeNlGq4VDXUlJy2th2slBNU8Gp8EzloYZOibZJ7t5ecIrFSjVA== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.6" + mime-types "^2.1.12" + +form-data@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-3.0.1.tgz#ebd53791b78356a99af9a300d4282c4d5eb9755f" + integrity sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.8" + mime-types "^2.1.12" + fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" @@ -2062,7 +2108,7 @@ mime-db@1.52.0: resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== -mime-types@^2.1.27: +mime-types@^2.1.12, mime-types@^2.1.27: version "2.1.35" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== @@ -2096,6 +2142,13 @@ neo-async@^2.6.2: resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== +node-fetch@^2.6.0: + version "2.6.12" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.12.tgz#02eb8e22074018e3d5a83016649d04df0e348fba" + integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== + dependencies: + whatwg-url "^5.0.0" + node-releases@^2.0.12: version "2.0.12" resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.12.tgz#35627cc224a23bfb06fb3380f2b3afaaa7eb1039" @@ -2491,6 +2544,11 @@ to-regex-range@^5.0.1: dependencies: is-number "^7.0.0" +tr46@~0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" + integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== + typescript@4.2.4: version "4.2.4" resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.2.4.tgz#8610b59747de028fda898a8aef0e103f156d0961" @@ -2542,6 +2600,11 @@ url-parse@^1.4.3: querystringify "^2.1.1" requires-port "^1.0.0" +uuid@^9.0.0: + version "9.0.0" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-9.0.0.tgz#592f550650024a38ceb0c562f2f6aa435761efb5" + integrity sha512-MXcSTerfPa4uqyzStbRoTgt5XIe3x5+42+q1sDuy3R5MDk66URdLMOZe5aPX/SQd+kuYAh0FdP/pO28IkQyTeg== + v8-compile-cache@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" @@ -2555,6 +2618,11 @@ watchpack@^2.0.0, watchpack@^2.4.0: glob-to-regexp "^0.4.1" graceful-fs "^4.1.2" +webidl-conversions@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" + integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== + webpack-cli@4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/webpack-cli/-/webpack-cli-4.6.0.tgz#27ae86bfaec0cf393fcfd58abdc5a229ad32fd16" @@ -2662,10 +2730,13 @@ webpack@^5: watchpack "^2.4.0" webpack-sources "^3.2.3" -whatwg-fetch@^3.0.0: - version "3.6.2" - resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-3.6.2.tgz#dced24f37f2624ed0281725d51d0e2e3fe677f8c" - integrity sha512-bJlen0FcuU/0EMLrdbJ7zOnW6ITZLrZMIarMUVmdKtsGvZna8vxKYaexICWPfZ8qwf9fzNq+UEIZrnSaApt6RA== +whatwg-url@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" + integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== + dependencies: + tr46 "~0.0.3" + webidl-conversions "^3.0.0" which@^2.0.1: version "2.0.2"