From ce975207aa6781c34d9952a82fec3aad3c6de5cf Mon Sep 17 00:00:00 2001 From: Rafael Belchior Date: Tue, 12 Mar 2024 22:56:19 +0000 Subject: [PATCH] feat(satp-hermes): add API1 layer WIP MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Rafael Belchior feat(satp-hermes): BLO API specification Signed-off-by: Rafael Belchior feat(satp-hermes): add BLO layer Signed-off-by: Rafael Belchior fix(satp-hermes): fix status endpoint and spec Signed-off-by: Rafael Belchior fix(satp-hermes): fix lint Signed-off-by: André Augusto ci(satp-hermes): rebase and update ci Signed-off-by: Rafael Belchior feat(satp-hermes): update BLO specification Signed-off-by: Rafael Belchior docs(satp-hermes): migrate BLO open api spec from json to yml Signed-off-by: Rafael Belchior feat(satp-hermes): update Go BLO SDK generation Signed-off-by: Rafael Belchior feat(satp-hermes): update BLO specification Signed-off-by: Rafael Belchior feat(satp-hermes): add health check endpoint to BLO spec Signed-off-by: Rafael Belchior fix(satp-hermes): re-add open-api json files The canonical source for the API definition are the yaml files located at packages/cactus-plugin-satp-hermes/src/main/yml/openapi.yml, due to its better readability compared to json. When yarn codegen is ran within the cactus-plugin-satp-hermes package, the json files are generated from the yaml. Signed-off-by: Rafael Belchior feat(satp-hermes): remove deprecated spec Signed-off-by: Rafael Belchior feat(SATP-Hermes): add gateway coordinator WIP Signed-off-by: Rafael Belchior feat(bungee): add skeleton for bungee Signed-off-by: André Augusto refactor(plugin-satp-hermes): update messages formats SATP core version 2.0.0 OpenAPI * created new messages in openAPI definition feat(bungee): fix bungee dependencies Signed-off-by: André Augusto feat(SATP-Hermes): gateway coordinator feat(SATP-Hermes): gateway coordinator feat(SATP-Hermes): gateway coordinator WIP Signed-off-by: Rafael Belchior test(SATP-Hermes): enable decorators needed for gateway coordinator checks Signed-off-by: Rafael Belchior docs(SATP-Hermes): update package.json Signed-off-by: Rafael Belchior refactor(SATP-Hermes): re-estructure project Signed-off-by: Rafael Belchior refactor(SATP-Hermes): re-estructure project Signed-off-by: Rafael Belchior refactor(SATP-Hermes): re-estructure project Signed-off-by: Rafael Belchior refactor(SATP-Hermes): remove kotlin sdk, add protobuffer Signed-off-by: Rafael Belchior feat(SATP-Hermes): protobuf structure Signed-off-by: Rafael Belchior feat(SATP-Hermes): protobuf structure Signed-off-by: Rafael Belchior refactor(SATP-Hermes): refactor naming Signed-off-by: Rafael Belchior feat(SATP-Hermes): protobuf structure improvements Signed-off-by: Rafael Belchior feat(SATP-Hermes): update yarn.lock and clean up Signed-off-by: André Augusto refactor(test-tooling): fix types of streams: use NodeJS.ReadableStream 1. The container management library that we use in the test infrastructure (called dockerode) is expecting streams that are defined in the global namespace of the `@types/node` library, e.g. the standard library of NodeJS itself. 2. Previously we were using the "streams" package to provide type information to the streams that we were passing around to dockerode and it was working fine, but after some changes that seem unrelated this has broken the compilation process. 3. The mentioned changes are not yet on the main branch, but we expect them to be there soon and so this change is laying the groundwork for that by pre-emptively fixing the broken build's root cause which is that the test-tooling package does not declare it's typings related dependencies correctly: It implicitly uses the NodeJS standard library's types but so far had not declared them on the package level. 4. This change is therefore to rectify the issue of the `@types/node` dependency missing from the test-tooling package and also the refactoring of some of the test ledger classes which were relying on the `streams` builtin package instead of correctly using the NodeJS.ReadableStream global. 5. Earlier the reasoning for this was that we try to avoid pulling in types from the global scope because we try to avoid any sort of dependency on the global scope in general. Once we have proof though that this is causing issues with the build, then we must give up the principle for practical reasons (and only in the minimum viable scope, e.g. this does not change the fact that everywhere else in the codebase we should still do our best to avoid using the global scoped classes, types, functions, etc..). Thank you to @AndreAugusto11 and @RafaelAPB for pointing out this issue through the pull request of his that is currently being worked on at the time of this writing: https://github.com/RafaelAPB/blockchain-integration-framework/pull/72 Related to but does not address #2811 Signed-off-by: Peter Somogyvari refactor(SATP-Hermes): remove unused packages * updated openapi version * updated bungee plugin version to 2.0.0-alpha.2 Co-authored-by: Peter Somogyvari Signed-off-by: André Augusto Signed-off-by: Peter Somogyvari fix(satp-hermes): re-add open-api json files The canonical source for the API definition are the yaml files located at packages/cactus-plugin-satp-hermes/src/main/yml/openapi.yml, due to its better readability compared to json. When yarn codegen is ran within the cactus-plugin-satp-hermes package, the json files are generated from the yaml. Signed-off-by: Rafael Belchior ci(satp-hermes): re-activate satp-hermes ci Signed-off-by: Rafael Belchior fixup: update package json, ci, yarn lock Signed-off-by: Rafael Belchior feat(SATP-Hermes): add gateway coordinator WIP Signed-off-by: Rafael Belchior feat(bungee): add skeleton for bungee Signed-off-by: André Augusto refactor(plugin-satp-hermes): update messages formats SATP core version 2.0.0 OpenAPI * created new messages in openAPI definition feat(bungee): fix bungee dependencies Signed-off-by: André Augusto feat(SATP-Hermes): gateway coordinator feat(SATP-Hermes): gateway coordinator feat(SATP-Hermes): gateway coordinator WIP Signed-off-by: Rafael Belchior test(SATP-Hermes): enable decorators needed for gateway coordinator checks Signed-off-by: Rafael Belchior docs(SATP-Hermes): update package.json Signed-off-by: Rafael Belchior refactor(SATP-Hermes): re-estructure project Signed-off-by: Rafael Belchior refactor(SATP-Hermes): re-estructure project Signed-off-by: Rafael Belchior refactor(SATP-Hermes): re-estructure project Signed-off-by: Rafael Belchior refactor(SATP-Hermes): remove kotlin sdk, add protobuffer Signed-off-by: Rafael Belchior feat(SATP-Hermes): protobuf structure Signed-off-by: Rafael Belchior feat(SATP-Hermes): protobuf structure Signed-off-by: Rafael Belchior refactor(SATP-Hermes): refactor naming Signed-off-by: Rafael Belchior feat(SATP-Hermes): protobuf structure improvements Signed-off-by: Rafael Belchior feat(SATP-Hermes): update yarn.lock and clean up Signed-off-by: André Augusto refactor(test-tooling): fix types of streams: use NodeJS.ReadableStream 1. The container management library that we use in the test infrastructure (called dockerode) is expecting streams that are defined in the global namespace of the `@types/node` library, e.g. the standard library of NodeJS itself. 2. Previously we were using the "streams" package to provide type information to the streams that we were passing around to dockerode and it was working fine, but after some changes that seem unrelated this has broken the compilation process. 3. The mentioned changes are not yet on the main branch, but we expect them to be there soon and so this change is laying the groundwork for that by pre-emptively fixing the broken build's root cause which is that the test-tooling package does not declare it's typings related dependencies correctly: It implicitly uses the NodeJS standard library's types but so far had not declared them on the package level. 4. This change is therefore to rectify the issue of the `@types/node` dependency missing from the test-tooling package and also the refactoring of some of the test ledger classes which were relying on the `streams` builtin package instead of correctly using the NodeJS.ReadableStream global. 5. Earlier the reasoning for this was that we try to avoid pulling in types from the global scope because we try to avoid any sort of dependency on the global scope in general. Once we have proof though that this is causing issues with the build, then we must give up the principle for practical reasons (and only in the minimum viable scope, e.g. this does not change the fact that everywhere else in the codebase we should still do our best to avoid using the global scoped classes, types, functions, etc..). Thank you to @AndreAugusto11 and @RafaelAPB for pointing out this issue through the pull request of his that is currently being worked on at the time of this writing: https://github.com/RafaelAPB/blockchain-integration-framework/pull/72 Related to but does not address #2811 Signed-off-by: Peter Somogyvari refactor(SATP-Hermes): remove unused packages * updated openapi version * updated bungee plugin version to 2.0.0-alpha.2 Co-authored-by: Peter Somogyvari Signed-off-by: André Augusto Signed-off-by: Peter Somogyvari --- .github/workflows/ci.yaml | 27 +- .../cactus-plugin-satp-hermes/package.json | 32 +- .../src/knex/knexfile-remote.ts | 1 + .../src/main/go/generated/api_chains.go | 147 + .../src/main/go/generated/docs/Chain.md | 114 + .../main/go/generated/docs/Chains1Inner.md | 114 + .../src/main/go/generated/docs/ChainsApi.md | 70 + .../go/generated/docs/Continue200Response.md | 51 + .../main/go/generated/docs/ContinueRequest.md | 72 + .../go/generated/docs/ContinueResponse.md | 51 + .../docs/GetChains200ResponseInner.md | 114 + .../docs/GetHealthCheck200Response.md | 56 + .../docs/GetIntegrations200ResponseInner.md | 114 + ...etRoutes200ResponseRoutesInnerFromToken.md | 265 + ...0ResponseRoutesInnerFromTokenExtensions.md | 82 + ...InnerFromTokenExtensionsBridgeInfoValue.md | 56 + .../go/generated/docs/HealthCheckResponse.md | 56 + .../go/generated/docs/Pause200Response.md | 51 + .../main/go/generated/docs/PauseRequest.md | 82 + .../main/go/generated/docs/PauseResponse.md | 51 + ...0ResponseStatusResponseDestinationChain.md | 102 + ...act200ResponseStatusResponseOriginChain.md | 102 + .../src/main/go/generated/model_chain.go | 202 + .../main/go/generated/model_chains_1_inner.go | 202 + .../generated/model_continue_200_response.go | 117 + .../go/generated/model_continue_request.go | 146 + .../go/generated/model_continue_response.go | 117 + .../model_get_chains_200_response_inner.go | 202 + .../model_get_health_check_200_response.go | 126 + ...del_get_integrations_200_response_inner.go | 202 + ...es_200_response_routes_inner_from_token.go | 414 ++ ...onse_routes_inner_from_token_extensions.go | 163 + ...from_token_extensions_bridge_info_value.go | 127 + ...esponse_routes_inner_steps_inner_action.go | 310 + .../generated/model_health_check_response.go | 126 + .../go/generated/model_pause_200_response.go | 117 + .../main/go/generated/model_pause_request.go | 162 + .../main/go/generated/model_pause_response.go | 117 + ...ponse_status_response_destination_chain.go | 164 + ...0_response_status_response_origin_chain.go | 164 + .../main/go/generated/test/api_chains_test.go | 37 + .../src/main/json/openapi-blo-bundled.json | 6114 +++++++++++++++++ .../main/json/openapi-gateway-bundled.json | 3259 +++++++++ .../blo/admin/get-audit-handler-service.ts | 1 + .../blo/admin/get-status-handler-service.ts | 62 + .../src/main/typescript/blo/dispatcher.ts | 72 + .../blo/transaction/cancel-handler-service.ts | 1 + .../blo/transaction/routes-handler-service.ts | 1 + .../transaction/transact-handler-service.ts | 1 + .../src/main/typescript/core/constants.ts | 4 +- .../src/main/typescript/core/errors.ts | 10 + .../typescript/core/stage-services/stage3.ts | 1 + .../src/main/typescript/core/types.ts | 15 +- .../src/main/typescript/gateway-refactor.ts | 173 +- .../typescript-axios-json/.gitignore | 4 + .../typescript-axios-json/.npmignore | 1 + .../.openapi-generator-ignore | 23 + .../.openapi-generator/FILES | 8 + .../.openapi-generator/VERSION | 1 + .../openapi-blo/typescript-axios-json/api.ts | 2678 ++++++++ .../openapi-blo/typescript-axios-json/base.ts | 72 + .../typescript-axios-json/common.ts | 150 + .../typescript-axios-json/configuration.ts | 101 + .../typescript-axios-json/git_push.sh | 57 + .../typescript-axios-json/index.ts | 18 + .../typescript-axios/.openapi-generator/FILES | 5 + .../openapi-blo/typescript-axios/api.ts | 2678 ++++++++ .../openapi-blo/typescript-axios/base.ts | 72 + .../openapi-blo/typescript-axios/common.ts | 150 + .../typescript-axios/configuration.ts | 101 + .../openapi-blo/typescript-axios/index.ts | 18 + .../generated/openapi/typescript-axios/api.ts | 2005 +++++- .../main/typescript/plugin-satp-gateway.ts | 2 +- .../repository/knex-local-log-repository.ts | 2 +- .../repository/knex-remote-log-repository.ts | 2 +- .../web-services/blo/status-endpoint.ts | 102 + .../client-side/client-request-endpoint.ts | 2 +- .../commit-final-response-endpoint.ts | 2 +- .../commit-prepare-response-endpoint.ts | 2 +- .../lock-evidence-response-endpoint.ts | 2 +- .../transfer-commence-response-endpoint.ts | 2 +- .../transfer-initiation-response-endpoint.ts | 2 +- .../recovery/recover-message-endpoint.ts | 2 +- .../recover-success-message-endpoint.ts | 2 +- .../recover-update-ack-message-endpoint.ts | 2 +- .../recover-update-message-endpoint.ts | 2 +- .../recovery/rollback-ack-message-endpoint.ts | 2 +- .../recovery/rollback-message-endpoint.ts | 2 +- .../commit-final-request-endpoint.ts | 2 +- .../commite-prepare-request-endpoint.ts | 2 +- .../lock-evidence-request-endpoint.ts | 2 +- .../transfer-commence-request-endpoint.ts | 2 +- .../transfer-complete-request-endpoint.ts | 2 +- .../transfer-initiation-request-endpoint.ts | 2 +- .../src/main/yml/bol/openapi-blo-bundled.yml | 4689 +++++++++++++ .../src/main/yml/bol/openapi-blo.yml | 337 + .../src/main/yml/bol/schemas.yml | 696 ++ .../src/main/yml/openapi.yml | 1229 ++++ ...nt-crash-after-transfer-initiation.test.ts | 29 +- .../gateway-coordinator-init.test.ts | 102 +- .../integration/odap-api-call.test.ts | 16 +- .../test/typescript/integration/odap.test.ts | 9 +- .../refactor-gateway-get-status.test.ts | 108 + .../integration/refactor-gateway-init.test.ts | 217 + ...er-crash-after-transfer-initiation.test.ts | 17 +- .../src/test/typescript/knex.config.ts | 15 +- .../src/test/typescript/test-utils.ts | 38 + .../unit/client/commit-final.test.ts | 2 +- .../unit/client/commit-preparation.test.ts | 2 +- .../unit/client/lock-evidence.test.ts | 2 +- .../unit/client/transfer-commence.test.ts | 2 +- .../client/transfer-initialization.test.ts | 2 +- .../typescript/unit/recovery/logging.test.ts | 2 +- .../unit/recovery/recover-success.test.ts | 2 +- .../unit/recovery/recover-update-ack.test.ts | 2 +- .../unit/recovery/recover-update.test.ts | 2 +- .../typescript/unit/recovery/recover.test.ts | 2 +- .../unit/server/commit-final.test.ts | 2 +- .../unit/server/commit-preparation.test.ts | 2 +- .../unit/server/lock-evidence.test.ts | 4 +- .../unit/server/transfer-commence.test.ts | 2 +- .../unit/server/transfer-complete.test.ts | 2 +- .../server/transfer-initialization.test.ts | 2 +- yarn.lock | 365 +- 124 files changed, 30130 insertions(+), 796 deletions(-) create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/api_chains.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chain.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chains1Inner.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ChainsApi.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Continue200Response.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueRequest.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueResponse.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetChains200ResponseInner.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetHealthCheck200Response.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetIntegrations200ResponseInner.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromToken.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensions.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/HealthCheckResponse.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Pause200Response.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseRequest.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseResponse.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseDestinationChain.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseOriginChain.md create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chain.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chains_1_inner.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_200_response.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_request.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_response.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_chains_200_response_inner.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_health_check_200_response.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_integrations_200_response_inner.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions_bridge_info_value.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_steps_inner_action.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_health_check_response.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_200_response.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_request.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_response.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_destination_chain.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_origin_chain.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/go/generated/test/api_chains_test.go create mode 100644 packages/cactus-plugin-satp-hermes/src/main/json/openapi-blo-bundled.json create mode 100644 packages/cactus-plugin-satp-hermes/src/main/json/openapi-gateway-bundled.json create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-audit-handler-service.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-status-handler-service.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/blo/dispatcher.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/cancel-handler-service.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/routes-handler-service.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/transact-handler-service.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.gitignore create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.npmignore create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator-ignore create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/FILES create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/VERSION create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/api.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/base.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/common.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/configuration.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/git_push.sh create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/index.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/.openapi-generator/FILES create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/api.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/base.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/common.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/configuration.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/index.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/blo/status-endpoint.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo-bundled.yml create mode 100644 packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo.yml create mode 100644 packages/cactus-plugin-satp-hermes/src/main/yml/bol/schemas.yml create mode 100644 packages/cactus-plugin-satp-hermes/src/main/yml/openapi.yml create mode 100644 packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-get-status.test.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-init.test.ts create mode 100644 packages/cactus-plugin-satp-hermes/src/test/typescript/test-utils.ts diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 4ed27ca2ee..856b4a2aa7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -1823,6 +1823,31 @@ jobs: with: name: coverage-reports-36 path: ./code-coverage-ts/**/ + cactus-plugin-bungee-hermes: + continue-on-error: false + env: + FULL_BUILD_DISABLED: true + JEST_TEST_RUNNER_DISABLED: false + JEST_TEST_PATTERN: packages/cactus-plugin-bungee-hermes/src/test/typescript/(unit|integration|benchmark)/.*/*.test.ts + TAPE_TEST_RUNNER_DISABLED: true + needs: build-dev + runs-on: ubuntu-22.04 + steps: + - name: Use Node.js ${{ env.NODEJS_VERSION }} + uses: actions/setup-node@v3.6.0 + with: + node-version: ${{ env.NODEJS_VERSION }} + - uses: actions/checkout@v3.5.2 + + - id: yarn-cache + name: Restore Yarn Cache + uses: actions/cache@v3.3.1 + with: + key: ${{ runner.os }}-yarn-${{ hashFiles('./yarn.lock') }} + path: ./.yarn/ + restore-keys: | + ${{ runner.os }}-yarn-${{ hashFiles('./yarn.lock') }} + - run: ./tools/ci.sh ct-api-client: continue-on-error: false env: @@ -2307,4 +2332,4 @@ name: Cactus_CI - dev schedule: # Run at 8:00 AM UTC on weekends (Monday and Thursday) - - cron: "0 8 * * 1,4" \ No newline at end of file + - cron: "0 8 * * 1,4" diff --git a/packages/cactus-plugin-satp-hermes/package.json b/packages/cactus-plugin-satp-hermes/package.json index 616ca0e4dd..241405e8cc 100644 --- a/packages/cactus-plugin-satp-hermes/package.json +++ b/packages/cactus-plugin-satp-hermes/package.json @@ -43,16 +43,23 @@ "build": "run-p tsc codegen", "build-proto": "buf build --path src/main/proto --verbose", "build:dev:backend:postbuild": "mkdir -p ./dist/lib/knex && cp -r ./src/knex/* ./dist/lib/knex", + "bundle-openapi-gateway-json": "swagger-cli bundle ./src/main/yml/openapi.yml -o ./src/main/json/openapi-gateway-bundled.json -r -t json", + "bundle-openapi-json": "swagger-cli bundle ./src/main/yml/bol/openapi-blo.yml -o ./src/main/json/openapi-blo-bundled.json -r -t json", + "bundle-openapi-yaml": "swagger-cli bundle ./src/main/yml/bol/openapi-blo.yml -o ./src/main/yml/bol/openapi-blo-bundled.yml -r -t yaml", "codegen": "run-p 'codegen:*'", "codegen:openapi": "npm run generate-sdk", "codegen:proto": "npm run generate-proto", "generate-proto": "cd src/main/proto && buf generate --template buf.gen.yaml --config buf.yaml --verbose", "generate-sdk": "run-p 'generate-sdk:*'", - "generate-sdk:typescript-axios": "openapi-generator-cli generate -i ./src/main/json/openapi.json -g typescript-axios -o ./src/main/typescript/generated/openapi/typescript-axios/ --reserved-words-mappings protected=protected --ignore-file-override ../../openapi-generator-ignore", - "lint": "npm-run-all 'buf lint' eslint '*/*/src/**/*.{js,ts}' --quiet --fix && cspell \"*/*/src/**/*.{js,ts}\"", - "lint-protobuf": "buf lint --path src/main/proto --verbose", + "generate-sdk:go": "openapi-generator-cli generate -i ./src/main/yml/bol/openapi-blo-bundled.yml -g go -o ./src/main/go/generated --additional-properties=packageName=generated,generateInterfaces=true,packageVersion=v0.0.1,moduleName=github.com/hyperledger/cacti/packages/cactus-plugin-satp-hermes/src/main/go/generated --git-user-id hyperledger --git-repo-id cacti/packages/cactus-plugin-satp-hermes/src/main/go/generated", + "generate-sdk:typescript-axios-bol": "yarn bundle-openapi-yaml && yarn bundle-openapi-json && openapi-generator-cli generate -i ./src/main/yml/bol/openapi-blo-bundled.yml -g typescript-axios -o ./src/main/typescript/generated/openapi-blo/typescript-axios/ --reserved-words-mappings protected=protected --enable-post-process-file", + "generate-sdk:typescript-axios-gateway": "yarn bundle-openapi-gateway-json && openapi-generator-cli generate -i ./src/main/json/openapi-gateway-bundled.json -g typescript-axios -o ./src/main/typescript/generated/openapi/typescript-axios/ --reserved-words-mappings protected=protected --ignore-file-override ../../openapi-generator-ignore", + "lint": "run-p 'lint:*'", + "lint:eslint": "eslint '*/*/src/**/*.{js,ts}' --quiet --fix && cspell \"*/*/src/**/*.{js,ts}\"", + "lint:oapi": "vacuum lint -d -e ./src/main/yml/bol/openapi-blo-bundled.yml", + "lint:protobuf": "buf lint --path src/main/proto --verbose", "pretsc": "npm run generate-sdk", - "tsc": "tsc --project ./tsconfig.json", + "tsc": "tsc --project ./tsconfig.yml", "watch": "tsc --build --watch" }, "jest": { @@ -90,9 +97,10 @@ "web3-utils": "1.6.1" }, "devDependencies": { + "@apidevtools/swagger-cli": "4.0.4", "@bufbuild/buf": "1.29.0", - "@bufbuild/protobuf": "1.7.2", - "@bufbuild/protoc-gen-es": "1.7.2", + "@bufbuild/protoc-gen-es": "1.8.0", + "@quobix/vacuum": "^0.9.10", "@types/body-parser": "1.19.4", "@types/crypto-js": "4.0.1", "@types/express": "5.0.0", @@ -105,6 +113,7 @@ "express": "4.21.1", "fabric-network": "2.2.20", "kubo-rpc-client": "3.0.1", + "swagger-cli": "^4.0.4", "typescript": "5.5.2" }, "engines": { @@ -114,18 +123,25 @@ "publishConfig": { "access": "public" }, + "customMetadata": { + "satp-draft-versions": { + "satp-core": "02", + "satp-architecture": "02", + "satp-crash": "02" + } + }, "watch": { "tsc": { "patterns": [ "src/", - "src/*/json/**/openapi*" + "src/*/yml/**/*" ], "ignore": [ "src/**/generated/*" ], "extensions": [ "ts", - "json" + "yml" ], "quiet": true, "verbose": false, diff --git a/packages/cactus-plugin-satp-hermes/src/knex/knexfile-remote.ts b/packages/cactus-plugin-satp-hermes/src/knex/knexfile-remote.ts index 6b36836510..d2a2e41600 100644 --- a/packages/cactus-plugin-satp-hermes/src/knex/knexfile-remote.ts +++ b/packages/cactus-plugin-satp-hermes/src/knex/knexfile-remote.ts @@ -1,4 +1,5 @@ import path from "path"; +import { v4 as uuidv4 } from "uuid"; // default configuration for knex module.exports = { diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/api_chains.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/api_chains.go new file mode 100644 index 0000000000..8fa2d004e5 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/api_chains.go @@ -0,0 +1,147 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: v0.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "bytes" + "context" + "io" + "net/http" + "net/url" +) + + +type ChainsApi interface { + + /* + GetChains Get supported chains + + Retrieves metadata about each supported blockchain network. + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetChainsRequest + */ + GetChains(ctx context.Context) ApiGetChainsRequest + + // GetChainsExecute executes the request + // @return []GetChains200ResponseInner + GetChainsExecute(r ApiGetChainsRequest) ([]GetChains200ResponseInner, *http.Response, error) +} + +// ChainsApiService ChainsApi service +type ChainsApiService service + +type ApiGetChainsRequest struct { + ctx context.Context + ApiService ChainsApi +} + +func (r ApiGetChainsRequest) Execute() ([]GetChains200ResponseInner, *http.Response, error) { + return r.ApiService.GetChainsExecute(r) +} + +/* +GetChains Get supported chains + +Retrieves metadata about each supported blockchain network. + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetChainsRequest +*/ +func (a *ChainsApiService) GetChains(ctx context.Context) ApiGetChainsRequest { + return ApiGetChainsRequest{ + ApiService: a, + ctx: ctx, + } +} + +// Execute executes the request +// @return []GetChains200ResponseInner +func (a *ChainsApiService) GetChainsExecute(r ApiGetChainsRequest) ([]GetChains200ResponseInner, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodGet + localVarPostBody interface{} + formFiles []formFile + localVarReturnValue []GetChains200ResponseInner + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ChainsApiService.GetChains") + if err != nil { + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/chains" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := &GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + var v TransactDefaultResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.error = formatErrorMessage(localVarHTTPResponse.Status, &v) + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := &GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chain.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chain.md new file mode 100644 index 0000000000..07315d0b34 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chain.md @@ -0,0 +1,114 @@ +# Chain + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ChainId** | **string** | A unique identifier for the blockchain network. | +**ChainName** | **string** | The name of the blockchain network. | +**ChainType** | **string** | The type of blockchain network (e.g., 'evm', 'fabric'). | +**NetworkName** | **string** | The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). | + +## Methods + +### NewChain + +`func NewChain(chainId string, chainName string, chainType string, networkName string, ) *Chain` + +NewChain instantiates a new Chain object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewChainWithDefaults + +`func NewChainWithDefaults() *Chain` + +NewChainWithDefaults instantiates a new Chain object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetChainId + +`func (o *Chain) GetChainId() string` + +GetChainId returns the ChainId field if non-nil, zero value otherwise. + +### GetChainIdOk + +`func (o *Chain) GetChainIdOk() (*string, bool)` + +GetChainIdOk returns a tuple with the ChainId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainId + +`func (o *Chain) SetChainId(v string)` + +SetChainId sets ChainId field to given value. + + +### GetChainName + +`func (o *Chain) GetChainName() string` + +GetChainName returns the ChainName field if non-nil, zero value otherwise. + +### GetChainNameOk + +`func (o *Chain) GetChainNameOk() (*string, bool)` + +GetChainNameOk returns a tuple with the ChainName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainName + +`func (o *Chain) SetChainName(v string)` + +SetChainName sets ChainName field to given value. + + +### GetChainType + +`func (o *Chain) GetChainType() string` + +GetChainType returns the ChainType field if non-nil, zero value otherwise. + +### GetChainTypeOk + +`func (o *Chain) GetChainTypeOk() (*string, bool)` + +GetChainTypeOk returns a tuple with the ChainType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainType + +`func (o *Chain) SetChainType(v string)` + +SetChainType sets ChainType field to given value. + + +### GetNetworkName + +`func (o *Chain) GetNetworkName() string` + +GetNetworkName returns the NetworkName field if non-nil, zero value otherwise. + +### GetNetworkNameOk + +`func (o *Chain) GetNetworkNameOk() (*string, bool)` + +GetNetworkNameOk returns a tuple with the NetworkName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetNetworkName + +`func (o *Chain) SetNetworkName(v string)` + +SetNetworkName sets NetworkName field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chains1Inner.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chains1Inner.md new file mode 100644 index 0000000000..6946a5c6d4 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Chains1Inner.md @@ -0,0 +1,114 @@ +# Chains1Inner + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ChainId** | **string** | A unique identifier for the blockchain network. | +**ChainName** | **string** | The name of the blockchain network. | +**ChainType** | **string** | The type of blockchain network (e.g., 'evm', 'fabric'). | +**NetworkName** | **string** | The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). | + +## Methods + +### NewChains1Inner + +`func NewChains1Inner(chainId string, chainName string, chainType string, networkName string, ) *Chains1Inner` + +NewChains1Inner instantiates a new Chains1Inner object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewChains1InnerWithDefaults + +`func NewChains1InnerWithDefaults() *Chains1Inner` + +NewChains1InnerWithDefaults instantiates a new Chains1Inner object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetChainId + +`func (o *Chains1Inner) GetChainId() string` + +GetChainId returns the ChainId field if non-nil, zero value otherwise. + +### GetChainIdOk + +`func (o *Chains1Inner) GetChainIdOk() (*string, bool)` + +GetChainIdOk returns a tuple with the ChainId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainId + +`func (o *Chains1Inner) SetChainId(v string)` + +SetChainId sets ChainId field to given value. + + +### GetChainName + +`func (o *Chains1Inner) GetChainName() string` + +GetChainName returns the ChainName field if non-nil, zero value otherwise. + +### GetChainNameOk + +`func (o *Chains1Inner) GetChainNameOk() (*string, bool)` + +GetChainNameOk returns a tuple with the ChainName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainName + +`func (o *Chains1Inner) SetChainName(v string)` + +SetChainName sets ChainName field to given value. + + +### GetChainType + +`func (o *Chains1Inner) GetChainType() string` + +GetChainType returns the ChainType field if non-nil, zero value otherwise. + +### GetChainTypeOk + +`func (o *Chains1Inner) GetChainTypeOk() (*string, bool)` + +GetChainTypeOk returns a tuple with the ChainType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainType + +`func (o *Chains1Inner) SetChainType(v string)` + +SetChainType sets ChainType field to given value. + + +### GetNetworkName + +`func (o *Chains1Inner) GetNetworkName() string` + +GetNetworkName returns the NetworkName field if non-nil, zero value otherwise. + +### GetNetworkNameOk + +`func (o *Chains1Inner) GetNetworkNameOk() (*string, bool)` + +GetNetworkNameOk returns a tuple with the NetworkName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetNetworkName + +`func (o *Chains1Inner) SetNetworkName(v string)` + +SetNetworkName sets NetworkName field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ChainsApi.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ChainsApi.md new file mode 100644 index 0000000000..53a9881669 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ChainsApi.md @@ -0,0 +1,70 @@ +# \ChainsApi + +All URIs are relative to *http://localhost:3011/api/v1/@hyperledger/cactus-plugin-satp-hermes* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**GetChains**](ChainsApi.md#GetChains) | **Get** /api/v1/@hyperledger/cactus-plugin-satp-hermes/chains | Get supported chains + + + +## GetChains + +> []GetChains200ResponseInner GetChains(ctx).Execute() + +Get supported chains + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + openapiclient "github.com/hyperledger/cacti/packages/cactus-plugin-satp-hermes/src/main/go/generated" +) + +func main() { + + configuration := openapiclient.NewConfiguration() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ChainsApi.GetChains(context.Background()).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `ChainsApi.GetChains``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `GetChains`: []GetChains200ResponseInner + fmt.Fprintf(os.Stdout, "Response from `ChainsApi.GetChains`: %v\n", resp) +} +``` + +### Path Parameters + +This endpoint does not need any parameter. + +### Other Parameters + +Other parameters are passed through a pointer to a apiGetChainsRequest struct via the builder pattern + + +### Return type + +[**[]GetChains200ResponseInner**](GetChains200ResponseInner.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Continue200Response.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Continue200Response.md new file mode 100644 index 0000000000..90d4ab92af --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Continue200Response.md @@ -0,0 +1,51 @@ +# Continue200Response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**StatusResponse** | [**Transact200ResponseStatusResponse**](Transact200ResponseStatusResponse.md) | | + +## Methods + +### NewContinue200Response + +`func NewContinue200Response(statusResponse Transact200ResponseStatusResponse, ) *Continue200Response` + +NewContinue200Response instantiates a new Continue200Response object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewContinue200ResponseWithDefaults + +`func NewContinue200ResponseWithDefaults() *Continue200Response` + +NewContinue200ResponseWithDefaults instantiates a new Continue200Response object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetStatusResponse + +`func (o *Continue200Response) GetStatusResponse() Transact200ResponseStatusResponse` + +GetStatusResponse returns the StatusResponse field if non-nil, zero value otherwise. + +### GetStatusResponseOk + +`func (o *Continue200Response) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool)` + +GetStatusResponseOk returns a tuple with the StatusResponse field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatusResponse + +`func (o *Continue200Response) SetStatusResponse(v Transact200ResponseStatusResponse)` + +SetStatusResponse sets StatusResponse field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueRequest.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueRequest.md new file mode 100644 index 0000000000..1bdd7d3aeb --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueRequest.md @@ -0,0 +1,72 @@ +# ContinueRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**SessionId** | **string** | A unique identifier for the transaction session to be continued. | +**ContextId** | **string** | A unique identifier for the transaction context. | + +## Methods + +### NewContinueRequest + +`func NewContinueRequest(sessionId string, contextId string, ) *ContinueRequest` + +NewContinueRequest instantiates a new ContinueRequest object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewContinueRequestWithDefaults + +`func NewContinueRequestWithDefaults() *ContinueRequest` + +NewContinueRequestWithDefaults instantiates a new ContinueRequest object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetSessionId + +`func (o *ContinueRequest) GetSessionId() string` + +GetSessionId returns the SessionId field if non-nil, zero value otherwise. + +### GetSessionIdOk + +`func (o *ContinueRequest) GetSessionIdOk() (*string, bool)` + +GetSessionIdOk returns a tuple with the SessionId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSessionId + +`func (o *ContinueRequest) SetSessionId(v string)` + +SetSessionId sets SessionId field to given value. + + +### GetContextId + +`func (o *ContinueRequest) GetContextId() string` + +GetContextId returns the ContextId field if non-nil, zero value otherwise. + +### GetContextIdOk + +`func (o *ContinueRequest) GetContextIdOk() (*string, bool)` + +GetContextIdOk returns a tuple with the ContextId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContextId + +`func (o *ContinueRequest) SetContextId(v string)` + +SetContextId sets ContextId field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueResponse.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueResponse.md new file mode 100644 index 0000000000..5be0f5d26f --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/ContinueResponse.md @@ -0,0 +1,51 @@ +# ContinueResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**StatusResponse** | [**Transact200ResponseStatusResponse**](Transact200ResponseStatusResponse.md) | | + +## Methods + +### NewContinueResponse + +`func NewContinueResponse(statusResponse Transact200ResponseStatusResponse, ) *ContinueResponse` + +NewContinueResponse instantiates a new ContinueResponse object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewContinueResponseWithDefaults + +`func NewContinueResponseWithDefaults() *ContinueResponse` + +NewContinueResponseWithDefaults instantiates a new ContinueResponse object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetStatusResponse + +`func (o *ContinueResponse) GetStatusResponse() Transact200ResponseStatusResponse` + +GetStatusResponse returns the StatusResponse field if non-nil, zero value otherwise. + +### GetStatusResponseOk + +`func (o *ContinueResponse) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool)` + +GetStatusResponseOk returns a tuple with the StatusResponse field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatusResponse + +`func (o *ContinueResponse) SetStatusResponse(v Transact200ResponseStatusResponse)` + +SetStatusResponse sets StatusResponse field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetChains200ResponseInner.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetChains200ResponseInner.md new file mode 100644 index 0000000000..7c96e73a17 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetChains200ResponseInner.md @@ -0,0 +1,114 @@ +# GetChains200ResponseInner + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ChainId** | **string** | A unique identifier for the blockchain network. | +**ChainName** | **string** | The name of the blockchain network. | +**ChainType** | **string** | The type of blockchain network (e.g., 'evm', 'fabric'). | +**NetworkName** | **string** | The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). | + +## Methods + +### NewGetChains200ResponseInner + +`func NewGetChains200ResponseInner(chainId string, chainName string, chainType string, networkName string, ) *GetChains200ResponseInner` + +NewGetChains200ResponseInner instantiates a new GetChains200ResponseInner object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewGetChains200ResponseInnerWithDefaults + +`func NewGetChains200ResponseInnerWithDefaults() *GetChains200ResponseInner` + +NewGetChains200ResponseInnerWithDefaults instantiates a new GetChains200ResponseInner object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetChainId + +`func (o *GetChains200ResponseInner) GetChainId() string` + +GetChainId returns the ChainId field if non-nil, zero value otherwise. + +### GetChainIdOk + +`func (o *GetChains200ResponseInner) GetChainIdOk() (*string, bool)` + +GetChainIdOk returns a tuple with the ChainId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainId + +`func (o *GetChains200ResponseInner) SetChainId(v string)` + +SetChainId sets ChainId field to given value. + + +### GetChainName + +`func (o *GetChains200ResponseInner) GetChainName() string` + +GetChainName returns the ChainName field if non-nil, zero value otherwise. + +### GetChainNameOk + +`func (o *GetChains200ResponseInner) GetChainNameOk() (*string, bool)` + +GetChainNameOk returns a tuple with the ChainName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainName + +`func (o *GetChains200ResponseInner) SetChainName(v string)` + +SetChainName sets ChainName field to given value. + + +### GetChainType + +`func (o *GetChains200ResponseInner) GetChainType() string` + +GetChainType returns the ChainType field if non-nil, zero value otherwise. + +### GetChainTypeOk + +`func (o *GetChains200ResponseInner) GetChainTypeOk() (*string, bool)` + +GetChainTypeOk returns a tuple with the ChainType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainType + +`func (o *GetChains200ResponseInner) SetChainType(v string)` + +SetChainType sets ChainType field to given value. + + +### GetNetworkName + +`func (o *GetChains200ResponseInner) GetNetworkName() string` + +GetNetworkName returns the NetworkName field if non-nil, zero value otherwise. + +### GetNetworkNameOk + +`func (o *GetChains200ResponseInner) GetNetworkNameOk() (*string, bool)` + +GetNetworkNameOk returns a tuple with the NetworkName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetNetworkName + +`func (o *GetChains200ResponseInner) SetNetworkName(v string)` + +SetNetworkName sets NetworkName field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetHealthCheck200Response.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetHealthCheck200Response.md new file mode 100644 index 0000000000..c8d4efc8cd --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetHealthCheck200Response.md @@ -0,0 +1,56 @@ +# GetHealthCheck200Response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Status** | Pointer to **string** | | [optional] + +## Methods + +### NewGetHealthCheck200Response + +`func NewGetHealthCheck200Response() *GetHealthCheck200Response` + +NewGetHealthCheck200Response instantiates a new GetHealthCheck200Response object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewGetHealthCheck200ResponseWithDefaults + +`func NewGetHealthCheck200ResponseWithDefaults() *GetHealthCheck200Response` + +NewGetHealthCheck200ResponseWithDefaults instantiates a new GetHealthCheck200Response object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetStatus + +`func (o *GetHealthCheck200Response) GetStatus() string` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *GetHealthCheck200Response) GetStatusOk() (*string, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatus + +`func (o *GetHealthCheck200Response) SetStatus(v string)` + +SetStatus sets Status field to given value. + +### HasStatus + +`func (o *GetHealthCheck200Response) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetIntegrations200ResponseInner.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetIntegrations200ResponseInner.md new file mode 100644 index 0000000000..585d83bcb7 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetIntegrations200ResponseInner.md @@ -0,0 +1,114 @@ +# GetIntegrations200ResponseInner + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ChainId** | **string** | A unique identifier for the blockchain network. | +**ChainName** | **string** | The name of the blockchain network. | +**ChainType** | **string** | The type of blockchain network (e.g., 'evm', 'fabric'). | +**NetworkName** | **string** | The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). | + +## Methods + +### NewGetIntegrations200ResponseInner + +`func NewGetIntegrations200ResponseInner(chainId string, chainName string, chainType string, networkName string, ) *GetIntegrations200ResponseInner` + +NewGetIntegrations200ResponseInner instantiates a new GetIntegrations200ResponseInner object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewGetIntegrations200ResponseInnerWithDefaults + +`func NewGetIntegrations200ResponseInnerWithDefaults() *GetIntegrations200ResponseInner` + +NewGetIntegrations200ResponseInnerWithDefaults instantiates a new GetIntegrations200ResponseInner object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetChainId + +`func (o *GetIntegrations200ResponseInner) GetChainId() string` + +GetChainId returns the ChainId field if non-nil, zero value otherwise. + +### GetChainIdOk + +`func (o *GetIntegrations200ResponseInner) GetChainIdOk() (*string, bool)` + +GetChainIdOk returns a tuple with the ChainId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainId + +`func (o *GetIntegrations200ResponseInner) SetChainId(v string)` + +SetChainId sets ChainId field to given value. + + +### GetChainName + +`func (o *GetIntegrations200ResponseInner) GetChainName() string` + +GetChainName returns the ChainName field if non-nil, zero value otherwise. + +### GetChainNameOk + +`func (o *GetIntegrations200ResponseInner) GetChainNameOk() (*string, bool)` + +GetChainNameOk returns a tuple with the ChainName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainName + +`func (o *GetIntegrations200ResponseInner) SetChainName(v string)` + +SetChainName sets ChainName field to given value. + + +### GetChainType + +`func (o *GetIntegrations200ResponseInner) GetChainType() string` + +GetChainType returns the ChainType field if non-nil, zero value otherwise. + +### GetChainTypeOk + +`func (o *GetIntegrations200ResponseInner) GetChainTypeOk() (*string, bool)` + +GetChainTypeOk returns a tuple with the ChainType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainType + +`func (o *GetIntegrations200ResponseInner) SetChainType(v string)` + +SetChainType sets ChainType field to given value. + + +### GetNetworkName + +`func (o *GetIntegrations200ResponseInner) GetNetworkName() string` + +GetNetworkName returns the NetworkName field if non-nil, zero value otherwise. + +### GetNetworkNameOk + +`func (o *GetIntegrations200ResponseInner) GetNetworkNameOk() (*string, bool)` + +GetNetworkNameOk returns a tuple with the NetworkName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetNetworkName + +`func (o *GetIntegrations200ResponseInner) SetNetworkName(v string)` + +SetNetworkName sets NetworkName field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromToken.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromToken.md new file mode 100644 index 0000000000..b8964106e4 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromToken.md @@ -0,0 +1,265 @@ +# GetRoutes200ResponseRoutesInnerFromToken + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ChainID** | **string** | The network of the DLT being interacted with. TODO: implement network identification draft | +**ChainType** | **string** | Supported DLT protocols. | +**Address** | **string** | A blockchain address. | +**Name** | Pointer to **string** | The name of the token. | [optional] +**Symbol** | **string** | The symbol of the token. | +**Decimals** | **int32** | How many decimals the token supports. | +**LogoURI** | Pointer to **string** | The logo of a token, chain, dex etc. | [optional] +**Tags** | Pointer to **[]string** | List of tags identifiers providing additional context or categorization. | [optional] +**PriceUSD** | Pointer to **string** | The current price of the token in USD. | [optional] +**Extensions** | Pointer to [**GetRoutes200ResponseRoutesInnerFromTokenExtensions**](GetRoutes200ResponseRoutesInnerFromTokenExtensions.md) | | [optional] + +## Methods + +### NewGetRoutes200ResponseRoutesInnerFromToken + +`func NewGetRoutes200ResponseRoutesInnerFromToken(chainID string, chainType string, address string, symbol string, decimals int32, ) *GetRoutes200ResponseRoutesInnerFromToken` + +NewGetRoutes200ResponseRoutesInnerFromToken instantiates a new GetRoutes200ResponseRoutesInnerFromToken object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewGetRoutes200ResponseRoutesInnerFromTokenWithDefaults + +`func NewGetRoutes200ResponseRoutesInnerFromTokenWithDefaults() *GetRoutes200ResponseRoutesInnerFromToken` + +NewGetRoutes200ResponseRoutesInnerFromTokenWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerFromToken object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetChainID + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainID() string` + +GetChainID returns the ChainID field if non-nil, zero value otherwise. + +### GetChainIDOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainIDOk() (*string, bool)` + +GetChainIDOk returns a tuple with the ChainID field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainID + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetChainID(v string)` + +SetChainID sets ChainID field to given value. + + +### GetChainType + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainType() string` + +GetChainType returns the ChainType field if non-nil, zero value otherwise. + +### GetChainTypeOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainTypeOk() (*string, bool)` + +GetChainTypeOk returns a tuple with the ChainType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetChainType + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetChainType(v string)` + +SetChainType sets ChainType field to given value. + + +### GetAddress + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetAddress() string` + +GetAddress returns the Address field if non-nil, zero value otherwise. + +### GetAddressOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetAddressOk() (*string, bool)` + +GetAddressOk returns a tuple with the Address field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAddress + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetAddress(v string)` + +SetAddress sets Address field to given value. + + +### GetName + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetNameOk() (*string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetName + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetName(v string)` + +SetName sets Name field to given value. + +### HasName + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) HasName() bool` + +HasName returns a boolean if a field has been set. + +### GetSymbol + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetSymbol() string` + +GetSymbol returns the Symbol field if non-nil, zero value otherwise. + +### GetSymbolOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetSymbolOk() (*string, bool)` + +GetSymbolOk returns a tuple with the Symbol field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSymbol + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetSymbol(v string)` + +SetSymbol sets Symbol field to given value. + + +### GetDecimals + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetDecimals() int32` + +GetDecimals returns the Decimals field if non-nil, zero value otherwise. + +### GetDecimalsOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetDecimalsOk() (*int32, bool)` + +GetDecimalsOk returns a tuple with the Decimals field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDecimals + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetDecimals(v int32)` + +SetDecimals sets Decimals field to given value. + + +### GetLogoURI + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetLogoURI() string` + +GetLogoURI returns the LogoURI field if non-nil, zero value otherwise. + +### GetLogoURIOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetLogoURIOk() (*string, bool)` + +GetLogoURIOk returns a tuple with the LogoURI field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetLogoURI + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetLogoURI(v string)` + +SetLogoURI sets LogoURI field to given value. + +### HasLogoURI + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) HasLogoURI() bool` + +HasLogoURI returns a boolean if a field has been set. + +### GetTags + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetTags() []string` + +GetTags returns the Tags field if non-nil, zero value otherwise. + +### GetTagsOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetTagsOk() (*[]string, bool)` + +GetTagsOk returns a tuple with the Tags field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTags + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetTags(v []string)` + +SetTags sets Tags field to given value. + +### HasTags + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) HasTags() bool` + +HasTags returns a boolean if a field has been set. + +### GetPriceUSD + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetPriceUSD() string` + +GetPriceUSD returns the PriceUSD field if non-nil, zero value otherwise. + +### GetPriceUSDOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetPriceUSDOk() (*string, bool)` + +GetPriceUSDOk returns a tuple with the PriceUSD field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPriceUSD + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetPriceUSD(v string)` + +SetPriceUSD sets PriceUSD field to given value. + +### HasPriceUSD + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) HasPriceUSD() bool` + +HasPriceUSD returns a boolean if a field has been set. + +### GetExtensions + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetExtensions() GetRoutes200ResponseRoutesInnerFromTokenExtensions` + +GetExtensions returns the Extensions field if non-nil, zero value otherwise. + +### GetExtensionsOk + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) GetExtensionsOk() (*GetRoutes200ResponseRoutesInnerFromTokenExtensions, bool)` + +GetExtensionsOk returns a tuple with the Extensions field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetExtensions + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) SetExtensions(v GetRoutes200ResponseRoutesInnerFromTokenExtensions)` + +SetExtensions sets Extensions field to given value. + +### HasExtensions + +`func (o *GetRoutes200ResponseRoutesInnerFromToken) HasExtensions() bool` + +HasExtensions returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensions.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensions.md new file mode 100644 index 0000000000..99390587a8 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensions.md @@ -0,0 +1,82 @@ +# GetRoutes200ResponseRoutesInnerFromTokenExtensions + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**BridgeInfo** | Pointer to [**map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue**](GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue.md) | | [optional] +**Verified** | Pointer to **bool** | Indicates whether the token is verified. | [optional] + +## Methods + +### NewGetRoutes200ResponseRoutesInnerFromTokenExtensions + +`func NewGetRoutes200ResponseRoutesInnerFromTokenExtensions() *GetRoutes200ResponseRoutesInnerFromTokenExtensions` + +NewGetRoutes200ResponseRoutesInnerFromTokenExtensions instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensions object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsWithDefaults + +`func NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsWithDefaults() *GetRoutes200ResponseRoutesInnerFromTokenExtensions` + +NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensions object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetBridgeInfo + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetBridgeInfo() map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue` + +GetBridgeInfo returns the BridgeInfo field if non-nil, zero value otherwise. + +### GetBridgeInfoOk + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetBridgeInfoOk() (*map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue, bool)` + +GetBridgeInfoOk returns a tuple with the BridgeInfo field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetBridgeInfo + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) SetBridgeInfo(v map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue)` + +SetBridgeInfo sets BridgeInfo field to given value. + +### HasBridgeInfo + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) HasBridgeInfo() bool` + +HasBridgeInfo returns a boolean if a field has been set. + +### GetVerified + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetVerified() bool` + +GetVerified returns the Verified field if non-nil, zero value otherwise. + +### GetVerifiedOk + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetVerifiedOk() (*bool, bool)` + +GetVerifiedOk returns a tuple with the Verified field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetVerified + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) SetVerified(v bool)` + +SetVerified sets Verified field to given value. + +### HasVerified + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) HasVerified() bool` + +HasVerified returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue.md new file mode 100644 index 0000000000..f46c000316 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue.md @@ -0,0 +1,56 @@ +# GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**TokenAddress** | Pointer to **string** | The address of the token being transferred. | [optional] + +## Methods + +### NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + +`func NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue() *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue` + +NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValueWithDefaults + +`func NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValueWithDefaults() *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue` + +NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValueWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetTokenAddress + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) GetTokenAddress() string` + +GetTokenAddress returns the TokenAddress field if non-nil, zero value otherwise. + +### GetTokenAddressOk + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) GetTokenAddressOk() (*string, bool)` + +GetTokenAddressOk returns a tuple with the TokenAddress field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTokenAddress + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) SetTokenAddress(v string)` + +SetTokenAddress sets TokenAddress field to given value. + +### HasTokenAddress + +`func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) HasTokenAddress() bool` + +HasTokenAddress returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/HealthCheckResponse.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/HealthCheckResponse.md new file mode 100644 index 0000000000..b2b2c03b63 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/HealthCheckResponse.md @@ -0,0 +1,56 @@ +# HealthCheckResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Status** | Pointer to **string** | | [optional] + +## Methods + +### NewHealthCheckResponse + +`func NewHealthCheckResponse() *HealthCheckResponse` + +NewHealthCheckResponse instantiates a new HealthCheckResponse object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewHealthCheckResponseWithDefaults + +`func NewHealthCheckResponseWithDefaults() *HealthCheckResponse` + +NewHealthCheckResponseWithDefaults instantiates a new HealthCheckResponse object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetStatus + +`func (o *HealthCheckResponse) GetStatus() string` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *HealthCheckResponse) GetStatusOk() (*string, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatus + +`func (o *HealthCheckResponse) SetStatus(v string)` + +SetStatus sets Status field to given value. + +### HasStatus + +`func (o *HealthCheckResponse) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Pause200Response.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Pause200Response.md new file mode 100644 index 0000000000..c18f13405d --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Pause200Response.md @@ -0,0 +1,51 @@ +# Pause200Response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**StatusResponse** | [**Transact200ResponseStatusResponse**](Transact200ResponseStatusResponse.md) | | + +## Methods + +### NewPause200Response + +`func NewPause200Response(statusResponse Transact200ResponseStatusResponse, ) *Pause200Response` + +NewPause200Response instantiates a new Pause200Response object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewPause200ResponseWithDefaults + +`func NewPause200ResponseWithDefaults() *Pause200Response` + +NewPause200ResponseWithDefaults instantiates a new Pause200Response object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetStatusResponse + +`func (o *Pause200Response) GetStatusResponse() Transact200ResponseStatusResponse` + +GetStatusResponse returns the StatusResponse field if non-nil, zero value otherwise. + +### GetStatusResponseOk + +`func (o *Pause200Response) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool)` + +GetStatusResponseOk returns a tuple with the StatusResponse field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatusResponse + +`func (o *Pause200Response) SetStatusResponse(v Transact200ResponseStatusResponse)` + +SetStatusResponse sets StatusResponse field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseRequest.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseRequest.md new file mode 100644 index 0000000000..211f1a9dc6 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseRequest.md @@ -0,0 +1,82 @@ +# PauseRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**SessionId** | Pointer to **string** | | [optional] +**ContextId** | Pointer to **string** | | [optional] + +## Methods + +### NewPauseRequest + +`func NewPauseRequest() *PauseRequest` + +NewPauseRequest instantiates a new PauseRequest object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewPauseRequestWithDefaults + +`func NewPauseRequestWithDefaults() *PauseRequest` + +NewPauseRequestWithDefaults instantiates a new PauseRequest object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetSessionId + +`func (o *PauseRequest) GetSessionId() string` + +GetSessionId returns the SessionId field if non-nil, zero value otherwise. + +### GetSessionIdOk + +`func (o *PauseRequest) GetSessionIdOk() (*string, bool)` + +GetSessionIdOk returns a tuple with the SessionId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSessionId + +`func (o *PauseRequest) SetSessionId(v string)` + +SetSessionId sets SessionId field to given value. + +### HasSessionId + +`func (o *PauseRequest) HasSessionId() bool` + +HasSessionId returns a boolean if a field has been set. + +### GetContextId + +`func (o *PauseRequest) GetContextId() string` + +GetContextId returns the ContextId field if non-nil, zero value otherwise. + +### GetContextIdOk + +`func (o *PauseRequest) GetContextIdOk() (*string, bool)` + +GetContextIdOk returns a tuple with the ContextId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContextId + +`func (o *PauseRequest) SetContextId(v string)` + +SetContextId sets ContextId field to given value. + +### HasContextId + +`func (o *PauseRequest) HasContextId() bool` + +HasContextId returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseResponse.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseResponse.md new file mode 100644 index 0000000000..0a02a46c9c --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/PauseResponse.md @@ -0,0 +1,51 @@ +# PauseResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**StatusResponse** | [**Transact200ResponseStatusResponse**](Transact200ResponseStatusResponse.md) | | + +## Methods + +### NewPauseResponse + +`func NewPauseResponse(statusResponse Transact200ResponseStatusResponse, ) *PauseResponse` + +NewPauseResponse instantiates a new PauseResponse object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewPauseResponseWithDefaults + +`func NewPauseResponseWithDefaults() *PauseResponse` + +NewPauseResponseWithDefaults instantiates a new PauseResponse object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetStatusResponse + +`func (o *PauseResponse) GetStatusResponse() Transact200ResponseStatusResponse` + +GetStatusResponse returns the StatusResponse field if non-nil, zero value otherwise. + +### GetStatusResponseOk + +`func (o *PauseResponse) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool)` + +GetStatusResponseOk returns a tuple with the StatusResponse field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatusResponse + +`func (o *PauseResponse) SetStatusResponse(v Transact200ResponseStatusResponse)` + +SetStatusResponse sets StatusResponse field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseDestinationChain.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseDestinationChain.md new file mode 100644 index 0000000000..fdff89f7a4 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseDestinationChain.md @@ -0,0 +1,102 @@ +# Transact200ResponseStatusResponseDestinationChain + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**DltProtocol** | Pointer to **interface{}** | | [optional] +**DltSubnetworkID** | Pointer to **interface{}** | | [optional] + +## Methods + +### NewTransact200ResponseStatusResponseDestinationChain + +`func NewTransact200ResponseStatusResponseDestinationChain() *Transact200ResponseStatusResponseDestinationChain` + +NewTransact200ResponseStatusResponseDestinationChain instantiates a new Transact200ResponseStatusResponseDestinationChain object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewTransact200ResponseStatusResponseDestinationChainWithDefaults + +`func NewTransact200ResponseStatusResponseDestinationChainWithDefaults() *Transact200ResponseStatusResponseDestinationChain` + +NewTransact200ResponseStatusResponseDestinationChainWithDefaults instantiates a new Transact200ResponseStatusResponseDestinationChain object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetDltProtocol + +`func (o *Transact200ResponseStatusResponseDestinationChain) GetDltProtocol() interface{}` + +GetDltProtocol returns the DltProtocol field if non-nil, zero value otherwise. + +### GetDltProtocolOk + +`func (o *Transact200ResponseStatusResponseDestinationChain) GetDltProtocolOk() (*interface{}, bool)` + +GetDltProtocolOk returns a tuple with the DltProtocol field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDltProtocol + +`func (o *Transact200ResponseStatusResponseDestinationChain) SetDltProtocol(v interface{})` + +SetDltProtocol sets DltProtocol field to given value. + +### HasDltProtocol + +`func (o *Transact200ResponseStatusResponseDestinationChain) HasDltProtocol() bool` + +HasDltProtocol returns a boolean if a field has been set. + +### SetDltProtocolNil + +`func (o *Transact200ResponseStatusResponseDestinationChain) SetDltProtocolNil(b bool)` + + SetDltProtocolNil sets the value for DltProtocol to be an explicit nil + +### UnsetDltProtocol +`func (o *Transact200ResponseStatusResponseDestinationChain) UnsetDltProtocol()` + +UnsetDltProtocol ensures that no value is present for DltProtocol, not even an explicit nil +### GetDltSubnetworkID + +`func (o *Transact200ResponseStatusResponseDestinationChain) GetDltSubnetworkID() interface{}` + +GetDltSubnetworkID returns the DltSubnetworkID field if non-nil, zero value otherwise. + +### GetDltSubnetworkIDOk + +`func (o *Transact200ResponseStatusResponseDestinationChain) GetDltSubnetworkIDOk() (*interface{}, bool)` + +GetDltSubnetworkIDOk returns a tuple with the DltSubnetworkID field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDltSubnetworkID + +`func (o *Transact200ResponseStatusResponseDestinationChain) SetDltSubnetworkID(v interface{})` + +SetDltSubnetworkID sets DltSubnetworkID field to given value. + +### HasDltSubnetworkID + +`func (o *Transact200ResponseStatusResponseDestinationChain) HasDltSubnetworkID() bool` + +HasDltSubnetworkID returns a boolean if a field has been set. + +### SetDltSubnetworkIDNil + +`func (o *Transact200ResponseStatusResponseDestinationChain) SetDltSubnetworkIDNil(b bool)` + + SetDltSubnetworkIDNil sets the value for DltSubnetworkID to be an explicit nil + +### UnsetDltSubnetworkID +`func (o *Transact200ResponseStatusResponseDestinationChain) UnsetDltSubnetworkID()` + +UnsetDltSubnetworkID ensures that no value is present for DltSubnetworkID, not even an explicit nil + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseOriginChain.md b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseOriginChain.md new file mode 100644 index 0000000000..1c53906205 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/docs/Transact200ResponseStatusResponseOriginChain.md @@ -0,0 +1,102 @@ +# Transact200ResponseStatusResponseOriginChain + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**DltProtocol** | Pointer to **interface{}** | | [optional] +**DltSubnetworkID** | Pointer to **interface{}** | | [optional] + +## Methods + +### NewTransact200ResponseStatusResponseOriginChain + +`func NewTransact200ResponseStatusResponseOriginChain() *Transact200ResponseStatusResponseOriginChain` + +NewTransact200ResponseStatusResponseOriginChain instantiates a new Transact200ResponseStatusResponseOriginChain object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewTransact200ResponseStatusResponseOriginChainWithDefaults + +`func NewTransact200ResponseStatusResponseOriginChainWithDefaults() *Transact200ResponseStatusResponseOriginChain` + +NewTransact200ResponseStatusResponseOriginChainWithDefaults instantiates a new Transact200ResponseStatusResponseOriginChain object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetDltProtocol + +`func (o *Transact200ResponseStatusResponseOriginChain) GetDltProtocol() interface{}` + +GetDltProtocol returns the DltProtocol field if non-nil, zero value otherwise. + +### GetDltProtocolOk + +`func (o *Transact200ResponseStatusResponseOriginChain) GetDltProtocolOk() (*interface{}, bool)` + +GetDltProtocolOk returns a tuple with the DltProtocol field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDltProtocol + +`func (o *Transact200ResponseStatusResponseOriginChain) SetDltProtocol(v interface{})` + +SetDltProtocol sets DltProtocol field to given value. + +### HasDltProtocol + +`func (o *Transact200ResponseStatusResponseOriginChain) HasDltProtocol() bool` + +HasDltProtocol returns a boolean if a field has been set. + +### SetDltProtocolNil + +`func (o *Transact200ResponseStatusResponseOriginChain) SetDltProtocolNil(b bool)` + + SetDltProtocolNil sets the value for DltProtocol to be an explicit nil + +### UnsetDltProtocol +`func (o *Transact200ResponseStatusResponseOriginChain) UnsetDltProtocol()` + +UnsetDltProtocol ensures that no value is present for DltProtocol, not even an explicit nil +### GetDltSubnetworkID + +`func (o *Transact200ResponseStatusResponseOriginChain) GetDltSubnetworkID() interface{}` + +GetDltSubnetworkID returns the DltSubnetworkID field if non-nil, zero value otherwise. + +### GetDltSubnetworkIDOk + +`func (o *Transact200ResponseStatusResponseOriginChain) GetDltSubnetworkIDOk() (*interface{}, bool)` + +GetDltSubnetworkIDOk returns a tuple with the DltSubnetworkID field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDltSubnetworkID + +`func (o *Transact200ResponseStatusResponseOriginChain) SetDltSubnetworkID(v interface{})` + +SetDltSubnetworkID sets DltSubnetworkID field to given value. + +### HasDltSubnetworkID + +`func (o *Transact200ResponseStatusResponseOriginChain) HasDltSubnetworkID() bool` + +HasDltSubnetworkID returns a boolean if a field has been set. + +### SetDltSubnetworkIDNil + +`func (o *Transact200ResponseStatusResponseOriginChain) SetDltSubnetworkIDNil(b bool)` + + SetDltSubnetworkIDNil sets the value for DltSubnetworkID to be an explicit nil + +### UnsetDltSubnetworkID +`func (o *Transact200ResponseStatusResponseOriginChain) UnsetDltSubnetworkID()` + +UnsetDltSubnetworkID ensures that no value is present for DltSubnetworkID, not even an explicit nil + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chain.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chain.go new file mode 100644 index 0000000000..f2e7079574 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chain.go @@ -0,0 +1,202 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the Chain type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Chain{} + +// Chain struct for Chain +type Chain struct { + // A unique identifier for the blockchain network. + ChainId string `json:"chainId"` + // The name of the blockchain network. + ChainName string `json:"chainName"` + // The type of blockchain network (e.g., 'evm', 'fabric'). + ChainType string `json:"chainType"` + // The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). + NetworkName string `json:"networkName"` +} + +// NewChain instantiates a new Chain object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChain(chainId string, chainName string, chainType string, networkName string) *Chain { + this := Chain{} + this.ChainId = chainId + this.ChainName = chainName + this.ChainType = chainType + this.NetworkName = networkName + return &this +} + +// NewChainWithDefaults instantiates a new Chain object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChainWithDefaults() *Chain { + this := Chain{} + return &this +} + +// GetChainId returns the ChainId field value +func (o *Chain) GetChainId() string { + if o == nil { + var ret string + return ret + } + + return o.ChainId +} + +// GetChainIdOk returns a tuple with the ChainId field value +// and a boolean to check if the value has been set. +func (o *Chain) GetChainIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainId, true +} + +// SetChainId sets field value +func (o *Chain) SetChainId(v string) { + o.ChainId = v +} + +// GetChainName returns the ChainName field value +func (o *Chain) GetChainName() string { + if o == nil { + var ret string + return ret + } + + return o.ChainName +} + +// GetChainNameOk returns a tuple with the ChainName field value +// and a boolean to check if the value has been set. +func (o *Chain) GetChainNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainName, true +} + +// SetChainName sets field value +func (o *Chain) SetChainName(v string) { + o.ChainName = v +} + +// GetChainType returns the ChainType field value +func (o *Chain) GetChainType() string { + if o == nil { + var ret string + return ret + } + + return o.ChainType +} + +// GetChainTypeOk returns a tuple with the ChainType field value +// and a boolean to check if the value has been set. +func (o *Chain) GetChainTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainType, true +} + +// SetChainType sets field value +func (o *Chain) SetChainType(v string) { + o.ChainType = v +} + +// GetNetworkName returns the NetworkName field value +func (o *Chain) GetNetworkName() string { + if o == nil { + var ret string + return ret + } + + return o.NetworkName +} + +// GetNetworkNameOk returns a tuple with the NetworkName field value +// and a boolean to check if the value has been set. +func (o *Chain) GetNetworkNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetworkName, true +} + +// SetNetworkName sets field value +func (o *Chain) SetNetworkName(v string) { + o.NetworkName = v +} + +func (o Chain) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Chain) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["chainId"] = o.ChainId + toSerialize["chainName"] = o.ChainName + toSerialize["chainType"] = o.ChainType + toSerialize["networkName"] = o.NetworkName + return toSerialize, nil +} + +type NullableChain struct { + value *Chain + isSet bool +} + +func (v NullableChain) Get() *Chain { + return v.value +} + +func (v *NullableChain) Set(val *Chain) { + v.value = val + v.isSet = true +} + +func (v NullableChain) IsSet() bool { + return v.isSet +} + +func (v *NullableChain) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChain(val *Chain) *NullableChain { + return &NullableChain{value: val, isSet: true} +} + +func (v NullableChain) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChain) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chains_1_inner.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chains_1_inner.go new file mode 100644 index 0000000000..49d8379190 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_chains_1_inner.go @@ -0,0 +1,202 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the Chains1Inner type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Chains1Inner{} + +// Chains1Inner struct for Chains1Inner +type Chains1Inner struct { + // A unique identifier for the blockchain network. + ChainId string `json:"chainId"` + // The name of the blockchain network. + ChainName string `json:"chainName"` + // The type of blockchain network (e.g., 'evm', 'fabric'). + ChainType string `json:"chainType"` + // The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). + NetworkName string `json:"networkName"` +} + +// NewChains1Inner instantiates a new Chains1Inner object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChains1Inner(chainId string, chainName string, chainType string, networkName string) *Chains1Inner { + this := Chains1Inner{} + this.ChainId = chainId + this.ChainName = chainName + this.ChainType = chainType + this.NetworkName = networkName + return &this +} + +// NewChains1InnerWithDefaults instantiates a new Chains1Inner object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChains1InnerWithDefaults() *Chains1Inner { + this := Chains1Inner{} + return &this +} + +// GetChainId returns the ChainId field value +func (o *Chains1Inner) GetChainId() string { + if o == nil { + var ret string + return ret + } + + return o.ChainId +} + +// GetChainIdOk returns a tuple with the ChainId field value +// and a boolean to check if the value has been set. +func (o *Chains1Inner) GetChainIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainId, true +} + +// SetChainId sets field value +func (o *Chains1Inner) SetChainId(v string) { + o.ChainId = v +} + +// GetChainName returns the ChainName field value +func (o *Chains1Inner) GetChainName() string { + if o == nil { + var ret string + return ret + } + + return o.ChainName +} + +// GetChainNameOk returns a tuple with the ChainName field value +// and a boolean to check if the value has been set. +func (o *Chains1Inner) GetChainNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainName, true +} + +// SetChainName sets field value +func (o *Chains1Inner) SetChainName(v string) { + o.ChainName = v +} + +// GetChainType returns the ChainType field value +func (o *Chains1Inner) GetChainType() string { + if o == nil { + var ret string + return ret + } + + return o.ChainType +} + +// GetChainTypeOk returns a tuple with the ChainType field value +// and a boolean to check if the value has been set. +func (o *Chains1Inner) GetChainTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainType, true +} + +// SetChainType sets field value +func (o *Chains1Inner) SetChainType(v string) { + o.ChainType = v +} + +// GetNetworkName returns the NetworkName field value +func (o *Chains1Inner) GetNetworkName() string { + if o == nil { + var ret string + return ret + } + + return o.NetworkName +} + +// GetNetworkNameOk returns a tuple with the NetworkName field value +// and a boolean to check if the value has been set. +func (o *Chains1Inner) GetNetworkNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetworkName, true +} + +// SetNetworkName sets field value +func (o *Chains1Inner) SetNetworkName(v string) { + o.NetworkName = v +} + +func (o Chains1Inner) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Chains1Inner) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["chainId"] = o.ChainId + toSerialize["chainName"] = o.ChainName + toSerialize["chainType"] = o.ChainType + toSerialize["networkName"] = o.NetworkName + return toSerialize, nil +} + +type NullableChains1Inner struct { + value *Chains1Inner + isSet bool +} + +func (v NullableChains1Inner) Get() *Chains1Inner { + return v.value +} + +func (v *NullableChains1Inner) Set(val *Chains1Inner) { + v.value = val + v.isSet = true +} + +func (v NullableChains1Inner) IsSet() bool { + return v.isSet +} + +func (v *NullableChains1Inner) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChains1Inner(val *Chains1Inner) *NullableChains1Inner { + return &NullableChains1Inner{value: val, isSet: true} +} + +func (v NullableChains1Inner) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChains1Inner) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_200_response.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_200_response.go new file mode 100644 index 0000000000..d9bea245da --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_200_response.go @@ -0,0 +1,117 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the Continue200Response type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Continue200Response{} + +// Continue200Response Response schema for a continue request, returning the status of the SATP session. +type Continue200Response struct { + StatusResponse Transact200ResponseStatusResponse `json:"statusResponse"` +} + +// NewContinue200Response instantiates a new Continue200Response object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewContinue200Response(statusResponse Transact200ResponseStatusResponse) *Continue200Response { + this := Continue200Response{} + this.StatusResponse = statusResponse + return &this +} + +// NewContinue200ResponseWithDefaults instantiates a new Continue200Response object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewContinue200ResponseWithDefaults() *Continue200Response { + this := Continue200Response{} + return &this +} + +// GetStatusResponse returns the StatusResponse field value +func (o *Continue200Response) GetStatusResponse() Transact200ResponseStatusResponse { + if o == nil { + var ret Transact200ResponseStatusResponse + return ret + } + + return o.StatusResponse +} + +// GetStatusResponseOk returns a tuple with the StatusResponse field value +// and a boolean to check if the value has been set. +func (o *Continue200Response) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool) { + if o == nil { + return nil, false + } + return &o.StatusResponse, true +} + +// SetStatusResponse sets field value +func (o *Continue200Response) SetStatusResponse(v Transact200ResponseStatusResponse) { + o.StatusResponse = v +} + +func (o Continue200Response) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Continue200Response) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["statusResponse"] = o.StatusResponse + return toSerialize, nil +} + +type NullableContinue200Response struct { + value *Continue200Response + isSet bool +} + +func (v NullableContinue200Response) Get() *Continue200Response { + return v.value +} + +func (v *NullableContinue200Response) Set(val *Continue200Response) { + v.value = val + v.isSet = true +} + +func (v NullableContinue200Response) IsSet() bool { + return v.isSet +} + +func (v *NullableContinue200Response) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableContinue200Response(val *Continue200Response) *NullableContinue200Response { + return &NullableContinue200Response{value: val, isSet: true} +} + +func (v NullableContinue200Response) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableContinue200Response) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_request.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_request.go new file mode 100644 index 0000000000..672169e029 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_request.go @@ -0,0 +1,146 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the ContinueRequest type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ContinueRequest{} + +// ContinueRequest Schema for a request to continue a paused transaction session. +type ContinueRequest struct { + // A unique identifier for the transaction session to be continued. + SessionId string `json:"sessionId"` + // A unique identifier for the transaction context. + ContextId string `json:"contextId"` +} + +// NewContinueRequest instantiates a new ContinueRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewContinueRequest(sessionId string, contextId string) *ContinueRequest { + this := ContinueRequest{} + this.SessionId = sessionId + this.ContextId = contextId + return &this +} + +// NewContinueRequestWithDefaults instantiates a new ContinueRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewContinueRequestWithDefaults() *ContinueRequest { + this := ContinueRequest{} + return &this +} + +// GetSessionId returns the SessionId field value +func (o *ContinueRequest) GetSessionId() string { + if o == nil { + var ret string + return ret + } + + return o.SessionId +} + +// GetSessionIdOk returns a tuple with the SessionId field value +// and a boolean to check if the value has been set. +func (o *ContinueRequest) GetSessionIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SessionId, true +} + +// SetSessionId sets field value +func (o *ContinueRequest) SetSessionId(v string) { + o.SessionId = v +} + +// GetContextId returns the ContextId field value +func (o *ContinueRequest) GetContextId() string { + if o == nil { + var ret string + return ret + } + + return o.ContextId +} + +// GetContextIdOk returns a tuple with the ContextId field value +// and a boolean to check if the value has been set. +func (o *ContinueRequest) GetContextIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ContextId, true +} + +// SetContextId sets field value +func (o *ContinueRequest) SetContextId(v string) { + o.ContextId = v +} + +func (o ContinueRequest) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ContinueRequest) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["sessionId"] = o.SessionId + toSerialize["contextId"] = o.ContextId + return toSerialize, nil +} + +type NullableContinueRequest struct { + value *ContinueRequest + isSet bool +} + +func (v NullableContinueRequest) Get() *ContinueRequest { + return v.value +} + +func (v *NullableContinueRequest) Set(val *ContinueRequest) { + v.value = val + v.isSet = true +} + +func (v NullableContinueRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableContinueRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableContinueRequest(val *ContinueRequest) *NullableContinueRequest { + return &NullableContinueRequest{value: val, isSet: true} +} + +func (v NullableContinueRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableContinueRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_response.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_response.go new file mode 100644 index 0000000000..74f3b5d9d5 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_continue_response.go @@ -0,0 +1,117 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the ContinueResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ContinueResponse{} + +// ContinueResponse Response schema for a continue request, returning the status of the SATP session. +type ContinueResponse struct { + StatusResponse Transact200ResponseStatusResponse `json:"statusResponse"` +} + +// NewContinueResponse instantiates a new ContinueResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewContinueResponse(statusResponse Transact200ResponseStatusResponse) *ContinueResponse { + this := ContinueResponse{} + this.StatusResponse = statusResponse + return &this +} + +// NewContinueResponseWithDefaults instantiates a new ContinueResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewContinueResponseWithDefaults() *ContinueResponse { + this := ContinueResponse{} + return &this +} + +// GetStatusResponse returns the StatusResponse field value +func (o *ContinueResponse) GetStatusResponse() Transact200ResponseStatusResponse { + if o == nil { + var ret Transact200ResponseStatusResponse + return ret + } + + return o.StatusResponse +} + +// GetStatusResponseOk returns a tuple with the StatusResponse field value +// and a boolean to check if the value has been set. +func (o *ContinueResponse) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool) { + if o == nil { + return nil, false + } + return &o.StatusResponse, true +} + +// SetStatusResponse sets field value +func (o *ContinueResponse) SetStatusResponse(v Transact200ResponseStatusResponse) { + o.StatusResponse = v +} + +func (o ContinueResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ContinueResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["statusResponse"] = o.StatusResponse + return toSerialize, nil +} + +type NullableContinueResponse struct { + value *ContinueResponse + isSet bool +} + +func (v NullableContinueResponse) Get() *ContinueResponse { + return v.value +} + +func (v *NullableContinueResponse) Set(val *ContinueResponse) { + v.value = val + v.isSet = true +} + +func (v NullableContinueResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableContinueResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableContinueResponse(val *ContinueResponse) *NullableContinueResponse { + return &NullableContinueResponse{value: val, isSet: true} +} + +func (v NullableContinueResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableContinueResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_chains_200_response_inner.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_chains_200_response_inner.go new file mode 100644 index 0000000000..4023043d78 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_chains_200_response_inner.go @@ -0,0 +1,202 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: v0.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetChains200ResponseInner type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetChains200ResponseInner{} + +// GetChains200ResponseInner struct for GetChains200ResponseInner +type GetChains200ResponseInner struct { + // A unique identifier for the blockchain network. + ChainId string `json:"chainId"` + // The name of the blockchain network. + ChainName string `json:"chainName"` + // The type of blockchain network (e.g., 'evm', 'fabric'). + ChainType string `json:"chainType"` + // The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). + NetworkName string `json:"networkName"` +} + +// NewGetChains200ResponseInner instantiates a new GetChains200ResponseInner object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetChains200ResponseInner(chainId string, chainName string, chainType string, networkName string) *GetChains200ResponseInner { + this := GetChains200ResponseInner{} + this.ChainId = chainId + this.ChainName = chainName + this.ChainType = chainType + this.NetworkName = networkName + return &this +} + +// NewGetChains200ResponseInnerWithDefaults instantiates a new GetChains200ResponseInner object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetChains200ResponseInnerWithDefaults() *GetChains200ResponseInner { + this := GetChains200ResponseInner{} + return &this +} + +// GetChainId returns the ChainId field value +func (o *GetChains200ResponseInner) GetChainId() string { + if o == nil { + var ret string + return ret + } + + return o.ChainId +} + +// GetChainIdOk returns a tuple with the ChainId field value +// and a boolean to check if the value has been set. +func (o *GetChains200ResponseInner) GetChainIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainId, true +} + +// SetChainId sets field value +func (o *GetChains200ResponseInner) SetChainId(v string) { + o.ChainId = v +} + +// GetChainName returns the ChainName field value +func (o *GetChains200ResponseInner) GetChainName() string { + if o == nil { + var ret string + return ret + } + + return o.ChainName +} + +// GetChainNameOk returns a tuple with the ChainName field value +// and a boolean to check if the value has been set. +func (o *GetChains200ResponseInner) GetChainNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainName, true +} + +// SetChainName sets field value +func (o *GetChains200ResponseInner) SetChainName(v string) { + o.ChainName = v +} + +// GetChainType returns the ChainType field value +func (o *GetChains200ResponseInner) GetChainType() string { + if o == nil { + var ret string + return ret + } + + return o.ChainType +} + +// GetChainTypeOk returns a tuple with the ChainType field value +// and a boolean to check if the value has been set. +func (o *GetChains200ResponseInner) GetChainTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainType, true +} + +// SetChainType sets field value +func (o *GetChains200ResponseInner) SetChainType(v string) { + o.ChainType = v +} + +// GetNetworkName returns the NetworkName field value +func (o *GetChains200ResponseInner) GetNetworkName() string { + if o == nil { + var ret string + return ret + } + + return o.NetworkName +} + +// GetNetworkNameOk returns a tuple with the NetworkName field value +// and a boolean to check if the value has been set. +func (o *GetChains200ResponseInner) GetNetworkNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetworkName, true +} + +// SetNetworkName sets field value +func (o *GetChains200ResponseInner) SetNetworkName(v string) { + o.NetworkName = v +} + +func (o GetChains200ResponseInner) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetChains200ResponseInner) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["chainId"] = o.ChainId + toSerialize["chainName"] = o.ChainName + toSerialize["chainType"] = o.ChainType + toSerialize["networkName"] = o.NetworkName + return toSerialize, nil +} + +type NullableGetChains200ResponseInner struct { + value *GetChains200ResponseInner + isSet bool +} + +func (v NullableGetChains200ResponseInner) Get() *GetChains200ResponseInner { + return v.value +} + +func (v *NullableGetChains200ResponseInner) Set(val *GetChains200ResponseInner) { + v.value = val + v.isSet = true +} + +func (v NullableGetChains200ResponseInner) IsSet() bool { + return v.isSet +} + +func (v *NullableGetChains200ResponseInner) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetChains200ResponseInner(val *GetChains200ResponseInner) *NullableGetChains200ResponseInner { + return &NullableGetChains200ResponseInner{value: val, isSet: true} +} + +func (v NullableGetChains200ResponseInner) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetChains200ResponseInner) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_health_check_200_response.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_health_check_200_response.go new file mode 100644 index 0000000000..b25ba1ae46 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_health_check_200_response.go @@ -0,0 +1,126 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetHealthCheck200Response type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetHealthCheck200Response{} + +// GetHealthCheck200Response struct for GetHealthCheck200Response +type GetHealthCheck200Response struct { + Status *string `json:"status,omitempty"` +} + +// NewGetHealthCheck200Response instantiates a new GetHealthCheck200Response object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetHealthCheck200Response() *GetHealthCheck200Response { + this := GetHealthCheck200Response{} + return &this +} + +// NewGetHealthCheck200ResponseWithDefaults instantiates a new GetHealthCheck200Response object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetHealthCheck200ResponseWithDefaults() *GetHealthCheck200Response { + this := GetHealthCheck200Response{} + return &this +} + +// GetStatus returns the Status field value if set, zero value otherwise. +func (o *GetHealthCheck200Response) GetStatus() string { + if o == nil || IsNil(o.Status) { + var ret string + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetHealthCheck200Response) GetStatusOk() (*string, bool) { + if o == nil || IsNil(o.Status) { + return nil, false + } + return o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *GetHealthCheck200Response) HasStatus() bool { + if o != nil && !IsNil(o.Status) { + return true + } + + return false +} + +// SetStatus gets a reference to the given string and assigns it to the Status field. +func (o *GetHealthCheck200Response) SetStatus(v string) { + o.Status = &v +} + +func (o GetHealthCheck200Response) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetHealthCheck200Response) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Status) { + toSerialize["status"] = o.Status + } + return toSerialize, nil +} + +type NullableGetHealthCheck200Response struct { + value *GetHealthCheck200Response + isSet bool +} + +func (v NullableGetHealthCheck200Response) Get() *GetHealthCheck200Response { + return v.value +} + +func (v *NullableGetHealthCheck200Response) Set(val *GetHealthCheck200Response) { + v.value = val + v.isSet = true +} + +func (v NullableGetHealthCheck200Response) IsSet() bool { + return v.isSet +} + +func (v *NullableGetHealthCheck200Response) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetHealthCheck200Response(val *GetHealthCheck200Response) *NullableGetHealthCheck200Response { + return &NullableGetHealthCheck200Response{value: val, isSet: true} +} + +func (v NullableGetHealthCheck200Response) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetHealthCheck200Response) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_integrations_200_response_inner.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_integrations_200_response_inner.go new file mode 100644 index 0000000000..e5749a63e6 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_integrations_200_response_inner.go @@ -0,0 +1,202 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetIntegrations200ResponseInner type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetIntegrations200ResponseInner{} + +// GetIntegrations200ResponseInner struct for GetIntegrations200ResponseInner +type GetIntegrations200ResponseInner struct { + // A unique identifier for the blockchain network. + ChainId string `json:"chainId"` + // The name of the blockchain network. + ChainName string `json:"chainName"` + // The type of blockchain network (e.g., 'evm', 'fabric'). + ChainType string `json:"chainType"` + // The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). + NetworkName string `json:"networkName"` +} + +// NewGetIntegrations200ResponseInner instantiates a new GetIntegrations200ResponseInner object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetIntegrations200ResponseInner(chainId string, chainName string, chainType string, networkName string) *GetIntegrations200ResponseInner { + this := GetIntegrations200ResponseInner{} + this.ChainId = chainId + this.ChainName = chainName + this.ChainType = chainType + this.NetworkName = networkName + return &this +} + +// NewGetIntegrations200ResponseInnerWithDefaults instantiates a new GetIntegrations200ResponseInner object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetIntegrations200ResponseInnerWithDefaults() *GetIntegrations200ResponseInner { + this := GetIntegrations200ResponseInner{} + return &this +} + +// GetChainId returns the ChainId field value +func (o *GetIntegrations200ResponseInner) GetChainId() string { + if o == nil { + var ret string + return ret + } + + return o.ChainId +} + +// GetChainIdOk returns a tuple with the ChainId field value +// and a boolean to check if the value has been set. +func (o *GetIntegrations200ResponseInner) GetChainIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainId, true +} + +// SetChainId sets field value +func (o *GetIntegrations200ResponseInner) SetChainId(v string) { + o.ChainId = v +} + +// GetChainName returns the ChainName field value +func (o *GetIntegrations200ResponseInner) GetChainName() string { + if o == nil { + var ret string + return ret + } + + return o.ChainName +} + +// GetChainNameOk returns a tuple with the ChainName field value +// and a boolean to check if the value has been set. +func (o *GetIntegrations200ResponseInner) GetChainNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainName, true +} + +// SetChainName sets field value +func (o *GetIntegrations200ResponseInner) SetChainName(v string) { + o.ChainName = v +} + +// GetChainType returns the ChainType field value +func (o *GetIntegrations200ResponseInner) GetChainType() string { + if o == nil { + var ret string + return ret + } + + return o.ChainType +} + +// GetChainTypeOk returns a tuple with the ChainType field value +// and a boolean to check if the value has been set. +func (o *GetIntegrations200ResponseInner) GetChainTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainType, true +} + +// SetChainType sets field value +func (o *GetIntegrations200ResponseInner) SetChainType(v string) { + o.ChainType = v +} + +// GetNetworkName returns the NetworkName field value +func (o *GetIntegrations200ResponseInner) GetNetworkName() string { + if o == nil { + var ret string + return ret + } + + return o.NetworkName +} + +// GetNetworkNameOk returns a tuple with the NetworkName field value +// and a boolean to check if the value has been set. +func (o *GetIntegrations200ResponseInner) GetNetworkNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetworkName, true +} + +// SetNetworkName sets field value +func (o *GetIntegrations200ResponseInner) SetNetworkName(v string) { + o.NetworkName = v +} + +func (o GetIntegrations200ResponseInner) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetIntegrations200ResponseInner) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["chainId"] = o.ChainId + toSerialize["chainName"] = o.ChainName + toSerialize["chainType"] = o.ChainType + toSerialize["networkName"] = o.NetworkName + return toSerialize, nil +} + +type NullableGetIntegrations200ResponseInner struct { + value *GetIntegrations200ResponseInner + isSet bool +} + +func (v NullableGetIntegrations200ResponseInner) Get() *GetIntegrations200ResponseInner { + return v.value +} + +func (v *NullableGetIntegrations200ResponseInner) Set(val *GetIntegrations200ResponseInner) { + v.value = val + v.isSet = true +} + +func (v NullableGetIntegrations200ResponseInner) IsSet() bool { + return v.isSet +} + +func (v *NullableGetIntegrations200ResponseInner) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetIntegrations200ResponseInner(val *GetIntegrations200ResponseInner) *NullableGetIntegrations200ResponseInner { + return &NullableGetIntegrations200ResponseInner{value: val, isSet: true} +} + +func (v NullableGetIntegrations200ResponseInner) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetIntegrations200ResponseInner) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token.go new file mode 100644 index 0000000000..6537a62963 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token.go @@ -0,0 +1,414 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetRoutes200ResponseRoutesInnerFromToken type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetRoutes200ResponseRoutesInnerFromToken{} + +// GetRoutes200ResponseRoutesInnerFromToken Metadata detailing a supported token +type GetRoutes200ResponseRoutesInnerFromToken struct { + // The network of the DLT being interacted with. TODO: implement network identification draft + ChainID string `json:"chainID"` + // Supported DLT protocols. + ChainType string `json:"chainType"` + // A blockchain address. + Address string `json:"address"` + // The name of the token. + Name *string `json:"name,omitempty"` + // The symbol of the token. + Symbol string `json:"symbol"` + // How many decimals the token supports. + Decimals int32 `json:"decimals"` + // The logo of a token, chain, dex etc. + LogoURI *string `json:"logoURI,omitempty"` + // List of tags identifiers providing additional context or categorization. + Tags []string `json:"tags,omitempty"` + // The current price of the token in USD. + PriceUSD *string `json:"priceUSD,omitempty"` + Extensions *GetRoutes200ResponseRoutesInnerFromTokenExtensions `json:"extensions,omitempty"` +} + +// NewGetRoutes200ResponseRoutesInnerFromToken instantiates a new GetRoutes200ResponseRoutesInnerFromToken object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetRoutes200ResponseRoutesInnerFromToken(chainID string, chainType string, address string, symbol string, decimals int32) *GetRoutes200ResponseRoutesInnerFromToken { + this := GetRoutes200ResponseRoutesInnerFromToken{} + this.ChainID = chainID + this.ChainType = chainType + this.Address = address + this.Symbol = symbol + this.Decimals = decimals + return &this +} + +// NewGetRoutes200ResponseRoutesInnerFromTokenWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerFromToken object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetRoutes200ResponseRoutesInnerFromTokenWithDefaults() *GetRoutes200ResponseRoutesInnerFromToken { + this := GetRoutes200ResponseRoutesInnerFromToken{} + return &this +} + +// GetChainID returns the ChainID field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainID() string { + if o == nil { + var ret string + return ret + } + + return o.ChainID +} + +// GetChainIDOk returns a tuple with the ChainID field value +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainIDOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainID, true +} + +// SetChainID sets field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetChainID(v string) { + o.ChainID = v +} + +// GetChainType returns the ChainType field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainType() string { + if o == nil { + var ret string + return ret + } + + return o.ChainType +} + +// GetChainTypeOk returns a tuple with the ChainType field value +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetChainTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChainType, true +} + +// SetChainType sets field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetChainType(v string) { + o.ChainType = v +} + +// GetAddress returns the Address field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetAddress() string { + if o == nil { + var ret string + return ret + } + + return o.Address +} + +// GetAddressOk returns a tuple with the Address field value +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetAddressOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Address, true +} + +// SetAddress sets field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetAddress(v string) { + o.Address = v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetName(v string) { + o.Name = &v +} + +// GetSymbol returns the Symbol field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetSymbol() string { + if o == nil { + var ret string + return ret + } + + return o.Symbol +} + +// GetSymbolOk returns a tuple with the Symbol field value +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetSymbolOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Symbol, true +} + +// SetSymbol sets field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetSymbol(v string) { + o.Symbol = v +} + +// GetDecimals returns the Decimals field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetDecimals() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Decimals +} + +// GetDecimalsOk returns a tuple with the Decimals field value +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetDecimalsOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Decimals, true +} + +// SetDecimals sets field value +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetDecimals(v int32) { + o.Decimals = v +} + +// GetLogoURI returns the LogoURI field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetLogoURI() string { + if o == nil || IsNil(o.LogoURI) { + var ret string + return ret + } + return *o.LogoURI +} + +// GetLogoURIOk returns a tuple with the LogoURI field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetLogoURIOk() (*string, bool) { + if o == nil || IsNil(o.LogoURI) { + return nil, false + } + return o.LogoURI, true +} + +// HasLogoURI returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) HasLogoURI() bool { + if o != nil && !IsNil(o.LogoURI) { + return true + } + + return false +} + +// SetLogoURI gets a reference to the given string and assigns it to the LogoURI field. +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetLogoURI(v string) { + o.LogoURI = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetTags() []string { + if o == nil || IsNil(o.Tags) { + var ret []string + return ret + } + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetTagsOk() ([]string, bool) { + if o == nil || IsNil(o.Tags) { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) HasTags() bool { + if o != nil && !IsNil(o.Tags) { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetTags(v []string) { + o.Tags = v +} + +// GetPriceUSD returns the PriceUSD field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetPriceUSD() string { + if o == nil || IsNil(o.PriceUSD) { + var ret string + return ret + } + return *o.PriceUSD +} + +// GetPriceUSDOk returns a tuple with the PriceUSD field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetPriceUSDOk() (*string, bool) { + if o == nil || IsNil(o.PriceUSD) { + return nil, false + } + return o.PriceUSD, true +} + +// HasPriceUSD returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) HasPriceUSD() bool { + if o != nil && !IsNil(o.PriceUSD) { + return true + } + + return false +} + +// SetPriceUSD gets a reference to the given string and assigns it to the PriceUSD field. +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetPriceUSD(v string) { + o.PriceUSD = &v +} + +// GetExtensions returns the Extensions field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetExtensions() GetRoutes200ResponseRoutesInnerFromTokenExtensions { + if o == nil || IsNil(o.Extensions) { + var ret GetRoutes200ResponseRoutesInnerFromTokenExtensions + return ret + } + return *o.Extensions +} + +// GetExtensionsOk returns a tuple with the Extensions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) GetExtensionsOk() (*GetRoutes200ResponseRoutesInnerFromTokenExtensions, bool) { + if o == nil || IsNil(o.Extensions) { + return nil, false + } + return o.Extensions, true +} + +// HasExtensions returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromToken) HasExtensions() bool { + if o != nil && !IsNil(o.Extensions) { + return true + } + + return false +} + +// SetExtensions gets a reference to the given GetRoutes200ResponseRoutesInnerFromTokenExtensions and assigns it to the Extensions field. +func (o *GetRoutes200ResponseRoutesInnerFromToken) SetExtensions(v GetRoutes200ResponseRoutesInnerFromTokenExtensions) { + o.Extensions = &v +} + +func (o GetRoutes200ResponseRoutesInnerFromToken) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetRoutes200ResponseRoutesInnerFromToken) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["chainID"] = o.ChainID + toSerialize["chainType"] = o.ChainType + toSerialize["address"] = o.Address + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + toSerialize["symbol"] = o.Symbol + toSerialize["decimals"] = o.Decimals + if !IsNil(o.LogoURI) { + toSerialize["logoURI"] = o.LogoURI + } + if !IsNil(o.Tags) { + toSerialize["tags"] = o.Tags + } + if !IsNil(o.PriceUSD) { + toSerialize["priceUSD"] = o.PriceUSD + } + if !IsNil(o.Extensions) { + toSerialize["extensions"] = o.Extensions + } + return toSerialize, nil +} + +type NullableGetRoutes200ResponseRoutesInnerFromToken struct { + value *GetRoutes200ResponseRoutesInnerFromToken + isSet bool +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromToken) Get() *GetRoutes200ResponseRoutesInnerFromToken { + return v.value +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromToken) Set(val *GetRoutes200ResponseRoutesInnerFromToken) { + v.value = val + v.isSet = true +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromToken) IsSet() bool { + return v.isSet +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromToken) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetRoutes200ResponseRoutesInnerFromToken(val *GetRoutes200ResponseRoutesInnerFromToken) *NullableGetRoutes200ResponseRoutesInnerFromToken { + return &NullableGetRoutes200ResponseRoutesInnerFromToken{value: val, isSet: true} +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromToken) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromToken) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions.go new file mode 100644 index 0000000000..a0099c3234 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions.go @@ -0,0 +1,163 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetRoutes200ResponseRoutesInnerFromTokenExtensions type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetRoutes200ResponseRoutesInnerFromTokenExtensions{} + +// GetRoutes200ResponseRoutesInnerFromTokenExtensions struct for GetRoutes200ResponseRoutesInnerFromTokenExtensions +type GetRoutes200ResponseRoutesInnerFromTokenExtensions struct { + BridgeInfo *map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue `json:"bridgeInfo,omitempty"` + // Indicates whether the token is verified. + Verified *bool `json:"verified,omitempty"` +} + +// NewGetRoutes200ResponseRoutesInnerFromTokenExtensions instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetRoutes200ResponseRoutesInnerFromTokenExtensions() *GetRoutes200ResponseRoutesInnerFromTokenExtensions { + this := GetRoutes200ResponseRoutesInnerFromTokenExtensions{} + return &this +} + +// NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsWithDefaults() *GetRoutes200ResponseRoutesInnerFromTokenExtensions { + this := GetRoutes200ResponseRoutesInnerFromTokenExtensions{} + return &this +} + +// GetBridgeInfo returns the BridgeInfo field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetBridgeInfo() map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + if o == nil || IsNil(o.BridgeInfo) { + var ret map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + return ret + } + return *o.BridgeInfo +} + +// GetBridgeInfoOk returns a tuple with the BridgeInfo field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetBridgeInfoOk() (*map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue, bool) { + if o == nil || IsNil(o.BridgeInfo) { + return nil, false + } + return o.BridgeInfo, true +} + +// HasBridgeInfo returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) HasBridgeInfo() bool { + if o != nil && !IsNil(o.BridgeInfo) { + return true + } + + return false +} + +// SetBridgeInfo gets a reference to the given map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue and assigns it to the BridgeInfo field. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) SetBridgeInfo(v map[string]GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) { + o.BridgeInfo = &v +} + +// GetVerified returns the Verified field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetVerified() bool { + if o == nil || IsNil(o.Verified) { + var ret bool + return ret + } + return *o.Verified +} + +// GetVerifiedOk returns a tuple with the Verified field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) GetVerifiedOk() (*bool, bool) { + if o == nil || IsNil(o.Verified) { + return nil, false + } + return o.Verified, true +} + +// HasVerified returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) HasVerified() bool { + if o != nil && !IsNil(o.Verified) { + return true + } + + return false +} + +// SetVerified gets a reference to the given bool and assigns it to the Verified field. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensions) SetVerified(v bool) { + o.Verified = &v +} + +func (o GetRoutes200ResponseRoutesInnerFromTokenExtensions) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetRoutes200ResponseRoutesInnerFromTokenExtensions) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.BridgeInfo) { + toSerialize["bridgeInfo"] = o.BridgeInfo + } + if !IsNil(o.Verified) { + toSerialize["verified"] = o.Verified + } + return toSerialize, nil +} + +type NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions struct { + value *GetRoutes200ResponseRoutesInnerFromTokenExtensions + isSet bool +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions) Get() *GetRoutes200ResponseRoutesInnerFromTokenExtensions { + return v.value +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions) Set(val *GetRoutes200ResponseRoutesInnerFromTokenExtensions) { + v.value = val + v.isSet = true +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions) IsSet() bool { + return v.isSet +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetRoutes200ResponseRoutesInnerFromTokenExtensions(val *GetRoutes200ResponseRoutesInnerFromTokenExtensions) *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions { + return &NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions{value: val, isSet: true} +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions_bridge_info_value.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions_bridge_info_value.go new file mode 100644 index 0000000000..d6337f0003 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_from_token_extensions_bridge_info_value.go @@ -0,0 +1,127 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue{} + +// GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue Information about the bridge used for the token transfer. +type GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue struct { + // The address of the token being transferred. + TokenAddress *string `json:"tokenAddress,omitempty"` +} + +// NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue() *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + this := GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue{} + return &this +} + +// NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValueWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValueWithDefaults() *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + this := GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue{} + return &this +} + +// GetTokenAddress returns the TokenAddress field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) GetTokenAddress() string { + if o == nil || IsNil(o.TokenAddress) { + var ret string + return ret + } + return *o.TokenAddress +} + +// GetTokenAddressOk returns a tuple with the TokenAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) GetTokenAddressOk() (*string, bool) { + if o == nil || IsNil(o.TokenAddress) { + return nil, false + } + return o.TokenAddress, true +} + +// HasTokenAddress returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) HasTokenAddress() bool { + if o != nil && !IsNil(o.TokenAddress) { + return true + } + + return false +} + +// SetTokenAddress gets a reference to the given string and assigns it to the TokenAddress field. +func (o *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) SetTokenAddress(v string) { + o.TokenAddress = &v +} + +func (o GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.TokenAddress) { + toSerialize["tokenAddress"] = o.TokenAddress + } + return toSerialize, nil +} + +type NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue struct { + value *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + isSet bool +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) Get() *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + return v.value +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) Set(val *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) { + v.value = val + v.isSet = true +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) IsSet() bool { + return v.isSet +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue(val *GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + return &NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue{value: val, isSet: true} +} + +func (v NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_steps_inner_action.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_steps_inner_action.go new file mode 100644 index 0000000000..f1148a04fd --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_get_routes_200_response_routes_inner_steps_inner_action.go @@ -0,0 +1,310 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the GetRoutes200ResponseRoutesInnerStepsInnerAction type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetRoutes200ResponseRoutesInnerStepsInnerAction{} + +// GetRoutes200ResponseRoutesInnerStepsInnerAction struct for GetRoutes200ResponseRoutesInnerStepsInnerAction +type GetRoutes200ResponseRoutesInnerStepsInnerAction struct { + FromToken *GetRoutes200ResponseRoutesInnerFromToken `json:"fromToken,omitempty"` + // The amount of 'fromToken' to be transferred, specified as a string to maintain precision. + FromAmount *string `json:"fromAmount,omitempty"` + ToToken *GetRoutes200ResponseRoutesInnerFromToken `json:"toToken,omitempty"` + // The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + Slippage *float32 `json:"slippage,omitempty"` + // A blockchain address. + FromAddress *string `json:"fromAddress,omitempty"` + // A blockchain address. + ToAddress *string `json:"toAddress,omitempty"` +} + +// NewGetRoutes200ResponseRoutesInnerStepsInnerAction instantiates a new GetRoutes200ResponseRoutesInnerStepsInnerAction object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetRoutes200ResponseRoutesInnerStepsInnerAction() *GetRoutes200ResponseRoutesInnerStepsInnerAction { + this := GetRoutes200ResponseRoutesInnerStepsInnerAction{} + return &this +} + +// NewGetRoutes200ResponseRoutesInnerStepsInnerActionWithDefaults instantiates a new GetRoutes200ResponseRoutesInnerStepsInnerAction object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetRoutes200ResponseRoutesInnerStepsInnerActionWithDefaults() *GetRoutes200ResponseRoutesInnerStepsInnerAction { + this := GetRoutes200ResponseRoutesInnerStepsInnerAction{} + return &this +} + +// GetFromToken returns the FromToken field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetFromToken() GetRoutes200ResponseRoutesInnerFromToken { + if o == nil || IsNil(o.FromToken) { + var ret GetRoutes200ResponseRoutesInnerFromToken + return ret + } + return *o.FromToken +} + +// GetFromTokenOk returns a tuple with the FromToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetFromTokenOk() (*GetRoutes200ResponseRoutesInnerFromToken, bool) { + if o == nil || IsNil(o.FromToken) { + return nil, false + } + return o.FromToken, true +} + +// HasFromToken returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) HasFromToken() bool { + if o != nil && !IsNil(o.FromToken) { + return true + } + + return false +} + +// SetFromToken gets a reference to the given GetRoutes200ResponseRoutesInnerFromToken and assigns it to the FromToken field. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) SetFromToken(v GetRoutes200ResponseRoutesInnerFromToken) { + o.FromToken = &v +} + +// GetFromAmount returns the FromAmount field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetFromAmount() string { + if o == nil || IsNil(o.FromAmount) { + var ret string + return ret + } + return *o.FromAmount +} + +// GetFromAmountOk returns a tuple with the FromAmount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetFromAmountOk() (*string, bool) { + if o == nil || IsNil(o.FromAmount) { + return nil, false + } + return o.FromAmount, true +} + +// HasFromAmount returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) HasFromAmount() bool { + if o != nil && !IsNil(o.FromAmount) { + return true + } + + return false +} + +// SetFromAmount gets a reference to the given string and assigns it to the FromAmount field. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) SetFromAmount(v string) { + o.FromAmount = &v +} + +// GetToToken returns the ToToken field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetToToken() GetRoutes200ResponseRoutesInnerFromToken { + if o == nil || IsNil(o.ToToken) { + var ret GetRoutes200ResponseRoutesInnerFromToken + return ret + } + return *o.ToToken +} + +// GetToTokenOk returns a tuple with the ToToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetToTokenOk() (*GetRoutes200ResponseRoutesInnerFromToken, bool) { + if o == nil || IsNil(o.ToToken) { + return nil, false + } + return o.ToToken, true +} + +// HasToToken returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) HasToToken() bool { + if o != nil && !IsNil(o.ToToken) { + return true + } + + return false +} + +// SetToToken gets a reference to the given GetRoutes200ResponseRoutesInnerFromToken and assigns it to the ToToken field. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) SetToToken(v GetRoutes200ResponseRoutesInnerFromToken) { + o.ToToken = &v +} + +// GetSlippage returns the Slippage field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetSlippage() float32 { + if o == nil || IsNil(o.Slippage) { + var ret float32 + return ret + } + return *o.Slippage +} + +// GetSlippageOk returns a tuple with the Slippage field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetSlippageOk() (*float32, bool) { + if o == nil || IsNil(o.Slippage) { + return nil, false + } + return o.Slippage, true +} + +// HasSlippage returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) HasSlippage() bool { + if o != nil && !IsNil(o.Slippage) { + return true + } + + return false +} + +// SetSlippage gets a reference to the given float32 and assigns it to the Slippage field. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) SetSlippage(v float32) { + o.Slippage = &v +} + +// GetFromAddress returns the FromAddress field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetFromAddress() string { + if o == nil || IsNil(o.FromAddress) { + var ret string + return ret + } + return *o.FromAddress +} + +// GetFromAddressOk returns a tuple with the FromAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetFromAddressOk() (*string, bool) { + if o == nil || IsNil(o.FromAddress) { + return nil, false + } + return o.FromAddress, true +} + +// HasFromAddress returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) HasFromAddress() bool { + if o != nil && !IsNil(o.FromAddress) { + return true + } + + return false +} + +// SetFromAddress gets a reference to the given string and assigns it to the FromAddress field. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) SetFromAddress(v string) { + o.FromAddress = &v +} + +// GetToAddress returns the ToAddress field value if set, zero value otherwise. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetToAddress() string { + if o == nil || IsNil(o.ToAddress) { + var ret string + return ret + } + return *o.ToAddress +} + +// GetToAddressOk returns a tuple with the ToAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) GetToAddressOk() (*string, bool) { + if o == nil || IsNil(o.ToAddress) { + return nil, false + } + return o.ToAddress, true +} + +// HasToAddress returns a boolean if a field has been set. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) HasToAddress() bool { + if o != nil && !IsNil(o.ToAddress) { + return true + } + + return false +} + +// SetToAddress gets a reference to the given string and assigns it to the ToAddress field. +func (o *GetRoutes200ResponseRoutesInnerStepsInnerAction) SetToAddress(v string) { + o.ToAddress = &v +} + +func (o GetRoutes200ResponseRoutesInnerStepsInnerAction) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetRoutes200ResponseRoutesInnerStepsInnerAction) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.FromToken) { + toSerialize["fromToken"] = o.FromToken + } + if !IsNil(o.FromAmount) { + toSerialize["fromAmount"] = o.FromAmount + } + if !IsNil(o.ToToken) { + toSerialize["toToken"] = o.ToToken + } + if !IsNil(o.Slippage) { + toSerialize["slippage"] = o.Slippage + } + if !IsNil(o.FromAddress) { + toSerialize["fromAddress"] = o.FromAddress + } + if !IsNil(o.ToAddress) { + toSerialize["toAddress"] = o.ToAddress + } + return toSerialize, nil +} + +type NullableGetRoutes200ResponseRoutesInnerStepsInnerAction struct { + value *GetRoutes200ResponseRoutesInnerStepsInnerAction + isSet bool +} + +func (v NullableGetRoutes200ResponseRoutesInnerStepsInnerAction) Get() *GetRoutes200ResponseRoutesInnerStepsInnerAction { + return v.value +} + +func (v *NullableGetRoutes200ResponseRoutesInnerStepsInnerAction) Set(val *GetRoutes200ResponseRoutesInnerStepsInnerAction) { + v.value = val + v.isSet = true +} + +func (v NullableGetRoutes200ResponseRoutesInnerStepsInnerAction) IsSet() bool { + return v.isSet +} + +func (v *NullableGetRoutes200ResponseRoutesInnerStepsInnerAction) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetRoutes200ResponseRoutesInnerStepsInnerAction(val *GetRoutes200ResponseRoutesInnerStepsInnerAction) *NullableGetRoutes200ResponseRoutesInnerStepsInnerAction { + return &NullableGetRoutes200ResponseRoutesInnerStepsInnerAction{value: val, isSet: true} +} + +func (v NullableGetRoutes200ResponseRoutesInnerStepsInnerAction) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetRoutes200ResponseRoutesInnerStepsInnerAction) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_health_check_response.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_health_check_response.go new file mode 100644 index 0000000000..439a89681c --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_health_check_response.go @@ -0,0 +1,126 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the HealthCheckResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &HealthCheckResponse{} + +// HealthCheckResponse struct for HealthCheckResponse +type HealthCheckResponse struct { + Status *string `json:"status,omitempty"` +} + +// NewHealthCheckResponse instantiates a new HealthCheckResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewHealthCheckResponse() *HealthCheckResponse { + this := HealthCheckResponse{} + return &this +} + +// NewHealthCheckResponseWithDefaults instantiates a new HealthCheckResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewHealthCheckResponseWithDefaults() *HealthCheckResponse { + this := HealthCheckResponse{} + return &this +} + +// GetStatus returns the Status field value if set, zero value otherwise. +func (o *HealthCheckResponse) GetStatus() string { + if o == nil || IsNil(o.Status) { + var ret string + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *HealthCheckResponse) GetStatusOk() (*string, bool) { + if o == nil || IsNil(o.Status) { + return nil, false + } + return o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *HealthCheckResponse) HasStatus() bool { + if o != nil && !IsNil(o.Status) { + return true + } + + return false +} + +// SetStatus gets a reference to the given string and assigns it to the Status field. +func (o *HealthCheckResponse) SetStatus(v string) { + o.Status = &v +} + +func (o HealthCheckResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o HealthCheckResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Status) { + toSerialize["status"] = o.Status + } + return toSerialize, nil +} + +type NullableHealthCheckResponse struct { + value *HealthCheckResponse + isSet bool +} + +func (v NullableHealthCheckResponse) Get() *HealthCheckResponse { + return v.value +} + +func (v *NullableHealthCheckResponse) Set(val *HealthCheckResponse) { + v.value = val + v.isSet = true +} + +func (v NullableHealthCheckResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableHealthCheckResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableHealthCheckResponse(val *HealthCheckResponse) *NullableHealthCheckResponse { + return &NullableHealthCheckResponse{value: val, isSet: true} +} + +func (v NullableHealthCheckResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableHealthCheckResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_200_response.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_200_response.go new file mode 100644 index 0000000000..f8caa99058 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_200_response.go @@ -0,0 +1,117 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the Pause200Response type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Pause200Response{} + +// Pause200Response Response for a pause transaction request. Returns the current status of the SATP session post-pause action. +type Pause200Response struct { + StatusResponse Transact200ResponseStatusResponse `json:"statusResponse"` +} + +// NewPause200Response instantiates a new Pause200Response object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPause200Response(statusResponse Transact200ResponseStatusResponse) *Pause200Response { + this := Pause200Response{} + this.StatusResponse = statusResponse + return &this +} + +// NewPause200ResponseWithDefaults instantiates a new Pause200Response object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPause200ResponseWithDefaults() *Pause200Response { + this := Pause200Response{} + return &this +} + +// GetStatusResponse returns the StatusResponse field value +func (o *Pause200Response) GetStatusResponse() Transact200ResponseStatusResponse { + if o == nil { + var ret Transact200ResponseStatusResponse + return ret + } + + return o.StatusResponse +} + +// GetStatusResponseOk returns a tuple with the StatusResponse field value +// and a boolean to check if the value has been set. +func (o *Pause200Response) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool) { + if o == nil { + return nil, false + } + return &o.StatusResponse, true +} + +// SetStatusResponse sets field value +func (o *Pause200Response) SetStatusResponse(v Transact200ResponseStatusResponse) { + o.StatusResponse = v +} + +func (o Pause200Response) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Pause200Response) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["statusResponse"] = o.StatusResponse + return toSerialize, nil +} + +type NullablePause200Response struct { + value *Pause200Response + isSet bool +} + +func (v NullablePause200Response) Get() *Pause200Response { + return v.value +} + +func (v *NullablePause200Response) Set(val *Pause200Response) { + v.value = val + v.isSet = true +} + +func (v NullablePause200Response) IsSet() bool { + return v.isSet +} + +func (v *NullablePause200Response) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePause200Response(val *Pause200Response) *NullablePause200Response { + return &NullablePause200Response{value: val, isSet: true} +} + +func (v NullablePause200Response) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePause200Response) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_request.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_request.go new file mode 100644 index 0000000000..ca3360617b --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_request.go @@ -0,0 +1,162 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the PauseRequest type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &PauseRequest{} + +// PauseRequest Request to temporarily pause an ongoing transaction session, identified by the session and context IDs. +type PauseRequest struct { + SessionId *string `json:"sessionId,omitempty"` + ContextId *string `json:"contextId,omitempty"` +} + +// NewPauseRequest instantiates a new PauseRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPauseRequest() *PauseRequest { + this := PauseRequest{} + return &this +} + +// NewPauseRequestWithDefaults instantiates a new PauseRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPauseRequestWithDefaults() *PauseRequest { + this := PauseRequest{} + return &this +} + +// GetSessionId returns the SessionId field value if set, zero value otherwise. +func (o *PauseRequest) GetSessionId() string { + if o == nil || IsNil(o.SessionId) { + var ret string + return ret + } + return *o.SessionId +} + +// GetSessionIdOk returns a tuple with the SessionId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PauseRequest) GetSessionIdOk() (*string, bool) { + if o == nil || IsNil(o.SessionId) { + return nil, false + } + return o.SessionId, true +} + +// HasSessionId returns a boolean if a field has been set. +func (o *PauseRequest) HasSessionId() bool { + if o != nil && !IsNil(o.SessionId) { + return true + } + + return false +} + +// SetSessionId gets a reference to the given string and assigns it to the SessionId field. +func (o *PauseRequest) SetSessionId(v string) { + o.SessionId = &v +} + +// GetContextId returns the ContextId field value if set, zero value otherwise. +func (o *PauseRequest) GetContextId() string { + if o == nil || IsNil(o.ContextId) { + var ret string + return ret + } + return *o.ContextId +} + +// GetContextIdOk returns a tuple with the ContextId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PauseRequest) GetContextIdOk() (*string, bool) { + if o == nil || IsNil(o.ContextId) { + return nil, false + } + return o.ContextId, true +} + +// HasContextId returns a boolean if a field has been set. +func (o *PauseRequest) HasContextId() bool { + if o != nil && !IsNil(o.ContextId) { + return true + } + + return false +} + +// SetContextId gets a reference to the given string and assigns it to the ContextId field. +func (o *PauseRequest) SetContextId(v string) { + o.ContextId = &v +} + +func (o PauseRequest) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o PauseRequest) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.SessionId) { + toSerialize["sessionId"] = o.SessionId + } + if !IsNil(o.ContextId) { + toSerialize["contextId"] = o.ContextId + } + return toSerialize, nil +} + +type NullablePauseRequest struct { + value *PauseRequest + isSet bool +} + +func (v NullablePauseRequest) Get() *PauseRequest { + return v.value +} + +func (v *NullablePauseRequest) Set(val *PauseRequest) { + v.value = val + v.isSet = true +} + +func (v NullablePauseRequest) IsSet() bool { + return v.isSet +} + +func (v *NullablePauseRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePauseRequest(val *PauseRequest) *NullablePauseRequest { + return &NullablePauseRequest{value: val, isSet: true} +} + +func (v NullablePauseRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePauseRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_response.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_response.go new file mode 100644 index 0000000000..7735d228c9 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_pause_response.go @@ -0,0 +1,117 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the PauseResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &PauseResponse{} + +// PauseResponse Response for a pause transaction request. Returns the current status of the SATP session post-pause action. +type PauseResponse struct { + StatusResponse Transact200ResponseStatusResponse `json:"statusResponse"` +} + +// NewPauseResponse instantiates a new PauseResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPauseResponse(statusResponse Transact200ResponseStatusResponse) *PauseResponse { + this := PauseResponse{} + this.StatusResponse = statusResponse + return &this +} + +// NewPauseResponseWithDefaults instantiates a new PauseResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPauseResponseWithDefaults() *PauseResponse { + this := PauseResponse{} + return &this +} + +// GetStatusResponse returns the StatusResponse field value +func (o *PauseResponse) GetStatusResponse() Transact200ResponseStatusResponse { + if o == nil { + var ret Transact200ResponseStatusResponse + return ret + } + + return o.StatusResponse +} + +// GetStatusResponseOk returns a tuple with the StatusResponse field value +// and a boolean to check if the value has been set. +func (o *PauseResponse) GetStatusResponseOk() (*Transact200ResponseStatusResponse, bool) { + if o == nil { + return nil, false + } + return &o.StatusResponse, true +} + +// SetStatusResponse sets field value +func (o *PauseResponse) SetStatusResponse(v Transact200ResponseStatusResponse) { + o.StatusResponse = v +} + +func (o PauseResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o PauseResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["statusResponse"] = o.StatusResponse + return toSerialize, nil +} + +type NullablePauseResponse struct { + value *PauseResponse + isSet bool +} + +func (v NullablePauseResponse) Get() *PauseResponse { + return v.value +} + +func (v *NullablePauseResponse) Set(val *PauseResponse) { + v.value = val + v.isSet = true +} + +func (v NullablePauseResponse) IsSet() bool { + return v.isSet +} + +func (v *NullablePauseResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePauseResponse(val *PauseResponse) *NullablePauseResponse { + return &NullablePauseResponse{value: val, isSet: true} +} + +func (v NullablePauseResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePauseResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_destination_chain.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_destination_chain.go new file mode 100644 index 0000000000..44c5b50c76 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_destination_chain.go @@ -0,0 +1,164 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the Transact200ResponseStatusResponseDestinationChain type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Transact200ResponseStatusResponseDestinationChain{} + +// Transact200ResponseStatusResponseDestinationChain struct for Transact200ResponseStatusResponseDestinationChain +type Transact200ResponseStatusResponseDestinationChain struct { + DltProtocol interface{} `json:"dltProtocol,omitempty"` + DltSubnetworkID interface{} `json:"dltSubnetworkID,omitempty"` +} + +// NewTransact200ResponseStatusResponseDestinationChain instantiates a new Transact200ResponseStatusResponseDestinationChain object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewTransact200ResponseStatusResponseDestinationChain() *Transact200ResponseStatusResponseDestinationChain { + this := Transact200ResponseStatusResponseDestinationChain{} + return &this +} + +// NewTransact200ResponseStatusResponseDestinationChainWithDefaults instantiates a new Transact200ResponseStatusResponseDestinationChain object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewTransact200ResponseStatusResponseDestinationChainWithDefaults() *Transact200ResponseStatusResponseDestinationChain { + this := Transact200ResponseStatusResponseDestinationChain{} + return &this +} + +// GetDltProtocol returns the DltProtocol field value if set, zero value otherwise (both if not set or set to explicit null). +func (o *Transact200ResponseStatusResponseDestinationChain) GetDltProtocol() interface{} { + if o == nil { + var ret interface{} + return ret + } + return o.DltProtocol +} + +// GetDltProtocolOk returns a tuple with the DltProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *Transact200ResponseStatusResponseDestinationChain) GetDltProtocolOk() (*interface{}, bool) { + if o == nil || IsNil(o.DltProtocol) { + return nil, false + } + return &o.DltProtocol, true +} + +// HasDltProtocol returns a boolean if a field has been set. +func (o *Transact200ResponseStatusResponseDestinationChain) HasDltProtocol() bool { + if o != nil && IsNil(o.DltProtocol) { + return true + } + + return false +} + +// SetDltProtocol gets a reference to the given interface{} and assigns it to the DltProtocol field. +func (o *Transact200ResponseStatusResponseDestinationChain) SetDltProtocol(v interface{}) { + o.DltProtocol = v +} + +// GetDltSubnetworkID returns the DltSubnetworkID field value if set, zero value otherwise (both if not set or set to explicit null). +func (o *Transact200ResponseStatusResponseDestinationChain) GetDltSubnetworkID() interface{} { + if o == nil { + var ret interface{} + return ret + } + return o.DltSubnetworkID +} + +// GetDltSubnetworkIDOk returns a tuple with the DltSubnetworkID field value if set, nil otherwise +// and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *Transact200ResponseStatusResponseDestinationChain) GetDltSubnetworkIDOk() (*interface{}, bool) { + if o == nil || IsNil(o.DltSubnetworkID) { + return nil, false + } + return &o.DltSubnetworkID, true +} + +// HasDltSubnetworkID returns a boolean if a field has been set. +func (o *Transact200ResponseStatusResponseDestinationChain) HasDltSubnetworkID() bool { + if o != nil && IsNil(o.DltSubnetworkID) { + return true + } + + return false +} + +// SetDltSubnetworkID gets a reference to the given interface{} and assigns it to the DltSubnetworkID field. +func (o *Transact200ResponseStatusResponseDestinationChain) SetDltSubnetworkID(v interface{}) { + o.DltSubnetworkID = v +} + +func (o Transact200ResponseStatusResponseDestinationChain) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Transact200ResponseStatusResponseDestinationChain) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if o.DltProtocol != nil { + toSerialize["dltProtocol"] = o.DltProtocol + } + if o.DltSubnetworkID != nil { + toSerialize["dltSubnetworkID"] = o.DltSubnetworkID + } + return toSerialize, nil +} + +type NullableTransact200ResponseStatusResponseDestinationChain struct { + value *Transact200ResponseStatusResponseDestinationChain + isSet bool +} + +func (v NullableTransact200ResponseStatusResponseDestinationChain) Get() *Transact200ResponseStatusResponseDestinationChain { + return v.value +} + +func (v *NullableTransact200ResponseStatusResponseDestinationChain) Set(val *Transact200ResponseStatusResponseDestinationChain) { + v.value = val + v.isSet = true +} + +func (v NullableTransact200ResponseStatusResponseDestinationChain) IsSet() bool { + return v.isSet +} + +func (v *NullableTransact200ResponseStatusResponseDestinationChain) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTransact200ResponseStatusResponseDestinationChain(val *Transact200ResponseStatusResponseDestinationChain) *NullableTransact200ResponseStatusResponseDestinationChain { + return &NullableTransact200ResponseStatusResponseDestinationChain{value: val, isSet: true} +} + +func (v NullableTransact200ResponseStatusResponseDestinationChain) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTransact200ResponseStatusResponseDestinationChain) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_origin_chain.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_origin_chain.go new file mode 100644 index 0000000000..c3429547bf --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/model_transact_200_response_status_response_origin_chain.go @@ -0,0 +1,164 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + +API version: 0.0.2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package generated + +import ( + "encoding/json" +) + +// checks if the Transact200ResponseStatusResponseOriginChain type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Transact200ResponseStatusResponseOriginChain{} + +// Transact200ResponseStatusResponseOriginChain struct for Transact200ResponseStatusResponseOriginChain +type Transact200ResponseStatusResponseOriginChain struct { + DltProtocol interface{} `json:"dltProtocol,omitempty"` + DltSubnetworkID interface{} `json:"dltSubnetworkID,omitempty"` +} + +// NewTransact200ResponseStatusResponseOriginChain instantiates a new Transact200ResponseStatusResponseOriginChain object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewTransact200ResponseStatusResponseOriginChain() *Transact200ResponseStatusResponseOriginChain { + this := Transact200ResponseStatusResponseOriginChain{} + return &this +} + +// NewTransact200ResponseStatusResponseOriginChainWithDefaults instantiates a new Transact200ResponseStatusResponseOriginChain object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewTransact200ResponseStatusResponseOriginChainWithDefaults() *Transact200ResponseStatusResponseOriginChain { + this := Transact200ResponseStatusResponseOriginChain{} + return &this +} + +// GetDltProtocol returns the DltProtocol field value if set, zero value otherwise (both if not set or set to explicit null). +func (o *Transact200ResponseStatusResponseOriginChain) GetDltProtocol() interface{} { + if o == nil { + var ret interface{} + return ret + } + return o.DltProtocol +} + +// GetDltProtocolOk returns a tuple with the DltProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *Transact200ResponseStatusResponseOriginChain) GetDltProtocolOk() (*interface{}, bool) { + if o == nil || IsNil(o.DltProtocol) { + return nil, false + } + return &o.DltProtocol, true +} + +// HasDltProtocol returns a boolean if a field has been set. +func (o *Transact200ResponseStatusResponseOriginChain) HasDltProtocol() bool { + if o != nil && IsNil(o.DltProtocol) { + return true + } + + return false +} + +// SetDltProtocol gets a reference to the given interface{} and assigns it to the DltProtocol field. +func (o *Transact200ResponseStatusResponseOriginChain) SetDltProtocol(v interface{}) { + o.DltProtocol = v +} + +// GetDltSubnetworkID returns the DltSubnetworkID field value if set, zero value otherwise (both if not set or set to explicit null). +func (o *Transact200ResponseStatusResponseOriginChain) GetDltSubnetworkID() interface{} { + if o == nil { + var ret interface{} + return ret + } + return o.DltSubnetworkID +} + +// GetDltSubnetworkIDOk returns a tuple with the DltSubnetworkID field value if set, nil otherwise +// and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *Transact200ResponseStatusResponseOriginChain) GetDltSubnetworkIDOk() (*interface{}, bool) { + if o == nil || IsNil(o.DltSubnetworkID) { + return nil, false + } + return &o.DltSubnetworkID, true +} + +// HasDltSubnetworkID returns a boolean if a field has been set. +func (o *Transact200ResponseStatusResponseOriginChain) HasDltSubnetworkID() bool { + if o != nil && IsNil(o.DltSubnetworkID) { + return true + } + + return false +} + +// SetDltSubnetworkID gets a reference to the given interface{} and assigns it to the DltSubnetworkID field. +func (o *Transact200ResponseStatusResponseOriginChain) SetDltSubnetworkID(v interface{}) { + o.DltSubnetworkID = v +} + +func (o Transact200ResponseStatusResponseOriginChain) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Transact200ResponseStatusResponseOriginChain) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if o.DltProtocol != nil { + toSerialize["dltProtocol"] = o.DltProtocol + } + if o.DltSubnetworkID != nil { + toSerialize["dltSubnetworkID"] = o.DltSubnetworkID + } + return toSerialize, nil +} + +type NullableTransact200ResponseStatusResponseOriginChain struct { + value *Transact200ResponseStatusResponseOriginChain + isSet bool +} + +func (v NullableTransact200ResponseStatusResponseOriginChain) Get() *Transact200ResponseStatusResponseOriginChain { + return v.value +} + +func (v *NullableTransact200ResponseStatusResponseOriginChain) Set(val *Transact200ResponseStatusResponseOriginChain) { + v.value = val + v.isSet = true +} + +func (v NullableTransact200ResponseStatusResponseOriginChain) IsSet() bool { + return v.isSet +} + +func (v *NullableTransact200ResponseStatusResponseOriginChain) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTransact200ResponseStatusResponseOriginChain(val *Transact200ResponseStatusResponseOriginChain) *NullableTransact200ResponseStatusResponseOriginChain { + return &NullableTransact200ResponseStatusResponseOriginChain{value: val, isSet: true} +} + +func (v NullableTransact200ResponseStatusResponseOriginChain) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTransact200ResponseStatusResponseOriginChain) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/go/generated/test/api_chains_test.go b/packages/cactus-plugin-satp-hermes/src/main/go/generated/test/api_chains_test.go new file mode 100644 index 0000000000..2c39e87f1c --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/go/generated/test/api_chains_test.go @@ -0,0 +1,37 @@ +/* +SATP Gateway Client (Business Logic Orchestrator) + +Testing ChainsApiService + +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); + +package generated + +import ( + "context" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "testing" + openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID" +) + +func Test_generated_ChainsApiService(t *testing.T) { + + configuration := openapiclient.NewConfiguration() + apiClient := openapiclient.NewAPIClient(configuration) + + t.Run("Test ChainsApiService GetChains", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.ChainsApi.GetChains(context.Background()).Execute() + + require.Nil(t, err) + require.NotNil(t, resp) + assert.Equal(t, 200, httpRes.StatusCode) + + }) + +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/json/openapi-blo-bundled.json b/packages/cactus-plugin-satp-hermes/src/main/json/openapi-blo-bundled.json new file mode 100644 index 0000000000..3d121dfd3f --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/json/openapi-blo-bundled.json @@ -0,0 +1,6114 @@ +{ + "openapi": "3.0.3", + "info": { + "title": "SATP Gateway Client (Business Logic Orchestrator)", + "version": "0.0.2", + "description": "SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability.\n\nThis API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification.\n\n**Additional Resources**:\n- [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/)\n- [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core)\n- [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/)\n- [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/)\n- [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/)\n- [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing)\n- [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses)", + "contact": { + "name": "Hyperledger Cacti" + }, + "x-logo": { + "altText": "Cacti logo", + "backgroundColor": "#fafafa", + "url": "https://github.com/hyperledger/cacti/blob/main/images/HL_Cacti_Logo_Color.png" + } + }, + "externalDocs": { + "description": "For more information about the SATP Gateway Client, refer to the official documentation.", + "url": "https://github.com/hyperledger/cacti/tree/main/packages/cactus-plugin-satp-hermes/README.md" + }, + "servers": [ + { + "url": "http://{host}:{port}/api/v1/@hyperledger/cactus-plugin-satp-hermes", + "description": "Development server", + "variables": { + "host": { + "default": "localhost" + }, + "port": { + "default": "3011" + } + } + } + ], + "tags": [ + { + "name": "transaction", + "description": "API endpoints for interacting with blockchains via gateways" + }, + { + "name": "admin", + "description": "API endpoints for fetching information on SATP sessions" + } + ], + "paths": { + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/transact": { + "post": { + "tags": [ + "transaction" + ], + "summary": "Submit a transaction intent", + "description": "Allows users to queue intents for transactions based on specified parameters.", + "operationId": "Transact", + "requestBody": { + "content": { + "application/json": { + "schema": { + "description": "Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks.", + "type": "object", + "required": [ + "contextID", + "mode" + ], + "properties": { + "contextID": { + "type": "string", + "format": "uuid", + "example": "123e4567-e89b-12d3-a456-426614174000" + }, + "mode": { + "type": "string", + "enum": [ + "data", + "transfer" + ], + "example": "transfer" + }, + "payload": { + "type": "string", + "example": "{\"data\":\"example payload\"}" + }, + "fromDLTNetworkID": { + "type": "string", + "example": "network1" + }, + "toDLTNetworkID": { + "type": "string", + "example": "network2" + }, + "fromAmount": { + "type": "string", + "example": "100" + }, + "fromToken": { + "type": "string", + "example": "TOKEN1" + }, + "toAmount": { + "type": "string", + "example": "95" + }, + "toToken": { + "type": "string", + "example": "TOKEN2" + } + } + } + } + }, + "required": true + }, + "responses": { + "200": { + "description": "Transaction successfully queued", + "content": { + "application/json": { + "schema": { + "description": "Response schema for a transaction request. Includes the session ID and the current status of the transaction.", + "type": "object", + "properties": { + "sessionID": { + "x-category": "satp-core", + "type": "string", + "description": "Unique identifier (UUID) for the session.", + "example": "000003e8-e0b8-21ee-ba00-325096b39f47" + }, + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + }, + "required": [ + "sessionID", + "statusResponse" + ] + } + } + } + }, + "default": { + "description": "An error occurred", + "content": { + "application/json": { + "schema": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + } + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel": { + "post": { + "tags": [ + "transaction" + ], + "summary": "Cancel a transaction session", + "description": "Attempts to cancel a previously submitted transaction intent using its session ID.", + "operationId": "Cancel", + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel" + } + }, + "requestBody": { + "content": { + "application/json": { + "schema": { + "description": "Request to cancel an ongoing transaction session, identified by the session ID.", + "type": "object", + "properties": { + "sessionID": { + "x-category": "satp-core", + "type": "string", + "description": "Unique identifier (UUID) for the session.", + "example": "000003e8-e0b8-21ee-ba00-325096b39f47" + } + }, + "required": [ + "sessionID" + ] + } + } + }, + "required": true + }, + "responses": { + "200": { + "description": "Transaction cancellation attempted", + "content": { + "application/json": { + "schema": { + "description": "Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status.", + "type": "object", + "properties": { + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + }, + "cancelSuccessful": { + "type": "boolean", + "description": "Indicates whether the cancel operation was successful.", + "example": true + } + }, + "required": [ + "statusResponse", + "cancelSuccessful" + ] + } + } + } + }, + "default": { + "description": "An error occurred or transaction cannot be cancelled", + "content": { + "application/json": { + "schema": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + } + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/status": { + "get": { + "summary": "Get SATP current session data", + "description": "Retrieve the status of a SATP session", + "operationId": "GetStatus", + "tags": [ + "admin" + ], + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "get", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/status" + } + }, + "parameters": [ + { + "name": "SessionID", + "in": "query", + "schema": { + "x-category": "satp-core", + "type": "string", + "description": "Unique identifier (UUID) for the session.", + "example": "000003e8-e0b8-21ee-ba00-325096b39f47" + }, + "required": true, + "description": "Unique identifier for the session." + } + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + } + } + }, + "400": { + "description": "Bad request" + }, + "404": { + "description": "Transaction not found" + }, + "500": { + "description": "Internal server error" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/healthcheck": { + "get": { + "summary": "Health check endpoint", + "description": "Responds if SATP Hermes is on", + "operationId": "GetHealthCheck", + "tags": [ + "admin" + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "status": { + "type": "string", + "example": "OK" + } + } + } + } + } + }, + "500": { + "description": "Internal server error" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/continue": { + "post": { + "tags": [ + "admin" + ], + "summary": "Continue a paused transaction session", + "description": "Attempts to continue a previously paused transaction intent, resuming its execution.", + "operationId": "Continue", + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/continue" + } + }, + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionId": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the transaction session to be continued." + }, + "contextId": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the transaction context." + } + }, + "required": [ + "sessionId", + "contextId" + ], + "description": "Schema for a request to continue a paused transaction session." + } + } + }, + "required": true + }, + "responses": { + "200": { + "description": "Transaction continuation attempted", + "content": { + "application/json": { + "schema": { + "type": "object", + "description": "Response schema for a continue request, returning the status of the SATP session.", + "properties": { + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + }, + "required": [ + "statusResponse" + ] + } + } + } + }, + "default": { + "description": "An error occurred or transaction cannot be continued", + "content": { + "application/json": { + "schema": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + } + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/pause": { + "post": { + "tags": [ + "admin" + ], + "summary": "Pause a transaction session", + "description": "Attempts to pause a previously submitted transaction intent, temporarily halting its execution.", + "operationId": "Pause", + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/pause" + } + }, + "requestBody": { + "content": { + "application/json": { + "schema": { + "description": "Request to temporarily pause an ongoing transaction session, identified by the session and context IDs.", + "type": "object", + "properties": { + "sessionId": { + "type": "string", + "format": "uuid", + "example": "123e4567-e89b-12d3-a456-426614174000" + }, + "contextId": { + "type": "string", + "format": "uuid", + "example": "123e4567-e89b-12d3-a456-426614174001" + } + } + } + } + }, + "required": true + }, + "responses": { + "200": { + "description": "Transaction pause attempted", + "content": { + "application/json": { + "schema": { + "description": "Response for a pause transaction request. Returns the current status of the SATP session post-pause action.", + "type": "object", + "properties": { + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + }, + "required": [ + "statusResponse" + ] + } + } + } + }, + "default": { + "description": "An error occurred or transaction cannot be paused", + "content": { + "application/json": { + "schema": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + } + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations": { + "get": { + "tags": [ + "transaction" + ], + "summary": "Get supported integrations", + "description": "Retrieves metadata about each supported blockchain networks, chains, and other systems.", + "operationId": "GetIntegrations", + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "get", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations" + } + }, + "responses": { + "200": { + "description": "A list of supported systems.", + "content": { + "application/json": { + "schema": { + "title": "Chains", + "type": "array", + "description": "List of chains and related metadata", + "items": { + "type": "object", + "properties": { + "chainId": { + "type": "string", + "description": "A unique identifier for the blockchain network." + }, + "chainName": { + "type": "string", + "description": "The name of the blockchain network." + }, + "chainType": { + "type": "string", + "description": "The type of blockchain network (e.g., 'evm', 'fabric')." + }, + "networkName": { + "type": "string", + "description": "The specific network name within the blockchain (e.g., 'mainnet', 'testnet')." + } + }, + "required": [ + "chainId", + "chainName", + "chainType", + "networkName" + ] + } + } + } + } + }, + "default": { + "description": "An error occurred", + "content": { + "application/json": { + "schema": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + } + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/routes": { + "get": { + "description": "Get a list of possible routes for swapping one asset for another across multiple exchanges", + "summary": "Get a list of routes for a gateway-to-gateway asset transfer", + "tags": [ + "transaction" + ], + "operationId": "GetRoutes", + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "get", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/routes" + } + }, + "parameters": [ + { + "name": "fromNetworkID", + "in": "query", + "schema": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "required": true, + "description": "The sending DLT Network." + }, + { + "name": "fromAmount", + "in": "query", + "schema": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "required": true, + "description": "The amount that should be sent including all decimals." + }, + { + "name": "fromToken", + "in": "query", + "schema": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "required": true, + "description": "The token that should be transferred. Can be the address or the symbol." + }, + { + "name": "toDLTNetwork", + "in": "query", + "schema": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "required": true, + "description": "The receiving DLT Network." + }, + { + "name": "toToken", + "in": "query", + "schema": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "required": true, + "description": "The token that should be transferred to. Can be the address or the symbol." + }, + { + "name": "fromAddress", + "in": "query", + "schema": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "required": true, + "description": "The sending wallet address." + }, + { + "name": "toAddress", + "in": "query", + "schema": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "required": true, + "description": "The receiving wallet address. If none is provided, the fromAddress will be used." + } + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "description": "A collection of available and unavailable routes", + "required": [ + "routes" + ], + "properties": { + "routes": { + "type": "array", + "description": "A collection of route objects", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "A unique identifier of the route." + }, + "gatewayID": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the gateway." + }, + "mode": { + "type": "string", + "enum": [ + "data", + "transfer" + ], + "description": "The mode of operation for this route - 'data' for arbitrary payload handling, 'transfer' for asset transfer." + }, + "fromDLTNetworkID": { + "type": "string", + "description": "The ID of the DLT Network where the operation will originate." + }, + "fromAmountUSD": { + "type": "string", + "format": "double", + "description": "The amount of 'fromToken' to be transferred in USD, specified as a string to maintain precision." + }, + "fromAmount": { + "type": "string", + "description": "The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).", + "pattern": "^[1-9][0-9]*$" + }, + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "toDLTNetworkID": { + "type": "string", + "description": "The ID of the DLT Network where the operation will end." + }, + "toAmountUSD": { + "type": "string", + "description": "The expected amount to be received in USD." + }, + "toAmount": { + "type": "string", + "description": "The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals))." + }, + "toAmountMin": { + "type": "string", + "description": "The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals))." + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "gasCostUSD": { + "type": "string", + "description": "The expected gas cost in USD." + }, + "containsSwitchChain": { + "type": "boolean", + "description": "Whether chain switching is enabled or not." + }, + "steps": { + "type": "array", + "description": "List of steps involved in this route, adjusted for mode.", + "items": { + "type": "object", + "description": "Details a single step within a route including actions and estimates.", + "properties": { + "id": { + "type": "string", + "description": "Id of the step" + }, + "type": { + "type": "string", + "description": "Type of the step, typically describing the action, e.g., 'swap'." + }, + "tool": { + "type": "string", + "description": "Tool used in the step, e.g., 'stargate'." + }, + "action": { + "type": "object", + "properties": { + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "fromAmount": { + "type": "string", + "description": "The amount of 'fromToken' to be transferred, specified as a string to maintain precision.", + "example": "1000000000000000000", + "pattern": "^[1-9][0-9]*$" + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "slippage": { + "type": "number", + "format": "float", + "description": "The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer.", + "example": 0.005 + }, + "fromAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + } + } + }, + "estimate": { + "type": "object", + "description": "Provides an estimation for a transaction, including costs, amounts, and execution duration.", + "properties": { + "approvalAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAmountMin": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "fromAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "feeCosts": { + "type": "array", + "description": "A collection of fee costs associated with the transaction.", + "items": { + "type": "object", + "description": "Details about a specific fee cost associated with the transaction.", + "properties": { + "name": { + "type": "string", + "description": "Name of the fee cost.", + "example": "Network Fee" + }, + "amount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "amountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "token": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "included": { + "type": "boolean", + "description": "Indicates if the fee is included in the transaction amount." + } + } + } + }, + "gasCosts": { + "type": "array", + "description": "A collection of estimated gas costs for executing the transaction.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type of the gas cost.", + "example": "SEND" + }, + "price": { + "type": "string", + "description": "The gas price, specified as a string to maintain precision.", + "example": "19236858243" + }, + "estimate": { + "type": "string", + "description": "The estimated gas required, specified as a string to maintain precision.", + "example": "445393" + }, + "limit": { + "type": "string", + "description": "The gas limit for the transaction, specified as a string to maintain precision.", + "example": "579011", + "pattern": "^[1-9][0-9]*$" + }, + "amount": { + "type": "string", + "description": "The amount of gas required in the gas currency.", + "example": "8567962003424499", + "pattern": "^[1-9][0-9]*$" + }, + "amountUSD": { + "type": "string", + "description": "The amount of gas required in USD.", + "example": "16.05", + "pattern": "^(0(\\.[0-9]+)?|[1-9][0-9]*(\\.[0-9]+)?)$" + }, + "token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + } + } + } + }, + "executionDuration": { + "type": "integer", + "description": "The estimated duration for the transaction execution in seconds.", + "example": 30 + }, + "fromAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "tool": { + "type": "string", + "description": "The tool or service used to generate this estimate.", + "example": "satp" + } + } + }, + "toolDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "integrationDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "includedStepIds": { + "type": "array", + "description": "IDs of further steps included within this step, allowing for nested actions without direct recursion.", + "items": { + "type": "string" + } + } + } + } + }, + "insurance": { + "type": "object", + "properties": { + "state": { + "type": "string", + "description": "The state of insurance applicability for the transaction.", + "example": "NOT_INSURABLE", + "enum": [ + "NOT_INSURABLE", + "INSURABLE", + "INSURED" + ] + }, + "feeAmountUsd": { + "type": "string", + "description": "The fee amount for insurance, represented in USD.", + "example": "10.00", + "pattern": "^(0|[1-9]\\d*)(\\.\\d+)?$" + } + } + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + } + }, + "required": [ + "id", + "gatewayID", + "mode" + ] + } + } + } + } + } + } + }, + "default": { + "description": "An error occurred", + "content": { + "application/json": { + "schema": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + } + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/audit": { + "get": { + "tags": [ + "admin" + ], + "summary": "Audit transactions", + "description": "Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction.", + "operationId": "GetAudit", + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "get", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/audit" + } + }, + "parameters": [ + { + "name": "auditStartDate", + "in": "query", + "description": "The start date for the audit period.", + "required": false, + "schema": { + "type": "string", + "format": "date-time" + } + }, + { + "name": "auditEndDate", + "in": "query", + "description": "The end date for the audit period.", + "required": false, + "schema": { + "type": "string", + "format": "date-time" + } + }, + { + "name": "includeProofs", + "in": "query", + "description": "Include proofs generated from each gateway transaction.", + "required": false, + "schema": { + "type": "boolean" + } + } + ], + "responses": { + "200": { + "description": "Audit results", + "content": { + "application/json": { + "schema": { + "description": "Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes.", + "type": "object", + "x-category": "response", + "properties": { + "proofs": { + "type": "array", + "items": { + "type": "string" + }, + "description": "An array of strings representing proofs.", + "example": [ + "proof1", + "proof2" + ] + }, + "auditStartTime": { + "type": "string", + "format": "date-time", + "description": "The start datetime of the audit period.", + "example": "2023-01-01T00:00:00Z" + }, + "auditEndTime": { + "type": "string", + "format": "date-time", + "description": "The end datetime of the audit period.", + "example": "2023-01-31T23:59:59Z" + } + } + } + } + } + } + } + } + } + }, + "components": { + "schemas": { + "AuthzScope": { + "type": "string", + "enum": [ + "group:admin", + "group:user" + ], + "x-enum-descriptions": [ + "Identities with the group:admin scope are administrators of the system.", + "Identities with the group:user scope are end users of the system who only have authorization to perform a limited set of actions." + ], + "x-enum-varnames": [ + "GroupAdmin", + "GroupUser" + ], + "example": "group:admin" + }, + "AuthzJwtClaim": { + "description": "Stores global constants related to the authorization of the application. Specifically enumerates the claims to validate for as per RFC 7519, section 4.1. See: https://tools.ietf.org/html/rfc7519#section-4.1", + "type": "string", + "enum": [ + "Hyperledger Labs - Carbon Accounting Tool" + ], + "x-enum-descriptions": [ + "The \"iss\" (issuer) claim identifies the principal that issued the JWT. The processing of this claim is generally application specific. The \"iss\" value is a case-sensitive string containing a StringOrURI value. Use of this claim is OPTIONAL." + ], + "x-enum-varnames": [ + "iss" + ], + "example": "Hyperledger Labs - Carbon Accounting Tool" + }, + "CredentialProfile": { + "type": "string", + "enum": [ + "SAML", + "OAUTH", + "X509" + ], + "example": "OAUTH" + }, + "getAuditRequest": { + "description": "Request schema for initiating an audit. Includes the start and end dates for the audit period and an option to include proofs.", + "type": "object", + "x-category": "request", + "properties": { + "auditStartDate": { + "type": "string", + "format": "date-time", + "description": "The start datetime for the audit.", + "example": "2023-01-01T00:00:00Z" + }, + "auditEndDate": { + "type": "string", + "format": "date-time", + "description": "The end datetime for the audit.", + "example": "2023-01-31T23:59:59Z" + }, + "includeProofs": { + "type": "boolean", + "description": "Include proofs generated from each gateway transaction.", + "example": true + } + } + }, + "getAuditResponse": { + "description": "Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes.", + "type": "object", + "x-category": "response", + "properties": { + "proofs": { + "type": "array", + "items": { + "type": "string" + }, + "description": "An array of strings representing proofs.", + "example": [ + "proof1", + "proof2" + ] + }, + "auditStartTime": { + "type": "string", + "format": "date-time", + "description": "The start datetime of the audit period.", + "example": "2023-01-01T00:00:00Z" + }, + "auditEndTime": { + "type": "string", + "format": "date-time", + "description": "The end datetime of the audit period.", + "example": "2023-01-31T23:59:59Z" + } + } + }, + "StatusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + }, + "PauseRequest": { + "description": "Request to temporarily pause an ongoing transaction session, identified by the session and context IDs.", + "type": "object", + "properties": { + "sessionId": { + "type": "string", + "format": "uuid", + "example": "123e4567-e89b-12d3-a456-426614174000" + }, + "contextId": { + "type": "string", + "format": "uuid", + "example": "123e4567-e89b-12d3-a456-426614174001" + } + } + }, + "PauseResponse": { + "description": "Response for a pause transaction request. Returns the current status of the SATP session post-pause action.", + "type": "object", + "properties": { + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + }, + "required": [ + "statusResponse" + ] + }, + "StatusRequest": { + "description": "Request for retrieving the current status of a session, identified by the session ID.", + "type": "object", + "x-category": "request", + "required": [ + "sessionID" + ], + "properties": { + "sessionID": { + "type": "string", + "description": "The ID of the session for which the status is being requested." + } + }, + "example": "123e4567-e89b-12d3-a456-426614174000" + }, + "TransactRequest": { + "description": "Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks.", + "type": "object", + "required": [ + "contextID", + "mode" + ], + "properties": { + "contextID": { + "type": "string", + "format": "uuid", + "example": "123e4567-e89b-12d3-a456-426614174000" + }, + "mode": { + "type": "string", + "enum": [ + "data", + "transfer" + ], + "example": "transfer" + }, + "payload": { + "type": "string", + "example": "{\"data\":\"example payload\"}" + }, + "fromDLTNetworkID": { + "type": "string", + "example": "network1" + }, + "toDLTNetworkID": { + "type": "string", + "example": "network2" + }, + "fromAmount": { + "type": "string", + "example": "100" + }, + "fromToken": { + "type": "string", + "example": "TOKEN1" + }, + "toAmount": { + "type": "string", + "example": "95" + }, + "toToken": { + "type": "string", + "example": "TOKEN2" + } + } + }, + "TransactResponse": { + "description": "Response schema for a transaction request. Includes the session ID and the current status of the transaction.", + "type": "object", + "properties": { + "sessionID": { + "x-category": "satp-core", + "type": "string", + "description": "Unique identifier (UUID) for the session.", + "example": "000003e8-e0b8-21ee-ba00-325096b39f47" + }, + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + }, + "required": [ + "sessionID", + "statusResponse" + ] + }, + "CancelRequest": { + "description": "Request to cancel an ongoing transaction session, identified by the session ID.", + "type": "object", + "properties": { + "sessionID": { + "x-category": "satp-core", + "type": "string", + "description": "Unique identifier (UUID) for the session.", + "example": "000003e8-e0b8-21ee-ba00-325096b39f47" + } + }, + "required": [ + "sessionID" + ] + }, + "CancelResponse": { + "description": "Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status.", + "type": "object", + "properties": { + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + }, + "cancelSuccessful": { + "type": "boolean", + "description": "Indicates whether the cancel operation was successful.", + "example": true + } + }, + "required": [ + "statusResponse", + "cancelSuccessful" + ] + }, + "APIError": { + "x-category": "response", + "type": "object", + "x-go-type": "ApiError", + "x-go-name": "ApiError", + "description": "An Error", + "required": [ + "message", + "type", + "code", + "status", + "timestamp" + ], + "properties": { + "type": { + "type": "string", + "description": "HTTP error type", + "example": "bad-request" + }, + "code": { + "type": "integer", + "description": "Numeric error code", + "example": 16384 + }, + "status": { + "type": "integer", + "description": "HTTP status of the error", + "example": 500 + }, + "message": { + "type": "string", + "description": "Long error description", + "example": "Oops there's been an internal error handling" + }, + "timestamp": { + "type": "string", + "description": "Timestamp of the error", + "example": "2021-07-21T17:32:28Z" + } + } + }, + "DLTProtocol": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "DLTNetworkID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "DLTSubnetworkID": { + "x-category": "satp-core", + "type": "string", + "description": "The subnetwork of the DLT being interacted with. TODO: implement network identification draft" + }, + "SessionID": { + "x-category": "satp-core", + "type": "string", + "description": "Unique identifier (UUID) for the session.", + "example": "000003e8-e0b8-21ee-ba00-325096b39f47" + }, + "Address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "AmountString": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "AmountDecimal": { + "type": "number", + "format": "float", + "description": "Amount value with decimal places", + "example": 100.33 + }, + "TokenSymbol": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "LogoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "RoutesResponse": { + "type": "object", + "description": "A collection of available and unavailable routes", + "required": [ + "routes" + ], + "properties": { + "routes": { + "type": "array", + "description": "A collection of route objects", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "A unique identifier of the route." + }, + "gatewayID": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the gateway." + }, + "mode": { + "type": "string", + "enum": [ + "data", + "transfer" + ], + "description": "The mode of operation for this route - 'data' for arbitrary payload handling, 'transfer' for asset transfer." + }, + "fromDLTNetworkID": { + "type": "string", + "description": "The ID of the DLT Network where the operation will originate." + }, + "fromAmountUSD": { + "type": "string", + "format": "double", + "description": "The amount of 'fromToken' to be transferred in USD, specified as a string to maintain precision." + }, + "fromAmount": { + "type": "string", + "description": "The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).", + "pattern": "^[1-9][0-9]*$" + }, + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "toDLTNetworkID": { + "type": "string", + "description": "The ID of the DLT Network where the operation will end." + }, + "toAmountUSD": { + "type": "string", + "description": "The expected amount to be received in USD." + }, + "toAmount": { + "type": "string", + "description": "The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals))." + }, + "toAmountMin": { + "type": "string", + "description": "The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals))." + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "gasCostUSD": { + "type": "string", + "description": "The expected gas cost in USD." + }, + "containsSwitchChain": { + "type": "boolean", + "description": "Whether chain switching is enabled or not." + }, + "steps": { + "type": "array", + "description": "List of steps involved in this route, adjusted for mode.", + "items": { + "type": "object", + "description": "Details a single step within a route including actions and estimates.", + "properties": { + "id": { + "type": "string", + "description": "Id of the step" + }, + "type": { + "type": "string", + "description": "Type of the step, typically describing the action, e.g., 'swap'." + }, + "tool": { + "type": "string", + "description": "Tool used in the step, e.g., 'stargate'." + }, + "action": { + "type": "object", + "properties": { + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "fromAmount": { + "type": "string", + "description": "The amount of 'fromToken' to be transferred, specified as a string to maintain precision.", + "example": "1000000000000000000", + "pattern": "^[1-9][0-9]*$" + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "slippage": { + "type": "number", + "format": "float", + "description": "The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer.", + "example": 0.005 + }, + "fromAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + } + } + }, + "estimate": { + "type": "object", + "description": "Provides an estimation for a transaction, including costs, amounts, and execution duration.", + "properties": { + "approvalAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAmountMin": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "fromAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "feeCosts": { + "type": "array", + "description": "A collection of fee costs associated with the transaction.", + "items": { + "type": "object", + "description": "Details about a specific fee cost associated with the transaction.", + "properties": { + "name": { + "type": "string", + "description": "Name of the fee cost.", + "example": "Network Fee" + }, + "amount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "amountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "token": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "included": { + "type": "boolean", + "description": "Indicates if the fee is included in the transaction amount." + } + } + } + }, + "gasCosts": { + "type": "array", + "description": "A collection of estimated gas costs for executing the transaction.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type of the gas cost.", + "example": "SEND" + }, + "price": { + "type": "string", + "description": "The gas price, specified as a string to maintain precision.", + "example": "19236858243" + }, + "estimate": { + "type": "string", + "description": "The estimated gas required, specified as a string to maintain precision.", + "example": "445393" + }, + "limit": { + "type": "string", + "description": "The gas limit for the transaction, specified as a string to maintain precision.", + "example": "579011", + "pattern": "^[1-9][0-9]*$" + }, + "amount": { + "type": "string", + "description": "The amount of gas required in the gas currency.", + "example": "8567962003424499", + "pattern": "^[1-9][0-9]*$" + }, + "amountUSD": { + "type": "string", + "description": "The amount of gas required in USD.", + "example": "16.05", + "pattern": "^(0(\\.[0-9]+)?|[1-9][0-9]*(\\.[0-9]+)?)$" + }, + "token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + } + } + } + }, + "executionDuration": { + "type": "integer", + "description": "The estimated duration for the transaction execution in seconds.", + "example": 30 + }, + "fromAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "tool": { + "type": "string", + "description": "The tool or service used to generate this estimate.", + "example": "satp" + } + } + }, + "toolDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "integrationDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "includedStepIds": { + "type": "array", + "description": "IDs of further steps included within this step, allowing for nested actions without direct recursion.", + "items": { + "type": "string" + } + } + } + } + }, + "insurance": { + "type": "object", + "properties": { + "state": { + "type": "string", + "description": "The state of insurance applicability for the transaction.", + "example": "NOT_INSURABLE", + "enum": [ + "NOT_INSURABLE", + "INSURABLE", + "INSURED" + ] + }, + "feeAmountUsd": { + "type": "string", + "description": "The fee amount for insurance, represented in USD.", + "example": "10.00", + "pattern": "^(0|[1-9]\\d*)(\\.\\d+)?$" + } + } + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + } + }, + "required": [ + "id", + "gatewayID", + "mode" + ] + } + } + } + }, + "Route": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "A unique identifier of the route." + }, + "gatewayID": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the gateway." + }, + "mode": { + "type": "string", + "enum": [ + "data", + "transfer" + ], + "description": "The mode of operation for this route - 'data' for arbitrary payload handling, 'transfer' for asset transfer." + }, + "fromDLTNetworkID": { + "type": "string", + "description": "The ID of the DLT Network where the operation will originate." + }, + "fromAmountUSD": { + "type": "string", + "format": "double", + "description": "The amount of 'fromToken' to be transferred in USD, specified as a string to maintain precision." + }, + "fromAmount": { + "type": "string", + "description": "The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).", + "pattern": "^[1-9][0-9]*$" + }, + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "toDLTNetworkID": { + "type": "string", + "description": "The ID of the DLT Network where the operation will end." + }, + "toAmountUSD": { + "type": "string", + "description": "The expected amount to be received in USD." + }, + "toAmount": { + "type": "string", + "description": "The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals))." + }, + "toAmountMin": { + "type": "string", + "description": "The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals))." + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "gasCostUSD": { + "type": "string", + "description": "The expected gas cost in USD." + }, + "containsSwitchChain": { + "type": "boolean", + "description": "Whether chain switching is enabled or not." + }, + "steps": { + "type": "array", + "description": "List of steps involved in this route, adjusted for mode.", + "items": { + "type": "object", + "description": "Details a single step within a route including actions and estimates.", + "properties": { + "id": { + "type": "string", + "description": "Id of the step" + }, + "type": { + "type": "string", + "description": "Type of the step, typically describing the action, e.g., 'swap'." + }, + "tool": { + "type": "string", + "description": "Tool used in the step, e.g., 'stargate'." + }, + "action": { + "type": "object", + "properties": { + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "fromAmount": { + "type": "string", + "description": "The amount of 'fromToken' to be transferred, specified as a string to maintain precision.", + "example": "1000000000000000000", + "pattern": "^[1-9][0-9]*$" + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "slippage": { + "type": "number", + "format": "float", + "description": "The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer.", + "example": 0.005 + }, + "fromAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + } + } + }, + "estimate": { + "type": "object", + "description": "Provides an estimation for a transaction, including costs, amounts, and execution duration.", + "properties": { + "approvalAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAmountMin": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "fromAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "feeCosts": { + "type": "array", + "description": "A collection of fee costs associated with the transaction.", + "items": { + "type": "object", + "description": "Details about a specific fee cost associated with the transaction.", + "properties": { + "name": { + "type": "string", + "description": "Name of the fee cost.", + "example": "Network Fee" + }, + "amount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "amountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "token": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "included": { + "type": "boolean", + "description": "Indicates if the fee is included in the transaction amount." + } + } + } + }, + "gasCosts": { + "type": "array", + "description": "A collection of estimated gas costs for executing the transaction.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type of the gas cost.", + "example": "SEND" + }, + "price": { + "type": "string", + "description": "The gas price, specified as a string to maintain precision.", + "example": "19236858243" + }, + "estimate": { + "type": "string", + "description": "The estimated gas required, specified as a string to maintain precision.", + "example": "445393" + }, + "limit": { + "type": "string", + "description": "The gas limit for the transaction, specified as a string to maintain precision.", + "example": "579011", + "pattern": "^[1-9][0-9]*$" + }, + "amount": { + "type": "string", + "description": "The amount of gas required in the gas currency.", + "example": "8567962003424499", + "pattern": "^[1-9][0-9]*$" + }, + "amountUSD": { + "type": "string", + "description": "The amount of gas required in USD.", + "example": "16.05", + "pattern": "^(0(\\.[0-9]+)?|[1-9][0-9]*(\\.[0-9]+)?)$" + }, + "token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + } + } + } + }, + "executionDuration": { + "type": "integer", + "description": "The estimated duration for the transaction execution in seconds.", + "example": 30 + }, + "fromAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "tool": { + "type": "string", + "description": "The tool or service used to generate this estimate.", + "example": "satp" + } + } + }, + "toolDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "integrationDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "includedStepIds": { + "type": "array", + "description": "IDs of further steps included within this step, allowing for nested actions without direct recursion.", + "items": { + "type": "string" + } + } + } + } + }, + "insurance": { + "type": "object", + "properties": { + "state": { + "type": "string", + "description": "The state of insurance applicability for the transaction.", + "example": "NOT_INSURABLE", + "enum": [ + "NOT_INSURABLE", + "INSURABLE", + "INSURED" + ] + }, + "feeAmountUsd": { + "type": "string", + "description": "The fee amount for insurance, represented in USD.", + "example": "10.00", + "pattern": "^(0|[1-9]\\d*)(\\.\\d+)?$" + } + } + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + } + }, + "required": [ + "id", + "gatewayID", + "mode" + ] + }, + "ContinueRequest": { + "type": "object", + "properties": { + "sessionId": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the transaction session to be continued." + }, + "contextId": { + "type": "string", + "format": "uuid", + "description": "A unique identifier for the transaction context." + } + }, + "required": [ + "sessionId", + "contextId" + ], + "description": "Schema for a request to continue a paused transaction session." + }, + "ContinueResponse": { + "type": "object", + "description": "Response schema for a continue request, returning the status of the SATP session.", + "properties": { + "statusResponse": { + "description": "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.", + "type": "object", + "x-category": "response", + "required": [ + "status", + "substatus", + "stage", + "step", + "startTime", + "originChain", + "destinationChain" + ], + "properties": { + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED" + ], + "example": "DONE" + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "NOT_PROCESSABLE_REFUND_NEEDED" + ], + "example": "COMPLETED" + }, + "stage": { + "type": "string", + "enum": [ + "STAGE0", + "STAGE1", + "STAGE2", + "STAGE3" + ], + "example": "STAGE3" + }, + "step": { + "type": "string", + "enum": [ + "transfer-initialization-claims", + "conveyance-of-network-capabilities-and-parameters", + "transfer-proposal-message", + "transfer-proposal-receipt-message", + "transfer-proposal-reject-and-conditional-reject-message", + "transfer-commence-message", + "commence-response-message", + "lock-assertion-message", + "lock-assertion-receipt-message", + "commit-preparation-message", + "commit-ready-message", + "commit-final-assertion-message", + "commit-final-acknowledgement-receipt-message", + "transfer-complete-message", + "rollback-transfer-initialization-claims", + "rollback-conveyance-of-network-capabilities-and-parameters", + "rollback-transfer-proposal-message", + "rollback-transfer-proposal-receipt-message", + "rollback-transfer-proposal-reject-and-conditional-reject-message", + "rollback-transfer-commence-message", + "rollback-commence-response-message", + "rollback-lock-assertion-message", + "rollback-lock-assertion-receipt-message", + "rollback-commit-preparation-message", + "rollback-commit-ready-message", + "rollback-commit-final-assertion-message", + "rollback-commit-final-acknowledgement-receipt-message", + "rollback-transfer-complete-message" + ], + "example": "transfer-complete-message" + }, + "startTime": { + "type": "string", + "format": "date-time", + "example": "2023-01-01T00:00:00Z" + }, + "originChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerFabric" + }, + "dltSubnetworkID": { + "example": "subnetwork1" + } + } + }, + "destinationChain": { + "type": "object", + "properties": { + "dltProtocol": { + "example": "HyperledgerBesu" + }, + "dltSubnetworkID": { + "example": "subnetwork2" + } + } + } + } + } + }, + "required": [ + "statusResponse" + ] + }, + "Chain": { + "type": "object", + "properties": { + "chainId": { + "type": "string", + "description": "A unique identifier for the blockchain network." + }, + "chainName": { + "type": "string", + "description": "The name of the blockchain network." + }, + "chainType": { + "type": "string", + "description": "The type of blockchain network (e.g., 'evm', 'fabric')." + }, + "networkName": { + "type": "string", + "description": "The specific network name within the blockchain (e.g., 'mainnet', 'testnet')." + } + }, + "required": [ + "chainId", + "chainName", + "chainType", + "networkName" + ] + }, + "Chains": { + "title": "Chains", + "type": "array", + "description": "List of chains and related metadata", + "items": { + "type": "object", + "properties": { + "chainId": { + "type": "string", + "description": "A unique identifier for the blockchain network." + }, + "chainName": { + "type": "string", + "description": "The name of the blockchain network." + }, + "chainType": { + "type": "string", + "description": "The type of blockchain network (e.g., 'evm', 'fabric')." + }, + "networkName": { + "type": "string", + "description": "The specific network name within the blockchain (e.g., 'mainnet', 'testnet')." + } + }, + "required": [ + "chainId", + "chainName", + "chainType", + "networkName" + ] + } + }, + "Token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "Tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "HealthCheckResponse": { + "type": "object", + "properties": { + "status": { + "type": "string", + "example": "OK" + } + } + }, + "BridgeInfo": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + }, + "IncludedStep": { + "type": "object", + "description": "Details a single step within a route including actions and estimates.", + "properties": { + "id": { + "type": "string", + "description": "Id of the step" + }, + "type": { + "type": "string", + "description": "Type of the step, typically describing the action, e.g., 'swap'." + }, + "tool": { + "type": "string", + "description": "Tool used in the step, e.g., 'stargate'." + }, + "action": { + "type": "object", + "properties": { + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "fromAmount": { + "type": "string", + "description": "The amount of 'fromToken' to be transferred, specified as a string to maintain precision.", + "example": "1000000000000000000", + "pattern": "^[1-9][0-9]*$" + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "slippage": { + "type": "number", + "format": "float", + "description": "The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer.", + "example": 0.005 + }, + "fromAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + } + } + }, + "estimate": { + "type": "object", + "description": "Provides an estimation for a transaction, including costs, amounts, and execution duration.", + "properties": { + "approvalAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAmountMin": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "fromAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "feeCosts": { + "type": "array", + "description": "A collection of fee costs associated with the transaction.", + "items": { + "type": "object", + "description": "Details about a specific fee cost associated with the transaction.", + "properties": { + "name": { + "type": "string", + "description": "Name of the fee cost.", + "example": "Network Fee" + }, + "amount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "amountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "token": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "included": { + "type": "boolean", + "description": "Indicates if the fee is included in the transaction amount." + } + } + } + }, + "gasCosts": { + "type": "array", + "description": "A collection of estimated gas costs for executing the transaction.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type of the gas cost.", + "example": "SEND" + }, + "price": { + "type": "string", + "description": "The gas price, specified as a string to maintain precision.", + "example": "19236858243" + }, + "estimate": { + "type": "string", + "description": "The estimated gas required, specified as a string to maintain precision.", + "example": "445393" + }, + "limit": { + "type": "string", + "description": "The gas limit for the transaction, specified as a string to maintain precision.", + "example": "579011", + "pattern": "^[1-9][0-9]*$" + }, + "amount": { + "type": "string", + "description": "The amount of gas required in the gas currency.", + "example": "8567962003424499", + "pattern": "^[1-9][0-9]*$" + }, + "amountUSD": { + "type": "string", + "description": "The amount of gas required in USD.", + "example": "16.05", + "pattern": "^(0(\\.[0-9]+)?|[1-9][0-9]*(\\.[0-9]+)?)$" + }, + "token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + } + } + } + }, + "executionDuration": { + "type": "integer", + "description": "The estimated duration for the transaction execution in seconds.", + "example": 30 + }, + "fromAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "tool": { + "type": "string", + "description": "The tool or service used to generate this estimate.", + "example": "satp" + } + } + }, + "toolDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "integrationDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "includedStepIds": { + "type": "array", + "description": "IDs of further steps included within this step, allowing for nested actions without direct recursion.", + "items": { + "type": "string" + } + } + } + }, + "Insurance": { + "type": "object", + "properties": { + "state": { + "type": "string", + "description": "The state of insurance applicability for the transaction.", + "example": "NOT_INSURABLE", + "enum": [ + "NOT_INSURABLE", + "INSURABLE", + "INSURED" + ] + }, + "feeAmountUsd": { + "type": "string", + "description": "The fee amount for insurance, represented in USD.", + "example": "10.00", + "pattern": "^(0|[1-9]\\d*)(\\.\\d+)?$" + } + } + }, + "Action": { + "type": "object", + "properties": { + "fromToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "fromAmount": { + "type": "string", + "description": "The amount of 'fromToken' to be transferred, specified as a string to maintain precision.", + "example": "1000000000000000000", + "pattern": "^[1-9][0-9]*$" + }, + "toToken": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + }, + "slippage": { + "type": "number", + "format": "float", + "description": "The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer.", + "example": 0.005 + }, + "fromAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + } + } + }, + "IntegrationDetails": { + "type": "object", + "description": "Describes integration or tool details such as bridges or exchanges involved in the transaction.", + "required": [ + "key", + "name", + "logoURI" + ], + "properties": { + "key": { + "type": "string", + "description": "A unique identifier for the integration or tool.", + "example": "1inch" + }, + "name": { + "type": "string", + "description": "The name of the integration or tool.", + "example": "1inch Exchange" + }, + "logoURI": { + "type": "string", + "format": "uri", + "description": "URL to the logo of the integration or tool.", + "example": "https://cdn.example.com/logos/1inch.png" + } + } + }, + "Estimate": { + "type": "object", + "description": "Provides an estimation for a transaction, including costs, amounts, and execution duration.", + "properties": { + "approvalAddress": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "toAmountMin": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "fromAmount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "feeCosts": { + "type": "array", + "description": "A collection of fee costs associated with the transaction.", + "items": { + "type": "object", + "description": "Details about a specific fee cost associated with the transaction.", + "properties": { + "name": { + "type": "string", + "description": "Name of the fee cost.", + "example": "Network Fee" + }, + "amount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "amountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "token": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "included": { + "type": "boolean", + "description": "Indicates if the fee is included in the transaction amount." + } + } + } + }, + "gasCosts": { + "type": "array", + "description": "A collection of estimated gas costs for executing the transaction.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type of the gas cost.", + "example": "SEND" + }, + "price": { + "type": "string", + "description": "The gas price, specified as a string to maintain precision.", + "example": "19236858243" + }, + "estimate": { + "type": "string", + "description": "The estimated gas required, specified as a string to maintain precision.", + "example": "445393" + }, + "limit": { + "type": "string", + "description": "The gas limit for the transaction, specified as a string to maintain precision.", + "example": "579011", + "pattern": "^[1-9][0-9]*$" + }, + "amount": { + "type": "string", + "description": "The amount of gas required in the gas currency.", + "example": "8567962003424499", + "pattern": "^[1-9][0-9]*$" + }, + "amountUSD": { + "type": "string", + "description": "The amount of gas required in USD.", + "example": "16.05", + "pattern": "^(0(\\.[0-9]+)?|[1-9][0-9]*(\\.[0-9]+)?)$" + }, + "token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + } + } + } + }, + "executionDuration": { + "type": "integer", + "description": "The estimated duration for the transaction execution in seconds.", + "example": 30 + }, + "fromAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "toAmountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "tool": { + "type": "string", + "description": "The tool or service used to generate this estimate.", + "example": "satp" + } + } + }, + "FeeCost": { + "type": "object", + "description": "Details about a specific fee cost associated with the transaction.", + "properties": { + "name": { + "type": "string", + "description": "Name of the fee cost.", + "example": "Network Fee" + }, + "amount": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "amountUSD": { + "type": "string", + "description": "The amount in string format including all decimals.", + "pattern": "^([1-9][0-9]*|0)(\\.[0-9]+)?$", + "example": "1000000000000000000" + }, + "token": { + "type": "string", + "description": "The symbol of a token", + "example": "ETH" + }, + "included": { + "type": "boolean", + "description": "Indicates if the fee is included in the transaction amount." + } + } + }, + "GasCost": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type of the gas cost.", + "example": "SEND" + }, + "price": { + "type": "string", + "description": "The gas price, specified as a string to maintain precision.", + "example": "19236858243" + }, + "estimate": { + "type": "string", + "description": "The estimated gas required, specified as a string to maintain precision.", + "example": "445393" + }, + "limit": { + "type": "string", + "description": "The gas limit for the transaction, specified as a string to maintain precision.", + "example": "579011", + "pattern": "^[1-9][0-9]*$" + }, + "amount": { + "type": "string", + "description": "The amount of gas required in the gas currency.", + "example": "8567962003424499", + "pattern": "^[1-9][0-9]*$" + }, + "amountUSD": { + "type": "string", + "description": "The amount of gas required in USD.", + "example": "16.05", + "pattern": "^(0(\\.[0-9]+)?|[1-9][0-9]*(\\.[0-9]+)?)$" + }, + "token": { + "type": "object", + "description": "Metadata detailing a supported token", + "required": [ + "chainID", + "chainType", + "address", + "symbol", + "decimals" + ], + "properties": { + "chainID": { + "x-category": "satp-core", + "type": "string", + "description": "The network of the DLT being interacted with. TODO: implement network identification draft" + }, + "chainType": { + "x-category": "satp-core", + "type": "string", + "enum": [ + "HyperledgerFabric", + "HyperledgerBesu" + ], + "description": "Supported DLT protocols." + }, + "address": { + "type": "string", + "description": "A blockchain address.", + "example": "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" + }, + "name": { + "type": "string", + "description": "The name of the token." + }, + "symbol": { + "type": "string", + "description": "The symbol of the token." + }, + "decimals": { + "type": "integer", + "description": "How many decimals the token supports.", + "minimum": 1 + }, + "logoURI": { + "type": "string", + "description": "The logo of a token, chain, dex etc.", + "format": "uri" + }, + "tags": { + "title": "Tags", + "type": "array", + "description": "List of tags identifiers providing additional context or categorization.", + "items": { + "type": "string" + }, + "example": [ + "satp", + "hyperledger" + ] + }, + "priceUSD": { + "type": "string", + "description": "The current price of the token in USD." + }, + "extensions": { + "type": "object", + "properties": { + "bridgeInfo": { + "type": "object", + "additionalProperties": { + "type": "object", + "description": "Information about the bridge used for the token transfer.", + "properties": { + "tokenAddress": { + "type": "string", + "description": "The address of the token being transferred.", + "example": "0x..." + } + } + } + }, + "verified": { + "type": "boolean", + "description": "Indicates whether the token is verified." + } + } + } + } + } + } + } + } + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/json/openapi-gateway-bundled.json b/packages/cactus-plugin-satp-hermes/src/main/json/openapi-gateway-bundled.json new file mode 100644 index 0000000000..a627a5dd37 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/json/openapi-gateway-bundled.json @@ -0,0 +1,3259 @@ +{ + "openapi": "3.0.3", + "info": { + "title": "Hyperledger Cactus Plugin - Odap Hermes", + "description": "Implementation for Odap and Hermes", + "version": "v2.0.0-alpha.2", + "license": { + "name": "Apache-2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" + } + }, + "components": { + "schemas": { + "CredentialProfile": { + "type": "string", + "enum": [ + "SAML", + "OAUTH", + "X509" + ] + }, + "PayloadProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "ApplicationProfile": { + "type": "object" + }, + "Payload": { + "type": "object" + }, + "AssetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "LoggingProfile": { + "type": "array", + "items": { + "type": "string" + } + }, + "AccessControlProfile": { + "type": "array", + "items": { + "type": "string" + } + }, + "Permissions": { + "type": "object" + }, + "Transaction": { + "type": "object" + }, + "ActionCategory": { + "type": "object" + }, + "History": { + "type": "object", + "properties": { + "Transactions": { + "type": "array", + "items": { + "type": "object" + } + }, + "Actions": { + "type": "array", + "items": { + "type": "object" + } + }, + "Origin": { + "type": "string" + }, + "Destination": { + "type": "string" + }, + "Balance": { + "type": "string" + }, + "CurrentStatus": { + "type": "object" + }, + "ApplicationSpecificParameters": { + "type": "object" + } + } + }, + "SenderDltSystem": { + "type": "object" + }, + "RecipientDltSystem": { + "type": "object" + }, + "LockEvidenceClaim": { + "type": "object" + }, + "LockClaimFormat": { + "type": "object" + }, + "CommitFinalClaim": { + "type": "object" + }, + "CommitFinalClaimFormat": { + "type": "object" + }, + "CommitAcknowledgementClaim": { + "type": "object" + }, + "CommitAcknowledgementClaimFormat": { + "type": "object" + }, + "SessionData": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "step": { + "type": "number" + }, + "version": { + "type": "string" + }, + "lastSequenceNumber": { + "type": "number" + }, + "loggingProfile": { + "type": "string" + }, + "accessControlProfile": { + "type": "string" + }, + "applicationProfile": { + "type": "string" + }, + "payloadProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "allowedSourceBackupGateways": { + "type": "array", + "items": { + "type": "string" + } + }, + "allowedRecipientBackupGateways": { + "type": "array", + "items": { + "type": "string" + } + }, + "sourceBasePath": { + "type": "string" + }, + "recipientBasePath": { + "type": "string" + }, + "originatorPubkey": { + "type": "string" + }, + "beneficiaryPubkey": { + "type": "string" + }, + "sourceGatewayPubkey": { + "type": "string" + }, + "sourceGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayPubkey": { + "type": "string" + }, + "recipientGatewayDltSystem": { + "type": "string" + }, + "initializationRequestMessageHash": { + "type": "string" + }, + "initializationResponseMessageHash": { + "type": "string" + }, + "initializationRequestMessageRcvTimeStamp": { + "type": "string" + }, + "initializationRequestMessageProcessedTimeStamp": { + "type": "string" + }, + "clientSignatureInitializationRequestMessage": { + "type": "string" + }, + "serverSignatureInitializationResponseMessage": { + "type": "string" + }, + "transferCommenceMessageRequestHash": { + "type": "string" + }, + "transferCommenceMessageResponseHash": { + "type": "string" + }, + "clientSignatureTransferCommenceRequestMessage": { + "type": "string" + }, + "serverSignatureTransferCommenceResponseMessage": { + "type": "string" + }, + "lockEvidenceRequestMessageHash": { + "type": "string" + }, + "lockEvidenceResponseMessageHash": { + "type": "string" + }, + "clientSignatureLockEvidenceRequestMessage": { + "type": "string" + }, + "serverSignatureLockEvidenceResponseMessage": { + "type": "string" + }, + "lockEvidenceClaim": { + "type": "string" + }, + "commitPrepareRequestMessageHash": { + "type": "string" + }, + "commitPrepareResponseMessageHash": { + "type": "string" + }, + "clientSignatureCommitPreparationRequestMessage": { + "type": "string" + }, + "serverSignatureCommitPreparationResponseMessage": { + "type": "string" + }, + "commitFinalRequestMessageHash": { + "type": "string" + }, + "commitFinalResponseMessageHash": { + "type": "string" + }, + "commitFinalClaim": { + "type": "string" + }, + "commitFinalClaimFormat": { + "type": "string" + }, + "commitAcknowledgementClaim": { + "type": "string" + }, + "commitAcknowledgementClaimFormat": { + "type": "string" + }, + "clientSignatureCommitFinalRequestMessage": { + "type": "string" + }, + "serverSignatureCommitFinalResponseMessage": { + "type": "string" + }, + "transferCompleteMessageHash": { + "type": "string" + }, + "clientSignatureTransferCompleteMessage": { + "type": "string" + }, + "maxRetries": { + "type": "number" + }, + "recipientLedgerAssetID": { + "type": "string" + }, + "sourceLedgerAssetID": { + "type": "string" + }, + "maxTimeout": { + "type": "number" + }, + "lastLogEntryTimestamp": { + "type": "string" + }, + "unlockAssetClaim": { + "type": "string" + }, + "recreateAssetClaim": { + "type": "string" + }, + "deleteAssetClaim": { + "type": "string" + }, + "lastMessageReceivedTimestamp": { + "type": "string" + }, + "rollback": { + "type": "boolean" + }, + "rollbackMessageHash": { + "type": "string" + }, + "rollbackProofs": { + "type": "array", + "items": { + "type": "string" + } + }, + "rollbackActionsPerformed": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "CREATE", + "DELETE", + "LOCK", + "UNLOCK" + ] + } + } + } + }, + "TransferInitializationV1Request": { + "type": "object", + "properties": { + "messageType": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "version": { + "type": "string" + }, + "developerURN": { + "type": "string" + }, + "credentialProfile": { + "type": "string", + "enum": [ + "SAML", + "OAUTH", + "X509" + ] + }, + "payloadProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "applicationProfile": { + "type": "string" + }, + "loggingProfile": { + "type": "string" + }, + "accessControlProfile": { + "type": "string" + }, + "signature": { + "type": "string" + }, + "sourceGatewayPubkey": { + "type": "string" + }, + "sourceGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayPubkey": { + "type": "string" + }, + "recipientGatewayDltSystem": { + "type": "string" + }, + "escrowType": { + "type": "string", + "enum": [ + "FAUCET", + "TIMELOCK", + "HASHLOCK", + "HASHTIMELOCK", + "MULTICLAIMPC", + "DESTROY", + "BURN" + ] + }, + "expiryTime": { + "type": "string" + }, + "multipleClaimsAllowed": { + "type": "boolean" + }, + "multipleCancelsAllowed": { + "type": "boolean" + }, + "permissions": { + "type": "object" + }, + "origin": { + "type": "string" + }, + "destination": { + "type": "string" + }, + "subsequentCalls": { + "type": "object" + }, + "histories": { + "type": "array", + "items": { + "type": "object", + "properties": { + "Transactions": { + "type": "array", + "items": { + "type": "object" + } + }, + "Actions": { + "type": "array", + "items": { + "type": "object" + } + }, + "Origin": { + "type": "string" + }, + "Destination": { + "type": "string" + }, + "Balance": { + "type": "string" + }, + "CurrentStatus": { + "type": "object" + }, + "ApplicationSpecificParameters": { + "type": "object" + } + } + } + }, + "sequenceNumber": { + "type": "integer" + }, + "sourceBasePath": { + "type": "string" + }, + "recipientBasePath": { + "type": "string" + }, + "maxRetries": { + "type": "number" + }, + "maxTimeout": { + "type": "number" + }, + "backupGatewaysAllowed": { + "type": "array", + "items": { + "type": "string" + } + }, + "recipientLedgerAssetID": { + "type": "string" + }, + "sourceLedgerAssetID": { + "type": "string" + } + }, + "required": [ + "messageType", + "sessionID", + "loggingProfile", + "accessControlProfile", + "payloadProfile", + "applicationProfile", + "signature", + "sourceGatewayPubkey", + "sourceGatewayDltSystem", + "recipientGatewayPubkey", + "recipientGatewayDltSystem", + "sequenceNumber", + "sourceBasePath", + "recipientBasePath", + "maxRetries", + "maxTimeout", + "backupGatewaysAllowed", + "recipientLedgerAssetID", + "sourceLedgerAssetID" + ] + }, + "TransferInitializationV1Response": { + "type": "object", + "properties": { + "messageType": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + }, + "odapPhase": { + "type": "string", + "enum": [ + "TransferInitialization", + "LockEvidenceVerification", + "CommitmentEstablishment" + ] + }, + "initialRequestMessageHash": { + "type": "string" + }, + "destination": { + "type": "string" + }, + "timeStamp": { + "type": "string" + }, + "processedTimeStamp": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "signature": { + "type": "string" + }, + "backupGatewaysAllowed": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "messageType", + "initialRequestMessageHash", + "timeStamp", + "processedTimeStamp", + "sessionID", + "serverIdentityPubkey", + "sequenceNumber", + "signature", + "backupGatewaysAllowed" + ] + }, + "TransferCommenceV1Request": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "originatorPubkey": { + "type": "string" + }, + "beneficiaryPubkey": { + "type": "string" + }, + "senderDltSystem": { + "type": "string" + }, + "recipientDltSystem": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashAssetProfile": { + "type": "string" + }, + "assetUnit": { + "type": "integer" + }, + "hashPrevMessage": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "integer" + } + }, + "required": [ + "sessionID", + "messageType", + "originatorPubkey", + "beneficiaryPubkey", + "senderDltSystem", + "recipientDltSystem", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashAssetProfile", + "hashPrevMessage", + "signature", + "sequenceNumber" + ] + }, + "TransferCommenceV1Response": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashCommenceRequest": { + "type": "string" + }, + "serverTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "messageHash": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "serverIdentityPubkey", + "clientIdentityPubkey", + "hashCommenceRequest", + "signature", + "sequenceNumber" + ] + }, + "LockEvidenceV1Request": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "lockEvidenceClaim": { + "type": "string" + }, + "lockEvidenceFormat": { + "nullable": true, + "type": "object" + }, + "lockEvidenceExpiration": { + "type": "string" + }, + "hashCommenceAckRequest": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "messageHash": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "lockEvidenceClaim", + "lockEvidenceExpiration", + "hashCommenceAckRequest", + "signature", + "sequenceNumber" + ] + }, + "LockEvidenceV1Response": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashLockEvidenceRequest": { + "type": "string" + }, + "serverTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashLockEvidenceRequest", + "signature", + "sequenceNumber" + ] + }, + "CommitPreparationV1Request": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashLockEvidenceAck": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer" + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashLockEvidenceAck", + "signature", + "sequenceNumber" + ] + }, + "CommitPreparationV1Response": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashCommitPrep": { + "type": "string" + }, + "serverTransferNumber": { + "type": "string" + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashCommitPrep", + "signature", + "sequenceNumber" + ] + }, + "CommitFinalV1Request": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "commitFinalClaim": { + "type": "string" + }, + "commitFinalClaimFormat": { + "type": "object" + }, + "hashCommitPrepareAck": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "commitFinalClaim", + "hashCommitPrepareAck", + "signature", + "sequenceNumber" + ] + }, + "CommitFinalV1Response": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "commitAcknowledgementClaim": { + "type": "string" + }, + "commitAcknowledgementClaimFormat": { + "type": "object" + }, + "hashCommitFinal": { + "type": "string" + }, + "serverTransferNumber": { + "type": "integer" + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "commitAcknowledgementClaim", + "hashCommitFinal", + "signature", + "sequenceNumber" + ] + }, + "TransferCompleteV1Request": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashCommitFinalAck": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "hashTransferCommence": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashCommitFinalAck", + "signature", + "hashTransferCommence", + "sequenceNumber" + ] + }, + "ClientV1Request": { + "type": "object", + "properties": { + "version": { + "type": "string" + }, + "loggingProfile": { + "type": "string" + }, + "accessControlProfile": { + "type": "string" + }, + "assetControlProfile": { + "type": "string" + }, + "applicationProfile": { + "type": "string" + }, + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "payloadProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "sourceGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayPubkey": { + "type": "string" + }, + "originatorPubkey": { + "type": "string" + }, + "beneficiaryPubkey": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "clientDltSystem": { + "type": "string" + }, + "serverDltSystem": { + "type": "string" + }, + "clientGatewayConfiguration": { + "type": "object", + "properties": { + "apiHost": { + "type": "string" + } + }, + "required": [ + "apiHost" + ] + }, + "serverGatewayConfiguration": { + "type": "object", + "properties": { + "apiHost": { + "type": "string" + } + }, + "required": [ + "apiHost" + ] + }, + "maxRetries": { + "type": "number" + }, + "maxTimeout": { + "type": "number" + }, + "sourceLedgerAssetID": { + "type": "string" + }, + "recipientLedgerAssetID": { + "type": "string" + } + }, + "required": [ + "version", + "loggingProfile", + "accessControlProfile", + "assetControlProfile", + "applicationProfile", + "assetProfile", + "payloadProfile", + "sourceGatewayDltSystem", + "recipientGatewayDltSystem", + "recipientGatewayPubkey", + "originatorPubkey", + "beneficiaryPubkey", + "clientIdentityPubkey", + "serverIdentityPubkey", + "clientDltSystem", + "serverDltSystem", + "clientGatewayConfiguration", + "serverGatewayConfiguration", + "maxRetries", + "maxTimeout", + "sourceLedgerAssetID", + "recipientLedgerAssetID" + ] + }, + "RecoverV1Message": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "odapPhase": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + }, + "lastLogEntryTimestamp": { + "type": "string" + }, + "isBackup": { + "type": "boolean" + }, + "newBasePath": { + "type": "string" + }, + "newGatewayPubKey": { + "type": "string" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "odapPhase", + "sequenceNumber", + "lastLogEntryTimestamp", + "isBackup", + "newBasePath", + "signature" + ] + }, + "RecoverUpdateV1Message": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "recoveredLogs": { + "type": "array", + "items": { + "type": "object", + "properties": { + "key": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "data": { + "type": "string" + }, + "type": { + "type": "string" + }, + "operation": { + "type": "string" + }, + "timestamp": { + "type": "string" + } + }, + "required": [ + "sessionID", + "type", + "operation" + ] + } + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "recoveredLogs", + "signature" + ] + }, + "RecoverUpdateAckV1Message": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "changedEntriesHash": { + "type": "array", + "items": { + "type": "string" + } + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "changedEntriesHash", + "signature" + ] + }, + "RecoverSuccessV1Message": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "signature" + ] + }, + "RollbackV1Message": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "actionPerformed": { + "type": "array", + "items": { + "type": "string" + } + }, + "proofs": { + "type": "array", + "items": { + "type": "string" + } + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "actionPerformed", + "proofs", + "signature" + ] + }, + "RollbackAckV1Message": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "signature" + ] + }, + "LocalLog": { + "type": "object", + "properties": { + "key": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "data": { + "type": "string" + }, + "type": { + "type": "string" + }, + "operation": { + "type": "string" + }, + "timestamp": { + "type": "string" + } + }, + "required": [ + "sessionID", + "type", + "operation" + ] + }, + "SatpMessage": { + "type": "object", + "properties": { + "SequenceNumber": { + "type": "number" + }, + "Phase": { + "type": "string", + "enum": [ + "TransferInitialization", + "LockEvidenceVerification", + "CommitmentEstablishment" + ] + }, + "ResourceURL": { + "type": "string" + }, + "DeveloperURN": { + "type": "string" + }, + "ActionResponse": { + "type": "object", + "properties": { + "ResponseCode": { + "type": "string", + "enum": [ + "200", + "404" + ], + "x-enum-varnames": [ + "OK", + "RESOURCE_NOT_FOUND" + ] + }, + "Arguments": { + "type": "array", + "items": {} + } + } + }, + "CredentialProfile": { + "type": "string", + "enum": [ + "SAML", + "OAuth", + "X509" + ] + }, + "CredentialBlock": { + "type": "array", + "items": {} + }, + "CredentialsProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "ApplicationProfile": { + "type": "object" + }, + "Payload": { + "type": "object" + }, + "PayloadHash": { + "type": "string" + }, + "MessageSignature": { + "type": "string" + } + } + } + } + }, + "paths": { + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationrequest": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationrequest" + } + }, + "operationId": "phase1TransferInitiationRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "messageType": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "version": { + "type": "string" + }, + "developerURN": { + "type": "string" + }, + "credentialProfile": { + "type": "string", + "enum": [ + "SAML", + "OAUTH", + "X509" + ] + }, + "payloadProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "applicationProfile": { + "type": "string" + }, + "loggingProfile": { + "type": "string" + }, + "accessControlProfile": { + "type": "string" + }, + "signature": { + "type": "string" + }, + "sourceGatewayPubkey": { + "type": "string" + }, + "sourceGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayPubkey": { + "type": "string" + }, + "recipientGatewayDltSystem": { + "type": "string" + }, + "escrowType": { + "type": "string", + "enum": [ + "FAUCET", + "TIMELOCK", + "HASHLOCK", + "HASHTIMELOCK", + "MULTICLAIMPC", + "DESTROY", + "BURN" + ] + }, + "expiryTime": { + "type": "string" + }, + "multipleClaimsAllowed": { + "type": "boolean" + }, + "multipleCancelsAllowed": { + "type": "boolean" + }, + "permissions": { + "type": "object" + }, + "origin": { + "type": "string" + }, + "destination": { + "type": "string" + }, + "subsequentCalls": { + "type": "object" + }, + "histories": { + "type": "array", + "items": { + "type": "object", + "properties": { + "Transactions": { + "type": "array", + "items": { + "type": "object" + } + }, + "Actions": { + "type": "array", + "items": { + "type": "object" + } + }, + "Origin": { + "type": "string" + }, + "Destination": { + "type": "string" + }, + "Balance": { + "type": "string" + }, + "CurrentStatus": { + "type": "object" + }, + "ApplicationSpecificParameters": { + "type": "object" + } + } + } + }, + "sequenceNumber": { + "type": "integer" + }, + "sourceBasePath": { + "type": "string" + }, + "recipientBasePath": { + "type": "string" + }, + "maxRetries": { + "type": "number" + }, + "maxTimeout": { + "type": "number" + }, + "backupGatewaysAllowed": { + "type": "array", + "items": { + "type": "string" + } + }, + "recipientLedgerAssetID": { + "type": "string" + }, + "sourceLedgerAssetID": { + "type": "string" + } + }, + "required": [ + "messageType", + "sessionID", + "loggingProfile", + "accessControlProfile", + "payloadProfile", + "applicationProfile", + "signature", + "sourceGatewayPubkey", + "sourceGatewayDltSystem", + "recipientGatewayPubkey", + "recipientGatewayDltSystem", + "sequenceNumber", + "sourceBasePath", + "recipientBasePath", + "maxRetries", + "maxTimeout", + "backupGatewaysAllowed", + "recipientLedgerAssetID", + "sourceLedgerAssetID" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommencerequest": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommencerequest" + } + }, + "operationId": "phase2TransferCommenceRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "originatorPubkey": { + "type": "string" + }, + "beneficiaryPubkey": { + "type": "string" + }, + "senderDltSystem": { + "type": "string" + }, + "recipientDltSystem": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashAssetProfile": { + "type": "string" + }, + "assetUnit": { + "type": "integer" + }, + "hashPrevMessage": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "integer" + } + }, + "required": [ + "sessionID", + "messageType", + "originatorPubkey", + "beneficiaryPubkey", + "senderDltSystem", + "recipientDltSystem", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashAssetProfile", + "hashPrevMessage", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidencerequest": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidencerequest" + } + }, + "operationId": "phase2LockEvidenceRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "lockEvidenceClaim": { + "type": "string" + }, + "lockEvidenceFormat": { + "nullable": true, + "type": "object" + }, + "lockEvidenceExpiration": { + "type": "string" + }, + "hashCommenceAckRequest": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "messageHash": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "lockEvidenceClaim", + "lockEvidenceExpiration", + "hashCommenceAckRequest", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationrequest": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationrequest" + } + }, + "operationId": "phase3CommitPreparationRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashLockEvidenceAck": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer" + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashLockEvidenceAck", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalrequest": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalrequest" + } + }, + "operationId": "phase3CommitFinalRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "commitFinalClaim": { + "type": "string" + }, + "commitFinalClaimFormat": { + "type": "object" + }, + "hashCommitPrepareAck": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "commitFinalClaim", + "hashCommitPrepareAck", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/transfercompleterequest": { + "get": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "get", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/transfercompleterequest" + } + }, + "operationId": "phase3TransferCompleteRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashCommitFinalAck": { + "type": "string" + }, + "clientTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "hashTransferCommence": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashCommitFinalAck", + "signature", + "hashTransferCommence", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/clientrequest": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/clientrequest" + } + }, + "operationId": "clientRequestV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "version": { + "type": "string" + }, + "loggingProfile": { + "type": "string" + }, + "accessControlProfile": { + "type": "string" + }, + "assetControlProfile": { + "type": "string" + }, + "applicationProfile": { + "type": "string" + }, + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "payloadProfile": { + "type": "object", + "properties": { + "assetProfile": { + "type": "object", + "properties": { + "issuer": { + "type": "string" + }, + "assetCode": { + "type": "string" + }, + "assetCodeType": { + "type": "string" + }, + "issuanceDate": { + "type": "string" + }, + "expirationDate": { + "type": "string" + }, + "verificationEndPoint": { + "type": "string" + }, + "digitalSignature": { + "type": "string" + }, + "prospectusLink": { + "type": "string" + }, + "keyInformationLink": { + "type": "array", + "items": {} + }, + "keyWord": { + "type": "array", + "items": {} + }, + "transferRestriction": { + "type": "array", + "items": {} + }, + "ledgerRequirements": { + "type": "array", + "items": {} + } + }, + "required": [ + "expirationDate" + ] + }, + "capabilities": { + "type": "string" + } + }, + "required": [ + "assetProfile" + ] + }, + "sourceGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayDltSystem": { + "type": "string" + }, + "recipientGatewayPubkey": { + "type": "string" + }, + "originatorPubkey": { + "type": "string" + }, + "beneficiaryPubkey": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "clientDltSystem": { + "type": "string" + }, + "serverDltSystem": { + "type": "string" + }, + "clientGatewayConfiguration": { + "type": "object", + "properties": { + "apiHost": { + "type": "string" + } + }, + "required": [ + "apiHost" + ] + }, + "serverGatewayConfiguration": { + "type": "object", + "properties": { + "apiHost": { + "type": "string" + } + }, + "required": [ + "apiHost" + ] + }, + "maxRetries": { + "type": "number" + }, + "maxTimeout": { + "type": "number" + }, + "sourceLedgerAssetID": { + "type": "string" + }, + "recipientLedgerAssetID": { + "type": "string" + } + }, + "required": [ + "version", + "loggingProfile", + "accessControlProfile", + "assetControlProfile", + "applicationProfile", + "assetProfile", + "payloadProfile", + "sourceGatewayDltSystem", + "recipientGatewayDltSystem", + "recipientGatewayPubkey", + "originatorPubkey", + "beneficiaryPubkey", + "clientIdentityPubkey", + "serverIdentityPubkey", + "clientDltSystem", + "serverDltSystem", + "clientGatewayConfiguration", + "serverGatewayConfiguration", + "maxRetries", + "maxTimeout", + "sourceLedgerAssetID", + "recipientLedgerAssetID" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": {} + } + } + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationresponse": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationresponse" + } + }, + "operationId": "phase1TransferInitiationResponseV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "messageType": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + }, + "odapPhase": { + "type": "string", + "enum": [ + "TransferInitialization", + "LockEvidenceVerification", + "CommitmentEstablishment" + ] + }, + "initialRequestMessageHash": { + "type": "string" + }, + "destination": { + "type": "string" + }, + "timeStamp": { + "type": "string" + }, + "processedTimeStamp": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "signature": { + "type": "string" + }, + "backupGatewaysAllowed": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "messageType", + "initialRequestMessageHash", + "timeStamp", + "processedTimeStamp", + "sessionID", + "serverIdentityPubkey", + "sequenceNumber", + "signature", + "backupGatewaysAllowed" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommenceresponse": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommenceresponse" + } + }, + "operationId": "phase2TransferCommenceResponseV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashCommenceRequest": { + "type": "string" + }, + "serverTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "messageHash": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "serverIdentityPubkey", + "clientIdentityPubkey", + "hashCommenceRequest", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidenceresponse": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidenceresponse" + } + }, + "operationId": "phase2LockEvidenceResponseV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashLockEvidenceRequest": { + "type": "string" + }, + "serverTransferNumber": { + "type": "integer", + "nullable": true + }, + "signature": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashLockEvidenceRequest", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationresponse": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationresponse" + } + }, + "operationId": "phase3CommitPreparationResponseV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "hashCommitPrep": { + "type": "string" + }, + "serverTransferNumber": { + "type": "string" + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "hashCommitPrep", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalresponse": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalresponse" + } + }, + "operationId": "phase3CommitFinalResponseV1", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "messageType": { + "type": "string" + }, + "clientIdentityPubkey": { + "type": "string" + }, + "serverIdentityPubkey": { + "type": "string" + }, + "commitAcknowledgementClaim": { + "type": "string" + }, + "commitAcknowledgementClaimFormat": { + "type": "object" + }, + "hashCommitFinal": { + "type": "string" + }, + "serverTransferNumber": { + "type": "integer" + }, + "signature": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + } + }, + "required": [ + "sessionID", + "messageType", + "clientIdentityPubkey", + "serverIdentityPubkey", + "commitAcknowledgementClaim", + "hashCommitFinal", + "signature", + "sequenceNumber" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recovermessage": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recovermessage" + } + }, + "operationId": "RecoverV1Message", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "odapPhase": { + "type": "string" + }, + "sequenceNumber": { + "type": "number" + }, + "lastLogEntryTimestamp": { + "type": "string" + }, + "isBackup": { + "type": "boolean" + }, + "newBasePath": { + "type": "string" + }, + "newGatewayPubKey": { + "type": "string" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "odapPhase", + "sequenceNumber", + "lastLogEntryTimestamp", + "isBackup", + "newBasePath", + "signature" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdatemessage": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdatemessage" + } + }, + "operationId": "RecoverUpdateV1Message", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "recoveredLogs": { + "type": "array", + "items": { + "type": "object", + "properties": { + "key": { + "type": "string" + }, + "sessionID": { + "type": "string" + }, + "data": { + "type": "string" + }, + "type": { + "type": "string" + }, + "operation": { + "type": "string" + }, + "timestamp": { + "type": "string" + } + }, + "required": [ + "sessionID", + "type", + "operation" + ] + } + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "recoveredLogs", + "signature" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdateackmessage": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdateackmessage" + } + }, + "operationId": "RecoverUpdateAckV1Message", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "changedEntriesHash": { + "type": "array", + "items": { + "type": "string" + } + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "changedEntriesHash", + "signature" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoversuccessmessage": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoversuccessmessage" + } + }, + "operationId": "RecoverV1Success", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "signature" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackmessage": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackmessage" + } + }, + "operationId": "RollbackV1Message", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "actionPerformed": { + "type": "array", + "items": { + "type": "string" + } + }, + "proofs": { + "type": "array", + "items": { + "type": "string" + } + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "actionPerformed", + "proofs", + "signature" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + }, + "/api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackackmessage": { + "post": { + "x-hyperledger-cacti": { + "http": { + "verbLowerCase": "post", + "path": "/api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackackmessage" + } + }, + "operationId": "RollbackAckV1Message", + "description": "", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "sessionID": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "sessionID", + "success", + "signature" + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK" + } + } + } + } + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-audit-handler-service.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-audit-handler-service.ts new file mode 100644 index 0000000000..65b3dba385 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-audit-handler-service.ts @@ -0,0 +1 @@ +// todo diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-status-handler-service.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-status-handler-service.ts new file mode 100644 index 0000000000..68bffe6a9b --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/admin/get-status-handler-service.ts @@ -0,0 +1,62 @@ +import { GetStatusError } from "../../core/errors"; +import { + StatusRequest, + StatusResponse, + Transact200ResponseStatusResponseOriginChain, +} from "../../generated/openapi-blo/typescript-axios"; +import { Logger } from "@hyperledger/cactus-common"; + +export async function GetStatusHandler( + logger: Logger, + req: StatusRequest, +): Promise { + const fnTag = `GetStatusHandler`; + logger.info(`${fnTag}, Obtaining status for sessionID=${req.sessionID}`); + + try { + const processedRequest = req; + const result = await GetStatusService(logger, processedRequest); + return result; + } catch (error) { + if (error instanceof GetStatusError) { + logger.error(`${fnTag}, Error getting status: ${error.message}`); + throw error; + } else { + logger.error(`${fnTag}, Unexpected error: ${error.message}`); + throw new Error("An unexpected error occurred while obtaining status."); + } + } +} + +// TODO call SATP core, use try catch to propagate errors +export async function GetStatusService( + logger: Logger, + req: StatusRequest, +): Promise { + // Implement the logic for getting status here; call core + const originChain: Transact200ResponseStatusResponseOriginChain = { + dltProtocol: "besu", + dltSubnetworkID: "v24.4.0-RC1", + }; + + const destinationChain: Transact200ResponseStatusResponseOriginChain = { + dltProtocol: "fabric", + dltSubnetworkID: "v2.0.0", + }; + + const mock: StatusResponse = { + status: "DONE", + substatus: "COMPLETED", + stage: "STAGE3", + step: "transfer-complete-message", + startTime: "2023-03-14T16:50:06.662Z", + originChain: originChain, + destinationChain: destinationChain, + }; + + logger.info(req); + // logger.error("GetStatusService not implemented"); + // throw new GetStatusError(req.sessionID, "GetStatusService not implemented"); + + return mock; +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/dispatcher.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/dispatcher.ts new file mode 100644 index 0000000000..2510fb0a8d --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/dispatcher.ts @@ -0,0 +1,72 @@ +import { + Logger, + Checks, + LogLevelDesc, + LoggerProvider, +} from "@hyperledger/cactus-common"; + +import { IWebServiceEndpoint } from "@hyperledger/cactus-core-api"; + +//import { GatewayIdentity, GatewayChannel } from "../core/types"; +//import { GetStatusError, NonExistantGatewayIdentity } from "../core/errors"; +import { GetStatusEndpointV1 } from "../web-services/blo/status-endpoint"; + +//import { GetAuditRequest, GetAuditResponse } from "../generated/openapi-blo/typescript-axios"; +import { + StatusRequest, + StatusResponse, +} from "../generated/openapi-blo/typescript-axios"; +import { GetStatusHandler } from "./admin/get-status-handler-service"; + +export interface BLODispatcherOptions { + logger: Logger; + logLevel?: LogLevelDesc; + instanceId: string; +} + +export class BLODispatcher { + public static readonly CLASS_NAME = "BLODispatcher"; + private readonly logger: Logger; + private endpoints: IWebServiceEndpoint[] | undefined; + private readonly instanceId: string; + + constructor(public readonly options: BLODispatcherOptions) { + const fnTag = `${BLODispatcher.CLASS_NAME}#constructor()`; + Checks.truthy(options, `${fnTag} arg options`); + + const level = this.options.logLevel || "INFO"; + const label = this.className; + this.logger = LoggerProvider.getOrCreate({ level, label }); + this.instanceId = options.instanceId; + this.logger.info(`Instantiated ${this.className} OK`); + } + + public get className(): string { + return BLODispatcher.CLASS_NAME; + } + + public async getOrCreateWebServices(): Promise { + const fnTag = `${BLODispatcher.CLASS_NAME}#getOrCreateWebServices()`; + this.logger.info( + `${fnTag}, Registering webservices on instanceId=${this.instanceId}`, + ); + + if (Array.isArray(this.endpoints)) { + return this.endpoints; + } + const getStatusEndpointV1 = new GetStatusEndpointV1({ + dispatcher: this, + logLevel: this.options.logLevel, + }); + + const theEndpoints = [getStatusEndpointV1]; + this.endpoints = theEndpoints; + return theEndpoints; + } + + public async GetStatus(req: StatusRequest): Promise { + return GetStatusHandler(this.logger, req); + } + + // TODO implement handlers GetAudit, Transact, Cancel, Routes +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/cancel-handler-service.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/cancel-handler-service.ts new file mode 100644 index 0000000000..65b3dba385 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/cancel-handler-service.ts @@ -0,0 +1 @@ +// todo diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/routes-handler-service.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/routes-handler-service.ts new file mode 100644 index 0000000000..65b3dba385 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/routes-handler-service.ts @@ -0,0 +1 @@ +// todo diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/transact-handler-service.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/transact-handler-service.ts new file mode 100644 index 0000000000..65b3dba385 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/blo/transaction/transact-handler-service.ts @@ -0,0 +1 @@ +// todo diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/constants.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/constants.ts index 4c2a8ac472..10b525dcab 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/constants.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/constants.ts @@ -1,3 +1,3 @@ export const DEFAULT_PORT_GATEWAY_SERVER = 3010; -export const DEFAULT_PORT_GATEWAY_CLIENT = DEFAULT_PORT_GATEWAY_SERVER + 1; -export const DEFAULT_PORT_GATEWAY_UI = DEFAULT_PORT_GATEWAY_SERVER + 2; \ No newline at end of file +export const DEFAULT_PORT_GATEWAY_CLIENT = DEFAULT_PORT_GATEWAY_SERVER + 1; +export const DEFAULT_PORT_GATEWAY_UI = DEFAULT_PORT_GATEWAY_SERVER + 2; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/errors.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/errors.ts index a2bd3c7f79..d0d6599c9e 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/errors.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/errors.ts @@ -13,3 +13,13 @@ export class NonExistantGatewayIdentity extends Error { Object.setPrototypeOf(this, BootstrapError.prototype); } } + +export class GetStatusError extends Error { + constructor(sessionID: string, message: string) { + super( + `Could not GetStatus at Session: with id ${sessionID}. Reason: ${message}`, + ); + this.name = this.constructor.name; + Object.setPrototypeOf(this, GetStatusError.prototype); + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/stage-services/stage3.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/stage-services/stage3.ts index e69de29bb2..991aa1a51e 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/stage-services/stage3.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/stage-services/stage3.ts @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/types.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/types.ts index e534679f3d..6c33f0ac0b 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/core/types.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/core/types.ts @@ -1,11 +1,16 @@ import { Secp256k1Keys, LogLevelDesc } from "@hyperledger/cactus-common"; import { ValidatorOptions } from "class-validator"; +import { BLODispatcher } from "../blo/dispatcher"; export enum CurrentDrafts { Core = "Core", Architecture = "Architecture", Crash = "Crash", } +export interface IRequestOptions { + logLevel?: LogLevelDesc; + dispatcher: BLODispatcher; +} export type DraftVersions = { [K in CurrentDrafts]: string; @@ -25,6 +30,11 @@ export type GatewayChannel = { id: string; }; +export type Address = + | `http://${string}` + | `https://${string}` + | `${number}.${number}.${number}.${number}.`; + export type GatewayIdentity = { id: string; name?: string; @@ -33,10 +43,7 @@ export type GatewayIdentity = { proofID?: string; gatewayServerPort?: number; gatewayClientPort?: number; - address?: - | `http://${string}` - | `https://${string}` - | `${number}.${number}.${number}.${number}.`; + address?: Address; }; export interface SATPGatewayConfig { diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/gateway-refactor.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/gateway-refactor.ts index 3f23bbfbb4..2191fc0da2 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/gateway-refactor.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/gateway-refactor.ts @@ -25,11 +25,15 @@ import { } from "./core/types"; import { GatewayOrchestrator } from "./gol/gateway-orchestrator"; export { SATPGatewayConfig }; -import express, { Express } from 'express'; +import express, { Express } from "express"; import { expressConnectMiddleware } from "@connectrpc/connect-express"; import http from "http"; import { configureRoutes } from "./web-services/router"; -import { DEFAULT_PORT_GATEWAY_CLIENT, DEFAULT_PORT_GATEWAY_SERVER } from "./core/constants"; +import { + DEFAULT_PORT_GATEWAY_CLIENT, + DEFAULT_PORT_GATEWAY_SERVER, +} from "./core/constants"; +import { BLODispatcher, BLODispatcherOptions } from "./blo/dispatcher"; export class SATPGateway { // todo more checks; example port from config is between 3000 and 9000 @@ -53,8 +57,9 @@ export class SATPGateway { private gatewayApplication?: Express; private gatewayServer?: http.Server; - private BOLApplication?: Express; - private BOLServer?: http.Server; + private BLOApplication?: Express; + private BLOServer?: http.Server; + private BLODispatcher?: BLODispatcher; // TODO!: add logic to manage sessions (parallelization, user input, freeze, unfreeze, rollback, recovery) // private sessions: Map = new Map(); @@ -83,6 +88,18 @@ export class SATPGateway { this.gatewayConnectionManager = new GatewayOrchestrator(seedGateways, { logger: this.logger, }); + + const dispatcherOps: BLODispatcherOptions = { + logger: this.logger, + logLevel: this.config.logLevel, + instanceId: this.config.gid!.id, + }; + + if (!this.config.gid || !dispatcherOps.instanceId) { + throw new Error("Invalid configuration"); + } + + this.BLODispatcher = new BLODispatcher(dispatcherOps); } // todo load docs for gateway coordinator and expose them in a http gatewayApplication @@ -104,7 +121,6 @@ export class SATPGateway { // this._app.use("/api-docs", swaggerUi.serve, swaggerUi.setup(OpenAPISpec)); } - static ProcessGatewayCoordinatorConfig( pluginOptions: SATPGatewayConfig, ): SATPGatewayConfig { @@ -137,7 +153,7 @@ export class SATPGateway { if (!pluginOptions.gid.id) { pluginOptions.gid.id = id; } - + if (!pluginOptions.gid.name) { pluginOptions.gid.name = id; } @@ -171,7 +187,6 @@ export class SATPGateway { pluginOptions.gid.gatewayClientPort = DEFAULT_PORT_GATEWAY_CLIENT; } - if (!pluginOptions.logLevel) { pluginOptions.logLevel = "DEBUG"; } @@ -195,50 +210,92 @@ export class SATPGateway { * Startup Methods * ---------------- * This section includes methods responsible for starting up the server and its associated services. - * It ensures that both the GatewayServer and BOLServer are initiated concurrently for efficient launch. + * It ensures that both the GatewayServer and BLOServer are initiated concurrently for efficient launch. */ async startup(): Promise { const fnTag = `${this.label}#startup()`; this.logger.trace(`Entering ${fnTag}`); await Promise.all([ + // TODO! need to add TLS support for Connect and gRPC to work this.startupGatewayServer(), this.startupBOLServer(), ]); - this.logger.info("Both GatewayServer and BOLServer have started"); + this.logger.info("Both GatewayServer and BLOServer have started"); } - async startupGatewayServer(): Promise { const fnTag = `${this.label}#startupGatewayServer()`; this.logger.trace(`Entering ${fnTag}`); this.logger.info("Starting gateway server"); - const port = this.options.gid?.gatewayServerPort ?? DEFAULT_PORT_GATEWAY_SERVER; - - if (!this.gatewayApplication || !this.gatewayServer) { - this.gatewayApplication = express(); - this.gatewayApplication.use(expressConnectMiddleware({ routes: configureRoutes })); - this.gatewayServer = http.createServer(this.gatewayApplication).listen(port); - } else { - this.logger.warn("Server already running"); - } + const port = + this.options.gid?.gatewayServerPort ?? DEFAULT_PORT_GATEWAY_SERVER; + + return new Promise((resolve, reject) => { + if (!this.gatewayApplication || !this.gatewayServer) { + this.gatewayApplication = express(); + this.gatewayApplication.use( + expressConnectMiddleware({ routes: configureRoutes }), + ); + this.gatewayServer = http.createServer(this.gatewayApplication); + + this.gatewayServer.listen(port, () => { + this.logger.info( + `Gateway server started and listening on port ${port}`, + ); + resolve(); + }); + + this.gatewayServer.on("error", (error) => { + this.logger.error(`Gateway server failed to start: ${error}`); + reject(error); + }); + } else { + this.logger.warn("Server already running"); + resolve(); + } + }); } - async startupBOLServer(): Promise { const fnTag = `${this.label}#startupBOLServer()`; this.logger.trace(`Entering ${fnTag}`); this.logger.info("Starting BOL server"); - const port = (this.options.gid?.gatewayClientPort ?? DEFAULT_PORT_GATEWAY_CLIENT); - - if (!this.BOLApplication || !this.BOLServer) { - this.BOLApplication = express(); - // todo - // this.BOLApplication.use(expressConnectMiddleware()); - this.BOLServer = http.createServer(this.BOLApplication).listen(port); - } else { - this.logger.warn("Server already running"); - } + const port = + this.options.gid?.gatewayClientPort ?? DEFAULT_PORT_GATEWAY_CLIENT; + + return new Promise(async (resolve, reject) => { + if (!this.BLOApplication || !this.BLOServer) { + if (!this.BLODispatcher) { + throw new Error("BLODispatcher is not defined"); + } + this.BLOApplication = express(); + try { + const webServices = await this.BLODispatcher.getOrCreateWebServices(); + for (const service of webServices) { + this.logger.debug(`Registering web service: ${service.getPath()}`); + await service.registerExpress(this.BLOApplication); + } + } catch (error) { + throw new Error(`Failed to register web services: ${error}`); + } + + this.BLOServer = http.createServer(this.BLOApplication); + + this.BLOServer.listen(port, () => { + this.logger.info(`BOL server started and listening on port ${port}`); + resolve(); + }); + + this.BLOServer.on("error", (error) => { + this.logger.error(`BOL server failed to start: ${error}`); + reject(error); + }); + } else { + this.logger.warn("BOL Server already running."); + resolve(); + } + }); } /** @@ -249,6 +306,7 @@ export class SATPGateway { * These operations are fundamental for setting up and managing gateway connections within the system. */ + // TODO: addGateways as an admin endpoint public async addGateways(IDs: string[]): Promise { const fnTag = `${this.label}#addGateways()`; this.logger.trace(`Entering ${fnTag}`); @@ -358,48 +416,53 @@ export class SATPGateway { return mockGatewayIdentity; } - public getIdentity(): GatewayIdentity { + // TODO: keep getter; add an admin endpoint to get identity of connected gateway to BLO + public get Identity(): GatewayIdentity { const fnTag = `${this.label}#getIdentity()`; this.logger.trace(`Entering ${fnTag}`); + if (!this.config.gid) { + throw new Error("GatewayIdentity is not defined"); + } return this.config.gid!; } -/** - * Shutdown Methods - * ----------------- - * This section includes methods responsible for cleanly shutting down the server and its associated services. - */ + /** + * Shutdown Methods + * ----------------- + * This section includes methods responsible for cleanly shutting down the server and its associated services. + */ public onShutdown(hook: ShutdownHook): void { const fnTag = `${this.label}#onShutdown()`; this.logger.trace(`Entering ${fnTag}`); - this.logger.debug(`Adding shutdown hook: ${hook.name}`); + this.logger.debug(`Adding shutdown hook: ${hook.name}`); this.shutdownHooks.push(hook); } public async shutdown(): Promise { const fnTag = `${this.label}#getGatewaySeeds()`; - this.logger.debug(`Entering ${fnTag}`); + this.logger.debug(`Entering ${fnTag}`); this.logger.info("Shutting down Node server - Gateway"); await this.shutdownGatewayServer(); this.logger.info("Shutting down Node server - BOL"); - await this.shutdownBOLServer(); + await this.shutdownBLOServer(); this.logger.debug("Running shutdown hooks"); - for (const hook of this.shutdownHooks) { + for (const hook of this.shutdownHooks) { this.logger.debug(`Running shutdown hook: ${hook.name}`); await hook.hook(); } - this.logger.info("Shutting down Gateway Connection Manager") - const connectionsClosed = await this.gatewayConnectionManager.disconnectAll(); + this.logger.info("Shutting down Gateway Connection Manager"); + const connectionsClosed = + await this.gatewayConnectionManager.disconnectAll(); this.logger.info(`Closed ${connectionsClosed} connections`); this.logger.info("Gateway Coordinator shut down"); return connectionsClosed; } - + private async shutdownGatewayServer(): Promise { const fnTag = `${this.label}#shutdownServer()`; this.logger.debug(`Entering ${fnTag}`); @@ -409,28 +472,30 @@ export class SATPGateway { this.gatewayServer = undefined; this.logger.info("Server shut down"); } catch (error) { - this.logger.error(`Error shutting down the gatewayApplication: ${error}`); + this.logger.error( + `Error shutting down the gatewayApplication: ${error}`, + ); } } else { this.logger.warn("Server is not running."); } } - - private async shutdownBOLServer(): Promise { - const fnTag = `${this.label}#shutdownBOLServer()`; + + private async shutdownBLOServer(): Promise { + const fnTag = `${this.label}#shutdownBLOServer()`; this.logger.debug(`Entering ${fnTag}`); - if (this.BOLServer) { + if (this.BLOServer) { try { - await this.BOLServer.close(); - this.BOLServer = undefined; + await this.BLOServer.close(); + this.BLOServer = undefined; this.logger.info("Server shut down"); } catch (error) { - this.logger.error(`Error shutting down the gatewayApplication: ${error}`); + this.logger.error( + `Error shutting down the gatewayApplication: ${error}`, + ); } } else { this.logger.warn("Server is not running."); } } - -} - +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.gitignore b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.gitignore new file mode 100644 index 0000000000..149b576547 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.gitignore @@ -0,0 +1,4 @@ +wwwroot/*.js +node_modules +typings +dist diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.npmignore b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.npmignore new file mode 100644 index 0000000000..999d88df69 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.npmignore @@ -0,0 +1 @@ +# empty npmignore to ensure all required files (e.g., in the dist folder) are published by npm \ No newline at end of file diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator-ignore b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator-ignore new file mode 100644 index 0000000000..7484ee590a --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator-ignore @@ -0,0 +1,23 @@ +# OpenAPI Generator Ignore +# Generated by openapi-generator https://github.com/openapitools/openapi-generator + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/FILES b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/FILES new file mode 100644 index 0000000000..a80cd4f07b --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/FILES @@ -0,0 +1,8 @@ +.gitignore +.npmignore +api.ts +base.ts +common.ts +configuration.ts +git_push.sh +index.ts diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/VERSION b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/VERSION new file mode 100644 index 0000000000..cd802a1ec4 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/.openapi-generator/VERSION @@ -0,0 +1 @@ +6.6.0 \ No newline at end of file diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/api.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/api.ts new file mode 100644 index 0000000000..5009672823 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/api.ts @@ -0,0 +1,2678 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import type { Configuration } from './configuration'; +import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios'; +import globalAxios from 'axios'; +// Some imports not used depending on template conditions +// @ts-ignore +import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common'; +import type { RequestArgs } from './base'; +// @ts-ignore +import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base'; + +/** + * An Error + * @export + * @interface APIError + */ +export interface APIError { + /** + * HTTP error type + * @type {string} + * @memberof APIError + */ + 'type': string; + /** + * Numeric error code + * @type {number} + * @memberof APIError + */ + 'code': number; + /** + * HTTP status of the error + * @type {number} + * @memberof APIError + */ + 'status': number; + /** + * Long error description + * @type {string} + * @memberof APIError + */ + 'message': string; + /** + * Timestamp of the error + * @type {string} + * @memberof APIError + */ + 'timestamp': string; +} +/** + * + * @export + * @interface Action + */ +export interface Action { + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Action + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The amount of \'fromToken\' to be transferred, specified as a string to maintain precision. + * @type {string} + * @memberof Action + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Action + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The maximum acceptable difference between the expected price of the \'toToken\' and the price at the time of the transfer. + * @type {number} + * @memberof Action + */ + 'slippage'?: number; + /** + * A blockchain address. + * @type {string} + * @memberof Action + */ + 'fromAddress'?: string; + /** + * A blockchain address. + * @type {string} + * @memberof Action + */ + 'toAddress'?: string; +} +/** + * Stores global constants related to the authorization of the application. Specifically enumerates the claims to validate for as per RFC 7519, section 4.1. See: https://tools.ietf.org/html/rfc7519#section-4.1 + * @export + * @enum {string} + */ + +export const AuthzJwtClaim = { + /** + * The "iss" (issuer) claim identifies the principal that issued the JWT. The processing of this claim is generally application specific. The "iss" value is a case-sensitive string containing a StringOrURI value. Use of this claim is OPTIONAL. + */ + iss: 'Hyperledger Labs - Carbon Accounting Tool' +} as const; + +export type AuthzJwtClaim = typeof AuthzJwtClaim[keyof typeof AuthzJwtClaim]; + + +/** + * + * @export + * @enum {string} + */ + +export const AuthzScope = { + /** + * Identities with the group:admin scope are administrators of the system. + */ + GroupAdmin: 'group:admin', + /** + * Identities with the group:user scope are end users of the system who only have authorization to perform a limited set of actions. + */ + GroupUser: 'group:user' +} as const; + +export type AuthzScope = typeof AuthzScope[keyof typeof AuthzScope]; + + +/** + * Information about the bridge used for the token transfer. + * @export + * @interface BridgeInfo + */ +export interface BridgeInfo { + /** + * The address of the token being transferred. + * @type {string} + * @memberof BridgeInfo + */ + 'tokenAddress'?: string; +} +/** + * Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status. + * @export + * @interface Cancel200Response + */ +export interface Cancel200Response { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Cancel200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; + /** + * Indicates whether the cancel operation was successful. + * @type {boolean} + * @memberof Cancel200Response + */ + 'cancelSuccessful': boolean; +} +/** + * Request to cancel an ongoing transaction session, identified by the session ID. + * @export + * @interface CancelRequest + */ +export interface CancelRequest { + /** + * Unique identifier (UUID) for the session. + * @type {string} + * @memberof CancelRequest + */ + 'sessionID': string; +} +/** + * Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status. + * @export + * @interface CancelResponse + */ +export interface CancelResponse { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof CancelResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; + /** + * Indicates whether the cancel operation was successful. + * @type {boolean} + * @memberof CancelResponse + */ + 'cancelSuccessful': boolean; +} +/** + * + * @export + * @interface Chain + */ +export interface Chain { + /** + * A unique identifier for the blockchain network. + * @type {string} + * @memberof Chain + */ + 'chainId': string; + /** + * The name of the blockchain network. + * @type {string} + * @memberof Chain + */ + 'chainName': string; + /** + * The type of blockchain network (e.g., \'evm\', \'fabric\'). + * @type {string} + * @memberof Chain + */ + 'chainType': string; + /** + * The specific network name within the blockchain (e.g., \'mainnet\', \'testnet\'). + * @type {string} + * @memberof Chain + */ + 'networkName': string; +} +/** + * + * @export + * @interface Chains1Inner + */ +export interface Chains1Inner { + /** + * A unique identifier for the blockchain network. + * @type {string} + * @memberof Chains1Inner + */ + 'chainId': string; + /** + * The name of the blockchain network. + * @type {string} + * @memberof Chains1Inner + */ + 'chainName': string; + /** + * The type of blockchain network (e.g., \'evm\', \'fabric\'). + * @type {string} + * @memberof Chains1Inner + */ + 'chainType': string; + /** + * The specific network name within the blockchain (e.g., \'mainnet\', \'testnet\'). + * @type {string} + * @memberof Chains1Inner + */ + 'networkName': string; +} +/** + * Response schema for a continue request, returning the status of the SATP session. + * @export + * @interface Continue200Response + */ +export interface Continue200Response { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Continue200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * Schema for a request to continue a paused transaction session. + * @export + * @interface ContinueRequest + */ +export interface ContinueRequest { + /** + * A unique identifier for the transaction session to be continued. + * @type {string} + * @memberof ContinueRequest + */ + 'sessionId': string; + /** + * A unique identifier for the transaction context. + * @type {string} + * @memberof ContinueRequest + */ + 'contextId': string; +} +/** + * Response schema for a continue request, returning the status of the SATP session. + * @export + * @interface ContinueResponse + */ +export interface ContinueResponse { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof ContinueResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * + * @export + * @enum {string} + */ + +export const CredentialProfile = { + Saml: 'SAML', + Oauth: 'OAUTH', + X509: 'X509' +} as const; + +export type CredentialProfile = typeof CredentialProfile[keyof typeof CredentialProfile]; + + +/** + * Supported DLT protocols. + * @export + * @enum {string} + */ + +export const DLTProtocol = { + HyperledgerFabric: 'HyperledgerFabric', + HyperledgerBesu: 'HyperledgerBesu' +} as const; + +export type DLTProtocol = typeof DLTProtocol[keyof typeof DLTProtocol]; + + +/** + * Provides an estimation for a transaction, including costs, amounts, and execution duration. + * @export + * @interface Estimate + */ +export interface Estimate { + /** + * A blockchain address. + * @type {string} + * @memberof Estimate + */ + 'approvalAddress'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'toAmountMin'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'toAmount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'fromAmount'?: string; + /** + * A collection of fee costs associated with the transaction. + * @type {Array} + * @memberof Estimate + */ + 'feeCosts'?: Array; + /** + * A collection of estimated gas costs for executing the transaction. + * @type {Array} + * @memberof Estimate + */ + 'gasCosts'?: Array; + /** + * The estimated duration for the transaction execution in seconds. + * @type {number} + * @memberof Estimate + */ + 'executionDuration'?: number; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'fromAmountUSD'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'toAmountUSD'?: string; + /** + * The tool or service used to generate this estimate. + * @type {string} + * @memberof Estimate + */ + 'tool'?: string; +} +/** + * Details about a specific fee cost associated with the transaction. + * @export + * @interface FeeCost + */ +export interface FeeCost { + /** + * Name of the fee cost. + * @type {string} + * @memberof FeeCost + */ + 'name'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof FeeCost + */ + 'amount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof FeeCost + */ + 'amountUSD'?: string; + /** + * The symbol of a token + * @type {string} + * @memberof FeeCost + */ + 'token'?: string; + /** + * Indicates if the fee is included in the transaction amount. + * @type {boolean} + * @memberof FeeCost + */ + 'included'?: boolean; +} +/** + * + * @export + * @interface GasCost + */ +export interface GasCost { + /** + * The type of the gas cost. + * @type {string} + * @memberof GasCost + */ + 'type'?: string; + /** + * The gas price, specified as a string to maintain precision. + * @type {string} + * @memberof GasCost + */ + 'price'?: string; + /** + * The estimated gas required, specified as a string to maintain precision. + * @type {string} + * @memberof GasCost + */ + 'estimate'?: string; + /** + * The gas limit for the transaction, specified as a string to maintain precision. + * @type {string} + * @memberof GasCost + */ + 'limit'?: string; + /** + * The amount of gas required in the gas currency. + * @type {string} + * @memberof GasCost + */ + 'amount'?: string; + /** + * The amount of gas required in USD. + * @type {string} + * @memberof GasCost + */ + 'amountUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GasCost + */ + 'token'?: GetRoutes200ResponseRoutesInnerFromToken; +} +/** + * Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes. + * @export + * @interface GetAudit200Response + */ +export interface GetAudit200Response { + /** + * An array of strings representing proofs. + * @type {Array} + * @memberof GetAudit200Response + */ + 'proofs'?: Array; + /** + * The start datetime of the audit period. + * @type {string} + * @memberof GetAudit200Response + */ + 'auditStartTime'?: string; + /** + * The end datetime of the audit period. + * @type {string} + * @memberof GetAudit200Response + */ + 'auditEndTime'?: string; +} +/** + * Request schema for initiating an audit. Includes the start and end dates for the audit period and an option to include proofs. + * @export + * @interface GetAuditRequest + */ +export interface GetAuditRequest { + /** + * The start datetime for the audit. + * @type {string} + * @memberof GetAuditRequest + */ + 'auditStartDate'?: string; + /** + * The end datetime for the audit. + * @type {string} + * @memberof GetAuditRequest + */ + 'auditEndDate'?: string; + /** + * Include proofs generated from each gateway transaction. + * @type {boolean} + * @memberof GetAuditRequest + */ + 'includeProofs'?: boolean; +} +/** + * Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes. + * @export + * @interface GetAuditResponse + */ +export interface GetAuditResponse { + /** + * An array of strings representing proofs. + * @type {Array} + * @memberof GetAuditResponse + */ + 'proofs'?: Array; + /** + * The start datetime of the audit period. + * @type {string} + * @memberof GetAuditResponse + */ + 'auditStartTime'?: string; + /** + * The end datetime of the audit period. + * @type {string} + * @memberof GetAuditResponse + */ + 'auditEndTime'?: string; +} +/** + * + * @export + * @interface GetHealthCheck200Response + */ +export interface GetHealthCheck200Response { + /** + * + * @type {string} + * @memberof GetHealthCheck200Response + */ + 'status'?: string; +} +/** + * A collection of available and unavailable routes + * @export + * @interface GetRoutes200Response + */ +export interface GetRoutes200Response { + /** + * A collection of route objects + * @type {Array} + * @memberof GetRoutes200Response + */ + 'routes': Array; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInner + */ +export interface GetRoutes200ResponseRoutesInner { + /** + * A unique identifier of the route. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'id': string; + /** + * A unique identifier for the gateway. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'gatewayID': string; + /** + * The mode of operation for this route - \'data\' for arbitrary payload handling, \'transfer\' for asset transfer. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'mode': GetRoutes200ResponseRoutesInnerModeEnum; + /** + * The ID of the DLT Network where the operation will originate. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromDLTNetworkID'?: string; + /** + * The amount of \'fromToken\' to be transferred in USD, specified as a string to maintain precision. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromAmountUSD'?: number; + /** + * The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The ID of the DLT Network where the operation will end. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toDLTNetworkID'?: string; + /** + * The expected amount to be received in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toAmountUSD'?: string; + /** + * The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toAmount'?: string; + /** + * The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toAmountMin'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The expected gas cost in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'gasCostUSD'?: string; + /** + * Whether chain switching is enabled or not. + * @type {boolean} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'containsSwitchChain'?: boolean; + /** + * List of steps involved in this route, adjusted for mode. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'steps'?: Array; + /** + * + * @type {GetRoutes200ResponseRoutesInnerInsurance} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'insurance'?: GetRoutes200ResponseRoutesInnerInsurance; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'tags'?: Array; +} + +export const GetRoutes200ResponseRoutesInnerModeEnum = { + Data: 'data', + Transfer: 'transfer' +} as const; + +export type GetRoutes200ResponseRoutesInnerModeEnum = typeof GetRoutes200ResponseRoutesInnerModeEnum[keyof typeof GetRoutes200ResponseRoutesInnerModeEnum]; + +/** + * Metadata detailing a supported token + * @export + * @interface GetRoutes200ResponseRoutesInnerFromToken + */ +export interface GetRoutes200ResponseRoutesInnerFromToken { + /** + * The network of the DLT being interacted with. TODO: implement network identification draft + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'chainID': string; + /** + * Supported DLT protocols. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'chainType': GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum; + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'address': string; + /** + * The name of the token. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'name'?: string; + /** + * The symbol of the token. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'symbol': string; + /** + * How many decimals the token supports. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'decimals': number; + /** + * The logo of a token, chain, dex etc. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'logoURI'?: string; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'tags'?: Array; + /** + * The current price of the token in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'priceUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromTokenExtensions} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'extensions'?: GetRoutes200ResponseRoutesInnerFromTokenExtensions; +} + +export const GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum = { + HyperledgerFabric: 'HyperledgerFabric', + HyperledgerBesu: 'HyperledgerBesu' +} as const; + +export type GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum = typeof GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum[keyof typeof GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum]; + +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerFromTokenExtensions + */ +export interface GetRoutes200ResponseRoutesInnerFromTokenExtensions { + /** + * + * @type {{ [key: string]: GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue; }} + * @memberof GetRoutes200ResponseRoutesInnerFromTokenExtensions + */ + 'bridgeInfo'?: { [key: string]: GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue; }; + /** + * Indicates whether the token is verified. + * @type {boolean} + * @memberof GetRoutes200ResponseRoutesInnerFromTokenExtensions + */ + 'verified'?: boolean; +} +/** + * Information about the bridge used for the token transfer. + * @export + * @interface GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + */ +export interface GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + /** + * The address of the token being transferred. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + */ + 'tokenAddress'?: string; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerInsurance + */ +export interface GetRoutes200ResponseRoutesInnerInsurance { + /** + * The state of insurance applicability for the transaction. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerInsurance + */ + 'state'?: GetRoutes200ResponseRoutesInnerInsuranceStateEnum; + /** + * The fee amount for insurance, represented in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerInsurance + */ + 'feeAmountUsd'?: string; +} + +export const GetRoutes200ResponseRoutesInnerInsuranceStateEnum = { + NotInsurable: 'NOT_INSURABLE', + Insurable: 'INSURABLE', + Insured: 'INSURED' +} as const; + +export type GetRoutes200ResponseRoutesInnerInsuranceStateEnum = typeof GetRoutes200ResponseRoutesInnerInsuranceStateEnum[keyof typeof GetRoutes200ResponseRoutesInnerInsuranceStateEnum]; + +/** + * Details a single step within a route including actions and estimates. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInner + */ +export interface GetRoutes200ResponseRoutesInnerStepsInner { + /** + * Id of the step + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'id'?: string; + /** + * Type of the step, typically describing the action, e.g., \'swap\'. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'type'?: string; + /** + * Tool used in the step, e.g., \'stargate\'. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'tool'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerAction} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'action'?: GetRoutes200ResponseRoutesInnerStepsInnerAction; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerEstimate} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'estimate'?: GetRoutes200ResponseRoutesInnerStepsInnerEstimate; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'toolDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'integrationDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * IDs of further steps included within this step, allowing for nested actions without direct recursion. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'includedStepIds'?: Array; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerAction + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerAction { + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The amount of \'fromToken\' to be transferred, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The maximum acceptable difference between the expected price of the \'toToken\' and the price at the time of the transfer. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'slippage'?: number; + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'fromAddress'?: string; + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'toAddress'?: string; +} +/** + * Provides an estimation for a transaction, including costs, amounts, and execution duration. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerEstimate { + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'approvalAddress'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'toAmountMin'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'toAmount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'fromAmount'?: string; + /** + * A collection of fee costs associated with the transaction. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'feeCosts'?: Array; + /** + * A collection of estimated gas costs for executing the transaction. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'gasCosts'?: Array; + /** + * The estimated duration for the transaction execution in seconds. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'executionDuration'?: number; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'fromAmountUSD'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'toAmountUSD'?: string; + /** + * The tool or service used to generate this estimate. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'tool'?: string; +} +/** + * Details about a specific fee cost associated with the transaction. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner { + /** + * Name of the fee cost. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'name'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'amount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'amountUSD'?: string; + /** + * The symbol of a token + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'token'?: string; + /** + * Indicates if the fee is included in the transaction amount. + * @type {boolean} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'included'?: boolean; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner { + /** + * The type of the gas cost. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'type'?: string; + /** + * The gas price, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'price'?: string; + /** + * The estimated gas required, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'estimate'?: string; + /** + * The gas limit for the transaction, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'limit'?: string; + /** + * The amount of gas required in the gas currency. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'amount'?: string; + /** + * The amount of gas required in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'amountUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'token'?: GetRoutes200ResponseRoutesInnerFromToken; +} +/** + * Describes integration or tool details such as bridges or exchanges involved in the transaction. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerToolDetails { + /** + * A unique identifier for the integration or tool. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ + 'key': string; + /** + * The name of the integration or tool. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ + 'name': string; + /** + * URL to the logo of the integration or tool. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ + 'logoURI': string; +} +/** + * + * @export + * @interface HealthCheckResponse + */ +export interface HealthCheckResponse { + /** + * + * @type {string} + * @memberof HealthCheckResponse + */ + 'status'?: string; +} +/** + * Details a single step within a route including actions and estimates. + * @export + * @interface IncludedStep + */ +export interface IncludedStep { + /** + * Id of the step + * @type {string} + * @memberof IncludedStep + */ + 'id'?: string; + /** + * Type of the step, typically describing the action, e.g., \'swap\'. + * @type {string} + * @memberof IncludedStep + */ + 'type'?: string; + /** + * Tool used in the step, e.g., \'stargate\'. + * @type {string} + * @memberof IncludedStep + */ + 'tool'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerAction} + * @memberof IncludedStep + */ + 'action'?: GetRoutes200ResponseRoutesInnerStepsInnerAction; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerEstimate} + * @memberof IncludedStep + */ + 'estimate'?: GetRoutes200ResponseRoutesInnerStepsInnerEstimate; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof IncludedStep + */ + 'toolDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof IncludedStep + */ + 'integrationDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * IDs of further steps included within this step, allowing for nested actions without direct recursion. + * @type {Array} + * @memberof IncludedStep + */ + 'includedStepIds'?: Array; +} +/** + * + * @export + * @interface Insurance + */ +export interface Insurance { + /** + * The state of insurance applicability for the transaction. + * @type {string} + * @memberof Insurance + */ + 'state'?: InsuranceStateEnum; + /** + * The fee amount for insurance, represented in USD. + * @type {string} + * @memberof Insurance + */ + 'feeAmountUsd'?: string; +} + +export const InsuranceStateEnum = { + NotInsurable: 'NOT_INSURABLE', + Insurable: 'INSURABLE', + Insured: 'INSURED' +} as const; + +export type InsuranceStateEnum = typeof InsuranceStateEnum[keyof typeof InsuranceStateEnum]; + +/** + * Describes integration or tool details such as bridges or exchanges involved in the transaction. + * @export + * @interface IntegrationDetails + */ +export interface IntegrationDetails { + /** + * A unique identifier for the integration or tool. + * @type {string} + * @memberof IntegrationDetails + */ + 'key': string; + /** + * The name of the integration or tool. + * @type {string} + * @memberof IntegrationDetails + */ + 'name': string; + /** + * URL to the logo of the integration or tool. + * @type {string} + * @memberof IntegrationDetails + */ + 'logoURI': string; +} +/** + * Response for a pause transaction request. Returns the current status of the SATP session post-pause action. + * @export + * @interface Pause200Response + */ +export interface Pause200Response { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Pause200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * Request to temporarily pause an ongoing transaction session, identified by the session and context IDs. + * @export + * @interface PauseRequest + */ +export interface PauseRequest { + /** + * + * @type {string} + * @memberof PauseRequest + */ + 'sessionId'?: string; + /** + * + * @type {string} + * @memberof PauseRequest + */ + 'contextId'?: string; +} +/** + * Response for a pause transaction request. Returns the current status of the SATP session post-pause action. + * @export + * @interface PauseResponse + */ +export interface PauseResponse { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof PauseResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * + * @export + * @interface Route + */ +export interface Route { + /** + * A unique identifier of the route. + * @type {string} + * @memberof Route + */ + 'id': string; + /** + * A unique identifier for the gateway. + * @type {string} + * @memberof Route + */ + 'gatewayID': string; + /** + * The mode of operation for this route - \'data\' for arbitrary payload handling, \'transfer\' for asset transfer. + * @type {string} + * @memberof Route + */ + 'mode': RouteModeEnum; + /** + * The ID of the DLT Network where the operation will originate. + * @type {string} + * @memberof Route + */ + 'fromDLTNetworkID'?: string; + /** + * The amount of \'fromToken\' to be transferred in USD, specified as a string to maintain precision. + * @type {number} + * @memberof Route + */ + 'fromAmountUSD'?: number; + /** + * The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof Route + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Route + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The ID of the DLT Network where the operation will end. + * @type {string} + * @memberof Route + */ + 'toDLTNetworkID'?: string; + /** + * The expected amount to be received in USD. + * @type {string} + * @memberof Route + */ + 'toAmountUSD'?: string; + /** + * The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof Route + */ + 'toAmount'?: string; + /** + * The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof Route + */ + 'toAmountMin'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Route + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The expected gas cost in USD. + * @type {string} + * @memberof Route + */ + 'gasCostUSD'?: string; + /** + * Whether chain switching is enabled or not. + * @type {boolean} + * @memberof Route + */ + 'containsSwitchChain'?: boolean; + /** + * List of steps involved in this route, adjusted for mode. + * @type {Array} + * @memberof Route + */ + 'steps'?: Array; + /** + * + * @type {GetRoutes200ResponseRoutesInnerInsurance} + * @memberof Route + */ + 'insurance'?: GetRoutes200ResponseRoutesInnerInsurance; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof Route + */ + 'tags'?: Array; +} + +export const RouteModeEnum = { + Data: 'data', + Transfer: 'transfer' +} as const; + +export type RouteModeEnum = typeof RouteModeEnum[keyof typeof RouteModeEnum]; + +/** + * A collection of available and unavailable routes + * @export + * @interface RoutesResponse + */ +export interface RoutesResponse { + /** + * A collection of route objects + * @type {Array} + * @memberof RoutesResponse + */ + 'routes': Array; +} +/** + * Request for retrieving the current status of a session, identified by the session ID. + * @export + * @interface StatusRequest + */ +export interface StatusRequest { + /** + * The ID of the session for which the status is being requested. + * @type {string} + * @memberof StatusRequest + */ + 'sessionID': string; +} +/** + * Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information. + * @export + * @interface StatusResponse + */ +export interface StatusResponse { + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'status': StatusResponseStatusEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'substatus': StatusResponseSubstatusEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'stage': StatusResponseStageEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'step': StatusResponseStepEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'startTime': string; + /** + * + * @type {Transact200ResponseStatusResponseOriginChain} + * @memberof StatusResponse + */ + 'originChain': Transact200ResponseStatusResponseOriginChain; + /** + * + * @type {Transact200ResponseStatusResponseDestinationChain} + * @memberof StatusResponse + */ + 'destinationChain': Transact200ResponseStatusResponseDestinationChain; +} + +export const StatusResponseStatusEnum = { + NotFound: 'NOT_FOUND', + Invalid: 'INVALID', + Pending: 'PENDING', + Done: 'DONE', + Failed: 'FAILED' +} as const; + +export type StatusResponseStatusEnum = typeof StatusResponseStatusEnum[keyof typeof StatusResponseStatusEnum]; +export const StatusResponseSubstatusEnum = { + WaitSourceConfirmations: 'WAIT_SOURCE_CONFIRMATIONS', + WaitDestinationTransaction: 'WAIT_DESTINATION_TRANSACTION', + BridgeNotAvailable: 'BRIDGE_NOT_AVAILABLE', + ChainNotAvailable: 'CHAIN_NOT_AVAILABLE', + RefundInProgress: 'REFUND_IN_PROGRESS', + UnknownError: 'UNKNOWN_ERROR', + Completed: 'COMPLETED', + Partial: 'PARTIAL', + Refunded: 'REFUNDED', + NotProcessableRefundNeeded: 'NOT_PROCESSABLE_REFUND_NEEDED' +} as const; + +export type StatusResponseSubstatusEnum = typeof StatusResponseSubstatusEnum[keyof typeof StatusResponseSubstatusEnum]; +export const StatusResponseStageEnum = { + Stage0: 'STAGE0', + Stage1: 'STAGE1', + Stage2: 'STAGE2', + Stage3: 'STAGE3' +} as const; + +export type StatusResponseStageEnum = typeof StatusResponseStageEnum[keyof typeof StatusResponseStageEnum]; +export const StatusResponseStepEnum = { + TransferInitializationClaims: 'transfer-initialization-claims', + ConveyanceOfNetworkCapabilitiesAndParameters: 'conveyance-of-network-capabilities-and-parameters', + TransferProposalMessage: 'transfer-proposal-message', + TransferProposalReceiptMessage: 'transfer-proposal-receipt-message', + TransferProposalRejectAndConditionalRejectMessage: 'transfer-proposal-reject-and-conditional-reject-message', + TransferCommenceMessage: 'transfer-commence-message', + CommenceResponseMessage: 'commence-response-message', + LockAssertionMessage: 'lock-assertion-message', + LockAssertionReceiptMessage: 'lock-assertion-receipt-message', + CommitPreparationMessage: 'commit-preparation-message', + CommitReadyMessage: 'commit-ready-message', + CommitFinalAssertionMessage: 'commit-final-assertion-message', + CommitFinalAcknowledgementReceiptMessage: 'commit-final-acknowledgement-receipt-message', + TransferCompleteMessage: 'transfer-complete-message', + RollbackTransferInitializationClaims: 'rollback-transfer-initialization-claims', + RollbackConveyanceOfNetworkCapabilitiesAndParameters: 'rollback-conveyance-of-network-capabilities-and-parameters', + RollbackTransferProposalMessage: 'rollback-transfer-proposal-message', + RollbackTransferProposalReceiptMessage: 'rollback-transfer-proposal-receipt-message', + RollbackTransferProposalRejectAndConditionalRejectMessage: 'rollback-transfer-proposal-reject-and-conditional-reject-message', + RollbackTransferCommenceMessage: 'rollback-transfer-commence-message', + RollbackCommenceResponseMessage: 'rollback-commence-response-message', + RollbackLockAssertionMessage: 'rollback-lock-assertion-message', + RollbackLockAssertionReceiptMessage: 'rollback-lock-assertion-receipt-message', + RollbackCommitPreparationMessage: 'rollback-commit-preparation-message', + RollbackCommitReadyMessage: 'rollback-commit-ready-message', + RollbackCommitFinalAssertionMessage: 'rollback-commit-final-assertion-message', + RollbackCommitFinalAcknowledgementReceiptMessage: 'rollback-commit-final-acknowledgement-receipt-message', + RollbackTransferCompleteMessage: 'rollback-transfer-complete-message' +} as const; + +export type StatusResponseStepEnum = typeof StatusResponseStepEnum[keyof typeof StatusResponseStepEnum]; + +/** + * Metadata detailing a supported token + * @export + * @interface Token + */ +export interface Token { + /** + * The network of the DLT being interacted with. TODO: implement network identification draft + * @type {string} + * @memberof Token + */ + 'chainID': string; + /** + * Supported DLT protocols. + * @type {string} + * @memberof Token + */ + 'chainType': TokenChainTypeEnum; + /** + * A blockchain address. + * @type {string} + * @memberof Token + */ + 'address': string; + /** + * The name of the token. + * @type {string} + * @memberof Token + */ + 'name'?: string; + /** + * The symbol of the token. + * @type {string} + * @memberof Token + */ + 'symbol': string; + /** + * How many decimals the token supports. + * @type {number} + * @memberof Token + */ + 'decimals': number; + /** + * The logo of a token, chain, dex etc. + * @type {string} + * @memberof Token + */ + 'logoURI'?: string; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof Token + */ + 'tags'?: Array; + /** + * The current price of the token in USD. + * @type {string} + * @memberof Token + */ + 'priceUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromTokenExtensions} + * @memberof Token + */ + 'extensions'?: GetRoutes200ResponseRoutesInnerFromTokenExtensions; +} + +export const TokenChainTypeEnum = { + HyperledgerFabric: 'HyperledgerFabric', + HyperledgerBesu: 'HyperledgerBesu' +} as const; + +export type TokenChainTypeEnum = typeof TokenChainTypeEnum[keyof typeof TokenChainTypeEnum]; + +/** + * Response schema for a transaction request. Includes the session ID and the current status of the transaction. + * @export + * @interface Transact200Response + */ +export interface Transact200Response { + /** + * Unique identifier (UUID) for the session. + * @type {string} + * @memberof Transact200Response + */ + 'sessionID': string; + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Transact200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information. + * @export + * @interface Transact200ResponseStatusResponse + */ +export interface Transact200ResponseStatusResponse { + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'status': Transact200ResponseStatusResponseStatusEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'substatus': Transact200ResponseStatusResponseSubstatusEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'stage': Transact200ResponseStatusResponseStageEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'step': Transact200ResponseStatusResponseStepEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'startTime': string; + /** + * + * @type {Transact200ResponseStatusResponseOriginChain} + * @memberof Transact200ResponseStatusResponse + */ + 'originChain': Transact200ResponseStatusResponseOriginChain; + /** + * + * @type {Transact200ResponseStatusResponseDestinationChain} + * @memberof Transact200ResponseStatusResponse + */ + 'destinationChain': Transact200ResponseStatusResponseDestinationChain; +} + +export const Transact200ResponseStatusResponseStatusEnum = { + NotFound: 'NOT_FOUND', + Invalid: 'INVALID', + Pending: 'PENDING', + Done: 'DONE', + Failed: 'FAILED' +} as const; + +export type Transact200ResponseStatusResponseStatusEnum = typeof Transact200ResponseStatusResponseStatusEnum[keyof typeof Transact200ResponseStatusResponseStatusEnum]; +export const Transact200ResponseStatusResponseSubstatusEnum = { + WaitSourceConfirmations: 'WAIT_SOURCE_CONFIRMATIONS', + WaitDestinationTransaction: 'WAIT_DESTINATION_TRANSACTION', + BridgeNotAvailable: 'BRIDGE_NOT_AVAILABLE', + ChainNotAvailable: 'CHAIN_NOT_AVAILABLE', + RefundInProgress: 'REFUND_IN_PROGRESS', + UnknownError: 'UNKNOWN_ERROR', + Completed: 'COMPLETED', + Partial: 'PARTIAL', + Refunded: 'REFUNDED', + NotProcessableRefundNeeded: 'NOT_PROCESSABLE_REFUND_NEEDED' +} as const; + +export type Transact200ResponseStatusResponseSubstatusEnum = typeof Transact200ResponseStatusResponseSubstatusEnum[keyof typeof Transact200ResponseStatusResponseSubstatusEnum]; +export const Transact200ResponseStatusResponseStageEnum = { + Stage0: 'STAGE0', + Stage1: 'STAGE1', + Stage2: 'STAGE2', + Stage3: 'STAGE3' +} as const; + +export type Transact200ResponseStatusResponseStageEnum = typeof Transact200ResponseStatusResponseStageEnum[keyof typeof Transact200ResponseStatusResponseStageEnum]; +export const Transact200ResponseStatusResponseStepEnum = { + TransferInitializationClaims: 'transfer-initialization-claims', + ConveyanceOfNetworkCapabilitiesAndParameters: 'conveyance-of-network-capabilities-and-parameters', + TransferProposalMessage: 'transfer-proposal-message', + TransferProposalReceiptMessage: 'transfer-proposal-receipt-message', + TransferProposalRejectAndConditionalRejectMessage: 'transfer-proposal-reject-and-conditional-reject-message', + TransferCommenceMessage: 'transfer-commence-message', + CommenceResponseMessage: 'commence-response-message', + LockAssertionMessage: 'lock-assertion-message', + LockAssertionReceiptMessage: 'lock-assertion-receipt-message', + CommitPreparationMessage: 'commit-preparation-message', + CommitReadyMessage: 'commit-ready-message', + CommitFinalAssertionMessage: 'commit-final-assertion-message', + CommitFinalAcknowledgementReceiptMessage: 'commit-final-acknowledgement-receipt-message', + TransferCompleteMessage: 'transfer-complete-message', + RollbackTransferInitializationClaims: 'rollback-transfer-initialization-claims', + RollbackConveyanceOfNetworkCapabilitiesAndParameters: 'rollback-conveyance-of-network-capabilities-and-parameters', + RollbackTransferProposalMessage: 'rollback-transfer-proposal-message', + RollbackTransferProposalReceiptMessage: 'rollback-transfer-proposal-receipt-message', + RollbackTransferProposalRejectAndConditionalRejectMessage: 'rollback-transfer-proposal-reject-and-conditional-reject-message', + RollbackTransferCommenceMessage: 'rollback-transfer-commence-message', + RollbackCommenceResponseMessage: 'rollback-commence-response-message', + RollbackLockAssertionMessage: 'rollback-lock-assertion-message', + RollbackLockAssertionReceiptMessage: 'rollback-lock-assertion-receipt-message', + RollbackCommitPreparationMessage: 'rollback-commit-preparation-message', + RollbackCommitReadyMessage: 'rollback-commit-ready-message', + RollbackCommitFinalAssertionMessage: 'rollback-commit-final-assertion-message', + RollbackCommitFinalAcknowledgementReceiptMessage: 'rollback-commit-final-acknowledgement-receipt-message', + RollbackTransferCompleteMessage: 'rollback-transfer-complete-message' +} as const; + +export type Transact200ResponseStatusResponseStepEnum = typeof Transact200ResponseStatusResponseStepEnum[keyof typeof Transact200ResponseStatusResponseStepEnum]; + +/** + * + * @export + * @interface Transact200ResponseStatusResponseDestinationChain + */ +export interface Transact200ResponseStatusResponseDestinationChain { + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseDestinationChain + */ + 'dltProtocol'?: any; + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseDestinationChain + */ + 'dltSubnetworkID'?: any; +} +/** + * + * @export + * @interface Transact200ResponseStatusResponseOriginChain + */ +export interface Transact200ResponseStatusResponseOriginChain { + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseOriginChain + */ + 'dltProtocol'?: any; + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseOriginChain + */ + 'dltSubnetworkID'?: any; +} +/** + * An Error + * @export + * @interface TransactDefaultResponse + */ +export interface TransactDefaultResponse { + /** + * HTTP error type + * @type {string} + * @memberof TransactDefaultResponse + */ + 'type': string; + /** + * Numeric error code + * @type {number} + * @memberof TransactDefaultResponse + */ + 'code': number; + /** + * HTTP status of the error + * @type {number} + * @memberof TransactDefaultResponse + */ + 'status': number; + /** + * Long error description + * @type {string} + * @memberof TransactDefaultResponse + */ + 'message': string; + /** + * Timestamp of the error + * @type {string} + * @memberof TransactDefaultResponse + */ + 'timestamp': string; +} +/** + * Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks. + * @export + * @interface TransactRequest + */ +export interface TransactRequest { + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'contextID': string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'mode': TransactRequestModeEnum; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'payload'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'fromDLTNetworkID'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'toDLTNetworkID'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'fromAmount'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'fromToken'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'toAmount'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'toToken'?: string; +} + +export const TransactRequestModeEnum = { + Data: 'data', + Transfer: 'transfer' +} as const; + +export type TransactRequestModeEnum = typeof TransactRequestModeEnum[keyof typeof TransactRequestModeEnum]; + +/** + * Response schema for a transaction request. Includes the session ID and the current status of the transaction. + * @export + * @interface TransactResponse + */ +export interface TransactResponse { + /** + * Unique identifier (UUID) for the session. + * @type {string} + * @memberof TransactResponse + */ + 'sessionID': string; + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof TransactResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; +} + +/** + * AdminApi - axios parameter creator + * @export + */ +export const AdminApiAxiosParamCreator = function (configuration?: Configuration) { + return { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + _continue: async (continueRequest: ContinueRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'continueRequest' is not null or undefined + assertParamExists('_continue', 'continueRequest', continueRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/continue`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(continueRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getAudit: async (auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options: AxiosRequestConfig = {}): Promise => { + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/audit`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + if (auditStartDate !== undefined) { + localVarQueryParameter['auditStartDate'] = (auditStartDate as any instanceof Date) ? + (auditStartDate as any).toISOString() : + auditStartDate; + } + + if (auditEndDate !== undefined) { + localVarQueryParameter['auditEndDate'] = (auditEndDate as any instanceof Date) ? + (auditEndDate as any).toISOString() : + auditEndDate; + } + + if (includeProofs !== undefined) { + localVarQueryParameter['includeProofs'] = includeProofs; + } + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getHealthCheck: async (options: AxiosRequestConfig = {}): Promise => { + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/healthcheck`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getStatus: async (sessionID: string, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'sessionID' is not null or undefined + assertParamExists('getStatus', 'sessionID', sessionID) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/status`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + if (sessionID !== undefined) { + localVarQueryParameter['SessionID'] = sessionID; + } + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + pause: async (pauseRequest: PauseRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'pauseRequest' is not null or undefined + assertParamExists('pause', 'pauseRequest', pauseRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/pause`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(pauseRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + } +}; + +/** + * AdminApi - functional programming interface + * @export + */ +export const AdminApiFp = function(configuration?: Configuration) { + const localVarAxiosParamCreator = AdminApiAxiosParamCreator(configuration) + return { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async _continue(continueRequest: ContinueRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator._continue(continueRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getAudit(auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getAudit(auditStartDate, auditEndDate, includeProofs, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getHealthCheck(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getHealthCheck(options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getStatus(sessionID: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getStatus(sessionID, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async pause(pauseRequest: PauseRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.pause(pauseRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + } +}; + +/** + * AdminApi - factory interface + * @export + */ +export const AdminApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { + const localVarFp = AdminApiFp(configuration) + return { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + _continue(continueRequest: ContinueRequest, options?: any): AxiosPromise { + return localVarFp._continue(continueRequest, options).then((request) => request(axios, basePath)); + }, + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getAudit(auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options?: any): AxiosPromise { + return localVarFp.getAudit(auditStartDate, auditEndDate, includeProofs, options).then((request) => request(axios, basePath)); + }, + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getHealthCheck(options?: any): AxiosPromise { + return localVarFp.getHealthCheck(options).then((request) => request(axios, basePath)); + }, + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getStatus(sessionID: string, options?: any): AxiosPromise { + return localVarFp.getStatus(sessionID, options).then((request) => request(axios, basePath)); + }, + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + pause(pauseRequest: PauseRequest, options?: any): AxiosPromise { + return localVarFp.pause(pauseRequest, options).then((request) => request(axios, basePath)); + }, + }; +}; + +/** + * AdminApi - object-oriented interface + * @export + * @class AdminApi + * @extends {BaseAPI} + */ +export class AdminApi extends BaseAPI { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public _continue(continueRequest: ContinueRequest, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration)._continue(continueRequest, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public getAudit(auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).getAudit(auditStartDate, auditEndDate, includeProofs, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public getHealthCheck(options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).getHealthCheck(options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public getStatus(sessionID: string, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).getStatus(sessionID, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public pause(pauseRequest: PauseRequest, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).pause(pauseRequest, options).then((request) => request(this.axios, this.basePath)); + } +} + + +/** + * TransactionApi - axios parameter creator + * @export + */ +export const TransactionApiAxiosParamCreator = function (configuration?: Configuration) { + return { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + cancel: async (cancelRequest: CancelRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'cancelRequest' is not null or undefined + assertParamExists('cancel', 'cancelRequest', cancelRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(cancelRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getIntegrations: async (options: AxiosRequestConfig = {}): Promise => { + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getRoutes: async (fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'fromNetworkID' is not null or undefined + assertParamExists('getRoutes', 'fromNetworkID', fromNetworkID) + // verify required parameter 'fromAmount' is not null or undefined + assertParamExists('getRoutes', 'fromAmount', fromAmount) + // verify required parameter 'fromToken' is not null or undefined + assertParamExists('getRoutes', 'fromToken', fromToken) + // verify required parameter 'toDLTNetwork' is not null or undefined + assertParamExists('getRoutes', 'toDLTNetwork', toDLTNetwork) + // verify required parameter 'toToken' is not null or undefined + assertParamExists('getRoutes', 'toToken', toToken) + // verify required parameter 'fromAddress' is not null or undefined + assertParamExists('getRoutes', 'fromAddress', fromAddress) + // verify required parameter 'toAddress' is not null or undefined + assertParamExists('getRoutes', 'toAddress', toAddress) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/routes`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + if (fromNetworkID !== undefined) { + localVarQueryParameter['fromNetworkID'] = fromNetworkID; + } + + if (fromAmount !== undefined) { + localVarQueryParameter['fromAmount'] = fromAmount; + } + + if (fromToken !== undefined) { + localVarQueryParameter['fromToken'] = fromToken; + } + + if (toDLTNetwork !== undefined) { + localVarQueryParameter['toDLTNetwork'] = toDLTNetwork; + } + + if (toToken !== undefined) { + localVarQueryParameter['toToken'] = toToken; + } + + if (fromAddress !== undefined) { + localVarQueryParameter['fromAddress'] = fromAddress; + } + + if (toAddress !== undefined) { + localVarQueryParameter['toAddress'] = toAddress; + } + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + transact: async (transactRequest: TransactRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'transactRequest' is not null or undefined + assertParamExists('transact', 'transactRequest', transactRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/transact`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(transactRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + } +}; + +/** + * TransactionApi - functional programming interface + * @export + */ +export const TransactionApiFp = function(configuration?: Configuration) { + const localVarAxiosParamCreator = TransactionApiAxiosParamCreator(configuration) + return { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async cancel(cancelRequest: CancelRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.cancel(cancelRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getIntegrations(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getIntegrations(options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getRoutes(fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getRoutes(fromNetworkID, fromAmount, fromToken, toDLTNetwork, toToken, fromAddress, toAddress, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async transact(transactRequest: TransactRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.transact(transactRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + } +}; + +/** + * TransactionApi - factory interface + * @export + */ +export const TransactionApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { + const localVarFp = TransactionApiFp(configuration) + return { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + cancel(cancelRequest: CancelRequest, options?: any): AxiosPromise { + return localVarFp.cancel(cancelRequest, options).then((request) => request(axios, basePath)); + }, + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getIntegrations(options?: any): AxiosPromise> { + return localVarFp.getIntegrations(options).then((request) => request(axios, basePath)); + }, + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getRoutes(fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options?: any): AxiosPromise { + return localVarFp.getRoutes(fromNetworkID, fromAmount, fromToken, toDLTNetwork, toToken, fromAddress, toAddress, options).then((request) => request(axios, basePath)); + }, + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + transact(transactRequest: TransactRequest, options?: any): AxiosPromise { + return localVarFp.transact(transactRequest, options).then((request) => request(axios, basePath)); + }, + }; +}; + +/** + * TransactionApi - object-oriented interface + * @export + * @class TransactionApi + * @extends {BaseAPI} + */ +export class TransactionApi extends BaseAPI { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public cancel(cancelRequest: CancelRequest, options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).cancel(cancelRequest, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public getIntegrations(options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).getIntegrations(options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public getRoutes(fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).getRoutes(fromNetworkID, fromAmount, fromToken, toDLTNetwork, toToken, fromAddress, toAddress, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public transact(transactRequest: TransactRequest, options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).transact(transactRequest, options).then((request) => request(this.axios, this.basePath)); + } +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/base.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/base.ts new file mode 100644 index 0000000000..59018f25b9 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/base.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import type { Configuration } from './configuration'; +// Some imports not used depending on template conditions +// @ts-ignore +import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios'; +import globalAxios from 'axios'; + +export const BASE_PATH = "http://localhost:3011/api/v1/@hyperledger/cactus-plugin-satp-hermes".replace(/\/+$/, ""); + +/** + * + * @export + */ +export const COLLECTION_FORMATS = { + csv: ",", + ssv: " ", + tsv: "\t", + pipes: "|", +}; + +/** + * + * @export + * @interface RequestArgs + */ +export interface RequestArgs { + url: string; + options: AxiosRequestConfig; +} + +/** + * + * @export + * @class BaseAPI + */ +export class BaseAPI { + protected configuration: Configuration | undefined; + + constructor(configuration?: Configuration, protected basePath: string = BASE_PATH, protected axios: AxiosInstance = globalAxios) { + if (configuration) { + this.configuration = configuration; + this.basePath = configuration.basePath || this.basePath; + } + } +}; + +/** + * + * @export + * @class RequiredError + * @extends {Error} + */ +export class RequiredError extends Error { + constructor(public field: string, msg?: string) { + super(msg); + this.name = "RequiredError" + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/common.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/common.ts new file mode 100644 index 0000000000..e2604cb54e --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/common.ts @@ -0,0 +1,150 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import type { Configuration } from "./configuration"; +import type { RequestArgs } from "./base"; +import type { AxiosInstance, AxiosResponse } from 'axios'; +import { RequiredError } from "./base"; + +/** + * + * @export + */ +export const DUMMY_BASE_URL = 'https://example.com' + +/** + * + * @throws {RequiredError} + * @export + */ +export const assertParamExists = function (functionName: string, paramName: string, paramValue: unknown) { + if (paramValue === null || paramValue === undefined) { + throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`); + } +} + +/** + * + * @export + */ +export const setApiKeyToObject = async function (object: any, keyParamName: string, configuration?: Configuration) { + if (configuration && configuration.apiKey) { + const localVarApiKeyValue = typeof configuration.apiKey === 'function' + ? await configuration.apiKey(keyParamName) + : await configuration.apiKey; + object[keyParamName] = localVarApiKeyValue; + } +} + +/** + * + * @export + */ +export const setBasicAuthToObject = function (object: any, configuration?: Configuration) { + if (configuration && (configuration.username || configuration.password)) { + object["auth"] = { username: configuration.username, password: configuration.password }; + } +} + +/** + * + * @export + */ +export const setBearerAuthToObject = async function (object: any, configuration?: Configuration) { + if (configuration && configuration.accessToken) { + const accessToken = typeof configuration.accessToken === 'function' + ? await configuration.accessToken() + : await configuration.accessToken; + object["Authorization"] = "Bearer " + accessToken; + } +} + +/** + * + * @export + */ +export const setOAuthToObject = async function (object: any, name: string, scopes: string[], configuration?: Configuration) { + if (configuration && configuration.accessToken) { + const localVarAccessTokenValue = typeof configuration.accessToken === 'function' + ? await configuration.accessToken(name, scopes) + : await configuration.accessToken; + object["Authorization"] = "Bearer " + localVarAccessTokenValue; + } +} + +function setFlattenedQueryParams(urlSearchParams: URLSearchParams, parameter: any, key: string = ""): void { + if (parameter == null) return; + if (typeof parameter === "object") { + if (Array.isArray(parameter)) { + (parameter as any[]).forEach(item => setFlattenedQueryParams(urlSearchParams, item, key)); + } + else { + Object.keys(parameter).forEach(currentKey => + setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`) + ); + } + } + else { + if (urlSearchParams.has(key)) { + urlSearchParams.append(key, parameter); + } + else { + urlSearchParams.set(key, parameter); + } + } +} + +/** + * + * @export + */ +export const setSearchParams = function (url: URL, ...objects: any[]) { + const searchParams = new URLSearchParams(url.search); + setFlattenedQueryParams(searchParams, objects); + url.search = searchParams.toString(); +} + +/** + * + * @export + */ +export const serializeDataIfNeeded = function (value: any, requestOptions: any, configuration?: Configuration) { + const nonString = typeof value !== 'string'; + const needsSerialization = nonString && configuration && configuration.isJsonMime + ? configuration.isJsonMime(requestOptions.headers['Content-Type']) + : nonString; + return needsSerialization + ? JSON.stringify(value !== undefined ? value : {}) + : (value || ""); +} + +/** + * + * @export + */ +export const toPathString = function (url: URL) { + return url.pathname + url.search + url.hash +} + +/** + * + * @export + */ +export const createRequestFunction = function (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) { + return >(axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => { + const axiosRequestArgs = {...axiosArgs.options, url: (configuration?.basePath || basePath) + axiosArgs.url}; + return axios.request(axiosRequestArgs); + }; +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/configuration.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/configuration.ts new file mode 100644 index 0000000000..a444ba448f --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/configuration.ts @@ -0,0 +1,101 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ConfigurationParameters { + apiKey?: string | Promise | ((name: string) => string) | ((name: string) => Promise); + username?: string; + password?: string; + accessToken?: string | Promise | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise); + basePath?: string; + baseOptions?: any; + formDataCtor?: new () => any; +} + +export class Configuration { + /** + * parameter for apiKey security + * @param name security name + * @memberof Configuration + */ + apiKey?: string | Promise | ((name: string) => string) | ((name: string) => Promise); + /** + * parameter for basic security + * + * @type {string} + * @memberof Configuration + */ + username?: string; + /** + * parameter for basic security + * + * @type {string} + * @memberof Configuration + */ + password?: string; + /** + * parameter for oauth2 security + * @param name security name + * @param scopes oauth2 scope + * @memberof Configuration + */ + accessToken?: string | Promise | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise); + /** + * override base path + * + * @type {string} + * @memberof Configuration + */ + basePath?: string; + /** + * base options for axios calls + * + * @type {any} + * @memberof Configuration + */ + baseOptions?: any; + /** + * The FormData constructor that will be used to create multipart form data + * requests. You can inject this here so that execution environments that + * do not support the FormData class can still run the generated client. + * + * @type {new () => FormData} + */ + formDataCtor?: new () => any; + + constructor(param: ConfigurationParameters = {}) { + this.apiKey = param.apiKey; + this.username = param.username; + this.password = param.password; + this.accessToken = param.accessToken; + this.basePath = param.basePath; + this.baseOptions = param.baseOptions; + this.formDataCtor = param.formDataCtor; + } + + /** + * Check if the given MIME is a JSON MIME. + * JSON MIME examples: + * application/json + * application/json; charset=UTF8 + * APPLICATION/JSON + * application/vnd.company+json + * @param mime - MIME (Multipurpose Internet Mail Extensions) + * @return True if the given MIME is JSON, false otherwise. + */ + public isJsonMime(mime: string): boolean { + const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i'); + return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json'); + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/git_push.sh b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/git_push.sh new file mode 100644 index 0000000000..f53a75d4fa --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/git_push.sh @@ -0,0 +1,57 @@ +#!/bin/sh +# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ +# +# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com" + +git_user_id=$1 +git_repo_id=$2 +release_note=$3 +git_host=$4 + +if [ "$git_host" = "" ]; then + git_host="github.com" + echo "[INFO] No command line input provided. Set \$git_host to $git_host" +fi + +if [ "$git_user_id" = "" ]; then + git_user_id="GIT_USER_ID" + echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" +fi + +if [ "$git_repo_id" = "" ]; then + git_repo_id="GIT_REPO_ID" + echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" +fi + +if [ "$release_note" = "" ]; then + release_note="Minor update" + echo "[INFO] No command line input provided. Set \$release_note to $release_note" +fi + +# Initialize the local directory as a Git repository +git init + +# Adds the files in the local repository and stages them for commit. +git add . + +# Commits the tracked changes and prepares them to be pushed to a remote repository. +git commit -m "$release_note" + +# Sets the new remote +git_remote=$(git remote) +if [ "$git_remote" = "" ]; then # git remote not defined + + if [ "$GIT_TOKEN" = "" ]; then + echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." + git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git + else + git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git + fi + +fi + +git pull origin master + +# Pushes (Forces) the changes in the local repository up to the remote repository +echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" +git push origin master 2>&1 | grep -v 'To https' diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/index.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/index.ts new file mode 100644 index 0000000000..d13fdacf7f --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios-json/index.ts @@ -0,0 +1,18 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export * from "./api"; +export * from "./configuration"; + diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/.openapi-generator/FILES b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/.openapi-generator/FILES new file mode 100644 index 0000000000..53250c0269 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/.openapi-generator/FILES @@ -0,0 +1,5 @@ +api.ts +base.ts +common.ts +configuration.ts +index.ts diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/api.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/api.ts new file mode 100644 index 0000000000..d80bb5dc08 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/api.ts @@ -0,0 +1,2678 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import type { Configuration } from './configuration'; +import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios'; +import globalAxios from 'axios'; +// Some imports not used depending on template conditions +// @ts-ignore +import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common'; +import type { RequestArgs } from './base'; +// @ts-ignore +import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base'; + +/** + * An Error + * @export + * @interface APIError + */ +export interface APIError { + /** + * HTTP error type + * @type {string} + * @memberof APIError + */ + 'type': string; + /** + * Numeric error code + * @type {number} + * @memberof APIError + */ + 'code': number; + /** + * HTTP status of the error + * @type {number} + * @memberof APIError + */ + 'status': number; + /** + * Long error description + * @type {string} + * @memberof APIError + */ + 'message': string; + /** + * Timestamp of the error + * @type {string} + * @memberof APIError + */ + 'timestamp': string; +} +/** + * + * @export + * @interface Action + */ +export interface Action { + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Action + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The amount of \'fromToken\' to be transferred, specified as a string to maintain precision. + * @type {string} + * @memberof Action + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Action + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The maximum acceptable difference between the expected price of the \'toToken\' and the price at the time of the transfer. + * @type {number} + * @memberof Action + */ + 'slippage'?: number; + /** + * A blockchain address. + * @type {string} + * @memberof Action + */ + 'fromAddress'?: string; + /** + * A blockchain address. + * @type {string} + * @memberof Action + */ + 'toAddress'?: string; +} +/** + * Stores global constants related to the authorization of the application. Specifically enumerates the claims to validate for as per RFC 7519, section 4.1. See: https://tools.ietf.org/html/rfc7519#section-4.1 + * @export + * @enum {string} + */ + +export const AuthzJwtClaim = { + /** + * The "iss" (issuer) claim identifies the principal that issued the JWT. The processing of this claim is generally application specific. The "iss" value is a case-sensitive string containing a StringOrURI value. Use of this claim is OPTIONAL. + */ + iss: 'Hyperledger Labs - Carbon Accounting Tool' +} as const; + +export type AuthzJwtClaim = typeof AuthzJwtClaim[keyof typeof AuthzJwtClaim]; + + +/** + * + * @export + * @enum {string} + */ + +export const AuthzScope = { + /** + * Identities with the group:admin scope are administrators of the system. + */ + GroupAdmin: 'group:admin', + /** + * Identities with the group:user scope are end users of the system who only have authorization to perform a limited set of actions. + */ + GroupUser: 'group:user' +} as const; + +export type AuthzScope = typeof AuthzScope[keyof typeof AuthzScope]; + + +/** + * Information about the bridge used for the token transfer. + * @export + * @interface BridgeInfo + */ +export interface BridgeInfo { + /** + * The address of the token being transferred. + * @type {string} + * @memberof BridgeInfo + */ + 'tokenAddress'?: string; +} +/** + * Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status. + * @export + * @interface Cancel200Response + */ +export interface Cancel200Response { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Cancel200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; + /** + * Indicates whether the cancel operation was successful. + * @type {boolean} + * @memberof Cancel200Response + */ + 'cancelSuccessful': boolean; +} +/** + * Request to cancel an ongoing transaction session, identified by the session ID. + * @export + * @interface CancelRequest + */ +export interface CancelRequest { + /** + * Unique identifier (UUID) for the session. + * @type {string} + * @memberof CancelRequest + */ + 'sessionID': string; +} +/** + * Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status. + * @export + * @interface CancelResponse + */ +export interface CancelResponse { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof CancelResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; + /** + * Indicates whether the cancel operation was successful. + * @type {boolean} + * @memberof CancelResponse + */ + 'cancelSuccessful': boolean; +} +/** + * + * @export + * @interface Chain + */ +export interface Chain { + /** + * A unique identifier for the blockchain network. + * @type {string} + * @memberof Chain + */ + 'chainId': string; + /** + * The name of the blockchain network. + * @type {string} + * @memberof Chain + */ + 'chainName': string; + /** + * The type of blockchain network (e.g., \'evm\', \'fabric\'). + * @type {string} + * @memberof Chain + */ + 'chainType': string; + /** + * The specific network name within the blockchain (e.g., \'mainnet\', \'testnet\'). + * @type {string} + * @memberof Chain + */ + 'networkName': string; +} +/** + * + * @export + * @interface Chains1Inner + */ +export interface Chains1Inner { + /** + * A unique identifier for the blockchain network. + * @type {string} + * @memberof Chains1Inner + */ + 'chainId': string; + /** + * The name of the blockchain network. + * @type {string} + * @memberof Chains1Inner + */ + 'chainName': string; + /** + * The type of blockchain network (e.g., \'evm\', \'fabric\'). + * @type {string} + * @memberof Chains1Inner + */ + 'chainType': string; + /** + * The specific network name within the blockchain (e.g., \'mainnet\', \'testnet\'). + * @type {string} + * @memberof Chains1Inner + */ + 'networkName': string; +} +/** + * Response schema for a continue request, returning the status of the SATP session. + * @export + * @interface Continue200Response + */ +export interface Continue200Response { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Continue200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * Schema for a request to continue a paused transaction session. + * @export + * @interface ContinueRequest + */ +export interface ContinueRequest { + /** + * A unique identifier for the transaction session to be continued. + * @type {string} + * @memberof ContinueRequest + */ + 'sessionId': string; + /** + * A unique identifier for the transaction context. + * @type {string} + * @memberof ContinueRequest + */ + 'contextId': string; +} +/** + * Response schema for a continue request, returning the status of the SATP session. + * @export + * @interface ContinueResponse + */ +export interface ContinueResponse { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof ContinueResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * + * @export + * @enum {string} + */ + +export const CredentialProfile = { + Saml: 'SAML', + Oauth: 'OAUTH', + X509: 'X509' +} as const; + +export type CredentialProfile = typeof CredentialProfile[keyof typeof CredentialProfile]; + + +/** + * Supported DLT protocols. + * @export + * @enum {string} + */ + +export const DLTProtocol = { + HyperledgerFabric: 'HyperledgerFabric', + HyperledgerBesu: 'HyperledgerBesu' +} as const; + +export type DLTProtocol = typeof DLTProtocol[keyof typeof DLTProtocol]; + + +/** + * Provides an estimation for a transaction, including costs, amounts, and execution duration. + * @export + * @interface Estimate + */ +export interface Estimate { + /** + * A blockchain address. + * @type {string} + * @memberof Estimate + */ + 'approvalAddress'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'toAmountMin'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'toAmount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'fromAmount'?: string; + /** + * A collection of fee costs associated with the transaction. + * @type {Array} + * @memberof Estimate + */ + 'feeCosts'?: Array; + /** + * A collection of estimated gas costs for executing the transaction. + * @type {Array} + * @memberof Estimate + */ + 'gasCosts'?: Array; + /** + * The estimated duration for the transaction execution in seconds. + * @type {number} + * @memberof Estimate + */ + 'executionDuration'?: number; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'fromAmountUSD'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof Estimate + */ + 'toAmountUSD'?: string; + /** + * The tool or service used to generate this estimate. + * @type {string} + * @memberof Estimate + */ + 'tool'?: string; +} +/** + * Details about a specific fee cost associated with the transaction. + * @export + * @interface FeeCost + */ +export interface FeeCost { + /** + * Name of the fee cost. + * @type {string} + * @memberof FeeCost + */ + 'name'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof FeeCost + */ + 'amount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof FeeCost + */ + 'amountUSD'?: string; + /** + * The symbol of a token + * @type {string} + * @memberof FeeCost + */ + 'token'?: string; + /** + * Indicates if the fee is included in the transaction amount. + * @type {boolean} + * @memberof FeeCost + */ + 'included'?: boolean; +} +/** + * + * @export + * @interface GasCost + */ +export interface GasCost { + /** + * The type of the gas cost. + * @type {string} + * @memberof GasCost + */ + 'type'?: string; + /** + * The gas price, specified as a string to maintain precision. + * @type {string} + * @memberof GasCost + */ + 'price'?: string; + /** + * The estimated gas required, specified as a string to maintain precision. + * @type {string} + * @memberof GasCost + */ + 'estimate'?: string; + /** + * The gas limit for the transaction, specified as a string to maintain precision. + * @type {string} + * @memberof GasCost + */ + 'limit'?: string; + /** + * The amount of gas required in the gas currency. + * @type {string} + * @memberof GasCost + */ + 'amount'?: string; + /** + * The amount of gas required in USD. + * @type {string} + * @memberof GasCost + */ + 'amountUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GasCost + */ + 'token'?: GetRoutes200ResponseRoutesInnerFromToken; +} +/** + * Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes. + * @export + * @interface GetAudit200Response + */ +export interface GetAudit200Response { + /** + * An array of strings representing proofs. + * @type {Array} + * @memberof GetAudit200Response + */ + 'proofs'?: Array; + /** + * The start datetime of the audit period. + * @type {string} + * @memberof GetAudit200Response + */ + 'auditStartTime'?: string; + /** + * The end datetime of the audit period. + * @type {string} + * @memberof GetAudit200Response + */ + 'auditEndTime'?: string; +} +/** + * Request schema for initiating an audit. Includes the start and end dates for the audit period and an option to include proofs. + * @export + * @interface GetAuditRequest + */ +export interface GetAuditRequest { + /** + * The start datetime for the audit. + * @type {string} + * @memberof GetAuditRequest + */ + 'auditStartDate'?: string; + /** + * The end datetime for the audit. + * @type {string} + * @memberof GetAuditRequest + */ + 'auditEndDate'?: string; + /** + * Include proofs generated from each gateway transaction. + * @type {boolean} + * @memberof GetAuditRequest + */ + 'includeProofs'?: boolean; +} +/** + * Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes. + * @export + * @interface GetAuditResponse + */ +export interface GetAuditResponse { + /** + * An array of strings representing proofs. + * @type {Array} + * @memberof GetAuditResponse + */ + 'proofs'?: Array; + /** + * The start datetime of the audit period. + * @type {string} + * @memberof GetAuditResponse + */ + 'auditStartTime'?: string; + /** + * The end datetime of the audit period. + * @type {string} + * @memberof GetAuditResponse + */ + 'auditEndTime'?: string; +} +/** + * + * @export + * @interface GetHealthCheck200Response + */ +export interface GetHealthCheck200Response { + /** + * + * @type {string} + * @memberof GetHealthCheck200Response + */ + 'status'?: string; +} +/** + * A collection of available and unavailable routes + * @export + * @interface GetRoutes200Response + */ +export interface GetRoutes200Response { + /** + * A collection of route objects + * @type {Array} + * @memberof GetRoutes200Response + */ + 'routes': Array; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInner + */ +export interface GetRoutes200ResponseRoutesInner { + /** + * A unique identifier of the route. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'id': string; + /** + * A unique identifier for the gateway. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'gatewayID': string; + /** + * The mode of operation for this route - \'data\' for arbitrary payload handling, \'transfer\' for asset transfer. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'mode': GetRoutes200ResponseRoutesInnerModeEnum; + /** + * The ID of the DLT Network where the operation will originate. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromDLTNetworkID'?: string; + /** + * The amount of \'fromToken\' to be transferred in USD, specified as a string to maintain precision. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromAmountUSD'?: number; + /** + * The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The ID of the DLT Network where the operation will end. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toDLTNetworkID'?: string; + /** + * The expected amount to be received in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toAmountUSD'?: string; + /** + * The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toAmount'?: string; + /** + * The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toAmountMin'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The expected gas cost in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'gasCostUSD'?: string; + /** + * Whether chain switching is enabled or not. + * @type {boolean} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'containsSwitchChain'?: boolean; + /** + * List of steps involved in this route, adjusted for mode. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'steps'?: Array; + /** + * + * @type {GetRoutes200ResponseRoutesInnerInsurance} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'insurance'?: GetRoutes200ResponseRoutesInnerInsurance; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInner + */ + 'tags'?: Array; +} + +export const GetRoutes200ResponseRoutesInnerModeEnum = { + Data: 'data', + Transfer: 'transfer' +} as const; + +export type GetRoutes200ResponseRoutesInnerModeEnum = typeof GetRoutes200ResponseRoutesInnerModeEnum[keyof typeof GetRoutes200ResponseRoutesInnerModeEnum]; + +/** + * Metadata detailing a supported token + * @export + * @interface GetRoutes200ResponseRoutesInnerFromToken + */ +export interface GetRoutes200ResponseRoutesInnerFromToken { + /** + * The network of the DLT being interacted with. TODO: implement network identification draft + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'chainID': string; + /** + * Supported DLT protocols. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'chainType': GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum; + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'address': string; + /** + * The name of the token. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'name'?: string; + /** + * The symbol of the token. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'symbol': string; + /** + * How many decimals the token supports. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'decimals': number; + /** + * The logo of a token, chain, dex etc. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'logoURI'?: string; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'tags'?: Array; + /** + * The current price of the token in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'priceUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromTokenExtensions} + * @memberof GetRoutes200ResponseRoutesInnerFromToken + */ + 'extensions'?: GetRoutes200ResponseRoutesInnerFromTokenExtensions; +} + +export const GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum = { + HyperledgerFabric: 'HyperledgerFabric', + HyperledgerBesu: 'HyperledgerBesu' +} as const; + +export type GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum = typeof GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum[keyof typeof GetRoutes200ResponseRoutesInnerFromTokenChainTypeEnum]; + +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerFromTokenExtensions + */ +export interface GetRoutes200ResponseRoutesInnerFromTokenExtensions { + /** + * + * @type {{ [key: string]: GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue; }} + * @memberof GetRoutes200ResponseRoutesInnerFromTokenExtensions + */ + 'bridgeInfo'?: { [key: string]: GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue; }; + /** + * Indicates whether the token is verified. + * @type {boolean} + * @memberof GetRoutes200ResponseRoutesInnerFromTokenExtensions + */ + 'verified'?: boolean; +} +/** + * Information about the bridge used for the token transfer. + * @export + * @interface GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + */ +export interface GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue { + /** + * The address of the token being transferred. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerFromTokenExtensionsBridgeInfoValue + */ + 'tokenAddress'?: string; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerInsurance + */ +export interface GetRoutes200ResponseRoutesInnerInsurance { + /** + * The state of insurance applicability for the transaction. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerInsurance + */ + 'state'?: GetRoutes200ResponseRoutesInnerInsuranceStateEnum; + /** + * The fee amount for insurance, represented in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerInsurance + */ + 'feeAmountUsd'?: string; +} + +export const GetRoutes200ResponseRoutesInnerInsuranceStateEnum = { + NotInsurable: 'NOT_INSURABLE', + Insurable: 'INSURABLE', + Insured: 'INSURED' +} as const; + +export type GetRoutes200ResponseRoutesInnerInsuranceStateEnum = typeof GetRoutes200ResponseRoutesInnerInsuranceStateEnum[keyof typeof GetRoutes200ResponseRoutesInnerInsuranceStateEnum]; + +/** + * Details a single step within a route including actions and estimates. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInner + */ +export interface GetRoutes200ResponseRoutesInnerStepsInner { + /** + * Id of the step + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'id'?: string; + /** + * Type of the step, typically describing the action, e.g., \'swap\'. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'type'?: string; + /** + * Tool used in the step, e.g., \'stargate\'. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'tool'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerAction} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'action'?: GetRoutes200ResponseRoutesInnerStepsInnerAction; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerEstimate} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'estimate'?: GetRoutes200ResponseRoutesInnerStepsInnerEstimate; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'toolDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'integrationDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * IDs of further steps included within this step, allowing for nested actions without direct recursion. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerStepsInner + */ + 'includedStepIds'?: Array; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerAction + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerAction { + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The amount of \'fromToken\' to be transferred, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The maximum acceptable difference between the expected price of the \'toToken\' and the price at the time of the transfer. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'slippage'?: number; + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'fromAddress'?: string; + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerAction + */ + 'toAddress'?: string; +} +/** + * Provides an estimation for a transaction, including costs, amounts, and execution duration. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerEstimate { + /** + * A blockchain address. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'approvalAddress'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'toAmountMin'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'toAmount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'fromAmount'?: string; + /** + * A collection of fee costs associated with the transaction. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'feeCosts'?: Array; + /** + * A collection of estimated gas costs for executing the transaction. + * @type {Array} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'gasCosts'?: Array; + /** + * The estimated duration for the transaction execution in seconds. + * @type {number} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'executionDuration'?: number; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'fromAmountUSD'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'toAmountUSD'?: string; + /** + * The tool or service used to generate this estimate. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimate + */ + 'tool'?: string; +} +/** + * Details about a specific fee cost associated with the transaction. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner { + /** + * Name of the fee cost. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'name'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'amount'?: string; + /** + * The amount in string format including all decimals. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'amountUSD'?: string; + /** + * The symbol of a token + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'token'?: string; + /** + * Indicates if the fee is included in the transaction amount. + * @type {boolean} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateFeeCostsInner + */ + 'included'?: boolean; +} +/** + * + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner { + /** + * The type of the gas cost. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'type'?: string; + /** + * The gas price, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'price'?: string; + /** + * The estimated gas required, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'estimate'?: string; + /** + * The gas limit for the transaction, specified as a string to maintain precision. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'limit'?: string; + /** + * The amount of gas required in the gas currency. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'amount'?: string; + /** + * The amount of gas required in USD. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'amountUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerEstimateGasCostsInner + */ + 'token'?: GetRoutes200ResponseRoutesInnerFromToken; +} +/** + * Describes integration or tool details such as bridges or exchanges involved in the transaction. + * @export + * @interface GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ +export interface GetRoutes200ResponseRoutesInnerStepsInnerToolDetails { + /** + * A unique identifier for the integration or tool. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ + 'key': string; + /** + * The name of the integration or tool. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ + 'name': string; + /** + * URL to the logo of the integration or tool. + * @type {string} + * @memberof GetRoutes200ResponseRoutesInnerStepsInnerToolDetails + */ + 'logoURI': string; +} +/** + * + * @export + * @interface HealthCheckResponse + */ +export interface HealthCheckResponse { + /** + * + * @type {string} + * @memberof HealthCheckResponse + */ + 'status'?: string; +} +/** + * Details a single step within a route including actions and estimates. + * @export + * @interface IncludedStep + */ +export interface IncludedStep { + /** + * Id of the step + * @type {string} + * @memberof IncludedStep + */ + 'id'?: string; + /** + * Type of the step, typically describing the action, e.g., \'swap\'. + * @type {string} + * @memberof IncludedStep + */ + 'type'?: string; + /** + * Tool used in the step, e.g., \'stargate\'. + * @type {string} + * @memberof IncludedStep + */ + 'tool'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerAction} + * @memberof IncludedStep + */ + 'action'?: GetRoutes200ResponseRoutesInnerStepsInnerAction; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerEstimate} + * @memberof IncludedStep + */ + 'estimate'?: GetRoutes200ResponseRoutesInnerStepsInnerEstimate; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof IncludedStep + */ + 'toolDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * + * @type {GetRoutes200ResponseRoutesInnerStepsInnerToolDetails} + * @memberof IncludedStep + */ + 'integrationDetails'?: GetRoutes200ResponseRoutesInnerStepsInnerToolDetails; + /** + * IDs of further steps included within this step, allowing for nested actions without direct recursion. + * @type {Array} + * @memberof IncludedStep + */ + 'includedStepIds'?: Array; +} +/** + * + * @export + * @interface Insurance + */ +export interface Insurance { + /** + * The state of insurance applicability for the transaction. + * @type {string} + * @memberof Insurance + */ + 'state'?: InsuranceStateEnum; + /** + * The fee amount for insurance, represented in USD. + * @type {string} + * @memberof Insurance + */ + 'feeAmountUsd'?: string; +} + +export const InsuranceStateEnum = { + NotInsurable: 'NOT_INSURABLE', + Insurable: 'INSURABLE', + Insured: 'INSURED' +} as const; + +export type InsuranceStateEnum = typeof InsuranceStateEnum[keyof typeof InsuranceStateEnum]; + +/** + * Describes integration or tool details such as bridges or exchanges involved in the transaction. + * @export + * @interface IntegrationDetails + */ +export interface IntegrationDetails { + /** + * A unique identifier for the integration or tool. + * @type {string} + * @memberof IntegrationDetails + */ + 'key': string; + /** + * The name of the integration or tool. + * @type {string} + * @memberof IntegrationDetails + */ + 'name': string; + /** + * URL to the logo of the integration or tool. + * @type {string} + * @memberof IntegrationDetails + */ + 'logoURI': string; +} +/** + * Response for a pause transaction request. Returns the current status of the SATP session post-pause action. + * @export + * @interface Pause200Response + */ +export interface Pause200Response { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Pause200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * Request to temporarily pause an ongoing transaction session, identified by the session and context IDs. + * @export + * @interface PauseRequest + */ +export interface PauseRequest { + /** + * + * @type {string} + * @memberof PauseRequest + */ + 'sessionId'?: string; + /** + * + * @type {string} + * @memberof PauseRequest + */ + 'contextId'?: string; +} +/** + * Response for a pause transaction request. Returns the current status of the SATP session post-pause action. + * @export + * @interface PauseResponse + */ +export interface PauseResponse { + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof PauseResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * + * @export + * @interface Route + */ +export interface Route { + /** + * A unique identifier of the route. + * @type {string} + * @memberof Route + */ + 'id': string; + /** + * A unique identifier for the gateway. + * @type {string} + * @memberof Route + */ + 'gatewayID': string; + /** + * The mode of operation for this route - \'data\' for arbitrary payload handling, \'transfer\' for asset transfer. + * @type {string} + * @memberof Route + */ + 'mode': RouteModeEnum; + /** + * The ID of the DLT Network where the operation will originate. + * @type {string} + * @memberof Route + */ + 'fromDLTNetworkID'?: string; + /** + * The amount of \'fromToken\' to be transferred in USD, specified as a string to maintain precision. + * @type {number} + * @memberof Route + */ + 'fromAmountUSD'?: number; + /** + * The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof Route + */ + 'fromAmount'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Route + */ + 'fromToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The ID of the DLT Network where the operation will end. + * @type {string} + * @memberof Route + */ + 'toDLTNetworkID'?: string; + /** + * The expected amount to be received in USD. + * @type {string} + * @memberof Route + */ + 'toAmountUSD'?: string; + /** + * The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof Route + */ + 'toAmount'?: string; + /** + * The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + * @type {string} + * @memberof Route + */ + 'toAmountMin'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromToken} + * @memberof Route + */ + 'toToken'?: GetRoutes200ResponseRoutesInnerFromToken; + /** + * The expected gas cost in USD. + * @type {string} + * @memberof Route + */ + 'gasCostUSD'?: string; + /** + * Whether chain switching is enabled or not. + * @type {boolean} + * @memberof Route + */ + 'containsSwitchChain'?: boolean; + /** + * List of steps involved in this route, adjusted for mode. + * @type {Array} + * @memberof Route + */ + 'steps'?: Array; + /** + * + * @type {GetRoutes200ResponseRoutesInnerInsurance} + * @memberof Route + */ + 'insurance'?: GetRoutes200ResponseRoutesInnerInsurance; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof Route + */ + 'tags'?: Array; +} + +export const RouteModeEnum = { + Data: 'data', + Transfer: 'transfer' +} as const; + +export type RouteModeEnum = typeof RouteModeEnum[keyof typeof RouteModeEnum]; + +/** + * A collection of available and unavailable routes + * @export + * @interface RoutesResponse + */ +export interface RoutesResponse { + /** + * A collection of route objects + * @type {Array} + * @memberof RoutesResponse + */ + 'routes': Array; +} +/** + * Request for retrieving the current status of a session, identified by the session ID. + * @export + * @interface StatusRequest + */ +export interface StatusRequest { + /** + * The ID of the session for which the status is being requested. + * @type {string} + * @memberof StatusRequest + */ + 'sessionID': string; +} +/** + * Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information. + * @export + * @interface StatusResponse + */ +export interface StatusResponse { + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'status': StatusResponseStatusEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'substatus': StatusResponseSubstatusEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'stage': StatusResponseStageEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'step': StatusResponseStepEnum; + /** + * + * @type {string} + * @memberof StatusResponse + */ + 'startTime': string; + /** + * + * @type {Transact200ResponseStatusResponseOriginChain} + * @memberof StatusResponse + */ + 'originChain': Transact200ResponseStatusResponseOriginChain; + /** + * + * @type {Transact200ResponseStatusResponseDestinationChain} + * @memberof StatusResponse + */ + 'destinationChain': Transact200ResponseStatusResponseDestinationChain; +} + +export const StatusResponseStatusEnum = { + NotFound: 'NOT_FOUND', + Invalid: 'INVALID', + Pending: 'PENDING', + Done: 'DONE', + Failed: 'FAILED' +} as const; + +export type StatusResponseStatusEnum = typeof StatusResponseStatusEnum[keyof typeof StatusResponseStatusEnum]; +export const StatusResponseSubstatusEnum = { + WaitSourceConfirmations: 'WAIT_SOURCE_CONFIRMATIONS', + WaitDestinationTransaction: 'WAIT_DESTINATION_TRANSACTION', + BridgeNotAvailable: 'BRIDGE_NOT_AVAILABLE', + ChainNotAvailable: 'CHAIN_NOT_AVAILABLE', + RefundInProgress: 'REFUND_IN_PROGRESS', + UnknownError: 'UNKNOWN_ERROR', + Completed: 'COMPLETED', + Partial: 'PARTIAL', + Refunded: 'REFUNDED', + NotProcessableRefundNeeded: 'NOT_PROCESSABLE_REFUND_NEEDED' +} as const; + +export type StatusResponseSubstatusEnum = typeof StatusResponseSubstatusEnum[keyof typeof StatusResponseSubstatusEnum]; +export const StatusResponseStageEnum = { + Stage0: 'STAGE0', + Stage1: 'STAGE1', + Stage2: 'STAGE2', + Stage3: 'STAGE3' +} as const; + +export type StatusResponseStageEnum = typeof StatusResponseStageEnum[keyof typeof StatusResponseStageEnum]; +export const StatusResponseStepEnum = { + TransferInitializationClaims: 'transfer-initialization-claims', + ConveyanceOfNetworkCapabilitiesAndParameters: 'conveyance-of-network-capabilities-and-parameters', + TransferProposalMessage: 'transfer-proposal-message', + TransferProposalReceiptMessage: 'transfer-proposal-receipt-message', + TransferProposalRejectAndConditionalRejectMessage: 'transfer-proposal-reject-and-conditional-reject-message', + TransferCommenceMessage: 'transfer-commence-message', + CommenceResponseMessage: 'commence-response-message', + LockAssertionMessage: 'lock-assertion-message', + LockAssertionReceiptMessage: 'lock-assertion-receipt-message', + CommitPreparationMessage: 'commit-preparation-message', + CommitReadyMessage: 'commit-ready-message', + CommitFinalAssertionMessage: 'commit-final-assertion-message', + CommitFinalAcknowledgementReceiptMessage: 'commit-final-acknowledgement-receipt-message', + TransferCompleteMessage: 'transfer-complete-message', + RollbackTransferInitializationClaims: 'rollback-transfer-initialization-claims', + RollbackConveyanceOfNetworkCapabilitiesAndParameters: 'rollback-conveyance-of-network-capabilities-and-parameters', + RollbackTransferProposalMessage: 'rollback-transfer-proposal-message', + RollbackTransferProposalReceiptMessage: 'rollback-transfer-proposal-receipt-message', + RollbackTransferProposalRejectAndConditionalRejectMessage: 'rollback-transfer-proposal-reject-and-conditional-reject-message', + RollbackTransferCommenceMessage: 'rollback-transfer-commence-message', + RollbackCommenceResponseMessage: 'rollback-commence-response-message', + RollbackLockAssertionMessage: 'rollback-lock-assertion-message', + RollbackLockAssertionReceiptMessage: 'rollback-lock-assertion-receipt-message', + RollbackCommitPreparationMessage: 'rollback-commit-preparation-message', + RollbackCommitReadyMessage: 'rollback-commit-ready-message', + RollbackCommitFinalAssertionMessage: 'rollback-commit-final-assertion-message', + RollbackCommitFinalAcknowledgementReceiptMessage: 'rollback-commit-final-acknowledgement-receipt-message', + RollbackTransferCompleteMessage: 'rollback-transfer-complete-message' +} as const; + +export type StatusResponseStepEnum = typeof StatusResponseStepEnum[keyof typeof StatusResponseStepEnum]; + +/** + * Metadata detailing a supported token + * @export + * @interface Token + */ +export interface Token { + /** + * The network of the DLT being interacted with. TODO: implement network identification draft + * @type {string} + * @memberof Token + */ + 'chainID': string; + /** + * Supported DLT protocols. + * @type {string} + * @memberof Token + */ + 'chainType': TokenChainTypeEnum; + /** + * A blockchain address. + * @type {string} + * @memberof Token + */ + 'address': string; + /** + * The name of the token. + * @type {string} + * @memberof Token + */ + 'name'?: string; + /** + * The symbol of the token. + * @type {string} + * @memberof Token + */ + 'symbol': string; + /** + * How many decimals the token supports. + * @type {number} + * @memberof Token + */ + 'decimals': number; + /** + * The logo of a token, chain, dex etc. + * @type {string} + * @memberof Token + */ + 'logoURI'?: string; + /** + * List of tags identifiers providing additional context or categorization. + * @type {Array} + * @memberof Token + */ + 'tags'?: Array; + /** + * The current price of the token in USD. + * @type {string} + * @memberof Token + */ + 'priceUSD'?: string; + /** + * + * @type {GetRoutes200ResponseRoutesInnerFromTokenExtensions} + * @memberof Token + */ + 'extensions'?: GetRoutes200ResponseRoutesInnerFromTokenExtensions; +} + +export const TokenChainTypeEnum = { + HyperledgerFabric: 'HyperledgerFabric', + HyperledgerBesu: 'HyperledgerBesu' +} as const; + +export type TokenChainTypeEnum = typeof TokenChainTypeEnum[keyof typeof TokenChainTypeEnum]; + +/** + * Response schema for a transaction request. Includes the session ID and the current status of the transaction. + * @export + * @interface Transact200Response + */ +export interface Transact200Response { + /** + * Unique identifier (UUID) for the session. + * @type {string} + * @memberof Transact200Response + */ + 'sessionID': string; + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof Transact200Response + */ + 'statusResponse': Transact200ResponseStatusResponse; +} +/** + * Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information. + * @export + * @interface Transact200ResponseStatusResponse + */ +export interface Transact200ResponseStatusResponse { + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'status': Transact200ResponseStatusResponseStatusEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'substatus': Transact200ResponseStatusResponseSubstatusEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'stage': Transact200ResponseStatusResponseStageEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'step': Transact200ResponseStatusResponseStepEnum; + /** + * + * @type {string} + * @memberof Transact200ResponseStatusResponse + */ + 'startTime': string; + /** + * + * @type {Transact200ResponseStatusResponseOriginChain} + * @memberof Transact200ResponseStatusResponse + */ + 'originChain': Transact200ResponseStatusResponseOriginChain; + /** + * + * @type {Transact200ResponseStatusResponseDestinationChain} + * @memberof Transact200ResponseStatusResponse + */ + 'destinationChain': Transact200ResponseStatusResponseDestinationChain; +} + +export const Transact200ResponseStatusResponseStatusEnum = { + NotFound: 'NOT_FOUND', + Invalid: 'INVALID', + Pending: 'PENDING', + Done: 'DONE', + Failed: 'FAILED' +} as const; + +export type Transact200ResponseStatusResponseStatusEnum = typeof Transact200ResponseStatusResponseStatusEnum[keyof typeof Transact200ResponseStatusResponseStatusEnum]; +export const Transact200ResponseStatusResponseSubstatusEnum = { + WaitSourceConfirmations: 'WAIT_SOURCE_CONFIRMATIONS', + WaitDestinationTransaction: 'WAIT_DESTINATION_TRANSACTION', + BridgeNotAvailable: 'BRIDGE_NOT_AVAILABLE', + ChainNotAvailable: 'CHAIN_NOT_AVAILABLE', + RefundInProgress: 'REFUND_IN_PROGRESS', + UnknownError: 'UNKNOWN_ERROR', + Completed: 'COMPLETED', + Partial: 'PARTIAL', + Refunded: 'REFUNDED', + NotProcessableRefundNeeded: 'NOT_PROCESSABLE_REFUND_NEEDED' +} as const; + +export type Transact200ResponseStatusResponseSubstatusEnum = typeof Transact200ResponseStatusResponseSubstatusEnum[keyof typeof Transact200ResponseStatusResponseSubstatusEnum]; +export const Transact200ResponseStatusResponseStageEnum = { + Stage0: 'STAGE0', + Stage1: 'STAGE1', + Stage2: 'STAGE2', + Stage3: 'STAGE3' +} as const; + +export type Transact200ResponseStatusResponseStageEnum = typeof Transact200ResponseStatusResponseStageEnum[keyof typeof Transact200ResponseStatusResponseStageEnum]; +export const Transact200ResponseStatusResponseStepEnum = { + TransferInitializationClaims: 'transfer-initialization-claims', + ConveyanceOfNetworkCapabilitiesAndParameters: 'conveyance-of-network-capabilities-and-parameters', + TransferProposalMessage: 'transfer-proposal-message', + TransferProposalReceiptMessage: 'transfer-proposal-receipt-message', + TransferProposalRejectAndConditionalRejectMessage: 'transfer-proposal-reject-and-conditional-reject-message', + TransferCommenceMessage: 'transfer-commence-message', + CommenceResponseMessage: 'commence-response-message', + LockAssertionMessage: 'lock-assertion-message', + LockAssertionReceiptMessage: 'lock-assertion-receipt-message', + CommitPreparationMessage: 'commit-preparation-message', + CommitReadyMessage: 'commit-ready-message', + CommitFinalAssertionMessage: 'commit-final-assertion-message', + CommitFinalAcknowledgementReceiptMessage: 'commit-final-acknowledgement-receipt-message', + TransferCompleteMessage: 'transfer-complete-message', + RollbackTransferInitializationClaims: 'rollback-transfer-initialization-claims', + RollbackConveyanceOfNetworkCapabilitiesAndParameters: 'rollback-conveyance-of-network-capabilities-and-parameters', + RollbackTransferProposalMessage: 'rollback-transfer-proposal-message', + RollbackTransferProposalReceiptMessage: 'rollback-transfer-proposal-receipt-message', + RollbackTransferProposalRejectAndConditionalRejectMessage: 'rollback-transfer-proposal-reject-and-conditional-reject-message', + RollbackTransferCommenceMessage: 'rollback-transfer-commence-message', + RollbackCommenceResponseMessage: 'rollback-commence-response-message', + RollbackLockAssertionMessage: 'rollback-lock-assertion-message', + RollbackLockAssertionReceiptMessage: 'rollback-lock-assertion-receipt-message', + RollbackCommitPreparationMessage: 'rollback-commit-preparation-message', + RollbackCommitReadyMessage: 'rollback-commit-ready-message', + RollbackCommitFinalAssertionMessage: 'rollback-commit-final-assertion-message', + RollbackCommitFinalAcknowledgementReceiptMessage: 'rollback-commit-final-acknowledgement-receipt-message', + RollbackTransferCompleteMessage: 'rollback-transfer-complete-message' +} as const; + +export type Transact200ResponseStatusResponseStepEnum = typeof Transact200ResponseStatusResponseStepEnum[keyof typeof Transact200ResponseStatusResponseStepEnum]; + +/** + * + * @export + * @interface Transact200ResponseStatusResponseDestinationChain + */ +export interface Transact200ResponseStatusResponseDestinationChain { + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseDestinationChain + */ + 'dltProtocol'?: any; + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseDestinationChain + */ + 'dltSubnetworkID'?: any; +} +/** + * + * @export + * @interface Transact200ResponseStatusResponseOriginChain + */ +export interface Transact200ResponseStatusResponseOriginChain { + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseOriginChain + */ + 'dltProtocol'?: any; + /** + * + * @type {any} + * @memberof Transact200ResponseStatusResponseOriginChain + */ + 'dltSubnetworkID'?: any; +} +/** + * An Error + * @export + * @interface TransactDefaultResponse + */ +export interface TransactDefaultResponse { + /** + * HTTP error type + * @type {string} + * @memberof TransactDefaultResponse + */ + 'type': string; + /** + * Numeric error code + * @type {number} + * @memberof TransactDefaultResponse + */ + 'code': number; + /** + * HTTP status of the error + * @type {number} + * @memberof TransactDefaultResponse + */ + 'status': number; + /** + * Long error description + * @type {string} + * @memberof TransactDefaultResponse + */ + 'message': string; + /** + * Timestamp of the error + * @type {string} + * @memberof TransactDefaultResponse + */ + 'timestamp': string; +} +/** + * Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks. + * @export + * @interface TransactRequest + */ +export interface TransactRequest { + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'contextID': string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'mode': TransactRequestModeEnum; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'payload'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'fromDLTNetworkID'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'toDLTNetworkID'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'fromAmount'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'fromToken'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'toAmount'?: string; + /** + * + * @type {string} + * @memberof TransactRequest + */ + 'toToken'?: string; +} + +export const TransactRequestModeEnum = { + Data: 'data', + Transfer: 'transfer' +} as const; + +export type TransactRequestModeEnum = typeof TransactRequestModeEnum[keyof typeof TransactRequestModeEnum]; + +/** + * Response schema for a transaction request. Includes the session ID and the current status of the transaction. + * @export + * @interface TransactResponse + */ +export interface TransactResponse { + /** + * Unique identifier (UUID) for the session. + * @type {string} + * @memberof TransactResponse + */ + 'sessionID': string; + /** + * + * @type {Transact200ResponseStatusResponse} + * @memberof TransactResponse + */ + 'statusResponse': Transact200ResponseStatusResponse; +} + +/** + * AdminApi - axios parameter creator + * @export + */ +export const AdminApiAxiosParamCreator = function (configuration?: Configuration) { + return { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + _continue: async (continueRequest: ContinueRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'continueRequest' is not null or undefined + assertParamExists('_continue', 'continueRequest', continueRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/continue`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(continueRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getAudit: async (auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options: AxiosRequestConfig = {}): Promise => { + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/audit`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + if (auditStartDate !== undefined) { + localVarQueryParameter['auditStartDate'] = (auditStartDate as any instanceof Date) ? + (auditStartDate as any).toISOString() : + auditStartDate; + } + + if (auditEndDate !== undefined) { + localVarQueryParameter['auditEndDate'] = (auditEndDate as any instanceof Date) ? + (auditEndDate as any).toISOString() : + auditEndDate; + } + + if (includeProofs !== undefined) { + localVarQueryParameter['includeProofs'] = includeProofs; + } + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getHealthCheck: async (options: AxiosRequestConfig = {}): Promise => { + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/healthcheck`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getStatus: async (sessionID: string, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'sessionID' is not null or undefined + assertParamExists('getStatus', 'sessionID', sessionID) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/status`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + if (sessionID !== undefined) { + localVarQueryParameter['SessionID'] = sessionID; + } + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + pause: async (pauseRequest: PauseRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'pauseRequest' is not null or undefined + assertParamExists('pause', 'pauseRequest', pauseRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/pause`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(pauseRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + } +}; + +/** + * AdminApi - functional programming interface + * @export + */ +export const AdminApiFp = function(configuration?: Configuration) { + const localVarAxiosParamCreator = AdminApiAxiosParamCreator(configuration) + return { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async _continue(continueRequest: ContinueRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator._continue(continueRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getAudit(auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getAudit(auditStartDate, auditEndDate, includeProofs, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getHealthCheck(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getHealthCheck(options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getStatus(sessionID: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getStatus(sessionID, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async pause(pauseRequest: PauseRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.pause(pauseRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + } +}; + +/** + * AdminApi - factory interface + * @export + */ +export const AdminApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { + const localVarFp = AdminApiFp(configuration) + return { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + _continue(continueRequest: ContinueRequest, options?: any): AxiosPromise { + return localVarFp._continue(continueRequest, options).then((request) => request(axios, basePath)); + }, + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getAudit(auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options?: any): AxiosPromise { + return localVarFp.getAudit(auditStartDate, auditEndDate, includeProofs, options).then((request) => request(axios, basePath)); + }, + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getHealthCheck(options?: any): AxiosPromise { + return localVarFp.getHealthCheck(options).then((request) => request(axios, basePath)); + }, + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getStatus(sessionID: string, options?: any): AxiosPromise { + return localVarFp.getStatus(sessionID, options).then((request) => request(axios, basePath)); + }, + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + pause(pauseRequest: PauseRequest, options?: any): AxiosPromise { + return localVarFp.pause(pauseRequest, options).then((request) => request(axios, basePath)); + }, + }; +}; + +/** + * AdminApi - object-oriented interface + * @export + * @class AdminApi + * @extends {BaseAPI} + */ +export class AdminApi extends BaseAPI { + /** + * Attempts to continue a previously paused transaction intent, resuming its execution. + * @summary Continue a paused transaction session + * @param {ContinueRequest} continueRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public _continue(continueRequest: ContinueRequest, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration)._continue(continueRequest, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + * @summary Audit transactions + * @param {string} [auditStartDate] The start date for the audit period. + * @param {string} [auditEndDate] The end date for the audit period. + * @param {boolean} [includeProofs] Include proofs generated from each gateway transaction. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public getAudit(auditStartDate?: string, auditEndDate?: string, includeProofs?: boolean, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).getAudit(auditStartDate, auditEndDate, includeProofs, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Responds if SATP Hermes is on + * @summary Health check endpoint + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public getHealthCheck(options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).getHealthCheck(options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Retrieve the status of a SATP session + * @summary Get SATP current session data + * @param {string} sessionID Unique identifier for the session. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public getStatus(sessionID: string, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).getStatus(sessionID, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + * @summary Pause a transaction session + * @param {PauseRequest} pauseRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AdminApi + */ + public pause(pauseRequest: PauseRequest, options?: AxiosRequestConfig) { + return AdminApiFp(this.configuration).pause(pauseRequest, options).then((request) => request(this.axios, this.basePath)); + } +} + + +/** + * TransactionApi - axios parameter creator + * @export + */ +export const TransactionApiAxiosParamCreator = function (configuration?: Configuration) { + return { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + cancel: async (cancelRequest: CancelRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'cancelRequest' is not null or undefined + assertParamExists('cancel', 'cancelRequest', cancelRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(cancelRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getIntegrations: async (options: AxiosRequestConfig = {}): Promise => { + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getRoutes: async (fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'fromNetworkID' is not null or undefined + assertParamExists('getRoutes', 'fromNetworkID', fromNetworkID) + // verify required parameter 'fromAmount' is not null or undefined + assertParamExists('getRoutes', 'fromAmount', fromAmount) + // verify required parameter 'fromToken' is not null or undefined + assertParamExists('getRoutes', 'fromToken', fromToken) + // verify required parameter 'toDLTNetwork' is not null or undefined + assertParamExists('getRoutes', 'toDLTNetwork', toDLTNetwork) + // verify required parameter 'toToken' is not null or undefined + assertParamExists('getRoutes', 'toToken', toToken) + // verify required parameter 'fromAddress' is not null or undefined + assertParamExists('getRoutes', 'fromAddress', fromAddress) + // verify required parameter 'toAddress' is not null or undefined + assertParamExists('getRoutes', 'toAddress', toAddress) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/routes`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + if (fromNetworkID !== undefined) { + localVarQueryParameter['fromNetworkID'] = fromNetworkID; + } + + if (fromAmount !== undefined) { + localVarQueryParameter['fromAmount'] = fromAmount; + } + + if (fromToken !== undefined) { + localVarQueryParameter['fromToken'] = fromToken; + } + + if (toDLTNetwork !== undefined) { + localVarQueryParameter['toDLTNetwork'] = toDLTNetwork; + } + + if (toToken !== undefined) { + localVarQueryParameter['toToken'] = toToken; + } + + if (fromAddress !== undefined) { + localVarQueryParameter['fromAddress'] = fromAddress; + } + + if (toAddress !== undefined) { + localVarQueryParameter['toAddress'] = toAddress; + } + + + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + transact: async (transactRequest: TransactRequest, options: AxiosRequestConfig = {}): Promise => { + // verify required parameter 'transactRequest' is not null or undefined + assertParamExists('transact', 'transactRequest', transactRequest) + const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/transact`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + + + localVarHeaderParameter['Content-Type'] = 'application/json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(transactRequest, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + } +}; + +/** + * TransactionApi - functional programming interface + * @export + */ +export const TransactionApiFp = function(configuration?: Configuration) { + const localVarAxiosParamCreator = TransactionApiAxiosParamCreator(configuration) + return { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async cancel(cancelRequest: CancelRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.cancel(cancelRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getIntegrations(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getIntegrations(options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getRoutes(fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.getRoutes(fromNetworkID, fromAmount, fromToken, toDLTNetwork, toToken, fromAddress, toAddress, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async transact(transactRequest: TransactRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.transact(transactRequest, options); + return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); + }, + } +}; + +/** + * TransactionApi - factory interface + * @export + */ +export const TransactionApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { + const localVarFp = TransactionApiFp(configuration) + return { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + cancel(cancelRequest: CancelRequest, options?: any): AxiosPromise { + return localVarFp.cancel(cancelRequest, options).then((request) => request(axios, basePath)); + }, + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getIntegrations(options?: any): AxiosPromise> { + return localVarFp.getIntegrations(options).then((request) => request(axios, basePath)); + }, + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getRoutes(fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options?: any): AxiosPromise { + return localVarFp.getRoutes(fromNetworkID, fromAmount, fromToken, toDLTNetwork, toToken, fromAddress, toAddress, options).then((request) => request(axios, basePath)); + }, + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + transact(transactRequest: TransactRequest, options?: any): AxiosPromise { + return localVarFp.transact(transactRequest, options).then((request) => request(axios, basePath)); + }, + }; +}; + +/** + * TransactionApi - object-oriented interface + * @export + * @class TransactionApi + * @extends {BaseAPI} + */ +export class TransactionApi extends BaseAPI { + /** + * Attempts to cancel a previously submitted transaction intent using its session ID. + * @summary Cancel a transaction session + * @param {CancelRequest} cancelRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public cancel(cancelRequest: CancelRequest, options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).cancel(cancelRequest, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Retrieves metadata about each supported blockchain networks, chains, and other systems. + * @summary Get supported integrations + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public getIntegrations(options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).getIntegrations(options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Get a list of possible routes for swapping one asset for another across multiple exchanges + * @summary Get a list of routes for a gateway-to-gateway asset transfer + * @param {string} fromNetworkID The sending DLT Network. + * @param {string} fromAmount The amount that should be sent including all decimals. + * @param {string} fromToken The token that should be transferred. Can be the address or the symbol. + * @param {string} toDLTNetwork The receiving DLT Network. + * @param {string} toToken The token that should be transferred to. Can be the address or the symbol. + * @param {string} fromAddress The sending wallet address. + * @param {string} toAddress The receiving wallet address. If none is provided, the fromAddress will be used. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public getRoutes(fromNetworkID: string, fromAmount: string, fromToken: string, toDLTNetwork: string, toToken: string, fromAddress: string, toAddress: string, options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).getRoutes(fromNetworkID, fromAmount, fromToken, toDLTNetwork, toToken, fromAddress, toAddress, options).then((request) => request(this.axios, this.basePath)); + } + + /** + * Allows users to queue intents for transactions based on specified parameters. + * @summary Submit a transaction intent + * @param {TransactRequest} transactRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionApi + */ + public transact(transactRequest: TransactRequest, options?: AxiosRequestConfig) { + return TransactionApiFp(this.configuration).transact(transactRequest, options).then((request) => request(this.axios, this.basePath)); + } +} + + diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/base.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/base.ts new file mode 100644 index 0000000000..59018f25b9 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/base.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import type { Configuration } from './configuration'; +// Some imports not used depending on template conditions +// @ts-ignore +import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios'; +import globalAxios from 'axios'; + +export const BASE_PATH = "http://localhost:3011/api/v1/@hyperledger/cactus-plugin-satp-hermes".replace(/\/+$/, ""); + +/** + * + * @export + */ +export const COLLECTION_FORMATS = { + csv: ",", + ssv: " ", + tsv: "\t", + pipes: "|", +}; + +/** + * + * @export + * @interface RequestArgs + */ +export interface RequestArgs { + url: string; + options: AxiosRequestConfig; +} + +/** + * + * @export + * @class BaseAPI + */ +export class BaseAPI { + protected configuration: Configuration | undefined; + + constructor(configuration?: Configuration, protected basePath: string = BASE_PATH, protected axios: AxiosInstance = globalAxios) { + if (configuration) { + this.configuration = configuration; + this.basePath = configuration.basePath || this.basePath; + } + } +}; + +/** + * + * @export + * @class RequiredError + * @extends {Error} + */ +export class RequiredError extends Error { + constructor(public field: string, msg?: string) { + super(msg); + this.name = "RequiredError" + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/common.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/common.ts new file mode 100644 index 0000000000..e2604cb54e --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/common.ts @@ -0,0 +1,150 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import type { Configuration } from "./configuration"; +import type { RequestArgs } from "./base"; +import type { AxiosInstance, AxiosResponse } from 'axios'; +import { RequiredError } from "./base"; + +/** + * + * @export + */ +export const DUMMY_BASE_URL = 'https://example.com' + +/** + * + * @throws {RequiredError} + * @export + */ +export const assertParamExists = function (functionName: string, paramName: string, paramValue: unknown) { + if (paramValue === null || paramValue === undefined) { + throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`); + } +} + +/** + * + * @export + */ +export const setApiKeyToObject = async function (object: any, keyParamName: string, configuration?: Configuration) { + if (configuration && configuration.apiKey) { + const localVarApiKeyValue = typeof configuration.apiKey === 'function' + ? await configuration.apiKey(keyParamName) + : await configuration.apiKey; + object[keyParamName] = localVarApiKeyValue; + } +} + +/** + * + * @export + */ +export const setBasicAuthToObject = function (object: any, configuration?: Configuration) { + if (configuration && (configuration.username || configuration.password)) { + object["auth"] = { username: configuration.username, password: configuration.password }; + } +} + +/** + * + * @export + */ +export const setBearerAuthToObject = async function (object: any, configuration?: Configuration) { + if (configuration && configuration.accessToken) { + const accessToken = typeof configuration.accessToken === 'function' + ? await configuration.accessToken() + : await configuration.accessToken; + object["Authorization"] = "Bearer " + accessToken; + } +} + +/** + * + * @export + */ +export const setOAuthToObject = async function (object: any, name: string, scopes: string[], configuration?: Configuration) { + if (configuration && configuration.accessToken) { + const localVarAccessTokenValue = typeof configuration.accessToken === 'function' + ? await configuration.accessToken(name, scopes) + : await configuration.accessToken; + object["Authorization"] = "Bearer " + localVarAccessTokenValue; + } +} + +function setFlattenedQueryParams(urlSearchParams: URLSearchParams, parameter: any, key: string = ""): void { + if (parameter == null) return; + if (typeof parameter === "object") { + if (Array.isArray(parameter)) { + (parameter as any[]).forEach(item => setFlattenedQueryParams(urlSearchParams, item, key)); + } + else { + Object.keys(parameter).forEach(currentKey => + setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`) + ); + } + } + else { + if (urlSearchParams.has(key)) { + urlSearchParams.append(key, parameter); + } + else { + urlSearchParams.set(key, parameter); + } + } +} + +/** + * + * @export + */ +export const setSearchParams = function (url: URL, ...objects: any[]) { + const searchParams = new URLSearchParams(url.search); + setFlattenedQueryParams(searchParams, objects); + url.search = searchParams.toString(); +} + +/** + * + * @export + */ +export const serializeDataIfNeeded = function (value: any, requestOptions: any, configuration?: Configuration) { + const nonString = typeof value !== 'string'; + const needsSerialization = nonString && configuration && configuration.isJsonMime + ? configuration.isJsonMime(requestOptions.headers['Content-Type']) + : nonString; + return needsSerialization + ? JSON.stringify(value !== undefined ? value : {}) + : (value || ""); +} + +/** + * + * @export + */ +export const toPathString = function (url: URL) { + return url.pathname + url.search + url.hash +} + +/** + * + * @export + */ +export const createRequestFunction = function (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) { + return >(axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => { + const axiosRequestArgs = {...axiosArgs.options, url: (configuration?.basePath || basePath) + axiosArgs.url}; + return axios.request(axiosRequestArgs); + }; +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/configuration.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/configuration.ts new file mode 100644 index 0000000000..a444ba448f --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/configuration.ts @@ -0,0 +1,101 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ConfigurationParameters { + apiKey?: string | Promise | ((name: string) => string) | ((name: string) => Promise); + username?: string; + password?: string; + accessToken?: string | Promise | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise); + basePath?: string; + baseOptions?: any; + formDataCtor?: new () => any; +} + +export class Configuration { + /** + * parameter for apiKey security + * @param name security name + * @memberof Configuration + */ + apiKey?: string | Promise | ((name: string) => string) | ((name: string) => Promise); + /** + * parameter for basic security + * + * @type {string} + * @memberof Configuration + */ + username?: string; + /** + * parameter for basic security + * + * @type {string} + * @memberof Configuration + */ + password?: string; + /** + * parameter for oauth2 security + * @param name security name + * @param scopes oauth2 scope + * @memberof Configuration + */ + accessToken?: string | Promise | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise); + /** + * override base path + * + * @type {string} + * @memberof Configuration + */ + basePath?: string; + /** + * base options for axios calls + * + * @type {any} + * @memberof Configuration + */ + baseOptions?: any; + /** + * The FormData constructor that will be used to create multipart form data + * requests. You can inject this here so that execution environments that + * do not support the FormData class can still run the generated client. + * + * @type {new () => FormData} + */ + formDataCtor?: new () => any; + + constructor(param: ConfigurationParameters = {}) { + this.apiKey = param.apiKey; + this.username = param.username; + this.password = param.password; + this.accessToken = param.accessToken; + this.basePath = param.basePath; + this.baseOptions = param.baseOptions; + this.formDataCtor = param.formDataCtor; + } + + /** + * Check if the given MIME is a JSON MIME. + * JSON MIME examples: + * application/json + * application/json; charset=UTF8 + * APPLICATION/JSON + * application/vnd.company+json + * @param mime - MIME (Multipurpose Internet Mail Extensions) + * @return True if the given MIME is JSON, false otherwise. + */ + public isJsonMime(mime: string): boolean { + const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i'); + return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json'); + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/index.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/index.ts new file mode 100644 index 0000000000..d13fdacf7f --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi-blo/typescript-axios/index.ts @@ -0,0 +1,18 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * SATP Gateway Client (Business Logic Orchestrator) + * SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. **Additional Resources**: - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + * + * The version of the OpenAPI document: 0.0.2 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export * from "./api"; +export * from "./configuration"; + diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi/typescript-axios/api.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi/typescript-axios/api.ts index 1124ba5bc7..5ee7dc12bb 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi/typescript-axios/api.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/generated/openapi/typescript-axios/api.ts @@ -102,6 +102,158 @@ export interface AssetProfile { */ 'ledgerRequirements'?: Array; } +/** + * + * @export + * @interface ClientRequestV1Request + */ +export interface ClientRequestV1Request { + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'version': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'loggingProfile': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'accessControlProfile': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'assetControlProfile': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'applicationProfile': string; + /** + * + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile} + * @memberof ClientRequestV1Request + */ + 'assetProfile': Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile; + /** + * + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfile} + * @memberof ClientRequestV1Request + */ + 'payloadProfile': Phase1TransferInitiationRequestV1RequestPayloadProfile; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'sourceGatewayDltSystem': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'recipientGatewayDltSystem': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'recipientGatewayPubkey': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'originatorPubkey': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'beneficiaryPubkey': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'clientDltSystem': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'serverDltSystem': string; + /** + * + * @type {ClientRequestV1RequestClientGatewayConfiguration} + * @memberof ClientRequestV1Request + */ + 'clientGatewayConfiguration': ClientRequestV1RequestClientGatewayConfiguration; + /** + * + * @type {ClientRequestV1RequestClientGatewayConfiguration} + * @memberof ClientRequestV1Request + */ + 'serverGatewayConfiguration': ClientRequestV1RequestClientGatewayConfiguration; + /** + * + * @type {number} + * @memberof ClientRequestV1Request + */ + 'maxRetries': number; + /** + * + * @type {number} + * @memberof ClientRequestV1Request + */ + 'maxTimeout': number; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'sourceLedgerAssetID': string; + /** + * + * @type {string} + * @memberof ClientRequestV1Request + */ + 'recipientLedgerAssetID': string; +} +/** + * + * @export + * @interface ClientRequestV1RequestClientGatewayConfiguration + */ +export interface ClientRequestV1RequestClientGatewayConfiguration { + /** + * + * @type {string} + * @memberof ClientRequestV1RequestClientGatewayConfiguration + */ + 'apiHost': string; +} /** * * @export @@ -140,16 +292,16 @@ export interface ClientV1Request { 'applicationProfile': string; /** * - * @type {AssetProfile} + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile} * @memberof ClientV1Request */ - 'assetProfile': AssetProfile; + 'assetProfile': Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile; /** * - * @type {PayloadProfile} + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfile} * @memberof ClientV1Request */ - 'payloadProfile': PayloadProfile; + 'payloadProfile': Phase1TransferInitiationRequestV1RequestPayloadProfile; /** * * @type {string} @@ -206,16 +358,16 @@ export interface ClientV1Request { 'serverDltSystem': string; /** * - * @type {ClientV1RequestClientGatewayConfiguration} + * @type {ClientRequestV1RequestClientGatewayConfiguration} * @memberof ClientV1Request */ - 'clientGatewayConfiguration': ClientV1RequestClientGatewayConfiguration; + 'clientGatewayConfiguration': ClientRequestV1RequestClientGatewayConfiguration; /** * - * @type {ClientV1RequestClientGatewayConfiguration} + * @type {ClientRequestV1RequestClientGatewayConfiguration} * @memberof ClientV1Request */ - 'serverGatewayConfiguration': ClientV1RequestClientGatewayConfiguration; + 'serverGatewayConfiguration': ClientRequestV1RequestClientGatewayConfiguration; /** * * @type {number} @@ -241,19 +393,6 @@ export interface ClientV1Request { */ 'recipientLedgerAssetID': string; } -/** - * - * @export - * @interface ClientV1RequestClientGatewayConfiguration - */ -export interface ClientV1RequestClientGatewayConfiguration { - /** - * - * @type {string} - * @memberof ClientV1RequestClientGatewayConfiguration - */ - 'apiHost': string; -} /** * * @export @@ -622,195 +761,1259 @@ export interface LockEvidenceV1Request { * @type {string} * @memberof LockEvidenceV1Request */ - 'clientIdentityPubkey': string; + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'lockEvidenceClaim': string; + /** + * + * @type {object} + * @memberof LockEvidenceV1Request + */ + 'lockEvidenceFormat'?: object | null; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'lockEvidenceExpiration': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'hashCommenceAckRequest': string; + /** + * + * @type {number} + * @memberof LockEvidenceV1Request + */ + 'clientTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'signature': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Request + */ + 'messageHash'?: string; + /** + * + * @type {number} + * @memberof LockEvidenceV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface LockEvidenceV1Response + */ +export interface LockEvidenceV1Response { + /** + * + * @type {string} + * @memberof LockEvidenceV1Response + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Response + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Response + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Response + */ + 'hashLockEvidenceRequest': string; + /** + * + * @type {number} + * @memberof LockEvidenceV1Response + */ + 'serverTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof LockEvidenceV1Response + */ + 'signature': string; + /** + * + * @type {string} + * @memberof LockEvidenceV1Response + */ + 'messageType': string; + /** + * + * @type {number} + * @memberof LockEvidenceV1Response + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface PayloadProfile + */ +export interface PayloadProfile { + /** + * + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile} + * @memberof PayloadProfile + */ + 'assetProfile': Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile; + /** + * + * @type {string} + * @memberof PayloadProfile + */ + 'capabilities'?: string; +} +/** + * + * @export + * @interface Phase1TransferInitiationRequestV1Request + */ +export interface Phase1TransferInitiationRequestV1Request { + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'version'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'developerURN'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'credentialProfile'?: Phase1TransferInitiationRequestV1RequestCredentialProfileEnum; + /** + * + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfile} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'payloadProfile': Phase1TransferInitiationRequestV1RequestPayloadProfile; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'applicationProfile': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'loggingProfile': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'accessControlProfile': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'signature': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'sourceGatewayPubkey': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'sourceGatewayDltSystem': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'recipientGatewayPubkey': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'recipientGatewayDltSystem': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'escrowType'?: Phase1TransferInitiationRequestV1RequestEscrowTypeEnum; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'expiryTime'?: string; + /** + * + * @type {boolean} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'multipleClaimsAllowed'?: boolean; + /** + * + * @type {boolean} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'multipleCancelsAllowed'?: boolean; + /** + * + * @type {object} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'permissions'?: object; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'origin'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'destination'?: string; + /** + * + * @type {object} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'subsequentCalls'?: object; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'histories'?: Array; + /** + * + * @type {number} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'sequenceNumber': number; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'sourceBasePath': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'recipientBasePath': string; + /** + * + * @type {number} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'maxRetries': number; + /** + * + * @type {number} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'maxTimeout': number; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'backupGatewaysAllowed': Array; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'recipientLedgerAssetID': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1Request + */ + 'sourceLedgerAssetID': string; +} + +export const Phase1TransferInitiationRequestV1RequestCredentialProfileEnum = { + Saml: 'SAML', + Oauth: 'OAUTH', + X509: 'X509' +} as const; + +export type Phase1TransferInitiationRequestV1RequestCredentialProfileEnum = typeof Phase1TransferInitiationRequestV1RequestCredentialProfileEnum[keyof typeof Phase1TransferInitiationRequestV1RequestCredentialProfileEnum]; +export const Phase1TransferInitiationRequestV1RequestEscrowTypeEnum = { + Faucet: 'FAUCET', + Timelock: 'TIMELOCK', + Hashlock: 'HASHLOCK', + Hashtimelock: 'HASHTIMELOCK', + Multiclaimpc: 'MULTICLAIMPC', + Destroy: 'DESTROY', + Burn: 'BURN' +} as const; + +export type Phase1TransferInitiationRequestV1RequestEscrowTypeEnum = typeof Phase1TransferInitiationRequestV1RequestEscrowTypeEnum[keyof typeof Phase1TransferInitiationRequestV1RequestEscrowTypeEnum]; + +/** + * + * @export + * @interface Phase1TransferInitiationRequestV1RequestHistoriesInner + */ +export interface Phase1TransferInitiationRequestV1RequestHistoriesInner { + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'Transactions'?: Array; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'Actions'?: Array; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'Origin'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'Destination'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'Balance'?: string; + /** + * + * @type {object} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'CurrentStatus'?: object; + /** + * + * @type {object} + * @memberof Phase1TransferInitiationRequestV1RequestHistoriesInner + */ + 'ApplicationSpecificParameters'?: object; +} +/** + * + * @export + * @interface Phase1TransferInitiationRequestV1RequestPayloadProfile + */ +export interface Phase1TransferInitiationRequestV1RequestPayloadProfile { + /** + * + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfile + */ + 'assetProfile': Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfile + */ + 'capabilities'?: string; +} +/** + * + * @export + * @interface Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ +export interface Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile { + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'issuer'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'assetCode'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'assetCodeType'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'issuanceDate'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'expirationDate': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'verificationEndPoint'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'digitalSignature'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'prospectusLink'?: string; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'keyInformationLink'?: Array; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'keyWord'?: Array; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'transferRestriction'?: Array; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile + */ + 'ledgerRequirements'?: Array; +} +/** + * + * @export + * @interface Phase1TransferInitiationResponseV1Request + */ +export interface Phase1TransferInitiationResponseV1Request { + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'sessionID': string; + /** + * + * @type {number} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'sequenceNumber': number; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'odapPhase'?: Phase1TransferInitiationResponseV1RequestOdapPhaseEnum; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'initialRequestMessageHash': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'destination'?: string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'timeStamp': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'processedTimeStamp': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'signature': string; + /** + * + * @type {Array} + * @memberof Phase1TransferInitiationResponseV1Request + */ + 'backupGatewaysAllowed': Array; +} + +export const Phase1TransferInitiationResponseV1RequestOdapPhaseEnum = { + TransferInitialization: 'TransferInitialization', + LockEvidenceVerification: 'LockEvidenceVerification', + CommitmentEstablishment: 'CommitmentEstablishment' +} as const; + +export type Phase1TransferInitiationResponseV1RequestOdapPhaseEnum = typeof Phase1TransferInitiationResponseV1RequestOdapPhaseEnum[keyof typeof Phase1TransferInitiationResponseV1RequestOdapPhaseEnum]; + +/** + * + * @export + * @interface Phase2LockEvidenceRequestV1Request + */ +export interface Phase2LockEvidenceRequestV1Request { + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'lockEvidenceClaim': string; + /** + * + * @type {object} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'lockEvidenceFormat'?: object | null; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'lockEvidenceExpiration': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'hashCommenceAckRequest': string; + /** + * + * @type {number} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'clientTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'signature': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'messageHash'?: string; + /** + * + * @type {number} + * @memberof Phase2LockEvidenceRequestV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase2LockEvidenceResponseV1Request + */ +export interface Phase2LockEvidenceResponseV1Request { + /** + * + * @type {string} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'hashLockEvidenceRequest': string; + /** + * + * @type {number} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'serverTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'signature': string; + /** + * + * @type {string} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'messageType': string; + /** + * + * @type {number} + * @memberof Phase2LockEvidenceResponseV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase2TransferCommenceRequestV1Request + */ +export interface Phase2TransferCommenceRequestV1Request { + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'originatorPubkey': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'beneficiaryPubkey': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'senderDltSystem': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'recipientDltSystem': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'hashAssetProfile': string; + /** + * + * @type {number} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'assetUnit'?: number; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'hashPrevMessage': string; + /** + * + * @type {number} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'clientTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'signature': string; + /** + * + * @type {number} + * @memberof Phase2TransferCommenceRequestV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase2TransferCommenceResponseV1Request + */ +export interface Phase2TransferCommenceResponseV1Request { + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'hashCommenceRequest': string; + /** + * + * @type {number} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'serverTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'signature': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'messageHash'?: string; + /** + * + * @type {number} + * @memberof Phase2TransferCommenceResponseV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase3CommitFinalRequestV1Request + */ +export interface Phase3CommitFinalRequestV1Request { + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'commitFinalClaim': string; + /** + * + * @type {object} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'commitFinalClaimFormat'?: object; + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'hashCommitPrepareAck': string; + /** + * + * @type {number} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'clientTransferNumber'?: number | null; + /** + * + * @type {string} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'signature': string; + /** + * + * @type {number} + * @memberof Phase3CommitFinalRequestV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase3CommitFinalResponseV1Request + */ +export interface Phase3CommitFinalResponseV1Request { + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'commitAcknowledgementClaim': string; + /** + * + * @type {object} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'commitAcknowledgementClaimFormat'?: object; + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'hashCommitFinal': string; + /** + * + * @type {number} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'serverTransferNumber'?: number; + /** + * + * @type {string} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'signature': string; + /** + * + * @type {number} + * @memberof Phase3CommitFinalResponseV1Request + */ + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase3CommitPreparationRequestV1Request + */ +export interface Phase3CommitPreparationRequestV1Request { + /** + * + * @type {string} + * @memberof Phase3CommitPreparationRequestV1Request + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof Phase3CommitPreparationRequestV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase3CommitPreparationRequestV1Request + */ + 'clientIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase3CommitPreparationRequestV1Request + */ + 'serverIdentityPubkey': string; + /** + * + * @type {string} + * @memberof Phase3CommitPreparationRequestV1Request + */ + 'hashLockEvidenceAck': string; + /** + * + * @type {number} + * @memberof Phase3CommitPreparationRequestV1Request + */ + 'clientTransferNumber'?: number; /** * * @type {string} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationRequestV1Request */ - 'serverIdentityPubkey': string; + 'signature': string; /** * - * @type {string} - * @memberof LockEvidenceV1Request + * @type {number} + * @memberof Phase3CommitPreparationRequestV1Request */ - 'lockEvidenceClaim': string; + 'sequenceNumber': number; +} +/** + * + * @export + * @interface Phase3CommitPreparationResponseV1Request + */ +export interface Phase3CommitPreparationResponseV1Request { /** * - * @type {object} - * @memberof LockEvidenceV1Request + * @type {string} + * @memberof Phase3CommitPreparationResponseV1Request */ - 'lockEvidenceFormat'?: object; + 'sessionID': string; /** * * @type {string} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationResponseV1Request */ - 'lockEvidenceExpiration': string; + 'messageType': string; /** * * @type {string} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationResponseV1Request */ - 'hashCommenceAckRequest': string; + 'clientIdentityPubkey': string; /** * - * @type {number} - * @memberof LockEvidenceV1Request + * @type {string} + * @memberof Phase3CommitPreparationResponseV1Request */ - 'clientTransferNumber'?: number | null; + 'serverIdentityPubkey': string; /** * * @type {string} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationResponseV1Request */ - 'signature': string; + 'hashCommitPrep': string; /** * * @type {string} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationResponseV1Request */ - 'messageType': string; + 'serverTransferNumber'?: string; /** * * @type {string} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationResponseV1Request */ - 'messageHash'?: string; + 'signature': string; /** * * @type {number} - * @memberof LockEvidenceV1Request + * @memberof Phase3CommitPreparationResponseV1Request */ 'sequenceNumber': number; } /** * * @export - * @interface LockEvidenceV1Response + * @interface Phase3TransferCompleteRequestV1Request */ -export interface LockEvidenceV1Response { +export interface Phase3TransferCompleteRequestV1Request { /** * * @type {string} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ 'sessionID': string; /** * * @type {string} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request + */ + 'messageType': string; + /** + * + * @type {string} + * @memberof Phase3TransferCompleteRequestV1Request */ 'clientIdentityPubkey': string; /** * * @type {string} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ 'serverIdentityPubkey': string; /** * * @type {string} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ - 'hashLockEvidenceRequest': string; + 'hashCommitFinalAck': string; /** * * @type {number} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ - 'serverTransferNumber'?: number | null; + 'clientTransferNumber'?: number | null; /** * * @type {string} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ 'signature': string; /** * * @type {string} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ - 'messageType': string; + 'hashTransferCommence': string; /** * * @type {number} - * @memberof LockEvidenceV1Response + * @memberof Phase3TransferCompleteRequestV1Request */ 'sequenceNumber': number; } /** * * @export - * @interface PayloadProfile + * @interface RecoverSuccessV1Message */ -export interface PayloadProfile { +export interface RecoverSuccessV1Message { /** * - * @type {AssetProfile} - * @memberof PayloadProfile + * @type {string} + * @memberof RecoverSuccessV1Message + */ + 'sessionID': string; + /** + * + * @type {boolean} + * @memberof RecoverSuccessV1Message */ - 'assetProfile': AssetProfile; + 'success': boolean; /** * * @type {string} - * @memberof PayloadProfile + * @memberof RecoverSuccessV1Message */ - 'capabilities'?: string; + 'signature': string; } /** * * @export - * @interface RecoverSuccessV1Message + * @interface RecoverUpdateAckV1Message */ -export interface RecoverSuccessV1Message { +export interface RecoverUpdateAckV1Message { /** * * @type {string} - * @memberof RecoverSuccessV1Message + * @memberof RecoverUpdateAckV1Message */ 'sessionID': string; /** * * @type {boolean} - * @memberof RecoverSuccessV1Message + * @memberof RecoverUpdateAckV1Message */ 'success': boolean; + /** + * + * @type {Array} + * @memberof RecoverUpdateAckV1Message + */ + 'changedEntriesHash': Array; /** * * @type {string} - * @memberof RecoverSuccessV1Message + * @memberof RecoverUpdateAckV1Message */ 'signature': string; } /** * * @export - * @interface RecoverUpdateAckV1Message + * @interface RecoverUpdateAckV1MessageRequest */ -export interface RecoverUpdateAckV1Message { +export interface RecoverUpdateAckV1MessageRequest { /** * * @type {string} - * @memberof RecoverUpdateAckV1Message + * @memberof RecoverUpdateAckV1MessageRequest */ 'sessionID': string; /** * * @type {boolean} - * @memberof RecoverUpdateAckV1Message + * @memberof RecoverUpdateAckV1MessageRequest */ 'success': boolean; /** * * @type {Array} - * @memberof RecoverUpdateAckV1Message + * @memberof RecoverUpdateAckV1MessageRequest */ 'changedEntriesHash': Array; /** * * @type {string} - * @memberof RecoverUpdateAckV1Message + * @memberof RecoverUpdateAckV1MessageRequest */ 'signature': string; } @@ -828,10 +2031,10 @@ export interface RecoverUpdateV1Message { 'sessionID': string; /** * - * @type {Array} + * @type {Array} * @memberof RecoverUpdateV1Message */ - 'recoveredLogs': Array; + 'recoveredLogs': Array; /** * * @type {string} @@ -839,6 +2042,74 @@ export interface RecoverUpdateV1Message { */ 'signature': string; } +/** + * + * @export + * @interface RecoverUpdateV1MessageRequest + */ +export interface RecoverUpdateV1MessageRequest { + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequest + */ + 'sessionID': string; + /** + * + * @type {Array} + * @memberof RecoverUpdateV1MessageRequest + */ + 'recoveredLogs': Array; + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequest + */ + 'signature': string; +} +/** + * + * @export + * @interface RecoverUpdateV1MessageRequestRecoveredLogsInner + */ +export interface RecoverUpdateV1MessageRequestRecoveredLogsInner { + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequestRecoveredLogsInner + */ + 'key'?: string; + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequestRecoveredLogsInner + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequestRecoveredLogsInner + */ + 'data'?: string; + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequestRecoveredLogsInner + */ + 'type': string; + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequestRecoveredLogsInner + */ + 'operation': string; + /** + * + * @type {string} + * @memberof RecoverUpdateV1MessageRequestRecoveredLogsInner + */ + 'timestamp'?: string; +} /** * * @export @@ -894,6 +2165,86 @@ export interface RecoverV1Message { */ 'signature': string; } +/** + * + * @export + * @interface RecoverV1MessageRequest + */ +export interface RecoverV1MessageRequest { + /** + * + * @type {string} + * @memberof RecoverV1MessageRequest + */ + 'sessionID': string; + /** + * + * @type {string} + * @memberof RecoverV1MessageRequest + */ + 'odapPhase': string; + /** + * + * @type {number} + * @memberof RecoverV1MessageRequest + */ + 'sequenceNumber': number; + /** + * + * @type {string} + * @memberof RecoverV1MessageRequest + */ + 'lastLogEntryTimestamp': string; + /** + * + * @type {boolean} + * @memberof RecoverV1MessageRequest + */ + 'isBackup': boolean; + /** + * + * @type {string} + * @memberof RecoverV1MessageRequest + */ + 'newBasePath': string; + /** + * + * @type {string} + * @memberof RecoverV1MessageRequest + */ + 'newGatewayPubKey'?: string; + /** + * + * @type {string} + * @memberof RecoverV1MessageRequest + */ + 'signature': string; +} +/** + * + * @export + * @interface RecoverV1SuccessRequest + */ +export interface RecoverV1SuccessRequest { + /** + * + * @type {string} + * @memberof RecoverV1SuccessRequest + */ + 'sessionID': string; + /** + * + * @type {boolean} + * @memberof RecoverV1SuccessRequest + */ + 'success': boolean; + /** + * + * @type {string} + * @memberof RecoverV1SuccessRequest + */ + 'signature': string; +} /** * * @export @@ -956,6 +2307,43 @@ export interface RollbackV1Message { */ 'signature': string; } +/** + * + * @export + * @interface RollbackV1MessageRequest + */ +export interface RollbackV1MessageRequest { + /** + * + * @type {string} + * @memberof RollbackV1MessageRequest + */ + 'sessionID': string; + /** + * + * @type {boolean} + * @memberof RollbackV1MessageRequest + */ + 'success': boolean; + /** + * + * @type {Array} + * @memberof RollbackV1MessageRequest + */ + 'actionPerformed': Array; + /** + * + * @type {Array} + * @memberof RollbackV1MessageRequest + */ + 'proofs': Array; + /** + * + * @type {string} + * @memberof RollbackV1MessageRequest + */ + 'signature': string; +} /** * * @export @@ -1006,10 +2394,10 @@ export interface SatpMessage { 'CredentialBlock'?: Array; /** * - * @type {PayloadProfile} + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfile} * @memberof SatpMessage */ - 'CredentialsProfile'?: PayloadProfile; + 'CredentialsProfile'?: Phase1TransferInitiationRequestV1RequestPayloadProfile; /** * * @type {object} @@ -1128,16 +2516,16 @@ export interface SessionData { 'applicationProfile'?: string; /** * - * @type {PayloadProfile} + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfile} * @memberof SessionData */ - 'payloadProfile'?: PayloadProfile; + 'payloadProfile'?: Phase1TransferInitiationRequestV1RequestPayloadProfile; /** * - * @type {AssetProfile} + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile} * @memberof SessionData */ - 'assetProfile'?: AssetProfile; + 'assetProfile'?: Phase1TransferInitiationRequestV1RequestPayloadProfileAssetProfile; /** * * @type {Array} @@ -1706,16 +3094,16 @@ export interface TransferInitializationV1Request { 'developerURN'?: string; /** * - * @type {CredentialProfile} + * @type {string} * @memberof TransferInitializationV1Request */ - 'credentialProfile'?: CredentialProfile; + 'credentialProfile'?: TransferInitializationV1RequestCredentialProfileEnum; /** * - * @type {PayloadProfile} + * @type {Phase1TransferInitiationRequestV1RequestPayloadProfile} * @memberof TransferInitializationV1Request */ - 'payloadProfile': PayloadProfile; + 'payloadProfile': Phase1TransferInitiationRequestV1RequestPayloadProfile; /** * * @type {string} @@ -1814,10 +3202,10 @@ export interface TransferInitializationV1Request { 'subsequentCalls'?: object; /** * - * @type {Array} + * @type {Array} * @memberof TransferInitializationV1Request */ - 'histories'?: Array; + 'histories'?: Array; /** * * @type {number} @@ -1868,6 +3256,13 @@ export interface TransferInitializationV1Request { 'sourceLedgerAssetID': string; } +export const TransferInitializationV1RequestCredentialProfileEnum = { + Saml: 'SAML', + Oauth: 'OAUTH', + X509: 'X509' +} as const; + +export type TransferInitializationV1RequestCredentialProfileEnum = typeof TransferInitializationV1RequestCredentialProfileEnum[keyof typeof TransferInitializationV1RequestCredentialProfileEnum]; export const TransferInitializationV1RequestEscrowTypeEnum = { Faucet: 'FAUCET', Timelock: 'TIMELOCK', @@ -1971,11 +3366,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati return { /** * - * @param {ClientV1Request} [clientV1Request] + * @param {ClientRequestV1Request} [clientRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - clientRequestV1: async (clientV1Request?: ClientV1Request, options: AxiosRequestConfig = {}): Promise => { + clientRequestV1: async (clientRequestV1Request?: ClientRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/clientrequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -1995,7 +3390,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(clientV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(clientRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2004,11 +3399,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {TransferInitializationV1Request} [transferInitializationV1Request] + * @param {Phase1TransferInitiationRequestV1Request} [phase1TransferInitiationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase1TransferInitiationRequestV1: async (transferInitializationV1Request?: TransferInitializationV1Request, options: AxiosRequestConfig = {}): Promise => { + phase1TransferInitiationRequestV1: async (phase1TransferInitiationRequestV1Request?: Phase1TransferInitiationRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationrequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2028,7 +3423,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(transferInitializationV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase1TransferInitiationRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2037,11 +3432,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {TransferInitializationV1Response} [transferInitializationV1Response] + * @param {Phase1TransferInitiationResponseV1Request} [phase1TransferInitiationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase1TransferInitiationResponseV1: async (transferInitializationV1Response?: TransferInitializationV1Response, options: AxiosRequestConfig = {}): Promise => { + phase1TransferInitiationResponseV1: async (phase1TransferInitiationResponseV1Request?: Phase1TransferInitiationResponseV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationresponse`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2061,7 +3456,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(transferInitializationV1Response, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase1TransferInitiationResponseV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2070,11 +3465,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {LockEvidenceV1Request} [lockEvidenceV1Request] + * @param {Phase2LockEvidenceRequestV1Request} [phase2LockEvidenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2LockEvidenceRequestV1: async (lockEvidenceV1Request?: LockEvidenceV1Request, options: AxiosRequestConfig = {}): Promise => { + phase2LockEvidenceRequestV1: async (phase2LockEvidenceRequestV1Request?: Phase2LockEvidenceRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidencerequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2094,7 +3489,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(lockEvidenceV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase2LockEvidenceRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2103,11 +3498,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {LockEvidenceV1Response} [lockEvidenceV1Response] + * @param {Phase2LockEvidenceResponseV1Request} [phase2LockEvidenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2LockEvidenceResponseV1: async (lockEvidenceV1Response?: LockEvidenceV1Response, options: AxiosRequestConfig = {}): Promise => { + phase2LockEvidenceResponseV1: async (phase2LockEvidenceResponseV1Request?: Phase2LockEvidenceResponseV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidenceresponse`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2127,7 +3522,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(lockEvidenceV1Response, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase2LockEvidenceResponseV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2136,11 +3531,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {TransferCommenceV1Request} [transferCommenceV1Request] + * @param {Phase2TransferCommenceRequestV1Request} [phase2TransferCommenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2TransferCommenceRequestV1: async (transferCommenceV1Request?: TransferCommenceV1Request, options: AxiosRequestConfig = {}): Promise => { + phase2TransferCommenceRequestV1: async (phase2TransferCommenceRequestV1Request?: Phase2TransferCommenceRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommencerequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2160,7 +3555,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(transferCommenceV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase2TransferCommenceRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2169,11 +3564,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {TransferCommenceV1Response} [transferCommenceV1Response] + * @param {Phase2TransferCommenceResponseV1Request} [phase2TransferCommenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2TransferCommenceResponseV1: async (transferCommenceV1Response?: TransferCommenceV1Response, options: AxiosRequestConfig = {}): Promise => { + phase2TransferCommenceResponseV1: async (phase2TransferCommenceResponseV1Request?: Phase2TransferCommenceResponseV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommenceresponse`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2193,7 +3588,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(transferCommenceV1Response, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase2TransferCommenceResponseV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2202,11 +3597,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {CommitFinalV1Request} [commitFinalV1Request] + * @param {Phase3CommitFinalRequestV1Request} [phase3CommitFinalRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitFinalRequestV1: async (commitFinalV1Request?: CommitFinalV1Request, options: AxiosRequestConfig = {}): Promise => { + phase3CommitFinalRequestV1: async (phase3CommitFinalRequestV1Request?: Phase3CommitFinalRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalrequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2226,7 +3621,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(commitFinalV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase3CommitFinalRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2235,11 +3630,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {CommitFinalV1Response} [commitFinalV1Response] + * @param {Phase3CommitFinalResponseV1Request} [phase3CommitFinalResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitFinalResponseV1: async (commitFinalV1Response?: CommitFinalV1Response, options: AxiosRequestConfig = {}): Promise => { + phase3CommitFinalResponseV1: async (phase3CommitFinalResponseV1Request?: Phase3CommitFinalResponseV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalresponse`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2259,7 +3654,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(commitFinalV1Response, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase3CommitFinalResponseV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2268,11 +3663,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {CommitPreparationV1Request} [commitPreparationV1Request] + * @param {Phase3CommitPreparationRequestV1Request} [phase3CommitPreparationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitPreparationRequestV1: async (commitPreparationV1Request?: CommitPreparationV1Request, options: AxiosRequestConfig = {}): Promise => { + phase3CommitPreparationRequestV1: async (phase3CommitPreparationRequestV1Request?: Phase3CommitPreparationRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationrequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2292,7 +3687,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(commitPreparationV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase3CommitPreparationRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2301,11 +3696,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {CommitPreparationV1Response} [commitPreparationV1Response] + * @param {Phase3CommitPreparationResponseV1Request} [phase3CommitPreparationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitPreparationResponseV1: async (commitPreparationV1Response?: CommitPreparationV1Response, options: AxiosRequestConfig = {}): Promise => { + phase3CommitPreparationResponseV1: async (phase3CommitPreparationResponseV1Request?: Phase3CommitPreparationResponseV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationresponse`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2325,7 +3720,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(commitPreparationV1Response, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase3CommitPreparationResponseV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2334,11 +3729,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {TransferCompleteV1Request} [transferCompleteV1Request] + * @param {Phase3TransferCompleteRequestV1Request} [phase3TransferCompleteRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3TransferCompleteRequestV1: async (transferCompleteV1Request?: TransferCompleteV1Request, options: AxiosRequestConfig = {}): Promise => { + phase3TransferCompleteRequestV1: async (phase3TransferCompleteRequestV1Request?: Phase3TransferCompleteRequestV1Request, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/transfercompleterequest`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2358,7 +3753,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(transferCompleteV1Request, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(phase3TransferCompleteRequestV1Request, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2367,11 +3762,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {RecoverUpdateAckV1Message} [recoverUpdateAckV1Message] + * @param {RecoverUpdateAckV1MessageRequest} [recoverUpdateAckV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverUpdateAckV1Message: async (recoverUpdateAckV1Message?: RecoverUpdateAckV1Message, options: AxiosRequestConfig = {}): Promise => { + recoverUpdateAckV1Message: async (recoverUpdateAckV1MessageRequest?: RecoverUpdateAckV1MessageRequest, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdateackmessage`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2391,7 +3786,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(recoverUpdateAckV1Message, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(recoverUpdateAckV1MessageRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2400,11 +3795,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {RecoverUpdateV1Message} [recoverUpdateV1Message] + * @param {RecoverUpdateV1MessageRequest} [recoverUpdateV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverUpdateV1Message: async (recoverUpdateV1Message?: RecoverUpdateV1Message, options: AxiosRequestConfig = {}): Promise => { + recoverUpdateV1Message: async (recoverUpdateV1MessageRequest?: RecoverUpdateV1MessageRequest, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdatemessage`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2424,7 +3819,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(recoverUpdateV1Message, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(recoverUpdateV1MessageRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2433,11 +3828,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {RecoverV1Message} [recoverV1Message] + * @param {RecoverV1MessageRequest} [recoverV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverV1Message: async (recoverV1Message?: RecoverV1Message, options: AxiosRequestConfig = {}): Promise => { + recoverV1Message: async (recoverV1MessageRequest?: RecoverV1MessageRequest, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/recovermessage`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2457,7 +3852,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(recoverV1Message, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(recoverV1MessageRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2466,11 +3861,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {RecoverSuccessV1Message} [recoverSuccessV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverV1Success: async (recoverSuccessV1Message?: RecoverSuccessV1Message, options: AxiosRequestConfig = {}): Promise => { + recoverV1Success: async (recoverV1SuccessRequest?: RecoverV1SuccessRequest, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/recoversuccessmessage`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2490,7 +3885,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(recoverSuccessV1Message, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(recoverV1SuccessRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2499,11 +3894,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {RollbackAckV1Message} [rollbackAckV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - rollbackAckV1Message: async (rollbackAckV1Message?: RollbackAckV1Message, options: AxiosRequestConfig = {}): Promise => { + rollbackAckV1Message: async (recoverV1SuccessRequest?: RecoverV1SuccessRequest, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackackmessage`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2523,7 +3918,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(rollbackAckV1Message, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(recoverV1SuccessRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2532,11 +3927,11 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati }, /** * - * @param {RollbackV1Message} [rollbackV1Message] + * @param {RollbackV1MessageRequest} [rollbackV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - rollbackV1Message: async (rollbackV1Message?: RollbackV1Message, options: AxiosRequestConfig = {}): Promise => { + rollbackV1Message: async (rollbackV1MessageRequest?: RollbackV1MessageRequest, options: AxiosRequestConfig = {}): Promise => { const localVarPath = `/api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackmessage`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); @@ -2556,7 +3951,7 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - localVarRequestOptions.data = serializeDataIfNeeded(rollbackV1Message, localVarRequestOptions, configuration) + localVarRequestOptions.data = serializeDataIfNeeded(rollbackV1MessageRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), @@ -2575,182 +3970,182 @@ export const DefaultApiFp = function(configuration?: Configuration) { return { /** * - * @param {ClientV1Request} [clientV1Request] + * @param {ClientRequestV1Request} [clientRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async clientRequestV1(clientV1Request?: ClientV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.clientRequestV1(clientV1Request, options); + async clientRequestV1(clientRequestV1Request?: ClientRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.clientRequestV1(clientRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {TransferInitializationV1Request} [transferInitializationV1Request] + * @param {Phase1TransferInitiationRequestV1Request} [phase1TransferInitiationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase1TransferInitiationRequestV1(transferInitializationV1Request?: TransferInitializationV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase1TransferInitiationRequestV1(transferInitializationV1Request, options); + async phase1TransferInitiationRequestV1(phase1TransferInitiationRequestV1Request?: Phase1TransferInitiationRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase1TransferInitiationRequestV1(phase1TransferInitiationRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {TransferInitializationV1Response} [transferInitializationV1Response] + * @param {Phase1TransferInitiationResponseV1Request} [phase1TransferInitiationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase1TransferInitiationResponseV1(transferInitializationV1Response?: TransferInitializationV1Response, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase1TransferInitiationResponseV1(transferInitializationV1Response, options); + async phase1TransferInitiationResponseV1(phase1TransferInitiationResponseV1Request?: Phase1TransferInitiationResponseV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase1TransferInitiationResponseV1(phase1TransferInitiationResponseV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {LockEvidenceV1Request} [lockEvidenceV1Request] + * @param {Phase2LockEvidenceRequestV1Request} [phase2LockEvidenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase2LockEvidenceRequestV1(lockEvidenceV1Request?: LockEvidenceV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase2LockEvidenceRequestV1(lockEvidenceV1Request, options); + async phase2LockEvidenceRequestV1(phase2LockEvidenceRequestV1Request?: Phase2LockEvidenceRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase2LockEvidenceRequestV1(phase2LockEvidenceRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {LockEvidenceV1Response} [lockEvidenceV1Response] + * @param {Phase2LockEvidenceResponseV1Request} [phase2LockEvidenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase2LockEvidenceResponseV1(lockEvidenceV1Response?: LockEvidenceV1Response, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase2LockEvidenceResponseV1(lockEvidenceV1Response, options); + async phase2LockEvidenceResponseV1(phase2LockEvidenceResponseV1Request?: Phase2LockEvidenceResponseV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase2LockEvidenceResponseV1(phase2LockEvidenceResponseV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {TransferCommenceV1Request} [transferCommenceV1Request] + * @param {Phase2TransferCommenceRequestV1Request} [phase2TransferCommenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase2TransferCommenceRequestV1(transferCommenceV1Request?: TransferCommenceV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase2TransferCommenceRequestV1(transferCommenceV1Request, options); + async phase2TransferCommenceRequestV1(phase2TransferCommenceRequestV1Request?: Phase2TransferCommenceRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase2TransferCommenceRequestV1(phase2TransferCommenceRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {TransferCommenceV1Response} [transferCommenceV1Response] + * @param {Phase2TransferCommenceResponseV1Request} [phase2TransferCommenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase2TransferCommenceResponseV1(transferCommenceV1Response?: TransferCommenceV1Response, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase2TransferCommenceResponseV1(transferCommenceV1Response, options); + async phase2TransferCommenceResponseV1(phase2TransferCommenceResponseV1Request?: Phase2TransferCommenceResponseV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase2TransferCommenceResponseV1(phase2TransferCommenceResponseV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {CommitFinalV1Request} [commitFinalV1Request] + * @param {Phase3CommitFinalRequestV1Request} [phase3CommitFinalRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase3CommitFinalRequestV1(commitFinalV1Request?: CommitFinalV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitFinalRequestV1(commitFinalV1Request, options); + async phase3CommitFinalRequestV1(phase3CommitFinalRequestV1Request?: Phase3CommitFinalRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitFinalRequestV1(phase3CommitFinalRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {CommitFinalV1Response} [commitFinalV1Response] + * @param {Phase3CommitFinalResponseV1Request} [phase3CommitFinalResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase3CommitFinalResponseV1(commitFinalV1Response?: CommitFinalV1Response, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitFinalResponseV1(commitFinalV1Response, options); + async phase3CommitFinalResponseV1(phase3CommitFinalResponseV1Request?: Phase3CommitFinalResponseV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitFinalResponseV1(phase3CommitFinalResponseV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {CommitPreparationV1Request} [commitPreparationV1Request] + * @param {Phase3CommitPreparationRequestV1Request} [phase3CommitPreparationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase3CommitPreparationRequestV1(commitPreparationV1Request?: CommitPreparationV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitPreparationRequestV1(commitPreparationV1Request, options); + async phase3CommitPreparationRequestV1(phase3CommitPreparationRequestV1Request?: Phase3CommitPreparationRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitPreparationRequestV1(phase3CommitPreparationRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {CommitPreparationV1Response} [commitPreparationV1Response] + * @param {Phase3CommitPreparationResponseV1Request} [phase3CommitPreparationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase3CommitPreparationResponseV1(commitPreparationV1Response?: CommitPreparationV1Response, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitPreparationResponseV1(commitPreparationV1Response, options); + async phase3CommitPreparationResponseV1(phase3CommitPreparationResponseV1Request?: Phase3CommitPreparationResponseV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase3CommitPreparationResponseV1(phase3CommitPreparationResponseV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {TransferCompleteV1Request} [transferCompleteV1Request] + * @param {Phase3TransferCompleteRequestV1Request} [phase3TransferCompleteRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async phase3TransferCompleteRequestV1(transferCompleteV1Request?: TransferCompleteV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.phase3TransferCompleteRequestV1(transferCompleteV1Request, options); + async phase3TransferCompleteRequestV1(phase3TransferCompleteRequestV1Request?: Phase3TransferCompleteRequestV1Request, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.phase3TransferCompleteRequestV1(phase3TransferCompleteRequestV1Request, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {RecoverUpdateAckV1Message} [recoverUpdateAckV1Message] + * @param {RecoverUpdateAckV1MessageRequest} [recoverUpdateAckV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async recoverUpdateAckV1Message(recoverUpdateAckV1Message?: RecoverUpdateAckV1Message, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.recoverUpdateAckV1Message(recoverUpdateAckV1Message, options); + async recoverUpdateAckV1Message(recoverUpdateAckV1MessageRequest?: RecoverUpdateAckV1MessageRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.recoverUpdateAckV1Message(recoverUpdateAckV1MessageRequest, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {RecoverUpdateV1Message} [recoverUpdateV1Message] + * @param {RecoverUpdateV1MessageRequest} [recoverUpdateV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async recoverUpdateV1Message(recoverUpdateV1Message?: RecoverUpdateV1Message, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.recoverUpdateV1Message(recoverUpdateV1Message, options); + async recoverUpdateV1Message(recoverUpdateV1MessageRequest?: RecoverUpdateV1MessageRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.recoverUpdateV1Message(recoverUpdateV1MessageRequest, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {RecoverV1Message} [recoverV1Message] + * @param {RecoverV1MessageRequest} [recoverV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async recoverV1Message(recoverV1Message?: RecoverV1Message, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.recoverV1Message(recoverV1Message, options); + async recoverV1Message(recoverV1MessageRequest?: RecoverV1MessageRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.recoverV1Message(recoverV1MessageRequest, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {RecoverSuccessV1Message} [recoverSuccessV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async recoverV1Success(recoverSuccessV1Message?: RecoverSuccessV1Message, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.recoverV1Success(recoverSuccessV1Message, options); + async recoverV1Success(recoverV1SuccessRequest?: RecoverV1SuccessRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.recoverV1Success(recoverV1SuccessRequest, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {RollbackAckV1Message} [rollbackAckV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async rollbackAckV1Message(rollbackAckV1Message?: RollbackAckV1Message, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.rollbackAckV1Message(rollbackAckV1Message, options); + async rollbackAckV1Message(recoverV1SuccessRequest?: RecoverV1SuccessRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.rollbackAckV1Message(recoverV1SuccessRequest, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, /** * - * @param {RollbackV1Message} [rollbackV1Message] + * @param {RollbackV1MessageRequest} [rollbackV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - async rollbackV1Message(rollbackV1Message?: RollbackV1Message, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.rollbackV1Message(rollbackV1Message, options); + async rollbackV1Message(rollbackV1MessageRequest?: RollbackV1MessageRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.rollbackV1Message(rollbackV1MessageRequest, options); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); }, } @@ -2765,165 +4160,165 @@ export const DefaultApiFactory = function (configuration?: Configuration, basePa return { /** * - * @param {ClientV1Request} [clientV1Request] + * @param {ClientRequestV1Request} [clientRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - clientRequestV1(clientV1Request?: ClientV1Request, options?: any): AxiosPromise { - return localVarFp.clientRequestV1(clientV1Request, options).then((request) => request(axios, basePath)); + clientRequestV1(clientRequestV1Request?: ClientRequestV1Request, options?: any): AxiosPromise { + return localVarFp.clientRequestV1(clientRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {TransferInitializationV1Request} [transferInitializationV1Request] + * @param {Phase1TransferInitiationRequestV1Request} [phase1TransferInitiationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase1TransferInitiationRequestV1(transferInitializationV1Request?: TransferInitializationV1Request, options?: any): AxiosPromise { - return localVarFp.phase1TransferInitiationRequestV1(transferInitializationV1Request, options).then((request) => request(axios, basePath)); + phase1TransferInitiationRequestV1(phase1TransferInitiationRequestV1Request?: Phase1TransferInitiationRequestV1Request, options?: any): AxiosPromise { + return localVarFp.phase1TransferInitiationRequestV1(phase1TransferInitiationRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {TransferInitializationV1Response} [transferInitializationV1Response] + * @param {Phase1TransferInitiationResponseV1Request} [phase1TransferInitiationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase1TransferInitiationResponseV1(transferInitializationV1Response?: TransferInitializationV1Response, options?: any): AxiosPromise { - return localVarFp.phase1TransferInitiationResponseV1(transferInitializationV1Response, options).then((request) => request(axios, basePath)); + phase1TransferInitiationResponseV1(phase1TransferInitiationResponseV1Request?: Phase1TransferInitiationResponseV1Request, options?: any): AxiosPromise { + return localVarFp.phase1TransferInitiationResponseV1(phase1TransferInitiationResponseV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {LockEvidenceV1Request} [lockEvidenceV1Request] + * @param {Phase2LockEvidenceRequestV1Request} [phase2LockEvidenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2LockEvidenceRequestV1(lockEvidenceV1Request?: LockEvidenceV1Request, options?: any): AxiosPromise { - return localVarFp.phase2LockEvidenceRequestV1(lockEvidenceV1Request, options).then((request) => request(axios, basePath)); + phase2LockEvidenceRequestV1(phase2LockEvidenceRequestV1Request?: Phase2LockEvidenceRequestV1Request, options?: any): AxiosPromise { + return localVarFp.phase2LockEvidenceRequestV1(phase2LockEvidenceRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {LockEvidenceV1Response} [lockEvidenceV1Response] + * @param {Phase2LockEvidenceResponseV1Request} [phase2LockEvidenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2LockEvidenceResponseV1(lockEvidenceV1Response?: LockEvidenceV1Response, options?: any): AxiosPromise { - return localVarFp.phase2LockEvidenceResponseV1(lockEvidenceV1Response, options).then((request) => request(axios, basePath)); + phase2LockEvidenceResponseV1(phase2LockEvidenceResponseV1Request?: Phase2LockEvidenceResponseV1Request, options?: any): AxiosPromise { + return localVarFp.phase2LockEvidenceResponseV1(phase2LockEvidenceResponseV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {TransferCommenceV1Request} [transferCommenceV1Request] + * @param {Phase2TransferCommenceRequestV1Request} [phase2TransferCommenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2TransferCommenceRequestV1(transferCommenceV1Request?: TransferCommenceV1Request, options?: any): AxiosPromise { - return localVarFp.phase2TransferCommenceRequestV1(transferCommenceV1Request, options).then((request) => request(axios, basePath)); + phase2TransferCommenceRequestV1(phase2TransferCommenceRequestV1Request?: Phase2TransferCommenceRequestV1Request, options?: any): AxiosPromise { + return localVarFp.phase2TransferCommenceRequestV1(phase2TransferCommenceRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {TransferCommenceV1Response} [transferCommenceV1Response] + * @param {Phase2TransferCommenceResponseV1Request} [phase2TransferCommenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase2TransferCommenceResponseV1(transferCommenceV1Response?: TransferCommenceV1Response, options?: any): AxiosPromise { - return localVarFp.phase2TransferCommenceResponseV1(transferCommenceV1Response, options).then((request) => request(axios, basePath)); + phase2TransferCommenceResponseV1(phase2TransferCommenceResponseV1Request?: Phase2TransferCommenceResponseV1Request, options?: any): AxiosPromise { + return localVarFp.phase2TransferCommenceResponseV1(phase2TransferCommenceResponseV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {CommitFinalV1Request} [commitFinalV1Request] + * @param {Phase3CommitFinalRequestV1Request} [phase3CommitFinalRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitFinalRequestV1(commitFinalV1Request?: CommitFinalV1Request, options?: any): AxiosPromise { - return localVarFp.phase3CommitFinalRequestV1(commitFinalV1Request, options).then((request) => request(axios, basePath)); + phase3CommitFinalRequestV1(phase3CommitFinalRequestV1Request?: Phase3CommitFinalRequestV1Request, options?: any): AxiosPromise { + return localVarFp.phase3CommitFinalRequestV1(phase3CommitFinalRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {CommitFinalV1Response} [commitFinalV1Response] + * @param {Phase3CommitFinalResponseV1Request} [phase3CommitFinalResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitFinalResponseV1(commitFinalV1Response?: CommitFinalV1Response, options?: any): AxiosPromise { - return localVarFp.phase3CommitFinalResponseV1(commitFinalV1Response, options).then((request) => request(axios, basePath)); + phase3CommitFinalResponseV1(phase3CommitFinalResponseV1Request?: Phase3CommitFinalResponseV1Request, options?: any): AxiosPromise { + return localVarFp.phase3CommitFinalResponseV1(phase3CommitFinalResponseV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {CommitPreparationV1Request} [commitPreparationV1Request] + * @param {Phase3CommitPreparationRequestV1Request} [phase3CommitPreparationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitPreparationRequestV1(commitPreparationV1Request?: CommitPreparationV1Request, options?: any): AxiosPromise { - return localVarFp.phase3CommitPreparationRequestV1(commitPreparationV1Request, options).then((request) => request(axios, basePath)); + phase3CommitPreparationRequestV1(phase3CommitPreparationRequestV1Request?: Phase3CommitPreparationRequestV1Request, options?: any): AxiosPromise { + return localVarFp.phase3CommitPreparationRequestV1(phase3CommitPreparationRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {CommitPreparationV1Response} [commitPreparationV1Response] + * @param {Phase3CommitPreparationResponseV1Request} [phase3CommitPreparationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3CommitPreparationResponseV1(commitPreparationV1Response?: CommitPreparationV1Response, options?: any): AxiosPromise { - return localVarFp.phase3CommitPreparationResponseV1(commitPreparationV1Response, options).then((request) => request(axios, basePath)); + phase3CommitPreparationResponseV1(phase3CommitPreparationResponseV1Request?: Phase3CommitPreparationResponseV1Request, options?: any): AxiosPromise { + return localVarFp.phase3CommitPreparationResponseV1(phase3CommitPreparationResponseV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {TransferCompleteV1Request} [transferCompleteV1Request] + * @param {Phase3TransferCompleteRequestV1Request} [phase3TransferCompleteRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - phase3TransferCompleteRequestV1(transferCompleteV1Request?: TransferCompleteV1Request, options?: any): AxiosPromise { - return localVarFp.phase3TransferCompleteRequestV1(transferCompleteV1Request, options).then((request) => request(axios, basePath)); + phase3TransferCompleteRequestV1(phase3TransferCompleteRequestV1Request?: Phase3TransferCompleteRequestV1Request, options?: any): AxiosPromise { + return localVarFp.phase3TransferCompleteRequestV1(phase3TransferCompleteRequestV1Request, options).then((request) => request(axios, basePath)); }, /** * - * @param {RecoverUpdateAckV1Message} [recoverUpdateAckV1Message] + * @param {RecoverUpdateAckV1MessageRequest} [recoverUpdateAckV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverUpdateAckV1Message(recoverUpdateAckV1Message?: RecoverUpdateAckV1Message, options?: any): AxiosPromise { - return localVarFp.recoverUpdateAckV1Message(recoverUpdateAckV1Message, options).then((request) => request(axios, basePath)); + recoverUpdateAckV1Message(recoverUpdateAckV1MessageRequest?: RecoverUpdateAckV1MessageRequest, options?: any): AxiosPromise { + return localVarFp.recoverUpdateAckV1Message(recoverUpdateAckV1MessageRequest, options).then((request) => request(axios, basePath)); }, /** * - * @param {RecoverUpdateV1Message} [recoverUpdateV1Message] + * @param {RecoverUpdateV1MessageRequest} [recoverUpdateV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverUpdateV1Message(recoverUpdateV1Message?: RecoverUpdateV1Message, options?: any): AxiosPromise { - return localVarFp.recoverUpdateV1Message(recoverUpdateV1Message, options).then((request) => request(axios, basePath)); + recoverUpdateV1Message(recoverUpdateV1MessageRequest?: RecoverUpdateV1MessageRequest, options?: any): AxiosPromise { + return localVarFp.recoverUpdateV1Message(recoverUpdateV1MessageRequest, options).then((request) => request(axios, basePath)); }, /** * - * @param {RecoverV1Message} [recoverV1Message] + * @param {RecoverV1MessageRequest} [recoverV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverV1Message(recoverV1Message?: RecoverV1Message, options?: any): AxiosPromise { - return localVarFp.recoverV1Message(recoverV1Message, options).then((request) => request(axios, basePath)); + recoverV1Message(recoverV1MessageRequest?: RecoverV1MessageRequest, options?: any): AxiosPromise { + return localVarFp.recoverV1Message(recoverV1MessageRequest, options).then((request) => request(axios, basePath)); }, /** * - * @param {RecoverSuccessV1Message} [recoverSuccessV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - recoverV1Success(recoverSuccessV1Message?: RecoverSuccessV1Message, options?: any): AxiosPromise { - return localVarFp.recoverV1Success(recoverSuccessV1Message, options).then((request) => request(axios, basePath)); + recoverV1Success(recoverV1SuccessRequest?: RecoverV1SuccessRequest, options?: any): AxiosPromise { + return localVarFp.recoverV1Success(recoverV1SuccessRequest, options).then((request) => request(axios, basePath)); }, /** * - * @param {RollbackAckV1Message} [rollbackAckV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - rollbackAckV1Message(rollbackAckV1Message?: RollbackAckV1Message, options?: any): AxiosPromise { - return localVarFp.rollbackAckV1Message(rollbackAckV1Message, options).then((request) => request(axios, basePath)); + rollbackAckV1Message(recoverV1SuccessRequest?: RecoverV1SuccessRequest, options?: any): AxiosPromise { + return localVarFp.rollbackAckV1Message(recoverV1SuccessRequest, options).then((request) => request(axios, basePath)); }, /** * - * @param {RollbackV1Message} [rollbackV1Message] + * @param {RollbackV1MessageRequest} [rollbackV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} */ - rollbackV1Message(rollbackV1Message?: RollbackV1Message, options?: any): AxiosPromise { - return localVarFp.rollbackV1Message(rollbackV1Message, options).then((request) => request(axios, basePath)); + rollbackV1Message(rollbackV1MessageRequest?: RollbackV1MessageRequest, options?: any): AxiosPromise { + return localVarFp.rollbackV1Message(rollbackV1MessageRequest, options).then((request) => request(axios, basePath)); }, }; }; @@ -2937,200 +4332,200 @@ export const DefaultApiFactory = function (configuration?: Configuration, basePa export class DefaultApi extends BaseAPI { /** * - * @param {ClientV1Request} [clientV1Request] + * @param {ClientRequestV1Request} [clientRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public clientRequestV1(clientV1Request?: ClientV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).clientRequestV1(clientV1Request, options).then((request) => request(this.axios, this.basePath)); + public clientRequestV1(clientRequestV1Request?: ClientRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).clientRequestV1(clientRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {TransferInitializationV1Request} [transferInitializationV1Request] + * @param {Phase1TransferInitiationRequestV1Request} [phase1TransferInitiationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase1TransferInitiationRequestV1(transferInitializationV1Request?: TransferInitializationV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase1TransferInitiationRequestV1(transferInitializationV1Request, options).then((request) => request(this.axios, this.basePath)); + public phase1TransferInitiationRequestV1(phase1TransferInitiationRequestV1Request?: Phase1TransferInitiationRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase1TransferInitiationRequestV1(phase1TransferInitiationRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {TransferInitializationV1Response} [transferInitializationV1Response] + * @param {Phase1TransferInitiationResponseV1Request} [phase1TransferInitiationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase1TransferInitiationResponseV1(transferInitializationV1Response?: TransferInitializationV1Response, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase1TransferInitiationResponseV1(transferInitializationV1Response, options).then((request) => request(this.axios, this.basePath)); + public phase1TransferInitiationResponseV1(phase1TransferInitiationResponseV1Request?: Phase1TransferInitiationResponseV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase1TransferInitiationResponseV1(phase1TransferInitiationResponseV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {LockEvidenceV1Request} [lockEvidenceV1Request] + * @param {Phase2LockEvidenceRequestV1Request} [phase2LockEvidenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase2LockEvidenceRequestV1(lockEvidenceV1Request?: LockEvidenceV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase2LockEvidenceRequestV1(lockEvidenceV1Request, options).then((request) => request(this.axios, this.basePath)); + public phase2LockEvidenceRequestV1(phase2LockEvidenceRequestV1Request?: Phase2LockEvidenceRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase2LockEvidenceRequestV1(phase2LockEvidenceRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {LockEvidenceV1Response} [lockEvidenceV1Response] + * @param {Phase2LockEvidenceResponseV1Request} [phase2LockEvidenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase2LockEvidenceResponseV1(lockEvidenceV1Response?: LockEvidenceV1Response, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase2LockEvidenceResponseV1(lockEvidenceV1Response, options).then((request) => request(this.axios, this.basePath)); + public phase2LockEvidenceResponseV1(phase2LockEvidenceResponseV1Request?: Phase2LockEvidenceResponseV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase2LockEvidenceResponseV1(phase2LockEvidenceResponseV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {TransferCommenceV1Request} [transferCommenceV1Request] + * @param {Phase2TransferCommenceRequestV1Request} [phase2TransferCommenceRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase2TransferCommenceRequestV1(transferCommenceV1Request?: TransferCommenceV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase2TransferCommenceRequestV1(transferCommenceV1Request, options).then((request) => request(this.axios, this.basePath)); + public phase2TransferCommenceRequestV1(phase2TransferCommenceRequestV1Request?: Phase2TransferCommenceRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase2TransferCommenceRequestV1(phase2TransferCommenceRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {TransferCommenceV1Response} [transferCommenceV1Response] + * @param {Phase2TransferCommenceResponseV1Request} [phase2TransferCommenceResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase2TransferCommenceResponseV1(transferCommenceV1Response?: TransferCommenceV1Response, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase2TransferCommenceResponseV1(transferCommenceV1Response, options).then((request) => request(this.axios, this.basePath)); + public phase2TransferCommenceResponseV1(phase2TransferCommenceResponseV1Request?: Phase2TransferCommenceResponseV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase2TransferCommenceResponseV1(phase2TransferCommenceResponseV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {CommitFinalV1Request} [commitFinalV1Request] + * @param {Phase3CommitFinalRequestV1Request} [phase3CommitFinalRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase3CommitFinalRequestV1(commitFinalV1Request?: CommitFinalV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase3CommitFinalRequestV1(commitFinalV1Request, options).then((request) => request(this.axios, this.basePath)); + public phase3CommitFinalRequestV1(phase3CommitFinalRequestV1Request?: Phase3CommitFinalRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase3CommitFinalRequestV1(phase3CommitFinalRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {CommitFinalV1Response} [commitFinalV1Response] + * @param {Phase3CommitFinalResponseV1Request} [phase3CommitFinalResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase3CommitFinalResponseV1(commitFinalV1Response?: CommitFinalV1Response, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase3CommitFinalResponseV1(commitFinalV1Response, options).then((request) => request(this.axios, this.basePath)); + public phase3CommitFinalResponseV1(phase3CommitFinalResponseV1Request?: Phase3CommitFinalResponseV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase3CommitFinalResponseV1(phase3CommitFinalResponseV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {CommitPreparationV1Request} [commitPreparationV1Request] + * @param {Phase3CommitPreparationRequestV1Request} [phase3CommitPreparationRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase3CommitPreparationRequestV1(commitPreparationV1Request?: CommitPreparationV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase3CommitPreparationRequestV1(commitPreparationV1Request, options).then((request) => request(this.axios, this.basePath)); + public phase3CommitPreparationRequestV1(phase3CommitPreparationRequestV1Request?: Phase3CommitPreparationRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase3CommitPreparationRequestV1(phase3CommitPreparationRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {CommitPreparationV1Response} [commitPreparationV1Response] + * @param {Phase3CommitPreparationResponseV1Request} [phase3CommitPreparationResponseV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase3CommitPreparationResponseV1(commitPreparationV1Response?: CommitPreparationV1Response, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase3CommitPreparationResponseV1(commitPreparationV1Response, options).then((request) => request(this.axios, this.basePath)); + public phase3CommitPreparationResponseV1(phase3CommitPreparationResponseV1Request?: Phase3CommitPreparationResponseV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase3CommitPreparationResponseV1(phase3CommitPreparationResponseV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {TransferCompleteV1Request} [transferCompleteV1Request] + * @param {Phase3TransferCompleteRequestV1Request} [phase3TransferCompleteRequestV1Request] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public phase3TransferCompleteRequestV1(transferCompleteV1Request?: TransferCompleteV1Request, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).phase3TransferCompleteRequestV1(transferCompleteV1Request, options).then((request) => request(this.axios, this.basePath)); + public phase3TransferCompleteRequestV1(phase3TransferCompleteRequestV1Request?: Phase3TransferCompleteRequestV1Request, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).phase3TransferCompleteRequestV1(phase3TransferCompleteRequestV1Request, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {RecoverUpdateAckV1Message} [recoverUpdateAckV1Message] + * @param {RecoverUpdateAckV1MessageRequest} [recoverUpdateAckV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public recoverUpdateAckV1Message(recoverUpdateAckV1Message?: RecoverUpdateAckV1Message, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).recoverUpdateAckV1Message(recoverUpdateAckV1Message, options).then((request) => request(this.axios, this.basePath)); + public recoverUpdateAckV1Message(recoverUpdateAckV1MessageRequest?: RecoverUpdateAckV1MessageRequest, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).recoverUpdateAckV1Message(recoverUpdateAckV1MessageRequest, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {RecoverUpdateV1Message} [recoverUpdateV1Message] + * @param {RecoverUpdateV1MessageRequest} [recoverUpdateV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public recoverUpdateV1Message(recoverUpdateV1Message?: RecoverUpdateV1Message, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).recoverUpdateV1Message(recoverUpdateV1Message, options).then((request) => request(this.axios, this.basePath)); + public recoverUpdateV1Message(recoverUpdateV1MessageRequest?: RecoverUpdateV1MessageRequest, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).recoverUpdateV1Message(recoverUpdateV1MessageRequest, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {RecoverV1Message} [recoverV1Message] + * @param {RecoverV1MessageRequest} [recoverV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public recoverV1Message(recoverV1Message?: RecoverV1Message, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).recoverV1Message(recoverV1Message, options).then((request) => request(this.axios, this.basePath)); + public recoverV1Message(recoverV1MessageRequest?: RecoverV1MessageRequest, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).recoverV1Message(recoverV1MessageRequest, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {RecoverSuccessV1Message} [recoverSuccessV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public recoverV1Success(recoverSuccessV1Message?: RecoverSuccessV1Message, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).recoverV1Success(recoverSuccessV1Message, options).then((request) => request(this.axios, this.basePath)); + public recoverV1Success(recoverV1SuccessRequest?: RecoverV1SuccessRequest, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).recoverV1Success(recoverV1SuccessRequest, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {RollbackAckV1Message} [rollbackAckV1Message] + * @param {RecoverV1SuccessRequest} [recoverV1SuccessRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public rollbackAckV1Message(rollbackAckV1Message?: RollbackAckV1Message, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).rollbackAckV1Message(rollbackAckV1Message, options).then((request) => request(this.axios, this.basePath)); + public rollbackAckV1Message(recoverV1SuccessRequest?: RecoverV1SuccessRequest, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).rollbackAckV1Message(recoverV1SuccessRequest, options).then((request) => request(this.axios, this.basePath)); } /** * - * @param {RollbackV1Message} [rollbackV1Message] + * @param {RollbackV1MessageRequest} [rollbackV1MessageRequest] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof DefaultApi */ - public rollbackV1Message(rollbackV1Message?: RollbackV1Message, options?: AxiosRequestConfig) { - return DefaultApiFp(this.configuration).rollbackV1Message(rollbackV1Message, options).then((request) => request(this.axios, this.basePath)); + public rollbackV1Message(rollbackV1MessageRequest?: RollbackV1MessageRequest, options?: AxiosRequestConfig) { + return DefaultApiFp(this.configuration).rollbackV1Message(rollbackV1MessageRequest, options).then((request) => request(this.axios, this.basePath)); } } diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/plugin-satp-gateway.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/plugin-satp-gateway.ts index bf82655807..25de4a19ae 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/plugin-satp-gateway.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/plugin-satp-gateway.ts @@ -5,7 +5,7 @@ import { Optional } from "typescript-optional"; import type { Express } from "express"; import { v4 as uuidV4 } from "uuid"; import { Knex } from "knex"; -import OAS from "../json/openapi.json"; +import OAS from "../json/openapi-gateway-bundled.json"; import { Secp256k1Keys, Logger, diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-local-log-repository.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-local-log-repository.ts index 65c07b10de..b977e3e111 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-local-log-repository.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-local-log-repository.ts @@ -7,7 +7,7 @@ export class KnexLocalLogRepository implements ILocalLogRepository { public constructor(config: Knex.Config | undefined) { // eslint-disable-next-line @typescript-eslint/no-var-requires - const configFile = require("../../../knex/knexfile.ts")[ + const configFile = require("../../../../knex/knexfile.ts")[ process.env.ENVIRONMENT || "development" ]; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-remote-log-repository.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-remote-log-repository.ts index 8d064da275..9431076d0a 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-remote-log-repository.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/repository/knex-remote-log-repository.ts @@ -10,7 +10,7 @@ export class KnexRemoteLogRepository implements IRemoteLogRepository { // simulating a remote log storage public constructor(config: Knex.Config | undefined) { // eslint-disable-next-line @typescript-eslint/no-var-requires - const configFile = require("../../../knex/knexfile-remote.ts")[ + const configFile = require("../../../../knex/knexfile-remote.ts")[ process.env.ENVIRONMENT || "development" ]; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/blo/status-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/blo/status-endpoint.ts new file mode 100644 index 0000000000..f7d80f722b --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/blo/status-endpoint.ts @@ -0,0 +1,102 @@ +import type { Express, Request, Response } from "express"; + +import { + IWebServiceEndpoint, + IExpressRequestHandler, + IEndpointAuthzOptions, +} from "@hyperledger/cactus-core-api"; +import { + Logger, + Checks, + LoggerProvider, + IAsyncProvider, +} from "@hyperledger/cactus-common"; + +import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; + +import OAS from "../../../json/openapi-blo-bundled.json"; +import { IRequestOptions } from "../../core/types"; +import { StatusRequest } from "../../generated/openapi-blo/typescript-axios"; + +export class GetStatusEndpointV1 implements IWebServiceEndpoint { + public static readonly CLASS_NAME = "GetStatusEndpointV1"; + + private readonly log: Logger; + + public get className(): string { + return GetStatusEndpointV1.CLASS_NAME; + } + + constructor(public readonly options: IRequestOptions) { + const fnTag = `${this.className}#constructor()`; + Checks.truthy(options, `${fnTag} arg options`); + Checks.truthy(options.dispatcher, `${fnTag} arg options.connector`); + + const level = this.options.logLevel || "INFO"; + const label = this.className; + this.log = LoggerProvider.getOrCreate({ level, label }); + } + + public getPath(): string { + const apiPath = + OAS.paths["/api/v1/@hyperledger/cactus-plugin-satp-hermes/status"]; + return apiPath.get["x-hyperledger-cacti"].http.path; + } + + public getVerbLowerCase(): string { + const apiPath = + OAS.paths["/api/v1/@hyperledger/cactus-plugin-satp-hermes/status"]; + return apiPath.get["x-hyperledger-cacti"].http.verbLowerCase; + } + + public getOperationId(): string { + return OAS.paths["/api/v1/@hyperledger/cactus-plugin-satp-hermes/status"] + .get.operationId; + } + + getAuthorizationOptionsProvider(): IAsyncProvider { + // TODO: make this an injectable dependency in the constructor + return { + get: async () => ({ + isProtected: true, + requiredRoles: [], + }), + }; + } + + public async registerExpress( + expressApp: Express, + ): Promise { + await registerWebServiceEndpoint(expressApp, this); + return this; + } + + public getExpressRequestHandler(): IExpressRequestHandler { + return this.handleRequest.bind(this); + } + + public async handleRequest(req: Request, res: Response): Promise { + const reqTag = `${this.getVerbLowerCase()} - ${this.getPath()}`; + this.log.debug(reqTag); + try { + const sessionId = req.query.SessionID as string; + if (!sessionId) { + res + .status(400) + .json({ message: "SessionID query parameter is required." }); + return; + } + const statusRequest: StatusRequest = { + sessionID: sessionId, + }; + const result = await this.options.dispatcher.GetStatus(statusRequest); + res.status(200).json(result); + } catch (ex) { + this.log.error(`Crash while serving ${reqTag}`, ex); + res.status(500).json({ + message: "Internal Server Error", + error: ex?.stack || ex?.message, + }); + } + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/client-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/client-request-endpoint.ts index 99a4124477..333077cf7b 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/client-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/client-request-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IClientRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-final-response-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-final-response-endpoint.ts index e08e40a183..38c51152f6 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-final-response-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-final-response-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ICommitFinalResponseEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-prepare-response-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-prepare-response-endpoint.ts index 6d7066a2b0..673c4002c8 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-prepare-response-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/commit-prepare-response-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ICommitPreparationResponseEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/lock-evidence-response-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/lock-evidence-response-endpoint.ts index f61c7b6161..0794db89fc 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/lock-evidence-response-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/lock-evidence-response-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ILockEvidenceResponseEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-commence-response-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-commence-response-endpoint.ts index 0de0281eb2..185f7d5673 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-commence-response-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-commence-response-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ITransferCommenceResponseEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-initiation-response-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-initiation-response-endpoint.ts index dbe1929339..913446225c 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-initiation-response-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/client-side/transfer-initiation-response-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ITransferInitiationResponseEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-message-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-message-endpoint.ts index f2416f4894..95c828d25e 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-message-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-message-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IRecoverMessageEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-success-message-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-success-message-endpoint.ts index 09b5ad642e..0e2f7fee51 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-success-message-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-success-message-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IRecoverSuccessMessageEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-ack-message-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-ack-message-endpoint.ts index aa0a36029d..a3e25fb740 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-ack-message-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-ack-message-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IRecoverUpdateAckMessageEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-message-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-message-endpoint.ts index a6d3aca96c..eed087ac1f 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-message-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/recover-update-message-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IRecoverUpdateMessageEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-ack-message-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-ack-message-endpoint.ts index 0e82229c07..b280b2e74b 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-ack-message-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-ack-message-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IRollbackAckMessageEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-message-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-message-endpoint.ts index d7da7f1991..65427e4e22 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-message-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/recovery/rollback-message-endpoint.ts @@ -17,7 +17,7 @@ import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface IRollbackMessageEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commit-final-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commit-final-request-endpoint.ts index 847d525a79..e5aea4fa1d 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commit-final-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commit-final-request-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ICommitFinalRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commite-prepare-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commite-prepare-request-endpoint.ts index 79e468e21f..e370deca37 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commite-prepare-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/commite-prepare-request-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ICommitPreparationRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/lock-evidence-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/lock-evidence-request-endpoint.ts index e8b90a1344..cc6af836ca 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/lock-evidence-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/lock-evidence-request-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ILockEvidenceRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-commence-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-commence-request-endpoint.ts index c3f9b2bb67..2060011ad3 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-commence-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-commence-request-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ITransferCommenceRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-complete-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-complete-request-endpoint.ts index 86c19ca18d..0467d4f709 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-complete-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-complete-request-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ITransferCompleteRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-initiation-request-endpoint.ts b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-initiation-request-endpoint.ts index deed90e247..400a309f4a 100644 --- a/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-initiation-request-endpoint.ts +++ b/packages/cactus-plugin-satp-hermes/src/main/typescript/web-services/server-side/transfer-initiation-request-endpoint.ts @@ -16,7 +16,7 @@ import { import { registerWebServiceEndpoint } from "@hyperledger/cactus-core"; import { PluginSATPGateway } from "../../plugin-satp-gateway"; -import OAS from "../../../json/openapi.json"; +import OAS from "../../../json/openapi-gateway-bundled.json"; export interface ITransferInitiationRequestEndpointOptions { logLevel?: LogLevelDesc; diff --git a/packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo-bundled.yml b/packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo-bundled.yml new file mode 100644 index 0000000000..ae3f997a2d --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo-bundled.yml @@ -0,0 +1,4689 @@ +openapi: 3.0.3 +info: + title: SATP Gateway Client (Business Logic Orchestrator) + version: 0.0.2 + description: |- + SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. + + This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. + + **Additional Resources**: + - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) + - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) + - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) + - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) + - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) + - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) + - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + contact: + name: Hyperledger Cacti + x-logo: + altText: Cacti logo + backgroundColor: '#fafafa' + url: 'https://github.com/hyperledger/cacti/blob/main/images/HL_Cacti_Logo_Color.png' +externalDocs: + description: 'For more information about the SATP Gateway Client, refer to the official documentation.' + url: 'https://github.com/hyperledger/cacti/tree/main/packages/cactus-plugin-satp-hermes/README.md' +servers: + - url: 'http://{host}:{port}/api/v1/@hyperledger/cactus-plugin-satp-hermes' + description: Development server + variables: + host: + default: localhost + port: + default: '3011' +tags: + - name: transaction + description: API endpoints for interacting with blockchains via gateways + - name: admin + description: API endpoints for fetching information on SATP sessions +paths: + /api/v1/@hyperledger/cactus-plugin-satp-hermes/transact: + post: + tags: + - transaction + summary: Submit a transaction intent + description: Allows users to queue intents for transactions based on specified parameters. + operationId: Transact + requestBody: + content: + application/json: + schema: + description: 'Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks.' + type: object + required: + - contextID + - mode + properties: + contextID: + type: string + format: uuid + example: 123e4567-e89b-12d3-a456-426614174000 + mode: + type: string + enum: + - data + - transfer + example: transfer + payload: + type: string + example: '{"data":"example payload"}' + fromDLTNetworkID: + type: string + example: network1 + toDLTNetworkID: + type: string + example: network2 + fromAmount: + type: string + example: '100' + fromToken: + type: string + example: TOKEN1 + toAmount: + type: string + example: '95' + toToken: + type: string + example: TOKEN2 + required: true + responses: + '200': + description: Transaction successfully queued + content: + application/json: + schema: + description: Response schema for a transaction request. Includes the session ID and the current status of the transaction. + type: object + properties: + sessionID: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + required: + - sessionID + - statusResponse + default: + description: An error occurred + content: + application/json: + schema: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + /api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel: + post: + tags: + - transaction + summary: Cancel a transaction session + description: Attempts to cancel a previously submitted transaction intent using its session ID. + operationId: Cancel + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel + requestBody: + content: + application/json: + schema: + description: 'Request to cancel an ongoing transaction session, identified by the session ID.' + type: object + properties: + sessionID: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 + required: + - sessionID + required: true + responses: + '200': + description: Transaction cancellation attempted + content: + application/json: + schema: + description: Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status. + type: object + properties: + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + cancelSuccessful: + type: boolean + description: Indicates whether the cancel operation was successful. + example: true + required: + - statusResponse + - cancelSuccessful + default: + description: An error occurred or transaction cannot be cancelled + content: + application/json: + schema: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + /api/v1/@hyperledger/cactus-plugin-satp-hermes/status: + get: + summary: Get SATP current session data + description: Retrieve the status of a SATP session + operationId: GetStatus + tags: + - admin + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/status + parameters: + - name: SessionID + in: query + schema: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 + required: true + description: Unique identifier for the session. + responses: + '200': + description: OK + content: + application/json: + schema: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + '400': + description: Bad request + '404': + description: Transaction not found + '500': + description: Internal server error + /api/v1/@hyperledger/cactus-plugin-satp-hermes/healthcheck: + get: + summary: Health check endpoint + description: Responds if SATP Hermes is on + operationId: GetHealthCheck + tags: + - admin + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + status: + type: string + example: OK + '500': + description: Internal server error + /api/v1/@hyperledger/cactus-plugin-satp-hermes/continue: + post: + tags: + - admin + summary: Continue a paused transaction session + description: 'Attempts to continue a previously paused transaction intent, resuming its execution.' + operationId: Continue + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/continue + requestBody: + content: + application/json: + schema: + type: object + properties: + sessionId: + type: string + format: uuid + description: A unique identifier for the transaction session to be continued. + contextId: + type: string + format: uuid + description: A unique identifier for the transaction context. + required: + - sessionId + - contextId + description: Schema for a request to continue a paused transaction session. + required: true + responses: + '200': + description: Transaction continuation attempted + content: + application/json: + schema: + type: object + description: 'Response schema for a continue request, returning the status of the SATP session.' + properties: + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + required: + - statusResponse + default: + description: An error occurred or transaction cannot be continued + content: + application/json: + schema: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + /api/v1/@hyperledger/cactus-plugin-satp-hermes/pause: + post: + tags: + - admin + summary: Pause a transaction session + description: 'Attempts to pause a previously submitted transaction intent, temporarily halting its execution.' + operationId: Pause + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/pause + requestBody: + content: + application/json: + schema: + description: 'Request to temporarily pause an ongoing transaction session, identified by the session and context IDs.' + type: object + properties: + sessionId: + type: string + format: uuid + example: 123e4567-e89b-12d3-a456-426614174000 + contextId: + type: string + format: uuid + example: 123e4567-e89b-12d3-a456-426614174001 + required: true + responses: + '200': + description: Transaction pause attempted + content: + application/json: + schema: + description: Response for a pause transaction request. Returns the current status of the SATP session post-pause action. + type: object + properties: + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + required: + - statusResponse + default: + description: An error occurred or transaction cannot be paused + content: + application/json: + schema: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + /api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations: + get: + tags: + - transaction + summary: Get supported integrations + description: 'Retrieves metadata about each supported blockchain networks, chains, and other systems.' + operationId: GetIntegrations + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations + responses: + '200': + description: A list of supported systems. + content: + application/json: + schema: + title: Chains + type: array + description: List of chains and related metadata + items: + type: object + properties: + chainId: + type: string + description: A unique identifier for the blockchain network. + chainName: + type: string + description: The name of the blockchain network. + chainType: + type: string + description: 'The type of blockchain network (e.g., ''evm'', ''fabric'').' + networkName: + type: string + description: 'The specific network name within the blockchain (e.g., ''mainnet'', ''testnet'').' + required: + - chainId + - chainName + - chainType + - networkName + default: + description: An error occurred + content: + application/json: + schema: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + /api/v1/@hyperledger/cactus-plugin-satp-hermes/routes: + get: + description: Get a list of possible routes for swapping one asset for another across multiple exchanges + summary: Get a list of routes for a gateway-to-gateway asset transfer + tags: + - transaction + operationId: GetRoutes + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/routes + parameters: + - name: fromNetworkID + in: query + schema: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + required: true + description: The sending DLT Network. + - name: fromAmount + in: query + schema: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + required: true + description: The amount that should be sent including all decimals. + - name: fromToken + in: query + schema: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + required: true + description: The token that should be transferred. Can be the address or the symbol. + - name: toDLTNetwork + in: query + schema: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + required: true + description: The receiving DLT Network. + - name: toToken + in: query + schema: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + required: true + description: The token that should be transferred to. Can be the address or the symbol. + - name: fromAddress + in: query + schema: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + required: true + description: The sending wallet address. + - name: toAddress + in: query + schema: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + required: true + description: 'The receiving wallet address. If none is provided, the fromAddress will be used.' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + description: A collection of available and unavailable routes + required: + - routes + properties: + routes: + type: array + description: A collection of route objects + items: + type: object + properties: + id: + type: string + description: A unique identifier of the route. + gatewayID: + type: string + format: uuid + description: A unique identifier for the gateway. + mode: + type: string + enum: + - data + - transfer + description: 'The mode of operation for this route - ''data'' for arbitrary payload handling, ''transfer'' for asset transfer.' + fromDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will originate. + fromAmountUSD: + type: string + format: double + description: 'The amount of ''fromToken'' to be transferred in USD, specified as a string to maintain precision.' + fromAmount: + type: string + description: 'The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + pattern: '^[1-9][0-9]*$' + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + toDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will end. + toAmountUSD: + type: string + description: The expected amount to be received in USD. + toAmount: + type: string + description: 'The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + toAmountMin: + type: string + description: 'The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + gasCostUSD: + type: string + description: The expected gas cost in USD. + containsSwitchChain: + type: boolean + description: Whether chain switching is enabled or not. + steps: + type: array + description: 'List of steps involved in this route, adjusted for mode.' + items: + type: object + description: Details a single step within a route including actions and estimates. + properties: + id: + type: string + description: Id of the step + type: + type: string + description: 'Type of the step, typically describing the action, e.g., ''swap''.' + tool: + type: string + description: 'Tool used in the step, e.g., ''stargate''.' + action: + type: object + properties: + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + fromAmount: + type: string + description: 'The amount of ''fromToken'' to be transferred, specified as a string to maintain precision.' + example: '1000000000000000000' + pattern: '^[1-9][0-9]*$' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + slippage: + type: number + format: float + description: The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + example: 0.005 + fromAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + estimate: + type: object + description: 'Provides an estimation for a transaction, including costs, amounts, and execution duration.' + properties: + approvalAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAmountMin: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + fromAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + feeCosts: + type: array + description: A collection of fee costs associated with the transaction. + items: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + amountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + token: + type: string + description: The symbol of a token + example: ETH + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. + gasCosts: + type: array + description: A collection of estimated gas costs for executing the transaction. + items: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: 'The gas price, specified as a string to maintain precision.' + example: '19236858243' + estimate: + type: string + description: 'The estimated gas required, specified as a string to maintain precision.' + example: '445393' + limit: + type: string + description: 'The gas limit for the transaction, specified as a string to maintain precision.' + example: '579011' + pattern: '^[1-9][0-9]*$' + amount: + type: string + description: The amount of gas required in the gas currency. + example: '8567962003424499' + pattern: '^[1-9][0-9]*$' + amountUSD: + type: string + description: The amount of gas required in USD. + example: '16.05' + pattern: '^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$' + token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + executionDuration: + type: integer + description: The estimated duration for the transaction execution in seconds. + example: 30 + fromAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + tool: + type: string + description: The tool or service used to generate this estimate. + example: satp + toolDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + integrationDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + includedStepIds: + type: array + description: 'IDs of further steps included within this step, allowing for nested actions without direct recursion.' + items: + type: string + insurance: + type: object + properties: + state: + type: string + description: The state of insurance applicability for the transaction. + example: NOT_INSURABLE + enum: + - NOT_INSURABLE + - INSURABLE + - INSURED + feeAmountUsd: + type: string + description: 'The fee amount for insurance, represented in USD.' + example: '10.00' + pattern: '^(0|[1-9]\d*)(\.\d+)?$' + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + required: + - id + - gatewayID + - mode + default: + description: An error occurred + content: + application/json: + schema: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + /api/v1/@hyperledger/cactus-plugin-satp-hermes/audit: + get: + tags: + - admin + summary: Audit transactions + description: Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + operationId: GetAudit + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/audit + parameters: + - name: auditStartDate + in: query + description: The start date for the audit period. + required: false + schema: + type: string + format: date-time + - name: auditEndDate + in: query + description: The end date for the audit period. + required: false + schema: + type: string + format: date-time + - name: includeProofs + in: query + description: Include proofs generated from each gateway transaction. + required: false + schema: + type: boolean + responses: + '200': + description: Audit results + content: + application/json: + schema: + description: Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes. + type: object + x-category: response + properties: + proofs: + type: array + items: + type: string + description: An array of strings representing proofs. + example: + - proof1 + - proof2 + auditStartTime: + type: string + format: date-time + description: The start datetime of the audit period. + example: '2023-01-01T00:00:00Z' + auditEndTime: + type: string + format: date-time + description: The end datetime of the audit period. + example: '2023-01-31T23:59:59Z' +components: + schemas: + AuthzScope: + type: string + enum: + - 'group:admin' + - 'group:user' + x-enum-descriptions: + - 'Identities with the group:admin scope are administrators of the system.' + - 'Identities with the group:user scope are end users of the system who only have authorization to perform a limited set of actions.' + x-enum-varnames: + - GroupAdmin + - GroupUser + example: 'group:admin' + AuthzJwtClaim: + description: 'Stores global constants related to the authorization of the application. Specifically enumerates the claims to validate for as per RFC 7519, section 4.1. See: https://tools.ietf.org/html/rfc7519#section-4.1' + type: string + enum: + - Hyperledger Labs - Carbon Accounting Tool + x-enum-descriptions: + - The "iss" (issuer) claim identifies the principal that issued the JWT. The processing of this claim is generally application specific. The "iss" value is a case-sensitive string containing a StringOrURI value. Use of this claim is OPTIONAL. + x-enum-varnames: + - iss + example: Hyperledger Labs - Carbon Accounting Tool + CredentialProfile: + type: string + enum: + - SAML + - OAUTH + - X509 + example: OAUTH + getAuditRequest: + description: Request schema for initiating an audit. Includes the start and end dates for the audit period and an option to include proofs. + type: object + x-category: request + properties: + auditStartDate: + type: string + format: date-time + description: The start datetime for the audit. + example: '2023-01-01T00:00:00Z' + auditEndDate: + type: string + format: date-time + description: The end datetime for the audit. + example: '2023-01-31T23:59:59Z' + includeProofs: + type: boolean + description: Include proofs generated from each gateway transaction. + example: true + getAuditResponse: + description: Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes. + type: object + x-category: response + properties: + proofs: + type: array + items: + type: string + description: An array of strings representing proofs. + example: + - proof1 + - proof2 + auditStartTime: + type: string + format: date-time + description: The start datetime of the audit period. + example: '2023-01-01T00:00:00Z' + auditEndTime: + type: string + format: date-time + description: The end datetime of the audit period. + example: '2023-01-31T23:59:59Z' + StatusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + PauseRequest: + description: 'Request to temporarily pause an ongoing transaction session, identified by the session and context IDs.' + type: object + properties: + sessionId: + type: string + format: uuid + example: 123e4567-e89b-12d3-a456-426614174000 + contextId: + type: string + format: uuid + example: 123e4567-e89b-12d3-a456-426614174001 + PauseResponse: + description: Response for a pause transaction request. Returns the current status of the SATP session post-pause action. + type: object + properties: + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + required: + - statusResponse + StatusRequest: + description: 'Request for retrieving the current status of a session, identified by the session ID.' + type: object + x-category: request + required: + - sessionID + properties: + sessionID: + type: string + description: The ID of the session for which the status is being requested. + example: 123e4567-e89b-12d3-a456-426614174000 + TransactRequest: + description: 'Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks.' + type: object + required: + - contextID + - mode + properties: + contextID: + type: string + format: uuid + example: 123e4567-e89b-12d3-a456-426614174000 + mode: + type: string + enum: + - data + - transfer + example: transfer + payload: + type: string + example: '{"data":"example payload"}' + fromDLTNetworkID: + type: string + example: network1 + toDLTNetworkID: + type: string + example: network2 + fromAmount: + type: string + example: '100' + fromToken: + type: string + example: TOKEN1 + toAmount: + type: string + example: '95' + toToken: + type: string + example: TOKEN2 + TransactResponse: + description: Response schema for a transaction request. Includes the session ID and the current status of the transaction. + type: object + properties: + sessionID: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + required: + - sessionID + - statusResponse + CancelRequest: + description: 'Request to cancel an ongoing transaction session, identified by the session ID.' + type: object + properties: + sessionID: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 + required: + - sessionID + CancelResponse: + description: Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status. + type: object + properties: + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + cancelSuccessful: + type: boolean + description: Indicates whether the cancel operation was successful. + example: true + required: + - statusResponse + - cancelSuccessful + APIError: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: '2021-07-21T17:32:28Z' + DLTProtocol: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + DLTNetworkID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + DLTSubnetworkID: + x-category: satp-core + type: string + description: 'The subnetwork of the DLT being interacted with. TODO: implement network identification draft' + SessionID: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 + Address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + AmountString: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + AmountDecimal: + type: number + format: float + description: Amount value with decimal places + example: 100.33 + TokenSymbol: + type: string + description: The symbol of a token + example: ETH + LogoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + RoutesResponse: + type: object + description: A collection of available and unavailable routes + required: + - routes + properties: + routes: + type: array + description: A collection of route objects + items: + type: object + properties: + id: + type: string + description: A unique identifier of the route. + gatewayID: + type: string + format: uuid + description: A unique identifier for the gateway. + mode: + type: string + enum: + - data + - transfer + description: 'The mode of operation for this route - ''data'' for arbitrary payload handling, ''transfer'' for asset transfer.' + fromDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will originate. + fromAmountUSD: + type: string + format: double + description: 'The amount of ''fromToken'' to be transferred in USD, specified as a string to maintain precision.' + fromAmount: + type: string + description: 'The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + pattern: '^[1-9][0-9]*$' + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + toDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will end. + toAmountUSD: + type: string + description: The expected amount to be received in USD. + toAmount: + type: string + description: 'The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + toAmountMin: + type: string + description: 'The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + gasCostUSD: + type: string + description: The expected gas cost in USD. + containsSwitchChain: + type: boolean + description: Whether chain switching is enabled or not. + steps: + type: array + description: 'List of steps involved in this route, adjusted for mode.' + items: + type: object + description: Details a single step within a route including actions and estimates. + properties: + id: + type: string + description: Id of the step + type: + type: string + description: 'Type of the step, typically describing the action, e.g., ''swap''.' + tool: + type: string + description: 'Tool used in the step, e.g., ''stargate''.' + action: + type: object + properties: + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + fromAmount: + type: string + description: 'The amount of ''fromToken'' to be transferred, specified as a string to maintain precision.' + example: '1000000000000000000' + pattern: '^[1-9][0-9]*$' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + slippage: + type: number + format: float + description: The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + example: 0.005 + fromAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + estimate: + type: object + description: 'Provides an estimation for a transaction, including costs, amounts, and execution duration.' + properties: + approvalAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAmountMin: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + fromAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + feeCosts: + type: array + description: A collection of fee costs associated with the transaction. + items: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + amountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + token: + type: string + description: The symbol of a token + example: ETH + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. + gasCosts: + type: array + description: A collection of estimated gas costs for executing the transaction. + items: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: 'The gas price, specified as a string to maintain precision.' + example: '19236858243' + estimate: + type: string + description: 'The estimated gas required, specified as a string to maintain precision.' + example: '445393' + limit: + type: string + description: 'The gas limit for the transaction, specified as a string to maintain precision.' + example: '579011' + pattern: '^[1-9][0-9]*$' + amount: + type: string + description: The amount of gas required in the gas currency. + example: '8567962003424499' + pattern: '^[1-9][0-9]*$' + amountUSD: + type: string + description: The amount of gas required in USD. + example: '16.05' + pattern: '^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$' + token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + executionDuration: + type: integer + description: The estimated duration for the transaction execution in seconds. + example: 30 + fromAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + tool: + type: string + description: The tool or service used to generate this estimate. + example: satp + toolDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + integrationDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + includedStepIds: + type: array + description: 'IDs of further steps included within this step, allowing for nested actions without direct recursion.' + items: + type: string + insurance: + type: object + properties: + state: + type: string + description: The state of insurance applicability for the transaction. + example: NOT_INSURABLE + enum: + - NOT_INSURABLE + - INSURABLE + - INSURED + feeAmountUsd: + type: string + description: 'The fee amount for insurance, represented in USD.' + example: '10.00' + pattern: '^(0|[1-9]\d*)(\.\d+)?$' + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + required: + - id + - gatewayID + - mode + Route: + type: object + properties: + id: + type: string + description: A unique identifier of the route. + gatewayID: + type: string + format: uuid + description: A unique identifier for the gateway. + mode: + type: string + enum: + - data + - transfer + description: 'The mode of operation for this route - ''data'' for arbitrary payload handling, ''transfer'' for asset transfer.' + fromDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will originate. + fromAmountUSD: + type: string + format: double + description: 'The amount of ''fromToken'' to be transferred in USD, specified as a string to maintain precision.' + fromAmount: + type: string + description: 'The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + pattern: '^[1-9][0-9]*$' + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + toDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will end. + toAmountUSD: + type: string + description: The expected amount to be received in USD. + toAmount: + type: string + description: 'The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + toAmountMin: + type: string + description: 'The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)).' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + gasCostUSD: + type: string + description: The expected gas cost in USD. + containsSwitchChain: + type: boolean + description: Whether chain switching is enabled or not. + steps: + type: array + description: 'List of steps involved in this route, adjusted for mode.' + items: + type: object + description: Details a single step within a route including actions and estimates. + properties: + id: + type: string + description: Id of the step + type: + type: string + description: 'Type of the step, typically describing the action, e.g., ''swap''.' + tool: + type: string + description: 'Tool used in the step, e.g., ''stargate''.' + action: + type: object + properties: + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + fromAmount: + type: string + description: 'The amount of ''fromToken'' to be transferred, specified as a string to maintain precision.' + example: '1000000000000000000' + pattern: '^[1-9][0-9]*$' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + slippage: + type: number + format: float + description: The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + example: 0.005 + fromAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + estimate: + type: object + description: 'Provides an estimation for a transaction, including costs, amounts, and execution duration.' + properties: + approvalAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAmountMin: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + fromAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + feeCosts: + type: array + description: A collection of fee costs associated with the transaction. + items: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + amountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + token: + type: string + description: The symbol of a token + example: ETH + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. + gasCosts: + type: array + description: A collection of estimated gas costs for executing the transaction. + items: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: 'The gas price, specified as a string to maintain precision.' + example: '19236858243' + estimate: + type: string + description: 'The estimated gas required, specified as a string to maintain precision.' + example: '445393' + limit: + type: string + description: 'The gas limit for the transaction, specified as a string to maintain precision.' + example: '579011' + pattern: '^[1-9][0-9]*$' + amount: + type: string + description: The amount of gas required in the gas currency. + example: '8567962003424499' + pattern: '^[1-9][0-9]*$' + amountUSD: + type: string + description: The amount of gas required in USD. + example: '16.05' + pattern: '^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$' + token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + executionDuration: + type: integer + description: The estimated duration for the transaction execution in seconds. + example: 30 + fromAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + tool: + type: string + description: The tool or service used to generate this estimate. + example: satp + toolDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + integrationDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + includedStepIds: + type: array + description: 'IDs of further steps included within this step, allowing for nested actions without direct recursion.' + items: + type: string + insurance: + type: object + properties: + state: + type: string + description: The state of insurance applicability for the transaction. + example: NOT_INSURABLE + enum: + - NOT_INSURABLE + - INSURABLE + - INSURED + feeAmountUsd: + type: string + description: 'The fee amount for insurance, represented in USD.' + example: '10.00' + pattern: '^(0|[1-9]\d*)(\.\d+)?$' + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + required: + - id + - gatewayID + - mode + ContinueRequest: + type: object + properties: + sessionId: + type: string + format: uuid + description: A unique identifier for the transaction session to be continued. + contextId: + type: string + format: uuid + description: A unique identifier for the transaction context. + required: + - sessionId + - contextId + description: Schema for a request to continue a paused transaction session. + ContinueResponse: + type: object + description: 'Response schema for a continue request, returning the status of the SATP session.' + properties: + statusResponse: + description: 'Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information.' + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: '2023-01-01T00:00:00Z' + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 + required: + - statusResponse + Chain: + type: object + properties: + chainId: + type: string + description: A unique identifier for the blockchain network. + chainName: + type: string + description: The name of the blockchain network. + chainType: + type: string + description: 'The type of blockchain network (e.g., ''evm'', ''fabric'').' + networkName: + type: string + description: 'The specific network name within the blockchain (e.g., ''mainnet'', ''testnet'').' + required: + - chainId + - chainName + - chainType + - networkName + Chains: + title: Chains + type: array + description: List of chains and related metadata + items: + type: object + properties: + chainId: + type: string + description: A unique identifier for the blockchain network. + chainName: + type: string + description: The name of the blockchain network. + chainType: + type: string + description: 'The type of blockchain network (e.g., ''evm'', ''fabric'').' + networkName: + type: string + description: 'The specific network name within the blockchain (e.g., ''mainnet'', ''testnet'').' + required: + - chainId + - chainName + - chainType + - networkName + Token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + Tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + HealthCheckResponse: + type: object + properties: + status: + type: string + example: OK + BridgeInfo: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + IncludedStep: + type: object + description: Details a single step within a route including actions and estimates. + properties: + id: + type: string + description: Id of the step + type: + type: string + description: 'Type of the step, typically describing the action, e.g., ''swap''.' + tool: + type: string + description: 'Tool used in the step, e.g., ''stargate''.' + action: + type: object + properties: + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + fromAmount: + type: string + description: 'The amount of ''fromToken'' to be transferred, specified as a string to maintain precision.' + example: '1000000000000000000' + pattern: '^[1-9][0-9]*$' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + slippage: + type: number + format: float + description: The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + example: 0.005 + fromAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + estimate: + type: object + description: 'Provides an estimation for a transaction, including costs, amounts, and execution duration.' + properties: + approvalAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAmountMin: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + fromAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + feeCosts: + type: array + description: A collection of fee costs associated with the transaction. + items: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + amountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + token: + type: string + description: The symbol of a token + example: ETH + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. + gasCosts: + type: array + description: A collection of estimated gas costs for executing the transaction. + items: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: 'The gas price, specified as a string to maintain precision.' + example: '19236858243' + estimate: + type: string + description: 'The estimated gas required, specified as a string to maintain precision.' + example: '445393' + limit: + type: string + description: 'The gas limit for the transaction, specified as a string to maintain precision.' + example: '579011' + pattern: '^[1-9][0-9]*$' + amount: + type: string + description: The amount of gas required in the gas currency. + example: '8567962003424499' + pattern: '^[1-9][0-9]*$' + amountUSD: + type: string + description: The amount of gas required in USD. + example: '16.05' + pattern: '^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$' + token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + executionDuration: + type: integer + description: The estimated duration for the transaction execution in seconds. + example: 30 + fromAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + tool: + type: string + description: The tool or service used to generate this estimate. + example: satp + toolDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + integrationDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + includedStepIds: + type: array + description: 'IDs of further steps included within this step, allowing for nested actions without direct recursion.' + items: + type: string + Insurance: + type: object + properties: + state: + type: string + description: The state of insurance applicability for the transaction. + example: NOT_INSURABLE + enum: + - NOT_INSURABLE + - INSURABLE + - INSURED + feeAmountUsd: + type: string + description: 'The fee amount for insurance, represented in USD.' + example: '10.00' + pattern: '^(0|[1-9]\d*)(\.\d+)?$' + Action: + type: object + properties: + fromToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + fromAmount: + type: string + description: 'The amount of ''fromToken'' to be transferred, specified as a string to maintain precision.' + example: '1000000000000000000' + pattern: '^[1-9][0-9]*$' + toToken: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + slippage: + type: number + format: float + description: The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + example: 0.005 + fromAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + IntegrationDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: 'https://cdn.example.com/logos/1inch.png' + Estimate: + type: object + description: 'Provides an estimation for a transaction, including costs, amounts, and execution duration.' + properties: + approvalAddress: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + toAmountMin: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + fromAmount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + feeCosts: + type: array + description: A collection of fee costs associated with the transaction. + items: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + amountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + token: + type: string + description: The symbol of a token + example: ETH + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. + gasCosts: + type: array + description: A collection of estimated gas costs for executing the transaction. + items: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: 'The gas price, specified as a string to maintain precision.' + example: '19236858243' + estimate: + type: string + description: 'The estimated gas required, specified as a string to maintain precision.' + example: '445393' + limit: + type: string + description: 'The gas limit for the transaction, specified as a string to maintain precision.' + example: '579011' + pattern: '^[1-9][0-9]*$' + amount: + type: string + description: The amount of gas required in the gas currency. + example: '8567962003424499' + pattern: '^[1-9][0-9]*$' + amountUSD: + type: string + description: The amount of gas required in USD. + example: '16.05' + pattern: '^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$' + token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. + executionDuration: + type: integer + description: The estimated duration for the transaction execution in seconds. + example: 30 + fromAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + toAmountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + tool: + type: string + description: The tool or service used to generate this estimate. + example: satp + FeeCost: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + amountUSD: + type: string + description: The amount in string format including all decimals. + pattern: '^([1-9][0-9]*|0)(\.[0-9]+)?$' + example: '1000000000000000000' + token: + type: string + description: The symbol of a token + example: ETH + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. + GasCost: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: 'The gas price, specified as a string to maintain precision.' + example: '19236858243' + estimate: + type: string + description: 'The estimated gas required, specified as a string to maintain precision.' + example: '445393' + limit: + type: string + description: 'The gas limit for the transaction, specified as a string to maintain precision.' + example: '579011' + pattern: '^[1-9][0-9]*$' + amount: + type: string + description: The amount of gas required in the gas currency. + example: '8567962003424499' + pattern: '^[1-9][0-9]*$' + amountUSD: + type: string + description: The amount of gas required in USD. + example: '16.05' + pattern: '^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$' + token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + x-category: satp-core + type: string + description: 'The network of the DLT being interacted with. TODO: implement network identification draft' + chainType: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. + address: + type: string + description: A blockchain address. + example: '0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7' + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + type: string + description: 'The logo of a token, chain, dex etc.' + format: uri + tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... + verified: + type: boolean + description: Indicates whether the token is verified. diff --git a/packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo.yml b/packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo.yml new file mode 100644 index 0000000000..83fbab2cb7 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/yml/bol/openapi-blo.yml @@ -0,0 +1,337 @@ +openapi: 3.0.3 +info: + title: SATP Gateway Client (Business Logic Orchestrator) + version: 0.0.2 + description: |- + SATP is a protocol operating between two gateways that conducts the transfer of a digital asset from one gateway to another. The protocol establishes a secure channel between the endpoints and implements a 2-phase commit to ensure the properties of transfer atomicity, consistency, isolation and durability. + + This API defines the gateway client facing API (business logic orchestrator, or BLO), which is named API-Type 1 in the SATP-Core specification. + + **Additional Resources**: + - [Proposed SATP Charter](https://datatracker.ietf.org/doc/charter-ietf-satp/) + - [SATP Core draft](https://datatracker.ietf.org/doc/draft-ietf-satp-core) + - [SATP Crash Recovery draft](https://datatracker.ietf.org/doc/draft-belchior-satp-gateway-recovery/) + - [SATP Architecture draft](https://datatracker.ietf.org/doc/draft-ietf-satp-architecture/) + - [SATP Use-Cases draft](https://datatracker.ietf.org/doc/draft-ramakrishna-sat-use-cases/) + - [SATP Data sharing draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-data-sharing) + - [SATP View Addresses draft](https://datatracker.ietf.org/doc/draft-ramakrishna-satp-views-addresses) + contact: + name: Hyperledger Cacti + x-logo: + altText: Cacti logo + backgroundColor: '#fafafa' + url: https://github.com/hyperledger/cacti/blob/main/images/HL_Cacti_Logo_Color.png +externalDocs: + description: For more information about the SATP Gateway Client, refer to the official documentation. + url: https://github.com/hyperledger/cacti/tree/main/packages/cactus-plugin-satp-hermes/README.md +servers: + - url: http://{host}:{port}/api/v1/@hyperledger/cactus-plugin-satp-hermes + description: Development server + variables: + host: + default: localhost + port: + default: '3011' +tags: + - name: transaction + description: API endpoints for interacting with blockchains via gateways + - name: admin + description: API endpoints for fetching information on SATP sessions +paths: + /api/v1/@hyperledger/cactus-plugin-satp-hermes/transact: + post: + tags: + - transaction + summary: Submit a transaction intent + description: Allows users to queue intents for transactions based on specified parameters. + operationId: Transact + requestBody: + content: + application/json: + schema: + $ref: ./schemas.yml#/TransactRequest + required: true + responses: + '200': + description: Transaction successfully queued + content: + application/json: + schema: + $ref: ./schemas.yml#/TransactResponse + default: + description: An error occurred + content: + application/json: + schema: + $ref: ./schemas.yml#/APIError + /api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel: + post: + tags: + - transaction + summary: Cancel a transaction session + description: Attempts to cancel a previously submitted transaction intent using its session ID. + operationId: Cancel + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/cancel + requestBody: + content: + application/json: + schema: + $ref: ./schemas.yml#/CancelRequest + required: true + responses: + '200': + description: Transaction cancellation attempted + content: + application/json: + schema: + $ref: ./schemas.yml#/CancelResponse + default: + description: An error occurred or transaction cannot be cancelled + content: + application/json: + schema: + $ref: ./schemas.yml#/APIError + /api/v1/@hyperledger/cactus-plugin-satp-hermes/status: + get: + summary: Get SATP current session data + description: Retrieve the status of a SATP session + operationId: GetStatus + tags: + - admin + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/status + parameters: + - name: SessionID + in: query + schema: + $ref: ./schemas.yml#/SessionID + required: true + description: Unique identifier for the session. + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: ./schemas.yml#/StatusResponse + '400': + description: Bad request + '404': + description: Transaction not found + '500': + description: Internal server error + /api/v1/@hyperledger/cactus-plugin-satp-hermes/healthcheck: + get: + summary: Health check endpoint + description: Responds if SATP Hermes is on + operationId: GetHealthCheck + tags: + - admin + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: './schemas.yml#/HealthCheckResponse' + '500': + description: Internal server error + /api/v1/@hyperledger/cactus-plugin-satp-hermes/continue: + post: + tags: + - admin + summary: Continue a paused transaction session + description: Attempts to continue a previously paused transaction intent, resuming its execution. + operationId: Continue + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/continue + requestBody: + content: + application/json: + schema: + $ref: ./schemas.yml#/ContinueRequest + required: true + responses: + '200': + description: Transaction continuation attempted + content: + application/json: + schema: + $ref: ./schemas.yml#/ContinueResponse + default: + description: An error occurred or transaction cannot be continued + content: + application/json: + schema: + $ref: ./schemas.yml#/APIError + /api/v1/@hyperledger/cactus-plugin-satp-hermes/pause: + post: + tags: + - admin + summary: Pause a transaction session + description: Attempts to pause a previously submitted transaction intent, temporarily halting its execution. + operationId: Pause + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/pause + requestBody: + content: + application/json: + schema: + $ref: ./schemas.yml#/PauseRequest + required: true + responses: + '200': + description: Transaction pause attempted + content: + application/json: + schema: + $ref: ./schemas.yml#/PauseResponse + default: + description: An error occurred or transaction cannot be paused + content: + application/json: + schema: + $ref: ./schemas.yml#/APIError + + /api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations: + get: + tags: + - transaction + summary: Get supported integrations + description: Retrieves metadata about each supported blockchain networks, chains, and other systems. + operationId: GetIntegrations + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/integrations + responses: + "200": + description: A list of supported systems. + content: + application/json: + schema: + $ref: ./schemas.yml#/Chains + default: + description: An error occurred + content: + application/json: + schema: + $ref: ./schemas.yml#/APIError + /api/v1/@hyperledger/cactus-plugin-satp-hermes/routes: + get: + description: Get a list of possible routes for swapping one asset for another across multiple exchanges + summary: Get a list of routes for a gateway-to-gateway asset transfer + tags: + - transaction + operationId: GetRoutes + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/routes + parameters: + - name: fromNetworkID + in: query + schema: + $ref: ./schemas.yml#/DLTNetworkID + required: true + description: The sending DLT Network. + - name: fromAmount + in: query + schema: + $ref: ./schemas.yml#/AmountString + required: true + description: The amount that should be sent including all decimals. + - name: fromToken + in: query + schema: + $ref: ./schemas.yml#/Address + required: true + description: The token that should be transferred. Can be the address or the symbol. + - name: toDLTNetwork + in: query + schema: + $ref: ./schemas.yml#/DLTNetworkID + required: true + description: The receiving DLT Network. + - name: toToken + in: query + schema: + $ref: ./schemas.yml#/Address + required: true + description: The token that should be transferred to. Can be the address or the symbol. + - name: fromAddress + in: query + schema: + $ref: ./schemas.yml#/Address + required: true + description: The sending wallet address. + - name: toAddress + in: query + schema: + $ref: ./schemas.yml#/Address + required: true + description: The receiving wallet address. If none is provided, the fromAddress will be used. + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: ./schemas.yml#/RoutesResponse + default: + description: An error occurred + content: + application/json: + schema: + $ref: ./schemas.yml#/APIError + /api/v1/@hyperledger/cactus-plugin-satp-hermes/audit: + get: + tags: + - admin + summary: Audit transactions + description: Audits transactions based on provided filters such as start and end dates. Optionally includes proofs generated from each gateway transaction. + operationId: GetAudit + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/audit + parameters: + - name: auditStartDate + in: query + description: The start date for the audit period. + required: false + schema: + type: string + format: date-time + - name: auditEndDate + in: query + description: The end date for the audit period. + required: false + schema: + type: string + format: date-time + - name: includeProofs + in: query + description: Include proofs generated from each gateway transaction. + required: false + schema: + type: boolean + responses: + '200': + description: Audit results + content: + application/json: + schema: + $ref: ./schemas.yml#/getAuditResponse +components: + schemas: + $ref: ./schemas.yml diff --git a/packages/cactus-plugin-satp-hermes/src/main/yml/bol/schemas.yml b/packages/cactus-plugin-satp-hermes/src/main/yml/bol/schemas.yml new file mode 100644 index 0000000000..ab79555139 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/yml/bol/schemas.yml @@ -0,0 +1,696 @@ +AuthzScope: + type: string + enum: + - group:admin + - group:user + x-enum-descriptions: + - Identities with the group:admin scope are administrators of the system. + - Identities with the group:user scope are end users of the system who only have authorization to perform a limited set of actions. + x-enum-varnames: + - GroupAdmin + - GroupUser + example: group:admin +AuthzJwtClaim: + description: "Stores global constants related to the authorization of the application. Specifically enumerates the claims to validate for as per RFC 7519, section 4.1. See: https://tools.ietf.org/html/rfc7519#section-4.1" + type: string + enum: + - Hyperledger Labs - Carbon Accounting Tool + x-enum-descriptions: + - The "iss" (issuer) claim identifies the principal that issued the JWT. The processing of this claim is generally application specific. The "iss" value is a case-sensitive string containing a StringOrURI value. Use of this claim is OPTIONAL. + x-enum-varnames: + - iss + example: Hyperledger Labs - Carbon Accounting Tool +CredentialProfile: + type: string + enum: + - SAML + - OAUTH + - X509 + example: OAUTH +getAuditRequest: + description: "Request schema for initiating an audit. Includes the start and end dates for the audit period and an option to include proofs." + type: object + x-category: request + properties: + auditStartDate: + type: string + format: date-time + description: The start datetime for the audit. + example: "2023-01-01T00:00:00Z" + auditEndDate: + type: string + format: date-time + description: The end datetime for the audit. + example: "2023-01-31T23:59:59Z" + includeProofs: + type: boolean + description: Include proofs generated from each gateway transaction. + example: true +getAuditResponse: + description: "Response schema for an audit request. Contains the proofs generated during the audit period and the start and end datetimes." + type: object + x-category: response + properties: + proofs: + type: array + items: + type: string + description: An array of strings representing proofs. + example: ["proof1", "proof2"] + auditStartTime: + type: string + format: date-time + description: The start datetime of the audit period. + example: "2023-01-01T00:00:00Z" + auditEndTime: + type: string + format: date-time + description: The end datetime of the audit period. + example: "2023-01-31T23:59:59Z" +StatusResponse: + description: "Provides the current status of the SATP session including detailed information on the progress, such as substatus, stage, and step, along with the session start time and chain information." + type: object + x-category: response + required: + - status + - substatus + - stage + - step + - startTime + - originChain + - destinationChain + properties: + status: + type: string + enum: + - NOT_FOUND + - INVALID + - PENDING + - DONE + - FAILED + example: DONE + substatus: + type: string + enum: + - WAIT_SOURCE_CONFIRMATIONS + - WAIT_DESTINATION_TRANSACTION + - BRIDGE_NOT_AVAILABLE + - CHAIN_NOT_AVAILABLE + - REFUND_IN_PROGRESS + - UNKNOWN_ERROR + - COMPLETED + - PARTIAL + - REFUNDED + - NOT_PROCESSABLE_REFUND_NEEDED + example: COMPLETED + stage: + type: string + enum: + - STAGE0 + - STAGE1 + - STAGE2 + - STAGE3 + example: STAGE3 + step: + type: string + enum: + - transfer-initialization-claims + - conveyance-of-network-capabilities-and-parameters + - transfer-proposal-message + - transfer-proposal-receipt-message + - transfer-proposal-reject-and-conditional-reject-message + - transfer-commence-message + - commence-response-message + - lock-assertion-message + - lock-assertion-receipt-message + - commit-preparation-message + - commit-ready-message + - commit-final-assertion-message + - commit-final-acknowledgement-receipt-message + - transfer-complete-message + - rollback-transfer-initialization-claims + - rollback-conveyance-of-network-capabilities-and-parameters + - rollback-transfer-proposal-message + - rollback-transfer-proposal-receipt-message + - rollback-transfer-proposal-reject-and-conditional-reject-message + - rollback-transfer-commence-message + - rollback-commence-response-message + - rollback-lock-assertion-message + - rollback-lock-assertion-receipt-message + - rollback-commit-preparation-message + - rollback-commit-ready-message + - rollback-commit-final-assertion-message + - rollback-commit-final-acknowledgement-receipt-message + - rollback-transfer-complete-message + example: transfer-complete-message + startTime: + type: string + format: date-time + example: "2023-01-01T00:00:00Z" + originChain: + type: object + properties: + dltProtocol: + example: HyperledgerFabric + dltSubnetworkID: + example: subnetwork1 + destinationChain: + type: object + properties: + dltProtocol: + example: HyperledgerBesu + dltSubnetworkID: + example: subnetwork2 +PauseRequest: + description: "Request to temporarily pause an ongoing transaction session, identified by the session and context IDs." + type: object + properties: + sessionId: + type: string + format: uuid + example: "123e4567-e89b-12d3-a456-426614174000" + contextId: + type: string + format: uuid + example: "123e4567-e89b-12d3-a456-426614174001" + +PauseResponse: + description: "Response for a pause transaction request. Returns the current status of the SATP session post-pause action." + type: object + properties: + statusResponse: + $ref: ./schemas.yml#/StatusResponse + required: + - statusResponse +StatusRequest: + description: "Request for retrieving the current status of a session, identified by the session ID." + type: object + x-category: request + required: + - sessionID + properties: + sessionID: + type: string + description: The ID of the session for which the status is being requested. + example: "123e4567-e89b-12d3-a456-426614174000" +TransactRequest: + description: "Request schema for initiating a transaction. Includes details such as the transaction context, mode (data or transfer), payload, and information about the source and destination DLT networks." + type: object + required: + - contextID + - mode + properties: + contextID: + type: string + format: uuid + example: "123e4567-e89b-12d3-a456-426614174000" + mode: + type: string + enum: + - data + - transfer + example: transfer + payload: + type: string + example: '{"data":"example payload"}' + fromDLTNetworkID: + type: string + example: "network1" + toDLTNetworkID: + type: string + example: "network2" + fromAmount: + type: string + example: "100" + fromToken: + type: string + example: "TOKEN1" + toAmount: + type: string + example: "95" + toToken: + type: string + example: "TOKEN2" + +TransactResponse: + description: "Response schema for a transaction request. Includes the session ID and the current status of the transaction." + type: object + properties: + sessionID: + $ref: ./schemas.yml#/SessionID + statusResponse: + $ref: ./schemas.yml#/StatusResponse + required: + - sessionID + - statusResponse +CancelRequest: + description: "Request to cancel an ongoing transaction session, identified by the session ID." + type: object + properties: + sessionID: + $ref: ./schemas.yml#/SessionID + required: + - sessionID +CancelResponse: + description: "Response for a cancel transaction request. Indicates whether the cancel action was successful and includes the current session status." + type: object + properties: + statusResponse: + $ref: ./schemas.yml#/StatusResponse + cancelSuccessful: + type: boolean + description: Indicates whether the cancel operation was successful. + example: true + required: + - statusResponse + - cancelSuccessful +APIError: + x-category: response + type: object + x-go-type: ApiError + x-go-name: ApiError + description: An Error + required: + - message + - type + - code + - status + - timestamp + properties: + type: + type: string + description: HTTP error type + example: bad-request + code: + type: integer + description: Numeric error code + example: 16384 + status: + type: integer + description: HTTP status of the error + example: 500 + message: + type: string + description: Long error description + example: Oops there's been an internal error handling + timestamp: + type: string + description: Timestamp of the error + example: "2021-07-21T17:32:28Z" +DLTProtocol: + x-category: satp-core + type: string + enum: + - HyperledgerFabric + - HyperledgerBesu + description: Supported DLT protocols. +DLTNetworkID: + x-category: satp-core + type: string + description: "The network of the DLT being interacted with. TODO: implement network identification draft" +DLTSubnetworkID: + x-category: satp-core + type: string + description: "The subnetwork of the DLT being interacted with. TODO: implement network identification draft" +SessionID: + x-category: satp-core + type: string + description: Unique identifier (UUID) for the session. + example: 000003e8-e0b8-21ee-ba00-325096b39f47 +Address: + type: string + description: A blockchain address. + example: "0x102A0F6D9F0F507288fE1e26740cFaD61184CCC7" +AmountString: + type: string + description: The amount in string format including all decimals. + pattern: ^([1-9][0-9]*|0)(\.[0-9]+)?$ + example: "1000000000000000000" +AmountDecimal: + type: number + format: float + description: Amount value with decimal places + example: 100.33 +TokenSymbol: + type: string + description: The symbol of a token + example: ETH +LogoURI: + type: string + description: The logo of a token, chain, dex etc. + format: uri +RoutesResponse: + type: object + description: A collection of available and unavailable routes + required: + - routes + properties: + routes: + type: array + description: A collection of route objects + items: + $ref: ./schemas.yml#/Route +Route: + type: object + properties: + id: + type: string + description: A unique identifier of the route. + gatewayID: + type: string + format: uuid + description: A unique identifier for the gateway. + mode: + type: string + enum: + - data + - transfer + description: The mode of operation for this route - 'data' for arbitrary payload handling, 'transfer' for asset transfer. + fromDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will originate. + fromAmountUSD: + type: string + format: double + description: The amount of 'fromToken' to be transferred in USD, specified as a string to maintain precision. + fromAmount: + type: string + description: The amount that should be sent including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + pattern: ^[1-9][0-9]*$ + fromToken: + $ref: ./schemas.yml#/Token + toDLTNetworkID: + type: string + description: The ID of the DLT Network where the operation will end. + toAmountUSD: + type: string + description: The expected amount to be received in USD. + toAmount: + type: string + description: The expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + toAmountMin: + type: string + description: The minimum expected amount to be received including all decimals (e.g., 1000000 for 1 USDC (6 decimals)). + toToken: + $ref: ./schemas.yml#/Token + gasCostUSD: + type: string + description: The expected gas cost in USD. + containsSwitchChain: + type: boolean + description: Whether chain switching is enabled or not. + steps: + type: array + description: List of steps involved in this route, adjusted for mode. + items: + $ref: ./schemas.yml#/IncludedStep + insurance: + $ref: ./schemas.yml#/Insurance + tags: + $ref: ./schemas.yml#/Tags + required: + - id + - gatewayID + - mode +ContinueRequest: + type: object + properties: + sessionId: + type: string + format: uuid + description: A unique identifier for the transaction session to be continued. + contextId: + type: string + format: uuid + description: A unique identifier for the transaction context. + required: + - sessionId + - contextId + description: Schema for a request to continue a paused transaction session. +ContinueResponse: + type: object + description: Response schema for a continue request, returning the status of the SATP session. + properties: + statusResponse: + $ref: ./schemas.yml#/StatusResponse + required: + - statusResponse +Chain: + type: object + properties: + chainId: + type: string + description: A unique identifier for the blockchain network. + chainName: + type: string + description: The name of the blockchain network. + chainType: + type: string + description: The type of blockchain network (e.g., 'evm', 'fabric'). + networkName: + type: string + description: The specific network name within the blockchain (e.g., 'mainnet', 'testnet'). + required: + - chainId + - chainName + - chainType + - networkName +Chains: + title: Chains + type: array + description: List of chains and related metadata + items: + $ref: ./schemas.yml#/Chain +Token: + type: object + description: Metadata detailing a supported token + required: + - chainID + - chainType + - address + - symbol + - decimals + properties: + chainID: + $ref: ./schemas.yml#/DLTNetworkID + chainType: + $ref: ./schemas.yml#/DLTProtocol + address: + $ref: ./schemas.yml#/Address + name: + type: string + description: The name of the token. + symbol: + type: string + description: The symbol of the token. + decimals: + type: integer + description: How many decimals the token supports. + minimum: 1 + logoURI: + $ref: ./schemas.yml#/LogoURI + tags: + $ref: ./schemas.yml#/Tags + priceUSD: + type: string + description: The current price of the token in USD. + extensions: + type: object + properties: + bridgeInfo: + type: object + additionalProperties: + $ref: ./schemas.yml#/BridgeInfo + verified: + type: boolean + description: Indicates whether the token is verified. +Tags: + title: Tags + type: array + description: List of tags identifiers providing additional context or categorization. + items: + type: string + example: + - satp + - hyperledger +HealthCheckResponse: + type: object + properties: + status: + type: string + example: 'OK' +BridgeInfo: + type: object + description: Information about the bridge used for the token transfer. + properties: + tokenAddress: + type: string + description: The address of the token being transferred. + example: 0x... +IncludedStep: + type: object + description: Details a single step within a route including actions and estimates. + properties: + id: + type: string + description: Id of the step + type: + type: string + description: Type of the step, typically describing the action, e.g., 'swap'. + tool: + type: string + description: Tool used in the step, e.g., 'stargate'. + action: + $ref: ./schemas.yml#/Action + estimate: + $ref: ./schemas.yml#/Estimate + toolDetails: + $ref: ./schemas.yml#/IntegrationDetails + integrationDetails: + $ref: ./schemas.yml#/IntegrationDetails + includedStepIds: + type: array + description: IDs of further steps included within this step, allowing for nested actions without direct recursion. + items: + type: string +Insurance: + type: object + properties: + state: + type: string + description: The state of insurance applicability for the transaction. + example: NOT_INSURABLE + enum: + - NOT_INSURABLE + - INSURABLE + - INSURED + feeAmountUsd: + type: string + description: The fee amount for insurance, represented in USD. + example: "10.00" + pattern: ^(0|[1-9]\d*)(\.\d+)?$ +Action: + type: object + properties: + fromToken: + $ref: ./schemas.yml#/Token + fromAmount: + type: string + description: The amount of 'fromToken' to be transferred, specified as a string to maintain precision. + example: "1000000000000000000" + pattern: ^[1-9][0-9]*$ + toToken: + $ref: ./schemas.yml#/Token + slippage: + type: number + format: float + description: The maximum acceptable difference between the expected price of the 'toToken' and the price at the time of the transfer. + example: 0.005 + fromAddress: + $ref: ./schemas.yml#/Address + toAddress: + $ref: ./schemas.yml#/Address +IntegrationDetails: + type: object + description: Describes integration or tool details such as bridges or exchanges involved in the transaction. + required: + - key + - name + - logoURI + properties: + key: + type: string + description: A unique identifier for the integration or tool. + example: 1inch + name: + type: string + description: The name of the integration or tool. + example: 1inch Exchange + logoURI: + type: string + format: uri + description: URL to the logo of the integration or tool. + example: https://cdn.example.com/logos/1inch.png +Estimate: + type: object + description: Provides an estimation for a transaction, including costs, amounts, and execution duration. + properties: + approvalAddress: + $ref: ./schemas.yml#/Address + toAmountMin: + $ref: ./schemas.yml#/AmountString + toAmount: + $ref: ./schemas.yml#/AmountString + fromAmount: + $ref: ./schemas.yml#/AmountString + feeCosts: + type: array + description: A collection of fee costs associated with the transaction. + items: + $ref: ./schemas.yml#/FeeCost + gasCosts: + type: array + description: A collection of estimated gas costs for executing the transaction. + items: + $ref: ./schemas.yml#/GasCost + executionDuration: + type: integer + description: The estimated duration for the transaction execution in seconds. + example: 30 + fromAmountUSD: + $ref: ./schemas.yml#/AmountString + toAmountUSD: + $ref: ./schemas.yml#/AmountString + tool: + type: string + description: The tool or service used to generate this estimate. + example: satp +FeeCost: + type: object + description: Details about a specific fee cost associated with the transaction. + properties: + name: + type: string + description: Name of the fee cost. + example: Network Fee + amount: + $ref: ./schemas.yml#/AmountString + amountUSD: + $ref: ./schemas.yml#/AmountString + token: + $ref: ./schemas.yml#/TokenSymbol + included: + type: boolean + description: Indicates if the fee is included in the transaction amount. +GasCost: + type: object + properties: + type: + type: string + description: The type of the gas cost. + example: SEND + price: + type: string + description: The gas price, specified as a string to maintain precision. + example: "19236858243" + estimate: + type: string + description: The estimated gas required, specified as a string to maintain precision. + example: "445393" + limit: + type: string + description: The gas limit for the transaction, specified as a string to maintain precision. + example: "579011" + pattern: ^[1-9][0-9]*$ + amount: + type: string + description: The amount of gas required in the gas currency. + example: "8567962003424499" + pattern: ^[1-9][0-9]*$ + amountUSD: + type: string + description: The amount of gas required in USD. + example: "16.05" + pattern: ^(0(\.[0-9]+)?|[1-9][0-9]*(\.[0-9]+)?)$ + token: + $ref: ./schemas.yml#/Token diff --git a/packages/cactus-plugin-satp-hermes/src/main/yml/openapi.yml b/packages/cactus-plugin-satp-hermes/src/main/yml/openapi.yml new file mode 100644 index 0000000000..5027174a8d --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/main/yml/openapi.yml @@ -0,0 +1,1229 @@ +openapi: 3.0.3 +info: + title: Hyperledger Cactus Plugin - Odap Hermes + description: Implementation for Odap and Hermes + version: v2.0.0-alpha.2 + license: + name: Apache-2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html +components: + schemas: + CredentialProfile: + type: string + enum: + - SAML + - OAUTH + - X509 + PayloadProfile: + type: object + properties: + assetProfile: + $ref: '#/components/schemas/AssetProfile' + capabilities: + type: string + required: + - assetProfile + ApplicationProfile: + type: object + Payload: + type: object + AssetProfile: + type: object + properties: + issuer: + type: string + assetCode: + type: string + assetCodeType: + type: string + issuanceDate: + type: string + expirationDate: + type: string + verificationEndPoint: + type: string + digitalSignature: + type: string + prospectusLink: + type: string + keyInformationLink: + type: array + items: {} + keyWord: + type: array + items: {} + transferRestriction: + type: array + items: {} + ledgerRequirements: + type: array + items: {} + required: + - expirationDate + LoggingProfile: + type: array + items: + type: string + AccessControlProfile: + type: array + items: + type: string + Permissions: + type: object + Transaction: + type: object + ActionCategory: + type: object + History: + type: object + properties: + Transactions: + type: array + items: + $ref: '#/components/schemas/Transaction' + Actions: + type: array + items: + $ref: '#/components/schemas/ActionCategory' + Origin: + type: string + Destination: + type: string + Balance: + type: string + CurrentStatus: + type: object + ApplicationSpecificParameters: + type: object + SenderDltSystem: + type: object + RecipientDltSystem: + type: object + LockEvidenceClaim: + type: object + LockClaimFormat: + type: object + CommitFinalClaim: + type: object + CommitFinalClaimFormat: + type: object + CommitAcknowledgementClaim: + type: object + CommitAcknowledgementClaimFormat: + type: object + SessionData: + type: object + properties: + id: + type: string + step: + type: number + version: + type: string + lastSequenceNumber: + type: number + loggingProfile: + type: string + accessControlProfile: + type: string + applicationProfile: + type: string + payloadProfile: + $ref: '#/components/schemas/PayloadProfile' + assetProfile: + $ref: '#/components/schemas/AssetProfile' + allowedSourceBackupGateways: + type: array + items: + type: string + allowedRecipientBackupGateways: + type: array + items: + type: string + sourceBasePath: + type: string + recipientBasePath: + type: string + originatorPubkey: + type: string + beneficiaryPubkey: + type: string + sourceGatewayPubkey: + type: string + sourceGatewayDltSystem: + type: string + recipientGatewayPubkey: + type: string + recipientGatewayDltSystem: + type: string + initializationRequestMessageHash: + type: string + initializationResponseMessageHash: + type: string + initializationRequestMessageRcvTimeStamp: + type: string + initializationRequestMessageProcessedTimeStamp: + type: string + clientSignatureInitializationRequestMessage: + type: string + serverSignatureInitializationResponseMessage: + type: string + transferCommenceMessageRequestHash: + type: string + transferCommenceMessageResponseHash: + type: string + clientSignatureTransferCommenceRequestMessage: + type: string + serverSignatureTransferCommenceResponseMessage: + type: string + lockEvidenceRequestMessageHash: + type: string + lockEvidenceResponseMessageHash: + type: string + clientSignatureLockEvidenceRequestMessage: + type: string + serverSignatureLockEvidenceResponseMessage: + type: string + lockEvidenceClaim: + type: string + commitPrepareRequestMessageHash: + type: string + commitPrepareResponseMessageHash: + type: string + clientSignatureCommitPreparationRequestMessage: + type: string + serverSignatureCommitPreparationResponseMessage: + type: string + commitFinalRequestMessageHash: + type: string + commitFinalResponseMessageHash: + type: string + commitFinalClaim: + type: string + commitFinalClaimFormat: + type: string + commitAcknowledgementClaim: + type: string + commitAcknowledgementClaimFormat: + type: string + clientSignatureCommitFinalRequestMessage: + type: string + serverSignatureCommitFinalResponseMessage: + type: string + transferCompleteMessageHash: + type: string + clientSignatureTransferCompleteMessage: + type: string + maxRetries: + type: number + recipientLedgerAssetID: + type: string + sourceLedgerAssetID: + type: string + maxTimeout: + type: number + lastLogEntryTimestamp: + type: string + unlockAssetClaim: + type: string + recreateAssetClaim: + type: string + deleteAssetClaim: + type: string + lastMessageReceivedTimestamp: + type: string + rollback: + type: boolean + rollbackMessageHash: + type: string + rollbackProofs: + type: array + items: + type: string + rollbackActionsPerformed: + type: array + items: + type: string + enum: + - CREATE + - DELETE + - LOCK + - UNLOCK + TransferInitializationV1Request: + type: object + properties: + messageType: + type: string + sessionID: + type: string + version: + type: string + developerURN: + type: string + credentialProfile: + $ref: '#/components/schemas/CredentialProfile' + payloadProfile: + $ref: '#/components/schemas/PayloadProfile' + applicationProfile: + type: string + loggingProfile: + type: string + accessControlProfile: + type: string + signature: + type: string + sourceGatewayPubkey: + type: string + sourceGatewayDltSystem: + type: string + recipientGatewayPubkey: + type: string + recipientGatewayDltSystem: + type: string + escrowType: + type: string + enum: + - FAUCET + - TIMELOCK + - HASHLOCK + - HASHTIMELOCK + - MULTICLAIMPC + - DESTROY + - BURN + expiryTime: + type: string + multipleClaimsAllowed: + type: boolean + multipleCancelsAllowed: + type: boolean + permissions: + $ref: '#/components/schemas/Permissions' + origin: + type: string + destination: + type: string + subsequentCalls: + type: object + histories: + type: array + items: + $ref: '#/components/schemas/History' + sequenceNumber: + type: integer + sourceBasePath: + type: string + recipientBasePath: + type: string + maxRetries: + type: number + maxTimeout: + type: number + backupGatewaysAllowed: + type: array + items: + type: string + recipientLedgerAssetID: + type: string + sourceLedgerAssetID: + type: string + required: + - messageType + - sessionID + - loggingProfile + - accessControlProfile + - payloadProfile + - applicationProfile + - signature + - sourceGatewayPubkey + - sourceGatewayDltSystem + - recipientGatewayPubkey + - recipientGatewayDltSystem + - sequenceNumber + - sourceBasePath + - recipientBasePath + - maxRetries + - maxTimeout + - backupGatewaysAllowed + - recipientLedgerAssetID + - sourceLedgerAssetID + TransferInitializationV1Response: + type: object + properties: + messageType: + type: string + sessionID: + type: string + sequenceNumber: + type: number + odapPhase: + type: string + enum: + - TransferInitialization + - LockEvidenceVerification + - CommitmentEstablishment + initialRequestMessageHash: + type: string + destination: + type: string + timeStamp: + type: string + processedTimeStamp: + type: string + serverIdentityPubkey: + type: string + signature: + type: string + backupGatewaysAllowed: + type: array + items: + type: string + required: + - messageType + - initialRequestMessageHash + - timeStamp + - processedTimeStamp + - sessionID + - serverIdentityPubkey + - sequenceNumber + - signature + - backupGatewaysAllowed + TransferCommenceV1Request: + type: object + properties: + sessionID: + type: string + messageType: + type: string + originatorPubkey: + type: string + beneficiaryPubkey: + type: string + senderDltSystem: + type: string + recipientDltSystem: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + hashAssetProfile: + type: string + assetUnit: + type: integer + hashPrevMessage: + type: string + clientTransferNumber: + type: integer + nullable: true + signature: + type: string + sequenceNumber: + type: integer + required: + - sessionID + - messageType + - originatorPubkey + - beneficiaryPubkey + - senderDltSystem + - recipientDltSystem + - clientIdentityPubkey + - serverIdentityPubkey + - hashAssetProfile + - hashPrevMessage + - signature + - sequenceNumber + TransferCommenceV1Response: + type: object + properties: + sessionID: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + hashCommenceRequest: + type: string + serverTransferNumber: + type: integer + nullable: true + signature: + type: string + messageType: + type: string + messageHash: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - serverIdentityPubkey + - clientIdentityPubkey + - hashCommenceRequest + - signature + - sequenceNumber + LockEvidenceV1Request: + type: object + properties: + sessionID: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + lockEvidenceClaim: + type: string + lockEvidenceFormat: + $ref: '#/components/schemas/LockClaimFormat' + nullable: true + lockEvidenceExpiration: + type: string + hashCommenceAckRequest: + type: string + clientTransferNumber: + type: integer + nullable: true + signature: + type: string + messageType: + type: string + messageHash: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - lockEvidenceClaim + - lockEvidenceExpiration + - hashCommenceAckRequest + - signature + - sequenceNumber + LockEvidenceV1Response: + type: object + properties: + sessionID: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + hashLockEvidenceRequest: + type: string + serverTransferNumber: + type: integer + nullable: true + signature: + type: string + messageType: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - hashLockEvidenceRequest + - signature + - sequenceNumber + CommitPreparationV1Request: + type: object + properties: + sessionID: + type: string + messageType: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + hashLockEvidenceAck: + type: string + clientTransferNumber: + type: integer + signature: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - hashLockEvidenceAck + - signature + - sequenceNumber + CommitPreparationV1Response: + type: object + properties: + sessionID: + type: string + messageType: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + hashCommitPrep: + type: string + serverTransferNumber: + type: string + signature: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - hashCommitPrep + - signature + - sequenceNumber + CommitFinalV1Request: + type: object + properties: + sessionID: + type: string + messageType: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + commitFinalClaim: + type: string + commitFinalClaimFormat: + $ref: '#/components/schemas/CommitFinalClaimFormat' + hashCommitPrepareAck: + type: string + clientTransferNumber: + type: integer + nullable: true + signature: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - commitFinalClaim + - hashCommitPrepareAck + - signature + - sequenceNumber + CommitFinalV1Response: + type: object + properties: + sessionID: + type: string + messageType: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + commitAcknowledgementClaim: + type: string + commitAcknowledgementClaimFormat: + $ref: '#/components/schemas/CommitAcknowledgementClaimFormat' + hashCommitFinal: + type: string + serverTransferNumber: + type: integer + signature: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - commitAcknowledgementClaim + - hashCommitFinal + - signature + - sequenceNumber + TransferCompleteV1Request: + type: object + properties: + sessionID: + type: string + messageType: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + hashCommitFinalAck: + type: string + clientTransferNumber: + type: integer + nullable: true + signature: + type: string + hashTransferCommence: + type: string + sequenceNumber: + type: number + required: + - sessionID + - messageType + - clientIdentityPubkey + - serverIdentityPubkey + - hashCommitFinalAck + - signature + - hashTransferCommence + - sequenceNumber + ClientV1Request: + type: object + properties: + version: + type: string + loggingProfile: + type: string + accessControlProfile: + type: string + assetControlProfile: + type: string + applicationProfile: + type: string + assetProfile: + $ref: '#/components/schemas/AssetProfile' + payloadProfile: + $ref: '#/components/schemas/PayloadProfile' + sourceGatewayDltSystem: + type: string + recipientGatewayDltSystem: + type: string + recipientGatewayPubkey: + type: string + originatorPubkey: + type: string + beneficiaryPubkey: + type: string + clientIdentityPubkey: + type: string + serverIdentityPubkey: + type: string + clientDltSystem: + type: string + serverDltSystem: + type: string + clientGatewayConfiguration: + type: object + properties: + apiHost: + type: string + required: + - apiHost + serverGatewayConfiguration: + type: object + properties: + apiHost: + type: string + required: + - apiHost + maxRetries: + type: number + maxTimeout: + type: number + sourceLedgerAssetID: + type: string + recipientLedgerAssetID: + type: string + required: + - version + - loggingProfile + - accessControlProfile + - assetControlProfile + - applicationProfile + - assetProfile + - payloadProfile + - sourceGatewayDltSystem + - recipientGatewayDltSystem + - recipientGatewayPubkey + - originatorPubkey + - beneficiaryPubkey + - clientIdentityPubkey + - serverIdentityPubkey + - clientDltSystem + - serverDltSystem + - clientGatewayConfiguration + - serverGatewayConfiguration + - maxRetries + - maxTimeout + - sourceLedgerAssetID + - recipientLedgerAssetID + RecoverV1Message: + type: object + properties: + sessionID: + type: string + odapPhase: + type: string + sequenceNumber: + type: number + lastLogEntryTimestamp: + type: string + isBackup: + type: boolean + newBasePath: + type: string + newGatewayPubKey: + type: string + signature: + type: string + required: + - sessionID + - odapPhase + - sequenceNumber + - lastLogEntryTimestamp + - isBackup + - newBasePath + - signature + RecoverUpdateV1Message: + type: object + properties: + sessionID: + type: string + recoveredLogs: + type: array + items: + $ref: '#/components/schemas/LocalLog' + signature: + type: string + required: + - sessionID + - recoveredLogs + - signature + RecoverUpdateAckV1Message: + type: object + properties: + sessionID: + type: string + success: + type: boolean + changedEntriesHash: + type: array + items: + type: string + signature: + type: string + required: + - sessionID + - success + - changedEntriesHash + - signature + RecoverSuccessV1Message: + type: object + properties: + sessionID: + type: string + success: + type: boolean + signature: + type: string + required: + - sessionID + - success + - signature + RollbackV1Message: + type: object + properties: + sessionID: + type: string + success: + type: boolean + actionPerformed: + type: array + items: + type: string + proofs: + type: array + items: + type: string + signature: + type: string + required: + - sessionID + - success + - actionPerformed + - proofs + - signature + RollbackAckV1Message: + type: object + properties: + sessionID: + type: string + success: + type: boolean + signature: + type: string + required: + - sessionID + - success + - signature + LocalLog: + type: object + properties: + key: + type: string + sessionID: + type: string + data: + type: string + type: + type: string + operation: + type: string + timestamp: + type: string + required: + - sessionID + - type + - operation + SatpMessage: + type: object + properties: + SequenceNumber: + type: number + Phase: + type: string + enum: + - TransferInitialization + - LockEvidenceVerification + - CommitmentEstablishment + ResourceURL: + type: string + DeveloperURN: + type: string + ActionResponse: + type: object + properties: + ResponseCode: + type: string + enum: + - '200' + - '404' + x-enum-varnames: + - OK + - RESOURCE_NOT_FOUND + Arguments: + type: array + items: {} + CredentialProfile: + type: string + enum: + - SAML + - OAuth + - X509 + CredentialBlock: + type: array + items: {} + CredentialsProfile: + $ref: '#/components/schemas/PayloadProfile' + ApplicationProfile: + $ref: '#/components/schemas/ApplicationProfile' + Payload: + $ref: '#/components/schemas/Payload' + PayloadHash: + type: string + MessageSignature: + type: string +paths: + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationrequest: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationrequest + operationId: phase1TransferInitiationRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TransferInitializationV1Request' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommencerequest: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommencerequest + operationId: phase2TransferCommenceRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TransferCommenceV1Request' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidencerequest: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidencerequest + operationId: phase2LockEvidenceRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LockEvidenceV1Request' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationrequest: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationrequest + operationId: phase3CommitPreparationRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CommitPreparationV1Request' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalrequest: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalrequest + operationId: phase3CommitFinalRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CommitFinalV1Request' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/transfercompleterequest: + get: + x-hyperledger-cacti: + http: + verbLowerCase: get + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/transfercompleterequest + operationId: phase3TransferCompleteRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TransferCompleteV1Request' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/clientrequest: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/clientrequest + operationId: clientRequestV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientV1Request' + responses: + '200': + description: OK + content: + application/json: + schema: {} + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationresponse: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase1/transferinitiationresponse + operationId: phase1TransferInitiationResponseV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TransferInitializationV1Response' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommenceresponse: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/transfercommenceresponse + operationId: phase2TransferCommenceResponseV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TransferCommenceV1Response' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidenceresponse: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase2/lockevidenceresponse + operationId: phase2LockEvidenceResponseV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LockEvidenceV1Response' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationresponse: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitpreparationresponse + operationId: phase3CommitPreparationResponseV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CommitPreparationV1Response' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalresponse: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/phase3/commitfinalresponse + operationId: phase3CommitFinalResponseV1 + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CommitFinalV1Response' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/recovermessage: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/recovermessage + operationId: RecoverV1Message + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RecoverV1Message' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdatemessage: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdatemessage + operationId: RecoverUpdateV1Message + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RecoverUpdateV1Message' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdateackmessage: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/recoverupdateackmessage + operationId: RecoverUpdateAckV1Message + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RecoverUpdateAckV1Message' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/recoversuccessmessage: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/recoversuccessmessage + operationId: RecoverV1Success + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RecoverSuccessV1Message' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackmessage: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackmessage + operationId: RollbackV1Message + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RollbackV1Message' + responses: + '200': + description: OK + /api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackackmessage: + post: + x-hyperledger-cacti: + http: + verbLowerCase: post + path: /api/v1/@hyperledger/cactus-plugin-satp-hermes/rollbackackmessage + operationId: RollbackAckV1Message + description: '' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RollbackAckV1Message' + responses: + '200': + description: OK diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/client-crash-after-transfer-initiation.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/client-crash-after-transfer-initiation.test.ts index 8c3a4f5ff0..6e7a8fad98 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/client-crash-after-transfer-initiation.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/client-crash-after-transfer-initiation.test.ts @@ -31,7 +31,10 @@ import { knexRemoteConnection, knexServerConnection, } from "../knex.config"; -import { Containers, pruneDockerAllIfGithubAction } from "@hyperledger/cactus-test-tooling"; +import { + Containers, + pruneDockerAllIfGithubAction, +} from "@hyperledger/cactus-test-tooling"; const logLevel: LogLevelDesc = "INFO"; @@ -68,13 +71,13 @@ const log = LoggerProvider.getOrCreate({ beforeAll(async () => { pruneDockerAllIfGithubAction({ logLevel }) - .then(() => { - log.info("Pruning throw OK"); - }) - .catch(async () => { - await Containers.logDiagnostics({ logLevel }); - fail("Pruning didn't throw OK"); - }); + .then(() => { + log.info("Pruning throw OK"); + }) + .catch(async () => { + await Containers.logDiagnostics({ logLevel }); + fail("Pruning didn't throw OK"); + }); { // Server Gateway configuration @@ -107,9 +110,13 @@ beforeAll(async () => { pluginRecipientGateway = new BesuSATPGateway(serverGatewayPluginOptions); - expect(pluginRecipientGateway.localRepository?.database).not.toBeUndefined(); - expect(pluginRecipientGateway.remoteRepository?.database).not.toBeUndefined(); - + expect( + pluginRecipientGateway.localRepository?.database, + ).not.toBeUndefined(); + expect( + pluginRecipientGateway.remoteRepository?.database, + ).not.toBeUndefined(); + await pluginRecipientGateway.localRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/gateway-coordinator-init.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/gateway-coordinator-init.test.ts index e1ec6bbe27..7ddc8a62d9 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/gateway-coordinator-init.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/gateway-coordinator-init.test.ts @@ -1,42 +1,33 @@ import "jest-extended"; import { Containers, + FabricTestLedgerV1, pruneDockerAllIfGithubAction, + BesuTestLedger, } from "@hyperledger/cactus-test-tooling"; -import { - LogLevelDesc, - Logger, - LoggerProvider, -} from "@hyperledger/cactus-common"; +import { LogLevelDesc, LoggerProvider } from "@hyperledger/cactus-common"; // import coordinator factory, coordinator and coordinator options -import { - SATPGateway, - SATPGatewayConfig, -} from "../../../main/typescript/gateway-refactor"; +import { SATPGateway, SATPGatewayConfig } from "../../../main/typescript/gateway-refactor"; import { PluginFactorySATPGateway } from "../../../main/typescript/factory/plugin-factory-gateway-orchestrator"; import { - IPluginFactoryOptions, - PluginImportType, + IPluginFactoryOptions, PluginImportType, } from "@hyperledger/cactus-core-api"; -import { - ShutdownHook, - SupportedGatewayImplementations, -} from "./../../../main/typescript/core/types"; +import { SupportedGatewayImplementations } from './../../../main/typescript/core/types'; const logLevel: LogLevelDesc = "INFO"; -const logger = LoggerProvider.getOrCreate({ +const log = LoggerProvider.getOrCreate({ level: "INFO", label: "satp-gateway-orchestrator-init-test", }); const factoryOptions: IPluginFactoryOptions = { pluginImportType: PluginImportType.Local, -}; +} const factory = new PluginFactorySATPGateway(factoryOptions); beforeAll(async () => { pruneDockerAllIfGithubAction({ logLevel }) .then(() => { - logger.info("Pruning throw OK"); + log.info("Pruning throw OK"); }) .catch(async () => { await Containers.logDiagnostics({ logLevel }); @@ -45,6 +36,7 @@ beforeAll(async () => { }); describe("SATPGateway initialization", () => { + it("initiates with default config", async () => { const options: SATPGatewayConfig = {}; const gateway = await factory.create(options); @@ -67,7 +59,7 @@ describe("SATPGateway initialization", () => { SupportedGatewayImplementations.BESU, ]); expect(identity.proofID).toBe("mockProofID1"); - expect(identity.gatewayServerPort).toBe(3010); + expect(identity.port).toBe(3000); expect(identity.address).toBe("http://localhost"); }); @@ -89,7 +81,7 @@ describe("SATPGateway initialization", () => { SupportedGatewayImplementations.BESU, ], proofID: "mockProofID10", - gatewayServerPort: 3010, + port: 3001, address: "https://localhost", }, }; @@ -113,7 +105,7 @@ describe("SATPGateway initialization", () => { SupportedGatewayImplementations.BESU, ]); expect(identity.proofID).toBe("mockProofID10"); - expect(identity.gatewayServerPort).toBe(3010); + expect(identity.port).toBe(3001); expect(identity.address).toBe("https://localhost"); }); @@ -135,6 +127,7 @@ describe("SATPGateway initialization", () => { SupportedGatewayImplementations.BESU, ], proofID: "mockProofID10", + port: 3010, address: "https://localhost", }, }; @@ -142,77 +135,20 @@ describe("SATPGateway initialization", () => { expect(gateway).toBeInstanceOf(SATPGateway); const identity = gateway.getIdentity(); - // default servers - expect(identity.gatewayServerPort).toBe(3010); - expect(identity.gatewayClientPort).toBe(3011); + expect(identity.port).toBe(3010); expect(identity.address).toBe("https://localhost"); - await gateway.startup(); + await gateway.startupServer(); await gateway.shutdown(); }); - it("shutdown hooks work", async () => { - const options: SATPGatewayConfig = { - gid: { - id: "mockID", - name: "CustomGateway", - version: [ - { - Core: "v02", - Architecture: "v02", - Crash: "v02", - }, - ], - supportedChains: [ - SupportedGatewayImplementations.FABRIC, - SupportedGatewayImplementations.BESU, - ], - proofID: "mockProofID10", - gatewayServerPort: 3014, - gatewayClientPort: 3015, - address: "https://localhost", - }, - }; - - const gateway = await factory.create(options); - expect(gateway).toBeInstanceOf(SATPGateway); - - // ensure logger is called with "mockHook" - const loggerSpy = jest.spyOn(logger, "info"); - - // ensure mockHookFn is called on shutdown - const mockHookFn = jest.fn(async () => { - logger.info("mockHook"); - }); - - const shutdownHook: ShutdownHook = { - name: "mockHook", - hook: async () => { - logger.info("mockHook"); - }, - }; - - const shutdownHookFn: ShutdownHook = { - name: "mockHookFn", - hook: mockHookFn, - }; - - gateway.onShutdown(shutdownHook); - gateway.onShutdown(shutdownHookFn); - await gateway.startup(); - await gateway.shutdown(); - - expect(loggerSpy).toHaveBeenCalledWith("mockHook"); - expect(mockHookFn).toHaveBeenCalled(); - - // for now, technically not needed. However if we use more tests with loggerSpy, conflicts could arise. This is a reminder to restore the spy after each test - loggerSpy.mockRestore(); - }); }); afterAll(async () => { + // shutdown channels + await pruneDockerAllIfGithubAction({ logLevel }) .then(() => { - logger.info("Pruning throw OK"); + log.info("Pruning throw OK"); }) .catch(async () => { await Containers.logDiagnostics({ logLevel }); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap-api-call.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap-api-call.test.ts index e49f1b8b5f..10355e7ccc 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap-api-call.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap-api-call.test.ts @@ -6,7 +6,12 @@ import bodyParser from "body-parser"; import express from "express"; import { DefaultApi as SatpApi } from "../../../main/typescript/public-api"; -import { IListenOptions, LogLevelDesc, LoggerProvider, Servers } from "@hyperledger/cactus-common"; +import { + IListenOptions, + LogLevelDesc, + LoggerProvider, + Servers, +} from "@hyperledger/cactus-common"; import { Configuration } from "@hyperledger/cactus-core-api"; @@ -25,7 +30,10 @@ import { FabricSATPGateway } from "../../../main/typescript/core/fabric-satp-gat import { ClientGatewayHelper } from "../../../main/typescript/core/client-helper"; import { ServerGatewayHelper } from "../../../main/typescript/core/server-helper"; import { knexRemoteConnection } from "../knex.config"; -import { Containers, pruneDockerAllIfGithubAction } from "@hyperledger/cactus-test-tooling"; +import { + Containers, + pruneDockerAllIfGithubAction, +} from "@hyperledger/cactus-test-tooling"; const logLevel: LogLevelDesc = "INFO"; @@ -81,13 +89,13 @@ test("runs ODAP between two gateways via openApi", async () => { expect(pluginSourceGateway.localRepository?.database).not.toBeUndefined(); expect(pluginRecipientGateway.localRepository?.database).not.toBeUndefined(); - + expect(pluginSourceGateway.remoteRepository?.database).not.toBeUndefined(); expect(pluginRecipientGateway.remoteRepository?.database).not.toBeUndefined(); await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap.test.ts index c09f08c65a..8342f08a1d 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/odap.test.ts @@ -14,7 +14,10 @@ import { ClientGatewayHelper } from "../../../main/typescript/core/client-helper import { ServerGatewayHelper } from "../../../main/typescript/core/server-helper"; import { knexRemoteConnection } from "../knex.config"; import { LogLevelDesc, LoggerProvider } from "@hyperledger/cactus-common"; -import { pruneDockerAllIfGithubAction, Containers } from "@hyperledger/cactus-test-tooling"; +import { + pruneDockerAllIfGithubAction, + Containers, +} from "@hyperledger/cactus-test-tooling"; const MAX_RETRIES = 5; const MAX_TIMEOUT = 5000; @@ -64,13 +67,13 @@ test("successful run ODAP instance", async () => { expect(pluginSourceGateway.localRepository?.database).not.toBeUndefined(); expect(pluginRecipientGateway.localRepository?.database).not.toBeUndefined(); - + expect(pluginSourceGateway.remoteRepository?.database).not.toBeUndefined(); expect(pluginRecipientGateway.remoteRepository?.database).not.toBeUndefined(); await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-get-status.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-get-status.test.ts new file mode 100644 index 0000000000..e7b4b9f447 --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-get-status.test.ts @@ -0,0 +1,108 @@ +import "jest-extended"; +import { + Containers, + pruneDockerAllIfGithubAction, +} from "@hyperledger/cactus-test-tooling"; +import { LogLevelDesc, LoggerProvider } from "@hyperledger/cactus-common"; +import { PluginFactorySATPGateway } from "../../../main/typescript/factory/plugin-factory-gateway-orchestrator"; +import { + IPluginFactoryOptions, + PluginImportType, +} from "@hyperledger/cactus-core-api"; + +import { + SATPGatewayConfig, + SupportedGatewayImplementations, +} from "../../../main/typescript/core/types"; +import { createClient } from "../test-utils"; + +const logLevel: LogLevelDesc = "DEBUG"; +const logger = LoggerProvider.getOrCreate({ + level: logLevel, + label: "satp-gateway-orchestrator-init-test", +}); +const factoryOptions: IPluginFactoryOptions = { + pluginImportType: PluginImportType.Local, +}; +const factory = new PluginFactorySATPGateway(factoryOptions); + +beforeAll(async () => { + pruneDockerAllIfGithubAction({ logLevel }) + .then(() => { + logger.info("Pruning throw OK"); + }) + .catch(async () => { + await Containers.logDiagnostics({ logLevel }); + fail("Pruning didn't throw OK"); + }); +}); + +// TODO create unit tests of the services to test that GetStatus functionality works (access via BLODispatcher) +describe("GetStatus Endpoint and Functionality testing", () => { + test("GetStatus endpoint works - SDK call", async () => { + const options: SATPGatewayConfig = { + logLevel: logLevel, + gid: { + id: "mockID", + name: "CustomGateway", + version: [ + { + Core: "v1", + Architecture: "v1", + Crash: "v1", + }, + ], + supportedChains: [ + SupportedGatewayImplementations.FABRIC, + SupportedGatewayImplementations.BESU, + ], + proofID: "mockProofID10", + gatewayServerPort: 3010, + gatewayClientPort: 3011, + address: "http://localhost", + }, + }; + + const gateway = await factory.create(options); + + try { + await gateway.startup(); + const address = options.gid!.address!; + const port = options.gid!.gatewayClientPort!; + //const apiType = "AdminApi"; + + const adminApiClient = createClient("AdminApi", address, port, logger); + + const statusRequest = { + sessionID: "test-session-id", + }; + + const response = await adminApiClient.getStatus(statusRequest.sessionID); + + // expect(response.status).toBe(200); + expect(response).toBeDefined(); + expect(response.status).toBeDefined(); + expect(response.status).toBe(200); + expect(response.data).toBeDefined(); + } catch (error) { + logger.error(`Error: ${error}`); + throw new Error(`Unexpected error during API call`); + } finally { + await gateway.shutdown(); + } + }); + + // TODO create integration tests of the services to test that GetStatus functionality works + test("GetStatus functionality works", async () => {}); +}); + +afterAll(async () => { + await pruneDockerAllIfGithubAction({ logLevel }) + .then(() => { + logger.info("Pruning throw OK"); + }) + .catch(async () => { + await Containers.logDiagnostics({ logLevel }); + fail("Pruning didn't throw OK"); + }); +}); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-init.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-init.test.ts new file mode 100644 index 0000000000..1f4d195a8e --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/refactor-gateway-init.test.ts @@ -0,0 +1,217 @@ +import "jest-extended"; +import { + Containers, + pruneDockerAllIfGithubAction, +} from "@hyperledger/cactus-test-tooling"; +import { LogLevelDesc, LoggerProvider } from "@hyperledger/cactus-common"; +// import coordinator factory, coordinator and coordinator options +import { + SATPGateway, + SATPGatewayConfig, +} from "../../../main/typescript/gateway-refactor"; +import { PluginFactorySATPGateway } from "../../../main/typescript/factory/plugin-factory-gateway-orchestrator"; +import { + IPluginFactoryOptions, + PluginImportType, +} from "@hyperledger/cactus-core-api"; +import { + ShutdownHook, + SupportedGatewayImplementations, +} from "./../../../main/typescript/core/types"; + +const logLevel: LogLevelDesc = "INFO"; +const logger = LoggerProvider.getOrCreate({ + level: "INFO", + label: "satp-gateway-orchestrator-init-test", +}); +const factoryOptions: IPluginFactoryOptions = { + pluginImportType: PluginImportType.Local, +}; +const factory = new PluginFactorySATPGateway(factoryOptions); + +beforeAll(async () => { + pruneDockerAllIfGithubAction({ logLevel }) + .then(() => { + logger.info("Pruning throw OK"); + }) + .catch(async () => { + await Containers.logDiagnostics({ logLevel }); + fail("Pruning didn't throw OK"); + }); +}); + +describe("SATPGateway initialization", () => { + it("should initiate gateway with default config", async () => { + const options: SATPGatewayConfig = {}; + const gateway = await factory.create(options); + + expect(gateway).toBeInstanceOf(SATPGateway); + + const identity = gateway.Identity; + expect(identity).toBeDefined(); + expect(identity.id).toBeDefined(); + expect(identity.name).toBeDefined(); + expect(identity.version).toEqual([ + { + Core: "v02", + Architecture: "v02", + Crash: "v02", + }, + ]); + expect(identity.supportedChains).toEqual([ + SupportedGatewayImplementations.FABRIC, + SupportedGatewayImplementations.BESU, + ]); + expect(identity.proofID).toBe("mockProofID1"); + expect(identity.gatewayServerPort).toBe(3010); + expect(identity.address).toBe("http://localhost"); + }); + + it("should initiate gateway with custom config", async () => { + const options: SATPGatewayConfig = { + logLevel: "INFO", + gid: { + id: "mockID", + name: "CustomGateway", + version: [ + { + Core: "v1", + Architecture: "v1", + Crash: "v1", + }, + ], + supportedChains: [ + SupportedGatewayImplementations.FABRIC, + SupportedGatewayImplementations.BESU, + ], + proofID: "mockProofID10", + gatewayServerPort: 3010, + address: "https://localhost", + }, + }; + const gateway = await factory.create(options); + + expect(gateway).toBeInstanceOf(SATPGateway); + + const identity = gateway.Identity; + expect(identity).toBeDefined(); + expect(identity.id).toBeDefined(); + expect(identity.name).toBeDefined(); + expect(identity.version).toEqual([ + { + Core: "v1", + Architecture: "v1", + Crash: "v1", + }, + ]); + expect(identity.supportedChains).toEqual([ + SupportedGatewayImplementations.FABRIC, + SupportedGatewayImplementations.BESU, + ]); + expect(identity.proofID).toBe("mockProofID10"); + expect(identity.gatewayServerPort).toBe(3010); + expect(identity.address).toBe("https://localhost"); + }); + + it("should launch gateway server", async () => { + const options: SATPGatewayConfig = { + logLevel: "INFO", + gid: { + id: "mockID", + name: "CustomGateway", + version: [ + { + Core: "v02", + Architecture: "v02", + Crash: "v02", + }, + ], + supportedChains: [ + SupportedGatewayImplementations.FABRIC, + SupportedGatewayImplementations.BESU, + ], + proofID: "mockProofID10", + address: "https://localhost", + }, + }; + const gateway = await factory.create(options); + expect(gateway).toBeInstanceOf(SATPGateway); + + const identity = gateway.Identity; + // default servers + expect(identity.gatewayServerPort).toBe(3010); + expect(identity.gatewayClientPort).toBe(3011); + expect(identity.address).toBe("https://localhost"); + await gateway.startup(); + await gateway.shutdown(); + }); + + it("shutdown hooks work", async () => { + const options: SATPGatewayConfig = { + gid: { + id: "mockID", + name: "CustomGateway", + version: [ + { + Core: "v02", + Architecture: "v02", + Crash: "v02", + }, + ], + supportedChains: [ + SupportedGatewayImplementations.FABRIC, + SupportedGatewayImplementations.BESU, + ], + proofID: "mockProofID10", + gatewayServerPort: 3014, + gatewayClientPort: 3015, + address: "https://localhost", + }, + }; + + const gateway = await factory.create(options); + expect(gateway).toBeInstanceOf(SATPGateway); + + // ensure logger is called with "mockHook" + const loggerSpy = jest.spyOn(logger, "info"); + + // ensure mockHookFn is called on shutdown + const mockHookFn = jest.fn(async () => { + logger.info("mockHook"); + }); + + const shutdownHook: ShutdownHook = { + name: "mockHook", + hook: async () => { + logger.info("mockHook"); + }, + }; + + const shutdownHookFn: ShutdownHook = { + name: "mockHookFn", + hook: mockHookFn, + }; + + gateway.onShutdown(shutdownHook); + gateway.onShutdown(shutdownHookFn); + await gateway.startup(); + await gateway.shutdown(); + + expect(loggerSpy).toHaveBeenCalledWith("mockHook"); + expect(mockHookFn).toHaveBeenCalled(); + + // for now, technically not needed. However if we use more tests with loggerSpy, conflicts could arise. This is a reminder to restore the spy after each test + loggerSpy.mockRestore(); + }); +}); + +afterAll(async () => { + await pruneDockerAllIfGithubAction({ logLevel }) + .then(() => { + logger.info("Pruning throw OK"); + }) + .catch(async () => { + await Containers.logDiagnostics({ logLevel }); + fail("Pruning didn't throw OK"); + }); +}); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/server-crash-after-transfer-initiation.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/server-crash-after-transfer-initiation.test.ts index ad3fd42083..115450c1d4 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/server-crash-after-transfer-initiation.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/integration/server-crash-after-transfer-initiation.test.ts @@ -29,7 +29,10 @@ import { ClientGatewayHelper } from "../../../main/typescript/core/client-helper import { ServerGatewayHelper } from "../../../main/typescript/core/server-helper"; import { knexClientConnection, knexRemoteConnection } from "../knex.config"; -import { pruneDockerAllIfGithubAction, Containers } from "@hyperledger/cactus-test-tooling"; +import { + pruneDockerAllIfGithubAction, + Containers, +} from "@hyperledger/cactus-test-tooling"; const logLevel: LogLevelDesc = "INFO"; @@ -72,7 +75,7 @@ beforeAll(async () => { await Containers.logDiagnostics({ logLevel }); fail("Pruning didn't throw OK"); }); - + { // Server Gateway configuration serverGatewayPluginOptions = { @@ -103,8 +106,12 @@ beforeAll(async () => { pluginRecipientGateway = new BesuSATPGateway(serverGatewayPluginOptions); - expect(pluginRecipientGateway.localRepository?.database).not.toBeUndefined(); - expect(pluginRecipientGateway.remoteRepository?.database).not.toBeUndefined(); + expect( + pluginRecipientGateway.localRepository?.database, + ).not.toBeUndefined(); + expect( + pluginRecipientGateway.remoteRepository?.database, + ).not.toBeUndefined(); await pluginRecipientGateway.localRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); @@ -143,7 +150,7 @@ beforeAll(async () => { pluginSourceGateway = new FabricSATPGateway(clientGatewayPluginOptions); expect(pluginSourceGateway.localRepository?.database).not.toBeUndefined(); - expect(pluginSourceGateway.remoteRepository?.database).not.toBeUndefined(); + expect(pluginSourceGateway.remoteRepository?.database).not.toBeUndefined(); await pluginSourceGateway.localRepository?.reset(); await pluginSourceGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/knex.config.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/knex.config.ts index c533074692..c32d533a4b 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/knex.config.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/knex.config.ts @@ -3,7 +3,10 @@ import { v4 as uuidv4 } from "uuid"; export const knexClientConnection = { client: "sqlite3", connection: { - filename: "./packages/cactus-plugin-satp-hermes/src/knex/.dev.client-" + uuidv4() + ".sqlite3", + filename: + "./packages/cactus-plugin-satp-hermes/src/knex/.dev.client-" + + uuidv4() + + ".sqlite3", }, migrations: { directory: "./packages/cactus-plugin-satp-hermes/src/knex/migrations", @@ -14,7 +17,10 @@ export const knexClientConnection = { export const knexServerConnection = { client: "sqlite3", connection: { - filename: "./packages/cactus-plugin-satp-hermes/src/knex/.dev.server-" + uuidv4() + ".sqlite3", + filename: + "./packages/cactus-plugin-satp-hermes/src/knex/.dev.server-" + + uuidv4() + + ".sqlite3", }, migrations: { directory: "./packages/cactus-plugin-satp-hermes/src/knex/migrations", @@ -25,7 +31,10 @@ export const knexServerConnection = { export const knexRemoteConnection = { client: "sqlite3", connection: { - filename: "./packages/cactus-plugin-satp-hermes/src/knex/.dev.remote-" + uuidv4() + ".sqlite3", + filename: + "./packages/cactus-plugin-satp-hermes/src/knex/.dev.remote-" + + uuidv4() + + ".sqlite3", }, migrations: { directory: "./packages/cactus-plugin-satp-hermes/src/knex/migrations", diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/test-utils.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/test-utils.ts new file mode 100644 index 0000000000..8293a6586c --- /dev/null +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/test-utils.ts @@ -0,0 +1,38 @@ +import { Logger } from "@hyperledger/cactus-common"; +import { + Configuration, + AdminApi, + TransactionApi, +} from "../../main/typescript/generated/openapi-blo/typescript-axios"; +//import { Api } from "@bufbuild/protobuf"; + +export function createClient( + type: "AdminApi", + address: string, + port: number, + logger: Logger, +): AdminApi; +export function createClient( + type: "TransactionApi", + address: string, + port: number, + logger: Logger, +): TransactionApi; + +export function createClient( + type: "AdminApi" | "TransactionApi", + address: string, + port: number, + logger: Logger, +): AdminApi | TransactionApi { + const config = new Configuration({ basePath: `${address}:${port}` }); + logger.debug(config); + + if (type === "AdminApi") { + return new AdminApi(config); + } else if (type === "TransactionApi") { + return new TransactionApi(config); + } else { + throw new Error("Invalid api type"); + } +} diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-final.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-final.test.ts index 9a5c2a23b7..fc1d1c341b 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-final.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-final.test.ts @@ -59,7 +59,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-preparation.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-preparation.test.ts index 737549ed05..69fdd146ef 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-preparation.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/commit-preparation.test.ts @@ -56,7 +56,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/lock-evidence.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/lock-evidence.test.ts index ac3aa68730..691229511a 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/lock-evidence.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/lock-evidence.test.ts @@ -55,7 +55,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-commence.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-commence.test.ts index 81da65aef6..6bcc36048f 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-commence.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-commence.test.ts @@ -55,7 +55,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-initialization.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-initialization.test.ts index ca998bc95d..acfee70fe6 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-initialization.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/client/transfer-initialization.test.ts @@ -56,7 +56,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/logging.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/logging.test.ts index a867986cee..3e8af87d5f 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/logging.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/logging.test.ts @@ -94,7 +94,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); await pluginSourceGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-success.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-success.test.ts index a3e80345d0..63906805fe 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-success.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-success.test.ts @@ -65,7 +65,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update-ack.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update-ack.test.ts index 83154dcc84..52ad598046 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update-ack.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update-ack.test.ts @@ -58,7 +58,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update.test.ts index f56b917a08..fc702e75a9 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover-update.test.ts @@ -70,7 +70,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover.test.ts index f516efd817..66a248cfe6 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/recovery/recover.test.ts @@ -76,7 +76,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); }); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-final.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-final.test.ts index fff1bf0a3a..f93dd989c8 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-final.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-final.test.ts @@ -60,7 +60,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-preparation.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-preparation.test.ts index 127ce29f9c..6df59514e9 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-preparation.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/commit-preparation.test.ts @@ -51,7 +51,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/lock-evidence.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/lock-evidence.test.ts index 6c0552d18c..d5ba51bda4 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/lock-evidence.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/lock-evidence.test.ts @@ -58,10 +58,10 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); - + dummyTransferCommenceResponseMessageHash = SHA256( "transferCommenceResponseMessageData", ).toString(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-commence.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-commence.test.ts index e23bd5b7a9..d792f45ab5 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-commence.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-commence.test.ts @@ -55,7 +55,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-complete.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-complete.test.ts index a2ad3a7cc1..df206cffd4 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-complete.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-complete.test.ts @@ -52,7 +52,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-initialization.test.ts b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-initialization.test.ts index b8d3d5a26b..0ed8286bde 100644 --- a/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-initialization.test.ts +++ b/packages/cactus-plugin-satp-hermes/src/test/typescript/unit/server/transfer-initialization.test.ts @@ -52,7 +52,7 @@ beforeEach(async () => { await pluginSourceGateway.localRepository?.reset(); await pluginRecipientGateway.localRepository?.reset(); - + await pluginSourceGateway.remoteRepository?.reset(); await pluginRecipientGateway.remoteRepository?.reset(); diff --git a/yarn.lock b/yarn.lock index fcd43ce60a..fd07432fa8 100644 --- a/yarn.lock +++ b/yarn.lock @@ -812,6 +812,17 @@ __metadata: languageName: node linkType: hard +"@apidevtools/json-schema-ref-parser@npm:9.0.6": + version: 9.0.6 + resolution: "@apidevtools/json-schema-ref-parser@npm:9.0.6" + dependencies: + "@jsdevtools/ono": "npm:^7.1.3" + call-me-maybe: "npm:^1.0.1" + js-yaml: "npm:^3.13.1" + checksum: 10/bfdff3d3c54fac0e864322dfa62c018cbcf90f66df6cbe33868a0134bee5bc4d013f980aac0f3e83ffabf4b9c13ffedbf5bae3578ce7db7d4cb559e874b16950 + languageName: node + linkType: hard + "@apidevtools/json-schema-ref-parser@npm:^11.6.2": version: 11.6.4 resolution: "@apidevtools/json-schema-ref-parser@npm:11.6.4" @@ -823,15 +834,48 @@ __metadata: languageName: node linkType: hard -"@apidevtools/json-schema-ref-parser@npm:^9.1.2": - version: 9.1.2 - resolution: "@apidevtools/json-schema-ref-parser@npm:9.1.2" +"@apidevtools/openapi-schemas@npm:^2.1.0": + version: 2.1.0 + resolution: "@apidevtools/openapi-schemas@npm:2.1.0" + checksum: 10/4ca78f79ee2e5a162d16d140f939ca90d51265014ea2e500955286ad3acd11b75db4179b7b4bae245b09a981baeb8d80b81bc24c61d6c471a4a4707ed277ebf2 + languageName: node + linkType: hard + +"@apidevtools/swagger-cli@npm:4.0.4": + version: 4.0.4 + resolution: "@apidevtools/swagger-cli@npm:4.0.4" dependencies: + "@apidevtools/swagger-parser": "npm:^10.0.1" + chalk: "npm:^4.1.0" + js-yaml: "npm:^3.14.0" + yargs: "npm:^15.4.1" + bin: + swagger-cli: bin/swagger-cli.js + checksum: 10/7dd8cfd996a445052ba7d316ffa7b46343a9d463b7342e1511ddd5f547f34a6135a6a0dfb94d0bab6b0d561eb6c7795131acc61c7d058046b5f47d1431ab4677 + languageName: node + linkType: hard + +"@apidevtools/swagger-methods@npm:^3.0.2": + version: 3.0.2 + resolution: "@apidevtools/swagger-methods@npm:3.0.2" + checksum: 10/d06b1ac5c1956613c4c6be695612ef860cd4e962b93a509ca551735a328a856cae1e33399cac1dcbf8333ba22b231746f3586074769ef0e172cf549ec9e7eaae + languageName: node + linkType: hard + +"@apidevtools/swagger-parser@npm:^10.0.1": + version: 10.1.0 + resolution: "@apidevtools/swagger-parser@npm:10.1.0" + dependencies: + "@apidevtools/json-schema-ref-parser": "npm:9.0.6" + "@apidevtools/openapi-schemas": "npm:^2.1.0" + "@apidevtools/swagger-methods": "npm:^3.0.2" "@jsdevtools/ono": "npm:^7.1.3" - "@types/json-schema": "npm:^7.0.6" + ajv: "npm:^8.6.3" + ajv-draft-04: "npm:^1.0.0" call-me-maybe: "npm:^1.0.1" - js-yaml: "npm:^4.1.0" - checksum: 10/7553f994974c5c6f99d14b9f47e9dccaedbcdd1565a099bbf7413494c71e1a246562bd6bfa394b6be026d176c734ff89aed87e2c3a92d01ff4350c64514bfb48 + peerDependencies: + openapi-types: ">=7" + checksum: 10/24f7f6524334887ff3ef1c8c768698963f4a03e6824719fdbe98ba5444c9f1cdca9a11789e90362c882321dedec3e66f414e05035054084921fe1d2527724adb languageName: node linkType: hard @@ -5914,20 +5958,13 @@ __metadata: languageName: node linkType: hard -"@bufbuild/protobuf@npm:1.10.0, @bufbuild/protobuf@npm:^1.6.0": +"@bufbuild/protobuf@npm:1.10.0": version: 1.10.0 resolution: "@bufbuild/protobuf@npm:1.10.0" checksum: 10/1f120f72bbb40dd3d0f8c73f1474b001cfb9be09c38b7b0292e35fec98c5184a3db380a6feff7626fb3fff108c8a8aa7fc8cfea14904dc0a1174a01c8e637cc6 languageName: node linkType: hard -"@bufbuild/protobuf@npm:1.7.2": - version: 1.7.2 - resolution: "@bufbuild/protobuf@npm:1.7.2" - checksum: 10/f23ccc77066100157043cf36bd2506acdcb235f0a902f7662fbbb992e78df4202780aeb55bd2e3fd1945bd9e52a4fca759351f333f2ff779e32996e13eb56d34 - languageName: node - linkType: hard - "@bufbuild/protobuf@npm:1.8.0, @bufbuild/protobuf@npm:^1.7.2, @bufbuild/protobuf@npm:^1.8.0": version: 1.8.0 resolution: "@bufbuild/protobuf@npm:1.8.0" @@ -5935,23 +5972,6 @@ __metadata: languageName: node linkType: hard -"@bufbuild/protoc-gen-es@npm:1.7.2": - version: 1.7.2 - resolution: "@bufbuild/protoc-gen-es@npm:1.7.2" - dependencies: - "@bufbuild/protobuf": "npm:^1.7.2" - "@bufbuild/protoplugin": "npm:1.7.2" - peerDependencies: - "@bufbuild/protobuf": 1.7.2 - peerDependenciesMeta: - "@bufbuild/protobuf": - optional: true - bin: - protoc-gen-es: bin/protoc-gen-es - checksum: 10/21898291c7239a61b7aa2fdbde7c2b40161d4e395783081bb9650840381764984075f405cd46e2f189df5b57d602a37796ae804b648338cf82a4ffecbef0de52 - languageName: node - linkType: hard - "@bufbuild/protoc-gen-es@npm:1.8.0": version: 1.8.0 resolution: "@bufbuild/protoc-gen-es@npm:1.8.0" @@ -5969,17 +5989,6 @@ __metadata: languageName: node linkType: hard -"@bufbuild/protoplugin@npm:1.7.2": - version: 1.7.2 - resolution: "@bufbuild/protoplugin@npm:1.7.2" - dependencies: - "@bufbuild/protobuf": "npm:1.7.2" - "@typescript/vfs": "npm:^1.4.0" - typescript: "npm:4.5.2" - checksum: 10/412c35a04a60fed1979b62fedc570c128efa8995290005df8d84bbf84a9b35cc6a9bbea5646210ed7708fb8cd274aea8ba30720ccd25eb62c9133efda55ca733 - languageName: node - linkType: hard - "@bufbuild/protoplugin@npm:1.8.0, @bufbuild/protoplugin@npm:^1.7.2": version: 1.8.0 resolution: "@bufbuild/protoplugin@npm:1.8.0" @@ -5991,17 +6000,6 @@ __metadata: languageName: node linkType: hard -"@bufbuild/protoplugin@npm:^1.6.0": - version: 1.10.0 - resolution: "@bufbuild/protoplugin@npm:1.10.0" - dependencies: - "@bufbuild/protobuf": "npm:1.10.0" - "@typescript/vfs": "npm:^1.4.0" - typescript: "npm:4.5.2" - checksum: 10/829a6d64076a16d7a89e732be39f1988b52b8babee215d91a5f692e0e6ac3e2b58ea4012bd7707c3cef4b6952cfcc36076b646aa09ed68888aedb2fb004d659f - languageName: node - linkType: hard - "@chainsafe/as-sha256@npm:^0.3.1": version: 0.3.1 resolution: "@chainsafe/as-sha256@npm:0.3.1" @@ -6268,19 +6266,6 @@ __metadata: languageName: node linkType: hard -"@connectrpc/connect-express@npm:1.3.0": - version: 1.3.0 - resolution: "@connectrpc/connect-express@npm:1.3.0" - dependencies: - "@types/express": "npm:^4.17.18" - peerDependencies: - "@bufbuild/protobuf": ^1.4.2 - "@connectrpc/connect": 1.3.0 - "@connectrpc/connect-node": 1.3.0 - checksum: 10/581495391477e2b8a2738bdc34dbf45a245d26cb4943a5b3d1813d80ae4f11d85e0d0f01d95e408e7b1cb7812a873218428d6b0cde9fc643747f06e8b7205627 - languageName: node - linkType: hard - "@connectrpc/connect-express@npm:1.4.0": version: 1.4.0 resolution: "@connectrpc/connect-express@npm:1.4.0" @@ -6306,18 +6291,6 @@ __metadata: languageName: node linkType: hard -"@connectrpc/connect-node@npm:1.3.0": - version: 1.3.0 - resolution: "@connectrpc/connect-node@npm:1.3.0" - dependencies: - undici: "npm:^5.28.2" - peerDependencies: - "@bufbuild/protobuf": ^1.4.2 - "@connectrpc/connect": 1.3.0 - checksum: 10/34b4903220881b39128bc31c79a0a006cb44c7cb9074fd0d77e853ff016f51c2a131811421c971c01210d4329068026c278cf64d349f2eb38126d0604710816a - languageName: node - linkType: hard - "@connectrpc/connect-node@npm:1.4.0": version: 1.4.0 resolution: "@connectrpc/connect-node@npm:1.4.0" @@ -6340,15 +6313,6 @@ __metadata: languageName: node linkType: hard -"@connectrpc/connect@npm:1.3.0": - version: 1.3.0 - resolution: "@connectrpc/connect@npm:1.3.0" - peerDependencies: - "@bufbuild/protobuf": ^1.4.2 - checksum: 10/7707d97ee6e4a83cc03371b1da1709c103f0338e85b2fbf49813053d96114818d34831b1c11715cc9badcc3ce5d4c9fbc423af4b6a8efa953bf0ef76cdc6e50d - languageName: node - linkType: hard - "@connectrpc/connect@npm:1.4.0": version: 1.4.0 resolution: "@connectrpc/connect@npm:1.4.0" @@ -6358,26 +6322,6 @@ __metadata: languageName: node linkType: hard -"@connectrpc/protoc-gen-connect-es@npm:1.3.0": - version: 1.3.0 - resolution: "@connectrpc/protoc-gen-connect-es@npm:1.3.0" - dependencies: - "@bufbuild/protobuf": "npm:^1.6.0" - "@bufbuild/protoplugin": "npm:^1.6.0" - peerDependencies: - "@bufbuild/protoc-gen-es": ^1.6.0 - "@connectrpc/connect": 1.3.0 - peerDependenciesMeta: - "@bufbuild/protoc-gen-es": - optional: true - "@connectrpc/connect": - optional: true - bin: - protoc-gen-connect-es: bin/protoc-gen-connect-es - checksum: 10/23a17bef378ac2fa414fb35fe50a7630134946a086f75f9201c5d0c3631f32e61445628b0420eac7353e88193e170059969bc83bad96a9f43cb98db30243aa1c - languageName: node - linkType: hard - "@connectrpc/protoc-gen-connect-es@npm:1.4.0": version: 1.4.0 resolution: "@connectrpc/protoc-gen-connect-es@npm:1.4.0" @@ -9109,21 +9053,6 @@ __metadata: languageName: node linkType: hard -"@grpc/proto-loader@npm:0.7.8": - version: 0.7.8 - resolution: "@grpc/proto-loader@npm:0.7.8" - dependencies: - "@types/long": "npm:^4.0.1" - lodash.camelcase: "npm:^4.3.0" - long: "npm:^4.0.0" - protobufjs: "npm:^7.2.4" - yargs: "npm:^17.7.2" - bin: - proto-loader-gen-types: build/bin/proto-loader-gen-types.js - checksum: 10/a7dde023f8209e7a97eecad5f627c31b796c663e0bf4a3bc81b848a8bdf0c2ba5de712189e4b6f759a2a766599b2a0ea197cdd4a45ab9d091329ca9ffb053bb8 - languageName: node - linkType: hard - "@grpc/proto-loader@npm:^0.7.0": version: 0.7.7 resolution: "@grpc/proto-loader@npm:0.7.7" @@ -11062,6 +10991,7 @@ __metadata: secp256k1: "npm:4.0.3" socket.io: "npm:4.6.2" sqlite3: "npm:5.1.5" + swagger-cli: "npm:^4.0.4" swagger-ui-express: "npm:5.0.0" typescript: "npm:5.5.2" typescript-optional: "npm:2.0.1" @@ -15035,6 +14965,18 @@ __metadata: languageName: node linkType: hard +"@quobix/vacuum@npm:^0.9.10": + version: 0.9.16 + resolution: "@quobix/vacuum@npm:0.9.16" + dependencies: + node-fetch: "npm:^3.2.10" + tar: "npm:^6.1.11" + bin: + vacuum: bin/vacuum.js + checksum: 10/0e9d717f8c8c2accf39e333d12e101e543229c41b9b3c8e7717e6b00de24e792392437dcb40700113033686b542643c10ebb25b4389b059a4a461af0b4e9aa44 + languageName: node + linkType: hard + "@redocly/ajv@npm:^8.11.0": version: 8.11.0 resolution: "@redocly/ajv@npm:8.11.0" @@ -17529,7 +17471,7 @@ __metadata: languageName: node linkType: hard -"@types/json-schema@npm:^7.0.15, @types/json-schema@npm:^7.0.6": +"@types/json-schema@npm:^7.0.15": version: 7.0.15 resolution: "@types/json-schema@npm:7.0.15" checksum: 10/1a3c3e06236e4c4aab89499c428d585527ce50c24fe8259e8b3926d3df4cfbbbcf306cfc73ddfb66cbafc973116efd15967020b0f738f63e09e64c7d260519e7 @@ -17752,15 +17694,6 @@ __metadata: languageName: node linkType: hard -"@types/multer@npm:^1.4.7": - version: 1.4.12 - resolution: "@types/multer@npm:1.4.12" - dependencies: - "@types/express": "npm:*" - checksum: 10/3d2b32da58ddd67f972d4ef1021492f78d65f33f936b6fb25dd461bb6cc7b03bfd1de1a11562c4310680dac8054e4398038db51767a0ffbf1fe62457b3706e95 - languageName: node - linkType: hard - "@types/node-fetch@npm:2.6.2": version: 2.6.2 resolution: "@types/node-fetch@npm:2.6.2" @@ -19856,7 +19789,7 @@ __metadata: languageName: node linkType: hard -"ajv@npm:8.17.1, ajv@npm:^8.10.0, ajv@npm:^8.11.2, ajv@npm:^8.14.0": +"ajv@npm:8.17.1, ajv@npm:^8.10.0, ajv@npm:^8.14.0": version: 8.17.1 resolution: "ajv@npm:8.17.1" dependencies: @@ -29546,28 +29479,6 @@ __metadata: languageName: node linkType: hard -"express-openapi-validator@npm:5.0.4": - version: 5.0.4 - resolution: "express-openapi-validator@npm:5.0.4" - dependencies: - "@apidevtools/json-schema-ref-parser": "npm:^9.1.2" - "@types/multer": "npm:^1.4.7" - ajv: "npm:^8.11.2" - ajv-draft-04: "npm:^1.0.0" - ajv-formats: "npm:^2.1.1" - content-type: "npm:^1.0.5" - lodash.clonedeep: "npm:^4.5.0" - lodash.get: "npm:^4.4.2" - lodash.uniq: "npm:^4.5.0" - lodash.zipobject: "npm:^4.1.3" - media-typer: "npm:^1.1.0" - multer: "npm:^1.4.5-lts.1" - ono: "npm:^7.1.3" - path-to-regexp: "npm:^6.2.0" - checksum: 10/793f3bcd369f4f67a228c4965834cd649e891ca1aae7b13795d6569399d02c6638df96428d4c320e3d61146e78627a6b012b1461bdb9a69ea1c1b0ce4a1401dc - languageName: node - linkType: hard - "express-openapi-validator@npm:5.2.0": version: 5.2.0 resolution: "express-openapi-validator@npm:5.2.0" @@ -30170,30 +30081,6 @@ __metadata: languageName: node linkType: hard -"fastify@npm:4.26.2": - version: 4.26.2 - resolution: "fastify@npm:4.26.2" - dependencies: - "@fastify/ajv-compiler": "npm:^3.5.0" - "@fastify/error": "npm:^3.4.0" - "@fastify/fast-json-stringify-compiler": "npm:^4.3.0" - abstract-logging: "npm:^2.0.1" - avvio: "npm:^8.3.0" - fast-content-type-parse: "npm:^1.1.0" - fast-json-stringify: "npm:^5.8.0" - find-my-way: "npm:^8.0.0" - light-my-request: "npm:^5.11.0" - pino: "npm:^8.17.0" - process-warning: "npm:^3.0.0" - proxy-addr: "npm:^2.0.7" - rfdc: "npm:^1.3.0" - secure-json-parse: "npm:^2.7.0" - semver: "npm:^7.5.4" - toad-cache: "npm:^3.3.0" - checksum: 10/24ee6b1496bf0c3b6b266edef6654c547ea54ffe3a17a98afd0f2a8e7a69e0fea2b58eaebb81388fa36d20032e239e656fbfdfac539b4758483a438250f791ff - languageName: node - linkType: hard - "fastify@npm:4.28.1": version: 4.28.1 resolution: "fastify@npm:4.28.1" @@ -32239,20 +32126,6 @@ __metadata: languageName: node linkType: hard -"google-protobuf@npm:3.18.0-rc.2": - version: 3.18.0-rc.2 - resolution: "google-protobuf@npm:3.18.0-rc.2" - checksum: 10/71cc1d20fd52bba970a3485165f78cb453725ef5f4c1146e9a8c23d2850072867ad29e58ebf25da3f2a990f129f7b5d23f4aeea0476e827c4bf61d1cecc922cc - languageName: node - linkType: hard - -"google-protobuf@npm:3.21.2": - version: 3.21.2 - resolution: "google-protobuf@npm:3.21.2" - checksum: 10/b376c2e47fb0419b41b901e4da8f3827fe9594ffb7887708b9c241f36005d0b9f2edc7b3f05795f6793924a241e767f67831732eae0f23bdbb337b56a6ab4e26 - languageName: node - linkType: hard - "google-protobuf@npm:3.21.4": version: 3.21.4 resolution: "google-protobuf@npm:3.21.4" @@ -36785,7 +36658,7 @@ __metadata: languageName: node linkType: hard -"js-yaml@npm:3.14.1, js-yaml@npm:^3.13.1, js-yaml@npm:^3.14.1, js-yaml@npm:^3.5.1, js-yaml@npm:^3.9.1": +"js-yaml@npm:3.14.1, js-yaml@npm:^3.13.1, js-yaml@npm:^3.14.0, js-yaml@npm:^3.14.1, js-yaml@npm:^3.5.1, js-yaml@npm:^3.9.1": version: 3.14.1 resolution: "js-yaml@npm:3.14.1" dependencies: @@ -38683,13 +38556,6 @@ __metadata: languageName: node linkType: hard -"lodash.zipobject@npm:^4.1.3": - version: 4.1.3 - resolution: "lodash.zipobject@npm:4.1.3" - checksum: 10/1ab635b665c0488a905779705a6683e9024115176e9e947d75d2a6b1e8673230fdb11c417788fbaf26d71e1cac5ad8e59a558924612cbf7d6615780836048883 - languageName: node - linkType: hard - "lodash@npm:>=4.17.21": version: 4.17.21 resolution: "lodash@npm:4.17.21" @@ -41083,7 +40949,7 @@ __metadata: languageName: node linkType: hard -"node-fetch@npm:^3.3.2": +"node-fetch@npm:^3.2.10, node-fetch@npm:^3.3.2": version: 3.3.2 resolution: "node-fetch@npm:3.3.2" dependencies: @@ -43541,13 +43407,6 @@ __metadata: languageName: node linkType: hard -"path-to-regexp@npm:^6.2.0": - version: 6.3.0 - resolution: "path-to-regexp@npm:6.3.0" - checksum: 10/6822f686f01556d99538b350722ef761541ec0ce95ca40ce4c29e20a5b492fe8361961f57993c71b2418de12e604478dcf7c430de34b2c31a688363a7a944d9c - languageName: node - linkType: hard - "path-to-regexp@npm:^6.2.2": version: 6.2.2 resolution: "path-to-regexp@npm:6.2.2" @@ -43802,13 +43661,6 @@ __metadata: languageName: node linkType: hard -"pino-std-serializers@npm:^6.0.0": - version: 6.2.2 - resolution: "pino-std-serializers@npm:6.2.2" - checksum: 10/a00cdff4e1fbc206da9bed047e6dc400b065f43e8b4cef1635b0192feab0e8f932cdeb0faaa38a5d93d2e777ba4cda939c2ed4c1a70f6839ff25f9aef97c27ff - languageName: node - linkType: hard - "pino-std-serializers@npm:^7.0.0": version: 7.0.0 resolution: "pino-std-serializers@npm:7.0.0" @@ -43816,27 +43668,6 @@ __metadata: languageName: node linkType: hard -"pino@npm:^8.17.0": - version: 8.21.0 - resolution: "pino@npm:8.21.0" - dependencies: - atomic-sleep: "npm:^1.0.0" - fast-redact: "npm:^3.1.1" - on-exit-leak-free: "npm:^2.1.0" - pino-abstract-transport: "npm:^1.2.0" - pino-std-serializers: "npm:^6.0.0" - process-warning: "npm:^3.0.0" - quick-format-unescaped: "npm:^4.0.3" - real-require: "npm:^0.2.0" - safe-stable-stringify: "npm:^2.3.1" - sonic-boom: "npm:^3.7.0" - thread-stream: "npm:^2.6.0" - bin: - pino: bin.js - checksum: 10/5a054eab533ab91b20f63497b86070f0a6b40e4688cde9de66d23e03d6046c4e95d69c3f526dea9f30bcbc5874c7fbf0f91660cded4753946fd02261ca8ac340 - languageName: node - linkType: hard - "pino@npm:^9.0.0": version: 9.4.0 resolution: "pino@npm:9.4.0" @@ -45504,15 +45335,6 @@ __metadata: languageName: node linkType: hard -"prom-client@npm:13.2.0": - version: 13.2.0 - resolution: "prom-client@npm:13.2.0" - dependencies: - tdigest: "npm:^0.1.1" - checksum: 10/46df22a933f35dc60480ef7139c2ea0f315a7f4b3018e9ac045572999a1c2ee92978ef0bfb124c111159718d98d8093de59b81bb3f6fd499f3d0ce576a987703 - languageName: node - linkType: hard - "prom-client@npm:15.1.3": version: 15.1.3 resolution: "prom-client@npm:15.1.3" @@ -49395,15 +49217,6 @@ __metadata: languageName: node linkType: hard -"sonic-boom@npm:^3.7.0": - version: 3.8.1 - resolution: "sonic-boom@npm:3.8.1" - dependencies: - atomic-sleep: "npm:^1.0.0" - checksum: 10/e03c9611e43fa81132cd2ce0fe4eb7fbcf19db267e9dec20dc6c586f82465c9c906e91a02f72150c740463ad9335536ea2131850307aaa6686d1fb5d4cc4be3e - languageName: node - linkType: hard - "sonic-boom@npm:^4.0.1": version: 4.1.0 resolution: "sonic-boom@npm:4.1.0" @@ -50907,6 +50720,17 @@ __metadata: languageName: node linkType: hard +"swagger-cli@npm:^4.0.4": + version: 4.0.4 + resolution: "swagger-cli@npm:4.0.4" + dependencies: + "@apidevtools/swagger-cli": "npm:4.0.4" + bin: + swagger-cli: swagger-cli.js + checksum: 10/2ac9557dd76014d109a6ad47b079fee0aa77f35941481626528e9e4a5d7d2051499381244eccee8521a495fc7d979f834bd69011438239185dcc95ce9f805ee2 + languageName: node + linkType: hard + "swagger-ui-dist@npm:>=5.0.0": version: 5.17.14 resolution: "swagger-ui-dist@npm:5.17.14" @@ -51610,15 +51434,6 @@ __metadata: languageName: node linkType: hard -"thread-stream@npm:^2.6.0": - version: 2.7.0 - resolution: "thread-stream@npm:2.7.0" - dependencies: - real-require: "npm:^0.2.0" - checksum: 10/03e743a2ccb2af5fa695d2e4369113336ee9b9f09c4453d50a222cbb4ae3af321bff658e0e5bf8bfbce9d7f5a7bf6262d12a2a365e160f4e76380ec624d32e7b - languageName: node - linkType: hard - "thread-stream@npm:^3.0.0": version: 3.1.0 resolution: "thread-stream@npm:3.1.0" @@ -52989,7 +52804,7 @@ __metadata: languageName: node linkType: hard -"undici@npm:^5.28.2, undici@npm:^5.28.3": +"undici@npm:^5.28.3": version: 5.28.4 resolution: "undici@npm:5.28.4" dependencies: @@ -53574,15 +53389,6 @@ __metadata: languageName: node linkType: hard -"uuid@npm:9.0.1, uuid@npm:^9.0.0, uuid@npm:^9.0.1": - version: 9.0.1 - resolution: "uuid@npm:9.0.1" - bin: - uuid: dist/bin/uuid - checksum: 10/9d0b6adb72b736e36f2b1b53da0d559125ba3e39d913b6072f6f033e0c87835b414f0836b45bcfaf2bdf698f92297fea1c3cc19b0b258bc182c9c43cc0fab9f2 - languageName: node - linkType: hard - "uuid@npm:^3.3.2, uuid@npm:^3.3.3": version: 3.4.0 resolution: "uuid@npm:3.4.0" @@ -53592,6 +53398,15 @@ __metadata: languageName: node linkType: hard +"uuid@npm:^9.0.0, uuid@npm:^9.0.1": + version: 9.0.1 + resolution: "uuid@npm:9.0.1" + bin: + uuid: dist/bin/uuid + checksum: 10/9d0b6adb72b736e36f2b1b53da0d559125ba3e39d913b6072f6f033e0c87835b414f0836b45bcfaf2bdf698f92297fea1c3cc19b0b258bc182c9c43cc0fab9f2 + languageName: node + linkType: hard + "v8-compile-cache-lib@npm:^3.0.0": version: 3.0.0 resolution: "v8-compile-cache-lib@npm:3.0.0" @@ -57604,7 +57419,7 @@ __metadata: languageName: node linkType: hard -"yargs@npm:^15.0.2, yargs@npm:^15.3.1": +"yargs@npm:^15.0.2, yargs@npm:^15.3.1, yargs@npm:^15.4.1": version: 15.4.1 resolution: "yargs@npm:15.4.1" dependencies: