Requires write_publications access scope.
An access token is required to call this API. Refer to Authorization for more information about how to obtain the token.
Modify and update the specified Publication object.
Arguments
input ● PublicationUpdateInput!non-null
Input fields for updating the publication.
More
id ● ID!non-null
ID of the Publication to be updated.
Return
publication ● Publication
The updated Publication.
More
userErrors ● [PublicationUserError!]!non-null
A list of errors encountered during execution.
More
Status and error codes
For detailed information about common codes, see Status and error codes.
Example
Updates a Publication
mutation PublicationUpdate {
publicationUpdate(
id: "gid://shopline/Publication/57843853"
input: {
publishablesToRemove: ["gid://shopline/Product/16055271775622479314742093"]
publishablesToAdd: ["gid://shopline/Product/16055271775622479314742093"]
}
) {
userErrors {
code
field
message
}
}
}
Response
{
"data": {
"publicationUpdate": {
"userErrors": []
}
}
}
Was this article helpful to you?