NAV Navbar
Python JavaScript

Introduction

Welcome to the Fireblocks developer page! Fireblocks provides a REST API that enables you to manage your workspace as well as fully automate your transaction flow and a webhook that provides you the ability to receive push notifications on events happening on your workspace.

You can submit transfers via the API and receive real-time insights on transfers; sign all transaction types and messages securely with Raw Transaction Signing; set up automated transaction signing with Fireblocks' co-signer; manage your vault accounts, internal and external wallets, exchange accounts, fiat accounts, and network connections; and take advantage of the AML integration, among other features. All transfers are reflected in the Fireblocks Console, Transaction Log, Audit Log, webhook, and API responses.

REST API

Getting Started

You can use our REST API to create transactions on the Fireblocks platform and view information regarding your vault accounts, FIAT accounts, connected wallets, exchanges, and network connections.

We offer SDKs in Python and JavaScript. You can view code examples to the right and switch between languages with the tabs in the top right. Additionally, you can test the API directly from the browser using this online tool.

The API specification is also available in OpenAPI 3.0 (Swagger) format.

Issuing API Credentials

In order to add an API User to your Fireblocks workspace please contact Fireblocks Support to add an API user and indicate the permission level needed. Generate an API private key for signing requests (see the Creating a Signed Request section for how to sign requests with the private key):
   * Run the following command line to generate an RSA 4096 private key:
     openssl req -new -newkey rsa:4096 -nodes -keyout fireblocks.key -out fireblocks.csr
   * Make sure you keep the private key safe and secure!
   * Send the generated CSR file (fireblocks.csr) to Fireblocks Support.

Signing a Request

All API calls must be authenticated.
The base URL is: https://api.fireblocks.io

from fireblocks_sdk import FireblocksSDK, TransferPeerPath, TRANSACTION_STATUS_CONFIRMED, TRANSACTION_STATUS_CANCELLED, TRANSACTION_STATUS_REJECTED, TRANSACTION_STATUS_FAILED, VAULT_ACCOUNT, TRANSACTION_MINT, TRANSACTION_BURN

privateKey = open('api-client-key.pem', 'r').read()
apiKey = 'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX'
fireblocks = FireblocksSDK(privateKey, apiKey)
import fs from "fs";
import path from "path";

privateKey = fs.readFileSync(path.resolve(__dirname, "./api-client-key.pem"), "utf8");
const apiKey = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX";
fireblocks = new FireblocksSDK(privateKey, apiKey);

Make sure to replace the apiKey with your API key and the privateKey pem with your file.

Fireblocks uses API keys to authenticate all API calls. You can request an API key by contacting our support team.

Every request must contain the following headers:
X-API-Key - The API Key to be provided to you by Fireblocks.
Authorization - Its value should be set to Bearer <Access Token>, where the access token is a Base64-encoded JWT.

The JWT should be structured as follows:

Authorization: Bearer <JWT>

IP Whitelisting

Fireblocks supports restriction of API calls to be accepted only from a specific IP address per API key. If you wish to whitelist your IP address, please submit a ticket to Fireblocks Support with the IP of the machine running your API client and the matching API key.

Endpoints

Vault

List Vault Accounts


vault_accounts = fireblocks.get_vault_accounts()


const vaultAccounts = await fireblocks.getVaultAccounts();

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "name": "string",
    "hiddenOnUI": false,
    "customerRefId": "string",
    "autoFuel": false,
    "assets": [
      {
        "id": "string",
        "total": "string",
        "available": "string",
        "pending": "string",
        "lockedAmount": "string",
        "totalStakedCPU": "string",
        "totalStakedNetwork": "string",
        "selfStakedCPU": "string",
        "selfStakedNetwork": "string",
        "pendingRefundCPU": "string",
        "pendingRefundNetwork": "string"
      }
    ]
  }
]

Retrieves all Vault Accounts in your workspace.

HTTP Request

GET /v1/vault/accounts

Response

Returns an array of VaultAccount objects.

Retrieve a Vault Account


vault_account = fireblocks.get_vault_account(vault_account_id)


const vaultAccount = await fireblocks.getVaultAccount(vault_account_id);

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "hiddenOnUI": false,
  "customerRefId": "string",
  "autoFuel": false,
  "assets": [
    {
      "id": "string",
      "total": "string",
      "available": "string",
      "pending": "string",
      "lockedAmount": "string",
      "totalStakedCPU": "string",
      "totalStakedNetwork": "string",
      "selfStakedCPU": "string",
      "selfStakedNetwork": "string",
      "pendingRefundCPU": "string",
      "pendingRefundNetwork": "string"
    }
  ]
}

Returns the requested Vault Account.

HTTP Request

GET /v1/vault/accounts/{vaultAccountId}

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account beign retrieved
Response

Returns a VaultAccount object.

Create a New Vault Account


vaultAccount = fireblocks.create_vault_account(name, hiddenOnUI, customer_ref_id, auto_fueling)


const vaultAccount = await fireblocks.createVaultAccount(name, hiddenOnUI, customerRefId, autoFueling);

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "hiddenOnUI": false,
  "customerRefId": "string",
  "autoFuel": false,
  "assets": [
    {
      "id": "string",
      "total": "string",
      "available": "string",
      "pending": "string",
      "lockedAmount": "string",
      "totalStakedCPU": "string",
      "totalStakedNetwork": "string",
      "selfStakedCPU": "string",
      "selfStakedNetwork": "string",
      "pendingRefundCPU": "string",
      "pendingRefundNetwork": "string"
    }
  ]
}

Creates a new Vault Account with the requested name.

HTTP Request

POST /v1/vault/accounts

Body Parameters
Parameter Description
name The name of the new account (this can be renamed later)
hiddenOnUI [optional] Should be set to true if you wish this account will not appear in the web console, false by default
customerRefId [optional] The ID for AML providers to associate the owner of funds with transactions
autoFuel [optional] In case the Gas Station service is enabled on your workspace, this flag needs to be set to "true" if
you wish to add this account's Ethereum address to be monitored and fueled upon detected deposits of ERC20 tokens.
Response

Returns a VaultAccount object.

Rename a Vault Account


vaultAccount = fireblocks.update_vault_account(vault_account_id, name)


const vaultAccount = await fireblocks.updateVaultAccount(vautlAccountId, name);

Make sure to replace vaultAccountId and name with the correct variables.

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "hiddenOnUI": false,
  "customerRefId": "string",
  "autoFuel": false,
  "assets": [
    {
      "id": "string",
      "total": "string",
      "available": "string",
      "pending": "string",
      "lockedAmount": "string",
      "totalStakedCPU": "string",
      "totalStakedNetwork": "string",
      "selfStakedCPU": "string",
      "selfStakedNetwork": "string",
      "pendingRefundCPU": "string",
      "pendingRefundNetwork": "string"
    }
  ]
}

Renames the requested vault account.

HTTP Request

PUT /v1/vault/accounts/{vaultAccountId}

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account to return, or 'default' for the default vault account
Body Parameters
Parameter Description
name The new name of the vault account
Response

Returns 200 on success.

Retrieve a Vault Wallet


vaultAsset = fireblocks.get_vault_asset(vault_account_id, asset_id)


const vaultAsset = await fireblocks.getVaultAsset(aultAccountId, assetId);

The above command returns JSON structured like this:

{
  "id": "string",
  "total": "string",
  "available": "string",
  "pending": "string",
  "lockedAmount": "string",
  "totalStakedCPU": "string",
  "totalStakedNetwork": "string",
  "selfStakedCPU": "string",
  "selfStakedNetwork": "string",
  "pendingRefundCPU": "string",
  "pendingRefundNetwork": "string"
}

Retrieves a wallet of a specific asset under a Fireblocks Vault Account.

HTTP Request

GET /v1/vault/accounts/{vaultAccountId}/{assetId}

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account to return, or 'default' for the default vault account
assetId The ID of the asset
Response

Returns a VaultAsset object.

Create a New Wallet under the Vault Account


vaultAsset = fireblocks.create_vault_asset(vault_account_id, asset_id)


const vaultAsset = await fireblocks.createVaultAsset(aultAccountId, assetId);

The above command returns JSON structured like this:

{
  "id": "string",
  "eosAccountName": "string"
}

Creates a new wallet of a specific asset under a Fireblocks Vault Account.

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/{assetId}

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account, or 'default' for the default vault account
assetId The ID of the asset
Body Parameters
Parameter Description
eosAccountName [optional] EOS account address
Response

Returns CreateVaultAssetResponse.

Hide the Vault Account from the Web Console View


vaultAsset = fireblocks.hide_vault_account(vault_account_id)


const vaultAsset = await fireblocks.hideVaultAccount(aultAccountId);

Hides the Vault Account from the web console view.

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/hide

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account to hide from the web console
Response

Returns 200 on success.

Return the Vault Account to be visible in the Web Console


vaultAsset = fireblocks.unhide_vault_account(vault_account_id)


const vaultAsset = await fireblocks.unhideVaultAccount(aultAccountId);

Returns the Vault Account to be visible in the web console.

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/unhide

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account to be visible in the web console
Response

Returns 200 on success.

Retrieve Addresses of a Vault Wallet


depositAddresses = fireblocks.get_deposit_addresses(vault_account_id, asset_id)


const depositAddresses = await fireblocks.getDepositAddresses(vaultAccountId, assetId);

The above command returns JSON structured like this:

[
  {
    "assetId": "string",
    "address": "string",
    "legacyAddress": "string",
    "description": "string",
    "tag": "string",
    "type": "string"
  }
]

Retrieves all addresses of a specific asset inside a Fireblocks Vault Account.

HTTP Request

GET /v1/vault/accounts/{vaultAccountId}/{assetId}/addresses

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account to return, or 'default' for the default vault account
assetId The ID of the asset
Body Parameters
Parameter Description
eosAccountName [optional] EOS account address
Response

Returns an array of VaultWalletAddress objects.

Create a New Deposit Address in a Vault Wallet


address = fireblocks.generate_new_address(vault_account_id, asset_id, description, customer_ref_id)


const address = await fireblocks.generateNewAddress(vaultAccountId, assetId, description, customerRefId);

The above command returns JSON structured like this:

{
  "id": "string",
  "eosAccountName": "string"
}

Generates a new deposit address for the requested asset under the specific vault account.

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/{assetId}/addresses

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account, or 'default' for the default vault account
assetId The ID of the asset
Body Parameters
Parameter Description
description [optional] Description of the new address
customerRefId [optional] The ID for AML providers to associate the owner of funds with transactions
Response

Returns a CreateAddressResponse object.

Rename an Address


address = fireblocks.set_address_description(vault_account_id, asset_id, address, tag, description)


const address = await fireblocks.setAddressDescription(vaultAccountId, assetId, address, tag, description);

The above command returns JSON structured like this:

{
  "id": "string",
  "eosAccountName": "string"
}

Updates the description of an existing address within a Fireblocks Vault wallet.

HTTP Request

PUT /v1/vault/accounts/{vaultAccountId}/{assetId}/addresses/{addressId}

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account, or 'default' for the default vault account
assetId The ID of the asset
addressId The address for which to add a description. For XRP/EOS/XLM, use :{tag or memo}, for all other assets, use only the address
Body Parameters
Parameter Description
description [optional] Description of the new address
Response

Returns 200 on success.

Set an AML Customer Reference ID for Vault Account


vaultAsset = fireblocks.set_vault_account_customer_ref_id(vault_account_id, customer_ref_id)


const vaultAsset = await fireblocks.setCustomerRefIdForVaultAccount(vaultAccountId, customerRefId);

Sets an AML/KYT customer reference ID for the vault account

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/set_customer_ref_id

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account
Body Parameters
Parameter Description
customerRefId The ID for AML providers to associate the owner of funds with transactions
Response

Returns 200 on success.

Set an AML Customer Reference ID for an Address


vaultAsset = fireblocks.set_customer_ref_id_for_address(vault_account_id, asset_id, address_id, customer_ref_id)


const vaultAsset = await fireblocks.setCustomerRefIdForAddress(vaultAccountId, assetId, addressId, customerRefId);

Sets an AML/KYT customer reference ID for the given address

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/{assetId}/addresses/{addressId}/set_customer_ref_id

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account
assetId The ID of the asset
addressId The address for which the customer reference ID should be added. For XRP/EOS/XLM, use :{tag or memo}, for all other assets, use only the address
Body Parameters
Parameter Description
customerRefId The ID for AML providers to associate the owner of funds with transactions
Response

Returns 200 on success.

Retrieve Public Key by Derivation Path


pubKey = fireblocks.get_public_key(algorithm, derivation_path, compressed)


const pubKey = await fireblocks.getPublicKey(algorithm, derivationPath, compressed);

Retrieves the public key of your Fireblocks' Vault.

HTTP Request

GET /v1/vault/public_key_info

Query Parameters
Parameter Description
algorithm String, one of the supported SigningAlgorithms
derivationPath List of integers.
compressed Boolean, whether the returned key should be in compressed format or not, false by default
Response

Returns PublicKey object.

Retrieve the Public Key of a Vault Wallet Address


pubKey = fireblocks.get_vault_wallet_public_key(vault_account_id, asset_id, change, address_index, compressed)


const pubKey = await fireblocks.getVaultWalletPublicKey(vaultAccountId, assetId, change, addressIndex, compressed);

Retrieves the public key of your Fireblocks' Vault.

HTTP Request

GET /v1/vault/accounts/{vaultAccountId}/{assetId}/{change}/{addressIndex}/public_key_info

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account which address should be renamed, or 'default' for the default vault account
assetId The ID of the asset
change Whether the address should be derived internal (change) or not
addressIndex The index of the address for the derivation path
Query Parameters
Parameter Description
compressed Boolean, whether the returned key should be in compressed format or not, false by default
Response

Returns PublicKey object.

Set Auto Fuel Properties of the Vault Account







This endpoint is relevant only if the Gas Station is enabled on your workspace!
Enable / Disable auto fueling of the Vault Account's Ethereum address

HTTP Request

POST /v1/vault/accounts/{vaultAccountId}/set_auto_fuel

URL Parameters
Parameter Description
vaultAccountId The ID of the vault account
Body Parameters
Parameter Description
autoFuel Boolean, should be set to true if you wish to monitor this account's Ethereum address for incomming deposits.
Response

Returns 200 on success.

Internal Wallets

Internal Wallets are your whitelisted addresses outside of Fireblocks. You can see each wallet's balances and transfer funds here.

List Internal Wallets


internalWallets = fireblocks.get_internal_wallets()


const internalWallets = await fireblocks.getInternalWallets();

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "name": "string",
    "customerRefId": "string",
    "assets": [
      {
        "id": "string",
        "balance": "string",
        "lockedAmount": "string",
        "status": "WAITING_FOR_APPROVAL",
        "activationTime":"string",
        "address": "string",
        "tag": "string"
      }
    ]
  }
]

Retrieves all Internal Wallets in your workspace.

HTTP Request

GET /v1/internal_wallets

Response

Returns an array of UnmanagedWallet objects.

Create a New Internal Wallet


internalWallet = fireblocks.create_internal_wallet(name, customer_ref_id)


const internalWallet = await fireblocks.createInternalWallet(name, customerRefId);

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "customerRefId": "string",
  "assets": [
    {
      "id": "string",
      "balance": "string",
      "lockedAmount": "string",
      "status": "WAITING_FOR_APPROVAL",
      "activationTime":"string",
      "address": "string",
      "tag": "string"
    }
  ]
}

Creates a new Internal Wallet container.

HTTP Request

POST /v1/internal_wallets

Body Parameters
Parameter Description
name The wallet container's display name
customerRefId [optional] The ID for AML providers to associate the owner of funds with transactions
Response

Returns an UnmanagedWallet objects.

Retrieve an Internal Wallet


internalWallet = fireblocks.get_internal_wallet(walletId)


const result = await fireblocks.getInternalWallet(walletId);

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "customerRefId": "string",
  "assets": [
    {
      "id": "string",
      "balance": "string",
      "lockedAmount": "string",
      "status": "WAITING_FOR_APPROVAL",
      "activationTime":"string",
      "address": "string",
      "tag": "string"
    }
  ]
}

Retrieves all assets under the Internal Wallet.

HTTP Request

GET /v1/internal_wallets/{walletId}

URL Parameters
Parameter Description
walletId The ID of the wallet to return
Response

Returns an array of UnmanagedWallet objects.

Delete an Internal Wallet


result = firebocks.delete_internal_wallet(walletId)


const result = await fireblocks.deleteInternalWallet(walletId);

The above command returns 200 (OK)

Deletes an Internal Wallet container.

HTTP Request

DELETE /v1/internal_wallets/{walletId}

URL Parameters
Parameter Description
walletId The ID of the wallet to delete
Response

Returns 200 on success.

Retrieve an Asset from an Internal Wallet


internalWalletAsset = fireblocks.get_internal_wallet_asset(walletId, assetId)


const internalWalletAsset = fireblocks.getInternalWalletAsset(walletId, assetId);

The above command returns JSON structured like this:

{
  "id": "string",
  "balance": "string",
  "lockedAmount": "string",
  "status": "WAITING_FOR_APPROVAL",
  "activationTime":"string",
  "address": "string",
  "tag": "string"
}

Retrieves the information on a specific asset within an Internal Wallet.

HTTP Request

GET /v1/internal_wallets/{walletId}/{assetId}

URL Parameters
Parameter Description
walletId The ID of the wallet to return
assetId The ID of the asset to return
Response

Returns WalletAsset object.

Add an Asset to an Internal Wallet


internalWalletAsset = fireblocks.create_internal_wallet_asset(walletId, assetId, address, tag)


const internalWalletAsset = await fireblocks.createInternalWalletAsset(walletContainerId, assetId, address, tag);

The above command returns JSON structured like this:

{
  "id": "string",
  "balance": "string",
  "lockedAmount": "string",
  "status": "WAITING_FOR_APPROVAL",
  "activationTime":"string",
  "address": "string",
  "tag": "string"
}

Adds an address to an existing Internal Wallet container.

HTTP Request

POST /v1/internal_wallets/{walletId}/{assetId}

URL Parameters
Parameter Description
walletId The ID of the wallet to return
assetId The ID of the asset to return
Body Parameters
Parameter Description
address The wallet's address or, for EOS wallets, the account name
tag For XRP wallets, the destination tag; for EOS/XLM, the memo; for Signet/SEN, the Bank Transfer Description
Response

Returns WalletAsset object.

Delete an Asset from an Internal Wallet


result = fireblocks.delete_internal_wallet_asset(walletId, assetId)


const result = await fireblocks.deleteInternalWalletAsset(walletId, assetId);

The above command returns 200 (OK)

Deletes an asset from an Internal Wallet.

HTTP Request

DELETE /v1/internal_wallets/{walletId}/{assetId}

URL Parameters
Parameter Description
walletId The ID of the wallet to delete
assetId The ID of the asset to delete
Response

Returns 200 success.

Set an AML Customer Reference ID for an Internal Wallet


result = firebocks.set_customer_ref_id_for_internal_wallet(wallet_id, customer_ref_id)


const result = await fireblocks.setCustomerRefIdForInternalWallet(walletId, customerRefId);

The above command returns 200 (OK)

Sets an AML/KYT customer reference ID for the specific internal wallet

HTTP Request

POST /v1/internal_wallets/{walletId}/set_customer_ref_id

URL Parameters
Parameter Description
walletId The ID of the wallet to be added with the customer reference ID
Body Parameters
Parameter Description
customerRefId The ID for AML providers to associate the owner of funds with transactions
Response

Returns 200 success.

External Wallets

External Wallets are your counterparties’ wallets. These are addresses you wish to whitelist as transfer destinations.

List External Wallets


externalWallets = fireblocks.get_external_wallets()


const externalWallets = await fireblocks.getExternalWallets();

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "name": "string",
    "customerRefId": "string",
    "assets": [
      {
        "id": "string",
        "status": "WAITING_FOR_APPROVAL",
        "activationTime":"string",
        "address": "string",
        "tag": "string"
      }
    ]
  }
]

Retrieves all External Wallets in your workspace.

HTTP Request

GET /v1/external_wallets

Response

Returns an array of ExternalWallet objects.

Create a New External Wallet


externalWallet = fireblocks.create_external_wallet(name, customer_ref_id)


const externalWallet = await fireblocks.createExternalWallet(name, customerRefId);

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "customerRefId": "string",
  "assets": [
    {
      "id": "string",
      "status": "WAITING_FOR_APPROVAL",
      "activationTime":"string",
      "address": "string",
      "tag": "string"
    }
  ]
}

Creates a new External Wallet.

HTTP Request

POST /v1/external_wallets

Body Parameters
Parameter Description
name The wallet's display name
customerRefId [optional] The ID for AML providers to associate the owner of funds with transactions
Response

Returns an ExternalWallet object.

Retrieve an External Wallet


externalWallet = fireblocks.get_external_wallet(walletId)


const externalWallet = await fireblocks.getExternalWallet(walletId);

The above command returns JSON structured like this:

{
  "id": "string",
  "name": "string",
  "customerRefId": "string",
  "assets": [
    {
      "id": "string",
      "status": "WAITING_FOR_APPROVAL",
      "activationTime":"string",
      "address": "string",
      "tag": "string"
    }
  ]
}

Retrieves the External Wallet for the request wallet ID.

HTTP Request

GET /v1/external_wallets/{walletId}

URL Parameters
Parameter Description
walletId The ID of the wallet to return
Response

Returns an ExternalWallet object.

Delete an External Wallet


result = firebocks.delete_external_wallet(walletId)


const result = await fireblocks.deleteExternalWallet(walletId);

The above command returns 200 (OK)

Deletes an External Wallet.

HTTP Request

DELETE /v1/external_wallets/{walletId}

URL Parameters
Parameter Description
walletId The ID of the wallet to delete
Response

Returns 200 on success.

Retrieve an Asset from an External Wallet


externalWalletAsset = fireblocks.get_external_wallet_asset(walletId, assetId)


const externalWalletAsset = fireblocks.getExternalWalletAsset(walletId, assetId)

The above command returns JSON structured like this:

{
  "id": "string",
  "status": "WAITING_FOR_APPROVAL",
  "activationTime":"string",
  "address": "string",
  "tag": "string"
}

Retrieves the External Wallet of the requested wallet ID and asset.

HTTP Request

GET /v1/external_wallets/{walletId}/{assetId}

URL Parameters
Parameter Description
walletId The ID of the wallet to return
assetId The ID of the asset to return
Response

Returns an ExternalWalletAsset object.

Add an Asset to an External Wallet


externalWalletAsset = fireblocks.create_external_wallet_asset(walletId, assetId, address, tag)


const externalWalletAsset = await fireblocks.createExternalWalletAsset(walletContainerId, assetId, address, tag);

The above command returns JSON structured like this:

{
  "id": "string",
  "status": "WAITING_FOR_APPROVAL",
  "activationTime":"string",
  "address": "string",
  "tag": "string"
}

Adds an address to an existing External Wallet.

HTTP Request

POST /v1/external_wallets/{walletId}/{assetId}

URL Parameters
Parameter Description
walletId The ID of the wallet to return
assetId The ID of the asset to return
Body Parameters
Parameter Description
address The wallet's address or, for EOS wallets, the account name
tag For XRP wallets, the destination tag; for EOS/XLM, the memo; for Signet/SEN, the Bank Transfer Description
Response

Returns an ExternalWalletAsset object.

Delete an Asset from an External Wallet


result = fireblocks.delete_external_wallet_asset(walletId, assetId)


const result = await fireblocks.deleteExternalWalletAsset(walletId, assetId);

The above command returns 200 (OK)

Deletes an external wallet asset.

HTTP Request

DELETE /v1/external_wallets/{walletId}/{assetId}

URL Parameters
Parameter Description
walletId The ID of the wallet to delete
assetId The ID of the asset to delete
Response

Returns 200 on success.

Set an AML Customer Reference ID for an External Wallet


result = firebocks.set_customer_ref_id_for_external_wallet(wallet_id, customer_ref_id)


const result = await fireblocks.setCustomerRefIdForExternalWallet(walletId, customerRefId);

The above command returns 200 (OK)

Sets an AML/KYT customer reference ID for the specific external wallet

HTTP Request

POST /v1/external_wallets/{walletId}/set_customer_ref_id

URL Parameters
Parameter Description
walletId The ID of the wallet to be added with the customer reference ID
Body Parameters
Parameter Description
customerRefId The ID for AML providers to associate the owner of funds with transactions
Response

Returns 200 on success.

Exchange Accounts

View your exchange accounts connected to your Fireblocks workspace.

List Exchange Accounts


exchangeAccounts = fireblocks.get_exchange_accounts()


const exchangeAccounts = await fireblocks.getExchangeAccounts();

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "type": "BITTREX",
    "name": "string",
    "status": "string",
    "assets": [
      {
        "id": "string",
        "balance": "string",
        "lockedAmount": "string"
      }
    ],
    "isSubaccount": true
  }
]

Fetches all the exchange accounts.

HTTP Request

GET /v1/exchange_accounts

Response

Returns an array of ExchangeAccount objects.

Retrieve a Specific Exchange Account


exchangeAccount = fireblocks.get_exchange_account(exchangeAccountId)


const exchnageAccount = await fireblocks.get_exchange_account(exchangeAccountId);

The above command returns JSON structured like this:

{
  "id": "string",
  "type": "BITTREX",
  "name": "string",
  "status": "string",
  "assets": [
    {
      "id": "string",
      "balance": "string",
      "lockedAmount": "string"
    }
  ],
  "isSubaccount": true
}

Retrieves the Exchange Account associated with the requested exchange account ID.

HTTP Request

GET /v1/exchange_accounts/{exchangeAccountId}

URL Parameters
Parameter Description
exchangeAccountId The ID of the exchange account to return
Response

Returns an ExchangeAccount object.

Retrieve a Specific Asset Within an Exchange Account


exchangeAsset = fireblocks.get_exchange_asset(exchangeAccountId, assetId)


const exchangeAsset = await fireblocks.getExchangeAsset(exchangeAccountId, assetId);

The above command returns JSON structured like this:

{
  "id": "string",
  "balance": "string",
  "lockedAmount": "string"
}

Retrieves a single asset within an Exchange Account.

HTTP Request

GET /v1/exchange_accounts/{exchangeAccountId}/{assetId}

URL Parameters
Parameter Description
exchangeAccountId The ID of the exchange account to return
assetId The ID of the asset to return
Response

Returns an ExchangeAsset object.

Transfer to a Subaccount


transferResult = fireblocks.transfer_to_subaccount(exchangeAccountId, assetId, subaccountId, amount)


const transferResult = await fireblocks.transferToSubaccount(exchangeAccountId, assetId, subaccountId, amount);

The above command returns 200 (OK)

Transfers funds from an exchange's main account to its subaccount, allowed only on supported exchanges.

HTTP Request

POST /v1/exchange_accounts/{exchangeAccountId}/{assetId}/transfer_to_subaccount"

URL Parameters
Parameter Description
exchangeAccountId The ID of the exchange account
assetId The ID of the asset to transfer
Body Parameters
Parameter Description
subaccountId The ID of the destined subaccount
amount The amount to transfer
Response

Returns 200 on success.

Transfer from a Subaccount


transferResult = fireblocks.transfer_from_subaccount(exchangeAccountId, assetId, subaccountId, amount)


const transferResult = await fireblocks.transferFromSubaccount(exchangeAccountId, assetId, subaccountId, amount)

The above command returns 200 (OK)

Transfers funds from an exchange's subaccount to its main account. This feature is allowed only on supported exchanges.

HTTP Request

POST /v1/exchange_accounts/{exchangeAccountId}/{assetId}/transfer_from_subaccount

URL Parameters
Parameter Description
exchangeAccountId The ID of the exchange account
assetId The ID of the asset to transfer
Body Parameters
Parameter Description
subaccountId The ID of the destined subaccount
amount The amount to transfer
Response

Returns 200 on success.

Fiat Accounts

View and operate with your linked Fiat accounts

List Fiat Accounts


transactions = fireblocks.get_fiat_accounts()


const transactions = await fireblocks.getFiatAccounts();

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "type": "SIGNET",
    "name": "string",
    "address": "string",
    "assets": [
      {
        "id": "string",
        "balance": "string"
      }
    ]
  }
]

Retrieves all the FIAT accounts linked to your workspace.

HTTP Request

GET /v1/fiat_accounts

Response

Returns an array of FiatAccount object.

Retrieve a Specific Fiat Accounts


transactions = fireblocks.get_fiat_account_by_id(account_id)


const transactions = await fireblocks.getFiatAccountById(accountId);

The above command returns JSON structured like this:

{
  "id": "string",
  "type": "SIGNET",
  "name": "string",
  "address": "string",
  "assets": [
    {
      "id": "string",
      "balance": "string"
    }
  ]
}

Retrieve the requested FIAT account.

HTTP Request

GET /v1/fiat_accounts/{accountId}

URL Parameters
Parameter Description
accountId The ID of the fiat account
Response

Returns a FiatAccount object.

Redeem Funds to Linked DDA


transactions = fireblocks.redeem_to_linked_dda(account_id, amount)


const transactions = await fireblocks.redeemToLinkedDDA(accountId, amount);

The above command returns 200 (OK)

Redeem funds to the connected DDA.

HTTP Request

POST /v1/fiat_accounts/{accountId}/redeem_to_linked_dda

URL Parameters
Parameter Description
accountId The ID of the fiat account
Body Parameters
Parameter Description
amount The reqested amount
Response

Returns 200 on success.

Deposit Funds from Linked DDA


transactions = fireblocks.deposit_from_linked_dda(account_id, amount)


const transactions = await fireblocks.depositFromLinkedDDA(accountId, amount);

The above command returns 200 (OK)

Deposit funds from the connected DDA.

HTTP Request

POST /v1/fiat_accounts/{accountId}/deposit_from_linked_dda

URL Parameters
Parameter Description
accountId The ID of the fiat account
Body Parameters
Parameter Description
amount The reqested amount
Response

Returns 200 on success.

Transactions

Transfer management endpoints.

List Transactions


transactions = fireblocks.get_transactions()

const transactions = await fireblocks.getTransactions({
        status: args.status,
        after: from
        });

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "assetId": "string",
    "source": {
      "type": "VAULT_ACCOUNT",
      "id": "string",
      "name": "string",
      "subType": "string"
    },
    "destination": {
      "type": "VAULT_ACCOUNT",
      "id": "string",
      "name": "string",
      "subType": "string"
    },
    "amountInfo": {
      "amount": "string",
      "requestedAmount": "string",
      "netAmount": "string",
      "amountUSD": "string"
    },
    "feeInfo": {
      "networkFee": "string",
      "serviceFee": "string"
    },
    "requestedAmount": 0,
    "amount": 0,
    "netAmount": 0,
    "amountUSD": 0,
    "serviceFee": 0,
    "networkFee": 0,
    "createdAt": "string",
    "lastUpdated": "string",
    "status": "SUBMITTED",
    "txHash": "string",
    "tag": "string",
    "subStatus": "INSUFFICIENT_FUNDS",
    "destinationAddress": "string",
    "destinationAddressDescription": "string",
    "destinationTag": "string",
    "signedBy": [
      "string"
    ],
    "createdBy": "string",
    "rejectedBy": "string",
    "addressType": "string",
    "note": "string",
    "exchangeTxId": "string",
    "feeCurrency": "string",
    "operation": "TRANSFER",
    "networkRecords": [
      {
        "source": {
          "type": "VAULT_ACCOUNT",
          "id": "string",
          "name": "string",
          "subType": "string"
        },
        "destination": {
          "type": "VAULT_ACCOUNT",
          "id": "string",
          "name": "string",
          "subType": "string"
        },
        "txHash": "string",
        "networkFee": "string",
        "assetId": "string",
        "netAmount": "string",
        "status": "DROPPED",
        "type": "string",
        "destinationAddress": "string"
      }
    ],
    "amlScreeningResult": {
      "provider": "string",
      "payload": {}
    },
    "customerRefId": "string",
    "numOfConfirmations": 0,
    "signedMessages": [
      {
        "content": "string",
        "algorithm": "ECDSA",
        "derivationPath": [
          1,1,0,10
        ],
        "signature": {
          "r": "string",
          "s": "string",
          "v": 0
        },
        "publicKey": "string"
      }
    ]
  }
]

Lists the transaction history for your workspace.

HTTP Request

GET /v1/transactions

Query Parameters
Parameter Description
before [optional] Unix timestamp in milliseconds. Returns only transactions created before the specified date
after [optional] Unix timestamp in milliseconds. Returns only transactions created after the specified date
status [optional] Comma-separated list of statuses. Returns only transactions with each of the specified statuses
orderBy [optional] The field to order the results by. Available values : createdAt (default), lastUpdated
sourceType [optional] The source type of the transaction. Available values: VAULT_ACCOUNT, EXCHANGE_ACCOUNT, INTERNAL_WALLET, EXTERNAL_WALLET, FIAT_ACCOUNT, NETWORK_CONNECTION, COMPOUND
sourceId [optional] The source ID of the transaction
destType [optional] The destination type of the transaction. Available values: VAULT_ACCOUNT, EXCHANGE_ACCOUNT, INTERNAL_WALLET, EXTERNAL_WALLET, FIAT_ACCOUNT, NETWORK_CONNECTION, COMPOUND
destId [optional] The destination ID of the transaction
assets [optional] A list of assets to filter by, seperated by commas
txHash [optional] Returns only results with a specified txHash
limit [optional] Limits the number of returned transactions. If not provided, a defult of 200 will be returned. The maximum allowed limit is 500.
Response

Returns an array of TransactionDetails object.
The response is paginated with a default of 200 results per page.

Create a New Transaction


tx_result = client.create_transaction(
        asset_id="BTC",
        amount="50",
        source=TransferPeerPath(VAULT_ACCOUNT, from_vault_account_id),
        destination=TransferPeerPath(VAULT_ACCOUNT, to_vault_account_id)
        )

const payload: TransactionArguments = {
    assetId: asset,
    source: {
        type: sourceType,
        id: sourceId || 0
    },
    destination: {
        type: destinationType,
        id: String(destinationId)
    },
    amount: String(amount),
    fee: String(fee),
    note: "Created by fireblocks SDK"
};

const result = await fireblocks.createTransaction(payload);

The above command returns JSON structured like this:

{
  "id": "string",
  "status": "string"
}

Submits a new transaction on the Fireblocks platform.

HTTP Request

POST /v1/transactions

Body Parameters
Parameter Description
assetId The ID of the asset
source TransferPeerPath json object
destination DestinationTransferPeerPath json object
amount The requested amount to transfer
fee [optional] For UTXO assets, the fee per bytes in the asset's smallest unit (Satoshi, Latoshi, etc.)
For XRP, the fee for the transaction
gasPrice [optional] For ETH-based assets only this will be used instead of the fee property, value is in Gwei
gasLimit [optional] For ETH-based assets only
networkFee [optional] The transaction blockchain fee (For Ethereum, you can't pass gasPrice, gasLimit and networkFee all together)
feeLevel [optional] LOW / MEDIUM / HIGH - Defines the blockchain fee level which will be payed for the transaction. Only for Ethereum and UTXO blockchains.
maxFee [optional] The maximum fee (gas price or fee per byte) that should be payed for the transaction.
failOnLowFee [optional] If this flag is true and the current feeLevel (chosen or MEDIUM by default) is higher than the one specified in "maxFee", the transction will fail.
note [optional] Note to be added to the transaction log
autoStaking [optional] For EOS transfers, staking will be managed by Fireblocks
networkStaking [optional] For EOS transfers, network stake
cpuStaking [optional] For EOS transfers, cpu stake
operation [optional] TransactionOperation Transaction operation type, the default is "TRANSFER"
customerRefId [optional] The ID for AML providers to associate the owner of funds with transactions
extraParameters [optional] Use for protocol / operation specific parameters. For raw transactions - pass rawMessageData field
Response

Returns a CreateTransactionResponse object. The response is paginated, the default response sise is up to 200 entries.

Retrieve a Specific Transaction


tx = fireblocks.get_transaction_by_id(txId)


  const tx = await fireblocks.getTransactionById(txId);

The above command returns JSON structured like this:

{
  "id": "string",
  "assetId": "string",
  "source": {
    "type": "VAULT_ACCOUNT",
    "id": "string",
    "name": "string",
    "subType": "string"
  },
  "destination": {
    "type": "VAULT_ACCOUNT",
    "id": "string",
    "name": "string",
    "subType": "string"
  },
  "amountInfo": {
    "amount": "string",
    "requestedAmount": "string",
    "netAmount": "string",
    "amountUSD": "string"
  },
  "feeInfo": {
    "networkFee": "string",
    "serviceFee": "string"
  },
  "requestedAmount": 0,
  "amount": 0,
  "netAmount": 0,
  "amountUSD": 0,
  "serviceFee": 0,
  "networkFee": 0,
  "createdAt": "string",
  "lastUpdated": "string",
  "status": "SUBMITTED",
  "txHash": "string",
  "tag": "string",
  "subStatus": "INSUFFICIENT_FUNDS",
  "destinationAddress": "string",
  "destinationAddressDescription": "string",
  "destinationTag": "string",
  "signedBy": [
    "string"
  ],
  "createdBy": "string",
  "rejectedBy": "string",
  "addressType": "string",
  "note": "string",
  "exchangeTxId": "string",
  "feeCurrency": "string",
  "operation": "TRANSFER",
  "networkRecords": [
    {
      "source": {
        "type": "VAULT_ACCOUNT",
        "id": "string",
        "name": "string",
        "subType": "string"
      },
      "destination": {
        "type": "VAULT_ACCOUNT",
        "id": "string",
        "name": "string",
        "subType": "string"
      },
      "txHash": "string",
      "networkFee": "string",
      "assetId": "string",
      "netAmount": "string",
      "status": "DROPPED",
      "type": "string",
      "destinationAddress": "string"
    }
  ],
  "amlScreeningResult": {
    "provider": "string",
    "payload": {}
  },
  "customerRefId": "string",
  "numOfConfirmations": 0,
  "signedMessages": [
    {
      "content": "string",
      "algorithm": "ECDSA",
      "derivationPath": [
        1,1,0,10
      ],
      "signature": {
          "r": "string",
          "s": "string",
          "v": 0
      },
      "publicKey": "string"
    }
  ]
}

Retrieves a specific transaction for the requested transaction ID.

HTTP Request

GET /v1/transactions/{txId}

URL Parameters
Parameter Description
txId The ID of the transaction to return
Response

Returns a TransactionDetails object.

Cancel Transaction


result = fireblocks.cancel_transaction_by_id(txId)


const result = await fireblocks.cancelTransactionById(txId);

The above command returns JSON structured like this:

{
  "success": true
}

Cancel the requested transaction.

HTTP Request

POST /v1/transactions/{txId}/cancel

URL Parameters
Parameter Description
txId The ID of the transaction to return
Response

Returns the status of the request.

Retrieve Network Fee


fee_result = fireblocks.get_fee_for_asset(asset_id)


const feeResult = await fireblocks.getFeeForAsset(assetId);

The above command returns JSON structured like this:

{
  "low": {
    "feePerByte": "string",
    "gasPrice": "string",
    "networkFee": "string"
  },
  "medium": {
    "feePerByte": "string",
    "gasPrice": "string",
    "networkFee": "string"
  },
  "high": {
    "feePerByte": "string",
    "gasPrice": "string",
    "networkFee": "string"
  }
}

Retrieves the current blockchain fees based on the requested asset.

HTTP Request

GET /v1/estimate_network_fee

Query Parameters
Parameter Description
assetId The asset for which you wish to retrieve the network fees
Response

Returns NetworkFee objects for low, medium and high fees.

Estimate Transaction Fee


estimated_fee = client.estimate_fee_for_transaction(
        asset_id="BTC",
        amount="50",
        source=TransferPeerPath(VAULT_ACCOUNT, from_vault_account_id),
        destination=TransferPeerPath(VAULT_ACCOUNT, to_vault_account_id)
        )

const payload: TransactionArguments = {
    assetId: asset,
    source: {
        type: sourceType,
        id: sourceId || 0
    },
    destination: {
        type: destinationType,
        id: String(destinationId)
    },
    amount: Number(amount)
};

const estimatedFee = await fireblocks.estimateFeeForTransaction(payload);

The above command returns JSON structured like this:

{
  "low": {
    "feePerByte": "string",
    "gasPrice": "string",
    "gasLimit": "string",
    "networkFee": "string"
  },
  "medium": {
    "feePerByte": "string",
    "gasPrice": "string",
    "gasLimit": "string",
    "networkFee": "string"
  },
  "high": {
    "feePerByte": "string",
    "gasPrice": "string",
    "gasLimit": "string",
    "networkFee": "string"
  }
}

Estimates the transaction fee for a given transaction request.

HTTP Request

POST /v1/transactions/estimate_fee

Body Parameters
Parameter Description
assetId The ID of the asset
amount The requested amount to transfer
source TransferPeerPath JSON object
destination DestinationTransferPeerPath JSON object
operation [optional] TransactionOperation Transaction operation type, the default is "TRANSFER"
Response

Returns an EstimatedTransactionFeeResponse object.

Set Confirmation Threshold by TX ID


set_conf_threshold = client.set_confirmation_threshold_by_tx_id(body)


const setConfThreshold = await fireblocks.setConfirmationThresholdByTxId(body);

The above command returns JSON structured like this:

{
  "success": true,
  "transactions": [
    "string"
  ]
}

Overrides the required number of confirmations for a transaction completion by its transaction ID.

HTTP Request

POST /v1/transactions/{txId}/set_confirmation_threshold

Body Parameters
Parameter Description
numOfConfirmations The number of transaction's confirmations to be considered COMPLETED
Response

Returns an SetConfirmationsThresholdResponse object.

Set Confirmation Threshold by TX Hash


set_conf_threshold = client.set_confirmation_threshold_by_tx_hash(body)


const setConfThreshold = await fireblocks.setConfirmationThresholdByTxHash(body);

The above command returns JSON structured like this:

{
  "success": true,
  "transactions": [
    "string"
  ]
}

Overrides the required number of confirmations for a transaction completion by its transactions hash.

HTTP Request

POST /v1/txHash/{txHash}/set_confirmation_threshold

Body Parameters
Parameter Description
numOfConfirmations The number of transaction's confirmations to be considered COMPLETED
Response

Returns an SetConfirmationsThresholdResponse object.

Network Connections

List Network Connections


network_connections = fireblocks.get_network_connections()


const networkConnections = await fireblocks.getNetworkConnections(txId);

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "localChannel": {
      "networkId": "string",
      "name": "string"
    },
    "remoteChannel": {
      "networkId": "string",
      "name": "string"
    }
  }
]

Retrieves all Fireblocks network connections.

HTTP Request

GET /v1/network_connections

Response

Returns an array of NetworkConnection objects.

Retrieve a Network Connection


network_connection = fireblocks.get_network_connection(connectionId)


const network_connection = await fireblocks.getNetworkConnection(connectionId);

The above command returns JSON structured like this:

{
  "id": "string",
  "localChannel": {
    "networkId": "string",
    "name": "string"
  },
  "remoteChannel": {
    "networkId": "string",
    "name": "string"
  }
}

Retrieves a network connection matching the requested connectionId.

HTTP Request

GET /v1/network_connections/{connectionId}

URL Parameters
Parameter Description
connectionId The ID of the network connection
Response

Returns a NetworkConnection object.

Supported Assets

Retrieve all Assets Supported by Fireblocks


supportedAssets = fireblocks.get_supported_assets()


const supportedAssets = await fireblocks.getSupportedAssets();

The above command returns JSON structured like this:

[
  {
    "id": "string",
    "name": "string",
    "type": "BASE_ASSET",
    "contractAddress": "string"
  }
]

Returns all assets supported by Fireblocks.

HTTP Request

GET /v1/supported_assets

Response

Returns an array of AssetTypeResponse.

Smart Transfers

The Fireblocks Assisted Transfer Solution allows counterparties to seamlessly transfer digital assets to each other for settlement.

List Transfer Tickets


ticketId = fireblocks.get_transfer_tickets()


const ticketId = await fireblocks.getTransferTickets();

The above command returns JSON structured like this:

[
  {
    "ticketId": "string",
    "externalTicketId": "string",
    "status": "OPEN",
    "description": "string",
    "terms": [
      {
        "termId": "string",
        "txId": "string",
        "networkConnectionId": "string",
        "outgoing": false,
        "amount": "string",
        "asset": "string",
        "status": "OPEN",
        "description": "string"
      }
    ]
  }
]

List all Smart Transfer tickets.

GET /v1/transfer_tickets

Response

Returns an array TransferTickets objects.

Submit a new Transfer Ticket


ticketId = fireblocks.create_transfer_ticket(terms, external_ticket_id, description)


const ticketId = await fireblocks.createTransferTicket(terms, externalTicketId, description);

The above command returns JSON structured like this:

{
  "ticketId": "string"
}

This endpoint creates a new transfer ticket between 2 parties on the Fireblocks network.

HTTP Request

POST /v1/transfer_tickets

Body Parameters
Parameter Description
terms Array of the TransferTicketTerms of the transfer ticket
externalTicketId [optional] Ticket ID on customer's OMS platform
description [optional] Custom information that can be added to the ticket
Response

Returns a newly created ticket ID.

Retrieve a Transfer Ticket


ticketId = fireblocks.get_transfer_ticket_by_id(ticket_id)


const ticketId = await fireblocks.getTransferTicketById(ticketId);

The above command returns JSON structured like this:

{
  "ticketId": "string",
  "externalTicketId": "string",
  "status": "OPEN",
  "description": "string",
  "terms": [
    {
      "termId": "string",
      "txId": "string",
      "networkConnectionId": "string",
      "outgoing": false,
      "amount": "string",
      "asset": "string",
      "status": "OPEN",
      "note": "string"
    }
  ]
}

Retrieve a transfer ticket.

GET /v1/transfer_tickets/{ticketId}

URL Parameters
Parameter Description
ticketId The ID of the transfer ticket
Response

Returns a TransferTicket object.

Retrieve a Term of a Transfer Ticket


ticketId = fireblocks.get_transfer_ticket_term(ticket_id, term_id)


const ticketId = await fireblocks.getTransferTicketTerm(ticketId, termId);

The above command returns JSON structured like this:

{
  "termId": "string",
  "txId": "string",
  "networkConnectionId": "string",
  "outgoing": false,
  "amount": "string",
  "asset": "string",
  "status": "OPEN",
  "note": "string"
}

Retrieves a term of a transfer ticket.

GET /v1/transfer_tickets/{ticketId}/{termId}

URL Parameters
Parameter Description
ticketId The ID of the transfer ticket
termId The ID of the term within the ticket
Response

Returns a TransferTicketTerm object.

Cancel a Transfer Request


ticketId = fireblocks.cancel_transfer_ticket(ticket_id)


const ticketId = await fireblocks.cancelTransferTicket(ticketId);

The above command returns 200 (OK)

POST /v1/transfer_tickets/{ticketId}/cancel

URL Parameters
Parameter Description
ticketId The ID of the transfer ticket to cancel
Response

Returns 200 on success.

Make a Transfer from a Transfer Term Context


ticketId = fireblocks.execute_ticket_term(ticket_id, term_id, source)


const ticketId = await fireblocks.executeTicketTerm(ticketId, termId, source);

The above command returns 200 (OK)

POST /v1/transfer_tickets/{ticketId}/{termId}/transfer

URL Parameters
Parameter Description
ticketId The ID of the transfer ticket
termId The ID of the term within the transfer ticket to fulfill
Body Parameters
Parameter Description
source [optional] TransferPeerPath json object. If no source will be provided, the source vault account will be the one associated with the network connection
Response

Returns 200 on success.

Gas Station

Fireblocks provides the Gas Station servce to fuel with ETH your Ethereum addresses with ERC20 tokens deposits.

Retrieve your Gas Station Settings







The above command returns JSON structured like this:

{
  "balance": {
    "ETH": "string"
  },
  "configuration": {
    "gasThreshold": "string",
    "gasCap": "string",
    "maxGasPrice": "string"
  }
}

Retrieves a term of a transfer ticket.

GET /v1/gas_station

Response

Returns a GasStationInfo object.

Edit your Gas Station settings







The above command returns JSON structured like this:

{
  "balance": {
    "ETH": "string"
  },
  "configuraiton" :{
    "gasCap": "string",
    "gasThreshold": "string",
    "maxGasPrice": "string"
  }
}

Configure your Gas Station's settings.

PUT /v1/gas_station/configuration

Body Parameters
Parameter Description
gasThreshold Below this ETH balane the address will be funded up until gasCap value, in ETH units
gasCap Up to this level the address will be funded with ETH, in ETH units
maxGasPrice The funding transaction will be sent with this maximum value gas price, in Gwei units
Response

Returns a GasStationConfiguration object.

Data Objects

Here, you can find a description of all the objects expected and returned by the endpoints described above.

Vault Objects

CreateVaultAssetResponse

Parameter Type Description
id string The ID of the asset
eosAccountName string Returned for EOS, the account name

VaultAsset

Parameter Type Description
id string The ID of the asset
total string The total wallet balance. In EOS, this value includes the network balance, self staking, and pending refunds. For all other coins, it is the balance as it appears on the blockchain
balance string Deprecated - replaced by "total"
available string Funds available for transfer. Equals the blockchain balance minus any locked amount
pending string The cumulative balance of all transactions pending to be cleared
lockedAmount string Funds in outgoing transactions that are not yet published to the network
totalStakedCPU string [optional] Only for EOS, total CPU staked for the account
totalStakedNetwork string [optional] Only for EOS, total Network staked for the account
selfStakedCPU string [optional] Only for EOS, self CPU staked for the account
selfStakedNetwork string [optional] Only for EOS, self Network staked for the account
pendingRefundCPU string [optional] Only for EOS, pending CPU stake refund for the account
pendingRefundNetwork string [optional] Only for EOS, pending Network stake refund for the account

VaultWalletAddress

Parameter Type Description
assetId string The ID of the asset
address string Address of the Vault Wallet, for BTC/LTC the address is in Segwit (Bech32) format, for BCH cash format
legacyAddress string For BTC/LTC/BCH the legacy format address
description string Description of the address
tag string Destination tag for XRP, used as memo for EOS/XLM, for Signet/SEN it is the Bank Transfer Description
type string Address type
customerRefId string [optional] The ID for AML providers to associate the owner of funds with transactions

CreateAddressResponse

Parameter Type Description
address string Address of the Vault Wallet, for BTC/LTC the address is in Segwit (Bech32) format, cash address format for BCH
legacyAddress string Legacy address format for BTC/LTC/BCH
tag string Destination tag for XRP, used as memo for EOS/XLM

VaultAccount

Parameter Type Description
id string The ID of the Vault Account
name string Name of the Vault Account
hiddenOnUI boolean Specifies whether this vault account is visible in the web console or not
customerRefId string [optional] The ID for AML providers to associate the owner of funds with transactions
autoFuel boolean Specifies whether this account's Ethereum address is auto fueled by the Gas Station or not
assets array of VaultAsset List of assets under this Vault Account

PublicKey

Parameter Type Description
publicKey sring The requested public key
algorithm string One of the SigningAlgorithms
derivationPath array of numbers For BIP32 derivation used to retrieve the public key

Internal/External Wallets

WalletAsset

Parameter Type Description
id string The ID of the asset
balance string The balance of the wallet
lockedAmount string Locked amount in the wallet
status ConfigChangeRequestStatus Status of the Internal Wallet
activationTime string The time the wallet will be activated in case wallets activation posponed according to workspace definition
address string The address of the wallet
tag string Destination tag (for XRP, used as memo for EOS/XLM) of the wallet.

ExternalWalletAsset

Parameter Type Description
id string The ID of the asset
status ConfigChangeRequestStatus Status of the External Wallet
activationTime string The time the wallet will be activated in case wallets activation posponed according to workspace definition
address string The address of the wallet
tag string Destination tag (for XRP, used as memo for EOS/XLM) of the wallet, for SEN/Signet used as Bank Transfer Description

UnmanagedWallet

Parameter Type Description
id string The ID of the Unmanaged Wallet
name string Name of the Wallet Container
customerRefId string [optional] The ID for AML providers to associate the owner of funds with transactions
assets array of WalletAsset Array of the assets available in the unmanaged wallet

ExternalWallet

Parameter Type Description
id string The ID of the Unmanaged Wallet
name string Name of the Wallet Container
customerRefId string [optional] The ID for AML providers to associate the owner of funds with transactions
assets array of ExternalWalletAsset Array of the assets available in the exteral wallet

Exchange Objects

ExchangeAccount

Parameter Type Description
id string The ID of the exchange account to return
type ExchangeType
name string Display name of the exchange account
status ConfigChangeRequestStatus Status of the exchange account connection
assets array of ExchangeAsset Assets in the account
isSubaccount boolean True if the account is a subaccount in an exchange

ExchangeAsset

Parameter Type Description
id string The ID of the exchange account to return
balance string Balance of the asset in the exchange account
lockedAmout string Locked amount in the account

ExchangeType

Parameter Type Description
type string [BITTREX, COINBASEPRO, BINANCE, BINANCEUS, BITMEX, KRAKEN, GEMINI, BITFINEX, BITSTAMP, POLONIEX, DERIBIT, LIQUID, HUOBI, BITHUMB, OKEX, OKCOIN, HITBTC, KORBIT, SEEDCX, BITSO]

Transactions

TransferPeerPath

Parameter Type Description
type string [ VAULT_ACCOUNT, EXCHANGE_ACCOUNT, INTERNAL_WALLET, EXTERNAL_WALLET, NETWORK_CONNECTION, FIAT_ACCOUNT, COMPOUND, GAS_STATION ]
id string The ID of the peer

DestinationTransferPeerPath

Parameter Type Description
type string [ VAULT_ACCOUNT, EXCHANGE_ACCOUNT, INTERNAL_WALLET, EXTERNAL_WALLET, NETWORK_CONNECTION, FIAT_ACCOUNT, COMPOUND, GAS_STATION ]
id string The ID of the exchange account to return
oneTimeAddress OneTimeAddress Destination address

CreateTransactionResponse

Parameter Type Description
id string The ID of the transaction
status TransactionStatus Status of the transaction

CancelTransactionResponse

Parameter Type Description
success boolean True if the cancellation succeeded

TransferPeerPathResponse

Parameter Type Description
type string [ VAULT_ACCOUNT, EXCHANGE_ACCOUNT, INTERNAL_WALLET, EXTERNAL_WALLET, NETWORK_CONNECTION, FIAT_ACCOUNT, COMPOUND ]
id string The ID of the exchange account to return
name string The name of the exchange account
subType string

TransactionDetails

Parameter Type Description
id string ID of the transaction
assetId string Transaction asset
source TransferPeerPathResponse Source of the transaction
destination TransferPeerPathResponse Destination of the transaction
requestedAmount number The amount requested by the user
amountInfo AmountInfo Details of the transaction's amount in string format
feeInfo FeeInfo Details of the transaction's fee in string format
amount number If the transfer is a withdrawal from an exchange, the actual amount that was requested to be transferred. Otherwise, the requested amount
netAmount number The net amount of the transaction, after fee deduction
amountUSD number The USD value of the requested amount
serviceFee number The total fee deducted by the exchange from the actual requested amount (serviceFee = amount - netAmount)
networkFee number The fee paid to the network
createdAt string Unix timestamp
lastUpdated string Unix timestamp
status TransactionStatus The current status of the transaction
txHash string Blockchain hash of the transaction
subStatus TransactionSubStatus More detailed status of the transaction
destinationAddress string Address where the asset were transfered
destinationAddressDescription string Description of the address
destinationTag string Destination tag (for XRP, used as memo for EOS/XLM) or Bank Transfer Description for Signet/SEN
signedBy array of string Signers of the transaction
createdBy string Initiator of the transaction
rejectedBy string User ID of the user that rejected the transaction (in case it was rejected)
addressType string [ ONE_TIME, WHITELISTED ]
note string Custome note of the transaction
exchangeTxId string If the transaction originated from an exchange, this is the exchange tx ID
feeCurrency string The asset which was taken to pay the fee (ETH for ERC-20 tokens, BTC for Tether Omni)
operation TransactionOperation Default operation is "TRANSFER"
amlScreeningResult AmlScreeningResult The result of the AML screening
customerRefId string The ID for AML providers to associate the owner of funds with transactions
numOfConfirmations number The number of confirmations of the transaction. The number will increase until the transaction will be considered completed according to the confirmation policy.
networkRecords array of NetworkRecord objects Transaction on the Fireblocks platform can aggregate several blockchain transactions, in such a case these records specify all the transactions that took place on the blockchain.
signedMessages array of SignedMessage objects A list of signed messages. Returned for raw transactions.

TransactionOperation

Parameter Type Description
operation string [ TRANSFER, RAW, MINT, BURN, SUPPLY_TO_COMPOUND, REDEEM_FROM_COMPOUND ]

SignedMessage

Parameter Type Description
content string The message for signing (hex-formatted)
algorithm string The algorithm that was used for signing, one of the SigningAlgorithms
derivationPath array of numbers BIP32 derivation path of the signing key. E.g. [44,0,46,0,0]
signature dictionary The message signature
publicKey string Signature's public key that can be used for verification.

NetworkFee

Parameter Type Description
feePerByte string [optional] For UTXOs
gasPrice string [optional] For Ethereum assets (ETH and Tokens)
networkFee string [optional] All other assets

TransactionFee

Parameter Type Description
feePerByte string [optional] For UTXOs,
gasPrice string [optional] For Ethereum assets (ETH and Tokens)
gasLimit string [optional] For Ethereum assets (ETH and Tokens), the limit for how much can be used
networkFee string [optional] Transaction fee

EstimatedTransactionFeeResponse

Parameter Type Description
low TransactionFee Transactions with this fee will probably take longer to be mined
medium TransactionFee Average transactions fee
high TransactionFee Transactions with this fee should be mined the fastest

AmountInfo

Parameter Type Description
amount string If the transfer is a withdrawal from an exchange, the actual amount that was requested to be transferred. Otherwise, the requested amount
requestedAmount string The amount requested by the user
netAmount string The net amount of the transaction, after fee deduction
amountUSD string The USD value of the requested amount

FeeInfo

Parameter Type Description
networkFee string The fee paid to the network
serviceFee string The total fee deducted by the exchange from the actual requested amount (serviceFee = amount - netAmount)

SetConfirmationsThresholdResponse

Parameter Type Description
success boolean
transactions array of strings txIds of the transactions

AmlScreeningResult

Parameter Type Description
provider string The AML service provider
payload string The response of the AML service provider

RawMessageData

Parameter Type Description
messages array of UnsignedMessage objects The messages that should be signed
algorithm string [optional] The algorithm which will be used to sign the transaction, one of the SigningAlgorithms

UnsignedMessage

Parameter Type Description
content string The message to be signed in hex format encoding
bip44addressIndex number [optional] BIP44 address_index path level
bip44change number [optional] BIP44 change path level
The 2 fields above complement the derivation path given the source id and asset were provided in the transaction body request.
In case none of the above was provided, please specify the derivation path.
derivationPath array of numbers [optional] Should be passed only if asset and source were not specified

SigningAlgorithm

Parameter Type Description
algorithm string [ MPC_ECDSA_SECP256K1, MPC_ECDSA_SECP256R1, MPC_EDDSA_ED25519 ]

OneTimeAddress

Parameter Type Description
address string Transfer destination address
tag string Transfer destination tag (for Ripple, 'memo' for EOS/XLM), for SEN/Signet used as Bank Transfer Description

Network Objects

NetworkRecord

Parameter Type Description
source TransferPeerPathResponse Source of the transaction
destination TransferPeerPathResponse Destination of the transaction
txHash string Blockchain hash of the transaction
networkFee number The fee paid to the network
assetId string Transaction asset
netAmount number The net amount of the transaction, after fee deduction
status NetworkStatus Status of the blockchain transaction
type string Type of the operation
destinationAddress string Destination address

NetworkConnection

Parameter Type Description
id string The ID of the Network Connection
localChannel Channel Local channel ID
remoteChannel Channel Remote channel ID

Channel

Parameter Type Description
networkId string 8 characters ID of the channel
name string The name of the channel

Fiat Account Objects

FiatAccount

Parameter Type Description
id string The ID of the account
type string [ SIGNET, SILVERGATE ]
name string Display name of the fiat account
address string The address of the account
assets Array of FiatAssets Array of the assets under the account

FiatAsset

Parameter Type Description
id string The ID of the asset
balance string The balance of the asset

Supported Assets Object

AssetTypeResponse

Parameter Type Description
id string The ID of the asset
name string The name of the asset
type string [ BASE_ASSET, ETH_CONTRACT, FIAT ]
contractAddress string Contract address for ERC-20 smart contracts

Smart Transfers Objects

TransferTicket

Parameter Type Description
ticketId string Transfer ticket ID on the Fireblocks platform
terms array of TransferTicketTerms All the terms of the transfer ticket
externalTicketId string [optional] Ticket ID on customer's internal system. Can be used for reference
description string [optional] Custom string set by the user
status TransferTicketStatus The current status of the transfer ticket

TransferTicketTerm

Parameter Type Description
networkConnectionId string The Fireblocks network connection on which this term should be fulfilled
outgoing boolean True means that the term is from the initiator of the ticket
asset string The asset of term that was agreed on
amount string The amount of the asset that should be transferred
note string [optional] Custom note that can be added to the term

TransferTicketTermResponse

Parameter Type Description
termId string The ID of the term within the ticket context, a running index.
networkConnectionId string The Fireblocks network connection on which this term should be fulfilled
outgoing boolean True means that the term is from the initiator of the ticket
asset string The asset of term that was agreed on
amount string The amount of the asset that should be transferred
txIds array of strings Transactions associated with this term
status TransferTicketTermStatus Status of the term
note string Custom note that can be added to the term

Gas Station Objects

GasStationInfo

Parameter Type Description
balance dictionary A dictionary of an asset and its balance in the Gas Station
configuration GasStationConfiguration The settings of your Gas Station

GasStationConfiguration

Parameter Type Description
gasThreshold string Below this ETH balane the address will be funded up until gasCap value, in ETH units
gasCap string Up to this level the address will be funded with ETH, in ETH units
maxGasPrice string The funding transaction will be sent with this maximum value gas price, in Gwei units

General Objects

ConfigChangeRequestStatus

Parameter Type Description
status string [ WAITING_FOR_APPROVAL, APPROVED, CANCELLED, REJECTED, FAILED ]

API Co-Signer

Overview

The API Co-Signer is a component that holds an MPC key share of a customer's Fireblocks Vault and a Configuration Change Key for automated signing and approvals. The key share is used to securely sign transactions initiated via the API. The Configuration Change Key is used to approve new unmanaged wallet additions in the Fireblocks Vault.
The API Co-Signer can be provisioned with a Co-Signer Callback Handler, an HTTPS server that receives signing requests from the API Co-Signer and returns to the co-signer either an approval or rejection response. For more details on how to handle a co-signer request and how to structure your response, please see the Automated Signer Callback section below.
Please refer to this article for setup instruction.

Automated Transaction Flow Diagram

Signing flow

Automated Signer Callback

In case the API Co-Signer is configured with a callback, it will send a POST request to that predefined HTTPS server that should respond with APPROVE, REJECT or IGNORE action. IGNORE can be returned only for transaction authorization or configuration change. This server should listen on the endpoints described below and respond accordingly to the needed action. Customer callback to approve or reject the signing.

Transaction Signing Callback Handler

# -*- coding: utf-8 -*-
"""
App runner
"""
# Third-party imports
import falcon
import json

class TransferRequest(object):
    def on_post(self, req, resp):
        raw_json = req.bounded_stream.read()
        obj = json.loads(raw_json.decode("utf-8"))
        # Prints the received object
        print(obj)
        # In this example always approves
        resp.body = json.dumps({'action': 'APPROVE'})
        resp.status = falcon.HTTP_200


# Create falcon app
app = falcon.API()

app.add_route('/tx_sign_request', TransferRequest())

""" Useful for debugging problems in API, it works with pdb
if __name__ == '__main__':
    from wsgiref import simple_server  # NOQA
    httpd = simple_server.make_server('127.0.0.1', 8000, app)
    httpd.serve_forever()
"""

POST /tx_sign_request

Returns a CallbackResponse object.

Parameters sent
Parameter Type Description
txId string Fireblocks' internal transaction ID
operation string The type of the operation
sourceType string Whether the transfer is from Fireblocks vault or exchange (VAULT or EXCHANGE)
sourceId string The ID of the vault account or the exchange account UUID
destType string The destination of the transaction (VAULT or EXCHANGE or UNMANAGED)
destAddressType string WHITELISTED or ONE_TIME
destId string The ID of the destination
asset string The asset symbol
amount number The amount of the transfer
amountStr string The amount of the transfer in string representation
destAddress string The destination address of the transfer
fee string [optional] The fee of the transaction
extraParameters [optional] JSON object Use for protocol / operation specific parameters. For raw transactions - pass rawMessageData field

Configuration Approval Callback Handler

POST /config_change_sign_request

Returns a CallbackResponse object.

Parameters sent
Parameter Type Description
type string [ UNMANAGED_WALLET, EXCHANGE, FIAT_ACCOUNT ]
extraInfo JSON object Either AddressInfo or ThirdPartyInfo json object

Co-Signer Data Objects

AddressInfo

Parameter Type Description
subType string [ INTERNAL, EXTERNAL ]
walletName string The name of the wallet as defined in the workspace
walletId string Fireblocks' internal wallet ID
asset string Wallet's asset
address string The address of the asset in the wallet
tag string [optional] For assets that have tag/memo (XRP/EOS/XLM), for SEN/Signet used as Bank Transfer Description

ThirdPartyInfo

Parameter Type Description
subType ThirdPartyType The third party
accountName string The name of the account
accountId string The ID of the account
apiKey string Third party's API key
addresses string [optional] A JSON formated "key":"value" string, where the key is an asset symbol (asset symbols can be retrieved at the supported-assets and the value is its address. There can be multiple entries in the JSON.

CallbackResponse

Parameter Type Description
action string [APPROVE, REJECT, IGNORE]
rejectionReason string Free text of the rejection reason for logging purposes

Webhook

Overview

Setting a webhook will allow you to get notifications for events that happen on your Fireblocks workspace. You can receive notifications on events in your workspace such as incoming/outgoing transactions, transactions status update, new vault accounts, new wallets, new external/internal addresses and many more.

In order to connect a Webhook to your Fireblocks workspace please contact Fireblocks Support and provide your Webhook's URL. Once your Webhook is connected to your Fireblocks workspace, Fireblocks will provide you with a public key to verify the signature of incoming events. All events will be sent with the following headers:

Fireblocks will send a POST request to the URL(s) associated with the workspace and expect a 200 response. If no response is received, Fireblocks will resend the request several more times with an increasing delay between each attempt, the retry attemps will be taken after 15 seconds, 1 minute and 5 minutes.

Please download the public key for signature validation here.
On the language tabs you can find examples on how to setup up the server and verify the signature header of the request.

Event Types

Below you can find the list of all events your webhook will receive notifications for.

# -*- coding: utf-8 -*-
"""
App runner
"""
# Third-party imports
import falcon
import json
import rsa
import base64

FIREBLOCKS_PUBLIC_KEY = """
-----BEGIN PUBLIC KEY-----
MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA0+6wd9OJQpK60ZI7qnZG
jjQ0wNFUHfRv85Tdyek8+ahlg1Ph8uhwl4N6DZw5LwLXhNjzAbQ8LGPxt36RUZl5
YlxTru0jZNKx5lslR+H4i936A4pKBjgiMmSkVwXD9HcfKHTp70GQ812+J0Fvti/v
4nrrUpc011Wo4F6omt1QcYsi4GTI5OsEbeKQ24BtUd6Z1Nm/EP7PfPxeb4CP8KOH
clM8K7OwBUfWrip8Ptljjz9BNOZUF94iyjJ/BIzGJjyCntho64ehpUYP8UJykLVd
CGcu7sVYWnknf1ZGLuqqZQt4qt7cUUhFGielssZP9N9x7wzaAIFcT3yQ+ELDu1SZ
dE4lZsf2uMyfj58V8GDOLLE233+LRsRbJ083x+e2mW5BdAGtGgQBusFfnmv5Bxqd
HgS55hsna5725/44tvxll261TgQvjGrTxwe7e5Ia3d2Syc+e89mXQaI/+cZnylNP
SwCCvx8mOM847T0XkVRX3ZrwXtHIA25uKsPJzUtksDnAowB91j7RJkjXxJcz3Vh1
4k182UFOTPRW9jzdWNSyWQGl/vpe9oQ4c2Ly15+/toBo4YXJeDdDnZ5c/O+KKadc
IMPBpnPrH/0O97uMPuED+nI6ISGOTMLZo35xJ96gPBwyG5s2QxIkKPXIrhgcgUnk
tSM7QYNhlftT4/yVvYnk0YcCAwEAAQ==
-----END PUBLIC KEY-----
"""

signature_pub_key = rsa.PublicKey.load_pkcs1_openssl_pem(FIREBLOCKS_PUBLIC_KEY)

class RequestBodyMiddleware(object):
    def process_request(self, req, resp):
        req.body = req.bounded_stream.read()

class AuthMiddleware(object):
    def process_request(self, req, resp):
        signature = req.get_header('Fireblocks-Signature')

        if signature is None:
            raise falcon.HTTPUnauthorized('Signature required')

        if not self._signature_is_valid(req.body, signature):
            raise falcon.HTTPUnauthorized('Invalid signature')

    def _signature_is_valid(self,  body, signature):
        try:
            hashing_alg = rsa.verify(body, base64.b64decode(signature), signature_pub_key)
            return hashing_alg == "SHA-512"
        except rsa.pkcs1.VerificationError:
            return False

class DummyRequest(object):
    def on_post(self, req, resp):
        obj = json.loads(req.body.decode("utf-8"))
        print(obj)
        resp.status = falcon.HTTP_201


# Create falcon app
app = falcon.API(
    middleware=[
        RequestBodyMiddleware(),
        AuthMiddleware()
    ]
)

app.add_route('/webhook', DummyRequest())


if __name__ == '__main__':
    from wsgiref import simple_server  # NOQA
    httpd = simple_server.make_server('127.0.0.1', 8000, app)
    httpd.serve_forever()
const crypto = require("crypto");
const express = require("express");
const bodyParser = require('body-parser')

const port = 3000;

const publicKey = `-----BEGIN PUBLIC KEY-----
MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA0+6wd9OJQpK60ZI7qnZG
jjQ0wNFUHfRv85Tdyek8+ahlg1Ph8uhwl4N6DZw5LwLXhNjzAbQ8LGPxt36RUZl5
YlxTru0jZNKx5lslR+H4i936A4pKBjgiMmSkVwXD9HcfKHTp70GQ812+J0Fvti/v
4nrrUpc011Wo4F6omt1QcYsi4GTI5OsEbeKQ24BtUd6Z1Nm/EP7PfPxeb4CP8KOH
clM8K7OwBUfWrip8Ptljjz9BNOZUF94iyjJ/BIzGJjyCntho64ehpUYP8UJykLVd
CGcu7sVYWnknf1ZGLuqqZQt4qt7cUUhFGielssZP9N9x7wzaAIFcT3yQ+ELDu1SZ
dE4lZsf2uMyfj58V8GDOLLE233+LRsRbJ083x+e2mW5BdAGtGgQBusFfnmv5Bxqd
HgS55hsna5725/44tvxll261TgQvjGrTxwe7e5Ia3d2Syc+e89mXQaI/+cZnylNP
SwCCvx8mOM847T0XkVRX3ZrwXtHIA25uKsPJzUtksDnAowB91j7RJkjXxJcz3Vh1
4k182UFOTPRW9jzdWNSyWQGl/vpe9oQ4c2Ly15+/toBo4YXJeDdDnZ5c/O+KKadc
IMPBpnPrH/0O97uMPuED+nI6ISGOTMLZo35xJ96gPBwyG5s2QxIkKPXIrhgcgUnk
tSM7QYNhlftT4/yVvYnk0YcCAwEAAQ==
-----END PUBLIC KEY-----`.replace(/\\n/g, "\n");

const app = express();

app.use(bodyParser.json());

app.post("/webhook", (req, res) => {
    const message = JSON.stringify(req.body);
    const signature = req.headers["Fireblocks-Signature"];

    const verifier = crypto.createVerify('RSA-SHA512');
    verifier.write(message);
    verifier.end();

    const isVerified = verifier.verify(publicKey, signature, "base64");
    console.log("Verified:", isVerified);

    res.send("ok");
});

app.listen(port, () => {
    console.log(`Webhook running at http://localhost:${port}`);
});

Event Data Description
TRANSACTION_CREATED TransactionCreated Sent upon any new transaction identified in the workspace
TRANSACTION_STATUS_UPDATED TransactionStatusUpdated Sent upon any change in the status of a transaction or number of confirmations update
VAULT_ACCOUNT_ADDED VaultAccountAdded Sent upon addition of a new vault account in the workspace
VAULT_ACCOUNT_ASSET_ADDED VaultAccountAssetAdded Sent upon addition of a new asset under a vault account
INTERNAL_WALLET_ASSET_ADDED InternalWalletAssetAdded Sent upon addition of a new asset under an internal wallet
EXTERNAL_WALLET_ASSET_ADDED ExternalWalletAssetAdded Sent upon addition of a new asset under an external wallet
EXCHANGE_ACCOUNT_ADDED ExchangeAccountAdded Sent upon addition of a new exchange account
FIAT_ACCOUNT_ADDED FiatAccountAdded Sent upon addition of a new fiat account
NETWORK_CONNECTION_ADDED NetworkConnectionAdded Sent upon addition of a new network connection

Event Objects

TransactionCreated

Parameter Type Description
type string TRANSACTION_CREATED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data TransactionDetails All the transaction information

TransactionStatusUpdated

Parameter Type Description
type string TRANSACTION_STATUS_UPDATED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data TransactionDetails All the transaction information

VaultAccountAdded

Parameter Type Description
type string VAULT_ACCOUNT_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data VaultAccount Vault wallet details

VaultAccountAssetAdded

Parameter Type Description
type string VAULT_ACCOUNT_ASSET_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data AssetAddedData Vault wallet details

AssetAddedData

Parameter Type Description
accountId string The ID of the vault account under which the wallet was added
tenantId string Unique id of your Fireblocks' workspace
accountName string The name of the vault account under which the wallet was added
assetId string Wallet's asset

InternalWalletAssetAdded

Parameter Type Description
type string INTERNAL_WALLET_ASSET_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data WalletAssetWebhook Internal wallet details

ExternalWalletAssetAdded

Parameter Type Description
type string EXTERNAL_WALLET_ASSET_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data WalletAssetWebhook External wallet details

ExchangeAccountAdded

Parameter Type Description
type string EXCHANGE_ACCOUNT_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data ThirdPartyWebhook Exchange accounts details

FiatAccountAdded

Parameter Type Description
type string FIAT_ACCOUNT_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data ThirdPartyWebhook Fiat account details

NetworkConnectionAdded

Parameter Type Description
type string NETWORK_CONNECTION_ADDED
tenantId string Unique id of your Fireblocks' workspace
timestamp number Timestamp in milliseconds
data NetworkConnection Network connection details

Data Objects

WalletAssetWebhook

Parameter Type Description
assetId string The wallet's asset
id string The ID of the wallet
name string The name of wallet
address string The address of the wallet
tag string Destination tag (for XRP, used as memo for EOS/XLM and as Bank Transfer Description for Signet/SEN) of the wallet
activationTime string The time the wallet will be activated in case wallets activation posponed according to workspace definition

ThirdPartyWebhook

Parameter Type Description
id string Id of the thirdparty account on the Fireblocks platform
subType string Subtype of the third party, ie. exchange or fiat name
name string Account name

Transfer Statuses

TransactionStatus

TransactionSubStatus

NetworkStatus

TransferTicketStatus

TransferTicketTermStatus