# Transactions

Transactions Api

## Chain id  (v1)

> Fetch chain id

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v1/transactions/chain_id":{"get":{"tags":["Transactions"],"summary":"Chain id  (v1)","description":"Fetch chain id","operationId":"chain_id","responses":{"200":{"description":"Current chain id","content":{"application/json":{"schema":{"type":"integer","format":"u-int8","minimum":0}}}}}}}}}
```

## Estimate gas price (v1)

> Get statistics derived from the gas prices of recently executed transactions.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v1/transactions/estimate_gas_price":{"get":{"tags":["Transactions"],"summary":"Estimate gas price (v1)","description":"Get statistics derived from the gas prices of recently executed transactions.","operationId":"estimate_gas_price_v1","responses":{"200":{"description":"Returns the mean and maximum gas prices of recently executed transactions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GasPriceRes"}}}}},"deprecated":true}}},"components":{"schemas":{"GasPriceRes":{"type":"object","required":["mean_gas_price","max_gas_price"],"properties":{"mean_gas_price":{"type":"integer","format":"u-int64","minimum":0},"max_gas_price":{"type":"integer","format":"u-int64","minimum":0}}}}}}
```

## Transaction parameters v1

> Retrieve limits that a client must respect when composing a transaction.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v1/transactions/parameters":{"get":{"tags":["Transactions"],"summary":"Transaction parameters v1","description":"Retrieve limits that a client must respect when composing a transaction.","operationId":"transaction_parameter","responses":{"200":{"description":"Acceptable parameters for transaction submission","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionParameters"}}}}}}}},"components":{"schemas":{"TransactionParameters":{"type":"object","required":["max_transaction_time_to_live_seconds"],"properties":{"max_transaction_time_to_live_seconds":{"type":"integer","format":"u-int64","minimum":0}}}}}}
```

## POST /rpc/v1/transactions/simulate

> Simulate a transaction (v1)

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v1/transactions/simulate":{"post":{"tags":["Transactions"],"summary":"Simulate a transaction (v1)","operationId":"simulate_txn_v1","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupraTransaction"}}},"required":true},"responses":{"200":{"description":"Simulate a transaction against the current state of the RPC node. The transaction must have an invalid signature.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionInfoV1"}}}}},"deprecated":true}}},"components":{"schemas":{"SupraTransaction":{"oneOf":[{"type":"object","required":["Smr"],"properties":{"Smr":{"$ref":"#/components/schemas/SignedSmrTransaction"}}},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/SignedTransaction"}}}],"description":"Transaction variants supported by Supra."},"SignedSmrTransaction":{"type":"object","description":"Defines internal transactions (DKG and Oracle) coupled with signer data.","required":["signer_data","transaction"],"properties":{"signer_data":{"$ref":"#/components/schemas/SignerData","description":"Signer data on the transaction."},"transaction":{"$ref":"#/components/schemas/UnsignedSmrTransaction","description":"Unsigned internal transaction."}}},"SignerData":{"type":"object","description":"Signer information of the [crate::api::delegates::UnsignedSmrTransaction].","required":["signer","signature"],"properties":{"signer":{"type":"object","description":"PublicKey of the transaction sender and signer"},"signature":{"type":"object","description":"Signature of the transaction by signer"}}},"UnsignedSmrTransaction":{"type":"object","description":"Defines unsigned transaction enclosing only header and payload information.","required":["header","payload"],"properties":{"header":{"$ref":"#/components/schemas/SmrTransactionHeader","description":"Header of the transaction containing meta information of transaction."},"payload":{"type":"object","description":"Actual payload of the transaction tagged based on the protocol type."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"SignedTransaction":{"type":"object","description":"Defines internal transactions(DKG and Oracle) coupled with signer data.","required":["raw_txn","authenticator"],"properties":{"raw_txn":{"type":"object","description":"The raw transaction"},"authenticator":{"type":"object","description":"Public key and signature to authenticate"}}},"TransactionInfoV1":{"type":"object","description":"Information about a Supra transaction.","required":["authenticator","hash","header","payload","status"],"properties":{"authenticator":{"type":"object","description":"The cryptographic material that was submitted with the transaction, according to its type."},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/TransactionBlockInfo","description":"Metadata about the block containing the transaction, if any. This field should\nnot be set if this [TransactionInfoV1] is yet to be included in a [Block]."}]},"hash":{"$ref":"#/components/schemas/Hash"},"header":{"$ref":"#/components/schemas/SmrTransactionHeader"},"payload":{"type":"object","description":"The deserialized payload of the transaction according to its type."},"output":{"oneOf":[{"$ref":"#/components/schemas/TransactionOutput"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}},"TransactionBlockInfo":{"type":"object","description":"Metadata about the block that finalized a particular [SmrTransaction].","required":["hash","height","timestamp"],"properties":{"hash":{"$ref":"#/components/schemas/Hash"},"height":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The height of the related block."},"timestamp":{"$ref":"#/components/schemas/SmrTimestamp"}},"deprecated":true},"Hash":{"type":"string","description":"Hex encoded hash"},"TransactionOutput":{"oneOf":[{"type":"object","required":["Dkg"],"properties":{"Dkg":{"$ref":"#/components/schemas/TxExecutionStatus"}}},{"type":"string","enum":["Empty"]},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/MoveTransactionOutput"}}},{"type":"object","required":["Oracle"],"properties":{"Oracle":{"$ref":"#/components/schemas/TxExecutionStatus"}}}],"description":"[crate::api::v1::TransactionOutput] with all fields in human-readable format."},"TxExecutionStatus":{"type":"string","enum":["Success","Fail","Invalid","PendingAfterExecution","Pending"]},"MoveTransactionOutput":{"type":"object","description":"The execution output of a Move transaction.","required":["gas_used","events","vm_status"],"properties":{"gas_used":{"type":"integer","format":"u-int64","description":"The gas used by the transaction.","minimum":0},"events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"vm_status":{"type":"string","description":"A message summarizing the execution result produced by the MoveVM."}}},"Event":{"type":"object","description":"On-chain event.","required":["guid","sequence_number","type","data"],"properties":{"guid":{"type":"string","description":"The globally unique identifier of this event stream."},"sequence_number":{"type":"integer","format":"u-int64","minimum":0},"type":{"type":"string","description":"The `MoveType` of the event"},"data":{"description":"The JSON representation of the event"}}}}}}
```

## Submit transaction (v1)

> Submit a transaction to Supra.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v1/transactions/submit":{"post":{"tags":["Transactions"],"summary":"Submit transaction (v1)","description":"Submit a transaction to Supra.","operationId":"submit_txn","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupraTransaction"}}},"required":true},"responses":{"200":{"description":"transaction submitted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Hash"}}}}}}}},"components":{"schemas":{"SupraTransaction":{"oneOf":[{"type":"object","required":["Smr"],"properties":{"Smr":{"$ref":"#/components/schemas/SignedSmrTransaction"}}},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/SignedTransaction"}}}],"description":"Transaction variants supported by Supra."},"SignedSmrTransaction":{"type":"object","description":"Defines internal transactions (DKG and Oracle) coupled with signer data.","required":["signer_data","transaction"],"properties":{"signer_data":{"$ref":"#/components/schemas/SignerData","description":"Signer data on the transaction."},"transaction":{"$ref":"#/components/schemas/UnsignedSmrTransaction","description":"Unsigned internal transaction."}}},"SignerData":{"type":"object","description":"Signer information of the [crate::api::delegates::UnsignedSmrTransaction].","required":["signer","signature"],"properties":{"signer":{"type":"object","description":"PublicKey of the transaction sender and signer"},"signature":{"type":"object","description":"Signature of the transaction by signer"}}},"UnsignedSmrTransaction":{"type":"object","description":"Defines unsigned transaction enclosing only header and payload information.","required":["header","payload"],"properties":{"header":{"$ref":"#/components/schemas/SmrTransactionHeader","description":"Header of the transaction containing meta information of transaction."},"payload":{"type":"object","description":"Actual payload of the transaction tagged based on the protocol type."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"SignedTransaction":{"type":"object","description":"Defines internal transactions(DKG and Oracle) coupled with signer data.","required":["raw_txn","authenticator"],"properties":{"raw_txn":{"type":"object","description":"The raw transaction"},"authenticator":{"type":"object","description":"Public key and signature to authenticate"}}},"Hash":{"type":"string","description":"Hex encoded hash"}}}}
```

## Get transaction by hash (v1)

> Get information about a transaction by its hash.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v1/transactions/{hash}":{"get":{"tags":["Transactions"],"summary":"Get transaction by hash (v1)","description":"Get information about a transaction by its hash.","operationId":"transaction_by_hash_v1","parameters":[{"name":"hash","in":"path","description":"Hash of the transaction to lookup","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Transaction data of the given transaction hash","content":{"application/json":{"schema":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/TransactionInfoV1"}]}}}}},"deprecated":true}}},"components":{"schemas":{"TransactionInfoV1":{"type":"object","description":"Information about a Supra transaction.","required":["authenticator","hash","header","payload","status"],"properties":{"authenticator":{"type":"object","description":"The cryptographic material that was submitted with the transaction, according to its type."},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/TransactionBlockInfo","description":"Metadata about the block containing the transaction, if any. This field should\nnot be set if this [TransactionInfoV1] is yet to be included in a [Block]."}]},"hash":{"$ref":"#/components/schemas/Hash"},"header":{"$ref":"#/components/schemas/SmrTransactionHeader"},"payload":{"type":"object","description":"The deserialized payload of the transaction according to its type."},"output":{"oneOf":[{"$ref":"#/components/schemas/TransactionOutput"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}},"TransactionBlockInfo":{"type":"object","description":"Metadata about the block that finalized a particular [SmrTransaction].","required":["hash","height","timestamp"],"properties":{"hash":{"$ref":"#/components/schemas/Hash"},"height":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The height of the related block."},"timestamp":{"$ref":"#/components/schemas/SmrTimestamp"}},"deprecated":true},"Hash":{"type":"string","description":"Hex encoded hash"},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"TransactionOutput":{"oneOf":[{"type":"object","required":["Dkg"],"properties":{"Dkg":{"$ref":"#/components/schemas/TxExecutionStatus"}}},{"type":"string","enum":["Empty"]},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/MoveTransactionOutput"}}},{"type":"object","required":["Oracle"],"properties":{"Oracle":{"$ref":"#/components/schemas/TxExecutionStatus"}}}],"description":"[crate::api::v1::TransactionOutput] with all fields in human-readable format."},"TxExecutionStatus":{"type":"string","enum":["Success","Fail","Invalid","PendingAfterExecution","Pending"]},"MoveTransactionOutput":{"type":"object","description":"The execution output of a Move transaction.","required":["gas_used","events","vm_status"],"properties":{"gas_used":{"type":"integer","format":"u-int64","description":"The gas used by the transaction.","minimum":0},"events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"vm_status":{"type":"string","description":"A message summarizing the execution result produced by the MoveVM."}}},"Event":{"type":"object","description":"On-chain event.","required":["guid","sequence_number","type","data"],"properties":{"guid":{"type":"string","description":"The globally unique identifier of this event stream."},"sequence_number":{"type":"integer","format":"u-int64","minimum":0},"type":{"type":"string","description":"The `MoveType` of the event"},"data":{"description":"The JSON representation of the event"}}}}}}
```

## Estimate gas price (v2)

> Get statistics derived from the gas prices of recently executed transactions.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v2/transactions/estimate_gas_price":{"get":{"tags":["Transactions"],"summary":"Estimate gas price (v2)","description":"Get statistics derived from the gas prices of recently executed transactions.","operationId":"estimate_gas_price_v2","responses":{"200":{"description":"Returns the mean, median and maximum gas prices of recently executed transactions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GasPriceResV2"}}}}}}}},"components":{"schemas":{"GasPriceResV2":{"type":"object","required":["mean_gas_price","max_gas_price","median_gas_price"],"properties":{"mean_gas_price":{"type":"integer","format":"u-int64","minimum":0},"max_gas_price":{"type":"integer","format":"u-int64","minimum":0},"median_gas_price":{"type":"integer","format":"u-int64","minimum":0}}}}}}
```

## POST /rpc/v2/transactions/simulate

> Simulate a transaction (v2)

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v2/transactions/simulate":{"post":{"tags":["Transactions"],"summary":"Simulate a transaction (v2)","operationId":"simulate_txn_v2","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupraTransaction"}}},"required":true},"responses":{"200":{"description":"Simulate a transaction against the current state of the RPC node. The transaction must have an invalid signature.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionInfoV2"}}}}}}}},"components":{"schemas":{"SupraTransaction":{"oneOf":[{"type":"object","required":["Smr"],"properties":{"Smr":{"$ref":"#/components/schemas/SignedSmrTransaction"}}},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/SignedTransaction"}}}],"description":"Transaction variants supported by Supra."},"SignedSmrTransaction":{"type":"object","description":"Defines internal transactions (DKG and Oracle) coupled with signer data.","required":["signer_data","transaction"],"properties":{"signer_data":{"$ref":"#/components/schemas/SignerData","description":"Signer data on the transaction."},"transaction":{"$ref":"#/components/schemas/UnsignedSmrTransaction","description":"Unsigned internal transaction."}}},"SignerData":{"type":"object","description":"Signer information of the [crate::api::delegates::UnsignedSmrTransaction].","required":["signer","signature"],"properties":{"signer":{"type":"object","description":"PublicKey of the transaction sender and signer"},"signature":{"type":"object","description":"Signature of the transaction by signer"}}},"UnsignedSmrTransaction":{"type":"object","description":"Defines unsigned transaction enclosing only header and payload information.","required":["header","payload"],"properties":{"header":{"$ref":"#/components/schemas/SmrTransactionHeader","description":"Header of the transaction containing meta information of transaction."},"payload":{"type":"object","description":"Actual payload of the transaction tagged based on the protocol type."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"SignedTransaction":{"type":"object","description":"Defines internal transactions(DKG and Oracle) coupled with signer data.","required":["raw_txn","authenticator"],"properties":{"raw_txn":{"type":"object","description":"The raw transaction"},"authenticator":{"type":"object","description":"Public key and signature to authenticate"}}},"TransactionInfoV2":{"type":"object","description":"Information about a Supra transaction.","required":["authenticator","hash","header","payload","status"],"properties":{"authenticator":{"type":"object","description":"The cryptographic material that was submitted with the transaction, according to its type."},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/BlockHeaderInfo","description":"Metadata about the block containing the transaction, if any. This field should\nnot be set if this [TransactionInfoV2] is yet to be included in a [Block]."}]},"hash":{"$ref":"#/components/schemas/Hash"},"header":{"$ref":"#/components/schemas/SmrTransactionHeader"},"payload":{"type":"object","description":"The deserialized payload of the transaction according to its type."},"output":{"oneOf":[{"$ref":"#/components/schemas/TransactionOutput"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}},"BlockHeaderInfo":{"type":"object","description":"Metadata about a Supra block.","required":["author","hash","height","parent","timestamp","view"],"properties":{"author":{"$ref":"#/components/schemas/Identity"},"hash":{"$ref":"#/components/schemas/Hash"},"height":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Number of blocks before this block in the chain (including the genesis block)."},"parent":{"$ref":"#/components/schemas/Hash"},"timestamp":{"$ref":"#/components/schemas/SmrTimestamp"},"view":{"$ref":"#/components/schemas/View"}}},"Identity":{"type":"string","description":"Hex encoded identity."},"Hash":{"type":"string","description":"Hex encoded hash"},"View":{"type":"object","required":["epoch_id","round"],"properties":{"epoch_id":{"$ref":"#/components/schemas/EpochId","description":"Identifier of the consensus epoch."},"round":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the consensus round."}}},"EpochId":{"type":"object","required":["chain_id","epoch"],"properties":{"chain_id":{"oneOf":[{"type":"integer","format":"u-int8","minimum":0}],"description":"Unique identifier for this instance of the SMR."},"epoch":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the epoch within the context of `chain_id`."}}},"TransactionOutput":{"oneOf":[{"type":"object","required":["Dkg"],"properties":{"Dkg":{"$ref":"#/components/schemas/TxExecutionStatus"}}},{"type":"string","enum":["Empty"]},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/MoveTransactionOutput"}}},{"type":"object","required":["Oracle"],"properties":{"Oracle":{"$ref":"#/components/schemas/TxExecutionStatus"}}}],"description":"[crate::api::v1::TransactionOutput] with all fields in human-readable format."},"TxExecutionStatus":{"type":"string","enum":["Success","Fail","Invalid","PendingAfterExecution","Pending"]},"MoveTransactionOutput":{"type":"object","description":"The execution output of a Move transaction.","required":["gas_used","events","vm_status"],"properties":{"gas_used":{"type":"integer","format":"u-int64","description":"The gas used by the transaction.","minimum":0},"events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"vm_status":{"type":"string","description":"A message summarizing the execution result produced by the MoveVM."}}},"Event":{"type":"object","description":"On-chain event.","required":["guid","sequence_number","type","data"],"properties":{"guid":{"type":"string","description":"The globally unique identifier of this event stream."},"sequence_number":{"type":"integer","format":"u-int64","minimum":0},"type":{"type":"string","description":"The `MoveType` of the event"},"data":{"description":"The JSON representation of the event"}}}}}}
```

## Get transaction by hash (v2)

> Get information about a transaction by its hash.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v2/transactions/{hash}":{"get":{"tags":["Transactions"],"summary":"Get transaction by hash (v2)","description":"Get information about a transaction by its hash.","operationId":"transaction_by_hash_v2","parameters":[{"name":"hash","in":"path","description":"Hash of the transaction to lookup","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Transaction data of the given transaction hash","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionInfoV2"}}}}}}}},"components":{"schemas":{"TransactionInfoV2":{"type":"object","description":"Information about a Supra transaction.","required":["authenticator","hash","header","payload","status"],"properties":{"authenticator":{"type":"object","description":"The cryptographic material that was submitted with the transaction, according to its type."},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/BlockHeaderInfo","description":"Metadata about the block containing the transaction, if any. This field should\nnot be set if this [TransactionInfoV2] is yet to be included in a [Block]."}]},"hash":{"$ref":"#/components/schemas/Hash"},"header":{"$ref":"#/components/schemas/SmrTransactionHeader"},"payload":{"type":"object","description":"The deserialized payload of the transaction according to its type."},"output":{"oneOf":[{"$ref":"#/components/schemas/TransactionOutput"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}},"BlockHeaderInfo":{"type":"object","description":"Metadata about a Supra block.","required":["author","hash","height","parent","timestamp","view"],"properties":{"author":{"$ref":"#/components/schemas/Identity"},"hash":{"$ref":"#/components/schemas/Hash"},"height":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Number of blocks before this block in the chain (including the genesis block)."},"parent":{"$ref":"#/components/schemas/Hash"},"timestamp":{"$ref":"#/components/schemas/SmrTimestamp"},"view":{"$ref":"#/components/schemas/View"}}},"Identity":{"type":"string","description":"Hex encoded identity."},"Hash":{"type":"string","description":"Hex encoded hash"},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"View":{"type":"object","required":["epoch_id","round"],"properties":{"epoch_id":{"$ref":"#/components/schemas/EpochId","description":"Identifier of the consensus epoch."},"round":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the consensus round."}}},"EpochId":{"type":"object","required":["chain_id","epoch"],"properties":{"chain_id":{"oneOf":[{"type":"integer","format":"u-int8","minimum":0}],"description":"Unique identifier for this instance of the SMR."},"epoch":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the epoch within the context of `chain_id`."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"TransactionOutput":{"oneOf":[{"type":"object","required":["Dkg"],"properties":{"Dkg":{"$ref":"#/components/schemas/TxExecutionStatus"}}},{"type":"string","enum":["Empty"]},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/MoveTransactionOutput"}}},{"type":"object","required":["Oracle"],"properties":{"Oracle":{"$ref":"#/components/schemas/TxExecutionStatus"}}}],"description":"[crate::api::v1::TransactionOutput] with all fields in human-readable format."},"TxExecutionStatus":{"type":"string","enum":["Success","Fail","Invalid","PendingAfterExecution","Pending"]},"MoveTransactionOutput":{"type":"object","description":"The execution output of a Move transaction.","required":["gas_used","events","vm_status"],"properties":{"gas_used":{"type":"integer","format":"u-int64","description":"The gas used by the transaction.","minimum":0},"events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"vm_status":{"type":"string","description":"A message summarizing the execution result produced by the MoveVM."}}},"Event":{"type":"object","description":"On-chain event.","required":["guid","sequence_number","type","data"],"properties":{"guid":{"type":"string","description":"The globally unique identifier of this event stream."},"sequence_number":{"type":"integer","format":"u-int64","minimum":0},"type":{"type":"string","description":"The `MoveType` of the event"},"data":{"description":"The JSON representation of the event"}}}}}}
```

## POST /rpc/v3/transactions/simulate

> Simulate a transaction (v3)

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v3/transactions/simulate":{"post":{"tags":["Transactions"],"summary":"Simulate a transaction (v3)","operationId":"simulate_txn_v3","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupraTransaction"}},"application/x.supra.signed_transaction+bcs":{"schema":{"type":"array","items":{"type":"integer","format":"u-int8","minimum":0}}}},"required":true},"responses":{"200":{"description":"Simulate a transaction against the current state of the RPC node. The transaction must have an invalid signature.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionInfoV2"}}}}}}}},"components":{"schemas":{"SupraTransaction":{"oneOf":[{"type":"object","required":["Smr"],"properties":{"Smr":{"$ref":"#/components/schemas/SignedSmrTransaction"}}},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/SignedTransaction"}}}],"description":"Transaction variants supported by Supra."},"SignedSmrTransaction":{"type":"object","description":"Defines internal transactions (DKG and Oracle) coupled with signer data.","required":["signer_data","transaction"],"properties":{"signer_data":{"$ref":"#/components/schemas/SignerData","description":"Signer data on the transaction."},"transaction":{"$ref":"#/components/schemas/UnsignedSmrTransaction","description":"Unsigned internal transaction."}}},"SignerData":{"type":"object","description":"Signer information of the [crate::api::delegates::UnsignedSmrTransaction].","required":["signer","signature"],"properties":{"signer":{"type":"object","description":"PublicKey of the transaction sender and signer"},"signature":{"type":"object","description":"Signature of the transaction by signer"}}},"UnsignedSmrTransaction":{"type":"object","description":"Defines unsigned transaction enclosing only header and payload information.","required":["header","payload"],"properties":{"header":{"$ref":"#/components/schemas/SmrTransactionHeader","description":"Header of the transaction containing meta information of transaction."},"payload":{"type":"object","description":"Actual payload of the transaction tagged based on the protocol type."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"SignedTransaction":{"type":"object","description":"Defines internal transactions(DKG and Oracle) coupled with signer data.","required":["raw_txn","authenticator"],"properties":{"raw_txn":{"type":"object","description":"The raw transaction"},"authenticator":{"type":"object","description":"Public key and signature to authenticate"}}},"TransactionInfoV2":{"type":"object","description":"Information about a Supra transaction.","required":["authenticator","hash","header","payload","status"],"properties":{"authenticator":{"type":"object","description":"The cryptographic material that was submitted with the transaction, according to its type."},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/BlockHeaderInfo","description":"Metadata about the block containing the transaction, if any. This field should\nnot be set if this [TransactionInfoV2] is yet to be included in a [Block]."}]},"hash":{"$ref":"#/components/schemas/Hash"},"header":{"$ref":"#/components/schemas/SmrTransactionHeader"},"payload":{"type":"object","description":"The deserialized payload of the transaction according to its type."},"output":{"oneOf":[{"$ref":"#/components/schemas/TransactionOutput"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}},"BlockHeaderInfo":{"type":"object","description":"Metadata about a Supra block.","required":["author","hash","height","parent","timestamp","view"],"properties":{"author":{"$ref":"#/components/schemas/Identity"},"hash":{"$ref":"#/components/schemas/Hash"},"height":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Number of blocks before this block in the chain (including the genesis block)."},"parent":{"$ref":"#/components/schemas/Hash"},"timestamp":{"$ref":"#/components/schemas/SmrTimestamp"},"view":{"$ref":"#/components/schemas/View"}}},"Identity":{"type":"string","description":"Hex encoded identity."},"Hash":{"type":"string","description":"Hex encoded hash"},"View":{"type":"object","required":["epoch_id","round"],"properties":{"epoch_id":{"$ref":"#/components/schemas/EpochId","description":"Identifier of the consensus epoch."},"round":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the consensus round."}}},"EpochId":{"type":"object","required":["chain_id","epoch"],"properties":{"chain_id":{"oneOf":[{"type":"integer","format":"u-int8","minimum":0}],"description":"Unique identifier for this instance of the SMR."},"epoch":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the epoch within the context of `chain_id`."}}},"TransactionOutput":{"oneOf":[{"type":"object","required":["Dkg"],"properties":{"Dkg":{"$ref":"#/components/schemas/TxExecutionStatus"}}},{"type":"string","enum":["Empty"]},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/MoveTransactionOutput"}}},{"type":"object","required":["Oracle"],"properties":{"Oracle":{"$ref":"#/components/schemas/TxExecutionStatus"}}}],"description":"[crate::api::v1::TransactionOutput] with all fields in human-readable format."},"TxExecutionStatus":{"type":"string","enum":["Success","Fail","Invalid","PendingAfterExecution","Pending"]},"MoveTransactionOutput":{"type":"object","description":"The execution output of a Move transaction.","required":["gas_used","events","vm_status"],"properties":{"gas_used":{"type":"integer","format":"u-int64","description":"The gas used by the transaction.","minimum":0},"events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"vm_status":{"type":"string","description":"A message summarizing the execution result produced by the MoveVM."}}},"Event":{"type":"object","description":"On-chain event.","required":["guid","sequence_number","type","data"],"properties":{"guid":{"type":"string","description":"The globally unique identifier of this event stream."},"sequence_number":{"type":"integer","format":"u-int64","minimum":0},"type":{"type":"string","description":"The `MoveType` of the event"},"data":{"description":"The JSON representation of the event"}}}}}}
```

## Submit transaction (v3)

> Submit a transaction to Supra.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v3/transactions/submit":{"post":{"tags":["Transactions"],"summary":"Submit transaction (v3)","description":"Submit a transaction to Supra.","operationId":"submit_txn_v3","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupraTransaction"}},"application/x.supra.signed_transaction+bcs":{"schema":{"type":"array","items":{"type":"integer","format":"u-int8","minimum":0}}}},"required":true},"responses":{"200":{"description":"transaction submitted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Hash"}}}}}}}},"components":{"schemas":{"SupraTransaction":{"oneOf":[{"type":"object","required":["Smr"],"properties":{"Smr":{"$ref":"#/components/schemas/SignedSmrTransaction"}}},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/SignedTransaction"}}}],"description":"Transaction variants supported by Supra."},"SignedSmrTransaction":{"type":"object","description":"Defines internal transactions (DKG and Oracle) coupled with signer data.","required":["signer_data","transaction"],"properties":{"signer_data":{"$ref":"#/components/schemas/SignerData","description":"Signer data on the transaction."},"transaction":{"$ref":"#/components/schemas/UnsignedSmrTransaction","description":"Unsigned internal transaction."}}},"SignerData":{"type":"object","description":"Signer information of the [crate::api::delegates::UnsignedSmrTransaction].","required":["signer","signature"],"properties":{"signer":{"type":"object","description":"PublicKey of the transaction sender and signer"},"signature":{"type":"object","description":"Signature of the transaction by signer"}}},"UnsignedSmrTransaction":{"type":"object","description":"Defines unsigned transaction enclosing only header and payload information.","required":["header","payload"],"properties":{"header":{"$ref":"#/components/schemas/SmrTransactionHeader","description":"Header of the transaction containing meta information of transaction."},"payload":{"type":"object","description":"Actual payload of the transaction tagged based on the protocol type."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"SignedTransaction":{"type":"object","description":"Defines internal transactions(DKG and Oracle) coupled with signer data.","required":["raw_txn","authenticator"],"properties":{"raw_txn":{"type":"object","description":"The raw transaction"},"authenticator":{"type":"object","description":"Public key and signature to authenticate"}}},"Hash":{"type":"string","description":"Hex encoded hash"}}}}
```

## Get transaction by hash v3

> Get information about a transaction by its hash.

```json
{"openapi":"3.1.0","info":{"title":"Supra RPC Node","version":"59f32573d4ca6e9e0f8e04896600ea56ff9fd0bc"},"tags":[{"name":"Transactions","description":"Transactions Api"}],"servers":[{"url":"https://rpc-testnet.supra.com","description":"RPC For Supra Scan and Faucet"},{"url":"https://rpc-wallet-testnet.supra.com","description":"RPC For Wallet"},{"url":"https://rpc-suprascan-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-archive-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-suprascan-reprocessing-testnet.supra.com","description":"RPC For Suprascan"},{"url":"https://rpc-testnet1.supra.com","description":"RPC For nodeops group1"},{"url":"http://localhost:27000","description":"LocalNet"}],"paths":{"/rpc/v3/transactions/{hash}":{"get":{"tags":["Transactions"],"summary":"Get transaction by hash v3","description":"Get information about a transaction by its hash.","operationId":"transaction_by_hash_v3","parameters":[{"name":"type","in":"query","description":"Transaction type to query. If missing any/all type of transactions will be looked for.","required":false,"schema":{"type":"string","description":"Type of the transaction to be queried.","enum":["auto","user","meta"]}},{"name":"hash","in":"path","description":"Hash of the transaction to lookup","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Transaction data of the given transaction hash","headers":{},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Transaction"}}}}}}}},"components":{"schemas":{"Transaction":{"oneOf":[{"allOf":[{"$ref":"#/components/schemas/TransactionInfoV2"},{"type":"object","required":["txn_type"],"properties":{"txn_type":{"type":"string","enum":["user"]}}}]},{"allOf":[{"$ref":"#/components/schemas/TransactionInfoV2"},{"type":"object","required":["txn_type"],"properties":{"txn_type":{"type":"string","enum":["automated"]}}}]},{"allOf":[{"$ref":"#/components/schemas/BlockMetadataInfo"},{"type":"object","required":["txn_type"],"properties":{"txn_type":{"type":"string","enum":["block_metadata"]}}}]}]},"TransactionInfoV2":{"type":"object","description":"Information about a Supra transaction.","required":["authenticator","hash","header","payload","status"],"properties":{"authenticator":{"type":"object","description":"The cryptographic material that was submitted with the transaction, according to its type."},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/BlockHeaderInfo","description":"Metadata about the block containing the transaction, if any. This field should\nnot be set if this [TransactionInfoV2] is yet to be included in a [Block]."}]},"hash":{"$ref":"#/components/schemas/Hash"},"header":{"$ref":"#/components/schemas/SmrTransactionHeader"},"payload":{"type":"object","description":"The deserialized payload of the transaction according to its type."},"output":{"oneOf":[{"$ref":"#/components/schemas/TransactionOutput"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}},"BlockHeaderInfo":{"type":"object","description":"Metadata about a Supra block.","required":["author","hash","height","parent","timestamp","view"],"properties":{"author":{"$ref":"#/components/schemas/Identity"},"hash":{"$ref":"#/components/schemas/Hash"},"height":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Number of blocks before this block in the chain (including the genesis block)."},"parent":{"$ref":"#/components/schemas/Hash"},"timestamp":{"$ref":"#/components/schemas/SmrTimestamp"},"view":{"$ref":"#/components/schemas/View"}}},"Identity":{"type":"string","description":"Hex encoded identity."},"Hash":{"type":"string","description":"Hex encoded hash"},"SmrTimestamp":{"type":"object","required":["timestamp"],"properties":{"timestamp":{"type":"integer","format":"u-int64","description":"The timestamp as measured in the number of microseconds since the unix epoch.","minimum":0}}},"View":{"type":"object","required":["epoch_id","round"],"properties":{"epoch_id":{"$ref":"#/components/schemas/EpochId","description":"Identifier of the consensus epoch."},"round":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the consensus round."}}},"EpochId":{"type":"object","required":["chain_id","epoch"],"properties":{"chain_id":{"oneOf":[{"type":"integer","format":"u-int8","minimum":0}],"description":"Unique identifier for this instance of the SMR."},"epoch":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"Identifier of the epoch within the context of `chain_id`."}}},"SmrTransactionHeader":{"type":"object","required":["chain_id","expiration_timestamp","sender","sequence_number","gas_unit_price","max_gas_amount"],"properties":{"chain_id":{"type":"integer","format":"uint8","description":"The unique identifier for the instance of the Supra chain that this transaction should\nbe executed upon.","minimum":0},"expiration_timestamp":{"$ref":"#/components/schemas/SmrTimestamp","description":"The time at which this transaction should be discarded if it has not been executed."},"sender":{"$ref":"#/components/schemas/AccountAddress","description":"The standardized representation of the sender's account address in the target VM."},"sequence_number":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The sequence number of the sender's account in the target VM."},"gas_unit_price":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The amount of Supra that the sender is willing to pay per unit of gas."},"max_gas_amount":{"oneOf":[{"type":"integer","format":"u-int64","minimum":0}],"description":"The maximum amount of gas that the sender is willing to spend."}}},"AccountAddress":{"type":"string","description":"Hex encoded account address."},"TransactionOutput":{"oneOf":[{"type":"object","required":["Dkg"],"properties":{"Dkg":{"$ref":"#/components/schemas/TxExecutionStatus"}}},{"type":"string","enum":["Empty"]},{"type":"object","required":["Move"],"properties":{"Move":{"$ref":"#/components/schemas/MoveTransactionOutput"}}},{"type":"object","required":["Oracle"],"properties":{"Oracle":{"$ref":"#/components/schemas/TxExecutionStatus"}}}],"description":"[crate::api::v1::TransactionOutput] with all fields in human-readable format."},"TxExecutionStatus":{"type":"string","enum":["Success","Fail","Invalid","PendingAfterExecution","Pending"]},"MoveTransactionOutput":{"type":"object","description":"The execution output of a Move transaction.","required":["gas_used","events","vm_status"],"properties":{"gas_used":{"type":"integer","format":"u-int64","description":"The gas used by the transaction.","minimum":0},"events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"vm_status":{"type":"string","description":"A message summarizing the execution result produced by the MoveVM."}}},"Event":{"type":"object","description":"On-chain event.","required":["guid","sequence_number","type","data"],"properties":{"guid":{"type":"string","description":"The globally unique identifier of this event stream."},"sequence_number":{"type":"integer","format":"u-int64","minimum":0},"type":{"type":"string","description":"The `MoveType` of the event"},"data":{"description":"The JSON representation of the event"}}},"BlockMetadataInfo":{"type":"object","description":"Details of block metadata transaction execution","required":["hash","output","status"],"properties":{"hash":{"$ref":"#/components/schemas/Hash"},"block_header":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/BlockHeaderInfo","description":"Metadata about the block containing the transaction, if any.\nThis field will not be set for transactions that are returned as a part of a block."}]},"output":{"$ref":"#/components/schemas/TransactionOutput"},"status":{"$ref":"#/components/schemas/TxExecutionStatus"}}}}}}
```
