From 7e0f5bd0752cf21a69c3bf418032931225389e1d Mon Sep 17 00:00:00 2001 From: Github Actions Bot Date: Tue, 3 Dec 2024 16:22:14 +0000 Subject: [PATCH] feat: sync SDK to OpenAPI doc v2.14.0 --- OPENAPI_VERSION | 2 +- sdk.json | 1476 +++++------------ src/generated/.openapi-generator/FILES | 25 +- src/generated/api.ts | 2 +- src/generated/apis/cubixapi.ts | 510 ++++++ src/generated/apis/payouts-api.ts | 16 +- src/generated/apis/transfers-api.ts | 477 ------ src/generated/apis/wallets-api.ts | 791 --------- src/generated/index.ts | 6 +- ...usiness-account-payout-destination-type.ts | 3 +- .../models/business-destination-request.ts | 1 + ...create-business-cubix-account-response.ts} | 12 +- ...=> cubix-fiat-account-creation-request.ts} | 12 +- .../models/cubix-fiat-account-response.ts | 64 + src/generated/models/cubix-instruction.ts | 27 + .../models/generate-address-request.ts | 40 - ...=> get-business-cubix-account-response.ts} | 12 +- src/generated/models/get-wallet-response.ts | 25 - src/generated/models/index.ts | 23 +- .../models/list-addresses-response.ts | 25 - ...ss-cubix-account-instructions-response.ts} | 12 +- ... list-business-cubix-accounts-response.ts} | 12 +- .../models/list-transfers-response.ts | 25 - src/generated/models/list-wallets-response.ts | 25 - .../models/pix-fiat-account-response.ts | 9 + .../transfer-creation-request-destination.ts | 25 - .../models/transfer-creation-request.ts | 49 - .../models/transfer-detailed-transfer.ts | 103 -- .../transfer-request-blockchain-location.ts | 50 - ...transfer-request-source-wallet-location.ts | 44 - src/generated/models/wallet.ts | 55 - 31 files changed, 1113 insertions(+), 2845 deletions(-) create mode 100644 src/generated/apis/cubixapi.ts delete mode 100644 src/generated/apis/wallets-api.ts rename src/generated/models/{create-wallet-response.ts => create-business-cubix-account-response.ts} (51%) rename src/generated/models/{wallet-creation-request.ts => cubix-fiat-account-creation-request.ts} (66%) create mode 100644 src/generated/models/cubix-fiat-account-response.ts create mode 100644 src/generated/models/cubix-instruction.ts delete mode 100644 src/generated/models/generate-address-request.ts rename src/generated/models/{generate-address-response.ts => get-business-cubix-account-response.ts} (51%) delete mode 100644 src/generated/models/get-wallet-response.ts delete mode 100644 src/generated/models/list-addresses-response.ts rename src/generated/models/{create-transfer-response.ts => list-business-cubix-account-instructions-response.ts} (51%) rename src/generated/models/{get-transfer-response.ts => list-business-cubix-accounts-response.ts} (50%) delete mode 100644 src/generated/models/list-transfers-response.ts delete mode 100644 src/generated/models/list-wallets-response.ts delete mode 100644 src/generated/models/transfer-creation-request-destination.ts delete mode 100644 src/generated/models/transfer-creation-request.ts delete mode 100644 src/generated/models/transfer-detailed-transfer.ts delete mode 100644 src/generated/models/transfer-request-blockchain-location.ts delete mode 100644 src/generated/models/transfer-request-source-wallet-location.ts delete mode 100644 src/generated/models/wallet.ts diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index d8b6989..edcfe40 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -2.12.0 +2.14.0 diff --git a/sdk.json b/sdk.json index b8c276b..ddb82a9 100644 --- a/sdk.json +++ b/sdk.json @@ -6,7 +6,7 @@ } ], "info": { - "version": "2.12.0", + "version": "2.14.0", "title": "All Circle APIs", "description": "Circle's General, Core Functionality, Payments, Payouts, Accounts, and Crypto Payments APIs bundled into one OpenAPI Specification." }, @@ -83,6 +83,10 @@ "name": "CBIT", "description": "Create and get information on CBIT accounts." }, + { + "name": "CUBIX", + "description": "Create and get information on CUBIX accounts." + }, { "name": "PIX", "description": "Create and get information on PIX accounts." @@ -1084,9 +1088,11 @@ "description": "WELLS FARGO BANK, NA ****0010", "trackingRef": "CIR13FB13A", "transferTypesInfo": { - "currencies": ["USD"], - "additionalProperties": { - "transactionLimits": 100000 + "wire": { + "currencies": ["USD", "EUR"] + }, + "rtgs": { + "currencies": ["USD"] } }, "fingerprint": "eb170539-9e1c-4e92-bf4f-1d09534fdca2", @@ -1164,9 +1170,11 @@ "description": "WELLS FARGO BANK, NA ****0010", "trackingRef": "CIR13FB13A", "transferTypesInfo": { - "currencies": ["USD"], - "additionalProperties": { - "transactionLimits": 100000 + "wire": { + "currencies": ["USD", "EUR"] + }, + "rtgs": { + "currencies": ["USD"] } }, "fingerprint": "eb170539-9e1c-4e92-bf4f-1d09534fdca2", @@ -1245,9 +1253,11 @@ "description": "WELLS FARGO BANK, NA ****0010", "trackingRef": "CIR13FB13A", "transferTypesInfo": { - "currencies": ["USD"], - "additionalProperties": { - "transactionLimits": 100000 + "wire": { + "currencies": ["USD", "EUR"] + }, + "rtgs": { + "currencies": ["USD"] } }, "fingerprint": "eb170539-9e1c-4e92-bf4f-1d09534fdca2", @@ -1406,9 +1416,8 @@ "trackingRef": "CIR25XSXT8", "walletAddress": "0x7d8da35e03ef3a5ec5d5edbb961ef399dfb42d1e", "transferTypesInfo": { - "currencies": ["USD"], - "additionalProperties": { - "transactionLimits": 100000 + "cbit": { + "currencies": ["USD"] } }, "createDate": "2020-04-10T02:13:30.000Z", @@ -1468,9 +1477,8 @@ "trackingRef": "CIR25XSXT8", "walletAddress": "0x7d8da35e03ef3a5ec5d5edbb961ef399dfb42d1e", "transferTypesInfo": { - "currencies": ["USD"], - "additionalProperties": { - "transactionLimits": 100000 + "cbit": { + "currencies": ["USD"] } }, "createDate": "2020-04-10T02:13:30.000Z", @@ -1531,9 +1539,8 @@ "trackingRef": "CIR25XSXT8", "walletAddress": "0x7d8da35e03ef3a5ec5d5edbb961ef399dfb42d1e", "transferTypesInfo": { - "currencies": ["USD"], - "additionalProperties": { - "transactionLimits": 100000 + "cbit": { + "currencies": ["USD"] } }, "createDate": "2020-04-10T02:13:30.000Z", @@ -1610,6 +1617,253 @@ } } }, + "/v1/businessAccount/banks/cubix": { + "post": { + "security": [ + { + "bearerAuth": [] + } + ], + "summary": "Create a CUBIX bank account", + "operationId": "createBusinessCubixAccount", + "tags": ["CUBIX"], + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CubixFiatAccountCreationRequest" + } + } + } + }, + "responses": { + "201": { + "description": "Successfully created a bank account for CUBIX transfers.", + "headers": { + "X-Request-Id": { + "$ref": "#/components/headers/XRequestId" + } + }, + "content": { + "application/json": { + "schema": { + "title": "CreateBusinessCubixAccountResponse", + "properties": { + "data": { + "$ref": "#/components/schemas/CubixFiatAccountResponse" + } + } + }, + "examples": { + "response": { + "value": { + "data": { + "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", + "status": "pending", + "trackingRef": "CIR25XSXT8", + "accountId": "ff2212d7-8476-4d1e-9d95-eda6455f4f54", + "transferTypesInfo": { + "cubix": { + "currencies": ["USD"] + } + }, + "createDate": "2020-04-10T02:13:30.000Z", + "updateDate": "2020-04-10T02:13:30.000Z" + } + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/NotAuthorized" + } + } + }, + "get": { + "security": [ + { + "bearerAuth": [] + } + ], + "summary": "List all CUBIX bank accounts.", + "operationId": "listBusinessCubixAccounts", + "tags": ["CUBIX"], + "responses": { + "200": { + "description": "Successfully retrieved all bank accounts for CUBIX transfers.", + "headers": { + "X-Request-Id": { + "$ref": "#/components/headers/XRequestId" + } + }, + "content": { + "application/json": { + "schema": { + "title": "ListBusinessCubixAccountsResponse", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/components/schemas/CubixFiatAccountResponse" + } + } + } + }, + "examples": { + "response": { + "value": { + "data": [ + { + "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", + "status": "pending", + "trackingRef": "CIR25XSXT8", + "accountId": "ff2212d7-8476-4d1e-9d95-eda6455f4f54", + "transferTypesInfo": { + "cubix": { + "currencies": ["USD"] + } + }, + "createDate": "2020-04-10T02:13:30.000Z", + "updateDate": "2020-04-10T02:13:30.000Z" + } + ] + } + } + } + } + } + }, + "401": { + "$ref": "#/components/responses/NotAuthorized" + } + } + } + }, + "/v1/businessAccount/banks/cubix/{id}": { + "get": { + "parameters": [ + { + "$ref": "#/components/parameters/IdPath" + } + ], + "security": [ + { + "bearerAuth": [] + } + ], + "summary": "Get a CUBIX bank account", + "operationId": "getBusinessCubixAccount", + "tags": ["CUBIX"], + "responses": { + "200": { + "description": "Successfully retrieved a bank account for CUBIX transfers.", + "headers": { + "X-Request-Id": { + "$ref": "#/components/headers/XRequestId" + } + }, + "content": { + "application/json": { + "schema": { + "title": "GetBusinessCubixAccountResponse", + "properties": { + "data": { + "$ref": "#/components/schemas/CubixFiatAccountResponse" + } + } + }, + "examples": { + "response": { + "value": { + "data": { + "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", + "status": "pending", + "trackingRef": "CIR25XSXT8", + "accountId": "ff2212d7-8476-4d1e-9d95-eda6455f4f54", + "transferTypesInfo": { + "cubix": { + "currencies": ["USD"] + } + }, + "createDate": "2020-04-10T02:13:30.000Z", + "updateDate": "2020-04-10T02:13:30.000Z" + } + } + } + } + } + } + }, + "401": { + "$ref": "#/components/responses/NotAuthorized" + }, + "404": { + "$ref": "#/components/responses/NotFound" + } + } + } + }, + "/v1/businessAccount/banks/cubix/{id}/instructions": { + "get": { + "parameters": [ + { + "$ref": "#/components/parameters/IdPath" + } + ], + "security": [ + { + "bearerAuth": [] + } + ], + "summary": "Get CUBIX instructions", + "description": "Get the CUBIX transfer instructions into the Circle bank account given your fiat account id.", + "operationId": "getBusinessCubixAccountInstructions", + "tags": ["CUBIX"], + "responses": { + "200": { + "description": "Successfully retrieved CUBIX transfer instructions for the fiat account.", + "headers": { + "X-Request-Id": { + "$ref": "#/components/headers/XRequestId" + } + }, + "content": { + "application/json": { + "schema": { + "title": "ListBusinessCubixAccountInstructionsResponse", + "properties": { + "data": { + "$ref": "#/components/schemas/CubixInstruction" + } + } + }, + "examples": { + "response": { + "value": { + "data": { + "trackingRef": "CIR25XSXT8", + "accountId": "ff2212d7-8476-4d1e-9d95-eda6455f4f54" + } + } + } + } + } + } + }, + "401": { + "$ref": "#/components/responses/NotAuthorized" + }, + "404": { + "$ref": "#/components/responses/NotFound" + } + } + } + }, "/v1/businessAccount/banks/pix": { "post": { "security": [ @@ -1655,6 +1909,11 @@ "status": "pending", "description": "BTG Pactual ****0010", "trackingRef": "CIR13FB13A", + "transferTypesInfo": { + "pix": { + "currencies": ["BRL"] + } + }, "riskEvaluation": { "decision": "approved", "reason": "3000" @@ -1716,6 +1975,11 @@ "status": "pending", "description": "BTG Pactual ****0010", "trackingRef": "CIR13FB13A", + "transferTypesInfo": { + "pix": { + "currencies": ["BRL"] + } + }, "riskEvaluation": { "decision": "approved", "reason": "3000" @@ -1778,6 +2042,11 @@ "status": "pending", "description": "BTG Pactual ****0010", "trackingRef": "CIR13FB13A", + "transferTypesInfo": { + "pix": { + "currencies": ["BRL"] + } + }, "riskEvaluation": { "decision": "approved", "reason": "3000" @@ -4776,7 +5045,7 @@ "required": false, "schema": { "type": "string", - "enum": ["wire", "cbit"] + "enum": ["wire", "cbit", "cubix"] } }, { @@ -5984,22 +6253,22 @@ } } }, - "/v1/wallets": { + "/v1/businessAccount/transfers": { "post": { "security": [ { "bearerAuth": [] } ], - "summary": "Create a wallet", - "description": "Creates an end user wallet.", - "operationId": "createWallet", - "tags": ["Wallets"], + "summary": "Create a transfer", + "description": "A transfer can be made from an existing business account to a blockchain location.", + "operationId": "createBusinessTransfer", + "tags": ["Transfers"], "requestBody": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/WalletCreationRequest" + "$ref": "#/components/schemas/BusinessTransferCreationRequest" } } } @@ -6011,555 +6280,14 @@ "$ref": "#/components/headers/XRequestId" } }, - "description": "Successfully created a wallet.", + "description": "Successfully created a transfer.", "content": { "application/json": { "schema": { - "title": "CreateWalletResponse", + "title": "CreateBusinessTransferResponse", "properties": { "data": { - "$ref": "#/components/schemas/Wallet" - } - } - }, - "examples": { - "response": { - "value": { - "data": { - "walletId": "434000", - "entityId": "fc988ed5-c129-4f70-a064-e5beb7eb8e32", - "type": "end_user_wallet", - "description": "Treasury Wallet", - "balances": [ - { - "amount": "3.14", - "currency": "USD" - } - ] - } - } - } - } - } - } - } - } - }, - "get": { - "security": [ - { - "bearerAuth": [] - } - ], - "parameters": [ - { - "$ref": "#/components/parameters/From" - }, - { - "$ref": "#/components/parameters/To" - }, - { - "$ref": "#/components/parameters/PageBefore" - }, - { - "$ref": "#/components/parameters/PageAfter" - }, - { - "$ref": "#/components/parameters/PageSize" - } - ], - "summary": "List all wallets", - "description": "Retrieves a list of a user's wallets.", - "operationId": "listWallets", - "tags": ["Wallets"], - "responses": { - "200": { - "description": "Successfully retrieved a list of wallets.", - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "content": { - "application/json": { - "schema": { - "title": "ListWalletsResponse", - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Wallet" - } - } - } - }, - "examples": { - "response": { - "value": { - "data": [ - { - "walletId": "434000", - "entityId": "fc988ed5-c129-4f70-a064-e5beb7eb8e32", - "type": "end_user_wallet", - "description": "Treasury Wallet", - "balances": [ - { - "amount": "3.14", - "currency": "USD" - } - ] - } - ] - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - } - } - } - }, - "/v1/wallets/{walletId}": { - "get": { - "parameters": [ - { - "$ref": "#/components/parameters/WalletId" - } - ], - "security": [ - { - "bearerAuth": [] - } - ], - "summary": "Get a wallet", - "operationId": "getWallet", - "tags": ["Wallets"], - "responses": { - "200": { - "description": "Successfully retrieved a wallet.", - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "content": { - "application/json": { - "schema": { - "title": "GetWalletResponse", - "properties": { - "data": { - "$ref": "#/components/schemas/Wallet" - } - } - }, - "examples": { - "response": { - "value": { - "data": { - "walletId": "434000", - "entityId": "fc988ed5-c129-4f70-a064-e5beb7eb8e32", - "type": "end_user_wallet", - "description": "Treasury Wallet", - "balances": [ - { - "amount": "3.14", - "currency": "USD" - } - ] - } - } - } - } - } - } - }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - } - }, - "/v1/wallets/{walletId}/addresses": { - "post": { - "parameters": [ - { - "$ref": "#/components/parameters/WalletId" - } - ], - "security": [ - { - "bearerAuth": [] - } - ], - "summary": "Create a blockchain address", - "description": "Generates a new blockchain address for a wallet for a given currency/chain pair. Circle may reuse addresses on blockchains that support reuse. For example, if you're requesting two addresses for depositing USD and ETH, both on Ethereum, you may see the same Ethereum address returned. Depositing cryptocurrency to a generated address will credit the associated wallet with the value of the deposit.\n", - "operationId": "generateAddress", - "tags": ["Wallets"], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/GenerateAddressRequest" - } - } - } - }, - "responses": { - "201": { - "description": "Successfully generated a new address.", - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "content": { - "application/json": { - "schema": { - "title": "GenerateAddressResponse", - "properties": { - "data": { - "$ref": "#/components/schemas/AddressObject" - } - } - }, - "examples": { - "response": { - "value": { - "data": { - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "addressTag": "123456789", - "currency": "USD", - "chain": "ALGO" - } - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "409": { - "$ref": "#/components/responses/Conflict" - } - } - }, - "get": { - "security": [ - { - "bearerAuth": [] - } - ], - "parameters": [ - { - "$ref": "#/components/parameters/WalletId" - }, - { - "$ref": "#/components/parameters/From" - }, - { - "$ref": "#/components/parameters/To" - }, - { - "$ref": "#/components/parameters/PageBefore" - }, - { - "$ref": "#/components/parameters/PageAfter" - }, - { - "$ref": "#/components/parameters/PageSize" - } - ], - "summary": "List all addresses", - "description": "Retrieves a list of addresses associated with a wallet.", - "operationId": "listAddresses", - "tags": ["Wallets"], - "responses": { - "200": { - "description": "Successfully retrieved a list of addresses.", - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "content": { - "application/json": { - "schema": { - "title": "ListAddressesResponse", - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddressObject" - } - } - } - }, - "examples": { - "response": { - "value": { - "data": [ - { - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "addressTag": "123456789", - "currency": "USD", - "chain": "ALGO" - } - ] - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - } - }, - "/v1/businessAccount/transfers": { - "post": { - "security": [ - { - "bearerAuth": [] - } - ], - "summary": "Create a transfer", - "description": "A transfer can be made from an existing business account to a blockchain location.", - "operationId": "createBusinessTransfer", - "tags": ["Transfers"], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/BusinessTransferCreationRequest" - } - } - } - }, - "responses": { - "201": { - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "description": "Successfully created a transfer.", - "content": { - "application/json": { - "schema": { - "title": "CreateBusinessTransferResponse", - "properties": { - "data": { - "$ref": "#/components/schemas/Transfer" - } - } - }, - "examples": { - "response": { - "value": { - "data": { - "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", - "source": { - "type": "wallet", - "id": "12345", - "identities": [ - { - "type": "individual", - "name": "Satoshi Nakamoto", - "addresses": [ - { - "line1": "100 Money Street", - "line2": "Suite 1", - "city": "Boston", - "district": "MA", - "postalCode": "01234", - "country": "US" - } - ] - } - ] - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "addressTag": "123456789", - "chain": "ALGO" - }, - "amount": { - "amount": "3.14", - "currency": "USD" - }, - "fees": [ - { - "amount": "10.00", - "currency": "USD", - "type": "network" - } - ], - "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", - "status": "pending", - "errorCode": "transfer_failed", - "createDate": "2020-04-10T02:13:30.000Z" - } - } - } - } - } - } - } - } - }, - "get": { - "security": [ - { - "bearerAuth": [] - } - ], - "parameters": [ - { - "$ref": "#/components/parameters/From" - }, - { - "$ref": "#/components/parameters/To" - }, - { - "$ref": "#/components/parameters/PageBefore" - }, - { - "$ref": "#/components/parameters/PageAfter" - }, - { - "$ref": "#/components/parameters/PageSize" - } - ], - "summary": "List all transfers", - "description": "Searches for transfers from your business account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided.", - "operationId": "listBusinessTransfers", - "tags": ["Transfers"], - "responses": { - "200": { - "description": "Successfully retrieved a list of transfers.", - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "content": { - "application/json": { - "schema": { - "title": "ListBusinessTransfersResponse", - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Transfer" - } - } - } - }, - "examples": { - "response": { - "value": { - "data": [ - { - "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", - "source": { - "type": "wallet", - "id": "12345", - "identities": [ - { - "type": "individual", - "name": "Satoshi Nakamoto", - "addresses": [ - { - "line1": "100 Money Street", - "line2": "Suite 1", - "city": "Boston", - "district": "MA", - "postalCode": "01234", - "country": "US" - } - ] - } - ] - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "addressTag": "123456789", - "chain": "ALGO" - }, - "amount": { - "amount": "3.14", - "currency": "USD" - }, - "fees": [ - { - "amount": "10.00", - "currency": "USD", - "type": "network" - } - ], - "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", - "status": "pending", - "errorCode": "transfer_failed", - "createDate": "2020-04-10T02:13:30.000Z" - } - ] - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/NotAuthorized" - } - } - } - }, - "/v1/businessAccount/transfers/{id}": { - "get": { - "parameters": [ - { - "$ref": "#/components/parameters/IdPath" - } - ], - "security": [ - { - "bearerAuth": [] - } - ], - "summary": "Get a transfer", - "operationId": "getBusinessTransfer", - "tags": ["Transfers"], - "responses": { - "200": { - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "description": "Successfully retrieved a transfer.", - "content": { - "application/json": { - "schema": { - "title": "GetBusinessTransferResponse", - "properties": { - "data": { - "$ref": "#/components/schemas/Transfer" + "$ref": "#/components/schemas/Transfer" } } }, @@ -6617,168 +6345,6 @@ } } } - } - }, - "/v1/transfers": { - "post": { - "security": [ - { - "bearerAuth": [] - } - ], - "summary": "Create a transfer", - "description": "A transfer can be made from an existing funded wallet to a blockchain address or another wallet.", - "operationId": "createTransfer", - "tags": ["Transfers"], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TransferCreationRequest" - }, - "examples": { - "request": { - "value": { - "idempotencyKey": "ba943ff1-ca16-49b2-ba55-1057e70ca5c7", - "source": { - "type": "wallet", - "id": "12345" - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "chain": "ETH" - }, - "amount": { - "amount": "3.14", - "currency": "USD" - } - } - }, - "travel rule": { - "value": { - "idempotencyKey": "ba943ff1-ca16-49b2-ba55-1057e70ca5c7", - "source": { - "type": "wallet", - "id": "12345", - "identities": [ - { - "type": "individual", - "name": "Satoshi Nakamoto", - "addresses": [ - { - "line1": "100 Money Street", - "line2": "Suite 1", - "city": "Boston", - "district": "MA", - "postalCode": "01234", - "country": "US" - } - ] - } - ] - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "chain": "ETH" - }, - "amount": { - "amount": "3000.00", - "currency": "USD" - } - } - } - } - } - } - }, - "responses": { - "201": { - "headers": { - "X-Request-Id": { - "$ref": "#/components/headers/XRequestId" - } - }, - "description": "Successfully created a transfer.", - "content": { - "application/json": { - "schema": { - "title": "CreateTransferResponse", - "properties": { - "data": { - "$ref": "#/components/schemas/Transfer" - } - } - }, - "examples": { - "response": { - "value": { - "data": { - "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", - "source": { - "type": "wallet", - "id": "12345" - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "chain": "ETH" - }, - "amount": { - "amount": "3.14", - "currency": "USD" - }, - "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", - "status": "pending", - "createDate": "2020-04-10T02:13:30.000Z" - } - } - }, - "travel rule": { - "value": { - "data": { - "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", - "source": { - "type": "wallet", - "id": "12345", - "identities": [ - { - "type": "individual", - "name": "Satoshi Nakamoto", - "addresses": [ - { - "line1": "100 Money Street", - "line2": "Suite 1", - "city": "Boston", - "district": "MA", - "postalCode": "01234", - "country": "US" - } - ] - } - ] - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "chain": "ETH" - }, - "amount": { - "amount": "3000.00", - "currency": "USD" - }, - "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", - "status": "pending", - "createDate": "2020-04-10T02:13:30.000Z" - } - } - } - } - } - } - } - } }, "get": { "security": [ @@ -6787,39 +6353,6 @@ } ], "parameters": [ - { - "name": "walletId", - "description": "Unique identifier for the source or destination wallet of transfers, if any. May not be used in conjunction with destinationWalletId or sourceWalletId. Useful for fetching all transfers related to a wallet.", - "in": "query", - "required": false, - "schema": { - "type": "string", - "example": "12345" - } - }, - { - "name": "sourceWalletId", - "description": "Unique identifier for the source wallet of transfers, if any.", - "in": "query", - "required": false, - "schema": { - "type": "string", - "example": "12345" - } - }, - { - "name": "destinationWalletId", - "description": "Unique identifier for the destination wallet of transfers, if any.", - "in": "query", - "required": false, - "schema": { - "type": "string", - "example": "12345" - } - }, - { - "$ref": "#/components/parameters/ReturnIdentities" - }, { "$ref": "#/components/parameters/From" }, @@ -6837,8 +6370,8 @@ } ], "summary": "List all transfers", - "description": "Searches for transfers involving the provided wallets. If no wallet ids are provided, searches all wallets associated with your Circle API account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided.", - "operationId": "listTransfers", + "description": "Searches for transfers from your business account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided.", + "operationId": "listBusinessTransfers", "tags": ["Transfers"], "responses": { "200": { @@ -6851,7 +6384,7 @@ "content": { "application/json": { "schema": { - "title": "ListTransfersResponse", + "title": "ListBusinessTransfersResponse", "properties": { "data": { "type": "array", @@ -6863,32 +6396,6 @@ }, "examples": { "response": { - "value": { - "data": [ - { - "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", - "source": { - "type": "wallet", - "id": "12345" - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "addressTag": "123456789", - "chain": "ALGO" - }, - "amount": { - "amount": "3.14", - "currency": "USD" - }, - "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", - "status": "pending", - "createDate": "2020-04-10T02:13:30.000Z" - } - ] - } - }, - "travel rule": { "value": { "data": [ { @@ -6920,11 +6427,19 @@ "chain": "ALGO" }, "amount": { - "amount": "3000.00", + "amount": "3.14", "currency": "USD" }, + "fees": [ + { + "amount": "10.00", + "currency": "USD", + "type": "network" + } + ], "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", "status": "pending", + "errorCode": "transfer_failed", "createDate": "2020-04-10T02:13:30.000Z" } ] @@ -6940,14 +6455,11 @@ } } }, - "/v1/transfers/{id}": { + "/v1/businessAccount/transfers/{id}": { "get": { "parameters": [ { "$ref": "#/components/parameters/IdPath" - }, - { - "$ref": "#/components/parameters/ReturnIdentities" } ], "security": [ @@ -6956,7 +6468,7 @@ } ], "summary": "Get a transfer", - "operationId": "getTransfer", + "operationId": "getBusinessTransfer", "tags": ["Transfers"], "responses": { "200": { @@ -6967,40 +6479,17 @@ }, "description": "Successfully retrieved a transfer.", "content": { - "application/json": { - "schema": { - "title": "GetTransferResponse", - "properties": { - "data": { - "$ref": "#/components/schemas/TransferDetailedTransfer" - } - } - }, - "examples": { - "response": { - "value": { - "data": { - "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", - "source": { - "type": "wallet", - "id": "12345" - }, - "destination": { - "type": "blockchain", - "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "chain": "ETH" - }, - "amount": { - "amount": "3.14", - "currency": "USD" - }, - "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", - "status": "pending", - "createDate": "2020-04-10T02:13:30.000Z" - } + "application/json": { + "schema": { + "title": "GetBusinessTransferResponse", + "properties": { + "data": { + "$ref": "#/components/schemas/Transfer" } - }, - "travel rule": { + } + }, + "examples": { + "response": { "value": { "data": { "id": "b8627ae8-732b-4d25-b947-1df8f4007a29", @@ -7027,14 +6516,23 @@ "destination": { "type": "blockchain", "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F", - "chain": "ETH" + "addressTag": "123456789", + "chain": "ALGO" }, "amount": { - "amount": "3000.00", + "amount": "3.14", "currency": "USD" }, + "fees": [ + { + "amount": "10.00", + "currency": "USD", + "type": "network" + } + ], "transactionHash": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63", "status": "pending", + "errorCode": "transfer_failed", "createDate": "2020-04-10T02:13:30.000Z" } } @@ -8552,6 +8050,14 @@ "description": "A map which shows transfer types supported on this account as well as additional information for each.", "additionalProperties": { "$ref": "#/components/schemas/TransferTypeInfo" + }, + "example": { + "wire": { + "currencies": ["USD", "EUR"] + }, + "rtgs": { + "currencies": ["USD"] + } } }, "fingerprint": { @@ -8883,6 +8389,11 @@ "description": "A map which shows transfer types supported on this account as well as additional information for each. For CBIT accounts this will always only show information for CBIT transfers.", "additionalProperties": { "$ref": "#/components/schemas/TransferTypeInfo" + }, + "example": { + "cbit": { + "currencies": ["USD"] + } } }, "createDate": { @@ -8922,6 +8433,86 @@ } } }, + "CubixFiatAccountResponse": { + "type": "object", + "required": [ + "id", + "status", + "trackingRef", + "accountId", + "createDate", + "updateDate", + "transferTypesInfo" + ], + "properties": { + "id": { + "$ref": "#/components/schemas/Id" + }, + "status": { + "$ref": "#/components/schemas/ExternalFiatAccountStatus" + }, + "trackingRef": { + "type": "string", + "description": "Tracking ref that needs to be set in the public description field when you send the funds to Circle's CUBIX account.", + "example": "CIR25XSXT8" + }, + "accountId": { + "type": "string", + "format": "uuid", + "description": "Your CUBIX Account ID.", + "example": "ff2212d7-8476-4d1e-9d95-eda6455f4f54" + }, + "transferTypesInfo": { + "type": "object", + "description": "A map which shows transfer types supported on this account as well as additional information for each. For CUBIX accounts this will always only show information for CUBIX transfers.", + "additionalProperties": { + "$ref": "#/components/schemas/TransferTypeInfo" + }, + "example": { + "cubix": { + "currencies": ["USD"] + } + } + }, + "createDate": { + "$ref": "#/components/schemas/UtcTimestamp" + }, + "updateDate": { + "$ref": "#/components/schemas/UtcTimestamp" + } + } + }, + "CubixFiatAccountCreationRequest": { + "type": "object", + "required": ["idempotencyKey", "accountId"], + "properties": { + "idempotencyKey": { + "$ref": "#/components/schemas/IdempotencyKey" + }, + "accountId": { + "type": "string", + "format": "uuid", + "description": "Cubix Account ID.", + "example": "ff2212d7-8476-4d1e-9d95-eda6455f4f54" + } + } + }, + "CubixInstruction": { + "type": "object", + "properties": { + "trackingRef": { + "type": "string", + "description": "Circle tracking reference that needs to be set in the CUBIX public memo field.", + "example": "CIR25XSXT8" + }, + "accountId": { + "type": "string", + "format": "uuid", + "description": "Circle account ID that needs to be set in the CUBIX account ID field.", + "example": "ff2212d7-8476-4d1e-9d95-eda6455f4f54" + } + } + }, "PixFiatAccountResponse": { "type": "object", "required": [ @@ -8931,7 +8522,8 @@ "trackingRef", "fingerprint", "createDate", - "updateDate" + "updateDate", + "transferTypesInfo" ], "properties": { "id": { @@ -8950,6 +8542,18 @@ "description": "Wire tracking ref that needs to be set in the wire reference to beneficiary field.", "example": "CIR13FB13A" }, + "transferTypesInfo": { + "type": "object", + "description": "A map which shows transfer types supported on this account as well as additional information for each. For PIX accounts this will always only show information for PIX transfers.", + "additionalProperties": { + "$ref": "#/components/schemas/TransferTypeInfo" + }, + "example": { + "pix": { + "currencies": ["BRL"] + } + } + }, "riskEvaluation": { "$ref": "#/components/schemas/RiskEvaluation" }, @@ -10940,7 +10544,7 @@ "BusinessAccountPayoutDestinationType": { "type": "string", "description": "The destination bank account type.", - "enum": ["wire", "cbit"] + "enum": ["wire", "cbit", "cubix"] }, "BankDestination": { "type": "object", @@ -11104,7 +10708,7 @@ "properties": { "type": { "type": "string", - "enum": ["wire", "cbit", "pix", "sepa", "sepa_instant"] + "enum": ["wire", "cbit", "cubix", "pix", "sepa", "sepa_instant"] }, "id": { "$ref": "#/components/schemas/Id" @@ -11641,69 +11245,6 @@ } } }, - "Wallet": { - "type": "object", - "properties": { - "walletId": { - "type": "string", - "description": "Wallet identifier. Numeric value but should be treated as a string as format may change in the future'", - "example": "434000" - }, - "entityId": { - "type": "string", - "description": "Universally unique identifier (UUID v4) of the entity that owns the wallet.", - "example": "fc988ed5-c129-4f70-a064-e5beb7eb8e32" - }, - "type": { - "type": "string", - "description": "Wallet type.", - "enum": ["end_user_wallet"] - }, - "description": { - "type": "string", - "description": "A human-friendly, non-unique identifier for a wallet.", - "example": "Treasury Wallet", - "maxLength": 255 - }, - "balances": { - "description": "A list of balances for currencies owned by the wallet.", - "type": "array", - "items": { - "$ref": "#/components/schemas/Money" - } - } - } - }, - "WalletCreationRequest": { - "type": "object", - "required": ["idempotencyKey"], - "properties": { - "idempotencyKey": { - "$ref": "#/components/schemas/IdempotencyKey" - }, - "description": { - "type": "string", - "description": "A human-friendly, non-unique identifier for a wallet.", - "example": "Treasury Wallet", - "maxLength": 255 - } - } - }, - "GenerateAddressRequest": { - "type": "object", - "required": ["idempotencyKey", "currency", "chain"], - "properties": { - "idempotencyKey": { - "$ref": "#/components/schemas/IdempotencyKey" - }, - "currency": { - "$ref": "#/components/schemas/Currency" - }, - "chain": { - "$ref": "#/components/schemas/Chain" - } - } - }, "TransferSourceBlockchainLocation": { "description": "A source blockchain address.", "type": "object", @@ -11897,118 +11438,6 @@ } } }, - "TransferRequestSourceWalletLocation": { - "type": "object", - "required": ["type", "id"], - "properties": { - "type": { - "type": "string", - "enum": ["wallet"] - }, - "id": { - "type": "string", - "description": "The id of the wallet.", - "example": "12345" - }, - "identities": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Identity" - } - } - } - }, - "TransferRequestBlockchainLocation": { - "type": "object", - "required": ["type", "address", "chain"], - "properties": { - "type": { - "type": "string", - "enum": ["blockchain"] - }, - "address": { - "type": "string", - "description": "The blockchain address.", - "example": "0x8381470ED67C3802402dbbFa0058E8871F017A6F" - }, - "addressTag": { - "$ref": "#/components/schemas/AddressTag" - }, - "chain": { - "$ref": "#/components/schemas/Chain" - } - } - }, - "TransferCreationRequest": { - "type": "object", - "required": ["idempotencyKey", "source", "destination", "amount"], - "properties": { - "idempotencyKey": { - "$ref": "#/components/schemas/IdempotencyKey" - }, - "source": { - "$ref": "#/components/schemas/TransferRequestSourceWalletLocation" - }, - "destination": { - "oneOf": [ - { - "$ref": "#/components/schemas/TransferRequestBlockchainLocation" - }, - { - "$ref": "#/components/schemas/WalletLocation" - } - ] - }, - "amount": { - "$ref": "#/components/schemas/Money" - } - } - }, - "TransferDetailedTransfer": { - "type": "object", - "description": "A transfer of funds.", - "required": ["id", "source", "destination", "amount", "status"], - "properties": { - "id": { - "$ref": "#/components/schemas/Id" - }, - "source": { - "$ref": "#/components/schemas/TransferSourceLocation" - }, - "destination": { - "$ref": "#/components/schemas/TransferDestinationLocation" - }, - "amount": { - "$ref": "#/components/schemas/Money" - }, - "fees": { - "description": "An array of fees applied to a transaction. This is only available when there is at least one non-zero fee.", - "type": "array", - "items": { - "$ref": "#/components/schemas/Fee" - } - }, - "transactionHash": { - "type": "string", - "description": "A hash that uniquely identifies the onchain transaction. This is only available where either source or destination are of type blockchain.", - "example": "0x4cebf8f90c9243a23c77e4ae20df691469e4b933b295a73376292843968f7a63" - }, - "status": { - "type": "string", - "description": "Status of the transfer. Status `pending` indicates that the transfer is in the process of running; `complete` indicates it finished successfully; `failed` indicates it failed.", - "enum": ["failed", "pending", "complete"] - }, - "errorCode": { - "$ref": "#/components/schemas/TransferErrorCode" - }, - "riskEvaluation": { - "$ref": "#/components/schemas/RiskEvaluation" - }, - "createDate": { - "$ref": "#/components/schemas/UtcTimestamp" - } - } - }, "MockChargebackCreationRequest": { "type": "object", "required": ["paymentId"], @@ -12610,27 +12039,6 @@ "format": "uuid", "example": "202ad9ce-974c-49ca-8d34-3afb7d7247ae" } - }, - "WalletId": { - "name": "walletId", - "description": "Identifier for the wallet.", - "in": "path", - "required": true, - "schema": { - "type": "string", - "example": "0123456789" - } - }, - "ReturnIdentities": { - "name": "returnIdentities", - "description": "Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`.", - "in": "query", - "required": false, - "schema": { - "type": "boolean", - "example": "true", - "default": false - } } } } diff --git a/src/generated/.openapi-generator/FILES b/src/generated/.openapi-generator/FILES index 931dd4f..d22ef94 100644 --- a/src/generated/.openapi-generator/FILES +++ b/src/generated/.openapi-generator/FILES @@ -9,6 +9,7 @@ apis/checkout-sessions-api.ts apis/crypto-address-book-api.ts apis/crypto-exchange-rates-api.ts apis/crypto-payment-intents-api.ts +apis/cubixapi.ts apis/deposits-api.ts apis/encryption-api.ts apis/health-api.ts @@ -22,7 +23,6 @@ apis/settlements-api.ts apis/stablecoins-api.ts apis/subscriptions-api.ts apis/transfers-api.ts -apis/wallets-api.ts apis/wires-api.ts base.ts common.ts @@ -84,6 +84,7 @@ models/continuous-payment-intent-creation-request.ts models/continuous-payment-intent.ts models/create-address-book-recipient-response.ts models/create-business-cbit-account-response.ts +models/create-business-cubix-account-response.ts models/create-business-deposit-address-response.ts models/create-business-payout-response.ts models/create-business-pix-account-response.ts @@ -103,8 +104,6 @@ models/create-payment-response.ts models/create-payment-token-response.ts models/create-payout-response.ts models/create-subscription-response.ts -models/create-transfer-response.ts -models/create-wallet-response.ts models/create-wire-payment-response.ts models/crypto-payment-creation-request.ts models/crypto-payment-deposit-address.ts @@ -123,6 +122,9 @@ models/crypto-refund-creation-request-amount.ts models/crypto-refund-creation-request-to-amount.ts models/crypto-refund-creation-request.ts models/crypto-refund-destination.ts +models/cubix-fiat-account-creation-request.ts +models/cubix-fiat-account-response.ts +models/cubix-instruction.ts models/currency.ts models/cvv-results.ts models/delete-subscription-response.ts @@ -151,10 +153,9 @@ models/fiat-payout-to-money.ts models/fiat-refund.ts models/final-adjustments.ts models/forbidden.ts -models/generate-address-request.ts -models/generate-address-response.ts models/get-address-book-recipient-response.ts models/get-business-cbit-account-response.ts +models/get-business-cubix-account-response.ts models/get-business-deposit-address-response.ts models/get-business-payout-response.ts models/get-business-pix-account-response.ts @@ -173,20 +174,19 @@ models/get-payout-response.ts models/get-public-key-response.ts models/get-settlement-response.ts models/get-settlements-response.ts -models/get-transfer-response.ts -models/get-wallet-response.ts models/google-pay-token.ts models/identity-address.ts models/identity.ts models/index.ts models/limit-exceeded.ts models/list-address-book-recipients-response.ts -models/list-addresses-response.ts models/list-balances-response.ts models/list-burn-fee-calculations-response.ts models/list-business-balances-response.ts models/list-business-cbit-account-instructions-response.ts models/list-business-cbit-accounts-response.ts +models/list-business-cubix-account-instructions-response.ts +models/list-business-cubix-accounts-response.ts models/list-business-deposits-response.ts models/list-business-payouts-response.ts models/list-business-pix-accounts-response.ts @@ -204,8 +204,6 @@ models/list-payments-response.ts models/list-payouts-response.ts models/list-stablecoins-response.ts models/list-subscriptions-response.ts -models/list-transfers-response.ts -models/list-wallets-response.ts models/metadata-card-and-ach.ts models/metadata-crypto-payment.ts models/metadata-payment.ts @@ -269,15 +267,10 @@ models/timeline.ts models/to-amount.ts models/token-amount.ts models/tokenized-card-details.ts -models/transfer-creation-request-destination.ts -models/transfer-creation-request.ts models/transfer-destination-blockchain-location.ts models/transfer-destination-location.ts models/transfer-destination-wallet-location.ts -models/transfer-detailed-transfer.ts models/transfer-error-code.ts -models/transfer-request-blockchain-location.ts -models/transfer-request-source-wallet-location.ts models/transfer-request-verified-blockchain-location.ts models/transfer-source-blockchain-location.ts models/transfer-source-location.ts @@ -290,9 +283,7 @@ models/update-billing-details.ts models/update-card-response.ts models/verification-error-code.ts models/wallet-config.ts -models/wallet-creation-request.ts models/wallet-location.ts -models/wallet.ts models/wire-creation-request-account-number.ts models/wire-creation-request-iban.ts models/wire-creation-request-us.ts diff --git a/src/generated/api.ts b/src/generated/api.ts index 3620fb5..bad9695 100644 --- a/src/generated/api.ts +++ b/src/generated/api.ts @@ -9,6 +9,7 @@ export * from "./apis/addresses-api"; export * from "./apis/balances-api"; export * from "./apis/cbitapi"; +export * from "./apis/cubixapi"; export * from "./apis/cards-api"; export * from "./apis/channels-api"; export * from "./apis/chargebacks-api"; @@ -29,5 +30,4 @@ export * from "./apis/settlements-api"; export * from "./apis/stablecoins-api"; export * from "./apis/subscriptions-api"; export * from "./apis/transfers-api"; -export * from "./apis/wallets-api"; export * from "./apis/wires-api"; diff --git a/src/generated/apis/cubixapi.ts b/src/generated/apis/cubixapi.ts new file mode 100644 index 0000000..2461341 --- /dev/null +++ b/src/generated/apis/cubixapi.ts @@ -0,0 +1,510 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import globalAxios, { + AxiosPromise, + AxiosInstance, + AxiosRequestConfig +} from "axios"; +import { Configuration } from "../configuration"; +// Some imports not used depending on template conditions +// @ts-ignore +import { + DUMMY_BASE_URL, + assertParamExists, + setBearerAuthToObject, + setSearchParams, + serializeDataIfNeeded, + toPathString, + createRequestFunction +} from "../common"; +// @ts-ignore +import { + BASE_PATH, + COLLECTION_FORMATS, + RequestArgs, + BaseAPI, + RequiredError +} from "../base"; +// @ts-ignore +import { BadRequest } from "../models"; +// @ts-ignore +import { CreateBusinessCubixAccountResponse } from "../models"; +// @ts-ignore +import { CubixFiatAccountCreationRequest } from "../models"; +// @ts-ignore +import { GetBusinessCubixAccountResponse } from "../models"; +// @ts-ignore +import { ListBusinessCubixAccountInstructionsResponse } from "../models"; +// @ts-ignore +import { ListBusinessCubixAccountsResponse } from "../models"; +// @ts-ignore +import { NotAuthorized } from "../models"; +// @ts-ignore +import { NotFound } from "../models"; +/** + * CUBIXApi - axios parameter creator + * @export + */ +export const CUBIXApiAxiosParamCreator = function ( + configuration?: Configuration +) { + return { + /** + * + * @summary Create a CUBIX bank account + * @param {CubixFiatAccountCreationRequest} [cubixFiatAccountCreationRequest] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + createBusinessCubixAccount: async ( + cubixFiatAccountCreationRequest?: CubixFiatAccountCreationRequest, + options: AxiosRequestConfig = {} + ): Promise => { + const localVarPath = `/v1/businessAccount/banks/cubix`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { + method: "POST", + ...baseOptions, + ...options + }; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication bearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration); + + localVarHeaderParameter["Content-Type"] = "application/json"; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = + baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = { + ...localVarHeaderParameter, + ...headersFromBaseOptions, + ...options.headers + }; + localVarRequestOptions.data = serializeDataIfNeeded( + cubixFiatAccountCreationRequest, + localVarRequestOptions, + configuration + ); + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions + }; + }, + /** + * + * @summary Get a CUBIX bank account + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getBusinessCubixAccount: async ( + id: string, + options: AxiosRequestConfig = {} + ): Promise => { + // verify required parameter 'id' is not null or undefined + assertParamExists("getBusinessCubixAccount", "id", id); + const localVarPath = `/v1/businessAccount/banks/cubix/{id}`.replace( + `{${"id"}}`, + encodeURIComponent(String(id)) + ); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { + method: "GET", + ...baseOptions, + ...options + }; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication bearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration); + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = + baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = { + ...localVarHeaderParameter, + ...headersFromBaseOptions, + ...options.headers + }; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions + }; + }, + /** + * Get the CUBIX transfer instructions into the Circle bank account given your fiat account id. + * @summary Get CUBIX instructions + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getBusinessCubixAccountInstructions: async ( + id: string, + options: AxiosRequestConfig = {} + ): Promise => { + // verify required parameter 'id' is not null or undefined + assertParamExists("getBusinessCubixAccountInstructions", "id", id); + const localVarPath = + `/v1/businessAccount/banks/cubix/{id}/instructions`.replace( + `{${"id"}}`, + encodeURIComponent(String(id)) + ); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { + method: "GET", + ...baseOptions, + ...options + }; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication bearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration); + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = + baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = { + ...localVarHeaderParameter, + ...headersFromBaseOptions, + ...options.headers + }; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions + }; + }, + /** + * + * @summary List all CUBIX bank accounts. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + listBusinessCubixAccounts: async ( + options: AxiosRequestConfig = {} + ): Promise => { + const localVarPath = `/v1/businessAccount/banks/cubix`; + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { + method: "GET", + ...baseOptions, + ...options + }; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication bearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration); + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = + baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = { + ...localVarHeaderParameter, + ...headersFromBaseOptions, + ...options.headers + }; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions + }; + } + }; +}; + +/** + * CUBIXApi - functional programming interface + * @export + */ +export const CUBIXApiFp = function (configuration?: Configuration) { + const localVarAxiosParamCreator = CUBIXApiAxiosParamCreator(configuration); + return { + /** + * + * @summary Create a CUBIX bank account + * @param {CubixFiatAccountCreationRequest} [cubixFiatAccountCreationRequest] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async createBusinessCubixAccount( + cubixFiatAccountCreationRequest?: CubixFiatAccountCreationRequest, + options?: AxiosRequestConfig + ): Promise< + ( + axios?: AxiosInstance, + basePath?: string + ) => AxiosPromise + > { + const localVarAxiosArgs = + await localVarAxiosParamCreator.createBusinessCubixAccount( + cubixFiatAccountCreationRequest, + options + ); + return createRequestFunction( + localVarAxiosArgs, + globalAxios, + BASE_PATH, + configuration + ); + }, + /** + * + * @summary Get a CUBIX bank account + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getBusinessCubixAccount( + id: string, + options?: AxiosRequestConfig + ): Promise< + ( + axios?: AxiosInstance, + basePath?: string + ) => AxiosPromise + > { + const localVarAxiosArgs = + await localVarAxiosParamCreator.getBusinessCubixAccount(id, options); + return createRequestFunction( + localVarAxiosArgs, + globalAxios, + BASE_PATH, + configuration + ); + }, + /** + * Get the CUBIX transfer instructions into the Circle bank account given your fiat account id. + * @summary Get CUBIX instructions + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async getBusinessCubixAccountInstructions( + id: string, + options?: AxiosRequestConfig + ): Promise< + ( + axios?: AxiosInstance, + basePath?: string + ) => AxiosPromise + > { + const localVarAxiosArgs = + await localVarAxiosParamCreator.getBusinessCubixAccountInstructions( + id, + options + ); + return createRequestFunction( + localVarAxiosArgs, + globalAxios, + BASE_PATH, + configuration + ); + }, + /** + * + * @summary List all CUBIX bank accounts. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async listBusinessCubixAccounts( + options?: AxiosRequestConfig + ): Promise< + ( + axios?: AxiosInstance, + basePath?: string + ) => AxiosPromise + > { + const localVarAxiosArgs = + await localVarAxiosParamCreator.listBusinessCubixAccounts(options); + return createRequestFunction( + localVarAxiosArgs, + globalAxios, + BASE_PATH, + configuration + ); + } + }; +}; + +/** + * CUBIXApi - factory interface + * @export + */ +export const CUBIXApiFactory = function ( + configuration?: Configuration, + basePath?: string, + axios?: AxiosInstance +) { + const localVarFp = CUBIXApiFp(configuration); + return { + /** + * + * @summary Create a CUBIX bank account + * @param {CubixFiatAccountCreationRequest} [cubixFiatAccountCreationRequest] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + createBusinessCubixAccount( + cubixFiatAccountCreationRequest?: CubixFiatAccountCreationRequest, + options?: any + ): AxiosPromise { + return localVarFp + .createBusinessCubixAccount(cubixFiatAccountCreationRequest, options) + .then((request) => request(axios, basePath)); + }, + /** + * + * @summary Get a CUBIX bank account + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getBusinessCubixAccount( + id: string, + options?: any + ): AxiosPromise { + return localVarFp + .getBusinessCubixAccount(id, options) + .then((request) => request(axios, basePath)); + }, + /** + * Get the CUBIX transfer instructions into the Circle bank account given your fiat account id. + * @summary Get CUBIX instructions + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + getBusinessCubixAccountInstructions( + id: string, + options?: any + ): AxiosPromise { + return localVarFp + .getBusinessCubixAccountInstructions(id, options) + .then((request) => request(axios, basePath)); + }, + /** + * + * @summary List all CUBIX bank accounts. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + listBusinessCubixAccounts( + options?: any + ): AxiosPromise { + return localVarFp + .listBusinessCubixAccounts(options) + .then((request) => request(axios, basePath)); + } + }; +}; + +/** + * CUBIXApi - object-oriented interface + * @export + * @class CUBIXApi + * @extends {BaseAPI} + */ +export class CUBIXApi extends BaseAPI { + /** + * + * @summary Create a CUBIX bank account + * @param {CubixFiatAccountCreationRequest} [cubixFiatAccountCreationRequest] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof CUBIXApi + */ + public createBusinessCubixAccount( + cubixFiatAccountCreationRequest?: CubixFiatAccountCreationRequest, + options?: AxiosRequestConfig + ) { + return CUBIXApiFp(this.configuration) + .createBusinessCubixAccount(cubixFiatAccountCreationRequest, options) + .then((request) => request(this.axios, this.basePath)); + } + + /** + * + * @summary Get a CUBIX bank account + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof CUBIXApi + */ + public getBusinessCubixAccount(id: string, options?: AxiosRequestConfig) { + return CUBIXApiFp(this.configuration) + .getBusinessCubixAccount(id, options) + .then((request) => request(this.axios, this.basePath)); + } + + /** + * Get the CUBIX transfer instructions into the Circle bank account given your fiat account id. + * @summary Get CUBIX instructions + * @param {string} id Universally unique identifier (UUID v4) of a resource. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof CUBIXApi + */ + public getBusinessCubixAccountInstructions( + id: string, + options?: AxiosRequestConfig + ) { + return CUBIXApiFp(this.configuration) + .getBusinessCubixAccountInstructions(id, options) + .then((request) => request(this.axios, this.basePath)); + } + + /** + * + * @summary List all CUBIX bank accounts. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof CUBIXApi + */ + public listBusinessCubixAccounts(options?: AxiosRequestConfig) { + return CUBIXApiFp(this.configuration) + .listBusinessCubixAccounts(options) + .then((request) => request(this.axios, this.basePath)); + } +} diff --git a/src/generated/apis/payouts-api.ts b/src/generated/apis/payouts-api.ts index 304bc43..d0eefe8 100644 --- a/src/generated/apis/payouts-api.ts +++ b/src/generated/apis/payouts-api.ts @@ -275,7 +275,7 @@ export const PayoutsApiAxiosParamCreator = function ( * * @summary List all payouts * @param {string} [destination] Universally unique identifier (UUID v4) for the destination bank account. Filters the results to fetch all payouts made to a destination bank account. - * @param {'wire' | 'cbit'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. + * @param {'wire' | 'cbit' | 'cubix'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. * @param {Set} [status] Queries items with the specified status. Matches any status if unspecified. * @param {string} [from] Queries items created since the specified date-time (inclusive). * @param {string} [to] Queries items created before the specified date-time (inclusive). @@ -287,7 +287,7 @@ export const PayoutsApiAxiosParamCreator = function ( */ listBusinessPayouts: async ( destination?: string, - type?: "wire" | "cbit", + type?: "wire" | "cbit" | "cubix", status?: Set, from?: string, to?: string, @@ -713,7 +713,7 @@ export const PayoutsApiFp = function (configuration?: Configuration) { * * @summary List all payouts * @param {string} [destination] Universally unique identifier (UUID v4) for the destination bank account. Filters the results to fetch all payouts made to a destination bank account. - * @param {'wire' | 'cbit'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. + * @param {'wire' | 'cbit' | 'cubix'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. * @param {Set} [status] Queries items with the specified status. Matches any status if unspecified. * @param {string} [from] Queries items created since the specified date-time (inclusive). * @param {string} [to] Queries items created before the specified date-time (inclusive). @@ -725,7 +725,7 @@ export const PayoutsApiFp = function (configuration?: Configuration) { */ async listBusinessPayouts( destination?: string, - type?: "wire" | "cbit", + type?: "wire" | "cbit" | "cubix", status?: Set, from?: string, to?: string, @@ -963,7 +963,7 @@ export const PayoutsApiFactory = function ( * * @summary List all payouts * @param {string} [destination] Universally unique identifier (UUID v4) for the destination bank account. Filters the results to fetch all payouts made to a destination bank account. - * @param {'wire' | 'cbit'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. + * @param {'wire' | 'cbit' | 'cubix'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. * @param {Set} [status] Queries items with the specified status. Matches any status if unspecified. * @param {string} [from] Queries items created since the specified date-time (inclusive). * @param {string} [to] Queries items created before the specified date-time (inclusive). @@ -975,7 +975,7 @@ export const PayoutsApiFactory = function ( */ listBusinessPayouts( destination?: string, - type?: "wire" | "cbit", + type?: "wire" | "cbit" | "cubix", status?: Set, from?: string, to?: string, @@ -1185,7 +1185,7 @@ export class PayoutsApi extends BaseAPI { * * @summary List all payouts * @param {string} [destination] Universally unique identifier (UUID v4) for the destination bank account. Filters the results to fetch all payouts made to a destination bank account. - * @param {'wire' | 'cbit'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. + * @param {'wire' | 'cbit' | 'cubix'} [type] Destination bank account type. Filters the results to fetch all payouts made to a specified destination bank account type. This query parameter can be passed multiple times to fetch results matching multiple destination bank account types. * @param {Set} [status] Queries items with the specified status. Matches any status if unspecified. * @param {string} [from] Queries items created since the specified date-time (inclusive). * @param {string} [to] Queries items created before the specified date-time (inclusive). @@ -1198,7 +1198,7 @@ export class PayoutsApi extends BaseAPI { */ public listBusinessPayouts( destination?: string, - type?: "wire" | "cbit", + type?: "wire" | "cbit" | "cubix", status?: Set, from?: string, to?: string, diff --git a/src/generated/apis/transfers-api.ts b/src/generated/apis/transfers-api.ts index 2715280..488ad5a 100644 --- a/src/generated/apis/transfers-api.ts +++ b/src/generated/apis/transfers-api.ts @@ -36,19 +36,11 @@ import { BusinessTransferCreationRequest } from "../models"; // @ts-ignore import { CreateBusinessTransferResponse } from "../models"; // @ts-ignore -import { CreateTransferResponse } from "../models"; -// @ts-ignore import { GetBusinessTransferResponse } from "../models"; // @ts-ignore -import { GetTransferResponse } from "../models"; -// @ts-ignore import { ListBusinessTransfersResponse } from "../models"; // @ts-ignore -import { ListTransfersResponse } from "../models"; -// @ts-ignore import { NotAuthorized } from "../models"; -// @ts-ignore -import { TransferCreationRequest } from "../models"; /** * TransfersApi - axios parameter creator * @export @@ -109,58 +101,6 @@ export const TransfersApiAxiosParamCreator = function ( options: localVarRequestOptions }; }, - /** - * A transfer can be made from an existing funded wallet to a blockchain address or another wallet. - * @summary Create a transfer - * @param {TransferCreationRequest} [transferCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createTransfer: async ( - transferCreationRequest?: TransferCreationRequest, - options: AxiosRequestConfig = {} - ): Promise => { - const localVarPath = `/v1/transfers`; - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "POST", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - localVarHeaderParameter["Content-Type"] = "application/json"; - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - localVarRequestOptions.data = serializeDataIfNeeded( - transferCreationRequest, - localVarRequestOptions, - configuration - ); - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, /** * * @summary Get a transfer @@ -211,62 +151,6 @@ export const TransfersApiAxiosParamCreator = function ( options: localVarRequestOptions }; }, - /** - * - * @summary Get a transfer - * @param {string} id Universally unique identifier (UUID v4) of a resource. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getTransfer: async ( - id: string, - returnIdentities?: boolean, - options: AxiosRequestConfig = {} - ): Promise => { - // verify required parameter 'id' is not null or undefined - assertParamExists("getTransfer", "id", id); - const localVarPath = `/v1/transfers/{id}`.replace( - `{${"id"}}`, - encodeURIComponent(String(id)) - ); - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "GET", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - if (returnIdentities !== undefined) { - localVarQueryParameter["returnIdentities"] = returnIdentities; - } - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, /** * Searches for transfers from your business account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. * @summary List all transfers @@ -337,105 +221,6 @@ export const TransfersApiAxiosParamCreator = function ( ...options.headers }; - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, - /** - * Searches for transfers involving the provided wallets. If no wallet ids are provided, searches all wallets associated with your Circle API account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. - * @summary List all transfers - * @param {string} [walletId] Unique identifier for the source or destination wallet of transfers, if any. May not be used in conjunction with destinationWalletId or sourceWalletId. Useful for fetching all transfers related to a wallet. - * @param {string} [sourceWalletId] Unique identifier for the source wallet of transfers, if any. - * @param {string} [destinationWalletId] Unique identifier for the destination wallet of transfers, if any. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - listTransfers: async ( - walletId?: string, - sourceWalletId?: string, - destinationWalletId?: string, - returnIdentities?: boolean, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options: AxiosRequestConfig = {} - ): Promise => { - const localVarPath = `/v1/transfers`; - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "GET", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - if (walletId !== undefined) { - localVarQueryParameter["walletId"] = walletId; - } - - if (sourceWalletId !== undefined) { - localVarQueryParameter["sourceWalletId"] = sourceWalletId; - } - - if (destinationWalletId !== undefined) { - localVarQueryParameter["destinationWalletId"] = destinationWalletId; - } - - if (returnIdentities !== undefined) { - localVarQueryParameter["returnIdentities"] = returnIdentities; - } - - if (from !== undefined) { - localVarQueryParameter["from"] = - (from as any) instanceof Date ? (from as any).toISOString() : from; - } - - if (to !== undefined) { - localVarQueryParameter["to"] = - (to as any) instanceof Date ? (to as any).toISOString() : to; - } - - if (pageBefore !== undefined) { - localVarQueryParameter["pageBefore"] = pageBefore; - } - - if (pageAfter !== undefined) { - localVarQueryParameter["pageAfter"] = pageAfter; - } - - if (pageSize !== undefined) { - localVarQueryParameter["pageSize"] = pageSize; - } - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - return { url: toPathString(localVarUrlObj), options: localVarRequestOptions @@ -480,33 +265,6 @@ export const TransfersApiFp = function (configuration?: Configuration) { configuration ); }, - /** - * A transfer can be made from an existing funded wallet to a blockchain address or another wallet. - * @summary Create a transfer - * @param {TransferCreationRequest} [transferCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async createTransfer( - transferCreationRequest?: TransferCreationRequest, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.createTransfer( - transferCreationRequest, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - }, /** * * @summary Get a transfer @@ -532,36 +290,6 @@ export const TransfersApiFp = function (configuration?: Configuration) { configuration ); }, - /** - * - * @summary Get a transfer - * @param {string} id Universally unique identifier (UUID v4) of a resource. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async getTransfer( - id: string, - returnIdentities?: boolean, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.getTransfer( - id, - returnIdentities, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - }, /** * Searches for transfers from your business account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. * @summary List all transfers @@ -601,57 +329,6 @@ export const TransfersApiFp = function (configuration?: Configuration) { BASE_PATH, configuration ); - }, - /** - * Searches for transfers involving the provided wallets. If no wallet ids are provided, searches all wallets associated with your Circle API account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. - * @summary List all transfers - * @param {string} [walletId] Unique identifier for the source or destination wallet of transfers, if any. May not be used in conjunction with destinationWalletId or sourceWalletId. Useful for fetching all transfers related to a wallet. - * @param {string} [sourceWalletId] Unique identifier for the source wallet of transfers, if any. - * @param {string} [destinationWalletId] Unique identifier for the destination wallet of transfers, if any. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async listTransfers( - walletId?: string, - sourceWalletId?: string, - destinationWalletId?: string, - returnIdentities?: boolean, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.listTransfers( - walletId, - sourceWalletId, - destinationWalletId, - returnIdentities, - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); } }; }; @@ -682,21 +359,6 @@ export const TransfersApiFactory = function ( .createBusinessTransfer(businessTransferCreationRequest, options) .then((request) => request(axios, basePath)); }, - /** - * A transfer can be made from an existing funded wallet to a blockchain address or another wallet. - * @summary Create a transfer - * @param {TransferCreationRequest} [transferCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createTransfer( - transferCreationRequest?: TransferCreationRequest, - options?: any - ): AxiosPromise { - return localVarFp - .createTransfer(transferCreationRequest, options) - .then((request) => request(axios, basePath)); - }, /** * * @summary Get a transfer @@ -712,23 +374,6 @@ export const TransfersApiFactory = function ( .getBusinessTransfer(id, options) .then((request) => request(axios, basePath)); }, - /** - * - * @summary Get a transfer - * @param {string} id Universally unique identifier (UUID v4) of a resource. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getTransfer( - id: string, - returnIdentities?: boolean, - options?: any - ): AxiosPromise { - return localVarFp - .getTransfer(id, returnIdentities, options) - .then((request) => request(axios, basePath)); - }, /** * Searches for transfers from your business account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. * @summary List all transfers @@ -758,48 +403,6 @@ export const TransfersApiFactory = function ( options ) .then((request) => request(axios, basePath)); - }, - /** - * Searches for transfers involving the provided wallets. If no wallet ids are provided, searches all wallets associated with your Circle API account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. - * @summary List all transfers - * @param {string} [walletId] Unique identifier for the source or destination wallet of transfers, if any. May not be used in conjunction with destinationWalletId or sourceWalletId. Useful for fetching all transfers related to a wallet. - * @param {string} [sourceWalletId] Unique identifier for the source wallet of transfers, if any. - * @param {string} [destinationWalletId] Unique identifier for the destination wallet of transfers, if any. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - listTransfers( - walletId?: string, - sourceWalletId?: string, - destinationWalletId?: string, - returnIdentities?: boolean, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: any - ): AxiosPromise { - return localVarFp - .listTransfers( - walletId, - sourceWalletId, - destinationWalletId, - returnIdentities, - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ) - .then((request) => request(axios, basePath)); } }; }; @@ -828,23 +431,6 @@ export class TransfersApi extends BaseAPI { .then((request) => request(this.axios, this.basePath)); } - /** - * A transfer can be made from an existing funded wallet to a blockchain address or another wallet. - * @summary Create a transfer - * @param {TransferCreationRequest} [transferCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof TransfersApi - */ - public createTransfer( - transferCreationRequest?: TransferCreationRequest, - options?: AxiosRequestConfig - ) { - return TransfersApiFp(this.configuration) - .createTransfer(transferCreationRequest, options) - .then((request) => request(this.axios, this.basePath)); - } - /** * * @summary Get a transfer @@ -859,25 +445,6 @@ export class TransfersApi extends BaseAPI { .then((request) => request(this.axios, this.basePath)); } - /** - * - * @summary Get a transfer - * @param {string} id Universally unique identifier (UUID v4) of a resource. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof TransfersApi - */ - public getTransfer( - id: string, - returnIdentities?: boolean, - options?: AxiosRequestConfig - ) { - return TransfersApiFp(this.configuration) - .getTransfer(id, returnIdentities, options) - .then((request) => request(this.axios, this.basePath)); - } - /** * Searches for transfers from your business account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. * @summary List all transfers @@ -902,48 +469,4 @@ export class TransfersApi extends BaseAPI { .listBusinessTransfers(from, to, pageBefore, pageAfter, pageSize, options) .then((request) => request(this.axios, this.basePath)); } - - /** - * Searches for transfers involving the provided wallets. If no wallet ids are provided, searches all wallets associated with your Circle API account. If the date parameters are omitted, returns the most recent transfers. This endpoint returns up to 50 transfers in descending chronological order or pageSize, if provided. - * @summary List all transfers - * @param {string} [walletId] Unique identifier for the source or destination wallet of transfers, if any. May not be used in conjunction with destinationWalletId or sourceWalletId. Useful for fetching all transfers related to a wallet. - * @param {string} [sourceWalletId] Unique identifier for the source wallet of transfers, if any. - * @param {string} [destinationWalletId] Unique identifier for the destination wallet of transfers, if any. - * @param {boolean} [returnIdentities] Specify if you would like to see identities in the response. Restricts maximum returned items to 5. By default returnIdentities is false, resulting in the response not returning `data.source.identities`. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof TransfersApi - */ - public listTransfers( - walletId?: string, - sourceWalletId?: string, - destinationWalletId?: string, - returnIdentities?: boolean, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: AxiosRequestConfig - ) { - return TransfersApiFp(this.configuration) - .listTransfers( - walletId, - sourceWalletId, - destinationWalletId, - returnIdentities, - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ) - .then((request) => request(this.axios, this.basePath)); - } } diff --git a/src/generated/apis/wallets-api.ts b/src/generated/apis/wallets-api.ts deleted file mode 100644 index 70ffe3a..0000000 --- a/src/generated/apis/wallets-api.ts +++ /dev/null @@ -1,791 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import globalAxios, { - AxiosPromise, - AxiosInstance, - AxiosRequestConfig -} from "axios"; -import { Configuration } from "../configuration"; -// Some imports not used depending on template conditions -// @ts-ignore -import { - DUMMY_BASE_URL, - assertParamExists, - setBearerAuthToObject, - setSearchParams, - serializeDataIfNeeded, - toPathString, - createRequestFunction -} from "../common"; -// @ts-ignore -import { - BASE_PATH, - COLLECTION_FORMATS, - RequestArgs, - BaseAPI, - RequiredError -} from "../base"; -// @ts-ignore -import { BadRequest } from "../models"; -// @ts-ignore -import { Conflict } from "../models"; -// @ts-ignore -import { CreateWalletResponse } from "../models"; -// @ts-ignore -import { GenerateAddressRequest } from "../models"; -// @ts-ignore -import { GenerateAddressResponse } from "../models"; -// @ts-ignore -import { GetWalletResponse } from "../models"; -// @ts-ignore -import { ListAddressesResponse } from "../models"; -// @ts-ignore -import { ListWalletsResponse } from "../models"; -// @ts-ignore -import { NotFound } from "../models"; -// @ts-ignore -import { WalletCreationRequest } from "../models"; -/** - * WalletsApi - axios parameter creator - * @export - */ -export const WalletsApiAxiosParamCreator = function ( - configuration?: Configuration -) { - return { - /** - * Creates an end user wallet. - * @summary Create a wallet - * @param {WalletCreationRequest} [walletCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createWallet: async ( - walletCreationRequest?: WalletCreationRequest, - options: AxiosRequestConfig = {} - ): Promise => { - const localVarPath = `/v1/wallets`; - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "POST", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - localVarHeaderParameter["Content-Type"] = "application/json"; - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - localVarRequestOptions.data = serializeDataIfNeeded( - walletCreationRequest, - localVarRequestOptions, - configuration - ); - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, - /** - * Generates a new blockchain address for a wallet for a given currency/chain pair. Circle may reuse addresses on blockchains that support reuse. For example, if you\'re requesting two addresses for depositing USD and ETH, both on Ethereum, you may see the same Ethereum address returned. Depositing cryptocurrency to a generated address will credit the associated wallet with the value of the deposit. - * @summary Create a blockchain address - * @param {string} walletId Identifier for the wallet. - * @param {GenerateAddressRequest} [generateAddressRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - generateAddress: async ( - walletId: string, - generateAddressRequest?: GenerateAddressRequest, - options: AxiosRequestConfig = {} - ): Promise => { - // verify required parameter 'walletId' is not null or undefined - assertParamExists("generateAddress", "walletId", walletId); - const localVarPath = `/v1/wallets/{walletId}/addresses`.replace( - `{${"walletId"}}`, - encodeURIComponent(String(walletId)) - ); - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "POST", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - localVarHeaderParameter["Content-Type"] = "application/json"; - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - localVarRequestOptions.data = serializeDataIfNeeded( - generateAddressRequest, - localVarRequestOptions, - configuration - ); - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, - /** - * - * @summary Get a wallet - * @param {string} walletId Identifier for the wallet. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getWallet: async ( - walletId: string, - options: AxiosRequestConfig = {} - ): Promise => { - // verify required parameter 'walletId' is not null or undefined - assertParamExists("getWallet", "walletId", walletId); - const localVarPath = `/v1/wallets/{walletId}`.replace( - `{${"walletId"}}`, - encodeURIComponent(String(walletId)) - ); - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "GET", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, - /** - * Retrieves a list of addresses associated with a wallet. - * @summary List all addresses - * @param {string} walletId Identifier for the wallet. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - listAddresses: async ( - walletId: string, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options: AxiosRequestConfig = {} - ): Promise => { - // verify required parameter 'walletId' is not null or undefined - assertParamExists("listAddresses", "walletId", walletId); - const localVarPath = `/v1/wallets/{walletId}/addresses`.replace( - `{${"walletId"}}`, - encodeURIComponent(String(walletId)) - ); - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "GET", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - if (from !== undefined) { - localVarQueryParameter["from"] = - (from as any) instanceof Date ? (from as any).toISOString() : from; - } - - if (to !== undefined) { - localVarQueryParameter["to"] = - (to as any) instanceof Date ? (to as any).toISOString() : to; - } - - if (pageBefore !== undefined) { - localVarQueryParameter["pageBefore"] = pageBefore; - } - - if (pageAfter !== undefined) { - localVarQueryParameter["pageAfter"] = pageAfter; - } - - if (pageSize !== undefined) { - localVarQueryParameter["pageSize"] = pageSize; - } - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - }, - /** - * Retrieves a list of a user\'s wallets. - * @summary List all wallets - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - listWallets: async ( - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options: AxiosRequestConfig = {} - ): Promise => { - const localVarPath = `/v1/wallets`; - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { - method: "GET", - ...baseOptions, - ...options - }; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication bearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration); - - if (from !== undefined) { - localVarQueryParameter["from"] = - (from as any) instanceof Date ? (from as any).toISOString() : from; - } - - if (to !== undefined) { - localVarQueryParameter["to"] = - (to as any) instanceof Date ? (to as any).toISOString() : to; - } - - if (pageBefore !== undefined) { - localVarQueryParameter["pageBefore"] = pageBefore; - } - - if (pageAfter !== undefined) { - localVarQueryParameter["pageAfter"] = pageAfter; - } - - if (pageSize !== undefined) { - localVarQueryParameter["pageSize"] = pageSize; - } - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = - baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = { - ...localVarHeaderParameter, - ...headersFromBaseOptions, - ...options.headers - }; - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions - }; - } - }; -}; - -/** - * WalletsApi - functional programming interface - * @export - */ -export const WalletsApiFp = function (configuration?: Configuration) { - const localVarAxiosParamCreator = WalletsApiAxiosParamCreator(configuration); - return { - /** - * Creates an end user wallet. - * @summary Create a wallet - * @param {WalletCreationRequest} [walletCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async createWallet( - walletCreationRequest?: WalletCreationRequest, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.createWallet( - walletCreationRequest, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - }, - /** - * Generates a new blockchain address for a wallet for a given currency/chain pair. Circle may reuse addresses on blockchains that support reuse. For example, if you\'re requesting two addresses for depositing USD and ETH, both on Ethereum, you may see the same Ethereum address returned. Depositing cryptocurrency to a generated address will credit the associated wallet with the value of the deposit. - * @summary Create a blockchain address - * @param {string} walletId Identifier for the wallet. - * @param {GenerateAddressRequest} [generateAddressRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async generateAddress( - walletId: string, - generateAddressRequest?: GenerateAddressRequest, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.generateAddress( - walletId, - generateAddressRequest, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - }, - /** - * - * @summary Get a wallet - * @param {string} walletId Identifier for the wallet. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async getWallet( - walletId: string, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.getWallet( - walletId, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - }, - /** - * Retrieves a list of addresses associated with a wallet. - * @summary List all addresses - * @param {string} walletId Identifier for the wallet. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async listAddresses( - walletId: string, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.listAddresses( - walletId, - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - }, - /** - * Retrieves a list of a user\'s wallets. - * @summary List all wallets - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - async listWallets( - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: AxiosRequestConfig - ): Promise< - ( - axios?: AxiosInstance, - basePath?: string - ) => AxiosPromise - > { - const localVarAxiosArgs = await localVarAxiosParamCreator.listWallets( - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ); - return createRequestFunction( - localVarAxiosArgs, - globalAxios, - BASE_PATH, - configuration - ); - } - }; -}; - -/** - * WalletsApi - factory interface - * @export - */ -export const WalletsApiFactory = function ( - configuration?: Configuration, - basePath?: string, - axios?: AxiosInstance -) { - const localVarFp = WalletsApiFp(configuration); - return { - /** - * Creates an end user wallet. - * @summary Create a wallet - * @param {WalletCreationRequest} [walletCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createWallet( - walletCreationRequest?: WalletCreationRequest, - options?: any - ): AxiosPromise { - return localVarFp - .createWallet(walletCreationRequest, options) - .then((request) => request(axios, basePath)); - }, - /** - * Generates a new blockchain address for a wallet for a given currency/chain pair. Circle may reuse addresses on blockchains that support reuse. For example, if you\'re requesting two addresses for depositing USD and ETH, both on Ethereum, you may see the same Ethereum address returned. Depositing cryptocurrency to a generated address will credit the associated wallet with the value of the deposit. - * @summary Create a blockchain address - * @param {string} walletId Identifier for the wallet. - * @param {GenerateAddressRequest} [generateAddressRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - generateAddress( - walletId: string, - generateAddressRequest?: GenerateAddressRequest, - options?: any - ): AxiosPromise { - return localVarFp - .generateAddress(walletId, generateAddressRequest, options) - .then((request) => request(axios, basePath)); - }, - /** - * - * @summary Get a wallet - * @param {string} walletId Identifier for the wallet. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getWallet( - walletId: string, - options?: any - ): AxiosPromise { - return localVarFp - .getWallet(walletId, options) - .then((request) => request(axios, basePath)); - }, - /** - * Retrieves a list of addresses associated with a wallet. - * @summary List all addresses - * @param {string} walletId Identifier for the wallet. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - listAddresses( - walletId: string, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: any - ): AxiosPromise { - return localVarFp - .listAddresses( - walletId, - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ) - .then((request) => request(axios, basePath)); - }, - /** - * Retrieves a list of a user\'s wallets. - * @summary List all wallets - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - listWallets( - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: any - ): AxiosPromise { - return localVarFp - .listWallets(from, to, pageBefore, pageAfter, pageSize, options) - .then((request) => request(axios, basePath)); - } - }; -}; - -/** - * WalletsApi - object-oriented interface - * @export - * @class WalletsApi - * @extends {BaseAPI} - */ -export class WalletsApi extends BaseAPI { - /** - * Creates an end user wallet. - * @summary Create a wallet - * @param {WalletCreationRequest} [walletCreationRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof WalletsApi - */ - public createWallet( - walletCreationRequest?: WalletCreationRequest, - options?: AxiosRequestConfig - ) { - return WalletsApiFp(this.configuration) - .createWallet(walletCreationRequest, options) - .then((request) => request(this.axios, this.basePath)); - } - - /** - * Generates a new blockchain address for a wallet for a given currency/chain pair. Circle may reuse addresses on blockchains that support reuse. For example, if you\'re requesting two addresses for depositing USD and ETH, both on Ethereum, you may see the same Ethereum address returned. Depositing cryptocurrency to a generated address will credit the associated wallet with the value of the deposit. - * @summary Create a blockchain address - * @param {string} walletId Identifier for the wallet. - * @param {GenerateAddressRequest} [generateAddressRequest] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof WalletsApi - */ - public generateAddress( - walletId: string, - generateAddressRequest?: GenerateAddressRequest, - options?: AxiosRequestConfig - ) { - return WalletsApiFp(this.configuration) - .generateAddress(walletId, generateAddressRequest, options) - .then((request) => request(this.axios, this.basePath)); - } - - /** - * - * @summary Get a wallet - * @param {string} walletId Identifier for the wallet. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof WalletsApi - */ - public getWallet(walletId: string, options?: AxiosRequestConfig) { - return WalletsApiFp(this.configuration) - .getWallet(walletId, options) - .then((request) => request(this.axios, this.basePath)); - } - - /** - * Retrieves a list of addresses associated with a wallet. - * @summary List all addresses - * @param {string} walletId Identifier for the wallet. - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof WalletsApi - */ - public listAddresses( - walletId: string, - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: AxiosRequestConfig - ) { - return WalletsApiFp(this.configuration) - .listAddresses( - walletId, - from, - to, - pageBefore, - pageAfter, - pageSize, - options - ) - .then((request) => request(this.axios, this.basePath)); - } - - /** - * Retrieves a list of a user\'s wallets. - * @summary List all wallets - * @param {string} [from] Queries items created since the specified date-time (inclusive). - * @param {string} [to] Queries items created before the specified date-time (inclusive). - * @param {string} [pageBefore] A collection ID value used for pagination. It marks the exclusive end of a page. When provided, the collection resource will return the next `n` items before the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageAfter. - * @param {string} [pageAfter] A collection ID value used for pagination. It marks the exclusive begin of a page. When provided, the collection resource will return the next `n` items after the id, with `n` being specified by `pageSize`. The items will be returned in the natural order of the collection. The resource will return the first page if neither `pageAfter` nor `pageBefore` are specified. SHOULD NOT be used in conjuction with pageBefore. - * @param {number} [pageSize] Limits the number of items to be returned. Some collections have a strict upper bound that will disregard this value. In case the specified value is higher than the allowed limit, the collection limit will be used. If avoided, the collection will determine the page size itself. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof WalletsApi - */ - public listWallets( - from?: string, - to?: string, - pageBefore?: string, - pageAfter?: string, - pageSize?: number, - options?: AxiosRequestConfig - ) { - return WalletsApiFp(this.configuration) - .listWallets(from, to, pageBefore, pageAfter, pageSize, options) - .then((request) => request(this.axios, this.basePath)); - } -} diff --git a/src/generated/index.ts b/src/generated/index.ts index 479c749..b2a936e 100644 --- a/src/generated/index.ts +++ b/src/generated/index.ts @@ -10,6 +10,7 @@ import { AddressesApi, BalancesApi, CBITApi, + CUBIXApi, CardsApi, ChannelsApi, ChargebacksApi, @@ -30,7 +31,6 @@ import { StablecoinsApi, SubscriptionsApi, TransfersApi, - WalletsApi, WiresApi } from "./api"; @@ -41,6 +41,7 @@ export class Circle { public addresses: AddressesApi; public balances: BalancesApi; public cbit: CBITApi; + public cubix: CUBIXApi; public cards: CardsApi; public channels: ChannelsApi; public chargebacks: ChargebacksApi; @@ -61,7 +62,6 @@ export class Circle { public stablecoins: StablecoinsApi; public subscriptions: SubscriptionsApi; public transfers: TransfersApi; - public wallets: WalletsApi; public wires: WiresApi; constructor(apiKey: string, baseUrl: string) { @@ -69,6 +69,7 @@ export class Circle { this.addresses = new AddressesApi(configuration); this.balances = new BalancesApi(configuration); this.cbit = new CBITApi(configuration); + this.cubix = new CUBIXApi(configuration); this.cards = new CardsApi(configuration); this.channels = new ChannelsApi(configuration); this.chargebacks = new ChargebacksApi(configuration); @@ -89,7 +90,6 @@ export class Circle { this.stablecoins = new StablecoinsApi(configuration); this.subscriptions = new SubscriptionsApi(configuration); this.transfers = new TransfersApi(configuration); - this.wallets = new WalletsApi(configuration); this.wires = new WiresApi(configuration); } } diff --git a/src/generated/models/business-account-payout-destination-type.ts b/src/generated/models/business-account-payout-destination-type.ts index 5689f61..b106711 100644 --- a/src/generated/models/business-account-payout-destination-type.ts +++ b/src/generated/models/business-account-payout-destination-type.ts @@ -14,7 +14,8 @@ export const BusinessAccountPayoutDestinationType = { Wire: "wire", - Cbit: "cbit" + Cbit: "cbit", + Cubix: "cubix" } as const; export type BusinessAccountPayoutDestinationType = diff --git a/src/generated/models/business-destination-request.ts b/src/generated/models/business-destination-request.ts index 5258876..4c8c26c 100644 --- a/src/generated/models/business-destination-request.ts +++ b/src/generated/models/business-destination-request.ts @@ -29,6 +29,7 @@ export interface BusinessDestinationRequest { export const BusinessDestinationRequestTypeEnum = { Wire: "wire", Cbit: "cbit", + Cubix: "cubix", Pix: "pix", Sepa: "sepa", SepaInstant: "sepa_instant" diff --git a/src/generated/models/create-wallet-response.ts b/src/generated/models/create-business-cubix-account-response.ts similarity index 51% rename from src/generated/models/create-wallet-response.ts rename to src/generated/models/create-business-cubix-account-response.ts index 52edf3c..49f3cf6 100644 --- a/src/generated/models/create-wallet-response.ts +++ b/src/generated/models/create-business-cubix-account-response.ts @@ -8,18 +8,18 @@ // May contain unused imports in some cases // @ts-ignore -import { Wallet } from "./wallet"; +import { CubixFiatAccountResponse } from "./cubix-fiat-account-response"; /** * * @export - * @interface CreateWalletResponse + * @interface CreateBusinessCubixAccountResponse */ -export interface CreateWalletResponse { +export interface CreateBusinessCubixAccountResponse { /** * - * @type {Wallet} - * @memberof CreateWalletResponse + * @type {CubixFiatAccountResponse} + * @memberof CreateBusinessCubixAccountResponse */ - data?: Wallet; + data?: CubixFiatAccountResponse; } diff --git a/src/generated/models/wallet-creation-request.ts b/src/generated/models/cubix-fiat-account-creation-request.ts similarity index 66% rename from src/generated/models/wallet-creation-request.ts rename to src/generated/models/cubix-fiat-account-creation-request.ts index b79e604..2b96c91 100644 --- a/src/generated/models/wallet-creation-request.ts +++ b/src/generated/models/cubix-fiat-account-creation-request.ts @@ -9,19 +9,19 @@ /** * * @export - * @interface WalletCreationRequest + * @interface CubixFiatAccountCreationRequest */ -export interface WalletCreationRequest { +export interface CubixFiatAccountCreationRequest { /** * Universally unique identifier (UUID v4) idempotency key. This key is utilized to ensure exactly-once execution of mutating requests. * @type {string} - * @memberof WalletCreationRequest + * @memberof CubixFiatAccountCreationRequest */ idempotencyKey: string; /** - * A human-friendly, non-unique identifier for a wallet. + * Cubix Account ID. * @type {string} - * @memberof WalletCreationRequest + * @memberof CubixFiatAccountCreationRequest */ - description?: string; + accountId: string; } diff --git a/src/generated/models/cubix-fiat-account-response.ts b/src/generated/models/cubix-fiat-account-response.ts new file mode 100644 index 0000000..0fd54e0 --- /dev/null +++ b/src/generated/models/cubix-fiat-account-response.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +// May contain unused imports in some cases +// @ts-ignore +import { ExternalFiatAccountStatus } from "./external-fiat-account-status"; +// May contain unused imports in some cases +// @ts-ignore +import { TransferTypeInfo } from "./transfer-type-info"; + +/** + * + * @export + * @interface CubixFiatAccountResponse + */ +export interface CubixFiatAccountResponse { + /** + * Unique system generated identifier for the entity. + * @type {string} + * @memberof CubixFiatAccountResponse + */ + id: string; + /** + * + * @type {ExternalFiatAccountStatus} + * @memberof CubixFiatAccountResponse + */ + status: ExternalFiatAccountStatus; + /** + * Tracking ref that needs to be set in the public description field when you send the funds to Circle\'s CUBIX account. + * @type {string} + * @memberof CubixFiatAccountResponse + */ + trackingRef: string; + /** + * Your CUBIX Account ID. + * @type {string} + * @memberof CubixFiatAccountResponse + */ + accountId: string; + /** + * A map which shows transfer types supported on this account as well as additional information for each. For CUBIX accounts this will always only show information for CUBIX transfers. + * @type {{ [key: string]: TransferTypeInfo; }} + * @memberof CubixFiatAccountResponse + */ + transferTypesInfo: { [key: string]: TransferTypeInfo }; + /** + * ISO-8601 UTC date/time format. + * @type {string} + * @memberof CubixFiatAccountResponse + */ + createDate: string; + /** + * ISO-8601 UTC date/time format. + * @type {string} + * @memberof CubixFiatAccountResponse + */ + updateDate: string; +} diff --git a/src/generated/models/cubix-instruction.ts b/src/generated/models/cubix-instruction.ts new file mode 100644 index 0000000..57ce3c8 --- /dev/null +++ b/src/generated/models/cubix-instruction.ts @@ -0,0 +1,27 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +/** + * + * @export + * @interface CubixInstruction + */ +export interface CubixInstruction { + /** + * Circle tracking reference that needs to be set in the CUBIX public memo field. + * @type {string} + * @memberof CubixInstruction + */ + trackingRef?: string; + /** + * Circle account ID that needs to be set in the CUBIX account ID field. + * @type {string} + * @memberof CubixInstruction + */ + accountId?: string; +} diff --git a/src/generated/models/generate-address-request.ts b/src/generated/models/generate-address-request.ts deleted file mode 100644 index 7d10710..0000000 --- a/src/generated/models/generate-address-request.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Chain } from "./chain"; -// May contain unused imports in some cases -// @ts-ignore -import { Currency } from "./currency"; - -/** - * - * @export - * @interface GenerateAddressRequest - */ -export interface GenerateAddressRequest { - /** - * Universally unique identifier (UUID v4) idempotency key. This key is utilized to ensure exactly-once execution of mutating requests. - * @type {string} - * @memberof GenerateAddressRequest - */ - idempotencyKey: string; - /** - * - * @type {Currency} - * @memberof GenerateAddressRequest - */ - currency: Currency | null; - /** - * - * @type {Chain} - * @memberof GenerateAddressRequest - */ - chain: Chain; -} diff --git a/src/generated/models/generate-address-response.ts b/src/generated/models/get-business-cubix-account-response.ts similarity index 51% rename from src/generated/models/generate-address-response.ts rename to src/generated/models/get-business-cubix-account-response.ts index 36290a0..3e1671d 100644 --- a/src/generated/models/generate-address-response.ts +++ b/src/generated/models/get-business-cubix-account-response.ts @@ -8,18 +8,18 @@ // May contain unused imports in some cases // @ts-ignore -import { AddressObject } from "./address-object"; +import { CubixFiatAccountResponse } from "./cubix-fiat-account-response"; /** * * @export - * @interface GenerateAddressResponse + * @interface GetBusinessCubixAccountResponse */ -export interface GenerateAddressResponse { +export interface GetBusinessCubixAccountResponse { /** * - * @type {AddressObject} - * @memberof GenerateAddressResponse + * @type {CubixFiatAccountResponse} + * @memberof GetBusinessCubixAccountResponse */ - data?: AddressObject; + data?: CubixFiatAccountResponse; } diff --git a/src/generated/models/get-wallet-response.ts b/src/generated/models/get-wallet-response.ts deleted file mode 100644 index aa70a73..0000000 --- a/src/generated/models/get-wallet-response.ts +++ /dev/null @@ -1,25 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Wallet } from "./wallet"; - -/** - * - * @export - * @interface GetWalletResponse - */ -export interface GetWalletResponse { - /** - * - * @type {Wallet} - * @memberof GetWalletResponse - */ - data?: Wallet; -} diff --git a/src/generated/models/index.ts b/src/generated/models/index.ts index 4a52b91..a07ec45 100644 --- a/src/generated/models/index.ts +++ b/src/generated/models/index.ts @@ -54,6 +54,7 @@ export * from "./continuous-payment-intent"; export * from "./continuous-payment-intent-creation-request"; export * from "./create-address-book-recipient-response"; export * from "./create-business-cbit-account-response"; +export * from "./create-business-cubix-account-response"; export * from "./create-business-deposit-address-response"; export * from "./create-business-payout-response"; export * from "./create-business-pix-account-response"; @@ -73,8 +74,6 @@ export * from "./create-payment-response"; export * from "./create-payment-token-response"; export * from "./create-payout-response"; export * from "./create-subscription-response"; -export * from "./create-transfer-response"; -export * from "./create-wallet-response"; export * from "./create-wire-payment-response"; export * from "./crypto-payment"; export * from "./crypto-payment-creation-request"; @@ -93,6 +92,9 @@ export * from "./crypto-refund-creation-request"; export * from "./crypto-refund-creation-request-amount"; export * from "./crypto-refund-creation-request-to-amount"; export * from "./crypto-refund-destination"; +export * from "./cubix-fiat-account-creation-request"; +export * from "./cubix-fiat-account-response"; +export * from "./cubix-instruction"; export * from "./currency"; export * from "./cvv-results"; export * from "./delete-subscription-response"; @@ -121,10 +123,9 @@ export * from "./fiat-payout-to-money"; export * from "./fiat-refund"; export * from "./final-adjustments"; export * from "./forbidden"; -export * from "./generate-address-request"; -export * from "./generate-address-response"; export * from "./get-address-book-recipient-response"; export * from "./get-business-cbit-account-response"; +export * from "./get-business-cubix-account-response"; export * from "./get-business-deposit-address-response"; export * from "./get-business-payout-response"; export * from "./get-business-pix-account-response"; @@ -143,19 +144,18 @@ export * from "./get-payout-response"; export * from "./get-public-key-response"; export * from "./get-settlement-response"; export * from "./get-settlements-response"; -export * from "./get-transfer-response"; -export * from "./get-wallet-response"; export * from "./google-pay-token"; export * from "./identity"; export * from "./identity-address"; export * from "./limit-exceeded"; export * from "./list-address-book-recipients-response"; -export * from "./list-addresses-response"; export * from "./list-balances-response"; export * from "./list-burn-fee-calculations-response"; export * from "./list-business-balances-response"; export * from "./list-business-cbit-account-instructions-response"; export * from "./list-business-cbit-accounts-response"; +export * from "./list-business-cubix-account-instructions-response"; +export * from "./list-business-cubix-accounts-response"; export * from "./list-business-deposits-response"; export * from "./list-business-payouts-response"; export * from "./list-business-pix-accounts-response"; @@ -173,8 +173,6 @@ export * from "./list-payments-response-data-inner"; export * from "./list-payouts-response"; export * from "./list-stablecoins-response"; export * from "./list-subscriptions-response"; -export * from "./list-transfers-response"; -export * from "./list-wallets-response"; export * from "./metadata-card-and-ach"; export * from "./metadata-crypto-payment"; export * from "./metadata-payment"; @@ -239,15 +237,10 @@ export * from "./to-amount"; export * from "./token-amount"; export * from "./tokenized-card-details"; export * from "./transfer"; -export * from "./transfer-creation-request"; -export * from "./transfer-creation-request-destination"; export * from "./transfer-destination-blockchain-location"; export * from "./transfer-destination-location"; export * from "./transfer-destination-wallet-location"; -export * from "./transfer-detailed-transfer"; export * from "./transfer-error-code"; -export * from "./transfer-request-blockchain-location"; -export * from "./transfer-request-source-wallet-location"; export * from "./transfer-request-verified-blockchain-location"; export * from "./transfer-source-blockchain-location"; export * from "./transfer-source-location"; @@ -258,9 +251,7 @@ export * from "./unwithdrawal-object"; export * from "./update-billing-details"; export * from "./update-card-response"; export * from "./verification-error-code"; -export * from "./wallet"; export * from "./wallet-config"; -export * from "./wallet-creation-request"; export * from "./wallet-location"; export * from "./wire"; export * from "./wire-creation-request"; diff --git a/src/generated/models/list-addresses-response.ts b/src/generated/models/list-addresses-response.ts deleted file mode 100644 index a52a321..0000000 --- a/src/generated/models/list-addresses-response.ts +++ /dev/null @@ -1,25 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { AddressObject } from "./address-object"; - -/** - * - * @export - * @interface ListAddressesResponse - */ -export interface ListAddressesResponse { - /** - * - * @type {Array} - * @memberof ListAddressesResponse - */ - data?: Array; -} diff --git a/src/generated/models/create-transfer-response.ts b/src/generated/models/list-business-cubix-account-instructions-response.ts similarity index 51% rename from src/generated/models/create-transfer-response.ts rename to src/generated/models/list-business-cubix-account-instructions-response.ts index 12190fa..25bf9ca 100644 --- a/src/generated/models/create-transfer-response.ts +++ b/src/generated/models/list-business-cubix-account-instructions-response.ts @@ -8,18 +8,18 @@ // May contain unused imports in some cases // @ts-ignore -import { Transfer } from "./transfer"; +import { CubixInstruction } from "./cubix-instruction"; /** * * @export - * @interface CreateTransferResponse + * @interface ListBusinessCubixAccountInstructionsResponse */ -export interface CreateTransferResponse { +export interface ListBusinessCubixAccountInstructionsResponse { /** * - * @type {Transfer} - * @memberof CreateTransferResponse + * @type {CubixInstruction} + * @memberof ListBusinessCubixAccountInstructionsResponse */ - data?: Transfer; + data?: CubixInstruction; } diff --git a/src/generated/models/get-transfer-response.ts b/src/generated/models/list-business-cubix-accounts-response.ts similarity index 50% rename from src/generated/models/get-transfer-response.ts rename to src/generated/models/list-business-cubix-accounts-response.ts index eccd3a3..749429f 100644 --- a/src/generated/models/get-transfer-response.ts +++ b/src/generated/models/list-business-cubix-accounts-response.ts @@ -8,18 +8,18 @@ // May contain unused imports in some cases // @ts-ignore -import { TransferDetailedTransfer } from "./transfer-detailed-transfer"; +import { CubixFiatAccountResponse } from "./cubix-fiat-account-response"; /** * * @export - * @interface GetTransferResponse + * @interface ListBusinessCubixAccountsResponse */ -export interface GetTransferResponse { +export interface ListBusinessCubixAccountsResponse { /** * - * @type {TransferDetailedTransfer} - * @memberof GetTransferResponse + * @type {Array} + * @memberof ListBusinessCubixAccountsResponse */ - data?: TransferDetailedTransfer; + data?: Array; } diff --git a/src/generated/models/list-transfers-response.ts b/src/generated/models/list-transfers-response.ts deleted file mode 100644 index ce7a8d9..0000000 --- a/src/generated/models/list-transfers-response.ts +++ /dev/null @@ -1,25 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Transfer } from "./transfer"; - -/** - * - * @export - * @interface ListTransfersResponse - */ -export interface ListTransfersResponse { - /** - * - * @type {Array} - * @memberof ListTransfersResponse - */ - data?: Array; -} diff --git a/src/generated/models/list-wallets-response.ts b/src/generated/models/list-wallets-response.ts deleted file mode 100644 index 01da554..0000000 --- a/src/generated/models/list-wallets-response.ts +++ /dev/null @@ -1,25 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Wallet } from "./wallet"; - -/** - * - * @export - * @interface ListWalletsResponse - */ -export interface ListWalletsResponse { - /** - * - * @type {Array} - * @memberof ListWalletsResponse - */ - data?: Array; -} diff --git a/src/generated/models/pix-fiat-account-response.ts b/src/generated/models/pix-fiat-account-response.ts index c347580..b0684fc 100644 --- a/src/generated/models/pix-fiat-account-response.ts +++ b/src/generated/models/pix-fiat-account-response.ts @@ -12,6 +12,9 @@ import { ExternalFiatAccountStatus } from "./external-fiat-account-status"; // May contain unused imports in some cases // @ts-ignore import { RiskEvaluation } from "./risk-evaluation"; +// May contain unused imports in some cases +// @ts-ignore +import { TransferTypeInfo } from "./transfer-type-info"; /** * @@ -43,6 +46,12 @@ export interface PixFiatAccountResponse { * @memberof PixFiatAccountResponse */ trackingRef: string; + /** + * A map which shows transfer types supported on this account as well as additional information for each. For PIX accounts this will always only show information for PIX transfers. + * @type {{ [key: string]: TransferTypeInfo; }} + * @memberof PixFiatAccountResponse + */ + transferTypesInfo: { [key: string]: TransferTypeInfo }; /** * * @type {RiskEvaluation} diff --git a/src/generated/models/transfer-creation-request-destination.ts b/src/generated/models/transfer-creation-request-destination.ts deleted file mode 100644 index a2027a3..0000000 --- a/src/generated/models/transfer-creation-request-destination.ts +++ /dev/null @@ -1,25 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Chain } from "./chain"; -// May contain unused imports in some cases -// @ts-ignore -import { TransferRequestBlockchainLocation } from "./transfer-request-blockchain-location"; -// May contain unused imports in some cases -// @ts-ignore -import { WalletLocation } from "./wallet-location"; - -/** - * @type TransferCreationRequestDestination - * @export - */ -export type TransferCreationRequestDestination = - | TransferRequestBlockchainLocation - | WalletLocation; diff --git a/src/generated/models/transfer-creation-request.ts b/src/generated/models/transfer-creation-request.ts deleted file mode 100644 index c572a6b..0000000 --- a/src/generated/models/transfer-creation-request.ts +++ /dev/null @@ -1,49 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Money } from "./money"; -// May contain unused imports in some cases -// @ts-ignore -import { TransferCreationRequestDestination } from "./transfer-creation-request-destination"; -// May contain unused imports in some cases -// @ts-ignore -import { TransferRequestSourceWalletLocation } from "./transfer-request-source-wallet-location"; - -/** - * - * @export - * @interface TransferCreationRequest - */ -export interface TransferCreationRequest { - /** - * Universally unique identifier (UUID v4) idempotency key. This key is utilized to ensure exactly-once execution of mutating requests. - * @type {string} - * @memberof TransferCreationRequest - */ - idempotencyKey: string; - /** - * - * @type {TransferRequestSourceWalletLocation} - * @memberof TransferCreationRequest - */ - source: TransferRequestSourceWalletLocation; - /** - * - * @type {TransferCreationRequestDestination} - * @memberof TransferCreationRequest - */ - destination: TransferCreationRequestDestination; - /** - * - * @type {Money} - * @memberof TransferCreationRequest - */ - amount: Money; -} diff --git a/src/generated/models/transfer-detailed-transfer.ts b/src/generated/models/transfer-detailed-transfer.ts deleted file mode 100644 index e3bdf2a..0000000 --- a/src/generated/models/transfer-detailed-transfer.ts +++ /dev/null @@ -1,103 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Fee } from "./fee"; -// May contain unused imports in some cases -// @ts-ignore -import { Money } from "./money"; -// May contain unused imports in some cases -// @ts-ignore -import { RiskEvaluation } from "./risk-evaluation"; -// May contain unused imports in some cases -// @ts-ignore -import { TransferDestinationLocation } from "./transfer-destination-location"; -// May contain unused imports in some cases -// @ts-ignore -import { TransferErrorCode } from "./transfer-error-code"; -// May contain unused imports in some cases -// @ts-ignore -import { TransferSourceLocation } from "./transfer-source-location"; - -/** - * A transfer of funds. - * @export - * @interface TransferDetailedTransfer - */ -export interface TransferDetailedTransfer { - /** - * Unique system generated identifier for the entity. - * @type {string} - * @memberof TransferDetailedTransfer - */ - id: string; - /** - * - * @type {TransferSourceLocation} - * @memberof TransferDetailedTransfer - */ - source: TransferSourceLocation; - /** - * - * @type {TransferDestinationLocation} - * @memberof TransferDetailedTransfer - */ - destination: TransferDestinationLocation; - /** - * - * @type {Money} - * @memberof TransferDetailedTransfer - */ - amount: Money; - /** - * An array of fees applied to a transaction. This is only available when there is at least one non-zero fee. - * @type {Array} - * @memberof TransferDetailedTransfer - */ - fees?: Array; - /** - * A hash that uniquely identifies the onchain transaction. This is only available where either source or destination are of type blockchain. - * @type {string} - * @memberof TransferDetailedTransfer - */ - transactionHash?: string; - /** - * Status of the transfer. Status `pending` indicates that the transfer is in the process of running; `complete` indicates it finished successfully; `failed` indicates it failed. - * @type {string} - * @memberof TransferDetailedTransfer - */ - status: TransferDetailedTransferStatusEnum; - /** - * - * @type {TransferErrorCode} - * @memberof TransferDetailedTransfer - */ - errorCode?: TransferErrorCode | null; - /** - * - * @type {RiskEvaluation} - * @memberof TransferDetailedTransfer - */ - riskEvaluation?: RiskEvaluation | null; - /** - * ISO-8601 UTC date/time format. - * @type {string} - * @memberof TransferDetailedTransfer - */ - createDate?: string; -} - -export const TransferDetailedTransferStatusEnum = { - Failed: "failed", - Pending: "pending", - Complete: "complete" -} as const; - -export type TransferDetailedTransferStatusEnum = - typeof TransferDetailedTransferStatusEnum[keyof typeof TransferDetailedTransferStatusEnum]; diff --git a/src/generated/models/transfer-request-blockchain-location.ts b/src/generated/models/transfer-request-blockchain-location.ts deleted file mode 100644 index 9c09879..0000000 --- a/src/generated/models/transfer-request-blockchain-location.ts +++ /dev/null @@ -1,50 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Chain } from "./chain"; - -/** - * - * @export - * @interface TransferRequestBlockchainLocation - */ -export interface TransferRequestBlockchainLocation { - /** - * - * @type {string} - * @memberof TransferRequestBlockchainLocation - */ - type: TransferRequestBlockchainLocationTypeEnum; - /** - * The blockchain address. - * @type {string} - * @memberof TransferRequestBlockchainLocation - */ - address: string; - /** - * The secondary identifier for a blockchain address. An example of this is the memo field on the Stellar network, which can be text, id, or hash format. - * @type {string} - * @memberof TransferRequestBlockchainLocation - */ - addressTag?: string | null; - /** - * - * @type {Chain} - * @memberof TransferRequestBlockchainLocation - */ - chain: Chain; -} - -export const TransferRequestBlockchainLocationTypeEnum = { - Blockchain: "blockchain" -} as const; - -export type TransferRequestBlockchainLocationTypeEnum = - typeof TransferRequestBlockchainLocationTypeEnum[keyof typeof TransferRequestBlockchainLocationTypeEnum]; diff --git a/src/generated/models/transfer-request-source-wallet-location.ts b/src/generated/models/transfer-request-source-wallet-location.ts deleted file mode 100644 index 9c37bf2..0000000 --- a/src/generated/models/transfer-request-source-wallet-location.ts +++ /dev/null @@ -1,44 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Identity } from "./identity"; - -/** - * - * @export - * @interface TransferRequestSourceWalletLocation - */ -export interface TransferRequestSourceWalletLocation { - /** - * - * @type {string} - * @memberof TransferRequestSourceWalletLocation - */ - type: TransferRequestSourceWalletLocationTypeEnum; - /** - * The id of the wallet. - * @type {string} - * @memberof TransferRequestSourceWalletLocation - */ - id: string; - /** - * - * @type {Array} - * @memberof TransferRequestSourceWalletLocation - */ - identities?: Array; -} - -export const TransferRequestSourceWalletLocationTypeEnum = { - Wallet: "wallet" -} as const; - -export type TransferRequestSourceWalletLocationTypeEnum = - typeof TransferRequestSourceWalletLocationTypeEnum[keyof typeof TransferRequestSourceWalletLocationTypeEnum]; diff --git a/src/generated/models/wallet.ts b/src/generated/models/wallet.ts deleted file mode 100644 index ef91d07..0000000 --- a/src/generated/models/wallet.ts +++ /dev/null @@ -1,55 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -// May contain unused imports in some cases -// @ts-ignore -import { Money } from "./money"; - -/** - * - * @export - * @interface Wallet - */ -export interface Wallet { - /** - * Wallet identifier. Numeric value but should be treated as a string as format may change in the future\' - * @type {string} - * @memberof Wallet - */ - walletId?: string; - /** - * Universally unique identifier (UUID v4) of the entity that owns the wallet. - * @type {string} - * @memberof Wallet - */ - entityId?: string; - /** - * Wallet type. - * @type {string} - * @memberof Wallet - */ - type?: WalletTypeEnum; - /** - * A human-friendly, non-unique identifier for a wallet. - * @type {string} - * @memberof Wallet - */ - description?: string; - /** - * A list of balances for currencies owned by the wallet. - * @type {Array} - * @memberof Wallet - */ - balances?: Array; -} - -export const WalletTypeEnum = { - EndUserWallet: "end_user_wallet" -} as const; - -export type WalletTypeEnum = typeof WalletTypeEnum[keyof typeof WalletTypeEnum];