EosioRpcProvider
public class EosioRpcProvider
extension EosioRpcProvider: EosioRpcProviderProtocol
Default RPC Provider implementation. Conforms to EosioRpcProviderProtocol.
RPC Reference: https://developers.eos.io/eosio-nodeos/reference
-
The blockchain ID that all RPC calls for an active instance of EosioRpcProvider should be interacting with.
Declaration
Swift
public var chainId: String? -
Initialize the default RPC Provider implementation with one RPC node endpoint.
Declaration
Swift
public convenience init(endpoint: URL, retries: Int = 3, delayBeforeRetry: Int = 1)Parameters
endpointA node URL.
retriesNumber of times to retry an endpoint before failing (default is 3 tries).
delayBeforeRetryNumber of seconds to wait between each retry (default is 1 second).
-
Initialize the default RPC Provider implementation with a list of RPC node endpoints. Extra endpoints will be used for failover purposes.
Declaration
Swift
public init(endpoints: [URL], retries: Int = 3, delayBeforeRetry: Int = 1)Parameters
endpointsA list of node URLs.
retriesNumber of times to retry an endpoint before failing over to the next (default is 3 tries).
delayBeforeRetryNumber of seconds to wait between each retry (default is 1 second).
-
Call
chain/get_account. Fetch an account by account name.Declaration
Swift
public func getAccount(requestParameters: EosioRpcAccountRequest, completion: @escaping (EosioResult<EosioRpcAccountResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcAccountResponseand an optionalEosioError. -
Call
chain/get_block. Get a block by block number or ID.Declaration
Swift
public func getBlock(requestParameters: EosioRpcBlockRequest, completion: @escaping (EosioResult<EosioRpcBlockResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcBlockResponseand an optionalEosioError. -
Call
chain/get_block_info. Get a block by block number or ID.Declaration
Swift
public func getBlockInfo(requestParameters: EosioRpcBlockInfoRequest, completion: @escaping (EosioResult<EosioRpcBlockInfoResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcBlockInfoResponseand an optionalEosioError. -
Call
chain/get_info. Get information about the chain and node.Declaration
Swift
public func getInfo(completion: @escaping (EosioResult<EosioRpcInfoResponse, EosioError>) -> Void)Parameters
completionCalled with the response, as an
EosioResultconsisting of anEosioRpcInfoResponseand an optionalEosioError. -
Call
chain/push_transaction. Push a transaction to the blockchain!Declaration
Swift
public func pushTransaction(requestParameters: EosioRpcPushTransactionRequest, completion: @escaping (EosioResult<EosioRpcTransactionResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcTransactionResponseand an optionalEosioError. -
Call
chain/push_transactions. Push multiple transactions to the chain.Declaration
Swift
public func pushTransactions(requestParameters: EosioRpcPushTransactionsRequest, completion: @escaping (EosioResult<EosioRpcPushTransactionsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcPushTransactionsResponseand an optionalEosioError. -
Call
chain/send_transaction. Send a transaction to the blockchain!Declaration
Swift
public func sendTransaction(requestParameters: EosioRpcSendTransactionRequest, completion: @escaping (EosioResult<EosioRpcTransactionResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcTransactionResponseand an optionalEosioError. -
Call
chain/send_transactions. Send multiple transactions to the chain.Declaration
Swift
public func sendTransactions(requestParameters: EosioRpcSendTransactionsRequest, completion: @escaping (EosioResult<EosioRpcSendTransactionsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcSendTransactionsResponseand an optionalEosioError. -
Call
chain/get_block_header_state.Declaration
Swift
public func getBlockHeaderState(requestParameters: EosioRpcBlockHeaderStateRequest, completion: @escaping (EosioResult<EosioRpcBlockHeaderStateResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcBlockHeaderStateResponseand an optionalEosioError. -
Call
chain/get_abi. Fetch an ABI by account/contract name.Declaration
Swift
public func getAbi(requestParameters: EosioRpcAbiRequest, completion: @escaping (EosioResult<EosioRpcAbiResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcAbiResponseand an optionalEosioError. -
Call
chain/get_currency_balance.Declaration
Swift
public func getCurrencyBalance(requestParameters: EosioRpcCurrencyBalanceRequest, completion: @escaping (EosioResult<EosioRpcCurrencyBalanceResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcCurrencyBalanceResponseand an optionalEosioError. -
Call
chain/get_currency_stats.Declaration
Swift
public func getCurrencyStats(requestParameters: EosioRpcCurrencyStatsRequest, completion: @escaping (EosioResult<EosioRpcCurrencyStatsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcCurrencyStatsResponseand an optionalEosioError. -
Call
chain/get_required_keys. Pass in a transaction and an array of available keys. Get back the subset of those keys required for signing the transaction.Declaration
Swift
public func getRequiredKeys(requestParameters: EosioRpcRequiredKeysRequest, completion: @escaping (EosioResult<EosioRpcRequiredKeysResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcRequiredKeysResponseand an optionalEosioError. -
Call
chain/get_producers.Declaration
Swift
public func getProducers(requestParameters: EosioRpcProducersRequest, completion: @escaping (EosioResult<EosioRpcProducersResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcProducersResponseand an optionalEosioError. -
Call
chain/get_raw_code_and_abi.Declaration
Swift
public func getRawCodeAndAbi(requestParameters: EosioRpcRawCodeAndAbiRequest, completion: @escaping (EosioResult<EosioRpcRawCodeAndAbiResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcRawCodeAndAbiResponseand an optionalEosioError. -
Call
chain/get_raw_code_and_abi. Convenience method called with simple account name.Declaration
Swift
public func getRawCodeAndAbi(accountName: String, completion: @escaping (EosioResult<EosioRpcRawCodeAndAbiResponse, EosioError>) -> Void)Parameters
accountNameThe account name, as a String.
completionCalled with the response, as an
EosioResultconsisting of anEosioRpcRawCodeAndAbiResponseand an optionalEosioError. -
Call
chain/get_table_by_scope.Declaration
Swift
public func getTableByScope(requestParameters: EosioRpcTableByScopeRequest, completion: @escaping (EosioResult<EosioRpcTableByScopeResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcTableByScopeResponseand an optionalEosioError. -
Call
chain/get_table_rows. Returns an object containing rows from the specified table.Declaration
Swift
public func getTableRows(requestParameters: EosioRpcTableRowsRequest, completion: @escaping (EosioResult<EosioRpcTableRowsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcTableRowsResponseand an optionalEosioError. -
Call
chain/get_kv_table_rows. Returns an object containing rows from the specified table.Declaration
Swift
public func getKvTableRows(requestParameters: EosioRpcKvTableRowsRequest, completion: @escaping (EosioResult<EosioRpcKvTableRowsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcKvTableRowsResponseand an optionalEosioError. -
Call
chain/get_code.Declaration
Swift
public func getCode(requestParameters: EosioRpcCodeRequest, completion: @escaping (EosioResult<EosioRpcCodeResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcCodeResponseand an optionalEosioError. -
Call
chain/get_code. Convenience method called with simple account name.Declaration
Swift
public func getCode(accountName: String, completion: @escaping (EosioResult<EosioRpcCodeResponse, EosioError>) -> Void)Parameters
accountNameThe account/contract name, as a String.
completionCalled with the response, as an
EosioResultconsisting of anEosioRpcCodeResponseand an optionalEosioError. -
Call
chain/get_raw_abi. Get a raw abi.Declaration
Swift
public func getRawAbi(requestParameters: EosioRpcRawAbiRequest, completion: @escaping (EosioResult<EosioRpcRawAbiResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcRawAbiResponseand an optionalEosioError. -
Call
history/get_actions.Declaration
Swift
public func getActions(requestParameters: EosioRpcHistoryActionsRequest, completion: @escaping (EosioResult<EosioRpcActionsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcActionsResponseand an optionalEosioError. -
Call
history/get_transaction.Declaration
Swift
public func getTransaction(requestParameters: EosioRpcHistoryTransactionRequest, completion: @escaping (EosioResult<EosioRpcGetTransactionResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcGetTransactionResponseand an optionalEosioError. -
Call
history/get_key_accounts.Declaration
Swift
public func getKeyAccounts(requestParameters: EosioRpcHistoryKeyAccountsRequest, completion: @escaping (EosioResult<EosioRpcKeyAccountsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcKeyAccountsResponseand an optionalEosioError. -
Call
history/get_controlled_accounts.Declaration
Swift
public func getControlledAccounts(requestParameters: EosioRpcHistoryControlledAccountsRequest, completion: @escaping (EosioResult<EosioRpcControlledAccountsResponse, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of anEosioRpcControlledAccountsResponseand an optionalEosioError. -
Call
chain/get_accountand get a Publisher back. Fetch an account by account name.Declaration
Swift
public func getAccountPublisher(requestParameters: EosioRpcAccountRequest) -> AnyPublisher<EosioRpcAccountResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcAccountResponseor rejected with anEosioError. -
Call
chain/get_blockand get a Publisher back. Get a block by block number or ID.Declaration
Swift
public func getBlockPublisher(requestParameters: EosioRpcBlockRequest) -> AnyPublisher<EosioRpcBlockResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcBlockResponseor rejected with anEosioError. -
Call
chain/get_block_infoand get a Publisher back. Get a block by block number.Declaration
Swift
public func getBlockInfoPublisher(requestParameters: EosioRpcBlockInfoRequest) -> AnyPublisher<EosioRpcBlockInfoResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcBlockInfoResponseor rejected with anEosioError. -
Call
chain/get_infoand get a Publisher back. Get information about the chain and node.Declaration
Swift
public func getInfoPublisher() -> AnyPublisher<EosioRpcInfoResponse, EosioError>Return Value
A Publisher fulfilled with an
EosioRpcInfoResponseor rejected with anEosioError. -
Call
chain/push_transactionand get a Publisher back. Push a transaction to the blockchain!Declaration
Swift
public func pushTransactionPublisher(requestParameters: EosioRpcPushTransactionRequest) -> AnyPublisher<EosioRpcTransactionResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcTransactionResponseor rejected with anEosioError. -
Call
chain/push_transactionsand get a Publisher back. Push multiple transactions to the chain.Declaration
Swift
public func pushTransactionsPublisher(requestParameters: EosioRpcPushTransactionsRequest) -> AnyPublisher<EosioRpcPushTransactionsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcPushTransactionsResponseor rejected with anEosioError. -
Call
chain/send_transactionand get a Publisher back. Send a transaction to the blockchain!Declaration
Swift
public func sendTransactionPublisher(requestParameters: EosioRpcSendTransactionRequest) -> AnyPublisher<EosioRpcTransactionResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcTransactionResponseor rejected with anEosioError. -
Call
chain/send_transactionsand get a Publisher back. Send multiple transactions to the chain.Declaration
Swift
public func sendTransactionsPublisher(requestParameters: EosioRpcSendTransactionsRequest) -> AnyPublisher<EosioRpcSendTransactionsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcSendTransactionsResponseor rejected with anEosioError. -
Call
chain/get_block_header_stateand get a Publisher back.Declaration
Swift
public func getBlockHeaderStatePublisher(requestParameters: EosioRpcBlockHeaderStateRequest) -> AnyPublisher<EosioRpcBlockHeaderStateResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcBlockHeaderStateResponseor rejected with anEosioError. -
Call
chain/get_abiand get a Publisher back. Fetch an ABI by account/contract name.Declaration
Swift
public func getAbiPublisher(requestParameters: EosioRpcAbiRequest) -> AnyPublisher<EosioRpcAbiResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcAbiResponseor rejected with anEosioError. -
Call
chain/get_currency_balanceand get a Publisher back.Declaration
Swift
public func getCurrencyBalancePublisher(requestParameters: EosioRpcCurrencyBalanceRequest) -> AnyPublisher<EosioRpcCurrencyBalanceResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcCurrencyBalanceResponseor rejected with anEosioError. -
Call
chain/get_currency_statsand get a Publisher back.Declaration
Swift
public func getCurrencyStatsPublisher(requestParameters: EosioRpcCurrencyStatsRequest) -> AnyPublisher<EosioRpcCurrencyStatsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcCurrencyStatsResponseor rejected with anEosioError. -
Call
chain/get_required_keysand get a Publisher back. Pass in a transaction and an array of available keys. Get back the subset of those keys required for signing the transaction.Declaration
Swift
public func getRequiredKeysPublisher(requestParameters: EosioRpcRequiredKeysRequest) -> AnyPublisher<EosioRpcRequiredKeysResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcRequiredKeysResponseor rejected with anEosioError. -
Call
chain/get_producersand get a Publisher back.Declaration
Swift
public func getProducersPublisher(requestParameters: EosioRpcProducersRequest) -> AnyPublisher<EosioRpcProducersResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcProducersResponseor rejected with anEosioError. -
Call
chain/get_raw_code_and_abiand get a Publisher back.Declaration
Swift
public func getRawCodeAndAbiPublisher(requestParameters: EosioRpcRawCodeAndAbiRequest) -> AnyPublisher<EosioRpcRawCodeAndAbiResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcRawCodeAndAbiResponseor rejected with anEosioError. -
Call
chain/get_raw_code_and_abiand get a Publisher back. Convenience method called with simple account name.Declaration
Swift
public func getRawCodeAndAbiPublisher(accountName: String) -> AnyPublisher<EosioRpcRawCodeAndAbiResponse, EosioError>Parameters
accountNameThe account/contract name, as a String.
Return Value
A Publisher fulfilled with an
EosioRpcRawCodeAndAbiResponseor rejected with anEosioError. -
Call
chain/get_table_by_scopeand get a Publisher back.Declaration
Swift
public func getTableByScopePublisher(requestParameters: EosioRpcTableByScopeRequest) -> AnyPublisher<EosioRpcTableByScopeResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcTableByScopeResponseor rejected with anEosioError. -
Call
chain/get_table_rowsand get a Publisher back. Returns an object containing rows from the specified table.Declaration
Swift
public func getTableRowsPublisher(requestParameters: EosioRpcTableRowsRequest) -> AnyPublisher<EosioRpcTableRowsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcTableRowsResponseor rejected with anEosioError. -
Call
chain/get_kv_table_rowsand get a Publisher back. Returns an object containing rows from the specified table.Declaration
Swift
public func getKvTableRowsPublisher(requestParameters: EosioRpcKvTableRowsRequest) -> AnyPublisher<EosioRpcKvTableRowsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcKvTableRowsResponseor rejected with anEosioError. -
Call
chain/get_codeand get a Publisher back.Declaration
Swift
public func getCodePublisher(requestParameters: EosioRpcCodeRequest) -> AnyPublisher<EosioRpcCodeResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcCodeResponseor rejected with anEosioError. -
Call
chain/get_codeand geta Publisher back. Convenience method called with simple account name.Declaration
Swift
public func getCodePublisher(accountName: String) -> AnyPublisher<EosioRpcCodeResponse, EosioError>Parameters
accountNameThe account/contract name, as a String.
Return Value
A Publisher fulfilled with an
EosioRpcCodeResponseor rejected with anEosioError. -
Call
chain/get_raw_abiand get a Publisher back. Get a raw abi.Declaration
Swift
public func getRawAbiPublisher(requestParameters: EosioRpcRawAbiRequest) -> AnyPublisher<EosioRpcRawAbiResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcRawAbiResponseor rejected with anEosioError. -
Call
history/get_actionsand get a Publisher back.Declaration
Swift
public func getActionsPublisher(requestParameters: EosioRpcHistoryActionsRequest) -> AnyPublisher<EosioRpcActionsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcActionsResponseor rejected with anEosioError. -
Call
history/get_transactionand get a Publisher back.Declaration
Swift
public func getTransactionPublisher(requestParameters: EosioRpcHistoryTransactionRequest) -> AnyPublisher<EosioRpcGetTransactionResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcGetTransactionResponseor rejected with anEosioError. -
Call
history/get_key_accountsand get a Publisher back.Declaration
Swift
public func getKeyAccountsPublisher(requestParameters: EosioRpcHistoryKeyAccountsRequest) -> AnyPublisher<EosioRpcKeyAccountsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcKeyAccountsResponseor rejected with anEosioError. -
Call
history/get_controlled_accountsand get a Publisher back.Declaration
Swift
public func getControlledAccountsPublisher(requestParameters: EosioRpcHistoryControlledAccountsRequest) -> AnyPublisher<EosioRpcControlledAccountsResponse, EosioError>Parameters
requestParametersReturn Value
A Publisher fulfilled with an
EosioRpcControlledAccountsResponseor rejected with anEosioError.
RPC methods used by EosioTransaction. These force conformance only to the protocols, not the entire response structs.
-
Call
chain/get_info. This method is called byEosioTransaction, as it only enforces the response protocol, not the entire response struct.Declaration
Swift
public func getInfoBase(completion: @escaping (EosioResult<EosioRpcInfoResponseProtocol, EosioError>) -> Void)Parameters
completionCalled with the response, as an
EosioResultconsisting of a response conforming toEosioRpcInfoResponseProtocoland an optionalEosioError. -
Call
chain/get_block_info. This method is called byEosioTransaction, as it only enforces the response protocol, not the entire response struct.Declaration
Swift
public func getBlockInfoBase(requestParameters: EosioRpcBlockInfoRequest, completion: @escaping (EosioResult<EosioRpcBlockInfoResponseProtocol, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of a response conforming toEosioRpcBlockResponseProtocoland an optionalEosioError. -
Call
chain/get_raw_abi. This method is called byEosioTransaction, as it only enforces the response protocol, not the entire response struct.Declaration
Swift
public func getRawAbiBase(requestParameters: EosioRpcRawAbiRequest, completion: @escaping (EosioResult<EosioRpcRawAbiResponseProtocol, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of a response conforming toEosioRpcRawAbiResponseProtocoland an optionalEosioError. -
Call
chain/get_required_keys. This method is called byEosioTransaction, as it only enforces the response protocol, not the entire response struct.Declaration
Swift
public func getRequiredKeysBase(requestParameters: EosioRpcRequiredKeysRequest, completion: @escaping (EosioResult<EosioRpcRequiredKeysResponseProtocol, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of a response conforming toEosioRpcRequiredKeysResponseProtocoland an optionalEosioError. -
Call
chain/push_transaction. This method is called byEosioTransaction, as it only enforces the response protocol, not the entire response struct.Declaration
Swift
public func pushTransactionBase(requestParameters: EosioRpcPushTransactionRequest, completion: @escaping (EosioResult<EosioRpcTransactionResponseProtocol, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of a response conforming toEosioRpcTransactionResponseProtocoland an optionalEosioError. -
Call
chain/send_transaction. This method is called byEosioTransaction, as it only enforces the response protocol, not the entire response struct.Declaration
Swift
public func sendTransactionBase(requestParameters: EosioRpcSendTransactionRequest, completion: @escaping (EosioResult<EosioRpcTransactionResponseProtocol, EosioError>) -> Void)Parameters
requestParameterscompletionCalled with the response, as an
EosioResultconsisting of a response conforming toEosioRpcTransactionResponseProtocoland an optionalEosioError.
-
Call
chain/get_accountand get a Promise back. Fetch an account by account name.Declaration
Swift
public func getAccount(_: PMKNamespacer, requestParameters: EosioRpcAccountRequest) -> Promise<EosioRpcAccountResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcAccountResponseor rejected with anEosioError. -
Call
chain/get_blockand get a Promise back. Get a block by block number or ID.Declaration
Swift
public func getBlock(_: PMKNamespacer, requestParameters: EosioRpcBlockRequest) -> Promise<EosioRpcBlockResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcBlockResponseor rejected with anEosioError. -
Call
chain/get_block_infoand get a Promise back. Get a block by block number.Declaration
Swift
public func getBlockInfo(_: PMKNamespacer, requestParameters: EosioRpcBlockInfoRequest) -> Promise<EosioRpcBlockInfoResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcBlockInfoResponseor rejected with anEosioError. -
Call
chain/get_infoand get a Promise back. Get information about the chain and node.Declaration
Swift
public func getInfo(_: PMKNamespacer) -> Promise<EosioRpcInfoResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.Return Value
A Promise fulfilled with an
EosioRpcInfoResponseor rejected with anEosioError. -
Call
chain/push_transactionand get a Promise back. Push a transaction to the blockchain!Declaration
Swift
public func pushTransaction(_: PMKNamespacer, requestParameters: EosioRpcPushTransactionRequest) -> Promise<EosioRpcTransactionResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcTransactionResponseor rejected with anEosioError. -
Call
chain/push_transactionsand get a Promise back. Push multiple transactions to the chain.Declaration
Swift
public func pushTransactions(_: PMKNamespacer, requestParameters: EosioRpcPushTransactionsRequest) -> Promise<EosioRpcPushTransactionsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcPushTransactionsResponseor rejected with anEosioError. -
Call
chain/send_transactionand get a Promise back. Send a transaction to the blockchain!Declaration
Swift
public func sendTransaction(_: PMKNamespacer, requestParameters: EosioRpcSendTransactionRequest) -> Promise<EosioRpcTransactionResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcTransactionResponseor rejected with anEosioError. -
Call
chain/send_transactionsand get a Promise back. Send multiple transactions to the chain.Declaration
Swift
public func sendTransactions(_: PMKNamespacer, requestParameters: EosioRpcSendTransactionsRequest) -> Promise<EosioRpcSendTransactionsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcSendTransactionsResponseor rejected with anEosioError. -
Call
chain/get_block_header_stateand get a Promise back.Declaration
Swift
public func getBlockHeaderState(_: PMKNamespacer, requestParameters: EosioRpcBlockHeaderStateRequest) -> Promise<EosioRpcBlockHeaderStateResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcBlockHeaderStateResponseor rejected with anEosioError. -
Call
chain/get_abiand get a Promise back. Fetch an ABI by account/contract name.Declaration
Swift
public func getAbi(_: PMKNamespacer, requestParameters: EosioRpcAbiRequest) -> Promise<EosioRpcAbiResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcAbiResponseor rejected with anEosioError. -
Call
chain/get_currency_balanceand get a Promise back.Declaration
Swift
public func getCurrencyBalance(_: PMKNamespacer, requestParameters: EosioRpcCurrencyBalanceRequest) -> Promise<EosioRpcCurrencyBalanceResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcCurrencyBalanceResponseor rejected with anEosioError. -
Call
chain/get_currency_statsand get a Promise back.Declaration
Swift
public func getCurrencyStats(_: PMKNamespacer, requestParameters: EosioRpcCurrencyStatsRequest) -> Promise<EosioRpcCurrencyStatsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcCurrencyStatsResponseor rejected with anEosioError. -
Call
chain/get_required_keysand get a Promise back. Pass in a transaction and an array of available keys. Get back the subset of those keys required for signing the transaction.Declaration
Swift
public func getRequiredKeys(_: PMKNamespacer, requestParameters: EosioRpcRequiredKeysRequest) -> Promise<EosioRpcRequiredKeysResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcRequiredKeysResponseor rejected with anEosioError. -
Call
chain/get_producersand get a Promise back.Declaration
Swift
public func getProducers(_: PMKNamespacer, requestParameters: EosioRpcProducersRequest) -> Promise<EosioRpcProducersResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcProducersResponseor rejected with anEosioError. -
Call
chain/get_raw_code_and_abiand get a Promise back.Declaration
Swift
public func getRawCodeAndAbi(_: PMKNamespacer, requestParameters: EosioRpcRawCodeAndAbiRequest) -> Promise<EosioRpcRawCodeAndAbiResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcRawCodeAndAbiResponseor rejected with anEosioError. -
Call
chain/get_raw_code_and_abiand get a Promise back. Convenience method called with simple account name.Declaration
Swift
public func getRawCodeAndAbi(_: PMKNamespacer, accountName: String) -> Promise<EosioRpcRawCodeAndAbiResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.accountNameThe account/contract name, as a String.
Return Value
A Promise fulfilled with an
EosioRpcRawCodeAndAbiResponseor rejected with anEosioError. -
Call
chain/get_table_by_scopeand get a Promise back.Declaration
Swift
public func getTableByScope(_: PMKNamespacer, requestParameters: EosioRpcTableByScopeRequest) -> Promise<EosioRpcTableByScopeResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcTableByScopeResponseor rejected with anEosioError. -
Call
chain/get_table_rowsand get a Promise back. Returns an object containing rows from the specified table.Declaration
Swift
public func getTableRows(_: PMKNamespacer, requestParameters: EosioRpcTableRowsRequest) -> Promise<EosioRpcTableRowsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcTableRowsResponseor rejected with anEosioError. -
Call
chain/get_kv_table_rowsand get a Promise back. Returns an object containing rows from the specified table.Declaration
Swift
public func getKvTableRows(_: PMKNamespacer, requestParameters: EosioRpcKvTableRowsRequest) -> Promise<EosioRpcKvTableRowsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcKvTableRowsResponseor rejected with anEosioError. -
Call
chain/get_codeand get a Promise back.Declaration
Swift
public func getCode(_: PMKNamespacer, requestParameters: EosioRpcCodeRequest) -> Promise<EosioRpcCodeResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcCodeResponseor rejected with anEosioError. -
Call
chain/get_codeand geta Promise back. Convenience method called with simple account name.Declaration
Swift
public func getCode(_: PMKNamespacer, accountName: String) -> Promise<EosioRpcCodeResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.accountNameThe account/contract name, as a String.
Return Value
A Promise fulfilled with an
EosioRpcCodeResponseor rejected with anEosioError. -
Call
chain/get_raw_abiand get a Promise back. Get a raw abi.Declaration
Swift
public func getRawAbi(_: PMKNamespacer, requestParameters: EosioRpcRawAbiRequest) -> Promise<EosioRpcRawAbiResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcRawAbiResponseor rejected with anEosioError. -
Call
history/get_actionsand get a Promise back.Declaration
Swift
public func getActions(_: PMKNamespacer, requestParameters: EosioRpcHistoryActionsRequest) -> Promise<EosioRpcActionsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcActionsResponseor rejected with anEosioError. -
Call
history/get_transactionand get a Promise back.Declaration
Swift
public func getTransaction(_: PMKNamespacer, requestParameters: EosioRpcHistoryTransactionRequest) -> Promise<EosioRpcGetTransactionResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcGetTransactionResponseor rejected with anEosioError. -
Call
history/get_key_accountsand get a Promise back.Declaration
Swift
public func getKeyAccounts(_: PMKNamespacer, requestParameters: EosioRpcHistoryKeyAccountsRequest) -> Promise<EosioRpcKeyAccountsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcKeyAccountsResponseor rejected with anEosioError. -
Call
history/get_controlled_accountsand get a Promise back.Declaration
Swift
public func getControlledAccounts(_: PMKNamespacer, requestParameters: EosioRpcHistoryControlledAccountsRequest) -> Promise<EosioRpcControlledAccountsResponse>Parameters
_Differentiates call signature from that of non-promise-returning endpoint method. Pass in
.promiseas the first parameter to call this method.requestParametersReturn Value
A Promise fulfilled with an
EosioRpcControlledAccountsResponseor rejected with anEosioError.
View on GitHub
EosioRpcProvider Class Reference