-
Notifications
You must be signed in to change notification settings - Fork 436
Switch docs back to openrpc
v2
#667
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
Open
acolytec3
wants to merge
62
commits into
ethereum:main
Choose a base branch
from
acolytec3:main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
62 commits
Select commit
Hold shift + click to select a range
909208b
add docusaurus
acolytec3 19ac475
update deploy scripts
acolytec3 5b0c81b
clean up stuff
acolytec3 6e0dc69
update action
acolytec3 f272141
workflow dispatch trigger
acolytec3 406f4eb
build against main
acolytec3 9eef24a
Merge remote-tracking branch 'upstream/main' into docusaurus
acolytec3 54c3163
Merge pull request #1 from acolytec3/docusaurus
acolytec3 6bb9628
push build to correct place
acolytec3 b3a20fc
use correct working directory
acolytec3 1612d44
fix references
acolytec3 e15e33e
update build artifact path in deploy workflow
acolytec3 4557be6
consolidate in base dir
acolytec3 caf5990
more cleanup
acolytec3 8b0a015
add test deploy ci
acolytec3 1d5d76a
add workflow_dispatch
acolytec3 0f036d9
fix deploy script
acolytec3 55d1bda
build specs and website
acolytec3 fb9286f
don't throw on broken links
acolytec3 e4a3ddd
update baseUrl
acolytec3 929cd81
make ESM/CJS stuff play nice
acolytec3 4719822
clean up links and docusaurus references
acolytec3 0608537
more link cleanup
acolytec3 87e206e
update links to point to ethereum
acolytec3 b63f4c4
remove docu boilerplate
acolytec3 13b1f6e
build docs too
acolytec3 5e218ea
Update docs/reference/intro.md
acolytec3 b5fff3b
Update docusaurus.config.ts
acolytec3 4331158
remove old deployment job
acolytec3 2325067
remove gatsby
lightclient c98edde
update generator to v2
acolytec3 4e5e35b
Update openrpc version
acolytec3 bcaaffe
Update prepare script
acolytec3 d84a43f
move build script to correct place
acolytec3 d299793
Add config to prep step
acolytec3 3746c0f
update ci
acolytec3 2d73118
use correct trigger
acolytec3 63e7647
remove config
acolytec3 c002ffa
add write permission
acolytec3 994c9da
push to master
acolytec3 f3c8c52
remove docusaurus nonsense
acolytec3 0244712
update node evn
acolytec3 7bae577
commit package-lock only
acolytec3 335846c
Merge remote-tracking branch 'origin/main' into openrpc-v2
acolytec3 b0ef8a4
Merge pull request #2 from acolytec3/openrpc-v2
acolytec3 7b920a7
switch to module
acolytec3 8820122
put prefix back to empty string
acolytec3 c5f4697
specify prefix
acolytec3 31e8683
use crazy-max
acolytec3 453178b
Merge remote-tracking branch 'upstream/main'
acolytec3 035eb3d
update spellcheck
acolytec3 c95d608
make repo name dynamic
acolytec3 0788d9f
dynamically add all md to menu
acolytec3 6f17bb6
Remove copy docs step and reorder menu links
acolytec3 989bb02
update support for latest generator
zcstarr 3c4dc1a
Merge pull request #4 from zcstarr/feat/generator_update
acolytec3 fbfcec3
remove node options detritus from deploy
acolytec3 94ce9fd
chore: change to mdx
bomanaps 3dabe2a
Replace styled table with remarkGfm plugin
acolytec3 5f630dd
Merge remote-tracking branch 'upstream/main'
acolytec3 48f8b82
Clean up links and add tests/quickstart to docs
acolytec3 11a9b3d
update test deploy to check on node 20, 22, 24
acolytec3 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,4 +7,3 @@ data.json | |
schema.json | ||
*.dic | ||
.idea/ | ||
.docusaurus |
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
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
const remarkGfm = require('remark-gfm'); | ||
|
||
module.exports = { | ||
pathPrefix: "/execution-apis", | ||
siteMetadata: { | ||
title: 'Ethereum JSON-RPC Specification', | ||
description: 'A specification of the standard interface for Ethereum clients.', | ||
siteUrl: process.env.GITHUB_REPOSITORY | ||
? `https://${process.env.GITHUB_REPOSITORY.split('/')[0]}.github.io/execution-apis` | ||
: 'https://ethereum.github.io/execution-apis', // fallback for local development | ||
logoUrl: 'https://github.com/open-rpc/design/master/icons/open-rpc-logo-noText/open-rpc-logo-noText%20(PNG)/256x256.png', | ||
primaryColor: '#3f51b5', //material-ui primary color | ||
secondaryColor: '#f50057', //material-ui secondary color | ||
author: '', | ||
menuLinks: [ | ||
{ name: 'Introduction', link: '/intro' }, | ||
{ | ||
name: 'API Documentation', | ||
link: '/api-documentation' | ||
}, | ||
{ name: 'Quickstart', link: '/quickstart' }, | ||
{ name: 'Contributors Guide', link: '/contributors-guide' }, | ||
{ name: 'Testing', link: '/tests'}, | ||
{ name: 'Ethsimulatev1 notes', link: '/ethsimulatev1-notes' }, | ||
], | ||
footerLinks: [ | ||
{ | ||
name: 'OpenRPC', | ||
link: 'https://open-rpc.org' | ||
} | ||
] | ||
}, | ||
plugins: [ | ||
{ | ||
resolve: 'gatsby-plugin-mdx', | ||
options: { | ||
extensions: ['.mdx', '.md'], | ||
gatsbyRemarkPlugins: [ | ||
{ | ||
resolve: 'gatsby-remark-autolink-headers', | ||
options: { | ||
icon: false, | ||
}, | ||
}, | ||
], | ||
mdxOptions: { | ||
remarkPlugins: [remarkGfm], | ||
}, | ||
}, | ||
}, | ||
"gatsby-openrpc-theme", | ||
{ | ||
resolve: 'gatsby-plugin-manifest', | ||
options: { | ||
name: 'pristine-site', | ||
short_name: 'pristine-site', | ||
start_url: '/execution-apis/', | ||
background_color: 'transparent', | ||
theme_color: '#3f51b5', | ||
display: 'minimal-ui', | ||
icon: 'src/images/gatsby-icon.png', // This path is relative to the root of the site. | ||
}, | ||
}, | ||
"gatsby-plugin-image", | ||
"gatsby-plugin-sharp", | ||
"gatsby-transformer-sharp", | ||
{ | ||
resolve: "gatsby-source-filesystem", | ||
options: { | ||
name: "images", | ||
path: __dirname + '/src/images', | ||
}, | ||
}, | ||
{ | ||
resolve: "gatsby-source-filesystem", | ||
options: { | ||
name: "docs", | ||
path: __dirname + '/../../../docs/reference', | ||
acolytec3 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
}, | ||
}, | ||
], | ||
} |
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
# Execution API Specification | ||
|
||
## JSON-RPC | ||
|
||
[View the spec][playground] | ||
|
||
The Ethereum JSON-RPC is a standard collection of methods that all execution | ||
clients implement. It is the canonical interface between users and the network. | ||
This interface allows downstream tooling and infrastructure to treat different | ||
Ethereum clients as modules that can be swapped at will. | ||
|
||
### Contributing | ||
|
||
Please see the [contributors guide][contributors-guide] | ||
for general information about the process of standardizing new API methods and | ||
making changes to existing ones. Information on test generation can be found | ||
in [test-gen][test-gen] | ||
|
||
The specification itself is written in [OpenRPC][openrpc]. Refer to the OpenRPC | ||
specification and the JSON schema [specification][json-schema] to get started. | ||
|
||
### Building | ||
|
||
The specification is split into multiple files to improve readability. The | ||
spec can be compiled into a single document as follows: | ||
|
||
```console | ||
$ npm install | ||
$ npm run build | ||
Build successful. | ||
``` | ||
|
||
This will output the file `openrpc.json` in the root of the project. This file | ||
will have all schema `#ref`s resolved. | ||
|
||
#### Testing | ||
|
||
There are several mechanisms for testing specification contributions and client | ||
conformance. | ||
|
||
First is the [OpenRPC validator][validator]. It performs some basic syntactic | ||
checks on the generated specification. | ||
|
||
```console | ||
$ npm install | ||
$ npm run lint | ||
OpenRPC spec validated successfully. | ||
``` | ||
|
||
Next is `speccheck`. This tool validates the test cases in the `tests` | ||
directory against the specification. | ||
|
||
```console | ||
$ go install github.com/lightclient/rpctestgen/cmd/speccheck@latest | ||
$ speccheck -v | ||
all passing. | ||
``` | ||
|
||
If you get an error that says: `speccheck: command not found`, | ||
make sure that the go binary is in your $PATH: | ||
|
||
```console | ||
$ export PATH=$HOME/go/bin:$PATH | ||
``` | ||
|
||
The spell checker ensures the specification is free of spelling errors. | ||
|
||
```console | ||
$ pip install pyspelling | ||
$ pyspelling -c spellcheck.yaml | ||
Spelling check passed :) | ||
``` | ||
|
||
pyspelling is a wrapper around either [Aspell](http://aspell.net/) or | ||
[Hunspell](https://hunspell.github.io/). You'll need to install | ||
one of those before running `pyspelling`. | ||
|
||
Finally, the test cases in the `tests/` directory may be run against individual | ||
execution client using the [`hive`] simulator [`rpc-compat`][rpc-compat]. | ||
Please see the documentation in the aforementioned repositories for more | ||
information. | ||
|
||
## GraphQL | ||
|
||
[View the spec][graphql-schema] | ||
|
||
[EIP-1767][eip-1767] proposed a GraphQL schema for interacting with Ethereum clients. Since then Besu and Geth have implemented the interface. This repo contains a live specification to integrate changes to the protocol as well as other improvements into the GraphQL schema. | ||
|
||
### Generation | ||
|
||
The schema in this repo is generated by issuing a meta GraphQL query against a live node. This can be done as follows: | ||
|
||
```console | ||
$ npm run graphql:schema | ||
``` | ||
|
||
### Testing | ||
|
||
A script is included in the source code which reads and validates the given schema to be a valid one. It is recommended to perform this check after modifying the schema by: | ||
|
||
```console | ||
$ npm run graphql:validate | ||
``` | ||
|
||
## License | ||
|
||
This repository is licensed under [CC0](LICENSE). | ||
|
||
|
||
[playground]: https://ethereum.github.io/execution-apis/docs/reference/json-rpc-api | ||
[openrpc]: https://open-rpc.org | ||
[validator]: https://open-rpc.github.io/schema-utils-js/functions/validateOpenRPCDocument.html | ||
[graphql-schema]: http://graphql-schema.ethdevops.io/?url=https://github.com/ethereum/execution-apis/main/graphql.json | ||
[eip-1767]: https://eips.ethereum.org/EIPS/eip-1767 | ||
[contributors-guide]: docs/reference/contributors-guide.md | ||
[json-schema]: https://json-schema.org | ||
[hive]: https://github.com/ethereum/hive | ||
[rpc-compat]: https://github.com/ethereum/hive/tree/master/simulators/ethereum/rpc-compat | ||
[test-gen]: docs/reference/tests.md |
File renamed without changes.
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there's an eth icon or one for execution apis we might drop that here.