StakeApi - interface

Export

StakeApi

interface StakeApiInterface {
    buildStakingOperation(buildStakingOperationRequest, options?): AxiosPromise<StakingOperation>;
    fetchHistoricalStakingBalances(networkId, assetId, addressId, startTime, endTime, limit?, page?, options?): AxiosPromise<FetchHistoricalStakingBalances200Response>;
    fetchStakingRewards(fetchStakingRewardsRequest, limit?, page?, options?): AxiosPromise<FetchStakingRewards200Response>;
    getExternalStakingOperation(networkId, addressId, stakingOperationId, options?): AxiosPromise<StakingOperation>;
    getStakingContext(getStakingContextRequest, options?): AxiosPromise<StakingContext>;
    getValidator(networkId, assetId, validatorId, options?): AxiosPromise<Validator>;
    listValidators(networkId, assetId, status?, limit?, page?, options?): AxiosPromise<ValidatorList>;
}

Implemented by

Methods

  • Fetch historical staking balances for given address.

    Parameters

    • networkId: string

      The ID of the blockchain network.

    • assetId: string

      The ID of the asset for which the historical staking balances are being fetched.

    • addressId: string

      The onchain address for which the historical staking balances are being fetched.

    • startTime: string

      The start time of this historical staking balance period.

    • endTime: string

      The end time of this historical staking balance period.

    • Optional limit: number

      A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 50.

    • Optional page: string

      A cursor for pagination across multiple pages of results. Don&#39;t include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.

    • Optional options: RawAxiosRequestConfig

      Override http request option.

    Returns AxiosPromise<FetchHistoricalStakingBalances200Response>

    Summary

    Fetch historical staking balances

    Throws

    Memberof

    StakeApiInterface

  • Fetch staking rewards for a list of addresses

    Parameters

    • fetchStakingRewardsRequest: FetchStakingRewardsRequest
    • Optional limit: number

      A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 50.

    • Optional page: string

      A cursor for pagination across multiple pages of results. Don&#39;t include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.

    • Optional options: RawAxiosRequestConfig

      Override http request option.

    Returns AxiosPromise<FetchStakingRewards200Response>

    Summary

    Fetch staking rewards

    Throws

    Memberof

    StakeApiInterface

  • Get the latest state of a staking operation

    Parameters

    • networkId: string

      The ID of the blockchain network

    • addressId: string

      The ID of the address to fetch the staking operation for

    • stakingOperationId: string

      The ID of the staking operation

    • Optional options: RawAxiosRequestConfig

      Override http request option.

    Returns AxiosPromise<StakingOperation>

    Summary

    Get the latest state of a staking operation

    Throws

    Memberof

    StakeApiInterface

  • Get staking context for an address

    Parameters

    Returns AxiosPromise<StakingContext>

    Summary

    Get staking context

    Throws

    Memberof

    StakeApiInterface

  • Get a validator belonging to the user for a given network, asset and id.

    Parameters

    • networkId: string

      The ID of the blockchain network.

    • assetId: string

      The symbol of the asset to get the validator for.

    • validatorId: string

      The unique id of the validator to fetch details for.

    • Optional options: RawAxiosRequestConfig

      Override http request option.

    Returns AxiosPromise<Validator>

    Summary

    Get a validator belonging to the CDP project

    Throws

    Memberof

    StakeApiInterface

  • List validators belonging to the user for a given network and asset.

    Parameters

    • networkId: string

      The ID of the blockchain network.

    • assetId: string

      The symbol of the asset to get the validators for.

    • Optional status: ValidatorStatus

      A filter to list validators based on a status.

    • Optional limit: number

      A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 50.

    • Optional page: string

      A cursor for pagination across multiple pages of results. Don&#39;t include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.

    • Optional options: RawAxiosRequestConfig

      Override http request option.

    Returns AxiosPromise<ValidatorList>

    Summary

    List validators belonging to the CDP project

    Throws

    Memberof

    StakeApiInterface