From 525e000874161dcfa5235063711b89c7b749ba16 Mon Sep 17 00:00:00 2001 From: fireblocks_dx_team Date: Tue, 1 Sep 2026 10:56:41 +0000 Subject: [PATCH] Generated SDK #2809037023 --- .openapi-generator/FILES | 18 + CHANGELOG.md | 239 ------ README.md | 12 +- api/openapi.yaml | 785 +++++++++++++----- build.gradle | 2 +- docs/Contact.md | 42 + docs/ContactApprovalRequest.md | 15 + docs/ContactTag.md | 20 + docs/ContactTagAttachmentPending.md | 24 + docs/ContactsApi.md | 108 +++ docs/ContactsPagedResponse.md | 15 + docs/FailureReason.md | 2 + docs/ScreeningTRLinkMissingTrmDecision.md | 4 +- docs/ScreeningTRLinkMissingTrmRule.md | 4 +- docs/ScreeningTRLinkPostScreeningRule.md | 4 +- docs/SecurityFinding.md | 30 - docs/SecurityFindingDetailed.md | 30 - docs/TRLinkMissingTrmDecision.md | 4 +- docs/TRLinkMissingTrmRule.md | 4 +- docs/TRLinkMissingTrmRule2.md | 4 +- docs/TRLinkPostScreeningRule.md | 4 +- docs/TRLinkPostScreeningRule2.md | 4 +- docs/TransactionRequest.md | 1 + pom.xml | 2 +- .../com/fireblocks/sdk/Configuration.java | 2 +- .../java/com/fireblocks/sdk/Fireblocks.java | 8 + .../com/fireblocks/sdk/api/ContactsApi.java | 274 ++++++ .../com/fireblocks/sdk/model/Contact.java | 653 +++++++++++++++ .../sdk/model/ContactApprovalRequest.java | 194 +++++ .../com/fireblocks/sdk/model/ContactTag.java | 400 +++++++++ .../model/ContactTagAttachmentPending.java | 235 ++++++ .../sdk/model/ContactsPagedResponse.java | 251 ++++++ .../fireblocks/sdk/model/FailureReason.java | 2 + .../ScreeningTRLinkMissingTrmDecision.java | 4 +- .../model/ScreeningTRLinkMissingTrmRule.java | 4 +- .../ScreeningTRLinkPostScreeningRule.java | 4 +- .../fireblocks/sdk/model/SecurityFinding.java | 121 +-- .../sdk/model/SecurityFindingDetailed.java | 122 --- .../sdk/model/TRLinkMissingTrmDecision.java | 4 +- .../sdk/model/TRLinkMissingTrmRule.java | 4 +- .../sdk/model/TRLinkMissingTrmRule2.java | 21 +- .../sdk/model/TRLinkPostScreeningRule.java | 4 +- .../sdk/model/TRLinkPostScreeningRule2.java | 22 +- .../sdk/model/TransactionRequest.java | 44 + .../com/fireblocks/sdk/FireblocksTest.java | 8 + .../fireblocks/sdk/api/ContactsApiTest.java | 70 ++ .../sdk/model/ContactApprovalRequestTest.java | 39 + .../ContactTagAttachmentPendingTest.java | 39 + .../fireblocks/sdk/model/ContactTagTest.java | 69 ++ .../com/fireblocks/sdk/model/ContactTest.java | 93 +++ .../sdk/model/ContactsPagedResponseTest.java | 45 + .../model/SecurityFindingDetailedTest.java | 6 - .../sdk/model/SecurityFindingTest.java | 6 - .../sdk/model/TransactionRequestTest.java | 6 + 54 files changed, 3337 insertions(+), 794 deletions(-) delete mode 100644 CHANGELOG.md create mode 100644 docs/Contact.md create mode 100644 docs/ContactApprovalRequest.md create mode 100644 docs/ContactTag.md create mode 100644 docs/ContactTagAttachmentPending.md create mode 100644 docs/ContactsApi.md create mode 100644 docs/ContactsPagedResponse.md create mode 100644 src/main/java/com/fireblocks/sdk/api/ContactsApi.java create mode 100644 src/main/java/com/fireblocks/sdk/model/Contact.java create mode 100644 src/main/java/com/fireblocks/sdk/model/ContactApprovalRequest.java create mode 100644 src/main/java/com/fireblocks/sdk/model/ContactTag.java create mode 100644 src/main/java/com/fireblocks/sdk/model/ContactTagAttachmentPending.java create mode 100644 src/main/java/com/fireblocks/sdk/model/ContactsPagedResponse.java create mode 100644 src/test/java/com/fireblocks/sdk/api/ContactsApiTest.java create mode 100644 src/test/java/com/fireblocks/sdk/model/ContactApprovalRequestTest.java create mode 100644 src/test/java/com/fireblocks/sdk/model/ContactTagAttachmentPendingTest.java create mode 100644 src/test/java/com/fireblocks/sdk/model/ContactTagTest.java create mode 100644 src/test/java/com/fireblocks/sdk/model/ContactTest.java create mode 100644 src/test/java/com/fireblocks/sdk/model/ContactsPagedResponseTest.java diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 28940eca..178f87c4 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -236,6 +236,12 @@ docs/ConnectedSingleAccount.md docs/ConnectedSingleAccountResponse.md docs/ConsoleUser.md docs/ConsoleUserApi.md +docs/Contact.md +docs/ContactApprovalRequest.md +docs/ContactTag.md +docs/ContactTagAttachmentPending.md +docs/ContactsApi.md +docs/ContactsPagedResponse.md docs/ContractAbiResponseDto.md docs/ContractAbiResponseDtoAbiInner.md docs/ContractAddressResponse.md @@ -1293,6 +1299,7 @@ src/main/java/com/fireblocks/sdk/api/ComplianceApi.java src/main/java/com/fireblocks/sdk/api/ComplianceScreeningConfigurationApi.java src/main/java/com/fireblocks/sdk/api/ConnectedAccountsBetaApi.java src/main/java/com/fireblocks/sdk/api/ConsoleUserApi.java +src/main/java/com/fireblocks/sdk/api/ContactsApi.java src/main/java/com/fireblocks/sdk/api/ContractInteractionsApi.java src/main/java/com/fireblocks/sdk/api/ContractTemplatesApi.java src/main/java/com/fireblocks/sdk/api/ContractsApi.java @@ -1559,6 +1566,11 @@ src/main/java/com/fireblocks/sdk/model/ConnectedAccountsResponse.java src/main/java/com/fireblocks/sdk/model/ConnectedSingleAccount.java src/main/java/com/fireblocks/sdk/model/ConnectedSingleAccountResponse.java src/main/java/com/fireblocks/sdk/model/ConsoleUser.java +src/main/java/com/fireblocks/sdk/model/Contact.java +src/main/java/com/fireblocks/sdk/model/ContactApprovalRequest.java +src/main/java/com/fireblocks/sdk/model/ContactTag.java +src/main/java/com/fireblocks/sdk/model/ContactTagAttachmentPending.java +src/main/java/com/fireblocks/sdk/model/ContactsPagedResponse.java src/main/java/com/fireblocks/sdk/model/ContractAbiResponseDto.java src/main/java/com/fireblocks/sdk/model/ContractAbiResponseDtoAbiInner.java src/main/java/com/fireblocks/sdk/model/ContractAddressResponse.java @@ -2550,6 +2562,7 @@ src/test/java/com/fireblocks/sdk/api/ComplianceApiTest.java src/test/java/com/fireblocks/sdk/api/ComplianceScreeningConfigurationApiTest.java src/test/java/com/fireblocks/sdk/api/ConnectedAccountsBetaApiTest.java src/test/java/com/fireblocks/sdk/api/ConsoleUserApiTest.java +src/test/java/com/fireblocks/sdk/api/ContactsApiTest.java src/test/java/com/fireblocks/sdk/api/ContractInteractionsApiTest.java src/test/java/com/fireblocks/sdk/api/ContractTemplatesApiTest.java src/test/java/com/fireblocks/sdk/api/ContractsApiTest.java @@ -2815,6 +2828,11 @@ src/test/java/com/fireblocks/sdk/model/ConnectedAccountsResponseTest.java src/test/java/com/fireblocks/sdk/model/ConnectedSingleAccountResponseTest.java src/test/java/com/fireblocks/sdk/model/ConnectedSingleAccountTest.java src/test/java/com/fireblocks/sdk/model/ConsoleUserTest.java +src/test/java/com/fireblocks/sdk/model/ContactApprovalRequestTest.java +src/test/java/com/fireblocks/sdk/model/ContactTagAttachmentPendingTest.java +src/test/java/com/fireblocks/sdk/model/ContactTagTest.java +src/test/java/com/fireblocks/sdk/model/ContactTest.java +src/test/java/com/fireblocks/sdk/model/ContactsPagedResponseTest.java src/test/java/com/fireblocks/sdk/model/ContractAbiResponseDtoAbiInnerTest.java src/test/java/com/fireblocks/sdk/model/ContractAbiResponseDtoTest.java src/test/java/com/fireblocks/sdk/model/ContractAddressResponseTest.java diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index 2e141026..00000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,239 +0,0 @@ -# Changelog - -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - -## [v28.0.0](https://github.com/fireblocks/java-sdk/compare/v15.0.0...v28.0.0) - 2026-08-26 - -### Merged - -- Generated SDK #2791732002 [`#152`](https://github.com/fireblocks/java-sdk/pull/152) - -## [v15.0.0](https://github.com/fireblocks/java-sdk/compare/v14.1.0...v15.0.0) - 2026-03-15 - -### Merged - -- Generated SDK #3733 (major) [`#128`](https://github.com/fireblocks/java-sdk/pull/128) - -## [v14.1.0](https://github.com/fireblocks/java-sdk/compare/v14.0.0...v14.1.0) - 2026-02-26 - -### Merged - -- Generated SDK #2167 [`#126`](https://github.com/fireblocks/java-sdk/pull/126) - -## [v14.0.0](https://github.com/fireblocks/java-sdk/compare/v13.0.0...v14.0.0) - 2026-02-03 - -### Merged - -- Generated SDK #4746 [`#121`](https://github.com/fireblocks/java-sdk/pull/121) - -## [v13.0.0](https://github.com/fireblocks/java-sdk/compare/v12.1.3...v13.0.0) - 2025-11-13 - -### Merged - -- Generated SDK #5834 [`#116`](https://github.com/fireblocks/java-sdk/pull/116) - -## [v12.1.3](https://github.com/fireblocks/java-sdk/compare/v12.1.2...v12.1.3) - 2025-10-22 - -### Merged - -- Generated SDK #8293 [`#115`](https://github.com/fireblocks/java-sdk/pull/115) - -## [v12.1.2](https://github.com/fireblocks/java-sdk/compare/v12.1.1...v12.1.2) - 2025-09-29 - -### Merged - -- Generated SDK #6061 [`#113`](https://github.com/fireblocks/java-sdk/pull/113) - -## [v12.1.1](https://github.com/fireblocks/java-sdk/compare/v12.1.0...v12.1.1) - 2025-09-10 - -### Merged - -- Generated SDK #1410 [`#111`](https://github.com/fireblocks/java-sdk/pull/111) - -## [v12.1.0](https://github.com/fireblocks/java-sdk/compare/v12.0.0...v12.1.0) - 2025-09-09 - -### Merged - -- Generated SDK #4521 [`#109`](https://github.com/fireblocks/java-sdk/pull/109) - -## [v12.0.0](https://github.com/fireblocks/java-sdk/compare/v11.2.0...v12.0.0) - 2025-09-01 - -### Merged - -- Generated SDK #7741 [`#108`](https://github.com/fireblocks/java-sdk/pull/108) - -## [v11.2.0](https://github.com/fireblocks/java-sdk/compare/v11.1.0...v11.2.0) - 2025-08-21 - -### Merged - -- Generated SDK #3302 [`#107`](https://github.com/fireblocks/java-sdk/pull/107) - -## [v11.1.0](https://github.com/fireblocks/java-sdk/compare/v11.0.0...v11.1.0) - 2025-08-11 - -### Merged - -- Generated SDK #1782 [`#105`](https://github.com/fireblocks/java-sdk/pull/105) - -## [v11.0.0](https://github.com/fireblocks/java-sdk/compare/v10.4.0...v11.0.0) - 2025-07-15 - -### Merged - -- Generated SDK #5610 [`#103`](https://github.com/fireblocks/java-sdk/pull/103) - -## [v10.4.0](https://github.com/fireblocks/java-sdk/compare/v10.3.0...v10.4.0) - 2025-06-29 - -### Merged - -- Generated SDK #1492 [`#101`](https://github.com/fireblocks/java-sdk/pull/101) - -## [v10.3.0](https://github.com/fireblocks/java-sdk/compare/v10.2.0...v10.3.0) - 2025-06-18 - -### Merged - -- Generated SDK #4009 [`#99`](https://github.com/fireblocks/java-sdk/pull/99) - -## [v10.2.0](https://github.com/fireblocks/java-sdk/compare/v10.1.1...v10.2.0) - 2025-06-04 - -### Merged - -- Generated SDK #8912 [`#98`](https://github.com/fireblocks/java-sdk/pull/98) - -## [v10.1.1](https://github.com/fireblocks/java-sdk/compare/v10.1.0...v10.1.1) - 2025-05-18 - -### Merged - -- Generated SDK #5019 [`#97`](https://github.com/fireblocks/java-sdk/pull/97) - -## [v10.1.0](https://github.com/fireblocks/java-sdk/compare/v10.0.2...v10.1.0) - 2025-05-07 - -### Merged - -- Generated SDK #7076 [`#95`](https://github.com/fireblocks/java-sdk/pull/95) - -## [v10.0.2](https://github.com/fireblocks/java-sdk/compare/v10.0.1...v10.0.2) - 2025-04-20 - -### Merged - -- Generated SDK #4794 [`#94`](https://github.com/fireblocks/java-sdk/pull/94) - -## [v10.0.1](https://github.com/fireblocks/java-sdk/compare/v10.0.0...v10.0.1) - 2025-04-07 - -### Merged - -- Generated SDK #3065 [`#93`](https://github.com/fireblocks/java-sdk/pull/93) - -## [v10.0.0](https://github.com/fireblocks/java-sdk/compare/v9.0.0...v10.0.0) - 2025-03-30 - -### Merged - -- Generated SDK #619 [`#90`](https://github.com/fireblocks/java-sdk/pull/90) - -## [v9.0.0](https://github.com/fireblocks/java-sdk/compare/v8.1.0...v9.0.0) - 2025-03-17 - -### Merged - -- Generated SDK #645 [`#89`](https://github.com/fireblocks/java-sdk/pull/89) - -## [v8.1.0](https://github.com/fireblocks/java-sdk/compare/v8.0.1...v8.1.0) - 2025-02-24 - -### Merged - -- Generated SDK #9833 [`#84`](https://github.com/fireblocks/java-sdk/pull/84) - -## [v8.0.1](https://github.com/fireblocks/java-sdk/compare/v8.0.0...v8.0.1) - 2025-02-12 - -### Merged - -- Generated SDK #4262 [`#82`](https://github.com/fireblocks/java-sdk/pull/82) - -## [v8.0.0](https://github.com/fireblocks/java-sdk/compare/v7.0.0...v8.0.0) - 2025-02-02 - -### Merged - -- Generated SDK #538 [`#80`](https://github.com/fireblocks/java-sdk/pull/80) - -## [v7.0.0](https://github.com/fireblocks/java-sdk/compare/v6.0.0...v7.0.0) - 2025-01-08 - -### Merged - -- Generated SDK #8699 [`#77`](https://github.com/fireblocks/java-sdk/pull/77) - -## [v6.0.0](https://github.com/fireblocks/java-sdk/compare/v5.0.0...v6.0.0) - 2024-12-05 - -### Merged - -- Generated SDK #1430 [`#73`](https://github.com/fireblocks/java-sdk/pull/73) - -## [v5.0.0](https://github.com/fireblocks/java-sdk/compare/v4.0.0...v5.0.0) - 2024-10-31 - -### Merged - -- Generated SDK #5184 [`#71`](https://github.com/fireblocks/java-sdk/pull/71) - -## [v4.0.0](https://github.com/fireblocks/java-sdk/compare/v3.1.0...v4.0.0) - 2024-09-17 - -### Merged - -- Generated SDK #237 [`#70`](https://github.com/fireblocks/java-sdk/pull/70) - -## [v3.1.0](https://github.com/fireblocks/java-sdk/compare/v3.0.0...v3.1.0) - 2024-07-25 - -### Merged - -- Generated SDK #6749 [`#67`](https://github.com/fireblocks/java-sdk/pull/67) - -## [v3.0.0](https://github.com/fireblocks/java-sdk/compare/v2.1.0...v3.0.0) - 2024-07-17 - -### Merged - -- Generated SDK #6152 [`#65`](https://github.com/fireblocks/java-sdk/pull/65) -- Generated SDK #7984 [`#62`](https://github.com/fireblocks/java-sdk/pull/62) -- Generated SDK #2873 [`#61`](https://github.com/fireblocks/java-sdk/pull/61) - -## [v2.1.0](https://github.com/fireblocks/java-sdk/compare/v2.0.1...v2.1.0) - 2024-06-04 - -### Merged - -- Generated SDK for version COR-46191/fix_pipelines [`#24`](https://github.com/fireblocks/java-sdk/pull/24) -- Generated SDK for version COR-46191/fix_pipelines [`#23`](https://github.com/fireblocks/java-sdk/pull/23) -- Generated SDK for version COR-46191/fix_pipelines [`#22`](https://github.com/fireblocks/java-sdk/pull/22) -- Generated SDK for version COR-46191/fix_pipelines [`#21`](https://github.com/fireblocks/java-sdk/pull/21) - -## [v2.0.1](https://github.com/fireblocks/java-sdk/compare/v2.0.0...v2.0.1) - 2024-06-04 - -### Merged - -- Generated SDK for version COR-46191/fix_pipelines [`#20`](https://github.com/fireblocks/java-sdk/pull/20) - -## [v2.0.0](https://github.com/fireblocks/java-sdk/compare/v1.1.0...v2.0.0) - 2024-05-08 - -### Merged - -- feat: add tokenization api [`#12`](https://github.com/fireblocks/java-sdk/pull/12) - -## [v1.1.0](https://github.com/fireblocks/java-sdk/compare/v1.0.1...v1.1.0) - 2024-04-17 - -### Merged - -- feat: add cosigners beta api [`#11`](https://github.com/fireblocks/java-sdk/pull/11) -- fix: fix readme doc headline [`#10`](https://github.com/fireblocks/java-sdk/pull/10) - -## [v1.0.1](https://github.com/fireblocks/java-sdk/compare/v1.0.0...v1.0.1) - 2024-04-07 - -### Merged - -- Generated SDK for version v1.0.1 [`#9`](https://github.com/fireblocks/java-sdk/pull/9) - -## v1.0.0 - 2024-04-07 - -### Merged - -- Generated SDK for version v1.0.0 GA [`#8`](https://github.com/fireblocks/java-sdk/pull/8) -- v0.0.1-beta [`#6`](https://github.com/fireblocks/java-sdk/pull/6) -- Update GitHub Actions workflows [`#5`](https://github.com/fireblocks/java-sdk/pull/5) -- Generated #1189972817 [`#3`](https://github.com/fireblocks/java-sdk/pull/3) -- Add installation instructions [`#2`](https://github.com/fireblocks/java-sdk/pull/2) -- Added Idempotency & NCW headers support #6 [`#1`](https://github.com/fireblocks/java-sdk/pull/1) diff --git a/README.md b/README.md index 583fa5ec..dada4474 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ Add this dependency to your project's POM: com.fireblocks.sdk fireblocks-sdk - 28.0.0 + 0.0.0 compile ``` @@ -42,7 +42,7 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "com.fireblocks.sdk:fireblocks-sdk:28.0.0" +compile "com.fireblocks.sdk:fireblocks-sdk:0.0.0" ``` ### Others @@ -55,7 +55,7 @@ mvn clean package Then manually install the following JARs: -- `target/fireblocks-sdk-28.0.0.jar` +- `target/fireblocks-sdk-0.0.0.jar` - `target/lib/*.jar` @@ -218,6 +218,7 @@ Class | Method | HTTP request | Description *ConnectedAccountsBetaApi* | [**syncConnectedAccountAllowlist**](docs/ConnectedAccountsBetaApi.md#syncConnectedAccountAllowlist) | **POST** /connected_accounts/{accountId}/allowlist/sync | Sync allowlist for connected account *ConsoleUserApi* | [**createConsoleUser**](docs/ConsoleUserApi.md#createConsoleUser) | **POST** /management/users | Create console user *ConsoleUserApi* | [**getConsoleUsers**](docs/ConsoleUserApi.md#getConsoleUsers) | **GET** /management/users | Get console users +*ContactsApi* | [**getContacts**](docs/ContactsApi.md#getContacts) | **GET** /contacts | List contacts *ContractInteractionsApi* | [**decodeContractData**](docs/ContractInteractionsApi.md#decodeContractData) | **POST** /contract_interactions/base_asset_id/{baseAssetId}/contract_address/{contractAddress}/decode | Decode a function call data, error, or event log *ContractInteractionsApi* | [**getContractAddress**](docs/ContractInteractionsApi.md#getContractAddress) | **GET** /contract_interactions/base_asset_id/{baseAssetId}/tx_hash/{txHash} | Get contract address by transaction hash *ContractInteractionsApi* | [**getDeployedContractAbi**](docs/ContractInteractionsApi.md#getDeployedContractAbi) | **GET** /contract_interactions/base_asset_id/{baseAssetId}/contract_address/{contractAddress}/functions | Return deployed contract's ABI @@ -819,6 +820,11 @@ Class | Method | HTTP request | Description - [ConnectedSingleAccount](docs/ConnectedSingleAccount.md) - [ConnectedSingleAccountResponse](docs/ConnectedSingleAccountResponse.md) - [ConsoleUser](docs/ConsoleUser.md) + - [Contact](docs/Contact.md) + - [ContactApprovalRequest](docs/ContactApprovalRequest.md) + - [ContactTag](docs/ContactTag.md) + - [ContactTagAttachmentPending](docs/ContactTagAttachmentPending.md) + - [ContactsPagedResponse](docs/ContactsPagedResponse.md) - [ContractAbiResponseDto](docs/ContractAbiResponseDto.md) - [ContractAbiResponseDtoAbiInner](docs/ContractAbiResponseDtoAbiInner.md) - [ContractAddressResponse](docs/ContractAddressResponse.md) diff --git a/api/openapi.yaml b/api/openapi.yaml index 1a44c2b0..1212572a 100644 --- a/api/openapi.yaml +++ b/api/openapi.yaml @@ -5912,6 +5912,217 @@ paths: x-content-type: application/json x-accepts: - application/json + /contacts: + get: + description: | + Returns a paginated list of the workspace's address book contacts. + + Live contacts are returned by default; pass `archived=true` to return only the archived + ones. Results are sorted by `name` ascending unless `sortBy`/`order` say otherwise. + Because the sort column is the page cursor's leading key, a `pageCursor` must be replayed + with the same sort it was minted under, or the request is rejected. + + Endpoint Permissions: any workspace role may read the address book. Writes are role-gated. + operationId: getContacts + parameters: + - description: Cursor indicating the page position. Omit to fetch the first + page. + example: bmFtZS1BU0M=~QWNtZSBDb3Jw:NA== + explode: true + in: query + name: pageCursor + required: false + schema: + maxLength: 1024 + type: string + style: form + - description: Number of results per page + example: 25 + explode: true + in: query + name: pageSize + required: false + schema: + default: 100 + maximum: 100 + minimum: 1 + type: integer + style: form + - description: Return the total count of matching contacts alongside the page. + Counting is opt-in because it costs an extra pass over the filtered set; + `total` is omitted from the response unless this is `true`. + example: true + explode: true + in: query + name: includeTotal + required: false + schema: + default: false + type: boolean + style: form + - description: Filter by a case-insensitive substring of the contact name + example: acme + explode: true + in: query + name: name + required: false + schema: + maxLength: 255 + minLength: 1 + type: string + style: form + - description: Filter by one or more contact types + example: + - COUNTERPARTY + explode: true + in: query + name: types + required: false + schema: + items: + enum: + - COUNTERPARTY + - OWN_ACCOUNT + type: string + maxItems: 2 + type: array + style: form + - description: Filter by the container holding the contact + example: 11111111-1111-1111-1111-111111111111 + explode: true + in: query + name: containerId + required: false + schema: + format: uuid + type: string + style: form + - description: Return only archived contacts instead of live ones + example: false + explode: true + in: query + name: archived + required: false + schema: + default: false + type: boolean + style: form + - description: Filter by the access control applied to the contact + example: WHITELIST + explode: true + in: query + name: accessControl + required: false + schema: + enum: + - WHITELIST + - BLACKLIST + type: string + style: form + - description: List of tag IDs to include. Contacts with any of these tags will + be included + example: + - df4c0987-30da-4976-8dcf-bc2dd41ae331 + explode: true + in: query + name: includeTagIds + required: false + schema: + items: + format: uuid + type: string + maxItems: 50 + type: array + style: form + - description: List of tag IDs to exclude. Contacts with any of these tags will + be filtered out + example: + - df4c0987-30da-4976-8dcf-bc2dd41ae331 + explode: true + in: query + name: excludeTagIds + required: false + schema: + items: + format: uuid + type: string + maxItems: 50 + type: array + style: form + - description: The field to sort by + example: updatedAt + explode: true + in: query + name: sortBy + required: false + schema: + default: name + enum: + - name + - updatedAt + type: string + style: form + - description: The sort direction + example: DESC + explode: true + in: query + name: order + required: false + schema: + default: ASC + enum: + - ASC + - DESC + type: string + style: form + responses: + "200": + content: + application/json: + schema: + $ref: "#/components/schemas/ContactsPagedResponse" + description: A paginated list of contacts + headers: + X-Request-ID: + $ref: "#/components/headers/X-Request-ID" + default: + $ref: "#/components/responses/Error" + summary: List contacts + tags: + - Contacts + x-rate-limit-category: query + x-readme: + code-samples: + - language: typescript + code: "const response: Promise>\ + \ = fireblocks.contacts.getContacts(contactsApiGetContactsRequest);" + name: Fireblocks SDK TypeScript example + - language: java + code: "CompletableFuture> response =\ + \ fireblocks.contacts().getContacts(pageCursor, pageSize, includeTotal,\ + \ name, types, containerId, archived, accessControl, includeTagIds, excludeTagIds,\ + \ sortBy, order);" + name: Fireblocks SDK Java example + - language: python + code: "response = fireblocks.contacts.get_contacts(page_cursor, page_size,\ + \ include_total, name, types, container_id, archived, access_control,\ + \ include_tag_ids, exclude_tag_ids, sort_by, order);" + name: Fireblocks SDK Python example + x-codeSamples: + - lang: TypeScript + source: "const response: Promise>\ + \ = fireblocks.contacts.getContacts(contactsApiGetContactsRequest);" + - lang: Java + source: "CompletableFuture> response =\ + \ fireblocks.contacts().getContacts(pageCursor, pageSize, includeTotal,\ + \ name, types, containerId, archived, accessControl, includeTagIds, excludeTagIds,\ + \ sortBy, order);" + - lang: Python + source: "response = fireblocks.contacts.get_contacts(page_cursor, page_size,\ + \ include_total, name, types, container_id, archived, access_control, include_tag_ids,\ + \ exclude_tag_ids, sort_by, order);" + x-accepts: + - application/json /contract_interactions/base_asset_id/{baseAssetId}/contract_address/{contractAddress}/decode: post: description: "Decode a function call data, error, or event log from a deployed\ @@ -46445,12 +46656,14 @@ components: trmStatus: $ref: "#/components/schemas/TRLinkTrmScreeningStatus" validBefore: - description: Unix timestamp when rule expires - example: 1672531200000 + description: Rule expires once this many seconds have elapsed since the + wait/screening step started + example: 1800 type: number validAfter: - description: Unix timestamp when rule becomes valid - example: 1640995200000 + description: Rule applies only after this many seconds have elapsed since + the wait/screening step started + example: 1800 type: number action: $ref: "#/components/schemas/TRLinkVerdict" @@ -46481,9 +46694,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND type: object TRLinkProviderResultWithRule: @@ -46513,9 +46726,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" properties: @@ -46539,12 +46752,14 @@ components: - $ref: "#/components/schemas/TRLinkRuleBase" - properties: validBefore: - description: Unix timestamp when rule expires - example: 1672531200000 + description: Rule expires once this many seconds have elapsed since the + wait/screening step started + example: 1800 type: number validAfter: - description: Unix timestamp when rule becomes valid - example: 1640995200000 + description: Rule applies only after this many seconds have elapsed since + the wait/screening step started + example: 1800 type: number action: $ref: "#/components/schemas/TRLinkMissingTrmAction" @@ -46596,9 +46811,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2000-01-23T04:56:07.000+00:00 type: object @@ -46657,9 +46872,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -46689,9 +46904,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2000-01-23T04:56:07.000+00:00 timestamp: 1640995200000 @@ -46946,9 +47161,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -46978,9 +47193,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2000-01-23T04:56:07.000+00:00 timestamp: 1640995200000 @@ -47037,9 +47252,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -47069,9 +47284,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2000-01-23T04:56:07.000+00:00 timestamp: 1640995200000 @@ -48097,9 +48312,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -48129,9 +48344,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2000-01-23T04:56:07.000+00:00 timestamp: 1640995200000 @@ -48188,9 +48403,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -48220,9 +48435,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2000-01-23T04:56:07.000+00:00 timestamp: 1640995200000 @@ -51752,6 +51967,7 @@ components: subType: null id: id type: null + feeCurrency: PATHUSD_TEMPO_54V8 extraParameters: piiData: key: "" @@ -53061,6 +53277,14 @@ components: After you submit a transaction with an external ID, Fireblocks will automatically reject all future transactions with the same ID. Using an external ID primarily helps in situations where, even though a submitted transaction responds with an error due to an internet outage, the transaction was still sent to and processed on the blockchain. Use the [Get a specific transaction by external transaction ID](https://developers.fireblocks.com/reference/gettransactionbyexternalid) endpoint to validate whether these transactions have been processed. example: 00000000-0000-0000-0000-000000000000 type: string + feeCurrency: + description: "For Tempo-based transactions only, the asset used to pay the\ + \ transaction's network fee, as an asset ID ([see supported assets](https://developers.fireblocks.com/api-reference/blockchains-&-assets/list-assets)).\ + \ For any other blockchain, this value is ignored. This feature is currently\ + \ in beta and might be subject to changes." + example: PATHUSD_TEMPO_54V8 + type: string + x-fb-entity: asset assetId: description: "The ID of the asset to transfer, for `TRANSFER`, `MINT` or\ \ `BURN` operations. [See the list of supported assets and their IDs on\ @@ -55030,6 +55254,7 @@ components: subType: null id: id type: null + feeCurrency: PATHUSD_TEMPO_54V8 extraParameters: piiData: key: "" @@ -56351,6 +56576,7 @@ components: subType: null id: id type: null + feeCurrency: PATHUSD_TEMPO_54V8 extraParameters: piiData: key: "" @@ -69232,6 +69458,7 @@ components: - UNSUPPORTED_SOURCE_ASSET - UNSUPPORTED_DESTINATION_ASSET - AMOUNT_BELOW_MINIMUM + - AMOUNT_ABOVE_MAXIMUM - PII_MISSING - EXTERNAL_SOURCE_NOT_SUPPORTED - UNSUPPORTED_REGION @@ -76481,12 +76708,14 @@ components: trmStatus: $ref: "#/components/schemas/TRLinkTrmScreeningStatusEnum" validBefore: - description: Unix timestamp when rule expires - example: 1672531200000 + description: Rule expires once this many seconds have elapsed since the + wait/screening step started + example: 1800 type: number validAfter: - description: Unix timestamp when rule becomes valid - example: 1640995200000 + description: Rule applies only after this many seconds have elapsed since + the wait/screening step started + example: 1800 type: number action: $ref: "#/components/schemas/TRLinkVerdictEnum" @@ -76517,9 +76746,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND type: object TRLinkProviderResultWithRule-2: @@ -76549,9 +76778,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" properties: @@ -76575,12 +76804,14 @@ components: - $ref: "#/components/schemas/ScreeningTRLinkRuleBase" - properties: validBefore: - description: Unix timestamp when rule expires - example: 1672531200000 + description: Rule expires once this many seconds have elapsed since the + wait/screening step started + example: 1800 type: number validAfter: - description: Unix timestamp when rule becomes valid - example: 1640995200000 + description: Rule applies only after this many seconds have elapsed since + the wait/screening step started + example: 1800 type: number action: $ref: "#/components/schemas/TRLinkMissingTrmActionEnum" @@ -76633,9 +76864,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2023-10-05T14:48:00Z type: object @@ -76694,9 +76925,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -76726,9 +76957,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2023-10-05T14:48:00Z timestamp: 1640995200000 @@ -76983,9 +77214,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -77015,9 +77246,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2023-10-05T14:48:00Z timestamp: 1640995200000 @@ -77074,9 +77305,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND providerResponse: "{}" customerShortName: ACME Corp @@ -77106,9 +77337,9 @@ components: sourceSubType: INTERNAL asset: BTC operation: TRANSFER - validBefore: 1672531200000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1640995200000 + validAfter: 1800 direction: OUTBOUND timestamp: 2023-10-05T14:48:00Z timestamp: 1640995200000 @@ -79885,9 +80116,9 @@ components: sourceSubType: sourceSubType asset: ETH operation: TRANSFER - validBefore: 1735689600000 + validBefore: 1800 networkProtocol: ETHEREUM - validAfter: 1704067200000 + validAfter: 1800 direction: OUTBOUND properties: customerId: @@ -79972,17 +80203,17 @@ components: trmStatus: $ref: "#/components/schemas/TRLinkTrmStatus" validBefore: - description: Rule is valid before this timestamp (milliseconds) - example: 1735689600000 - format: int64 + description: Rule expires once this many seconds have elapsed since the + wait/screening step started + example: 1800 nullable: true - type: integer + type: number validAfter: - description: Rule is valid after this timestamp (milliseconds) - example: 1704067200000 - format: int64 + description: Rule applies only after this many seconds have elapsed since + the wait/screening step started + example: 1800 nullable: true - type: integer + type: number action: $ref: "#/components/schemas/TRLinkPostScreeningAction" required: @@ -80019,9 +80250,9 @@ components: sourceSubType: sourceSubType asset: BTC operation: TRANSFER - validBefore: 1735689600000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1704067200000 + validAfter: 1800 direction: OUTBOUND properties: customerId: @@ -80099,17 +80330,17 @@ components: nullable: true type: boolean validBefore: - description: Rule is valid before this timestamp (milliseconds) - example: 1735689600000 - format: int64 + description: Rule expires once this many seconds have elapsed since the + wait/screening step started + example: 1800 nullable: true - type: integer + type: number validAfter: - description: Rule is valid after this timestamp (milliseconds) - example: 1704067200000 - format: int64 + description: Rule applies only after this many seconds have elapsed since + the wait/screening step started + example: 1800 nullable: true - type: integer + type: number action: $ref: "#/components/schemas/TRLinkMissingTrmAction-2" required: @@ -80140,9 +80371,9 @@ components: sourceSubType: sourceSubType asset: BTC operation: TRANSFER - validBefore: 1735689600000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1704067200000 + validAfter: 1800 direction: OUTBOUND - sourceId: sourceId amount: @@ -80164,9 +80395,9 @@ components: sourceSubType: sourceSubType asset: BTC operation: TRANSFER - validBefore: 1735689600000 + validBefore: 1800 networkProtocol: BITCOIN - validAfter: 1704067200000 + validAfter: 1800 direction: OUTBOUND preScreeningRules: - sourceId: sourceId @@ -80236,9 +80467,9 @@ components: sourceSubType: sourceSubType asset: ETH operation: TRANSFER - validBefore: 1735689600000 + validBefore: 1800 networkProtocol: ETHEREUM - validAfter: 1704067200000 + validAfter: 1800 direction: OUTBOUND - sourceId: sourceId amount: @@ -80262,9 +80493,9 @@ components: sourceSubType: sourceSubType asset: ETH operation: TRANSFER - validBefore: 1735689600000 + validBefore: 1800 networkProtocol: ETHEREUM - validAfter: 1704067200000 + validAfter: 1800 direction: OUTBOUND properties: preScreeningRules: @@ -82159,33 +82390,6 @@ components: example: d7ca6101-a65e-4a9c-b6c1-b8bd697e0cd2 format: uuid type: string - type: - description: The finding type identifier - enum: - - API_USER_NOT_WHITELISTED - - CONSOLE_IP_ALLOWLIST_DEACTIVATED - - ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS - - API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY - - API_COSIGNER_WITH_NO_CALLBACK - - API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS - - NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS - - TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS - - ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS - - NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED - - OTA_ENABLED_BUT_UNUSED - - POLICY_NOT_UPDATED_RECENTLY - - RAW_SIGNING_ENABLED_BUT_UNUSED - - API_USER_UNUSED_FOR_90_DAYS - - UNUSED_UNLIMITED_TOKEN_ALLOWANCES - - UNUSED_WHITELISTED_ADDRESS - - TRANSACTION_REPETITION_ATTACK - - USER_EMAIL_DOMAIN_NON_BUSINESS - - OUTDATED_MOBILE_APP_VERSION - - SINGLE_HOP_DRAIN_ATTACK - - LATERAL_MOVEMENT_DRAIN_ATTACK - - WORKSPACE_USER_DORMANT_FOR_X_DAYS - example: API_COSIGNER_WITH_NO_CALLBACK - type: string status: description: Current status of the finding enum: @@ -82256,10 +82460,17 @@ components: description: Additional structured context about the finding. Shape varies by finding type. example: - apiKey: e7c3f18c-3060-3748-3563-19c3dbb3fa88 - apiUserName: Security admin api - cosignerId: 02f53cfa-34a3-4393-a451-e13dfab3c157 - cosignerName: Production Co-Signer + id: 2a6f3c4e-9d33-437e-8f2a-2c9b4d3e1f35 + createdAt: 2026-05-12T12:06:26.242Z + email: "" + enabled: true + firstName: Admin API + isWhitelisted: false + lastName: testd6 + role: ADMIN + status: READY + tenantId: 6d13843c-4e2b-4a22-2c6f-3b8e3d4a7f52 + userType: API type: object ComplianceRequirement: description: A compliance requirement associated with a finding @@ -82290,65 +82501,39 @@ components: SecurityFindingDetailed: description: "A single FSPM finding, redacted to the public field set" example: - severity: HIGH - mitigationGuidance: "Add a callback implementation to the API user. Alternatively,\ - \ if the API user is no longer needed, you can delete it. To do so, go to\ - \ Developer Center > API Users, click the actions button (3 dots) next to\ - \ the API user, and select Delete. Note that by default this action can\ - \ only be performed by the workspace owner." - statusUpdatedByUserId: 00d77437-3e7a-4e39-8482-55115a7a0892 - riskExplanation: "An API user that is paired with a co-signer and does not\ - \ have a callback implementation is vulnerable to auto-approving, allowing\ - \ malicious transactions to proceed without review." + severity: MEDIUM + mitigationGuidance: "Go to Developer Center > API Users, click the actions\ + \ button (3 dots) next to the API user, and select 'Allowlist IP address'." + statusUpdatedByUserId: 7c2e3a4f-144d-4f23-932c-518b3d7f1a09 + riskExplanation: "This API user has no IP allowlist, so it can be accessed\ + \ from anywhere, increasing the risk of unauthorized activity." statusUpdatedAt: 2026-08-16T08:52:57Z complianceReqs: [] - type: API_COSIGNER_WITH_NO_CALLBACK - title: The API user 'Security admin api' is paired with a co-signer and has - no callback - createdAt: 2026-07-28T11:37:05Z - statusUpdatedReason: "False positive, callback is configured via a different\ - \ mechanism" - id: d7ca6101-a65e-4a9c-b6c1-b8bd697e0cd2 + title: The API user 'Admin API' is missing an IP allowlist + createdAt: 2026-07-21T07:49:28Z + statusUpdatedReason: "False positive, the API user only ever connects from\ + \ a fixed, trusted network" + id: 2f8a132e-623d-3a97-841f-2c5d9b7a3e60 category: USER_MANAGEMENT status: OPEN info: - apiKey: e7c3f18c-3060-3748-3563-19c3dbb3fa88 - apiUserName: Security admin api - cosignerId: 02f53cfa-34a3-4393-a451-e13dfab3c157 - cosignerName: Production Co-Signer + id: 2a6f3c4e-9d33-437e-8f2a-2c9b4d3e1f35 + createdAt: 2026-05-12T12:06:26.242Z + email: "" + enabled: true + firstName: Admin API + isWhitelisted: false + lastName: testd6 + role: ADMIN + status: READY + tenantId: 6d13843c-4e2b-4a22-2c6f-3b8e3d4a7f52 + userType: API properties: id: description: Unique identifier of the finding - example: d7ca6101-a65e-4a9c-b6c1-b8bd697e0cd2 + example: 2f8a132e-623d-3a97-841f-2c5d9b7a3e60 format: uuid type: string - type: - description: The finding type identifier - enum: - - API_USER_NOT_WHITELISTED - - CONSOLE_IP_ALLOWLIST_DEACTIVATED - - ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS - - API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY - - API_COSIGNER_WITH_NO_CALLBACK - - API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS - - NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS - - TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS - - ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS - - NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED - - OTA_ENABLED_BUT_UNUSED - - POLICY_NOT_UPDATED_RECENTLY - - RAW_SIGNING_ENABLED_BUT_UNUSED - - API_USER_UNUSED_FOR_90_DAYS - - UNUSED_UNLIMITED_TOKEN_ALLOWANCES - - UNUSED_WHITELISTED_ADDRESS - - TRANSACTION_REPETITION_ATTACK - - USER_EMAIL_DOMAIN_NON_BUSINESS - - OUTDATED_MOBILE_APP_VERSION - - SINGLE_HOP_DRAIN_ATTACK - - LATERAL_MOVEMENT_DRAIN_ATTACK - - WORKSPACE_USER_DORMANT_FOR_X_DAYS - example: API_COSIGNER_WITH_NO_CALLBACK - type: string status: description: Current status of the finding enum: @@ -82364,7 +82549,7 @@ components: - LOW - MEDIUM - HIGH - example: HIGH + example: MEDIUM type: string category: description: Category of the finding @@ -82379,13 +82564,12 @@ components: type: string createdAt: description: When the finding was first detected - example: 2026-07-28T11:37:05Z + example: 2026-07-21T07:49:28Z format: date-time type: string title: description: Human-readable title of the finding - example: The API user 'Security admin api' is paired with a co-signer and - has no callback + example: The API user 'Admin API' is missing an IP allowlist type: string statusUpdatedAt: description: "When the finding status was last updated, omitted if the status\ @@ -82396,13 +82580,14 @@ components: statusUpdatedByUserId: description: "The user who last updated the finding status, omitted if the\ \ status was never updated" - example: 00d77437-3e7a-4e39-8482-55115a7a0892 + example: 7c2e3a4f-144d-4f23-932c-518b3d7f1a09 format: uuid type: string statusUpdatedReason: description: "The reason provided for the last status update, omitted if\ \ none was provided" - example: "False positive, callback is configured via a different mechanism" + example: "False positive, the API user only ever connects from a fixed,\ + \ trusted network" type: string info: additionalProperties: @@ -82411,10 +82596,17 @@ components: description: Additional structured context about the finding. Shape varies by finding type. example: - apiKey: e7c3f18c-3060-3748-3563-19c3dbb3fa88 - apiUserName: Security admin api - cosignerId: 02f53cfa-34a3-4393-a451-e13dfab3c157 - cosignerName: Production Co-Signer + id: 2a6f3c4e-9d33-437e-8f2a-2c9b4d3e1f35 + createdAt: 2026-05-12T12:06:26.242Z + email: "" + enabled: true + firstName: Admin API + isWhitelisted: false + lastName: testd6 + role: ADMIN + status: READY + tenantId: 6d13843c-4e2b-4a22-2c6f-3b8e3d4a7f52 + userType: API type: object complianceReqs: description: Compliance requirements this finding relates to @@ -82424,17 +82616,13 @@ components: type: array riskExplanation: description: Explanation of the risk this finding represents - example: "An API user that is paired with a co-signer and does not have\ - \ a callback implementation is vulnerable to auto-approving, allowing\ - \ malicious transactions to proceed without review." + example: "This API user has no IP allowlist, so it can be accessed from\ + \ anywhere, increasing the risk of unauthorized activity." type: string mitigationGuidance: description: Guidance on how to mitigate this finding - example: "Add a callback implementation to the API user. Alternatively,\ - \ if the API user is no longer needed, you can delete it. To do so, go\ - \ to Developer Center > API Users, click the actions button (3 dots) next\ - \ to the API user, and select Delete. Note that by default this action\ - \ can only be performed by the workspace owner." + example: "Go to Developer Center > API Users, click the actions button (3\ + \ dots) next to the API user, and select 'Allowlist IP address'." type: string required: - category @@ -82447,7 +82635,6 @@ components: - severity - status - title - - type type: object AcceptFindingRequest: description: Request to accept a FSPM finding. A reason is required. @@ -87465,6 +87652,230 @@ components: - totalActiveTickets - totalInactiveTickets type: object + ContactApprovalRequest: + description: "An approval request awaiting a quorum decision. Null when none\ + \ is open. Carried both by a contact, for a quorum-gated write on the contact\ + \ itself, and by an individual tag, for a change to the tag's own definition.\ + \ An attach or detach of that tag to this contact is carried by the tag's\ + \ `pendingAttachment` instead." + nullable: true + properties: + id: + description: The approval request identifier + example: "12345" + type: string + type: + description: "The operation awaiting approval. Deliberately not an enumeration:\ + \ the set is open across the surfaces that carry one, and includes contact\ + \ operations such as CREATE_CONTACT and DELETE_CONTACT as well as changes\ + \ to a tag itself." + example: CREATE_CONTACT + type: string + required: + - id + - type + type: object + ContactTagAttachmentPending: + description: "An attach or detach of this tag to this contact awaiting a quorum\ + \ decision. Null when the attachment is settled. Distinct from the tag's own\ + \ `pendingApprovalRequest`, which covers a change to the tag itself rather\ + \ than to this pairing. When both are open, this is the one to act on from\ + \ a contact: cancelling a change to the tag's own definition belongs to the\ + \ tag surface, and `pendingApprovalRequest.id` must not be used to cancel\ + \ an attachment." + nullable: true + properties: + action: + description: "The operation awaiting approval. ATTACH means the tag is not\ + \ yet attached; DETACH means it is still attached, pending removal." + enum: + - ATTACH + - DETACH + example: ATTACH + type: string + approvalRequestId: + description: The identifier of the approval request gating the operation + example: "12345" + type: string + required: + - action + type: object + ContactTag: + description: "A tag attached to the contact, with the display details resolved\ + \ from the tagging service." + properties: + id: + description: The unique identifier of the tag + example: df4c0987-30da-4976-8dcf-bc2dd41ae331 + format: uuid + type: string + label: + description: The tag label + example: VIP + type: string + color: + description: The tag color in hex format. Absent when the tag has none. + example: "#FF5733" + type: string + description: + description: Description for the tag. Absent when the tag has none. + example: Tag for VIP counterparties + type: string + isProtected: + description: "Whether the tag is protected, meaning changes to it and to\ + \ its attachments are approval-gated." + example: false + type: boolean + pendingApprovalRequest: + $ref: "#/components/schemas/ContactApprovalRequest" + pendingAttachment: + $ref: "#/components/schemas/ContactTagAttachmentPending" + required: + - id + - isProtected + - label + - pendingApprovalRequest + - pendingAttachment + type: object + Contact: + description: A contact in the workspace address book. + properties: + id: + description: The unique identifier of the contact + example: 2f78ac4f-c409-4c56-9553-bc603fc0c932 + format: uuid + type: string + name: + description: "The contact name, unique across the workspace" + example: Acme Corp + type: string + type: + description: Whether the contact is an external party or an account the + workspace owns elsewhere + enum: + - COUNTERPARTY + - OWN_ACCOUNT + example: COUNTERPARTY + type: string + accessControl: + description: The access control applied to the contact. Absent when none + is set. + enum: + - WHITELIST + - BLACKLIST + example: WHITELIST + type: string + notes: + description: Free-text notes on the contact. Absent when none are set. + example: Primary OTC desk + type: string + externalRefId: + description: A customer-supplied reference id for the contact. Absent when + none is set. + example: crm-4471 + type: string + containerId: + description: The container holding the contact. Absent when the contact + sits at the root. + example: 11111111-1111-1111-1111-111111111111 + format: uuid + type: string + updatedAt: + description: "The date and time the contact was last modified, in ISO-8601" + example: 2026-08-06T12:00:00Z + format: date-time + type: string + archivedAt: + description: "The date and time the contact was archived, in ISO-8601. Absent\ + \ for live contacts, so this only carries a value when the request passed\ + \ archived=true." + example: 2026-08-07T11:00:00Z + format: date-time + type: string + tags: + description: The tags attached to the contact + example: + - id: df4c0987-30da-4976-8dcf-bc2dd41ae331 + label: VIP + color: "#FF5733" + description: Tag for VIP counterparties + isProtected: false + pendingApprovalRequest: null + pendingAttachment: null + items: + $ref: "#/components/schemas/ContactTag" + type: array + pendingApprovalRequest: + $ref: "#/components/schemas/ContactApprovalRequest" + required: + - id + - name + - pendingApprovalRequest + - tags + - type + - updatedAt + type: object + ContactsPagedResponse: + example: + next: bmFtZS1BU0M=~QWNtZSBDb3Jw:NA== + total: 42 + data: + - id: 2f78ac4f-c409-4c56-9553-bc603fc0c932 + name: Acme Corp + type: COUNTERPARTY + accessControl: WHITELIST + notes: Primary OTC desk + externalRefId: crm-4471 + containerId: 11111111-1111-1111-1111-111111111111 + updatedAt: 2026-08-06T12:00:00.000Z + tags: + - id: df4c0987-30da-4976-8dcf-bc2dd41ae331 + label: VIP + color: "#FF5733" + description: Tag for VIP counterparties + isProtected: false + pendingApprovalRequest: null + pendingAttachment: null + pendingApprovalRequest: null + properties: + data: + description: The page of contacts + example: + - id: 2f78ac4f-c409-4c56-9553-bc603fc0c932 + name: Acme Corp + type: COUNTERPARTY + accessControl: WHITELIST + notes: Primary OTC desk + externalRefId: crm-4471 + containerId: 11111111-1111-1111-1111-111111111111 + updatedAt: 2026-08-06T12:00:00.000Z + tags: + - id: df4c0987-30da-4976-8dcf-bc2dd41ae331 + label: VIP + color: "#FF5733" + description: Tag for VIP counterparties + isProtected: false + pendingApprovalRequest: null + pendingAttachment: null + pendingApprovalRequest: null + items: + $ref: "#/components/schemas/Contact" + type: array + next: + description: "Cursor to the next page; absent when the current page is the\ + \ last. Opaque, and bound to the sort that minted it — replay it unchanged\ + \ and keep sortBy/order steady across pages." + example: bmFtZS1BU0M=~QWNtZSBDb3Jw:NA== + type: string + total: + description: "The number of contacts matching the filters, ignoring pagination.\ + \ Present only when the request passed `includeTotal=true`; the key is\ + \ absent otherwise." + example: 42 + type: integer + required: + - data + type: object TagsPagedResponse: example: next: MjAyNS0wNy0wOSAxMDo1MzoxMy40NTI=:NA== diff --git a/build.gradle b/build.gradle index 0eb4b751..d43e483e 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'eclipse' apply plugin: 'com.diffplug.spotless' group = 'com.fireblocks.sdk' -version = '28.0.0' +version = '0.0.0' buildscript { repositories { diff --git a/docs/Contact.md b/docs/Contact.md new file mode 100644 index 00000000..98ff2fd6 --- /dev/null +++ b/docs/Contact.md @@ -0,0 +1,42 @@ + + +# Contact + +A contact in the workspace address book. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**id** | **UUID** | The unique identifier of the contact | | +|**name** | **String** | The contact name, unique across the workspace | | +|**type** | [**TypeEnum**](#TypeEnum) | Whether the contact is an external party or an account the workspace owns elsewhere | | +|**accessControl** | [**AccessControlEnum**](#AccessControlEnum) | The access control applied to the contact. Absent when none is set. | [optional] | +|**notes** | **String** | Free-text notes on the contact. Absent when none are set. | [optional] | +|**externalRefId** | **String** | A customer-supplied reference id for the contact. Absent when none is set. | [optional] | +|**containerId** | **UUID** | The container holding the contact. Absent when the contact sits at the root. | [optional] | +|**updatedAt** | **OffsetDateTime** | The date and time the contact was last modified, in ISO-8601 | | +|**archivedAt** | **OffsetDateTime** | The date and time the contact was archived, in ISO-8601. Absent for live contacts, so this only carries a value when the request passed archived=true. | [optional] | +|**tags** | [**List<ContactTag>**](ContactTag.md) | The tags attached to the contact | | +|**pendingApprovalRequest** | [**ContactApprovalRequest**](ContactApprovalRequest.md) | | | + + + +## Enum: TypeEnum + +| Name | Value | +|---- | -----| +| COUNTERPARTY | "COUNTERPARTY" | +| OWN_ACCOUNT | "OWN_ACCOUNT" | + + + +## Enum: AccessControlEnum + +| Name | Value | +|---- | -----| +| WHITELIST | "WHITELIST" | +| BLACKLIST | "BLACKLIST" | + + + diff --git a/docs/ContactApprovalRequest.md b/docs/ContactApprovalRequest.md new file mode 100644 index 00000000..4141a283 --- /dev/null +++ b/docs/ContactApprovalRequest.md @@ -0,0 +1,15 @@ + + +# ContactApprovalRequest + +An approval request awaiting a quorum decision. Null when none is open. Carried both by a contact, for a quorum-gated write on the contact itself, and by an individual tag, for a change to the tag's own definition. An attach or detach of that tag to this contact is carried by the tag's `pendingAttachment` instead. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**id** | **String** | The approval request identifier | | +|**type** | **String** | The operation awaiting approval. Deliberately not an enumeration: the set is open across the surfaces that carry one, and includes contact operations such as CREATE_CONTACT and DELETE_CONTACT as well as changes to a tag itself. | | + + + diff --git a/docs/ContactTag.md b/docs/ContactTag.md new file mode 100644 index 00000000..470ae42c --- /dev/null +++ b/docs/ContactTag.md @@ -0,0 +1,20 @@ + + +# ContactTag + +A tag attached to the contact, with the display details resolved from the tagging service. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**id** | **UUID** | The unique identifier of the tag | | +|**label** | **String** | The tag label | | +|**color** | **String** | The tag color in hex format. Absent when the tag has none. | [optional] | +|**description** | **String** | Description for the tag. Absent when the tag has none. | [optional] | +|**isProtected** | **Boolean** | Whether the tag is protected, meaning changes to it and to its attachments are approval-gated. | | +|**pendingApprovalRequest** | [**ContactApprovalRequest**](ContactApprovalRequest.md) | | | +|**pendingAttachment** | [**ContactTagAttachmentPending**](ContactTagAttachmentPending.md) | | | + + + diff --git a/docs/ContactTagAttachmentPending.md b/docs/ContactTagAttachmentPending.md new file mode 100644 index 00000000..7f1c3a80 --- /dev/null +++ b/docs/ContactTagAttachmentPending.md @@ -0,0 +1,24 @@ + + +# ContactTagAttachmentPending + +An attach or detach of this tag to this contact awaiting a quorum decision. Null when the attachment is settled. Distinct from the tag's own `pendingApprovalRequest`, which covers a change to the tag itself rather than to this pairing. When both are open, this is the one to act on from a contact: cancelling a change to the tag's own definition belongs to the tag surface, and `pendingApprovalRequest.id` must not be used to cancel an attachment. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**action** | [**ActionEnum**](#ActionEnum) | The operation awaiting approval. ATTACH means the tag is not yet attached; DETACH means it is still attached, pending removal. | | +|**approvalRequestId** | **String** | The identifier of the approval request gating the operation | [optional] | + + + +## Enum: ActionEnum + +| Name | Value | +|---- | -----| +| ATTACH | "ATTACH" | +| DETACH | "DETACH" | + + + diff --git a/docs/ContactsApi.md b/docs/ContactsApi.md new file mode 100644 index 00000000..793d55db --- /dev/null +++ b/docs/ContactsApi.md @@ -0,0 +1,108 @@ +# ContactsApi + +All URIs are relative to https://developers.fireblocks.com/reference/ + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**getContacts**](ContactsApi.md#getContacts) | **GET** /contacts | List contacts | + + + +## getContacts + +> CompletableFuture> getContacts getContacts(pageCursor, pageSize, includeTotal, name, types, containerId, archived, accessControl, includeTagIds, excludeTagIds, sortBy, order) + +List contacts + +Returns a paginated list of the workspace's address book contacts. Live contacts are returned by default; pass `archived=true` to return only the archived ones. Results are sorted by `name` ascending unless `sortBy`/`order` say otherwise. Because the sort column is the page cursor's leading key, a `pageCursor` must be replayed with the same sort it was minted under, or the request is rejected. Endpoint Permissions: any workspace role may read the address book. Writes are role-gated. + +### Example + +```java +// Import classes: +import com.fireblocks.sdk.ApiClient; +import com.fireblocks.sdk.ApiException; +import com.fireblocks.sdk.ApiResponse; +import com.fireblocks.sdk.BasePath; +import com.fireblocks.sdk.Fireblocks; +import com.fireblocks.sdk.ConfigurationOptions; +import com.fireblocks.sdk.model.*; +import com.fireblocks.sdk.api.ContactsApi; +import java.util.concurrent.CompletableFuture; +import java.util.concurrent.ExecutionException; + +public class Example { + public static void main(String[] args) { + ConfigurationOptions configurationOptions = new ConfigurationOptions() + .basePath(BasePath.Sandbox) + .apiKey("my-api-key") + .secretKey("my-secret-key"); + Fireblocks fireblocks = new Fireblocks(configurationOptions); + + String pageCursor = "bmFtZS1BU0M=~QWNtZSBDb3Jw:NA=="; // String | Cursor indicating the page position. Omit to fetch the first page. + Integer pageSize = 100; // Integer | Number of results per page + Boolean includeTotal = false; // Boolean | Return the total count of matching contacts alongside the page. Counting is opt-in because it costs an extra pass over the filtered set; `total` is omitted from the response unless this is `true`. + String name = "acme"; // String | Filter by a case-insensitive substring of the contact name + List types = Arrays.asList(); // List | Filter by one or more contact types + UUID containerId = UUID.fromString("11111111-1111-1111-1111-111111111111"); // UUID | Filter by the container holding the contact + Boolean archived = false; // Boolean | Return only archived contacts instead of live ones + String accessControl = "WHITELIST"; // String | Filter by the access control applied to the contact + List includeTagIds = Arrays.asList(); // List | List of tag IDs to include. Contacts with any of these tags will be included + List excludeTagIds = Arrays.asList(); // List | List of tag IDs to exclude. Contacts with any of these tags will be filtered out + String sortBy = "name"; // String | The field to sort by + String order = "ASC"; // String | The sort direction + try { + CompletableFuture> response = fireblocks.contacts().getContacts(pageCursor, pageSize, includeTotal, name, types, containerId, archived, accessControl, includeTagIds, excludeTagIds, sortBy, order); + System.out.println("Status code: " + response.get().getStatusCode()); + System.out.println("Response headers: " + response.get().getHeaders()); + System.out.println("Response body: " + response.get().getData()); + } catch (InterruptedException | ExecutionException e) { + ApiException apiException = (ApiException)e.getCause(); + System.err.println("Exception when calling ContactsApi#getContacts"); + System.err.println("Status code: " + apiException.getCode()); + System.err.println("Response headers: " + apiException.getResponseHeaders()); + System.err.println("Reason: " + apiException.getResponseBody()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +| Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **pageCursor** | **String**| Cursor indicating the page position. Omit to fetch the first page. | [optional] | +| **pageSize** | **Integer**| Number of results per page | [optional] [default to 100] | +| **includeTotal** | **Boolean**| Return the total count of matching contacts alongside the page. Counting is opt-in because it costs an extra pass over the filtered set; `total` is omitted from the response unless this is `true`. | [optional] [default to false] | +| **name** | **String**| Filter by a case-insensitive substring of the contact name | [optional] | +| **types** | [**List<String>**](String.md)| Filter by one or more contact types | [optional] [enum: COUNTERPARTY, OWN_ACCOUNT] | +| **containerId** | **UUID**| Filter by the container holding the contact | [optional] | +| **archived** | **Boolean**| Return only archived contacts instead of live ones | [optional] [default to false] | +| **accessControl** | **String**| Filter by the access control applied to the contact | [optional] [enum: WHITELIST, BLACKLIST] | +| **includeTagIds** | [**List<UUID>**](UUID.md)| List of tag IDs to include. Contacts with any of these tags will be included | [optional] | +| **excludeTagIds** | [**List<UUID>**](UUID.md)| List of tag IDs to exclude. Contacts with any of these tags will be filtered out | [optional] | +| **sortBy** | **String**| The field to sort by | [optional] [default to name] [enum: name, updatedAt] | +| **order** | **String**| The sort direction | [optional] [default to ASC] [enum: ASC, DESC] | + +### Return type + +CompletableFuture> + + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | A paginated list of contacts | * X-Request-ID -
| +| **0** | Error Response | * X-Request-ID -
| + diff --git a/docs/ContactsPagedResponse.md b/docs/ContactsPagedResponse.md new file mode 100644 index 00000000..ee07a1dd --- /dev/null +++ b/docs/ContactsPagedResponse.md @@ -0,0 +1,15 @@ + + +# ContactsPagedResponse + + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**data** | [**List<Contact>**](Contact.md) | The page of contacts | | +|**next** | **String** | Cursor to the next page; absent when the current page is the last. Opaque, and bound to the sort that minted it — replay it unchanged and keep sortBy/order steady across pages. | [optional] | +|**total** | **Integer** | The number of contacts matching the filters, ignoring pagination. Present only when the request passed `includeTotal=true`; the key is absent otherwise. | [optional] | + + + diff --git a/docs/FailureReason.md b/docs/FailureReason.md index 0089bd43..870d7c3a 100644 --- a/docs/FailureReason.md +++ b/docs/FailureReason.md @@ -49,6 +49,8 @@ * `AMOUNT_BELOW_MINIMUM` (value: `"AMOUNT_BELOW_MINIMUM"`) +* `AMOUNT_ABOVE_MAXIMUM` (value: `"AMOUNT_ABOVE_MAXIMUM"`) + * `PII_MISSING` (value: `"PII_MISSING"`) * `EXTERNAL_SOURCE_NOT_SUPPORTED` (value: `"EXTERNAL_SOURCE_NOT_SUPPORTED"`) diff --git a/docs/ScreeningTRLinkMissingTrmDecision.md b/docs/ScreeningTRLinkMissingTrmDecision.md index 2c208264..e01ea8ec 100644 --- a/docs/ScreeningTRLinkMissingTrmDecision.md +++ b/docs/ScreeningTRLinkMissingTrmDecision.md @@ -25,8 +25,8 @@ Interface for reporting missing TRM screening decisions in ITRLinkResult |**operation** | **TransactionOperationEnum** | | [optional] | |**description** | **String** | Rule description | [optional] | |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | -|**validBefore** | **BigDecimal** | Unix timestamp when rule expires | [optional] | -|**validAfter** | **BigDecimal** | Unix timestamp when rule becomes valid | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkMissingTrmActionEnum** | | | |**source** | **String** | TRLink missing TRM source | | |**timestamp** | **OffsetDateTime** | Timestamp of the decision | [optional] | diff --git a/docs/ScreeningTRLinkMissingTrmRule.md b/docs/ScreeningTRLinkMissingTrmRule.md index e348b53e..944d6967 100644 --- a/docs/ScreeningTRLinkMissingTrmRule.md +++ b/docs/ScreeningTRLinkMissingTrmRule.md @@ -25,8 +25,8 @@ TRLink missing TRM rule definition |**operation** | **TransactionOperationEnum** | | [optional] | |**description** | **String** | Rule description | [optional] | |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | -|**validBefore** | **BigDecimal** | Unix timestamp when rule expires | [optional] | -|**validAfter** | **BigDecimal** | Unix timestamp when rule becomes valid | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkMissingTrmActionEnum** | | | diff --git a/docs/ScreeningTRLinkPostScreeningRule.md b/docs/ScreeningTRLinkPostScreeningRule.md index fee0d806..2ee47cfb 100644 --- a/docs/ScreeningTRLinkPostScreeningRule.md +++ b/docs/ScreeningTRLinkPostScreeningRule.md @@ -27,8 +27,8 @@ TRLink post-screening rule definition |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | |**providerIdent** | **String** | Provider identifier | [optional] | |**trmStatus** | **TRLinkTrmScreeningStatusEnum** | | [optional] | -|**validBefore** | **BigDecimal** | Unix timestamp when rule expires | [optional] | -|**validAfter** | **BigDecimal** | Unix timestamp when rule becomes valid | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkVerdictEnum** | | | diff --git a/docs/SecurityFinding.md b/docs/SecurityFinding.md index 700118f5..93b2a5ef 100644 --- a/docs/SecurityFinding.md +++ b/docs/SecurityFinding.md @@ -9,7 +9,6 @@ A single FSPM finding | Name | Type | Description | Notes | |------------ | ------------- | ------------- | -------------| |**id** | **UUID** | Unique identifier of the finding | [optional] | -|**type** | [**TypeEnum**](#TypeEnum) | The finding type identifier | [optional] | |**status** | [**StatusEnum**](#StatusEnum) | Current status of the finding | [optional] | |**severity** | [**SeverityEnum**](#SeverityEnum) | Severity level of the finding | [optional] | |**category** | [**CategoryEnum**](#CategoryEnum) | Category of the finding | [optional] | @@ -18,35 +17,6 @@ A single FSPM finding -## Enum: TypeEnum - -| Name | Value | -|---- | -----| -| API_USER_NOT_WHITELISTED | "API_USER_NOT_WHITELISTED" | -| CONSOLE_IP_ALLOWLIST_DEACTIVATED | "CONSOLE_IP_ALLOWLIST_DEACTIVATED" | -| ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS | "ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS" | -| API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY | "API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY" | -| API_COSIGNER_WITH_NO_CALLBACK | "API_COSIGNER_WITH_NO_CALLBACK" | -| API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS | "API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS" | -| NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS | "NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS" | -| TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS | "TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS" | -| ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS | "ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS" | -| NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED | "NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED" | -| OTA_ENABLED_BUT_UNUSED | "OTA_ENABLED_BUT_UNUSED" | -| POLICY_NOT_UPDATED_RECENTLY | "POLICY_NOT_UPDATED_RECENTLY" | -| RAW_SIGNING_ENABLED_BUT_UNUSED | "RAW_SIGNING_ENABLED_BUT_UNUSED" | -| API_USER_UNUSED_FOR_90_DAYS | "API_USER_UNUSED_FOR_90_DAYS" | -| UNUSED_UNLIMITED_TOKEN_ALLOWANCES | "UNUSED_UNLIMITED_TOKEN_ALLOWANCES" | -| UNUSED_WHITELISTED_ADDRESS | "UNUSED_WHITELISTED_ADDRESS" | -| TRANSACTION_REPETITION_ATTACK | "TRANSACTION_REPETITION_ATTACK" | -| USER_EMAIL_DOMAIN_NON_BUSINESS | "USER_EMAIL_DOMAIN_NON_BUSINESS" | -| OUTDATED_MOBILE_APP_VERSION | "OUTDATED_MOBILE_APP_VERSION" | -| SINGLE_HOP_DRAIN_ATTACK | "SINGLE_HOP_DRAIN_ATTACK" | -| LATERAL_MOVEMENT_DRAIN_ATTACK | "LATERAL_MOVEMENT_DRAIN_ATTACK" | -| WORKSPACE_USER_DORMANT_FOR_X_DAYS | "WORKSPACE_USER_DORMANT_FOR_X_DAYS" | - - - ## Enum: StatusEnum | Name | Value | diff --git a/docs/SecurityFindingDetailed.md b/docs/SecurityFindingDetailed.md index fa015f79..9fa4b23e 100644 --- a/docs/SecurityFindingDetailed.md +++ b/docs/SecurityFindingDetailed.md @@ -9,7 +9,6 @@ A single FSPM finding, redacted to the public field set | Name | Type | Description | Notes | |------------ | ------------- | ------------- | -------------| |**id** | **UUID** | Unique identifier of the finding | | -|**type** | [**TypeEnum**](#TypeEnum) | The finding type identifier | | |**status** | [**StatusEnum**](#StatusEnum) | Current status of the finding | | |**severity** | [**SeverityEnum**](#SeverityEnum) | Severity level of the finding | | |**category** | [**CategoryEnum**](#CategoryEnum) | Category of the finding | | @@ -25,35 +24,6 @@ A single FSPM finding, redacted to the public field set -## Enum: TypeEnum - -| Name | Value | -|---- | -----| -| API_USER_NOT_WHITELISTED | "API_USER_NOT_WHITELISTED" | -| CONSOLE_IP_ALLOWLIST_DEACTIVATED | "CONSOLE_IP_ALLOWLIST_DEACTIVATED" | -| ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS | "ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS" | -| API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY | "API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY" | -| API_COSIGNER_WITH_NO_CALLBACK | "API_COSIGNER_WITH_NO_CALLBACK" | -| API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS | "API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS" | -| NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS | "NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS" | -| TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS | "TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS" | -| ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS | "ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS" | -| NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED | "NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED" | -| OTA_ENABLED_BUT_UNUSED | "OTA_ENABLED_BUT_UNUSED" | -| POLICY_NOT_UPDATED_RECENTLY | "POLICY_NOT_UPDATED_RECENTLY" | -| RAW_SIGNING_ENABLED_BUT_UNUSED | "RAW_SIGNING_ENABLED_BUT_UNUSED" | -| API_USER_UNUSED_FOR_90_DAYS | "API_USER_UNUSED_FOR_90_DAYS" | -| UNUSED_UNLIMITED_TOKEN_ALLOWANCES | "UNUSED_UNLIMITED_TOKEN_ALLOWANCES" | -| UNUSED_WHITELISTED_ADDRESS | "UNUSED_WHITELISTED_ADDRESS" | -| TRANSACTION_REPETITION_ATTACK | "TRANSACTION_REPETITION_ATTACK" | -| USER_EMAIL_DOMAIN_NON_BUSINESS | "USER_EMAIL_DOMAIN_NON_BUSINESS" | -| OUTDATED_MOBILE_APP_VERSION | "OUTDATED_MOBILE_APP_VERSION" | -| SINGLE_HOP_DRAIN_ATTACK | "SINGLE_HOP_DRAIN_ATTACK" | -| LATERAL_MOVEMENT_DRAIN_ATTACK | "LATERAL_MOVEMENT_DRAIN_ATTACK" | -| WORKSPACE_USER_DORMANT_FOR_X_DAYS | "WORKSPACE_USER_DORMANT_FOR_X_DAYS" | - - - ## Enum: StatusEnum | Name | Value | diff --git a/docs/TRLinkMissingTrmDecision.md b/docs/TRLinkMissingTrmDecision.md index c18487ef..d3eb9d27 100644 --- a/docs/TRLinkMissingTrmDecision.md +++ b/docs/TRLinkMissingTrmDecision.md @@ -25,8 +25,8 @@ Interface for reporting missing TRM screening decisions in ITRLinkResult |**operation** | **TransactionOperationEnum** | | [optional] | |**description** | **String** | Rule description | [optional] | |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | -|**validBefore** | **BigDecimal** | Unix timestamp when rule expires | [optional] | -|**validAfter** | **BigDecimal** | Unix timestamp when rule becomes valid | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkMissingTrmAction** | | | |**source** | **String** | TRLink missing TRM source | | |**timestamp** | **OffsetDateTime** | Timestamp of the decision | [optional] | diff --git a/docs/TRLinkMissingTrmRule.md b/docs/TRLinkMissingTrmRule.md index 941704ed..897e5b82 100644 --- a/docs/TRLinkMissingTrmRule.md +++ b/docs/TRLinkMissingTrmRule.md @@ -25,8 +25,8 @@ TRLink missing TRM rule definition |**operation** | **TransactionOperationEnum** | | [optional] | |**description** | **String** | Rule description | [optional] | |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | -|**validBefore** | **BigDecimal** | Unix timestamp when rule expires | [optional] | -|**validAfter** | **BigDecimal** | Unix timestamp when rule becomes valid | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkMissingTrmAction** | | | diff --git a/docs/TRLinkMissingTrmRule2.md b/docs/TRLinkMissingTrmRule2.md index 4b502d15..c20073f3 100644 --- a/docs/TRLinkMissingTrmRule2.md +++ b/docs/TRLinkMissingTrmRule2.md @@ -25,8 +25,8 @@ Rule for handling transactions when TRM screening data is missing or unavailable |**operation** | **String** | Operation type | [optional] | |**description** | **String** | Rule description | [optional] | |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | -|**validBefore** | **Long** | Rule is valid before this timestamp (milliseconds) | [optional] | -|**validAfter** | **Long** | Rule is valid after this timestamp (milliseconds) | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkMissingTrmAction2** | | | diff --git a/docs/TRLinkPostScreeningRule.md b/docs/TRLinkPostScreeningRule.md index ab9ce39d..a60b596c 100644 --- a/docs/TRLinkPostScreeningRule.md +++ b/docs/TRLinkPostScreeningRule.md @@ -27,8 +27,8 @@ TRLink post-screening rule definition |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | |**providerIdent** | **String** | Provider identifier | [optional] | |**trmStatus** | **TRLinkTrmScreeningStatus** | | [optional] | -|**validBefore** | **BigDecimal** | Unix timestamp when rule expires | [optional] | -|**validAfter** | **BigDecimal** | Unix timestamp when rule becomes valid | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkVerdict** | | | diff --git a/docs/TRLinkPostScreeningRule2.md b/docs/TRLinkPostScreeningRule2.md index 37a6de8a..e628495a 100644 --- a/docs/TRLinkPostScreeningRule2.md +++ b/docs/TRLinkPostScreeningRule2.md @@ -27,8 +27,8 @@ Post-screening rule that determines the verdict based on screening results |**isDefault** | **Boolean** | Whether this is a default rule | [optional] | |**providerIdent** | **String** | TRP provider identifier | [optional] | |**trmStatus** | **TRLinkTrmStatus** | | [optional] | -|**validBefore** | **Long** | Rule is valid before this timestamp (milliseconds) | [optional] | -|**validAfter** | **Long** | Rule is valid after this timestamp (milliseconds) | [optional] | +|**validBefore** | **BigDecimal** | Rule expires once this many seconds have elapsed since the wait/screening step started | [optional] | +|**validAfter** | **BigDecimal** | Rule applies only after this many seconds have elapsed since the wait/screening step started | [optional] | |**action** | **TRLinkPostScreeningAction** | | | diff --git a/docs/TransactionRequest.md b/docs/TransactionRequest.md index 5c4c50f1..cc0926a7 100644 --- a/docs/TransactionRequest.md +++ b/docs/TransactionRequest.md @@ -10,6 +10,7 @@ |**operation** | **TransactionOperation** | | [optional] | |**note** | **String** | Custom note, not sent to the blockchain, to describe the transaction at your Fireblocks workspace. | [optional] | |**externalTxId** | **String** | This parameter allows you to add a unique ID of your own to help prevent duplicate transactions. No specific format is required for this parameter. After you submit a transaction with an external ID, Fireblocks will automatically reject all future transactions with the same ID. Using an external ID primarily helps in situations where, even though a submitted transaction responds with an error due to an internet outage, the transaction was still sent to and processed on the blockchain. Use the [Get a specific transaction by external transaction ID](https://developers.fireblocks.com/reference/gettransactionbyexternalid) endpoint to validate whether these transactions have been processed. | [optional] | +|**feeCurrency** | **String** | For Tempo-based transactions only, the asset used to pay the transaction's network fee, as an asset ID ([see supported assets](https://developers.fireblocks.com/api-reference/blockchains-&-assets/list-assets)). For any other blockchain, this value is ignored. This feature is currently in beta and might be subject to changes. | [optional] | |**assetId** | **String** | The ID of the asset to transfer, for `TRANSFER`, `MINT` or `BURN` operations. [See the list of supported assets and their IDs on Fireblocks.](https://developers.fireblocks.com/reference/gettrlinksupportedasset#/) | [optional] | |**source** | [**SourceTransferPeerPath**](SourceTransferPeerPath.md) | | [optional] | |**destination** | [**DestinationTransferPeerPath**](DestinationTransferPeerPath.md) | | [optional] | diff --git a/pom.xml b/pom.xml index 3bb8d855..5c58d835 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ fireblocks-sdk jar fireblocks-sdk - 28.0.0 + 0.0.0 https://github.com/fireblocks/java-sdk The Fireblocks Official SDK is a comprehensive software development kit that enables seamless integration and interaction with the Fireblocks platform. Fireblocks is a cutting-edge blockchain infrastructure platform that provides secure and scalable solutions for managing digital assets and transactions. This SDK empowers developers to build robust applications that can interact with the Fireblocks platform's features, including creating and managing vault accounts, initiating secure transactions, managing assets, and more. It abstracts complex interactions with the Fireblocks API, making it easier for developers to leverage the platform's capabilities while adhering to best practices in security and efficiency. diff --git a/src/main/java/com/fireblocks/sdk/Configuration.java b/src/main/java/com/fireblocks/sdk/Configuration.java index 939c55f4..aa53bae8 100644 --- a/src/main/java/com/fireblocks/sdk/Configuration.java +++ b/src/main/java/com/fireblocks/sdk/Configuration.java @@ -21,7 +21,7 @@ value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.14.0") public class Configuration { - public static final String VERSION = "28.0.0"; + public static final String VERSION = "0.0.0"; private static final AtomicReference defaultApiClient = new AtomicReference<>(); private static volatile Supplier apiClientFactory = ApiClient::new; diff --git a/src/main/java/com/fireblocks/sdk/Fireblocks.java b/src/main/java/com/fireblocks/sdk/Fireblocks.java index de0a1786..9b775eb2 100644 --- a/src/main/java/com/fireblocks/sdk/Fireblocks.java +++ b/src/main/java/com/fireblocks/sdk/Fireblocks.java @@ -44,6 +44,7 @@ public class Fireblocks { private ComplianceScreeningConfigurationApi complianceScreeningConfiguration; private ConnectedAccountsBetaApi connectedAccountsBeta; private ConsoleUserApi consoleUser; + private ContactsApi contacts; private ContractInteractionsApi contractInteractions; private ContractTemplatesApi contractTemplates; private ContractsApi contracts; @@ -284,6 +285,13 @@ public ConsoleUserApi consoleUser() { return consoleUser; } + public ContactsApi contacts() { + if (contacts == null) { + contacts = new ContactsApi(apiClient); + } + return contacts; + } + public ContractInteractionsApi contractInteractions() { if (contractInteractions == null) { contractInteractions = new ContractInteractionsApi(apiClient); diff --git a/src/main/java/com/fireblocks/sdk/api/ContactsApi.java b/src/main/java/com/fireblocks/sdk/api/ContactsApi.java new file mode 100644 index 00000000..1bef494a --- /dev/null +++ b/src/main/java/com/fireblocks/sdk/api/ContactsApi.java @@ -0,0 +1,274 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.api; + + +import com.fasterxml.jackson.core.type.TypeReference; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.fireblocks.sdk.ApiClient; +import com.fireblocks.sdk.ApiException; +import com.fireblocks.sdk.ApiResponse; +import com.fireblocks.sdk.Pair; +import com.fireblocks.sdk.model.ContactsPagedResponse; +import java.io.IOException; +import java.io.InputStream; +import java.net.URI; +import java.net.http.HttpClient; +import java.net.http.HttpRequest; +import java.net.http.HttpResponse; +import java.time.Duration; +import java.util.ArrayList; +import java.util.List; +import java.util.StringJoiner; +import java.util.UUID; +import java.util.concurrent.CancellationException; +import java.util.concurrent.CompletableFuture; +import java.util.concurrent.CompletionException; +import java.util.concurrent.ExecutionException; +import java.util.function.Consumer; + +@jakarta.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.14.0") +public class ContactsApi { + private final HttpClient memberVarHttpClient; + private final ObjectMapper memberVarObjectMapper; + private final String memberVarBaseUri; + private final Consumer memberVarInterceptor; + private final Duration memberVarReadTimeout; + private final Consumer> memberVarResponseInterceptor; + private final Consumer> memberVarAsyncResponseInterceptor; + + public ContactsApi() { + this(new ApiClient()); + } + + public ContactsApi(ApiClient apiClient) { + memberVarHttpClient = apiClient.getHttpClient(); + memberVarObjectMapper = apiClient.getObjectMapper(); + memberVarBaseUri = apiClient.getBaseUri(); + memberVarInterceptor = apiClient.getRequestInterceptor(); + memberVarReadTimeout = apiClient.getReadTimeout(); + memberVarResponseInterceptor = apiClient.getResponseInterceptor(); + memberVarAsyncResponseInterceptor = apiClient.getAsyncResponseInterceptor(); + } + + private ApiException getApiException(String operationId, HttpResponse response) { + String message = + formatExceptionMessage(operationId, response.statusCode(), response.body()); + return new ApiException( + response.statusCode(), message, response.headers(), response.body()); + } + + /** + * Normalizes any failure raised while performing the call into the single failure type callers + * are told to expect. Transport-level errors surfaced by {@code HttpClient.sendAsync} - + * connection refused, DNS failures, TLS errors, timeouts - would otherwise reach the caller as + * a raw {@link java.io.IOException}, which makes the documented {@code (ApiException) + * e.getCause()} throw {@link ClassCastException}. + * + *

{@link CancellationException} is passed through unchanged: a cancelled call is not an API + * failure. + */ + private static Throwable toApiFailure(Throwable throwable) { + Throwable cause = throwable; + while ((cause instanceof CompletionException || cause instanceof ExecutionException) + && cause.getCause() != null) { + cause = cause.getCause(); + } + if (cause instanceof ApiException || cause instanceof CancellationException) { + return cause; + } + return new ApiException(cause); + } + + private String formatExceptionMessage(String operationId, int statusCode, String body) { + if (body == null || body.isEmpty()) { + body = "[no body]"; + } + return operationId + " call failed with: " + statusCode + " - " + body; + } + + /** + * List contacts Returns a paginated list of the workspace's address book contacts. Live + * contacts are returned by default; pass `archived=true` to return only the + * archived ones. Results are sorted by `name` ascending unless + * `sortBy`/`order` say otherwise. Because the sort column is the page + * cursor's leading key, a `pageCursor` must be replayed with the same sort it was + * minted under, or the request is rejected. Endpoint Permissions: any workspace role may read + * the address book. Writes are role-gated. + * + * @param pageCursor Cursor indicating the page position. Omit to fetch the first page. + * (optional) + * @param pageSize Number of results per page (optional, default to 100) + * @param includeTotal Return the total count of matching contacts alongside the page. Counting + * is opt-in because it costs an extra pass over the filtered set; `total` is + * omitted from the response unless this is `true`. (optional, default to false) + * @param name Filter by a case-insensitive substring of the contact name (optional) + * @param types Filter by one or more contact types (optional + * @param containerId Filter by the container holding the contact (optional) + * @param archived Return only archived contacts instead of live ones (optional, default to + * false) + * @param accessControl Filter by the access control applied to the contact (optional) + * @param includeTagIds List of tag IDs to include. Contacts with any of these tags will be + * included (optional + * @param excludeTagIds List of tag IDs to exclude. Contacts with any of these tags will be + * filtered out (optional + * @param sortBy The field to sort by (optional, default to name) + * @param order The sort direction (optional, default to ASC) + * @return CompletableFuture<ApiResponse<ContactsPagedResponse>>, which completes + * exceptionally with an {@link ApiException} if the API call fails + */ + public CompletableFuture> getContacts( + String pageCursor, + Integer pageSize, + Boolean includeTotal, + String name, + List types, + UUID containerId, + Boolean archived, + String accessControl, + List includeTagIds, + List excludeTagIds, + String sortBy, + String order) { + try { + HttpRequest.Builder localVarRequestBuilder = + getContactsRequestBuilder( + pageCursor, + pageSize, + includeTotal, + name, + types, + containerId, + archived, + accessControl, + includeTagIds, + excludeTagIds, + sortBy, + order); + return memberVarHttpClient + .sendAsync(localVarRequestBuilder.build(), HttpResponse.BodyHandlers.ofString()) + .thenComposeAsync( + localVarResponse -> { + if (memberVarAsyncResponseInterceptor != null) { + memberVarAsyncResponseInterceptor.accept(localVarResponse); + } + if (localVarResponse.statusCode() / 100 != 2) { + return CompletableFuture.failedFuture( + getApiException("getContacts", localVarResponse)); + } + try { + String responseBody = localVarResponse.body(); + return CompletableFuture.completedFuture( + new ApiResponse( + localVarResponse.statusCode(), + localVarResponse.headers().map(), + responseBody == null || responseBody.isBlank() + ? null + : memberVarObjectMapper.readValue( + responseBody, + new TypeReference< + ContactsPagedResponse>() {}))); + } catch (IOException e) { + return CompletableFuture.failedFuture(new ApiException(e)); + } + }) + .handle( + (localVarApiResponse, localVarThrowable) -> + localVarThrowable == null + ? CompletableFuture.completedFuture(localVarApiResponse) + : CompletableFuture + .> + failedFuture( + toApiFailure( + localVarThrowable))) + .thenCompose(localVarNormalized -> localVarNormalized); + } catch (ApiException e) { + return CompletableFuture.failedFuture(e); + } + } + + private HttpRequest.Builder getContactsRequestBuilder( + String pageCursor, + Integer pageSize, + Boolean includeTotal, + String name, + List types, + UUID containerId, + Boolean archived, + String accessControl, + List includeTagIds, + List excludeTagIds, + String sortBy, + String order) + throws ApiException { + + HttpRequest.Builder localVarRequestBuilder = HttpRequest.newBuilder(); + + String localVarPath = "/contacts"; + + List localVarQueryParams = new ArrayList<>(); + StringJoiner localVarQueryStringJoiner = new StringJoiner("&"); + String localVarQueryParameterBaseName; + localVarQueryParameterBaseName = "pageCursor"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("pageCursor", pageCursor)); + localVarQueryParameterBaseName = "pageSize"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("pageSize", pageSize)); + localVarQueryParameterBaseName = "includeTotal"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("includeTotal", includeTotal)); + localVarQueryParameterBaseName = "name"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("name", name)); + localVarQueryParameterBaseName = "types"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("multi", "types", types)); + localVarQueryParameterBaseName = "containerId"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("containerId", containerId)); + localVarQueryParameterBaseName = "archived"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("archived", archived)); + localVarQueryParameterBaseName = "accessControl"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("accessControl", accessControl)); + localVarQueryParameterBaseName = "includeTagIds"; + localVarQueryParams.addAll( + ApiClient.parameterToPairs("multi", "includeTagIds", includeTagIds)); + localVarQueryParameterBaseName = "excludeTagIds"; + localVarQueryParams.addAll( + ApiClient.parameterToPairs("multi", "excludeTagIds", excludeTagIds)); + localVarQueryParameterBaseName = "sortBy"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("sortBy", sortBy)); + localVarQueryParameterBaseName = "order"; + localVarQueryParams.addAll(ApiClient.parameterToPairs("order", order)); + + if (!localVarQueryParams.isEmpty() || localVarQueryStringJoiner.length() != 0) { + StringJoiner queryJoiner = new StringJoiner("&"); + localVarQueryParams.forEach(p -> queryJoiner.add(p.getName() + '=' + p.getValue())); + if (localVarQueryStringJoiner.length() != 0) { + queryJoiner.add(localVarQueryStringJoiner.toString()); + } + localVarRequestBuilder.uri( + URI.create(memberVarBaseUri + localVarPath + '?' + queryJoiner.toString())); + } else { + localVarRequestBuilder.uri(URI.create(memberVarBaseUri + localVarPath)); + } + + localVarRequestBuilder.header("Accept", "application/json"); + + localVarRequestBuilder.method("GET", HttpRequest.BodyPublishers.noBody()); + if (memberVarReadTimeout != null) { + localVarRequestBuilder.timeout(memberVarReadTimeout); + } + if (memberVarInterceptor != null) { + memberVarInterceptor.accept(localVarRequestBuilder); + } + return localVarRequestBuilder; + } +} diff --git a/src/main/java/com/fireblocks/sdk/model/Contact.java b/src/main/java/com/fireblocks/sdk/model/Contact.java new file mode 100644 index 00000000..fe8c7509 --- /dev/null +++ b/src/main/java/com/fireblocks/sdk/model/Contact.java @@ -0,0 +1,653 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonValue; +import com.fireblocks.sdk.ApiClient; +import java.time.OffsetDateTime; +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; +import java.util.StringJoiner; +import java.util.UUID; + +/** A contact in the workspace address book. */ +@JsonPropertyOrder({ + Contact.JSON_PROPERTY_ID, + Contact.JSON_PROPERTY_NAME, + Contact.JSON_PROPERTY_TYPE, + Contact.JSON_PROPERTY_ACCESS_CONTROL, + Contact.JSON_PROPERTY_NOTES, + Contact.JSON_PROPERTY_EXTERNAL_REF_ID, + Contact.JSON_PROPERTY_CONTAINER_ID, + Contact.JSON_PROPERTY_UPDATED_AT, + Contact.JSON_PROPERTY_ARCHIVED_AT, + Contact.JSON_PROPERTY_TAGS, + Contact.JSON_PROPERTY_PENDING_APPROVAL_REQUEST +}) +@jakarta.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.14.0") +public class Contact { + public static final String JSON_PROPERTY_ID = "id"; + @jakarta.annotation.Nonnull private UUID id; + + public static final String JSON_PROPERTY_NAME = "name"; + @jakarta.annotation.Nonnull private String name; + + /** Whether the contact is an external party or an account the workspace owns elsewhere */ + public enum TypeEnum { + COUNTERPARTY(String.valueOf("COUNTERPARTY")), + + OWN_ACCOUNT(String.valueOf("OWN_ACCOUNT")); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + } + + public static final String JSON_PROPERTY_TYPE = "type"; + @jakarta.annotation.Nonnull private TypeEnum type; + + /** The access control applied to the contact. Absent when none is set. */ + public enum AccessControlEnum { + WHITELIST(String.valueOf("WHITELIST")), + + BLACKLIST(String.valueOf("BLACKLIST")); + + private String value; + + AccessControlEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static AccessControlEnum fromValue(String value) { + for (AccessControlEnum b : AccessControlEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + } + + public static final String JSON_PROPERTY_ACCESS_CONTROL = "accessControl"; + @jakarta.annotation.Nullable private AccessControlEnum accessControl; + + public static final String JSON_PROPERTY_NOTES = "notes"; + @jakarta.annotation.Nullable private String notes; + + public static final String JSON_PROPERTY_EXTERNAL_REF_ID = "externalRefId"; + @jakarta.annotation.Nullable private String externalRefId; + + public static final String JSON_PROPERTY_CONTAINER_ID = "containerId"; + @jakarta.annotation.Nullable private UUID containerId; + + public static final String JSON_PROPERTY_UPDATED_AT = "updatedAt"; + @jakarta.annotation.Nonnull private OffsetDateTime updatedAt; + + public static final String JSON_PROPERTY_ARCHIVED_AT = "archivedAt"; + @jakarta.annotation.Nullable private OffsetDateTime archivedAt; + + public static final String JSON_PROPERTY_TAGS = "tags"; + @jakarta.annotation.Nonnull private List tags; + + public static final String JSON_PROPERTY_PENDING_APPROVAL_REQUEST = "pendingApprovalRequest"; + @jakarta.annotation.Nullable private ContactApprovalRequest pendingApprovalRequest; + + public Contact() {} + + @JsonCreator + public Contact( + @JsonProperty(value = JSON_PROPERTY_ID, required = true) UUID id, + @JsonProperty(value = JSON_PROPERTY_NAME, required = true) String name, + @JsonProperty(value = JSON_PROPERTY_TYPE, required = true) TypeEnum type, + @JsonProperty(value = JSON_PROPERTY_UPDATED_AT, required = true) + OffsetDateTime updatedAt, + @JsonProperty(value = JSON_PROPERTY_TAGS, required = true) List tags, + @JsonProperty(value = JSON_PROPERTY_PENDING_APPROVAL_REQUEST, required = true) + ContactApprovalRequest pendingApprovalRequest) { + this.id = id; + this.name = name; + this.type = type; + this.updatedAt = updatedAt; + this.tags = tags; + this.pendingApprovalRequest = pendingApprovalRequest; + } + + public Contact id(@jakarta.annotation.Nonnull UUID id) { + this.id = id; + return this; + } + + /** + * The unique identifier of the contact + * + * @return id + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_ID) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public UUID getId() { + return id; + } + + @JsonProperty(JSON_PROPERTY_ID) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setId(@jakarta.annotation.Nonnull UUID id) { + this.id = id; + } + + public Contact name(@jakarta.annotation.Nonnull String name) { + this.name = name; + return this; + } + + /** + * The contact name, unique across the workspace + * + * @return name + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_NAME) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public String getName() { + return name; + } + + @JsonProperty(JSON_PROPERTY_NAME) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setName(@jakarta.annotation.Nonnull String name) { + this.name = name; + } + + public Contact type(@jakarta.annotation.Nonnull TypeEnum type) { + this.type = type; + return this; + } + + /** + * Whether the contact is an external party or an account the workspace owns elsewhere + * + * @return type + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_TYPE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public TypeEnum getType() { + return type; + } + + @JsonProperty(JSON_PROPERTY_TYPE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setType(@jakarta.annotation.Nonnull TypeEnum type) { + this.type = type; + } + + public Contact accessControl(@jakarta.annotation.Nullable AccessControlEnum accessControl) { + this.accessControl = accessControl; + return this; + } + + /** + * The access control applied to the contact. Absent when none is set. + * + * @return accessControl + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_ACCESS_CONTROL) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public AccessControlEnum getAccessControl() { + return accessControl; + } + + @JsonProperty(JSON_PROPERTY_ACCESS_CONTROL) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccessControl(@jakarta.annotation.Nullable AccessControlEnum accessControl) { + this.accessControl = accessControl; + } + + public Contact notes(@jakarta.annotation.Nullable String notes) { + this.notes = notes; + return this; + } + + /** + * Free-text notes on the contact. Absent when none are set. + * + * @return notes + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_NOTES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getNotes() { + return notes; + } + + @JsonProperty(JSON_PROPERTY_NOTES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setNotes(@jakarta.annotation.Nullable String notes) { + this.notes = notes; + } + + public Contact externalRefId(@jakarta.annotation.Nullable String externalRefId) { + this.externalRefId = externalRefId; + return this; + } + + /** + * A customer-supplied reference id for the contact. Absent when none is set. + * + * @return externalRefId + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_EXTERNAL_REF_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getExternalRefId() { + return externalRefId; + } + + @JsonProperty(JSON_PROPERTY_EXTERNAL_REF_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setExternalRefId(@jakarta.annotation.Nullable String externalRefId) { + this.externalRefId = externalRefId; + } + + public Contact containerId(@jakarta.annotation.Nullable UUID containerId) { + this.containerId = containerId; + return this; + } + + /** + * The container holding the contact. Absent when the contact sits at the root. + * + * @return containerId + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_CONTAINER_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public UUID getContainerId() { + return containerId; + } + + @JsonProperty(JSON_PROPERTY_CONTAINER_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setContainerId(@jakarta.annotation.Nullable UUID containerId) { + this.containerId = containerId; + } + + public Contact updatedAt(@jakarta.annotation.Nonnull OffsetDateTime updatedAt) { + this.updatedAt = updatedAt; + return this; + } + + /** + * The date and time the contact was last modified, in ISO-8601 + * + * @return updatedAt + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_UPDATED_AT) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + + @JsonProperty(JSON_PROPERTY_UPDATED_AT) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setUpdatedAt(@jakarta.annotation.Nonnull OffsetDateTime updatedAt) { + this.updatedAt = updatedAt; + } + + public Contact archivedAt(@jakarta.annotation.Nullable OffsetDateTime archivedAt) { + this.archivedAt = archivedAt; + return this; + } + + /** + * The date and time the contact was archived, in ISO-8601. Absent for live contacts, so this + * only carries a value when the request passed archived=true. + * + * @return archivedAt + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_ARCHIVED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public OffsetDateTime getArchivedAt() { + return archivedAt; + } + + @JsonProperty(JSON_PROPERTY_ARCHIVED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setArchivedAt(@jakarta.annotation.Nullable OffsetDateTime archivedAt) { + this.archivedAt = archivedAt; + } + + public Contact tags(@jakarta.annotation.Nonnull List tags) { + this.tags = tags; + return this; + } + + public Contact addTagsItem(ContactTag tagsItem) { + if (this.tags == null) { + this.tags = new ArrayList<>(); + } + this.tags.add(tagsItem); + return this; + } + + /** + * The tags attached to the contact + * + * @return tags + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_TAGS) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public List getTags() { + return tags; + } + + @JsonProperty(JSON_PROPERTY_TAGS) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setTags(@jakarta.annotation.Nonnull List tags) { + this.tags = tags; + } + + public Contact pendingApprovalRequest( + @jakarta.annotation.Nullable ContactApprovalRequest pendingApprovalRequest) { + this.pendingApprovalRequest = pendingApprovalRequest; + return this; + } + + /** + * Get pendingApprovalRequest + * + * @return pendingApprovalRequest + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_PENDING_APPROVAL_REQUEST) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public ContactApprovalRequest getPendingApprovalRequest() { + return pendingApprovalRequest; + } + + @JsonProperty(JSON_PROPERTY_PENDING_APPROVAL_REQUEST) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setPendingApprovalRequest( + @jakarta.annotation.Nullable ContactApprovalRequest pendingApprovalRequest) { + this.pendingApprovalRequest = pendingApprovalRequest; + } + + /** Return true if this Contact object is equal to o. */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Contact contact = (Contact) o; + return Objects.equals(this.id, contact.id) + && Objects.equals(this.name, contact.name) + && Objects.equals(this.type, contact.type) + && Objects.equals(this.accessControl, contact.accessControl) + && Objects.equals(this.notes, contact.notes) + && Objects.equals(this.externalRefId, contact.externalRefId) + && Objects.equals(this.containerId, contact.containerId) + && Objects.equals(this.updatedAt, contact.updatedAt) + && Objects.equals(this.archivedAt, contact.archivedAt) + && Objects.equals(this.tags, contact.tags) + && Objects.equals(this.pendingApprovalRequest, contact.pendingApprovalRequest); + } + + @Override + public int hashCode() { + return Objects.hash( + id, + name, + type, + accessControl, + notes, + externalRefId, + containerId, + updatedAt, + archivedAt, + tags, + pendingApprovalRequest); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class Contact {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" accessControl: ").append(toIndentedString(accessControl)).append("\n"); + sb.append(" notes: ").append(toIndentedString(notes)).append("\n"); + sb.append(" externalRefId: ").append(toIndentedString(externalRefId)).append("\n"); + sb.append(" containerId: ").append(toIndentedString(containerId)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append(" archivedAt: ").append(toIndentedString(archivedAt)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" pendingApprovalRequest: ") + .append(toIndentedString(pendingApprovalRequest)) + .append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + /** + * Convert the instance into URL query string. + * + * @return URL query string + */ + public String toUrlQueryString() { + return toUrlQueryString(null); + } + + /** + * Convert the instance into URL query string. + * + * @param prefix prefix of the query string + * @return URL query string + */ + public String toUrlQueryString(String prefix) { + String suffix = ""; + String containerSuffix = ""; + String containerPrefix = ""; + if (prefix == null) { + // style=form, explode=true, e.g. /pet?name=cat&type=manx + prefix = ""; + } else { + // deepObject style e.g. /pet?id[name]=cat&id[type]=manx + prefix = prefix + "["; + suffix = "]"; + containerSuffix = "]"; + containerPrefix = "["; + } + + StringJoiner joiner = new StringJoiner("&"); + + // add `id` to the URL query string + if (getId() != null) { + joiner.add( + String.format( + "%sid%s=%s", + prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getId())))); + } + + // add `name` to the URL query string + if (getName() != null) { + joiner.add( + String.format( + "%sname%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getName())))); + } + + // add `type` to the URL query string + if (getType() != null) { + joiner.add( + String.format( + "%stype%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getType())))); + } + + // add `accessControl` to the URL query string + if (getAccessControl() != null) { + joiner.add( + String.format( + "%saccessControl%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getAccessControl())))); + } + + // add `notes` to the URL query string + if (getNotes() != null) { + joiner.add( + String.format( + "%snotes%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getNotes())))); + } + + // add `externalRefId` to the URL query string + if (getExternalRefId() != null) { + joiner.add( + String.format( + "%sexternalRefId%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getExternalRefId())))); + } + + // add `containerId` to the URL query string + if (getContainerId() != null) { + joiner.add( + String.format( + "%scontainerId%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getContainerId())))); + } + + // add `updatedAt` to the URL query string + if (getUpdatedAt() != null) { + joiner.add( + String.format( + "%supdatedAt%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getUpdatedAt())))); + } + + // add `archivedAt` to the URL query string + if (getArchivedAt() != null) { + joiner.add( + String.format( + "%sarchivedAt%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getArchivedAt())))); + } + + // add `tags` to the URL query string + if (getTags() != null) { + for (int i = 0; i < getTags().size(); i++) { + if (getTags().get(i) != null) { + joiner.add( + getTags() + .get(i) + .toUrlQueryString( + String.format( + "%stags%s%s", + prefix, + suffix, + "".equals(suffix) + ? "" + : String.format( + "%s%d%s", + containerPrefix, + i, + containerSuffix)))); + } + } + } + + // add `pendingApprovalRequest` to the URL query string + if (getPendingApprovalRequest() != null) { + joiner.add( + getPendingApprovalRequest() + .toUrlQueryString(prefix + "pendingApprovalRequest" + suffix)); + } + + return joiner.toString(); + } +} diff --git a/src/main/java/com/fireblocks/sdk/model/ContactApprovalRequest.java b/src/main/java/com/fireblocks/sdk/model/ContactApprovalRequest.java new file mode 100644 index 00000000..a3bb79cf --- /dev/null +++ b/src/main/java/com/fireblocks/sdk/model/ContactApprovalRequest.java @@ -0,0 +1,194 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fireblocks.sdk.ApiClient; +import java.util.Objects; +import java.util.StringJoiner; + +/** + * An approval request awaiting a quorum decision. Null when none is open. Carried both by a + * contact, for a quorum-gated write on the contact itself, and by an individual tag, for a change + * to the tag's own definition. An attach or detach of that tag to this contact is carried by + * the tag's `pendingAttachment` instead. + */ +@JsonPropertyOrder({ + ContactApprovalRequest.JSON_PROPERTY_ID, + ContactApprovalRequest.JSON_PROPERTY_TYPE +}) +@jakarta.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.14.0") +public class ContactApprovalRequest { + public static final String JSON_PROPERTY_ID = "id"; + @jakarta.annotation.Nonnull private String id; + + public static final String JSON_PROPERTY_TYPE = "type"; + @jakarta.annotation.Nonnull private String type; + + public ContactApprovalRequest() {} + + @JsonCreator + public ContactApprovalRequest( + @JsonProperty(value = JSON_PROPERTY_ID, required = true) String id, + @JsonProperty(value = JSON_PROPERTY_TYPE, required = true) String type) { + this.id = id; + this.type = type; + } + + public ContactApprovalRequest id(@jakarta.annotation.Nonnull String id) { + this.id = id; + return this; + } + + /** + * The approval request identifier + * + * @return id + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_ID) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public String getId() { + return id; + } + + @JsonProperty(JSON_PROPERTY_ID) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setId(@jakarta.annotation.Nonnull String id) { + this.id = id; + } + + public ContactApprovalRequest type(@jakarta.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * The operation awaiting approval. Deliberately not an enumeration: the set is open across the + * surfaces that carry one, and includes contact operations such as CREATE_CONTACT and + * DELETE_CONTACT as well as changes to a tag itself. + * + * @return type + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_TYPE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public String getType() { + return type; + } + + @JsonProperty(JSON_PROPERTY_TYPE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setType(@jakarta.annotation.Nonnull String type) { + this.type = type; + } + + /** Return true if this ContactApprovalRequest object is equal to o. */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ContactApprovalRequest contactApprovalRequest = (ContactApprovalRequest) o; + return Objects.equals(this.id, contactApprovalRequest.id) + && Objects.equals(this.type, contactApprovalRequest.type); + } + + @Override + public int hashCode() { + return Objects.hash(id, type); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ContactApprovalRequest {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + /** + * Convert the instance into URL query string. + * + * @return URL query string + */ + public String toUrlQueryString() { + return toUrlQueryString(null); + } + + /** + * Convert the instance into URL query string. + * + * @param prefix prefix of the query string + * @return URL query string + */ + public String toUrlQueryString(String prefix) { + String suffix = ""; + String containerSuffix = ""; + String containerPrefix = ""; + if (prefix == null) { + // style=form, explode=true, e.g. /pet?name=cat&type=manx + prefix = ""; + } else { + // deepObject style e.g. /pet?id[name]=cat&id[type]=manx + prefix = prefix + "["; + suffix = "]"; + containerSuffix = "]"; + containerPrefix = "["; + } + + StringJoiner joiner = new StringJoiner("&"); + + // add `id` to the URL query string + if (getId() != null) { + joiner.add( + String.format( + "%sid%s=%s", + prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getId())))); + } + + // add `type` to the URL query string + if (getType() != null) { + joiner.add( + String.format( + "%stype%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getType())))); + } + + return joiner.toString(); + } +} diff --git a/src/main/java/com/fireblocks/sdk/model/ContactTag.java b/src/main/java/com/fireblocks/sdk/model/ContactTag.java new file mode 100644 index 00000000..4de343ab --- /dev/null +++ b/src/main/java/com/fireblocks/sdk/model/ContactTag.java @@ -0,0 +1,400 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fireblocks.sdk.ApiClient; +import java.util.Objects; +import java.util.StringJoiner; +import java.util.UUID; + +/** A tag attached to the contact, with the display details resolved from the tagging service. */ +@JsonPropertyOrder({ + ContactTag.JSON_PROPERTY_ID, + ContactTag.JSON_PROPERTY_LABEL, + ContactTag.JSON_PROPERTY_COLOR, + ContactTag.JSON_PROPERTY_DESCRIPTION, + ContactTag.JSON_PROPERTY_IS_PROTECTED, + ContactTag.JSON_PROPERTY_PENDING_APPROVAL_REQUEST, + ContactTag.JSON_PROPERTY_PENDING_ATTACHMENT +}) +@jakarta.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.14.0") +public class ContactTag { + public static final String JSON_PROPERTY_ID = "id"; + @jakarta.annotation.Nonnull private UUID id; + + public static final String JSON_PROPERTY_LABEL = "label"; + @jakarta.annotation.Nonnull private String label; + + public static final String JSON_PROPERTY_COLOR = "color"; + @jakarta.annotation.Nullable private String color; + + public static final String JSON_PROPERTY_DESCRIPTION = "description"; + @jakarta.annotation.Nullable private String description; + + public static final String JSON_PROPERTY_IS_PROTECTED = "isProtected"; + @jakarta.annotation.Nonnull private Boolean isProtected; + + public static final String JSON_PROPERTY_PENDING_APPROVAL_REQUEST = "pendingApprovalRequest"; + @jakarta.annotation.Nullable private ContactApprovalRequest pendingApprovalRequest; + + public static final String JSON_PROPERTY_PENDING_ATTACHMENT = "pendingAttachment"; + @jakarta.annotation.Nullable private ContactTagAttachmentPending pendingAttachment; + + public ContactTag() {} + + @JsonCreator + public ContactTag( + @JsonProperty(value = JSON_PROPERTY_ID, required = true) UUID id, + @JsonProperty(value = JSON_PROPERTY_LABEL, required = true) String label, + @JsonProperty(value = JSON_PROPERTY_IS_PROTECTED, required = true) Boolean isProtected, + @JsonProperty(value = JSON_PROPERTY_PENDING_APPROVAL_REQUEST, required = true) + ContactApprovalRequest pendingApprovalRequest, + @JsonProperty(value = JSON_PROPERTY_PENDING_ATTACHMENT, required = true) + ContactTagAttachmentPending pendingAttachment) { + this.id = id; + this.label = label; + this.isProtected = isProtected; + this.pendingApprovalRequest = pendingApprovalRequest; + this.pendingAttachment = pendingAttachment; + } + + public ContactTag id(@jakarta.annotation.Nonnull UUID id) { + this.id = id; + return this; + } + + /** + * The unique identifier of the tag + * + * @return id + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_ID) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public UUID getId() { + return id; + } + + @JsonProperty(JSON_PROPERTY_ID) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setId(@jakarta.annotation.Nonnull UUID id) { + this.id = id; + } + + public ContactTag label(@jakarta.annotation.Nonnull String label) { + this.label = label; + return this; + } + + /** + * The tag label + * + * @return label + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_LABEL) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public String getLabel() { + return label; + } + + @JsonProperty(JSON_PROPERTY_LABEL) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setLabel(@jakarta.annotation.Nonnull String label) { + this.label = label; + } + + public ContactTag color(@jakarta.annotation.Nullable String color) { + this.color = color; + return this; + } + + /** + * The tag color in hex format. Absent when the tag has none. + * + * @return color + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_COLOR) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getColor() { + return color; + } + + @JsonProperty(JSON_PROPERTY_COLOR) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setColor(@jakarta.annotation.Nullable String color) { + this.color = color; + } + + public ContactTag description(@jakarta.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description for the tag. Absent when the tag has none. + * + * @return description + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_DESCRIPTION) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getDescription() { + return description; + } + + @JsonProperty(JSON_PROPERTY_DESCRIPTION) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setDescription(@jakarta.annotation.Nullable String description) { + this.description = description; + } + + public ContactTag isProtected(@jakarta.annotation.Nonnull Boolean isProtected) { + this.isProtected = isProtected; + return this; + } + + /** + * Whether the tag is protected, meaning changes to it and to its attachments are + * approval-gated. + * + * @return isProtected + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_IS_PROTECTED) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public Boolean getIsProtected() { + return isProtected; + } + + @JsonProperty(JSON_PROPERTY_IS_PROTECTED) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setIsProtected(@jakarta.annotation.Nonnull Boolean isProtected) { + this.isProtected = isProtected; + } + + public ContactTag pendingApprovalRequest( + @jakarta.annotation.Nullable ContactApprovalRequest pendingApprovalRequest) { + this.pendingApprovalRequest = pendingApprovalRequest; + return this; + } + + /** + * Get pendingApprovalRequest + * + * @return pendingApprovalRequest + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_PENDING_APPROVAL_REQUEST) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public ContactApprovalRequest getPendingApprovalRequest() { + return pendingApprovalRequest; + } + + @JsonProperty(JSON_PROPERTY_PENDING_APPROVAL_REQUEST) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setPendingApprovalRequest( + @jakarta.annotation.Nullable ContactApprovalRequest pendingApprovalRequest) { + this.pendingApprovalRequest = pendingApprovalRequest; + } + + public ContactTag pendingAttachment( + @jakarta.annotation.Nullable ContactTagAttachmentPending pendingAttachment) { + this.pendingAttachment = pendingAttachment; + return this; + } + + /** + * Get pendingAttachment + * + * @return pendingAttachment + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_PENDING_ATTACHMENT) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public ContactTagAttachmentPending getPendingAttachment() { + return pendingAttachment; + } + + @JsonProperty(JSON_PROPERTY_PENDING_ATTACHMENT) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setPendingAttachment( + @jakarta.annotation.Nullable ContactTagAttachmentPending pendingAttachment) { + this.pendingAttachment = pendingAttachment; + } + + /** Return true if this ContactTag object is equal to o. */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ContactTag contactTag = (ContactTag) o; + return Objects.equals(this.id, contactTag.id) + && Objects.equals(this.label, contactTag.label) + && Objects.equals(this.color, contactTag.color) + && Objects.equals(this.description, contactTag.description) + && Objects.equals(this.isProtected, contactTag.isProtected) + && Objects.equals(this.pendingApprovalRequest, contactTag.pendingApprovalRequest) + && Objects.equals(this.pendingAttachment, contactTag.pendingAttachment); + } + + @Override + public int hashCode() { + return Objects.hash( + id, + label, + color, + description, + isProtected, + pendingApprovalRequest, + pendingAttachment); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ContactTag {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" label: ").append(toIndentedString(label)).append("\n"); + sb.append(" color: ").append(toIndentedString(color)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" isProtected: ").append(toIndentedString(isProtected)).append("\n"); + sb.append(" pendingApprovalRequest: ") + .append(toIndentedString(pendingApprovalRequest)) + .append("\n"); + sb.append(" pendingAttachment: ") + .append(toIndentedString(pendingAttachment)) + .append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + /** + * Convert the instance into URL query string. + * + * @return URL query string + */ + public String toUrlQueryString() { + return toUrlQueryString(null); + } + + /** + * Convert the instance into URL query string. + * + * @param prefix prefix of the query string + * @return URL query string + */ + public String toUrlQueryString(String prefix) { + String suffix = ""; + String containerSuffix = ""; + String containerPrefix = ""; + if (prefix == null) { + // style=form, explode=true, e.g. /pet?name=cat&type=manx + prefix = ""; + } else { + // deepObject style e.g. /pet?id[name]=cat&id[type]=manx + prefix = prefix + "["; + suffix = "]"; + containerSuffix = "]"; + containerPrefix = "["; + } + + StringJoiner joiner = new StringJoiner("&"); + + // add `id` to the URL query string + if (getId() != null) { + joiner.add( + String.format( + "%sid%s=%s", + prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getId())))); + } + + // add `label` to the URL query string + if (getLabel() != null) { + joiner.add( + String.format( + "%slabel%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getLabel())))); + } + + // add `color` to the URL query string + if (getColor() != null) { + joiner.add( + String.format( + "%scolor%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getColor())))); + } + + // add `description` to the URL query string + if (getDescription() != null) { + joiner.add( + String.format( + "%sdescription%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getDescription())))); + } + + // add `isProtected` to the URL query string + if (getIsProtected() != null) { + joiner.add( + String.format( + "%sisProtected%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getIsProtected())))); + } + + // add `pendingApprovalRequest` to the URL query string + if (getPendingApprovalRequest() != null) { + joiner.add( + getPendingApprovalRequest() + .toUrlQueryString(prefix + "pendingApprovalRequest" + suffix)); + } + + // add `pendingAttachment` to the URL query string + if (getPendingAttachment() != null) { + joiner.add( + getPendingAttachment().toUrlQueryString(prefix + "pendingAttachment" + suffix)); + } + + return joiner.toString(); + } +} diff --git a/src/main/java/com/fireblocks/sdk/model/ContactTagAttachmentPending.java b/src/main/java/com/fireblocks/sdk/model/ContactTagAttachmentPending.java new file mode 100644 index 00000000..e6a11472 --- /dev/null +++ b/src/main/java/com/fireblocks/sdk/model/ContactTagAttachmentPending.java @@ -0,0 +1,235 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonValue; +import com.fireblocks.sdk.ApiClient; +import java.util.Objects; +import java.util.StringJoiner; + +/** + * An attach or detach of this tag to this contact awaiting a quorum decision. Null when the + * attachment is settled. Distinct from the tag's own `pendingApprovalRequest`, which + * covers a change to the tag itself rather than to this pairing. When both are open, this is the + * one to act on from a contact: cancelling a change to the tag's own definition belongs to the + * tag surface, and `pendingApprovalRequest.id` must not be used to cancel an attachment. + */ +@JsonPropertyOrder({ + ContactTagAttachmentPending.JSON_PROPERTY_ACTION, + ContactTagAttachmentPending.JSON_PROPERTY_APPROVAL_REQUEST_ID +}) +@jakarta.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.14.0") +public class ContactTagAttachmentPending { + /** + * The operation awaiting approval. ATTACH means the tag is not yet attached; DETACH means it is + * still attached, pending removal. + */ + public enum ActionEnum { + ATTACH(String.valueOf("ATTACH")), + + DETACH(String.valueOf("DETACH")); + + private String value; + + ActionEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static ActionEnum fromValue(String value) { + for (ActionEnum b : ActionEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + } + + public static final String JSON_PROPERTY_ACTION = "action"; + @jakarta.annotation.Nonnull private ActionEnum action; + + public static final String JSON_PROPERTY_APPROVAL_REQUEST_ID = "approvalRequestId"; + @jakarta.annotation.Nullable private String approvalRequestId; + + public ContactTagAttachmentPending() {} + + @JsonCreator + public ContactTagAttachmentPending( + @JsonProperty(value = JSON_PROPERTY_ACTION, required = true) ActionEnum action) { + this.action = action; + } + + public ContactTagAttachmentPending action(@jakarta.annotation.Nonnull ActionEnum action) { + this.action = action; + return this; + } + + /** + * The operation awaiting approval. ATTACH means the tag is not yet attached; DETACH means it is + * still attached, pending removal. + * + * @return action + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_ACTION) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public ActionEnum getAction() { + return action; + } + + @JsonProperty(JSON_PROPERTY_ACTION) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setAction(@jakarta.annotation.Nonnull ActionEnum action) { + this.action = action; + } + + public ContactTagAttachmentPending approvalRequestId( + @jakarta.annotation.Nullable String approvalRequestId) { + this.approvalRequestId = approvalRequestId; + return this; + } + + /** + * The identifier of the approval request gating the operation + * + * @return approvalRequestId + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_APPROVAL_REQUEST_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getApprovalRequestId() { + return approvalRequestId; + } + + @JsonProperty(JSON_PROPERTY_APPROVAL_REQUEST_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setApprovalRequestId(@jakarta.annotation.Nullable String approvalRequestId) { + this.approvalRequestId = approvalRequestId; + } + + /** Return true if this ContactTagAttachmentPending object is equal to o. */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ContactTagAttachmentPending contactTagAttachmentPending = (ContactTagAttachmentPending) o; + return Objects.equals(this.action, contactTagAttachmentPending.action) + && Objects.equals( + this.approvalRequestId, contactTagAttachmentPending.approvalRequestId); + } + + @Override + public int hashCode() { + return Objects.hash(action, approvalRequestId); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ContactTagAttachmentPending {\n"); + sb.append(" action: ").append(toIndentedString(action)).append("\n"); + sb.append(" approvalRequestId: ") + .append(toIndentedString(approvalRequestId)) + .append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + /** + * Convert the instance into URL query string. + * + * @return URL query string + */ + public String toUrlQueryString() { + return toUrlQueryString(null); + } + + /** + * Convert the instance into URL query string. + * + * @param prefix prefix of the query string + * @return URL query string + */ + public String toUrlQueryString(String prefix) { + String suffix = ""; + String containerSuffix = ""; + String containerPrefix = ""; + if (prefix == null) { + // style=form, explode=true, e.g. /pet?name=cat&type=manx + prefix = ""; + } else { + // deepObject style e.g. /pet?id[name]=cat&id[type]=manx + prefix = prefix + "["; + suffix = "]"; + containerSuffix = "]"; + containerPrefix = "["; + } + + StringJoiner joiner = new StringJoiner("&"); + + // add `action` to the URL query string + if (getAction() != null) { + joiner.add( + String.format( + "%saction%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getAction())))); + } + + // add `approvalRequestId` to the URL query string + if (getApprovalRequestId() != null) { + joiner.add( + String.format( + "%sapprovalRequestId%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getApprovalRequestId())))); + } + + return joiner.toString(); + } +} diff --git a/src/main/java/com/fireblocks/sdk/model/ContactsPagedResponse.java b/src/main/java/com/fireblocks/sdk/model/ContactsPagedResponse.java new file mode 100644 index 00000000..101e7124 --- /dev/null +++ b/src/main/java/com/fireblocks/sdk/model/ContactsPagedResponse.java @@ -0,0 +1,251 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fireblocks.sdk.ApiClient; +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; +import java.util.StringJoiner; + +/** ContactsPagedResponse */ +@JsonPropertyOrder({ + ContactsPagedResponse.JSON_PROPERTY_DATA, + ContactsPagedResponse.JSON_PROPERTY_NEXT, + ContactsPagedResponse.JSON_PROPERTY_TOTAL +}) +@jakarta.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.14.0") +public class ContactsPagedResponse { + public static final String JSON_PROPERTY_DATA = "data"; + @jakarta.annotation.Nonnull private List data; + + public static final String JSON_PROPERTY_NEXT = "next"; + @jakarta.annotation.Nullable private String next; + + public static final String JSON_PROPERTY_TOTAL = "total"; + @jakarta.annotation.Nullable private Integer total; + + public ContactsPagedResponse() {} + + @JsonCreator + public ContactsPagedResponse( + @JsonProperty(value = JSON_PROPERTY_DATA, required = true) List data) { + this.data = data; + } + + public ContactsPagedResponse data(@jakarta.annotation.Nonnull List data) { + this.data = data; + return this; + } + + public ContactsPagedResponse addDataItem(Contact dataItem) { + if (this.data == null) { + this.data = new ArrayList<>(); + } + this.data.add(dataItem); + return this; + } + + /** + * The page of contacts + * + * @return data + */ + @jakarta.annotation.Nonnull + @JsonProperty(JSON_PROPERTY_DATA) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public List getData() { + return data; + } + + @JsonProperty(JSON_PROPERTY_DATA) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setData(@jakarta.annotation.Nonnull List data) { + this.data = data; + } + + public ContactsPagedResponse next(@jakarta.annotation.Nullable String next) { + this.next = next; + return this; + } + + /** + * Cursor to the next page; absent when the current page is the last. Opaque, and bound to the + * sort that minted it — replay it unchanged and keep sortBy/order steady across pages. + * + * @return next + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_NEXT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getNext() { + return next; + } + + @JsonProperty(JSON_PROPERTY_NEXT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setNext(@jakarta.annotation.Nullable String next) { + this.next = next; + } + + public ContactsPagedResponse total(@jakarta.annotation.Nullable Integer total) { + this.total = total; + return this; + } + + /** + * The number of contacts matching the filters, ignoring pagination. Present only when the + * request passed `includeTotal=true`; the key is absent otherwise. + * + * @return total + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_TOTAL) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Integer getTotal() { + return total; + } + + @JsonProperty(JSON_PROPERTY_TOTAL) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setTotal(@jakarta.annotation.Nullable Integer total) { + this.total = total; + } + + /** Return true if this ContactsPagedResponse object is equal to o. */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ContactsPagedResponse contactsPagedResponse = (ContactsPagedResponse) o; + return Objects.equals(this.data, contactsPagedResponse.data) + && Objects.equals(this.next, contactsPagedResponse.next) + && Objects.equals(this.total, contactsPagedResponse.total); + } + + @Override + public int hashCode() { + return Objects.hash(data, next, total); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ContactsPagedResponse {\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append(" next: ").append(toIndentedString(next)).append("\n"); + sb.append(" total: ").append(toIndentedString(total)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + /** + * Convert the instance into URL query string. + * + * @return URL query string + */ + public String toUrlQueryString() { + return toUrlQueryString(null); + } + + /** + * Convert the instance into URL query string. + * + * @param prefix prefix of the query string + * @return URL query string + */ + public String toUrlQueryString(String prefix) { + String suffix = ""; + String containerSuffix = ""; + String containerPrefix = ""; + if (prefix == null) { + // style=form, explode=true, e.g. /pet?name=cat&type=manx + prefix = ""; + } else { + // deepObject style e.g. /pet?id[name]=cat&id[type]=manx + prefix = prefix + "["; + suffix = "]"; + containerSuffix = "]"; + containerPrefix = "["; + } + + StringJoiner joiner = new StringJoiner("&"); + + // add `data` to the URL query string + if (getData() != null) { + for (int i = 0; i < getData().size(); i++) { + if (getData().get(i) != null) { + joiner.add( + getData() + .get(i) + .toUrlQueryString( + String.format( + "%sdata%s%s", + prefix, + suffix, + "".equals(suffix) + ? "" + : String.format( + "%s%d%s", + containerPrefix, + i, + containerSuffix)))); + } + } + } + + // add `next` to the URL query string + if (getNext() != null) { + joiner.add( + String.format( + "%snext%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getNext())))); + } + + // add `total` to the URL query string + if (getTotal() != null) { + joiner.add( + String.format( + "%stotal%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getTotal())))); + } + + return joiner.toString(); + } +} diff --git a/src/main/java/com/fireblocks/sdk/model/FailureReason.java b/src/main/java/com/fireblocks/sdk/model/FailureReason.java index 54bc31d1..8f2afa16 100644 --- a/src/main/java/com/fireblocks/sdk/model/FailureReason.java +++ b/src/main/java/com/fireblocks/sdk/model/FailureReason.java @@ -62,6 +62,8 @@ public enum FailureReason { AMOUNT_BELOW_MINIMUM("AMOUNT_BELOW_MINIMUM"), + AMOUNT_ABOVE_MAXIMUM("AMOUNT_ABOVE_MAXIMUM"), + PII_MISSING("PII_MISSING"), EXTERNAL_SOURCE_NOT_SUPPORTED("EXTERNAL_SOURCE_NOT_SUPPORTED"), diff --git a/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmDecision.java b/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmDecision.java index 3692c23c..36fcfab2 100644 --- a/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmDecision.java +++ b/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmDecision.java @@ -547,7 +547,7 @@ public ScreeningTRLinkMissingTrmDecision validBefore( } /** - * Unix timestamp when rule expires + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @@ -571,7 +571,7 @@ public ScreeningTRLinkMissingTrmDecision validAfter( } /** - * Unix timestamp when rule becomes valid + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ diff --git a/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmRule.java b/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmRule.java index e34fe05d..95a231fa 100644 --- a/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmRule.java +++ b/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkMissingTrmRule.java @@ -529,7 +529,7 @@ public ScreeningTRLinkMissingTrmRule validBefore( } /** - * Unix timestamp when rule expires + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @@ -553,7 +553,7 @@ public ScreeningTRLinkMissingTrmRule validAfter( } /** - * Unix timestamp when rule becomes valid + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ diff --git a/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkPostScreeningRule.java b/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkPostScreeningRule.java index 387d13a4..0026bce5 100644 --- a/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkPostScreeningRule.java +++ b/src/main/java/com/fireblocks/sdk/model/ScreeningTRLinkPostScreeningRule.java @@ -586,7 +586,7 @@ public ScreeningTRLinkPostScreeningRule validBefore( } /** - * Unix timestamp when rule expires + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @@ -610,7 +610,7 @@ public ScreeningTRLinkPostScreeningRule validAfter( } /** - * Unix timestamp when rule becomes valid + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ diff --git a/src/main/java/com/fireblocks/sdk/model/SecurityFinding.java b/src/main/java/com/fireblocks/sdk/model/SecurityFinding.java index 4f994cdc..834e676e 100644 --- a/src/main/java/com/fireblocks/sdk/model/SecurityFinding.java +++ b/src/main/java/com/fireblocks/sdk/model/SecurityFinding.java @@ -27,7 +27,6 @@ /** A single FSPM finding */ @JsonPropertyOrder({ SecurityFinding.JSON_PROPERTY_ID, - SecurityFinding.JSON_PROPERTY_TYPE, SecurityFinding.JSON_PROPERTY_STATUS, SecurityFinding.JSON_PROPERTY_SEVERITY, SecurityFinding.JSON_PROPERTY_CATEGORY, @@ -41,89 +40,6 @@ public class SecurityFinding { public static final String JSON_PROPERTY_ID = "id"; @jakarta.annotation.Nullable private UUID id; - /** The finding type identifier */ - public enum TypeEnum { - API_USER_NOT_WHITELISTED(String.valueOf("API_USER_NOT_WHITELISTED")), - - CONSOLE_IP_ALLOWLIST_DEACTIVATED(String.valueOf("CONSOLE_IP_ALLOWLIST_DEACTIVATED")), - - ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS( - String.valueOf("ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS")), - - API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY( - String.valueOf("API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY")), - - API_COSIGNER_WITH_NO_CALLBACK(String.valueOf("API_COSIGNER_WITH_NO_CALLBACK")), - - API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS( - String.valueOf("API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS")), - - NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS( - String.valueOf("NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS")), - - TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS( - String.valueOf("TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS")), - - ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS( - String.valueOf("ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS")), - - NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED( - String.valueOf("NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED")), - - OTA_ENABLED_BUT_UNUSED(String.valueOf("OTA_ENABLED_BUT_UNUSED")), - - POLICY_NOT_UPDATED_RECENTLY(String.valueOf("POLICY_NOT_UPDATED_RECENTLY")), - - RAW_SIGNING_ENABLED_BUT_UNUSED(String.valueOf("RAW_SIGNING_ENABLED_BUT_UNUSED")), - - API_USER_UNUSED_FOR_90_DAYS(String.valueOf("API_USER_UNUSED_FOR_90_DAYS")), - - UNUSED_UNLIMITED_TOKEN_ALLOWANCES(String.valueOf("UNUSED_UNLIMITED_TOKEN_ALLOWANCES")), - - UNUSED_WHITELISTED_ADDRESS(String.valueOf("UNUSED_WHITELISTED_ADDRESS")), - - TRANSACTION_REPETITION_ATTACK(String.valueOf("TRANSACTION_REPETITION_ATTACK")), - - USER_EMAIL_DOMAIN_NON_BUSINESS(String.valueOf("USER_EMAIL_DOMAIN_NON_BUSINESS")), - - OUTDATED_MOBILE_APP_VERSION(String.valueOf("OUTDATED_MOBILE_APP_VERSION")), - - SINGLE_HOP_DRAIN_ATTACK(String.valueOf("SINGLE_HOP_DRAIN_ATTACK")), - - LATERAL_MOVEMENT_DRAIN_ATTACK(String.valueOf("LATERAL_MOVEMENT_DRAIN_ATTACK")), - - WORKSPACE_USER_DORMANT_FOR_X_DAYS(String.valueOf("WORKSPACE_USER_DORMANT_FOR_X_DAYS")); - - private String value; - - TypeEnum(String value) { - this.value = value; - } - - @JsonValue - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - @JsonCreator - public static TypeEnum fromValue(String value) { - for (TypeEnum b : TypeEnum.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - } - - public static final String JSON_PROPERTY_TYPE = "type"; - @jakarta.annotation.Nullable private TypeEnum type; - /** Current status of the finding */ public enum StatusEnum { OPEN(String.valueOf("OPEN")), @@ -277,29 +193,6 @@ public void setId(@jakarta.annotation.Nullable UUID id) { this.id = id; } - public SecurityFinding type(@jakarta.annotation.Nullable TypeEnum type) { - this.type = type; - return this; - } - - /** - * The finding type identifier - * - * @return type - */ - @jakarta.annotation.Nullable - @JsonProperty(JSON_PROPERTY_TYPE) - @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public TypeEnum getType() { - return type; - } - - @JsonProperty(JSON_PROPERTY_TYPE) - @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setType(@jakarta.annotation.Nullable TypeEnum type) { - this.type = type; - } - public SecurityFinding status(@jakarta.annotation.Nullable StatusEnum status) { this.status = status; return this; @@ -426,7 +319,6 @@ public boolean equals(Object o) { } SecurityFinding securityFinding = (SecurityFinding) o; return Objects.equals(this.id, securityFinding.id) - && Objects.equals(this.type, securityFinding.type) && Objects.equals(this.status, securityFinding.status) && Objects.equals(this.severity, securityFinding.severity) && Objects.equals(this.category, securityFinding.category) @@ -436,7 +328,7 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(id, type, status, severity, category, createdAt, title); + return Objects.hash(id, status, severity, category, createdAt, title); } @Override @@ -444,7 +336,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class SecurityFinding {\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append(" severity: ").append(toIndentedString(severity)).append("\n"); sb.append(" category: ").append(toIndentedString(category)).append("\n"); @@ -505,16 +396,6 @@ public String toUrlQueryString(String prefix) { prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getId())))); } - // add `type` to the URL query string - if (getType() != null) { - joiner.add( - String.format( - "%stype%s=%s", - prefix, - suffix, - ApiClient.urlEncode(ApiClient.valueToString(getType())))); - } - // add `status` to the URL query string if (getStatus() != null) { joiner.add( diff --git a/src/main/java/com/fireblocks/sdk/model/SecurityFindingDetailed.java b/src/main/java/com/fireblocks/sdk/model/SecurityFindingDetailed.java index e8243017..e07eb4fe 100644 --- a/src/main/java/com/fireblocks/sdk/model/SecurityFindingDetailed.java +++ b/src/main/java/com/fireblocks/sdk/model/SecurityFindingDetailed.java @@ -31,7 +31,6 @@ /** A single FSPM finding, redacted to the public field set */ @JsonPropertyOrder({ SecurityFindingDetailed.JSON_PROPERTY_ID, - SecurityFindingDetailed.JSON_PROPERTY_TYPE, SecurityFindingDetailed.JSON_PROPERTY_STATUS, SecurityFindingDetailed.JSON_PROPERTY_SEVERITY, SecurityFindingDetailed.JSON_PROPERTY_CATEGORY, @@ -52,89 +51,6 @@ public class SecurityFindingDetailed { public static final String JSON_PROPERTY_ID = "id"; @jakarta.annotation.Nonnull private UUID id; - /** The finding type identifier */ - public enum TypeEnum { - API_USER_NOT_WHITELISTED(String.valueOf("API_USER_NOT_WHITELISTED")), - - CONSOLE_IP_ALLOWLIST_DEACTIVATED(String.valueOf("CONSOLE_IP_ALLOWLIST_DEACTIVATED")), - - ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS( - String.valueOf("ADMIN_TH_SET_TO_ALL_AND_MORE_THAN_2_ADMINS")), - - API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY( - String.valueOf("API_USERS_COUNT_PASSES_TH_AND_OWNER_NOT_MANDATORY")), - - API_COSIGNER_WITH_NO_CALLBACK(String.valueOf("API_COSIGNER_WITH_NO_CALLBACK")), - - API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS( - String.valueOf("API_USER_DIDNT_APPROVE_CCR_IN_X_DAYS")), - - NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS( - String.valueOf("NON_VIEWER_DIDNT_INITIATE_APPROVE_OR_SIGN_TX_OR_CCR_LAST_X_DAYS")), - - TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS( - String.valueOf("TH_SET_TO_1_AND_MORE_THAN_3_APPROVERS")), - - ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS( - String.valueOf("ADMIN_TH_SET_TO_1_AND_MORE_THAN_3_ADMINS")), - - NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED( - String.valueOf("NON_EVM_DAPP_CONNECTIONS_ENABLED_BUT_UNUSED")), - - OTA_ENABLED_BUT_UNUSED(String.valueOf("OTA_ENABLED_BUT_UNUSED")), - - POLICY_NOT_UPDATED_RECENTLY(String.valueOf("POLICY_NOT_UPDATED_RECENTLY")), - - RAW_SIGNING_ENABLED_BUT_UNUSED(String.valueOf("RAW_SIGNING_ENABLED_BUT_UNUSED")), - - API_USER_UNUSED_FOR_90_DAYS(String.valueOf("API_USER_UNUSED_FOR_90_DAYS")), - - UNUSED_UNLIMITED_TOKEN_ALLOWANCES(String.valueOf("UNUSED_UNLIMITED_TOKEN_ALLOWANCES")), - - UNUSED_WHITELISTED_ADDRESS(String.valueOf("UNUSED_WHITELISTED_ADDRESS")), - - TRANSACTION_REPETITION_ATTACK(String.valueOf("TRANSACTION_REPETITION_ATTACK")), - - USER_EMAIL_DOMAIN_NON_BUSINESS(String.valueOf("USER_EMAIL_DOMAIN_NON_BUSINESS")), - - OUTDATED_MOBILE_APP_VERSION(String.valueOf("OUTDATED_MOBILE_APP_VERSION")), - - SINGLE_HOP_DRAIN_ATTACK(String.valueOf("SINGLE_HOP_DRAIN_ATTACK")), - - LATERAL_MOVEMENT_DRAIN_ATTACK(String.valueOf("LATERAL_MOVEMENT_DRAIN_ATTACK")), - - WORKSPACE_USER_DORMANT_FOR_X_DAYS(String.valueOf("WORKSPACE_USER_DORMANT_FOR_X_DAYS")); - - private String value; - - TypeEnum(String value) { - this.value = value; - } - - @JsonValue - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - @JsonCreator - public static TypeEnum fromValue(String value) { - for (TypeEnum b : TypeEnum.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - } - - public static final String JSON_PROPERTY_TYPE = "type"; - @jakarta.annotation.Nonnull private TypeEnum type; - /** Current status of the finding */ public enum StatusEnum { OPEN(String.valueOf("OPEN")), @@ -289,7 +205,6 @@ public SecurityFindingDetailed() {} @JsonCreator public SecurityFindingDetailed( @JsonProperty(value = JSON_PROPERTY_ID, required = true) UUID id, - @JsonProperty(value = JSON_PROPERTY_TYPE, required = true) TypeEnum type, @JsonProperty(value = JSON_PROPERTY_STATUS, required = true) StatusEnum status, @JsonProperty(value = JSON_PROPERTY_SEVERITY, required = true) SeverityEnum severity, @JsonProperty(value = JSON_PROPERTY_CATEGORY, required = true) CategoryEnum category, @@ -304,7 +219,6 @@ public SecurityFindingDetailed( @JsonProperty(value = JSON_PROPERTY_MITIGATION_GUIDANCE, required = true) String mitigationGuidance) { this.id = id; - this.type = type; this.status = status; this.severity = severity; this.category = category; @@ -339,29 +253,6 @@ public void setId(@jakarta.annotation.Nonnull UUID id) { this.id = id; } - public SecurityFindingDetailed type(@jakarta.annotation.Nonnull TypeEnum type) { - this.type = type; - return this; - } - - /** - * The finding type identifier - * - * @return type - */ - @jakarta.annotation.Nonnull - @JsonProperty(JSON_PROPERTY_TYPE) - @JsonInclude(value = JsonInclude.Include.ALWAYS) - public TypeEnum getType() { - return type; - } - - @JsonProperty(JSON_PROPERTY_TYPE) - @JsonInclude(value = JsonInclude.Include.ALWAYS) - public void setType(@jakarta.annotation.Nonnull TypeEnum type) { - this.type = type; - } - public SecurityFindingDetailed status(@jakarta.annotation.Nonnull StatusEnum status) { this.status = status; return this; @@ -672,7 +563,6 @@ public boolean equals(Object o) { } SecurityFindingDetailed securityFindingDetailed = (SecurityFindingDetailed) o; return Objects.equals(this.id, securityFindingDetailed.id) - && Objects.equals(this.type, securityFindingDetailed.type) && Objects.equals(this.status, securityFindingDetailed.status) && Objects.equals(this.severity, securityFindingDetailed.severity) && Objects.equals(this.category, securityFindingDetailed.category) @@ -694,7 +584,6 @@ public boolean equals(Object o) { public int hashCode() { return Objects.hash( id, - type, status, severity, category, @@ -714,7 +603,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class SecurityFindingDetailed {\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append(" severity: ").append(toIndentedString(severity)).append("\n"); sb.append(" category: ").append(toIndentedString(category)).append("\n"); @@ -788,16 +676,6 @@ public String toUrlQueryString(String prefix) { prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getId())))); } - // add `type` to the URL query string - if (getType() != null) { - joiner.add( - String.format( - "%stype%s=%s", - prefix, - suffix, - ApiClient.urlEncode(ApiClient.valueToString(getType())))); - } - // add `status` to the URL query string if (getStatus() != null) { joiner.add( diff --git a/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmDecision.java b/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmDecision.java index 7005cf48..adaeb5ec 100644 --- a/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmDecision.java +++ b/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmDecision.java @@ -540,7 +540,7 @@ public TRLinkMissingTrmDecision validBefore( } /** - * Unix timestamp when rule expires + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @@ -563,7 +563,7 @@ public TRLinkMissingTrmDecision validAfter(@jakarta.annotation.Nullable BigDecim } /** - * Unix timestamp when rule becomes valid + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ diff --git a/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule.java b/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule.java index 3d8cd626..d1148db9 100644 --- a/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule.java +++ b/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule.java @@ -523,7 +523,7 @@ public TRLinkMissingTrmRule validBefore(@jakarta.annotation.Nullable BigDecimal } /** - * Unix timestamp when rule expires + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @@ -546,7 +546,7 @@ public TRLinkMissingTrmRule validAfter(@jakarta.annotation.Nullable BigDecimal v } /** - * Unix timestamp when rule becomes valid + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ diff --git a/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule2.java b/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule2.java index dc664d33..6bd1c174 100644 --- a/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule2.java +++ b/src/main/java/com/fireblocks/sdk/model/TRLinkMissingTrmRule2.java @@ -18,6 +18,7 @@ import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fireblocks.sdk.ApiClient; +import java.math.BigDecimal; import java.util.Objects; import java.util.StringJoiner; @@ -100,10 +101,10 @@ public class TRLinkMissingTrmRule2 { @jakarta.annotation.Nullable private Boolean isDefault; public static final String JSON_PROPERTY_VALID_BEFORE = "validBefore"; - @jakarta.annotation.Nullable private Long validBefore; + @jakarta.annotation.Nullable private BigDecimal validBefore; public static final String JSON_PROPERTY_VALID_AFTER = "validAfter"; - @jakarta.annotation.Nullable private Long validAfter; + @jakarta.annotation.Nullable private BigDecimal validAfter; public static final String JSON_PROPERTY_ACTION = "action"; @jakarta.annotation.Nonnull private TRLinkMissingTrmAction2 action; @@ -510,49 +511,49 @@ public void setIsDefault(@jakarta.annotation.Nullable Boolean isDefault) { this.isDefault = isDefault; } - public TRLinkMissingTrmRule2 validBefore(@jakarta.annotation.Nullable Long validBefore) { + public TRLinkMissingTrmRule2 validBefore(@jakarta.annotation.Nullable BigDecimal validBefore) { this.validBefore = validBefore; return this; } /** - * Rule is valid before this timestamp (milliseconds) + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @jakarta.annotation.Nullable @JsonProperty(JSON_PROPERTY_VALID_BEFORE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public Long getValidBefore() { + public BigDecimal getValidBefore() { return validBefore; } @JsonProperty(JSON_PROPERTY_VALID_BEFORE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setValidBefore(@jakarta.annotation.Nullable Long validBefore) { + public void setValidBefore(@jakarta.annotation.Nullable BigDecimal validBefore) { this.validBefore = validBefore; } - public TRLinkMissingTrmRule2 validAfter(@jakarta.annotation.Nullable Long validAfter) { + public TRLinkMissingTrmRule2 validAfter(@jakarta.annotation.Nullable BigDecimal validAfter) { this.validAfter = validAfter; return this; } /** - * Rule is valid after this timestamp (milliseconds) + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ @jakarta.annotation.Nullable @JsonProperty(JSON_PROPERTY_VALID_AFTER) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public Long getValidAfter() { + public BigDecimal getValidAfter() { return validAfter; } @JsonProperty(JSON_PROPERTY_VALID_AFTER) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setValidAfter(@jakarta.annotation.Nullable Long validAfter) { + public void setValidAfter(@jakarta.annotation.Nullable BigDecimal validAfter) { this.validAfter = validAfter; } diff --git a/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule.java b/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule.java index 049ac33f..5b47c03f 100644 --- a/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule.java +++ b/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule.java @@ -580,7 +580,7 @@ public TRLinkPostScreeningRule validBefore( } /** - * Unix timestamp when rule expires + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @@ -603,7 +603,7 @@ public TRLinkPostScreeningRule validAfter(@jakarta.annotation.Nullable BigDecima } /** - * Unix timestamp when rule becomes valid + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ diff --git a/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule2.java b/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule2.java index 4780d1e6..0279f62f 100644 --- a/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule2.java +++ b/src/main/java/com/fireblocks/sdk/model/TRLinkPostScreeningRule2.java @@ -18,6 +18,7 @@ import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fireblocks.sdk.ApiClient; +import java.math.BigDecimal; import java.util.Objects; import java.util.StringJoiner; @@ -108,10 +109,10 @@ public class TRLinkPostScreeningRule2 { @jakarta.annotation.Nullable private TRLinkTrmStatus trmStatus; public static final String JSON_PROPERTY_VALID_BEFORE = "validBefore"; - @jakarta.annotation.Nullable private Long validBefore; + @jakarta.annotation.Nullable private BigDecimal validBefore; public static final String JSON_PROPERTY_VALID_AFTER = "validAfter"; - @jakarta.annotation.Nullable private Long validAfter; + @jakarta.annotation.Nullable private BigDecimal validAfter; public static final String JSON_PROPERTY_ACTION = "action"; @jakarta.annotation.Nonnull private TRLinkPostScreeningAction action; @@ -569,49 +570,50 @@ public void setTrmStatus(@jakarta.annotation.Nullable TRLinkTrmStatus trmStatus) this.trmStatus = trmStatus; } - public TRLinkPostScreeningRule2 validBefore(@jakarta.annotation.Nullable Long validBefore) { + public TRLinkPostScreeningRule2 validBefore( + @jakarta.annotation.Nullable BigDecimal validBefore) { this.validBefore = validBefore; return this; } /** - * Rule is valid before this timestamp (milliseconds) + * Rule expires once this many seconds have elapsed since the wait/screening step started * * @return validBefore */ @jakarta.annotation.Nullable @JsonProperty(JSON_PROPERTY_VALID_BEFORE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public Long getValidBefore() { + public BigDecimal getValidBefore() { return validBefore; } @JsonProperty(JSON_PROPERTY_VALID_BEFORE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setValidBefore(@jakarta.annotation.Nullable Long validBefore) { + public void setValidBefore(@jakarta.annotation.Nullable BigDecimal validBefore) { this.validBefore = validBefore; } - public TRLinkPostScreeningRule2 validAfter(@jakarta.annotation.Nullable Long validAfter) { + public TRLinkPostScreeningRule2 validAfter(@jakarta.annotation.Nullable BigDecimal validAfter) { this.validAfter = validAfter; return this; } /** - * Rule is valid after this timestamp (milliseconds) + * Rule applies only after this many seconds have elapsed since the wait/screening step started * * @return validAfter */ @jakarta.annotation.Nullable @JsonProperty(JSON_PROPERTY_VALID_AFTER) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public Long getValidAfter() { + public BigDecimal getValidAfter() { return validAfter; } @JsonProperty(JSON_PROPERTY_VALID_AFTER) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setValidAfter(@jakarta.annotation.Nullable Long validAfter) { + public void setValidAfter(@jakarta.annotation.Nullable BigDecimal validAfter) { this.validAfter = validAfter; } diff --git a/src/main/java/com/fireblocks/sdk/model/TransactionRequest.java b/src/main/java/com/fireblocks/sdk/model/TransactionRequest.java index 4d9ad9c1..e091d6e6 100644 --- a/src/main/java/com/fireblocks/sdk/model/TransactionRequest.java +++ b/src/main/java/com/fireblocks/sdk/model/TransactionRequest.java @@ -29,6 +29,7 @@ TransactionRequest.JSON_PROPERTY_OPERATION, TransactionRequest.JSON_PROPERTY_NOTE, TransactionRequest.JSON_PROPERTY_EXTERNAL_TX_ID, + TransactionRequest.JSON_PROPERTY_FEE_CURRENCY, TransactionRequest.JSON_PROPERTY_ASSET_ID, TransactionRequest.JSON_PROPERTY_SOURCE, TransactionRequest.JSON_PROPERTY_DESTINATION, @@ -72,6 +73,9 @@ public class TransactionRequest { public static final String JSON_PROPERTY_EXTERNAL_TX_ID = "externalTxId"; @jakarta.annotation.Nullable private String externalTxId; + public static final String JSON_PROPERTY_FEE_CURRENCY = "feeCurrency"; + @jakarta.annotation.Nullable private String feeCurrency; + public static final String JSON_PROPERTY_ASSET_ID = "assetId"; @jakarta.annotation.Nullable private String assetId; @@ -272,6 +276,33 @@ public void setExternalTxId(@jakarta.annotation.Nullable String externalTxId) { this.externalTxId = externalTxId; } + public TransactionRequest feeCurrency(@jakarta.annotation.Nullable String feeCurrency) { + this.feeCurrency = feeCurrency; + return this; + } + + /** + * For Tempo-based transactions only, the asset used to pay the transaction's network fee, + * as an asset ID ([see supported + * assets](https://developers.fireblocks.com/api-reference/blockchains-&-assets/list-assets)). + * For any other blockchain, this value is ignored. This feature is currently in beta and might + * be subject to changes. + * + * @return feeCurrency + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_FEE_CURRENCY) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getFeeCurrency() { + return feeCurrency; + } + + @JsonProperty(JSON_PROPERTY_FEE_CURRENCY) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setFeeCurrency(@jakarta.annotation.Nullable String feeCurrency) { + this.feeCurrency = feeCurrency; + } + public TransactionRequest assetId(@jakarta.annotation.Nullable String assetId) { this.assetId = assetId; return this; @@ -961,6 +992,7 @@ public boolean equals(Object o) { return Objects.equals(this.operation, transactionRequest.operation) && Objects.equals(this.note, transactionRequest.note) && Objects.equals(this.externalTxId, transactionRequest.externalTxId) + && Objects.equals(this.feeCurrency, transactionRequest.feeCurrency) && Objects.equals(this.assetId, transactionRequest.assetId) && Objects.equals(this.source, transactionRequest.source) && Objects.equals(this.destination, transactionRequest.destination) @@ -996,6 +1028,7 @@ public int hashCode() { operation, note, externalTxId, + feeCurrency, assetId, source, destination, @@ -1032,6 +1065,7 @@ public String toString() { sb.append(" operation: ").append(toIndentedString(operation)).append("\n"); sb.append(" note: ").append(toIndentedString(note)).append("\n"); sb.append(" externalTxId: ").append(toIndentedString(externalTxId)).append("\n"); + sb.append(" feeCurrency: ").append(toIndentedString(feeCurrency)).append("\n"); sb.append(" assetId: ").append(toIndentedString(assetId)).append("\n"); sb.append(" source: ").append(toIndentedString(source)).append("\n"); sb.append(" destination: ").append(toIndentedString(destination)).append("\n"); @@ -1144,6 +1178,16 @@ public String toUrlQueryString(String prefix) { ApiClient.urlEncode(ApiClient.valueToString(getExternalTxId())))); } + // add `feeCurrency` to the URL query string + if (getFeeCurrency() != null) { + joiner.add( + String.format( + "%sfeeCurrency%s=%s", + prefix, + suffix, + ApiClient.urlEncode(ApiClient.valueToString(getFeeCurrency())))); + } + // add `assetId` to the URL query string if (getAssetId() != null) { joiner.add( diff --git a/src/test/java/com/fireblocks/sdk/FireblocksTest.java b/src/test/java/com/fireblocks/sdk/FireblocksTest.java index 6372c04a..96774e70 100644 --- a/src/test/java/com/fireblocks/sdk/FireblocksTest.java +++ b/src/test/java/com/fireblocks/sdk/FireblocksTest.java @@ -421,6 +421,14 @@ public void testGetConsoleUserApi() { Assert.assertSame(consoleUser, fireblocks.consoleUser()); } + @Test + public void testGetContactsApi() { + setupFireblocks(true, null, null); + ContactsApi contacts = fireblocks.contacts(); + Assert.assertNotNull(contacts); + Assert.assertSame(contacts, fireblocks.contacts()); + } + @Test public void testGetContractInteractionsApi() { setupFireblocks(true, null, null); diff --git a/src/test/java/com/fireblocks/sdk/api/ContactsApiTest.java b/src/test/java/com/fireblocks/sdk/api/ContactsApiTest.java new file mode 100644 index 00000000..510c2882 --- /dev/null +++ b/src/test/java/com/fireblocks/sdk/api/ContactsApiTest.java @@ -0,0 +1,70 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.api; + + +import com.fireblocks.sdk.ApiResponse; +import com.fireblocks.sdk.model.ContactsPagedResponse; +import java.util.List; +import java.util.UUID; +import java.util.concurrent.CompletableFuture; +import org.junit.Ignore; +import org.junit.Test; + +/** API tests for ContactsApi */ +@Ignore +public class ContactsApiTest { + + private final ContactsApi api = new ContactsApi(); + + /** + * List contacts + * + *

Returns a paginated list of the workspace's address book contacts. Live contacts are + * returned by default; pass `archived=true` to return only the archived ones. + * Results are sorted by `name` ascending unless `sortBy`/`order` + * say otherwise. Because the sort column is the page cursor's leading key, a + * `pageCursor` must be replayed with the same sort it was minted under, or the + * request is rejected. Endpoint Permissions: any workspace role may read the address book. + * Writes are role-gated. + */ + @Test + public void getContactsTest() { + String pageCursor = null; + Integer pageSize = null; + Boolean includeTotal = null; + String name = null; + List types = null; + UUID containerId = null; + Boolean archived = null; + String accessControl = null; + List includeTagIds = null; + List excludeTagIds = null; + String sortBy = null; + String order = null; + CompletableFuture> response = + api.getContacts( + pageCursor, + pageSize, + includeTotal, + name, + types, + containerId, + archived, + accessControl, + includeTagIds, + excludeTagIds, + sortBy, + order); + } +} diff --git a/src/test/java/com/fireblocks/sdk/model/ContactApprovalRequestTest.java b/src/test/java/com/fireblocks/sdk/model/ContactApprovalRequestTest.java new file mode 100644 index 00000000..c303922d --- /dev/null +++ b/src/test/java/com/fireblocks/sdk/model/ContactApprovalRequestTest.java @@ -0,0 +1,39 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import org.junit.jupiter.api.Test; + +/** Model tests for ContactApprovalRequest */ +class ContactApprovalRequestTest { + private final ContactApprovalRequest model = new ContactApprovalRequest(); + + /** Model tests for ContactApprovalRequest */ + @Test + void testContactApprovalRequest() { + // TODO: test ContactApprovalRequest + } + + /** Test the property 'id' */ + @Test + void idTest() { + // TODO: test id + } + + /** Test the property 'type' */ + @Test + void typeTest() { + // TODO: test type + } +} diff --git a/src/test/java/com/fireblocks/sdk/model/ContactTagAttachmentPendingTest.java b/src/test/java/com/fireblocks/sdk/model/ContactTagAttachmentPendingTest.java new file mode 100644 index 00000000..c207264c --- /dev/null +++ b/src/test/java/com/fireblocks/sdk/model/ContactTagAttachmentPendingTest.java @@ -0,0 +1,39 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import org.junit.jupiter.api.Test; + +/** Model tests for ContactTagAttachmentPending */ +class ContactTagAttachmentPendingTest { + private final ContactTagAttachmentPending model = new ContactTagAttachmentPending(); + + /** Model tests for ContactTagAttachmentPending */ + @Test + void testContactTagAttachmentPending() { + // TODO: test ContactTagAttachmentPending + } + + /** Test the property 'action' */ + @Test + void actionTest() { + // TODO: test action + } + + /** Test the property 'approvalRequestId' */ + @Test + void approvalRequestIdTest() { + // TODO: test approvalRequestId + } +} diff --git a/src/test/java/com/fireblocks/sdk/model/ContactTagTest.java b/src/test/java/com/fireblocks/sdk/model/ContactTagTest.java new file mode 100644 index 00000000..68c7c239 --- /dev/null +++ b/src/test/java/com/fireblocks/sdk/model/ContactTagTest.java @@ -0,0 +1,69 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import org.junit.jupiter.api.Test; + +/** Model tests for ContactTag */ +class ContactTagTest { + private final ContactTag model = new ContactTag(); + + /** Model tests for ContactTag */ + @Test + void testContactTag() { + // TODO: test ContactTag + } + + /** Test the property 'id' */ + @Test + void idTest() { + // TODO: test id + } + + /** Test the property 'label' */ + @Test + void labelTest() { + // TODO: test label + } + + /** Test the property 'color' */ + @Test + void colorTest() { + // TODO: test color + } + + /** Test the property 'description' */ + @Test + void descriptionTest() { + // TODO: test description + } + + /** Test the property 'isProtected' */ + @Test + void isProtectedTest() { + // TODO: test isProtected + } + + /** Test the property 'pendingApprovalRequest' */ + @Test + void pendingApprovalRequestTest() { + // TODO: test pendingApprovalRequest + } + + /** Test the property 'pendingAttachment' */ + @Test + void pendingAttachmentTest() { + // TODO: test pendingAttachment + } +} diff --git a/src/test/java/com/fireblocks/sdk/model/ContactTest.java b/src/test/java/com/fireblocks/sdk/model/ContactTest.java new file mode 100644 index 00000000..5fc8199c --- /dev/null +++ b/src/test/java/com/fireblocks/sdk/model/ContactTest.java @@ -0,0 +1,93 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import org.junit.jupiter.api.Test; + +/** Model tests for Contact */ +class ContactTest { + private final Contact model = new Contact(); + + /** Model tests for Contact */ + @Test + void testContact() { + // TODO: test Contact + } + + /** Test the property 'id' */ + @Test + void idTest() { + // TODO: test id + } + + /** Test the property 'name' */ + @Test + void nameTest() { + // TODO: test name + } + + /** Test the property 'type' */ + @Test + void typeTest() { + // TODO: test type + } + + /** Test the property 'accessControl' */ + @Test + void accessControlTest() { + // TODO: test accessControl + } + + /** Test the property 'notes' */ + @Test + void notesTest() { + // TODO: test notes + } + + /** Test the property 'externalRefId' */ + @Test + void externalRefIdTest() { + // TODO: test externalRefId + } + + /** Test the property 'containerId' */ + @Test + void containerIdTest() { + // TODO: test containerId + } + + /** Test the property 'updatedAt' */ + @Test + void updatedAtTest() { + // TODO: test updatedAt + } + + /** Test the property 'archivedAt' */ + @Test + void archivedAtTest() { + // TODO: test archivedAt + } + + /** Test the property 'tags' */ + @Test + void tagsTest() { + // TODO: test tags + } + + /** Test the property 'pendingApprovalRequest' */ + @Test + void pendingApprovalRequestTest() { + // TODO: test pendingApprovalRequest + } +} diff --git a/src/test/java/com/fireblocks/sdk/model/ContactsPagedResponseTest.java b/src/test/java/com/fireblocks/sdk/model/ContactsPagedResponseTest.java new file mode 100644 index 00000000..088fb5fa --- /dev/null +++ b/src/test/java/com/fireblocks/sdk/model/ContactsPagedResponseTest.java @@ -0,0 +1,45 @@ +/* + * Fireblocks API + * Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain. - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com) + * + * The version of the OpenAPI document: 1.6.2 + * Contact: developers@fireblocks.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.fireblocks.sdk.model; + + +import org.junit.jupiter.api.Test; + +/** Model tests for ContactsPagedResponse */ +class ContactsPagedResponseTest { + private final ContactsPagedResponse model = new ContactsPagedResponse(); + + /** Model tests for ContactsPagedResponse */ + @Test + void testContactsPagedResponse() { + // TODO: test ContactsPagedResponse + } + + /** Test the property 'data' */ + @Test + void dataTest() { + // TODO: test data + } + + /** Test the property 'next' */ + @Test + void nextTest() { + // TODO: test next + } + + /** Test the property 'total' */ + @Test + void totalTest() { + // TODO: test total + } +} diff --git a/src/test/java/com/fireblocks/sdk/model/SecurityFindingDetailedTest.java b/src/test/java/com/fireblocks/sdk/model/SecurityFindingDetailedTest.java index 36ea122c..f4223001 100644 --- a/src/test/java/com/fireblocks/sdk/model/SecurityFindingDetailedTest.java +++ b/src/test/java/com/fireblocks/sdk/model/SecurityFindingDetailedTest.java @@ -31,12 +31,6 @@ void idTest() { // TODO: test id } - /** Test the property 'type' */ - @Test - void typeTest() { - // TODO: test type - } - /** Test the property 'status' */ @Test void statusTest() { diff --git a/src/test/java/com/fireblocks/sdk/model/SecurityFindingTest.java b/src/test/java/com/fireblocks/sdk/model/SecurityFindingTest.java index 886c0cc1..b0786817 100644 --- a/src/test/java/com/fireblocks/sdk/model/SecurityFindingTest.java +++ b/src/test/java/com/fireblocks/sdk/model/SecurityFindingTest.java @@ -31,12 +31,6 @@ void idTest() { // TODO: test id } - /** Test the property 'type' */ - @Test - void typeTest() { - // TODO: test type - } - /** Test the property 'status' */ @Test void statusTest() { diff --git a/src/test/java/com/fireblocks/sdk/model/TransactionRequestTest.java b/src/test/java/com/fireblocks/sdk/model/TransactionRequestTest.java index a0271319..bdc4ba0b 100644 --- a/src/test/java/com/fireblocks/sdk/model/TransactionRequestTest.java +++ b/src/test/java/com/fireblocks/sdk/model/TransactionRequestTest.java @@ -43,6 +43,12 @@ void externalTxIdTest() { // TODO: test externalTxId } + /** Test the property 'feeCurrency' */ + @Test + void feeCurrencyTest() { + // TODO: test feeCurrency + } + /** Test the property 'assetId' */ @Test void assetIdTest() {