Query for assets and related information
Get complete information on Asset
This examples incudes details query around all the details avaiable when querying for an asset, given the name of the asset. The example result below illustrates an asset which has an open primary sale, buying intent, and a selling intent.
{
assets (filter: {key:"name", operator:EQ, value:"Asset A"}) {
nodes{
id
organizationId
name
type
config
issuerId
regulationVerifiers {
id
}
denomination {
...on FiatAsset {
code
}
}
metadata {
acl
}
issuedTokens {
nodes {
userId
assetId
quantity
transactionsDetails {
transactionId
index
quantity
}
}
}
certificates {
nodes {
id
profileId
type
providerId
issuedAt
expiry
data
documents {
nodes {
id
uri
name
mimeType
}
}
}
}
intents {
nodes {
intent {
__typename
... on PrimarySale {
issuerId
}
... on BuyingIntent {
buyer
}
... on SellingIntent {
seller
}
}
}
}
}
}
}
{
"data": {
"assets": {
"nodes": [
{
"id": "bank-us:102:2aa75905-1ca6-4174-aa0a-0319b46c5ac2",
"organizationId": "bank-us",
"name": "Asset A",
"type": "Fund",
"config": "{\"signatureTemplate\":{\"hashFunction\":\"sha3-256\"}}",
"issuerId": "bank-us:101:49744cb3-ef17-4fd4-aec8-5fce737cbfba",
"regulationVerifiers": [
{
"id": "store-id:bank-us:101:09a6112e-c945-4558-a42a-1ddad5f2e476RegD"
},
{
"id": "store-id:bank-us:101:09a6112e-c945-4558-a42a-1ddad5f2e476RegX"
}
],
"denomination": {
"code": "USD"
},
"metadata": {
"acl": [
"bank-uk"
]
},
"issuedTokens": {
"nodes": []
},
"certificates": {
"nodes": [
{
"id": "bank-us:102:2aa75905-1ca6-4174-aa0a-0319b46c5ac2_6d8b2888-4fc7-493a-b68e-51d71289ccf7",
"profileId": "bank-us:102:2aa75905-1ca6-4174-aa0a-0319b46c5ac2",
"type": "KYA",
"providerId": "bank-us",
"issuedAt": 1667998971,
"expiry": 4102444800,
"data": "{\"description\":\"Asset A full description\",\"name\":\"Asset A\",\"info\":[{\"type\":\"text\",\"name\":\"Issuer\",\"value\":\"The Bank\"},{\"type\":\"text\",\"name\":\"Headquarters\",\"value\":\"New York City\"},{\"type\":\"text\",\"name\":\"Industry\",\"value\":\"Financial Industry\"},{\"type\":\"text\",\"name\":\"Services\",\"value\":\"Banking\"},{\"type\":\"link\",\"name\":\"Website\",\"value\":\"www.website.com\"}]}",
"documents": {
"nodes": [
{
"id": "6e2b32f5-2950-4c40-bc55-a31bd601bcae",
"uri": "bank-us:102:2aa75905-1ca6-4174-aa0a-0319b46c5ac2_6d8b2888-4fc7-493a-b68e-51d71289ccf7_6e2b32f5-2950-4c40-bc55-a31bd601bcae",
"name": "icon-1667998972453.png",
"mimeType": "image/png"
},
{
"id": "856d2b98-c095-40e7-bc54-543591a1dd7d",
"uri": "bank-us:102:2aa75905-1ca6-4174-aa0a-0319b46c5ac2_6d8b2888-4fc7-493a-b68e-51d71289ccf7_856d2b98-c095-40e7-bc54-543591a1dd7d",
"name": "logo-1667998972453.jpg",
"mimeType": "image/jpeg"
}
]
}
}
]
},
"intents": {
"nodes": [
{
"intent": {
"__typename": "PrimarySale",
"issuerId": "bank-us:101:49744cb3-ef17-4fd4-aec8-5fce737cbfba"
}
},
{
"intent": {
"__typename": "BuyingIntent",
"buyer": "bank-us:101:55408c4c-2b20-46c1-8fb6-029af7dbc823"
}
}
{
"intent": {
"__typename": "SellingIntent",
"buyer": "bank-us:101:55408c4c-2b20-46c1-8fb6-029af7dbc824"
}
}
]
}
}
]
}
}
}
Query for Open Intents
Retrieve what are the open intents for the given assets, including Primary Sale, Buying intents, and Sale Intents that are currently active.
{
assets (filter: { key: "id", operator: EQ, value: "fi-a:102:fc2426e5-ab81-4943-b818-7fe740adc924" }) {
nodes{
name
id
type
intents {
nodes {
intent {
__typename
... on PrimarySale {
issuerId
}
... on BuyingIntent {
buyer
}
... on SellingIntent {
seller
}
}
}
}
}
}
}
"data": {
"assets": {
"nodes": [
{
"name": "Lexington Mews",
"id": "bank-us:102:9e8fa9b6-6a43-45b1-9259-59d2689e3563",
"type": "Building",
"intents": {
"nodes": [
{
"intent": {
"__typename": "PrimarySale",
"issuerId": "bank-us:101:49744cb3-ef17-4fd4-aec8-5fce737cbfba"
}
},
{
"intent": {
"__typename": "BuyingIntent",
"buyer": "bank-us:101:55408c4c-2b20-46c1-8fb6-029af7dbc823"
}
}
{
"intent": {
"__typename": "SellingIntent",
"buyer": "bank-us:101:55408c4c-2b20-46c1-8fb6-029af7dbc824"
}
}
]
}
},
]
}
}
}