GetAccounts
Account Queries
There are two primary queries available for retrieving Account
data:
GetAccounts
: Retrieves a collection of atoms based on specified filters and parametersGetAccount
: Fetches a single atom by its unique identifier (address
)
We have more supporting Account
queries in our GraphQL package.
GetAccounts
query GetAccounts {
accounts {
# AccountMetadata fields
label
image
id
atom_id
type
# AccountClaims fields
claims(order_by: { shares: desc }) {
triple {
id
}
shares
counter_shares
}
# AccountPositions fields
positions(order_by: { shares: desc }) {
id
shares
vault {
id
total_shares
current_share_price
atom {
id
label
}
triple {
id
}
}
}
atom {
vault_id
wallet_id
vault {
position_count
total_shares
positions_aggregate {
aggregate {
count
sum {
shares
}
}
}
positions {
id
account {
label
id
}
shares
}
}
}
}
}
Interact with this query in Apollo Sandbox
GetAccount
query GetAccount($address: String!) {
account(id: $address) {
label
image
id
atom_id
type
atom {
id
data
image
label
emoji
type
wallet_id
creator {
id
label
image
}
}
claims(order_by: { shares: desc }) {
triple {
id
}
shares
counter_shares
}
}
}
# Variables
{
"address": "0x88d0af73508452c1a453356b3fac26525aec23a2", // change to the address you want to query
}