Interface NearIndexerService


  • public interface NearIndexerService
    Near indexer service uses http API to retrieve useful information on chain data
    Since:
    0.2.0
    Author:
    Alexandre Carvalho, Andre Bertolace
    • Method Detail

      • getAccountLikelyNFTs

        @GET("account/{accountId}/likelyNFTs")
        retrofit2.Call<AccountIdList> getAccountLikelyNFTs​(@Path("accountId")
                                                           java.lang.String accountId)
        Fetches all likely NFTs given an accountId
        Parameters:
        accountId - the account to search information for
        Returns:
        a retrofit call for a AccountIdList
      • getAccountLikelyFTs

        @GET("account/{accountId}/likelyTokens")
        retrofit2.Call<AccountIdList> getAccountLikelyFTs​(@Path("accountId")
                                                          java.lang.String accountId)
        Fetches all likely FTs (Tokens) given an accountId
        Parameters:
        accountId - the account to search information for
        Returns:
        a retrofit call for a AccountIdList
      • getStakingDeposits

        @GET("staking-deposits/{accountId}")
        retrofit2.Call<java.util.List<StakingDeposit>> getStakingDeposits​(@Path("accountId")
                                                                          java.lang.String accountId)
        Fetches staing deposits for an account
        Parameters:
        accountId - the account to search information for
        Returns:
        a retrofit call for a list of StakingDeposits
      • getNearRecentActivity

        @GET("account/{accountId}/activity")
        retrofit2.Call<RecentActivity> getNearRecentActivity​(@Path("accountId")
                                                             java.lang.String accountId)
        Fetches a list of recent activities for one account
        Parameters:
        accountId - the account to fetch activity
        Returns:
        list of recent activity for the account
      • getNearValue

        @GET("/fiat")
        retrofit2.Call<NearValue> getNearValue()
        Fetches the value of near in fiat currency
        Returns:
        the Near fiat value
      • getNearAccounts

        @GET("publicKey/{publicKey}/accounts")
        retrofit2.Call<java.util.List<java.lang.String>> getNearAccounts​(@Path("publicKey")
                                                                         java.lang.String publicKey)
        Fetches a list of accounts for a given public key
        Parameters:
        publicKey - the account public key
        Returns:
        list containing all account ids
      • usingPeer

        static NearIndexerService usingPeer​(java.lang.String url)
        NearIndexerService builder
        Parameters:
        url - the indexer url to connect to
        Returns:
        the indexer service instance