Uses of Interface
com.syntifi.near.api.rpc.NearClient
-
-
Uses of NearClient in com.syntifi.near.api.rpc
Methods in com.syntifi.near.api.rpc that return NearClient Modifier and Type Method Description static NearClient
NearClient. usingNetwork(Network network)
NearService builder -
Uses of NearClient in com.syntifi.near.api.rpc.service
Methods in com.syntifi.near.api.rpc.service with parameters of type NearClient Modifier and Type Method Description static TransactionAwait
AccountService. createNamedAccount(NearClient nearClient, java.lang.String mainDomain, java.lang.String newAccountId, PublicKey newAccountPublicKey, java.math.BigInteger amountToNewAccount, java.lang.String creatorAccountId, PublicKey creatorPublicKey, PrivateKey creatorPrivateKey)
Sends aTransferAction
transaction calling a contract to create_account and waits for result usingsendTransactionAwait(String)
static EncodedHash
AccountService. createNamedAccountAsync(NearClient nearClient, java.lang.String mainDomain, java.lang.String newAccountId, PublicKey newAccountPublicKey, java.math.BigInteger amountToNewAccount, java.lang.String creatorAccountId, PublicKey creatorPublicKey, PrivateKey creatorPrivateKey)
Sends aTransferAction
transaction async usingsendTransactionAsync(String)
with the needed actions to generate a named account and waits for result usingsendTransactionAwait(String)
static TransactionAwait
AccountService. createSubAccount(NearClient nearClient, java.lang.String newAccountId, java.math.BigInteger amountToNewAccount, java.lang.String creatorAccountId, PublicKey creatorPublicKey, PrivateKey creatorPrivateKey)
Sends aTransferAction
transaction with the needed actions to generate a sub account and waits for result usingsendTransactionAwait(String)
static EncodedHash
AccountService. createSubAccountAsync(NearClient nearClient, java.lang.String newAccountId, java.math.BigInteger amountToNewAccount, java.lang.String creatorAccountId, PublicKey creatorPublicKey, PrivateKey creatorPrivateKey)
Sends aTransferAction
transaction async usingsendTransactionAsync(String)
with the needed actions to generate a sub account and waits for result usingsendTransactionAwait(String)
static java.lang.String
TransactionService. prepareTransactionForActionList(NearClient nearClient, java.lang.String signerId, java.lang.String receiverId, PublicKey signerPublicKey, PrivateKey signerPrivateKey, java.util.List<Action> actionList)
Prepares the transaction to send and automatically queries for the next noncestatic java.lang.String
TransactionService. prepareTransactionForActionList(NearClient nearClient, java.lang.String signerId, java.lang.String receiverId, PublicKey signerPublicKey, PrivateKey signerPrivateKey, java.util.List<Action> actionList, java.lang.Long nonce)
Prepares the transaction to send with a given noncestatic EncodedHash
TransferService. sendTransactionAsync(NearClient nearClient, java.lang.String signerId, java.lang.String receiverId, PublicKey signerPublicKey, PrivateKey signerPrivateKey, java.util.List<Action> actionList)
Sends a list ofAction
transaction waiting for result usingsendTransactionAsync(String)
static TransactionAwait
TransferService. sendTransactionAwait(NearClient nearClient, java.lang.String signerId, java.lang.String receiverId, PublicKey signerPublicKey, PrivateKey signerPrivateKey, java.util.List<Action> actionList)
Sends a list ofAction
transaction waiting for result usingsendTransactionAwait(String)
static EncodedHash
TransferService. sendTransferActionAsync(NearClient nearClient, java.lang.String signerId, java.lang.String receiverId, PublicKey signerPublicKey, PrivateKey signerPrivateKey, java.math.BigInteger amount)
Sends aTransferAction
transaction async usingsendTransactionAsync(String)
static TransactionAwait
TransferService. sendTransferActionAwait(NearClient nearClient, java.lang.String signerId, java.lang.String receiverId, PublicKey signerPublicKey, PrivateKey signerPrivateKey, java.math.BigInteger amount)
Sends aTransferAction
transaction waiting for result usingsendTransactionAwait(String)
-
Uses of NearClient in com.syntifi.near.api.rpc.service.contract.common
Methods in com.syntifi.near.api.rpc.service.contract.common with parameters of type NearClient Modifier and Type Method Description static <T> FunctionCallResult<T>
ContractViewMethodCaller. call(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, Base64String params, java.lang.Class<T> returnClass)
Calls a contract for specific methodContractFunctionCallResult
FunctionCall. call(NearClient nearClient)
<T> FunctionCallResult<T>
ContractMethodProxy. invoke(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, ContractMethodType methodType, Base64String arguments, java.lang.Class<T> returnClass)
Proxy invoke the contracts view methods by sending the Base64StringTransactionAwait
ContractMethodProxy. invoke(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, ContractMethodType methodType, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey, com.fasterxml.jackson.databind.node.ObjectNode arguments, java.math.BigInteger deposit)
Proxy invoke the contracts call methods via signed transactions<T> FunctionCallResult<T>
ContractMethodProxyClient. invoke(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, ContractMethodType methodType, Base64String arguments, java.lang.Class<T> returnClass)
TransactionAwait
ContractMethodProxyClient. invoke(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, ContractMethodType methodType, java.lang.String accountId, PublicKey accountPublicKey, PrivateKey accountPrivateKey, com.fasterxml.jackson.databind.node.ObjectNode arguments, java.math.BigInteger deposit)
EncodedHash
ContractMethodProxy. invokeAsync(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, ContractMethodType methodType, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey, com.fasterxml.jackson.databind.node.ObjectNode arguments, java.math.BigInteger deposit)
Proxy invoke the contracts call methods via signed transactions asyncEncodedHash
ContractMethodProxyClient. invokeAsync(NearClient nearClient, java.lang.String contractAccountId, java.lang.String methodName, ContractMethodType methodType, java.lang.String accountId, PublicKey accountPublicKey, PrivateKey accountPrivateKey, com.fasterxml.jackson.databind.node.ObjectNode arguments, java.math.BigInteger deposit)
-
Uses of NearClient in com.syntifi.near.api.rpc.service.contract.ft
Methods in com.syntifi.near.api.rpc.service.contract.ft with parameters of type NearClient Modifier and Type Method Description TransactionAwait
FTService. callTransfer(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to transfer ftTransactionAwait
FTService. callTransfer(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey, java.lang.String memo)
Synchronous contractCall to transfer ftEncodedHash
FTService. callTransferAsync(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to transfer ftEncodedHash
FTService. callTransferAsync(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey, java.lang.String memo)
Asynchronous contractCall to transfer ftTransactionAwait
FTService. callTransferCall(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, java.lang.String msg, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to transfer_call ftTransactionAwait
FTService. callTransferCall(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, java.lang.String msg, PublicKey publicKey, PrivateKey privateKey, java.lang.String memo)
Synchronous contractCall to transfer_call ftEncodedHash
FTService. callTransferCallAsync(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, java.lang.String msg, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to transfer_call ftEncodedHash
FTService. callTransferCallAsync(NearClient nearClient, java.lang.String tokenId, java.lang.String amount, java.lang.String receiverId, java.lang.String accountId, java.lang.String msg, PublicKey publicKey, PrivateKey privateKey, java.lang.String memo)
Asynchronous contractCall to transfer_call ftFunctionCallResult<java.math.BigInteger>
FTService. getBalanceOf(NearClient nearClient, java.lang.String tokenId, java.lang.String accountId)
NEP-141 method to get the balance of the given token for the given accountFunctionCallResult<FTTokenMetadata>
FTService. getMetadata(NearClient nearClient, java.lang.String tokenId)
NEP-148 containing the metadata for the tokenFunctionCallResult<java.lang.String>
FTService. getTotalSupply(NearClient nearClient, java.lang.String tokenId)
NEP-141 method to get the total supply of the given token -
Uses of NearClient in com.syntifi.near.api.rpc.service.contract.nft
Methods in com.syntifi.near.api.rpc.service.contract.nft with parameters of type NearClient Modifier and Type Method Description TransactionAwait
NFTService. callTransfer(NearClient nearClient, java.lang.String contractAccountId, java.lang.String receiverAccountId, java.lang.String tokenId, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey, java.math.BigInteger deposit)
Synchronous contractCall to transfer nftEncodedHash
NFTService. callTransferAsync(NearClient nearClient, java.lang.String contractAccountId, java.lang.String receiverAccountId, java.lang.String tokenId, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey, java.math.BigInteger deposit)
Asynchronous contractCall to transfer nftFunctionCallResult<NFTContractMetadata>
NFTService. getMetadata(NearClient nearClient, java.lang.String contractAccountId)
Gets NFT metadataFunctionCallResult<java.lang.String>
NFTService. getSupplyForOwner(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Gets the supply of an NFT for an ownerFunctionCallResult<NFTTokenMetadata>
NFTService. getTokenMetadata(NearClient nearClient, java.lang.String contractAccountId, java.lang.String tokenId)
Gets NFT metadataFunctionCallResult<com.fasterxml.jackson.databind.JsonNode>
NFTService. getTokens(NearClient nearClient, java.lang.String contractAccountId, java.lang.String fromIndex)
Get tokens for given parametersFunctionCallResult<com.fasterxml.jackson.databind.JsonNode>
NFTService. getTokens(NearClient nearClient, java.lang.String contractAccountId, java.lang.String fromIndex, java.lang.Integer limit)
Get tokens for given parametersFunctionCallResult<NFTTokenList>
NFTService. getTokensForOwner(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId, java.lang.String fromIndex)
Gets tokens for the given ownerFunctionCallResult<NFTTokenList>
NFTService. getTokensForOwner(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId, java.lang.String fromIndex, java.lang.Integer limit)
Gets tokens for the given ownerFunctionCallResult<java.lang.String>
NFTService. getTotalSupply(NearClient nearClient, java.lang.String contractAccountId)
Get total supply of NFT for given contract -
Uses of NearClient in com.syntifi.near.api.rpc.service.contract.staking
Methods in com.syntifi.near.api.rpc.service.contract.staking with parameters of type NearClient Modifier and Type Method Description TransactionAwait
StakingService. callClaim(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to claim rewards from contractAccountIdEncodedHash
StakingService. callClaimAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to claim rewards from contractAccountIdTransactionAwait
StakingService. callDeposit(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to deposit an amount to the contractAccountIdTransactionAwait
StakingService. callDepositAndStake(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to deposit and stake an amount to the contractAccountIdEncodedHash
StakingService. callDepositAndStakeAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to deposit and stake an amount to the contractAccountIdEncodedHash
StakingService. callDepositAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to deposit an amount to the contractAccountIdTransactionAwait
StakingService. callPing(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to ping contractAccountIdEncodedHash
StakingService. callPingAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to ping contractAccountIdTransactionAwait
StakingService. callStake(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to stake an amount to the contractAccountIdTransactionAwait
StakingService. callStakeAll(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to stake all available balance in the contractAccountIdEncodedHash
StakingService. callStakeAllAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to stake all available balance in the contractAccountIdEncodedHash
StakingService. callStakeAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to stake an amount to the contractAccountIdTransactionAwait
StakingService. callUnstake(NearClient nearClient, java.lang.String contractAccountId, java.lang.String amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to unstake an amount to the contractAccountIdEncodedHash
StakingService. callUnstakeAsync(NearClient nearClient, java.lang.String contractAccountId, java.lang.String amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to unstake an amount to the contractAccountIdTransactionAwait
StakingService. callWithdraw(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Synchronous contractCall to withdraw an amount to the contractAccountIdEncodedHash
StakingService. callWithdrawAsync(NearClient nearClient, java.lang.String contractAccountId, java.math.BigInteger amount, java.lang.String accountId, PublicKey publicKey, PrivateKey privateKey)
Asynchronous contractCall to withdraw an amount to the contractAccountIdFunctionCallResult<java.lang.Boolean>
StakingService. isAccountUnstakedBalanceAvailable(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Contract function view call to check if the account unstaked balance is availableFunctionCallResult<java.math.BigInteger>
StakingService. viewAccountStakedBalance(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Contract function view call to get the account staked balanceFunctionCallResult<java.math.BigInteger>
StakingService. viewAccountTotalBalance(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Contract function view call to get the account total balanceFunctionCallResult<java.math.BigInteger>
StakingService. viewAccountUnstakedBalance(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Contract function view call to get the account unstaked balanceFunctionCallResult<com.fasterxml.jackson.databind.JsonNode>
StakingService. viewFarm(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId, java.lang.Long farmId)
Returns the detail for a specific farm the given farmIdFunctionCallResult<com.fasterxml.jackson.databind.JsonNode>
StakingService. viewFarms(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId, java.lang.Long fromIndex, java.lang.Long limit)
Returns the details for all farms for the given contractAccountIdFunctionCallResult<java.lang.String>
StakingService. viewOwnerId(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Contract function view call to get the contract owner idFunctionCallResult<RewardFee>
StakingService. viewRewardFeeFraction(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Returns the fee fraction charged by the staking farm (eg.FunctionCallResult<java.math.BigInteger>
StakingService. viewTotalStakedBalance(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId)
Contract function view call to get the total staked balanceFunctionCallResult<java.math.BigInteger>
StakingService. viewUnclaimedReward(NearClient nearClient, java.lang.String contractAccountId, java.lang.String accountId, java.lang.Long farmId)
Returns the unclaimed reward in a given farmId
-