Requires Any of write_content, write_online_store_pages access scopes.

Creates a blog.


The properties of the new blog.


Was this section helpful?

The blog that was created.

The list of errors that occurred from executing the mutation.


Was this section helpful?
Hide code
Mutation reference
Copy
mutation blogCreate($blog: BlogCreateInput!) {
  blogCreate(blog: $blog) {
    blog {
      # Blog fields
    }
    userErrors {
      field
      message
    }
  }
}
Hide code
Input
Copy
{
  "blog": {
    "commentPolicy": "AUTO_PUBLISHED",
    "handle": "<your-handle>",
    "metafields": [
      {
        "description": "<your-description>",
        "id": "gid://shopify/<objectName>/10079785100",
        "key": "<your-key>",
        "namespace": "<your-namespace>",
        "type": "<your-type>",
        "value": "<your-value>"
      }
    ],
    "templateSuffix": "<your-templateSuffix>",
    "title": "<your-title>"
  }
}
input BlogCreateInput {
  commentPolicy: CommentPolicy
  handle: String
  metafields: [MetafieldInput!]
  templateSuffix: String
  title: String!
}

input MetafieldInput {
  description: String
  id: ID
  key: String
  namespace: String
  type: String
  value: String
}