Add GET /fee for frontend max_fee quotes - #37
Merged
Merged
Conversation
Wallets need a number they can sign before POST /tx. Quote the open-frame fee and recommended_fee, plus suggested_max_fee (max of those with 1.5x slack) so inclusion can survive a frame rotation.
Share snapshot storage_task across ingress and egress so a panic or corrupt DB aborts instead of returning 500 while POST /tx keeps running.
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
GET /feeso wallets can set signedmax_feebeforePOST /tx.fee, next-framerecommended_fee, andsuggested_max_fee(maxof those plus 1.5× log slack) so a signature can survive a frame rotation. Users still pay the real frame fee, not the cap.get_fee().Test plan
GET /feeon an admitted sequencer returns all three exponents;suggested_max_feeismax(fee, recommended_fee) + 53.suggested_max_feeintoPOST /tx; inclusion succeeds.OPTIONS /feefrom another origin succeeds;/livezstill has no CORS.GET /feeduring shutdown (or with no open frame) returns503 UNAVAILABLE.