feat: Asset Hub migration and elastic scaling preparation - Array responses for useRcBlock, remove rcAt in favor of useRcBlock#1709
Merged
Merged
Conversation
andrew-ifrita
approved these changes
Jul 23, 2025
filvecchiato
approved these changes
Jul 23, 2025
rcAt and useRcBlock parametersuseRcBlock, remove rcAt in favor of useRcBlock
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR updates all endpoints that support
useRcBlockparameters to return array responses in preparation for Asset Hub migration and Polkadot/Kusama elastic scaling. This enables support for multiple Asset Hub blocks perrelay chain block while maintaining backward compatibility. This PR also removes any use of
rcAtin favor ofuseRcBlock.useRcBlock
useRcBlockworks in conjunction withat, unless its a/blocksendpoint which will use the block number in the path, or header if no block is supplied.Response Structure Changes
With
useRcBlockparameters:[ { "at": {...}, "data": "...", "rcBlockNumber": "5678901", "ahTimestamp": "1234567890" } ]When no Asset Hub blocks found:
Without these parameters (unchanged):
{ "at": {...}, "data": "..." }Affected Endpoints
Account Endpoints with
useRcBlock/accounts/{accountId}/asset-balances/accounts/{accountId}/asset-approvals/accounts/{accountId}/pool-asset-balances/accounts/{accountId}/pool-asset-approvals/accounts/{accountId}/balance-info/accounts/{accountId}/staking-info/accounts/{accountId}/staking-payouts/accounts/{accountId}/vesting-info/accounts/{accountId}/proxy-infoBlock Endpoints with
useRcBlock/blocks/head/blocks/{blockId}/blocks/{blockId}/header/blocks/head/header/blocks/{blockId}/extrinsics/{extrinsicIndex}/blocks/{blockId}/extrinsics-raw/blocks(range queries)Pallets Endpoints with
useRcBlock/pallets/asset-conversion/next-available-id/pallets/asset-conversion/liquidity-pools/pallets/assets/{assetId}/asset-info/pallets/{palletId}/consts/pallets/{palletId}/consts/{constantItemId}/pallets/{palletId}/dispatchables/pallets/{palletId}/dispatchables/{dispatchableItemId}/pallets/{palletId}/events/pallets/{palletId}/events/{eventItemId}/pallets/{palletId}/errors/pallets/{palletId}/errors/{errorItemId}/pallets/foreign-assets/pallets/nomination-pools/info/pallets/nomination-pools/{poolId}/pallets/ongoing-referenda/pallets/pool-assets/{assetId}/asset-info/pallets/staking/progress/pallets/staking/validators/pallets/{palletId}/storage/pallets/{palletId}/storage/{storageItemId}Usage
Using
useRcBlockparameter:Standard usage (unchanged):
Backward Compatibility
Regular queries without
useRcBlockcontinue to return single objects unchanged. Only queries using these parameters now return arrays.