Article
Represents an article object with content, author, and comment information. Articles are typically published on blogs and can include SEO metadata, author information, and reader comments.
Type Definition
type Article {
seoDescription: String
seoTitle: String
seoKeywords: String
handle: String
headerImage: String
author: Author
id: Int
title: String
content: String
summary: String
comments: [Comment]
commentsCount: Int
blog: Blog
isPublished: Boolean
commentsAreEnabled: Boolean
commentsRequireAccount: Boolean
commentsRequireApproval: Boolean
accountOwner: Boolean
url: String
createdAt: String
updatedAt: String
metafields: [Metafield]!
metafield: Metafield
}Fields
Relationships
The Article type is a core content object that represents published or draft articles within a blog. It maintains relationships with several key types:
- Author: Each article is written by an author, whose information is retrieved through the
authorfield. - Blog: Articles belong to a specific blog, accessible via the
blogfield. - Comments: Articles can have associated reader comments through the
commentsfield, with the count available viacommentsCount. - Metafields: Articles can store custom metadata through the
metafieldsfield for extensibility.
Articles are also referenced by queries and can appear as nodes in connection edges throughout the API.
Example
{
article(id: 12345) {
id
title
handle
content
summary
seoTitle
seoDescription
seoKeywords
headerImage
url
isPublished
createdAt
updatedAt
commentsCount
commentsAreEnabled
author {
name
email
}
blog {
title
handle
}
comments {
content
author
}
metafields {
namespace
key
value
}
}
}Implements
This type does not implement any interfaces.