To get the content of a reference set in your Connect subscription, query the referenceSetRecords
object.
query {
referenceSetRecords(dataSetId: "123456789-0000000000000000000"){
totalCount
nodes {
key
attributes {
name
value
}
}
}
}
{
"data": {
"referenceSetRecords": {
"totalCount": 3,
"nodes": [
{
"key": "OYXF-761",
"attributes": [
{
"name": "Email",
"value": "[email protected]"
},
{
"name": "Age",
"value": "14-17"
},
{
"name": "Nearest store",
"value": "Bremen"
},
{
"name": "Client",
"value": true
},
{
"name": "ID",
"value": "OYXF-761"
},
{
"name": "Joined on",
"value": "2024-10-10 13:59:31.000"
}
]
},
{
"key": "OYXF-87",
"attributes": [
{
"name": "Email",
"value": "[email protected]"
},
{
"name": "Age",
"value": "18-24"
},
{
"name": "Nearest store",
"value": "Bremen"
},
{
"name": "Client",
"value": true
},
{
"name": "ID",
"value": "OYXF-87"
},
{
"name": "Joined on",
"value": "2022-10-10 13:59:31.000"
}
]
},
{
"key": "OYXF-88",
"attributes": [
{
"name": "Email",
"value": "[email protected]"
},
{
"name": "Age",
"value": "18-24"
},
{
"name": "Nearest store",
"value": "Karlskrona"
},
{
"name": "Client",
"value": true
},
{
"name": "ID",
"value": "OYXF-88"
},
{
"name": "Joined on",
"value": "2024-11-10 13:59:31.000"
}
]
}
]
}
}
}
Arguments
Arguments supported by the referenceSetRecords
query
Argument | Nested field | Values | Required? | Definition |
---|---|---|---|---|
dataSetId | ID | Required | The ID of the reference set | |
filter | field | Optional | ||
contains | Optional | "Contains the specified text" | ||
eq | Optional | "Equals." | ||
in | Optional | "Is one of the following." | ||
orderBy | field | String | Optional | |
sort | Either of the following values: - ASC - DESC | Optional | The sort order to use for reference sets in the response |
Fields
Fields returned by the referenceSetRecords
query
Field | Nested field | Values | Required? | Description |
---|---|---|---|---|
nodes | key | Object | Required | The value of the key attribute for each entry in the reference set |
attributes | Array | Required | See nested fields | |
totalCount | Integer | Optional | The total number of entries in the reference set |
Fields nested into the attributes
field
Field | Values | Required? | Description |
---|---|---|---|
name | String | Required | The name of an attribute defined in the reference set |
value | Depends on the attribute type | Optional | The value assigned to the attribute |
type | One of the following values: - TEXT - NUMBER - BOOLEAN - DATE | Optional | The data format of the attribute |