Solana.RPC.Request (Solana v0.1.0)
View SourceFunctions for creating Solana JSON-RPC API requests.
This client only implements the most common methods (see the function documentation below). If you need a method that's on the full list but is not implemented here, please open an issue or contact the maintainers.
Summary
Functions
Encodes a Solana.RPC.Request.t/0
(or a list of them) in the required
format.
Returns all information associated with the account of the provided Pubkey.
Returns the balance of the provided pubkey's account.
Returns identity and transaction information about a confirmed block in the ledger.
Returns the current block height of the node
Get the fee the network will charge for a particular Message
Returns the slot of the lowest confirmed block that has not been purged from the ledger.
Returns a recent block hash from the ledger, and a fee schedule that can be used to compute the cost of submitting a transaction using it.
Returns minimum balance required to make an account rent exempt.
Returns the account information for a list of pubkeys.
Returns the statuses of a list of signatures.
Returns confirmed signatures for transactions involving an address backwards in time from the provided signature or most recent confirmed block.
Returns the 20 largest accounts of a particular SPL Token type.
Returns the total supply of an SPL Token.
Returns transaction details for a confirmed transaction.
Requests an airdrop of lamports to an account.
Submits a signed transaction to the cluster for processing.
Types
Functions
Encodes a Solana.RPC.Request.t/0
(or a list of them) in the required
format.
@spec get_account_info(account :: Solana.key(), opts :: keyword()) :: t()
Returns all information associated with the account of the provided Pubkey.
For more information, see the Solana docs.
@spec get_balance(account :: Solana.key(), opts :: keyword()) :: t()
Returns the balance of the provided pubkey's account.
For more information, see the Solana docs.
@spec get_block(slot :: non_neg_integer(), opts :: keyword()) :: t()
@spec get_block(slot :: non_neg_integer(), opts :: keyword()) :: t()
Returns identity and transaction information about a confirmed block in the ledger.
For more information, see the Solana docs.
Returns the current block height of the node
For more information, see the Solana docs.
Get the fee the network will charge for a particular Message
For more information, see the Solana docs.
@spec get_first_available_block() :: t()
Returns the slot of the lowest confirmed block that has not been purged from the ledger.
For more information, see the Solana docs.
Returns a recent block hash from the ledger, and a fee schedule that can be used to compute the cost of submitting a transaction using it.
For more information, see the Solana docs.
@spec get_minimum_balance_for_rent_exemption( length :: non_neg_integer(), opts :: keyword() ) :: t()
Returns minimum balance required to make an account rent exempt.
For more information, see the Solana docs.
@spec get_multiple_accounts(accounts :: [Solana.key()], opts :: keyword()) :: t()
Returns the account information for a list of pubkeys.
For more information, see the Solana docs.
@spec get_signature_statuses(signatures :: [Solana.key()], opts :: keyword()) :: t()
Returns the statuses of a list of signatures.
Unless the searchTransactionHistory
configuration parameter is included,
this method only searches the recent status cache of signatures, which retains
statuses for all active slots plus MAX_RECENT_BLOCKHASHES
rooted slots.
For more information, see the Solana docs.
@spec get_signatures_for_address(account :: Solana.key(), opts :: keyword()) :: t()
Returns confirmed signatures for transactions involving an address backwards in time from the provided signature or most recent confirmed block.
For more information, see the Solana docs.
@spec get_token_account_balance(account :: Solana.key(), opts :: keyword()) :: t()
@spec get_token_largest_accounts(mint :: Solana.key(), opts :: keyword()) :: t()
Returns the 20 largest accounts of a particular SPL Token type.
For more information, see the Solana docs.
@spec get_token_supply(mint :: Solana.key(), opts :: keyword()) :: t()
Returns the total supply of an SPL Token.
For more information, see the Solana docs.
@spec get_transaction(signature :: Solana.key(), opts :: keyword()) :: t()
Returns transaction details for a confirmed transaction.
For more information, see the Solana docs.
@spec request_airdrop( account :: Solana.key(), sol :: pos_integer(), opts :: keyword() ) :: t()
Requests an airdrop of lamports to an account.
For more information, see the Solana docs.
@spec send_transaction(transaction :: Solana.Transaction.t(), opts :: keyword()) :: t()
Submits a signed transaction to the cluster for processing.
For more information, see the Solana docs.