Repository navigation
fix(api): deprecate v2 block and burn-block endpoints in favor of v3 - #2733
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
Static review found no blocking issues in the scoped exemption logic, migration guidance, or regression coverage; tests were not executed.
No open issues 🎉
What changed in this PR
Deprecates v2 block and burn-block endpoints in favor of v3 while keeping them available when deprecated v1 endpoints are disabled.
Changes:
- Adds a sunset exemption that preserves deprecation warnings without returning
410 Gone. - Adds v3 migration messages to affected v2 routes and updates v1 block descriptions.
- Adds regression tests for warnings, exempt routes, and continued v1 shutdown behavior.
| File | Description |
|---|---|
tests/api/blocks/v2-blocks-deprecation.test.ts |
Tests warning headers and sunset behavior. |
src/api/routes/v2/burn-blocks.ts |
Deprecates three routes with v3 guidance and sunset exemptions. |
src/api/routes/v2/blocks.ts |
Adds deprecation metadata and exemptions to affected block routes. |
src/api/routes/v1/block.ts |
Updates descriptions to reference v3 operations. |
src/api/init.ts |
Documents sunset exemptions in the registration comment. |
src/api/deprecation-plugin.ts |
Defines and honors the sunset exemption flag. |
Review effort: Balanced
rafa-stacks
marked this pull request as ready for review
October 25, 2026 23:31
rafaelcr
approved these changes
Oct 25, 2026
This branch was successfully deployed
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.
Deprecates the v2 block and burn-block endpoints that have a v3 counterpart (they now return a
Warningheader pointing at the v3 path), while exempting them andGET /extended/v2/blocks/{height_or_hash}/transactionsfrom theENABLE_DEPRECATED_ENDPOINTSsunset so they keep serving after v1 is disabled. v1 block endpoint descriptions now point at the v3 operations.