General notes
- added Oxford support;
- switched to Postgresql 16;
- minor improvements.
To update from v1.12.*
to v1.13.0
you should drop the indexer database and restore it from the latest snapshot (in case of non-docker setup you may also need to update your Postgresql, see explanation below), or reindex from scratch. This is due to breaking changes in the consensus, that complicate DB migration.
Postgresql 16
We've switched to PostgreSQL 16 with raised performance, improvements to query parallelism, bulk data loading, and logical replication.
In fact, you don't necessarily have to update your Postgresql, because TzKT can work with older versions, however the DB snapshots we provide are created with pg_dump v16, which is not compatible with pg_restore v15 and older, so if you want to restore your DB from our snapshots, then you will have to use Postgresql of the appropriate version.
Changes in the API endpoints
- [BREAKING]
/rewards/delegators/{address}/{cycle}
was deprecated, because since Oxford a single account can have multiple delegations at the same time, that can lead to multiple delegator reward entities for a single cycle, so use/rewards/delegators/{address}?cycle={cycle}
instead; - [BREAKING]
/rewards/bakers/{address}/{cycle}
was deprecated, use/rewards/bakers/{address}?cycle={cycle}
instead; /operations/staking
was added;/operations/staking/count
was added;/operations/autostaking
was added;/operations/autostaking/count
was added;/accounts/{address}/operations
now also returns operations of new types:staking
andautostaking
.
Changes in the API models
Delegates:
- fields
stakedPseudotokens
,unstakedBaker
,totalStakedBalance
,issuedPseudotokens
,stakersCount
,limitOfStakingOverBaking
,edgeOfBakingOverStaking
,stakingOpsCount
,autostakingOpsCount
, andlostBalance
were added; - [BREAKING] field
frozenDeposit
was deprecated and replaced withstakedBalance
,unstakedBalance
,externalStakedBalance
, andexternalUnstakedBalance
.
Users:
- fields
stakedBalance
,stakedPseudotokens
,unstakedBalance
,unstakedBaker
,stakingOpsCount
, andlostBalance
were added.
Baker rewards:
- field
stakersCount
was added; - [BREAKING] field
stakingBalance
was deprecated and replaced withownDelegatedBalance
,ownStakedBalance
,externalDelegatedBalance
, andexternalStakedBalance
; - [BREAKING] field
delegatedBalance
was deprecated and replaced withownDelegatedBalance
andexternalDelegatedBalance
; - [BREAKING] field
activeStake
was deprecated and replaced withbakingPower
; - [BREAKING] field
selectedStake
was deprecated and replaced withtotalBakingPower
; - [BREAKING] field
numDelegators
was deprecated and replaced withdelegatorsCount
; - [BREAKING] field
blockRewards
was deprecated and replaced withblockRewardsLiquid
,blockRewardsStakedOwn
, andblockRewardsStakedShared
; - [BREAKING] field
endorsementRewards
was deprecated and replaced withendorsementRewardsLiquid
,endorsementRewardsStakedOwn
, andendorsementRewardsStakedShared
; - [BREAKING] field
doubleBakingLosses
was deprecated and replaced withdoubleBakingLostStaked
,doubleBakingLostUnstaked
,doubleBakingLostExternalStaked
, anddoubleBakingLostExternalUnstaked
; - [BREAKING] field
doubleEndorsingLosses
was deprecated and replaced withdoubleEndorsingLostStaked
,doubleEndorsingLostUnstaked
,doubleEndorsingLostExternalStaked
, anddoubleEndorsingLostExternalUnstaked
; - [BREAKING] field
doublePreendorsingLosses
was deprecated and replaced withdoublePreendorsingLostStaked
,doublePreendorsingLostUnstaked
,doublePreendorsingLostExternalStaked
, anddoublePreendorsingLostExternalUnstaked
; - [BREAKING] field
revelationRewards
was deprecated and replaced withvdfRevelationRewardsLiquid
,vdfRevelationRewardsStakedOwn
,vdfRevelationRewardsStakedShared
,nonceRevelationRewardsLiquid
,nonceRevelationRewardsStakedOwn
, andnonceRevelationRewardsStakedShared
; - [BREAKING] field
revelationLosses
was deprecated and replaced withnonceRevelationLosses
.
Rewards split:
- same changes as for baker rewards, described above.
Rewards split delegator:
- [BREAKING] field
balance
was deprecated and replaced withdelegatedBalance
andstakedBalance
; - [BREAKING] field
currentBalance
was deprecated and replaced withcurrentDelegatedBalance
andcurrentStakedBalance
.
Delegator rewards:
- [BREAKING] field
balance
was deprecated and replaced withdelegatedBalance
andstakedBalance
; - [BREAKING] field
stakingBalance
was deprecated and replaced withbakerDelegatedBalance
,bakerStakedBalance
,externalDelegatedBalance
, andexternalStakedBalance
; - [BREAKING] field
activeStake
was deprecated and replaced withbakingPower
; - [BREAKING] field
selectedStake
was deprecated and replaced withtotalBakingPower
; - [BREAKING] field
blockRewards
was deprecated and replaced withblockRewardsLiquid
,blockRewardsStakedOwn
, andblockRewardsStakedShared
; - [BREAKING] field
endorsementRewards
was deprecated and replaced withendorsementRewardsLiquid
,endorsementRewardsStakedOwn
, andendorsementRewardsStakedShared
; - [BREAKING] field
doubleBakingLosses
was deprecated and replaced withdoubleBakingLostStaked
,doubleBakingLostUnstaked
,doubleBakingLostExternalStaked
, anddoubleBakingLostExternalUnstaked
; - [BREAKING] field
doubleEndorsingLosses
was deprecated and replaced withdoubleEndorsingLostStaked
,doubleEndorsingLostUnstaked
,doubleEndorsingLostExternalStaked
, anddoubleEndorsingLostExternalUnstaked
; - [BREAKING] field
doublePreendorsingLosses
was deprecated and replaced withdoublePreendorsingLostStaked
,doublePreendorsingLostUnstaked
,doublePreendorsingLostExternalStaked
, anddoublePreendorsingLostExternalUnstaked
; - [BREAKING] field
revelationRewards
was deprecated and replaced withvdfRevelationRewardsLiquid
,vdfRevelationRewardsStakedOwn
,vdfRevelationRewardsStakedShared
,nonceRevelationRewardsLiquid
,nonceRevelationRewardsStakedOwn
, andnonceRevelationRewardsStakedShared
; - [BREAKING] field
revelationLosses
was deprecated and replaced withnonceRevelationLosses
.
Cycles:
- fields
blockReward
,blockBonusPerSlot
,endorsementRewardPerSlot
,nonceRevelationReward
,vdfRevelationReward
, andlbSubsidy
were added; - [BREAKING] field
totalStaking
was deprecated; - [BREAKING] field
selectedStake
was deprecated and replaced withtotalBakingPower
; - [BREAKING] field
selectedBakers
was deprecated and replaced withtotalBakers
; - [BREAKING] field
totalDelegated
was deprecated; - [BREAKING] field
totalDelegators
was deprecated.
Blocks:
- fields
aiToggle
,aiToggleEma
,stakingOps
, andautostakingOps
were added.
Blocks and baking operations:
- [BREAKING] field
reward
was deprecated and replaced withrewardLiquid
,rewardStakedOwn
, andrewardStakedShared
; - [BREAKING] field
bonus
was deprecated and replaced withbonusLiquid
,bonusStakedOwn
, andbonusStakedShared
.
Delegation operations:
- fields
unstakedPseudotokens
,unstakedBalance
, andunstakedRewards
were added.
Double baking/endorsing/preendorsing operations:
- field
slashedLevel
was added; - [BREAKING] field
accuserReward
was renamed toreward
; - [BREAKING] field
offenderLoss
was deprecated and replaced withlostStaked
,lostUnstaked
,lostExternalStaked
,lostExternalUnstaked
, androundingLoss
.
Endorsing reward operations:
- [BREAKING] field
received
was deprecated and replaced withrewardLiquid
,rewardStakedOwn
, andrewardStakedShared
.
Migration operations:
- field
kind
was extended with the new possible valueremove_bigmap_key
.
Nonce/vdf revelation operations:
- [BREAKING] field
reward
was deprecated and replaced withrewardLiquid
,rewardStakedOwn
, andrewardStakedShared
.
Smart rollup originate operations:
- [BREAKING] field
originationProof
was removed.
Protocol constants:
- fields
minimalFrozenStake
,maxDelegatedOverFrozenRatio
, andmaxExternalOverOwnStakeRatio
were added; - [BREAKING] field
tokensPerRoll
was deprecated and replaced withminimalStake
; - [BREAKING] field
revelationReward
was deprecated, use adaptive issuance values; - [BREAKING] field
lbSubsidy
was deprecated, use adaptive issuance values; - [BREAKING] field
frozenDepositsPercentage
was deprecated; - [BREAKING] field
doubleBakingPunishment
was deprecated; - [BREAKING] field
doubleEndorsingPunishmentNumerator
was deprecated; - [BREAKING] field
doubleEndorsingPunishmentDenominator
was deprecated; - [BREAKING] field
txRollupOriginationSize
was deprecated; - [BREAKING] field
txRollupCommitmentBond
was deprecated.
Statistics:
- field
totalLost
was added.
Changes in the WebSocket API:
- new operation types are available in the operations subscription.
Changes in the DB schema
Basically, DB schema has almost the same changes as the API models, described above.
For more details check out the full diffs at Tzkt.Data/Models.