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

feat(error): added errors for calling certain methods on the pending block #237

Open
wants to merge 1 commit into
base: v0.8.0
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions api/starknet_ws_api.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@
"errors": [
{
"$ref": "#/components/errors/TOO_MANY_BLOCKS_BACK"
},
{
"$ref": "#/components/errors/CALL_ON_PENDING"
}
]
},
Expand Down Expand Up @@ -95,6 +98,9 @@
},
{
"$ref": "#/components/errors/TOO_MANY_BLOCKS_BACK"
},
{
"$ref": "#/components/errors/CALL_ON_PENDING"
}
]
},
Expand Down Expand Up @@ -278,7 +284,6 @@
]
}
],

"components": {
"schemas": {
"FELT": {
Expand Down Expand Up @@ -337,7 +342,12 @@
"$ref": "./api/starknet_api_openrpc.json#/components/schemas/BLOCK_NUMBER"
}
},
"required": ["starting_block_hash", "starting_block_number", "ending_block_hash", "ending_block_number"]
"required": [
"starting_block_hash",
"starting_block_number",
"ending_block_hash",
"ending_block_number"
]
}
},
"errors": {
Expand All @@ -352,6 +362,10 @@
"TOO_MANY_BLOCKS_BACK": {
"code": 68,
"message": "Cannot go back more than 1024 blocks"
},
"CALL_ON_PENDING": {
"code": 69,
"message": "This method does not support being called on a pending block"
}
}
}
Expand Down