BatchGetTransactions - Sui

BatchGetTransactions. Returns several executed transactions by digest.

BatchGetTransactions - sui [Value: 20CU]
Returns several executed transactions by their digests. Each entry contains either the transaction or an error.
gRPC: sui.rpc.v2.LedgerService/BatchGetTransactions
Use cases

Use cases

  • Load transaction history pages
  • Check status of many transactions
  • Reduce request round trips
Constraints

Constraints

  • At most 200 digests per request
  • One mask for all transactions
  • Per-item errors, not call errors
Get started
Unlock Access to 100+ chains
Boost your app's speed and reliability with dRPC - get your access API key

Language

Request
Examples
grpcurl \
  -H "x-drpc-key: {API-KEY}" \
  -H "x-drpc-chain: sui" \
  -d '{
  "digests": [
    "J4NvV5iQZQFm1xKPYv9ffDCCPW6cZ4yFKsCqFUiDX5L4",
    "4FzT2nRk8hVqY6mJ3wX9cB1aE5dG7sL2pN4uK8oH6iQ3"
  ],
  "read_mask": "digest,effects.status,checkpoint"
}' \
  grpc.drpc.live:443 \
  sui.rpc.v2.LedgerService/BatchGetTransactions
Copy
Response
200
{
  "transactions": [
    {
      "transaction": {
        "digest": "J4NvV5iQZQFm1xKPYv9ffDCCPW6cZ4yFKsCqFUiDX5L4",
        "effects": { "status": { "success": true } },
        "checkpoint": "260411490"
      }
    },
    {
      "transaction": {
        "digest": "4FzT2nRk8hVqY6mJ3wX9cB1aE5dG7sL2pN4uK8oH6iQ3",
        "effects": { "status": { "success": true } },
        "checkpoint": "260411472"
      }
    }
  ]
}
Copy

Request params

Parametersobject
object
digestsarray_of_strings
Required. Digests of the requested transactions, at most 200.
read_maskstring
Optional. google.protobuf.FieldMask with the fields to return, as comma-separated paths. Defaults to `digest`. Use `*` to return all fields.

Response

200
Returns several executed transactions by their digests. Each entry contains either the transaction or an error.

Response params

object
transactionsarray_of_objects
Results in request order.
object
transactionobject
The executed transaction, if found.
object
digeststring
The transaction digest.
transactionobject
The transaction itself: `bcs`, `digest`, `version`, `kind`, `sender`, `gas_payment`, `expiration`.
signaturesarray_of_objects
User signatures authorizing the transaction.
effectsobject
Transaction effects.
object
statusobject
Execution status: `success`, and `error` if it failed.
epochstring
Epoch in which the transaction was executed.
gas_usedobject
Gas used by the transaction: `computation_cost`, `storage_cost`, `storage_rebate`, `non_refundable_storage_fee`.
changed_objectsarray_of_objects
Objects whose state was changed by the transaction.
gas_objectobject
Information about the gas object. Not set for system transactions that do not require gas.
dependenciesarray_of_strings
Digests of transactions this one depends on.
eventsobject
Events emitted by the transaction (`digest`, `events`). May be empty if the transaction emitted no events.
checkpointstring
Sequence number of the checkpoint that includes the transaction.
timestampstring
Unix timestamp of the checkpoint that includes the transaction (RFC 3339 in JSON).
balance_changesarray_of_objects
Balance changes per address and coin type (`address`, `coin_type`, `amount`).
objectsobject
Objects referenced as inputs or produced as outputs by the transaction.
transaction_indexstring
Position of the transaction within its checkpoint.
errorobject
google.rpc.Status (`code`, `message`) if the transaction could not be returned.