Skip to content

Commit

Permalink
Merge pull request #1447 from pierre-l/1429-get-transaction-receipt
Browse files Browse the repository at this point in the history
 feat(rpc/v05): add `starknet_getTransactionReceipt` implementation
  • Loading branch information
pierre-l authored Oct 20, 2023
2 parents 6c78cbe + 762dffe commit 4a2a176
Show file tree
Hide file tree
Showing 5 changed files with 867 additions and 2 deletions.
3 changes: 1 addition & 2 deletions crates/rpc/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -823,8 +823,7 @@ mod tests {
#[case::root_write("/", "v04/starknet_write_api.json", &[])]
#[case::root_pathfinder("/", "pathfinder_rpc_api.json", &["pathfinder_version"])]

#[case::v05_api ("/rpc/v0.5", "v05/starknet_api_openrpc.json",
&["starknet_getTransactionReceipt"])]
#[case::v05_api ("/rpc/v0.5", "v05/starknet_api_openrpc.json", &[])]
#[case::v05_trace("/rpc/v0.5", "v05/starknet_trace_api_openrpc.json", &[])]
#[case::v05_write("/rpc/v0.5", "v05/starknet_write_api.json", &[])]
#[case::v05_pathfinder("/rpc/v0.5", "pathfinder_rpc_api.json", &["pathfinder_version"])]
Expand Down
1 change: 1 addition & 0 deletions crates/rpc/src/v05.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ pub fn register_routes() -> RpcRouterBuilder {
.register("starknet_estimateMessageFee" , v04_method::estimate_message_fee)
.register("starknet_getTransactionByBlockIdAndIndex" , v04_method::get_transaction_by_block_id_and_index)
.register("starknet_getTransactionByHash" , v04_method::get_transaction_by_hash)
.register("starknet_getTransactionReceipt" , method::get_transaction_receipt)
.register("starknet_syncing" , v04_method::syncing)

.register("starknet_getBlockWithTxHashes" , method::get_block_with_tx_hashes)
Expand Down
2 changes: 2 additions & 0 deletions crates/rpc/src/v05/method.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
mod get_block_with_tx_hashes;
mod get_block_with_txs;
mod get_transaction_receipt;
mod get_transaction_status;
mod simulate_transactions;
mod spec_version;
Expand All @@ -8,6 +9,7 @@ mod trace_transaction;

pub(crate) use get_block_with_tx_hashes::get_block_with_tx_hashes;
pub(crate) use get_block_with_txs::get_block_with_txs;
pub(crate) use get_transaction_receipt::get_transaction_receipt;
pub(crate) use get_transaction_status::get_transaction_status;
pub(crate) use simulate_transactions::simulate_transactions;
pub(crate) use spec_version::spec_version;
Expand Down
Loading

0 comments on commit 4a2a176

Please sign in to comment.