> ## Documentation Index
> Fetch the complete documentation index at: https://developers.hubspot.jp/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# List blog posts

> Get the posts from your HubSpot blogs. Supports paging and filtering. This method would be useful for an integration that examined blog posts and used an external service to suggest edits.

export const ScopesList = ({scopes = [], description = "この API には、次のいずれかのスコープが必要です。"}) => {
  if (!scopes || scopes.length === 0) {
    return null;
  }
  const sortedScopes = scopes.sort((a, b) => a.localeCompare(b));
  return <div>
      <div className="text-sm mb-2">{description}</div>
      <div>
        {sortedScopes.map((scope, index) => <div key={index}>
            <code>
              <span className="text-xs">{scope}</span>
            </code>
          </div>)}
      </div>
    </div>;
};

<Accordion title="Scope requirements">
  <ScopesList scopes={['content']} />
</Accordion>


## OpenAPI

````yaml specs/legacy/v2/blog-posts-v2.json GET /content/api/v2/blog-posts
openapi: 3.0.1
info:
  title: Blog Posts API - V2
  version: v2
  description: >-
    Use the blog posts API to create, manage, and publish blog posts on your
    website.
  x-hubspot-api-use-case: Retrieve all blog posts created this year as a part of a content audit.
servers:
  - url: https://api.hubapi.com
security: []
tags:
  - name: Blog Posts
paths:
  /content/api/v2/blog-posts:
    get:
      tags:
        - Blog Posts
      summary: List blog posts
      description: >-
        Get the posts from your HubSpot blogs. Supports paging and filtering.
        This method would be useful for an integration that examined blog posts
        and used an external service to suggest edits.
      operationId: get-content-api-v2-blog-posts
      parameters:
        - name: limit
          in: query
          required: false
          description: The number of items to return. Defaults to 20. Cannot exceed 300.
          schema:
            type: integer
            default: 20
            maximum: 300
        - name: offset
          in: query
          required: false
          description: The offset set to start returning rows from. Defaults to 0.
          schema:
            type: integer
            default: 0
        - name: archived_at
          in: query
          required: false
          description: >-
            Returns the posts that match a particular deleted time value.
            Supports exact, gt, gte, lt, lte lookups.
          schema:
            type: integer
            format: int64
        - name: archivedInDashboard
          in: query
          required: false
          description: >-
            Returns the posts that match the boolean lookup (e.g. archived=false
            returns all posts currently not archived).
          schema:
            type: boolean
        - name: blog_author_id
          in: query
          required: false
          description: Returns the posts that match a particular blog author ID value.
          schema:
            type: integer
            format: int64
        - name: campaign
          in: query
          required: false
          description: >-
            Returns the posts that match the campaign guid. The campaign guid
            can be found in the campaign dashboard URL.
          schema:
            type: string
        - name: content_group_id
          in: query
          required: false
          description: >-
            Returns the posts that match the blog guid. The blog guid can be
            found using the Blog API.
          schema:
            type: integer
            format: int64
        - name: created
          in: query
          required: false
          description: >-
            Returns the posts that match a particular created time value.
            Supports exact, range, gt, gte, lt, lte lookups.
          schema:
            type: integer
            format: int64
        - name: name
          in: query
          required: false
          description: >-
            Returns the posts that match the name value. Supports exact,
            icontains, ne lookups.
          schema:
            type: string
        - name: slug
          in: query
          required: false
          description: Returns the posts that match a particular slug value.
          schema:
            type: string
        - name: updated
          in: query
          required: false
          description: >-
            Returns the posts that match a particular updated time. Supports
            exact, range, gt, gte, lt, lte lookups.
          schema:
            type: integer
            format: int64
        - name: state
          in: query
          required: false
          description: Filter by post state.
          schema:
            type: string
            enum:
              - DRAFT
              - PUBLISHED
              - SCHEDULED
        - name: order_by
          in: query
          required: false
          description: >-
            Return the posts ordered by a particular field value. Blog posts can
            currently only be sorted by publish_date. Use a negative value to
            sort in descending order (e.g. order_by=-publish_date).
          schema:
            type: string
      responses:
        '200':
          description: A list of blog posts.
          content:
            application/json:
              schema:
                type: object
                properties:
                  objects:
                    type: array
                    items:
                      $ref: '#/components/schemas/BlogPost'
                  total:
                    type: integer
                  limit:
                    type: integer
                  offset:
                    type: integer
      security:
        - hapikey: []
        - oauth2:
            - content
components:
  schemas:
    BlogPost:
      type: object
      properties:
        id:
          type: integer
          format: int64
        portal_id:
          type: integer
          format: int64
        name:
          type: string
          description: The internal name of the blog post
        html_title:
          type: string
        slug:
          type: string
          description: The path of the URL on which the post will live
        content_group_id:
          type: integer
          format: int64
          description: The id of the blog that this post belongs to
        blog_author_id:
          type: integer
          format: int64
          description: The integer id of the blog author
        post_body:
          type: string
          description: The HTML of the main post body
        post_summary:
          type: string
          description: >-
            The summary of the blog post that will appear on the main listing
            page
        meta_description:
          type: string
          description: A description that goes in meta tag on the page
        featured_image:
          type: string
          description: The URL of the featured image
        head_html:
          type: string
          description: >-
            Custom HTML for embed codes, javascript, etc. that goes in the head
            tag
        footer_html:
          type: string
          description: >-
            Custom HTML for embed codes, javascript that should be placed before
            the body tag
        campaign:
          type: string
          description: The guid of the marketing campaign this post is associated with
        campaign_name:
          type: string
          description: The name of the marketing campaign this post is associated with
        state:
          type: string
          enum:
            - DRAFT
            - PUBLISHED
            - SCHEDULED
          description: The current state of the blog post
        publish_date:
          type: integer
          format: int64
          description: >-
            The date the blog post is to be published at in milliseconds since
            the unix epoch
        publish_immediately:
          type: boolean
          description: >-
            Set this to true if you want to be published immediately when the
            schedule publish endpoint is called
        created:
          type: integer
          format: int64
          description: When the post was first created, in milliseconds since the epoch
        updated:
          type: integer
          format: int64
          description: When the post was last updated, in milliseconds since the epoch
        archived_at:
          type: integer
          format: int64
          description: When the post was deleted, in milliseconds since the epoch
        is_draft:
          type: boolean
          description: True if the post is still a draft, invisible to the public
        url:
          type: string
          description: The full URL with domain and scheme to the blog post
        published_url:
          type: string
          description: The published URL of the blog post
        topic_ids:
          type: array
          items:
            type: integer
            format: int64
          description: A json list of topic ids from the topics API
        keywords:
          type: array
          items:
            type: object
          description: A JSON list of keywords and their GUIDs
        use_featured_image:
          type: boolean
          description: Controls whether or not the blog post should use the featured image
        widgets:
          type: object
          description: >-
            A data structure containing the data for all the modules for this
            post

````