Retrieves staking rewards for a specific account from https://subscan.io.
Note that by default staking rewards are aggregated by day. Usually, Kusama
pays out rewards up to four times per day. If you want to receive all
individual staking rewards, set by_day = FALSE
.
A more coarse aggregation (weekly, monthly) would result in a biased "Value" column as one would need to take the mean of the selected period whereas the reward payouts actually happened on a daily base with a specific coin rate,
Usage
parse_kusama(
address,
pp_security_name = "Kusama",
currency = "EUR",
pp_lang = "EN",
securities_account = NULL,
dec = NULL,
sep = ";",
filename = NULL,
api_key = NULL,
by_day = TRUE
)
Arguments
- address
[character]
Wallet address.- pp_security_name
character
The name of the security in Portfolio Performance (e.g. "Kusama").- currency
character
Currency in which to calculate the staking rewards. Must be part of a valid coin pair on Binance, e.g. "DOTEUR".- pp_lang
character
The currency of Portfolio Performance. Only German ("DE") and English ("EN") are supported.- securities_account
character
The name of the account to which to associate the deliveries. In German called "Depot".- dec
character
Decimal separator. If not set, inferred by the value of argumentpp_lang
:If
pp_lang = "DE"
->dec = ","
If
pp_lang = "EN"
->dec = "."
- sep
character
Columns separator. Defaults to;
.- filename
character
The output filename.- api_key
character
Optional personal API key.- by_day
logical
Whether to aggregate by day. Kusama staking rewards are paid up to four times per day. If set toFALSE
, all individual rewards are returned.
Value
tibble::tibble (invisibly)