Skip to content

Instantly share code, notes, and snippets.

@luizstacio
Last active October 20, 2023 00:01
Show Gist options
  • Save luizstacio/a5e51705a8965a3ece87cea90981fa15 to your computer and use it in GitHub Desktop.
Save luizstacio/a5e51705a8965a3ece87cea90981fa15 to your computer and use it in GitHub Desktop.
Query example
query {
transaction(
id: "0x3470abd2b54137fd6ac4a9656e8cd8e91c6baf361250b30e05a2b546196237c4"
) {
id
inputAssetIds
inputContracts {
id
bytecode
}
gasPrice
gasLimit
maturity
txPointer
isScript
isCreate
isMint
witnesses
receiptsRoot
script
scriptData
bytecodeWitnessIndex
bytecodeLength
salt
storageSlots
rawPayload
receipts {
contract {
id
}
pc
is
to {
id
}
toAddress
amount
assetId
gas
param1
param2
val
ptr
digest
reason
ra
rb
rc
rd
len
receiptType
result
gasUsed
data
sender
recipient
nonce
contractId
subId
}
inputs {
type: __typename
... on InputCoin {
assetId
predicate
predicateData
amount
owner
witnessIndex
}
... on InputMessage {
amount
sender
recipient
data
predicate
predicateData
}
... on InputContract {
utxoId
txPointer
contract {
id
}
}
}
outputs {
type: __typename
... on CoinOutput {
to
amount
assetId
}
... on ChangeOutput {
to
amount
assetId
}
... on ContractOutput {
inputIndex
balanceRoot
stateRoot
}
... on VariableOutput {
assetId
amount
to
}
... on ContractCreated {
stateRoot
contract {
id
salt
bytecode
}
}
}
status {
type: __typename
... on SuccessStatus {
time
block {
id
header {
id
height
applicationHash
messageReceiptRoot
messageReceiptCount
time
}
}
programState {
data
returnType
}
}
... on SubmittedStatus {
time
}
... on SqueezedOutStatus {
reason
}
... on FailureStatus {
reason
time
programState {
data
returnType
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment