Prime SDK
Data Service
Along with using the Prime SDK, developers can make use of the data service to retreive information such as Account Balances.
For making these api-calls, you’ll need to get a data service api key.
Without passing one in, there is a default key which is very heavily rate limited.
Code example
Start by importing DataUtils from the Prime SDK like so:
Then initialise the Data Service with your api key:
Finally, call one of the functions listed below:
Function List
Function Name | Description |
---|---|
getAccountBalances() | Returns the Account Balance. |
getTransaction() | Returns details about a transaction. |
getNftList() | Returns a list of NFTs that the account owns. |
getExchangeSupportedAssets() | Returns exchange supported tokens on the account. |
getExchangeOffers() | Returns a list of exchange offers between two assets. |
getAdvanceRoutesLiFi() | Returns bridging routes between two assets via LiFi. |
getStepTransaction() | |
getCrossChainQuotes() | Returns bridging routes between two assets |
getTokenLists() | Returns a token list. |
getTokenListTokens() | Returns a specific token from the list. |
fetchExchangeRates() | Returns exchange rates between two tokens. |