Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

initial draft for MEV refund read endpoints #577

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

TymKh
Copy link
Contributor

@TymKh TymKh commented Sep 17, 2024

Document 5 endpoints to obtain data for MEV refunds (previously refund-api)

Copy link

vercel bot commented Sep 17, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
flashbots-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 17, 2024 3:26pm

@@ -869,6 +869,167 @@ If the first address matches the authentication signature, then a response with

If the signature is invalid or does not match the first address, an appropriate error will be returned instead.

### MEV Refund JSON-RPC API Documentation
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would delete this section (lines 872-874) and instead repeat the context on line 874 (APIs are for MEV-Share, not authenticated) in each individual API entry below. The reason is:

  • It's not standard to have sub-headings in our API docs today (we can revisit this, but it doesn't match the rest of the docs so would prefer to keep things consistent for now)
  • We want all of the context to be mentioned in each entry because a user might navigate directly to one of the API methods and miss this overall heading (in which case it won't be clear that the API they're looking at is for MEV-Share or does not require authentication)


### flashbots_getMevRefundsByRecipient

Retrieves all refunds sent to a specific recipient address.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In each of these individual API entries we should:

  • Specify that this API is for MEV-Share refunds. Eg. change the text to say "Retrieves all MEV-Share refunds..." where "MEV-Share" could also be a link to https://docs.flashbots.net/flashbots-protect/mev-share
  • Specify that the API does not require authentication (I would say "authentication" and not "signature")

(This same comment applies to each new API section below).

"jsonrpc": "2.0",
"id": 1,
"result": {
"refunds": [
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this list should be paginated?


### flashbots_getMevRefundsByHash

Retrieves refunds associated with a specific transaction or `sbundle` hash.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we add a quick explanation of what an "sbundle" is?


### flashbots_getMevRefundTotalByRecipient

Retrieves the total amount of MEV refunds received by a specific recipient address.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"MEV refunds" -> "MEV-Share refunds"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants