# Article - admin-graphql - OBJECT Version: unstable ## Description An article in the blogging system. ### Access Scopes `read_content` access scope or `read_online_store_pages` access scope. ## Fields * [author](/docs/api/admin-graphql/unstable/objects/ArticleAuthor): ArticleAuthor - The name of the author of the article. * [blog](/docs/api/admin-graphql/unstable/objects/Blog): Blog! - The blog containing the article. * [body](/docs/api/admin-graphql/unstable/scalars/HTML): HTML! - The text of the article's body, complete with HTML markup. * [commentsCount](/docs/api/admin-graphql/unstable/objects/Count): Count - Count of comments. * [createdAt](/docs/api/admin-graphql/unstable/scalars/DateTime): DateTime! - The date and time (ISO 8601 format) when the article was created. * [defaultCursor](/docs/api/admin-graphql/unstable/scalars/String): String! - A default [cursor](https://shopify.dev/api/usage/pagination-graphql) that returns the single next record, sorted ascending by ID. * [handle](/docs/api/admin-graphql/unstable/scalars/String): String! - A unique, human-friendly string for the article that's automatically generated from the article's title. The handle is used in the article's URL. * [id](/docs/api/admin-graphql/unstable/scalars/ID): ID! - A globally-unique ID. * [image](/docs/api/admin-graphql/unstable/objects/Image): Image - The image associated with the article. * [isPublished](/docs/api/admin-graphql/unstable/scalars/Boolean): Boolean! - Whether or not the article is visible. * [metafield](/docs/api/admin-graphql/unstable/objects/Metafield): Metafield - A [custom field](https://shopify.dev/docs/apps/build/custom-data), including its `namespace` and `key`, that's associated with a Shopify resource for the purposes of adding and storing additional information. * [metafieldsByIdentifiers](/docs/api/admin-graphql/unstable/objects/Metafield): Metafield! - The metafields associated with the resource matching the supplied list of namespaces and keys. * [publishedAt](/docs/api/admin-graphql/unstable/scalars/DateTime): DateTime - The date and time (ISO 8601 format) when the article became or will become visible. Returns null when the article isn't visible. * [summary](/docs/api/admin-graphql/unstable/scalars/HTML): HTML - A summary of the article, which can include HTML markup. The summary is used by the online store theme to display the article on other pages, such as the home page or the main blog page. * [tags](/docs/api/admin-graphql/unstable/scalars/String): String! - A comma-separated list of tags. Tags are additional short descriptors formatted as a string of comma-separated values. * [templateSuffix](/docs/api/admin-graphql/unstable/scalars/String): String - The name of the template an article is using if it's using an alternate template. If an article is using the default `article.liquid` template, then the value returned is `null`. * [title](/docs/api/admin-graphql/unstable/scalars/String): String! - The title of the article. * [translations](/docs/api/admin-graphql/unstable/objects/Translation): Translation! - The published translations associated with the resource. * [updatedAt](/docs/api/admin-graphql/unstable/scalars/DateTime): DateTime - The date and time (ISO 8601 format) when the article was last updated. ## Connections * [comments](/docs/api/admin-graphql/unstable/connections/CommentConnection): CommentConnection! * [events](/docs/api/admin-graphql/unstable/connections/EventConnection): EventConnection! * [metafieldDefinitions](/docs/api/admin-graphql/unstable/connections/MetafieldDefinitionConnection): MetafieldDefinitionConnection! * [metafields](/docs/api/admin-graphql/unstable/connections/MetafieldConnection): MetafieldConnection! ## Related queries * [article](/docs/api/admin-graphql/unstable/queries/article) Returns an Article resource by ID. * [articles](/docs/api/admin-graphql/unstable/queries/articles) List of the shop's articles. ## Related mutations * [articleCreate](/docs/api/admin-graphql/unstable/mutations/articleCreate) Creates an article. * [articleUpdate](/docs/api/admin-graphql/unstable/mutations/articleUpdate) Updates an article. ## Related Unions * [MetafieldReferencer](/docs/api/admin-graphql/unstable/unions/MetafieldReferencer) Types of resources that may use metafields to reference other resources. ## Examples ### Receive a single Article Curl example: "curl -X POST \\\nhttps://your-development-store.myshopify.com/admin/api/unstable/graphql.json \\\n-H 'Content-Type: application/json' \\\n-H 'X-Shopify-Access-Token: {access_token}' \\\n-d '{\n\"query\": \"query ArticleShow($id: ID!) { article(id: $id) { id author { name } createdAt handle } }\",\n \"variables\": {\n \"id\": \"gid://shopify/Article/959752435\"\n }\n}'\n" Node example: "const client = new shopify.clients.Graphql({session});\nconst data = await client.query({\n data: {\n \"query\": `query ArticleShow($id: ID!) {\n article(id: $id) {\n id\n author {\n name\n }\n createdAt\n handle\n }\n }`,\n \"variables\": {\n \"id\": \"gid://shopify/Article/959752435\"\n },\n },\n});\n" Ruby example: "session = ShopifyAPI::Auth::Session.new(\n shop: \"your-development-store.myshopify.com\",\n access_token: access_token\n)\nclient = ShopifyAPI::Clients::Graphql::Admin.new(\n session: session\n)\n\nquery = <<~QUERY\n query ArticleShow($id: ID!) {\n article(id: $id) {\n id\n author {\n name\n }\n createdAt\n handle\n }\n }\nQUERY\n\nvariables = {\n \"id\": \"gid://shopify/Article/959752435\"\n}\n\nresponse = client.query(query: query, variables: variables)\n" Remix example: "const { admin } = await authenticate.admin(request);\n\nconst response = await admin.graphql(\n `#graphql\n query ArticleShow($id: ID!) {\n article(id: $id) {\n id\n author {\n name\n }\n createdAt\n handle\n }\n }`,\n {\n variables: {\n \"id\": \"gid://shopify/Article/959752435\"\n },\n },\n);\n\nconst data = await response.json();\n" Graphql query: "query ArticleShow($id: ID!) {\n article(id: $id) {\n id\n author {\n name\n }\n createdAt\n handle\n }\n}" #### Graphql Input { "id": "gid://shopify/Article/959752435" } #### Graphql Response { "data": { "article": { "id": "gid://shopify/Article/959752435", "author": { "name": "dennis" }, "createdAt": "2012-01-01T00:00:00Z", "handle": "you-should-buy-this" } } }