Skip to content

refactor: playground forms#226

Draft
nrmnqdds wants to merge 12 commits intomainfrom
feat/playground-field
Draft

refactor: playground forms#226
nrmnqdds wants to merge 12 commits intomainfrom
feat/playground-field

Conversation

@nrmnqdds
Copy link
Contributor

Displays all possible inputs for JSON RPC playground

@vercel
Copy link

vercel bot commented Jul 28, 2025

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

Name Status Preview Updated (UTC)
explorer-sepolia ✅ Ready (Inspect) Visit Preview Aug 6, 2025 0:32am
explorer-starknet ✅ Ready (Inspect) Visit Preview Aug 6, 2025 0:32am

@nrmnqdds nrmnqdds linked an issue Jul 28, 2025 that may be closed by this pull request
Copy link
Member

@kariy kariy left a comment

Choose a reason for hiding this comment

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

Ok, good job. This is a very good start.

For the block id input here, I think we can make user's life more easier by having predefined values for the block tag - preconfirmed, latest, and l1 accepted - in the dropdown list. This is to prevent user from specifying invalid block tag.

Image

For estimate fee, we can just omit some of the fields as some of them are implied. In the screenshot for example, we're providing inputs for a Invoke transaction v3, so fields like version and type can be implied here to be 0x3 and INVOKE respectively.

This is specific to estimate fee, we can make the resource_bounds field optional. The purpose of having the estimate fee rpc method in the first place is so that we can get an estimated values for resource_bounds field. So, most of the time, people send an estimate fee request where all of the resource bounds fields are zero. But it doesn't necessarily mean having a nonzero resource bounds is incorrect, hence, we can make it optional here.

Image

For the simulation_flags, yes according to the spec the param is an array. BUT there's only a single value that it accepts (as of RPC 0.8.1) which is SKIP_VALIDATE. So, what I think we can do here, is have some sort of toggle button to choose between sending the estimate fee request with or without the SKIP_VALIDATE flag instead of an input that accepts multiple values.

      "SIMULATION_FLAG_FOR_ESTIMATE_FEE": {
        "type": "string",
        "enum": ["SKIP_VALIDATE"],
        "description": "Flags that indicate how to simulate a given transaction. By default, the sequencer behavior is replicated locally"
      },
Image

@nrmnqdds
Copy link
Contributor Author

nrmnqdds commented Aug 4, 2025

Checklist:

  • predefined values for block tag
  • omit version and type correspondingly
  • removes required on resource bounds
  • handles enums for SIMULATION_FLAG

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.

Dedicated input box for each nested field

2 participants