Requires read_publications access scope.
An access token is required to call this API. Refer to Authorization for more information about how to obtain the token.
Retrieve a list of all Publications.
Arguments
after ● String
Returns elements following the specified cursor. The first argument must also be specified when using this argument.
before ● String
Returns elements preceding the specified cursor. The last argument must also be specified when using this argument.
first ● Int
Returns the first n elements in the list.
last ● Int
Returns the last n elements in the list.
reverse ● Boolean
Whether to reverse the order of the list.
● true: reverse
● false: do not reverse
Default value: false
catalogType ● CatalogType
Filter Publications by catalog type.
More
Return
edges ● [PublicationEdge!]non-null
A list of edges.
More
nodes ● [Publication!]non-null
A list of nodes included in PublicationEdge.
More
pageInfo ● PageInfo!non-null
Information to assist with pagination.
More
Status and error codes
For detailed information about common codes, see Status and error codes.
Example
Publications List
query Publications {
publications(first: 2) {
pageInfo {
hasNextPage
hasPreviousPage
startCursor
endCursor
}
nodes {
supportsFuturePublishing
id
catalog {
id
title
status
... on AppCatalog {
id
title
status
apps(first: 10) {
nodes {
appKey
id
title
embedded
}
}
}
}
}
}
}
Response
{
"data": {
"publications": {
"nodes": [
{
"catalog": {
"apps": {
"nodes": [
{
"id": "gid://shopline/App/65094",
"title": "WhatsApp",
"appKey": "0bb53c89feb2c3b8fc0e4fea6991bdc37344127e",
"embedded": false
}
]
},
"id": "gid://shopline/Catalog/21230252",
"status": "ACTIVE",
"title": "Channel Catalog 21230251"
},
"id": "gid://shopline/Publication/21230251",
"supportsFuturePublishing": false
},
{
"catalog": {
"id": "gid://shopline/Catalog/21230258",
"status": "ACTIVE",
"title": "Channel Catalog 21230257",
"apps": {
"nodes": [
{
"title": "Facebook",
"appKey": "111afe2f9baceb93004af92b1276582619f1db26",
"embedded": false,
"id": "gid://shopline/App/65095"
}
]
}
},
"id": "gid://shopline/Publication/21230257",
"supportsFuturePublishing": false
}
],
"pageInfo": {
"hasPreviousPage": false,
"startCursor": "eyJsYXN0X2lkIjoyMTIzMDI1MSwibGFzdF92YWx1ZSI6IjIxMjMwMjUxIn0=",
"endCursor": "eyJsYXN0X2lkIjoyMTIzMDI1NywibGFzdF92YWx1ZSI6IjIxMjMwMjU3In0=",
"hasNextPage": true
}
}
}
}
Was this article helpful to you?