FireblocksSdk.Api.Tokenization (FireblocksSdk v0.2.3)

Copy Markdown View Source

Summary

Functions

Returns the latest token balance for the specified account address.

Returns paginated balance history for the specified account address with optional time-range filtering.

Returns the latest balance for each unique address holding this token.

Get the total count of linked tokens

Facilitates the creation of a new token, supporting both EVM-based and Stellar/Ripple platforms. For EVM, it deploys the corresponding contract template to the blockchain and links the token to the workspace. For Stellar/Ripple, it links a newly created token directly to the workspace without deploying a contract. Returns the token link with status "PENDING" until the token is deployed or "SUCCESS" if no deployment is needed.

Return a linked token, with its status and metadata.

Get a deterministic address for contract deployment. The address is derived from the contract's bytecode and provided salt. This endpoint is used to get the address of a contract that will be deployed in the future.

Return a linked token, with its status and metadata.

Link an existing token to the workspace.

Return all linked tokens (paginated)

Returns a list of currently active roles for the token contract.

Returns the total number of unique holders and the total supply for the token contract.

Returns a paginated list of onchain transactions for the token contract, optionally filtered by date range.

Returns a paginated list of ERC20 transfer events for the token contract, optionally filtered by date range.

Unlink a token. The token will be unlinked from the workspace. The token will not be deleted on chain nor the refId, only the link to the workspace will be removed.

Functions

balance(token_id, wallet)

Returns the latest token balance for the specified account address.

balance_history(opts)

Returns paginated balance history for the specified account address with optional time-range filtering.

Options:

  • :id (String.t/0) - Required. The token link id

  • :accountAddress (String.t/0) - Required. The account address to get balance history for

  • :startDate (String.t/0) - Start date of the time range in ISO 8601 format

  • :endDate (String.t/0) - End date of the time range in ISO 8601 format

  • :interval - Time interval for grouping data The default value is :day.

  • :pageCusor (String.t/0) - Page cursor to get the next page

  • :pageSize (non_neg_integer/0) - Number of items per page (max 100), requesting more than 100 will return 100 items The default value is 10.

  • :sortBy - Sorting only supported by 'blockTimestamp' The default value is :blockTimestamp.

  • :order - ASC / DESC ordering (default DESC) The default value is :desc.

balances(opts)

Returns the latest balance for each unique address holding this token.

FireblocksSdk.Api.Tokenization.balances([
  id: fbfbfbfb-fbfb-fbfb-fbfb-fbfbfbfbfbfb
])

Options:

  • :id (String.t/0) - Required. The token link id

  • :pageCursor (String.t/0) - Page cursor to get the next page

  • :pageSize (non_neg_integer/0) - The default value is 10.

  • :sortBy - Sorting field for transfers The default value is :blockTimestamp.

  • :order - The default value is :desc.

count()

Get the total count of linked tokens

create(params, idempotentKey \\ "")

Facilitates the creation of a new token, supporting both EVM-based and Stellar/Ripple platforms. For EVM, it deploys the corresponding contract template to the blockchain and links the token to the workspace. For Stellar/Ripple, it links a newly created token directly to the workspace without deploying a contract. Returns the token link with status "PENDING" until the token is deployed or "SUCCESS" if no deployment is needed.

Options:

get(token_id)

Return a linked token, with its status and metadata.

get_deterministic_address(params, idempotentKey \\ "")

Get a deterministic address for contract deployment. The address is derived from the contract's bytecode and provided salt. This endpoint is used to get the address of a contract that will be deployed in the future.

Options:

  • :chainDescriptor (String.t/0) - Required. The base asset identifier of the blockchain (legacyId) to calculate deterministic address. Example: 'ETH'

  • :templateId (String.t/0) - Required. The template identifier (UUID). Example: 'b70701f4-d7b1-4795-a8ee-b09cdb5b850d'

  • :initParams (list of map/0) - Required. The deploy function parameters and values of the contract template. See ParameterWithValue schema.

  • :salt (String.t/0) - Required. The salt to calculate the deterministic address. Must be a number between 0 and 2^256 -1, for it to fit in the bytes32 parameter. Example: '123456789'

get_link(link_id)

Return a linked token, with its status and metadata.

get_template(id)

link(link_req, idempotentKey \\ "")

Link an existing token to the workspace.

Options:

  • :type - Required. The type of token being link. Available values: :fungible, :non_fungible_token, :token_utility, :token_extension

  • :refId (String.t/0) - The Fireblocks' token link reference id. For example, 'BQ5R_BDESC_ABC' if it's a fungible asset

  • :displayName (String.t/0) - The token display name

  • :baseAssetId (String.t/0) - The blockchain base assetId

  • :contractAddress (String.t/0) - The contract's onchain address

list(filter)

Return all linked tokens (paginated)

Options:

rbac(token_id)

Returns a list of currently active roles for the token contract.

summary(token_id)

Returns the total number of unique holders and the total supply for the token contract.

templates()

transactions(opts)

Returns a paginated list of onchain transactions for the token contract, optionally filtered by date range.

FireblocksSdk.Api.Tokenization.transactions([
  id: fbfbfbfb-fbfb-fbfb-fbfb-fbfbfbfbfbfb
])

Options:

  • :id (String.t/0) - Required. The token link id

  • :startDate (String.t/0) - Start date of the time range in ISO 8601 format

  • :endDate (String.t/0) - End date of the time range in ISO 8601 format

  • :pageCursor (String.t/0) - Page cursor to get the next page

  • :pageSize (non_neg_integer/0) - The default value is 10.

  • :sortBy - Sorting field for transfers The default value is :blockTimeStamp.

  • :order - The default value is :desc.

  • :sender (String.t/0) - Filter transfers by sender address

  • :receiver (String.t/0) - Filter transfers by receiver address

transfers(opts)

Returns a paginated list of ERC20 transfer events for the token contract, optionally filtered by date range.

FireblocksSdk.Api.Tokenization.transfers([
  id: fbfbfbfb-fbfb-fbfb-fbfb-fbfbfbfbfbfb
])

Options:

  • :id (String.t/0) - Required. The token link id

  • :startDate (String.t/0) - Start date of the time range in ISO 8601 format

  • :endDate (String.t/0) - End date of the time range in ISO 8601 format

  • :pageCursor (String.t/0) - Page cursor to get the next page

  • :pageSize (non_neg_integer/0) - The default value is 10.

  • :sortBy - Sorting field for transfers The default value is :blockTimeStamp.

  • :order - The default value is :desc.

  • :sender (String.t/0) - Filter transfers by sender address

  • :receiver (String.t/0) - Filter transfers by receiver address

unlink(link_id)

Unlink a token. The token will be unlinked from the workspace. The token will not be deleted on chain nor the refId, only the link to the workspace will be removed.