# Create an article

`POST /articles`

> This is a subset of the full specification, limited to the `POST /articles` operation.
>
> You can find the full specification here: /_bundle/docs/references/@2.12/rest-api/api.intercom.io.yaml

```yaml
openapi: 3.0.1
info:
  title: Intercom API
  version: '2.12'
  description: This is a subset of the full specification, limited to the `POST /articles` operation.
  contact:
    name: Intercom Developer Hub
    url: https://developers.intercom.com
  license:
    name: MIT
    url: https://spdx.org/licenses/MIT
servers:
  - url: https://api.intercom.io
    description: The production API server
  - url: https://api.eu.intercom.io
    description: The european API server
  - url: https://api.au.intercom.io
    description: The australian API server
security:
  - bearerAuth: []
tags:
  - name: Articles
    description: Everything about your Articles
paths:
  /articles:
    post:
      summary: Create an article
      parameters:
        - name: Intercom-Version
          in: header
          schema:
            $ref: '#/components/schemas/intercom_version'
      tags:
        - Articles
      operationId: createArticle
      description: You can create a new article by making a POST request to `https://api.intercom.io/articles`.
      responses:
        '200':
          description: article created
          content:
            application/json:
              examples:
                article created:
                  value:
                    id: '4'
                    type: article
                    workspace_id: this_is_an_id68_that_should_be_at_least_4
                    parent_id: 3
                    parent_type: collection
                    parent_ids: []
                    statistics:
                      type: article_statistics
                      views: 0
                      conversations: 0
                      reactions: 0
                      happy_reaction_percentage: 0
                      neutral_reaction_percentage: 0
                      sad_reaction_percentage: 0
                    title: Thanks for everything
                    description: Description of the Article
                    body: <p class="no-margin">Body of the Article</p>
                    author_id: 991266252
                    state: published
                    created_at: 1736201425
                    updated_at: 1736201425
                    url: http://help-center.test/myapp-68/en/articles/4-thanks-for-everything
              schema:
                $ref: '#/components/schemas/article'
        '400':
          description: Bad Request
          content:
            application/json:
              examples:
                Bad Request:
                  value:
                    type: error.list
                    request_id: f48a23c3-8d82-4bc5-ae80-0b2048b481b9
                    errors:
                      - code: parameter_not_found
                        message: author_id must be in the main body or default locale translated_content object
              schema:
                $ref: '#/components/schemas/error'
        '401':
          description: Unauthorized
          content:
            application/json:
              examples:
                Unauthorized:
                  value:
                    type: error.list
                    request_id: b3b04042-a80c-49fc-bcf2-33807467f3f9
                    errors:
                      - code: unauthorized
                        message: Access Token Invalid
              schema:
                $ref: '#/components/schemas/error'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/create_article_request'
            examples:
              article_created:
                summary: article created
                value:
                  title: Thanks for everything
                  description: Description of the Article
                  body: Body of the Article
                  author_id: 991266252
                  state: published
                  parent_id: 3
                  parent_type: collection
                  translated_content:
                    fr:
                      title: Merci pour tout
                      description: Description de l'article
                      body: Corps de l'article
                      author_id: 991266252
                      state: published
              bad_request:
                summary: Bad Request
                value:
                  title: Thanks for everything
                  description: Description of the Article
                  body: Body of the Article
                  state: published
components:
  schemas:
    article:
      title: Article
      type: object
      x-tags:
        - Articles
      description: The Articles API is a central place to gather all information and take actions on your articles. Articles can live within collections and sections, or alternatively they can stand alone.
      properties:
        statistics:
          nullable: true
          $ref: '#/components/schemas/article_statistics'
      allOf:
        - $ref: '#/components/schemas/article_list_item'
    article_content:
      title: Article Content
      type: object
      description: The Content of an Article.
      nullable: true
      properties:
        type:
          type: string
          description: The type of object - `article_content` .
          enum:
            - null
            - article_content
          example: article_content
          nullable: true
        title:
          type: string
          description: The title of the article.
          example: How to create a new article
        description:
          type: string
          description: The description of the article.
          example: This article will show you how to create a new article.
        body:
          type: string
          description: The body of the article.
          example: This is the body of the article.
        author_id:
          type: integer
          description: The ID of the author of the article.
          example: '5017691'
        state:
          type: string
          description: Whether the article is `published` or is a `draft` .
          enum:
            - published
            - draft
          example: draft
        created_at:
          type: integer
          format: date-time
          description: The time when the article was created (seconds).
          example: 1663597223
        updated_at:
          type: integer
          format: date-time
          description: The time when the article was last updated (seconds).
          example: 1663597260
        url:
          type: string
          description: The URL of the article.
          example: http://intercom.test/help/en/articles/3-default-language
    article_list_item:
      title: Articles
      type: object
      x-tags:
        - Articles
      description: The data returned about your articles when you list them.
      properties:
        type:
          type: string
          description: The type of object - `article`.
          enum:
            - article
          default: article
          example: article
        id:
          type: string
          description: The unique identifier for the article which is given by Intercom.
          example: '6871119'
        workspace_id:
          type: string
          description: The id of the workspace which the article belongs to.
          example: hfi1bx4l
        title:
          type: string
          description: The title of the article. For multilingual articles, this will be the title of the default language's content.
          example: Default language title
        description:
          type: string
          nullable: true
          description: The description of the article. For multilingual articles, this will be the description of the default language's content.
          example: Default language description
        body:
          type: string
          nullable: true
          description: The body of the article in HTML. For multilingual articles, this will be the body of the default language's content.
          example: Default language body in html
        author_id:
          type: integer
          description: The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace.
          example: '5017691'
        state:
          type: string
          description: Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content.
          enum:
            - published
            - draft
          default: draft
          example: published
        created_at:
          type: integer
          format: date-time
          description: The time when the article was created. For multilingual articles, this will be the timestamp of creation of the default language's content in seconds.
          example: 1672928359
        updated_at:
          type: integer
          format: date-time
          description: The time when the article was last updated. For multilingual articles, this will be the timestamp of last update of the default language's content in seconds.
          example: 1672928610
        url:
          type: string
          nullable: true
          description: The URL of the article. For multilingual articles, this will be the URL of the default language's content.
          example: http://intercom.test/help/en/articles/3-default-language
        parent_id:
          type: integer
          nullable: true
          description: The id of the article's parent collection or section. An article without this field stands alone.
          example: '125685'
        parent_ids:
          type: array
          description: The ids of the article's parent collections or sections. An article without this field stands alone.
          items:
            type: integer
          example:
            - 18
            - 19
        parent_type:
          type: string
          nullable: true
          description: The type of parent, which can either be a `collection` or `section`.
          example: collection
        default_locale:
          type: string
          description: The default locale of the help center. This field is only returned for multilingual help centers.
          example: en
        translated_content:
          nullable: true
          $ref: '#/components/schemas/article_translated_content'
    article_statistics:
      title: Article Statistics
      type: object
      description: The statistics of an article.
      nullable: true
      properties:
        type:
          type: string
          description: The type of object - `article_statistics`.
          enum:
            - article_statistics
          default: article_statistics
          example: article_statistics
        views:
          type: integer
          description: The number of total views the article has received.
          example: 10
        conversions:
          type: integer
          description: The number of conversations started from the article.
          example: 0
        reactions:
          type: integer
          description: The number of total reactions the article has received.
          example: 10
        happy_reaction_percentage:
          type: number
          format: float
          description: The percentage of happy reactions the article has received against other types of reaction.
          example: 40
        neutral_reaction_percentage:
          type: number
          format: float
          description: The percentage of neutral reactions the article has received against other types of reaction.
          example: 40
        sad_reaction_percentage:
          type: number
          format: float
          description: The percentage of sad reactions the article has received against other types of reaction.
          example: 20
    article_translated_content:
      title: Article Translated Content
      type: object
      description: The Translated Content of an Article. The keys are the locale codes and the values are the translated content of the article.
      nullable: true
      properties:
        type:
          type: string
          description: The type of object - article_translated_content.
          enum:
            - null
            - article_translated_content
          example: article_translated_content
          nullable: true
        ar:
          description: The content of the article in Arabic
          $ref: '#/components/schemas/article_content'
        bg:
          description: The content of the article in Bulgarian
          $ref: '#/components/schemas/article_content'
        bs:
          description: The content of the article in Bosnian
          $ref: '#/components/schemas/article_content'
        ca:
          description: The content of the article in Catalan
          $ref: '#/components/schemas/article_content'
        cs:
          description: The content of the article in Czech
          $ref: '#/components/schemas/article_content'
        da:
          description: The content of the article in Danish
          $ref: '#/components/schemas/article_content'
        de:
          description: The content of the article in German
          $ref: '#/components/schemas/article_content'
        el:
          description: The content of the article in Greek
          $ref: '#/components/schemas/article_content'
        en:
          description: The content of the article in English
          $ref: '#/components/schemas/article_content'
        es:
          description: The content of the article in Spanish
          $ref: '#/components/schemas/article_content'
        et:
          description: The content of the article in Estonian
          $ref: '#/components/schemas/article_content'
        fi:
          description: The content of the article in Finnish
          $ref: '#/components/schemas/article_content'
        fr:
          description: The content of the article in French
          $ref: '#/components/schemas/article_content'
        he:
          description: The content of the article in Hebrew
          $ref: '#/components/schemas/article_content'
        hr:
          description: The content of the article in Croatian
          $ref: '#/components/schemas/article_content'
        hu:
          description: The content of the article in Hungarian
          $ref: '#/components/schemas/article_content'
        id:
          description: The content of the article in Indonesian
          $ref: '#/components/schemas/article_content'
        it:
          description: The content of the article in Italian
          $ref: '#/components/schemas/article_content'
        ja:
          description: The content of the article in Japanese
          $ref: '#/components/schemas/article_content'
        ko:
          description: The content of the article in Korean
          $ref: '#/components/schemas/article_content'
        lt:
          description: The content of the article in Lithuanian
          $ref: '#/components/schemas/article_content'
        lv:
          description: The content of the article in Latvian
          $ref: '#/components/schemas/article_content'
        mn:
          description: The content of the article in Mongolian
          $ref: '#/components/schemas/article_content'
        nb:
          description: The content of the article in Norwegian
          $ref: '#/components/schemas/article_content'
        nl:
          description: The content of the article in Dutch
          $ref: '#/components/schemas/article_content'
        pl:
          description: The content of the article in Polish
          $ref: '#/components/schemas/article_content'
        pt:
          description: The content of the article in Portuguese (Portugal)
          $ref: '#/components/schemas/article_content'
        ro:
          description: The content of the article in Romanian
          $ref: '#/components/schemas/article_content'
        ru:
          description: The content of the article in Russian
          $ref: '#/components/schemas/article_content'
        sl:
          description: The content of the article in Slovenian
          $ref: '#/components/schemas/article_content'
        sr:
          description: The content of the article in Serbian
          $ref: '#/components/schemas/article_content'
        sv:
          description: The content of the article in Swedish
          $ref: '#/components/schemas/article_content'
        tr:
          description: The content of the article in Turkish
          $ref: '#/components/schemas/article_content'
        vi:
          description: The content of the article in Vietnamese
          $ref: '#/components/schemas/article_content'
        pt-BR:
          description: The content of the article in Portuguese (Brazil)
          $ref: '#/components/schemas/article_content'
        zh-CN:
          description: The content of the article in Chinese (China)
          $ref: '#/components/schemas/article_content'
        zh-TW:
          description: The content of the article in Chinese (Taiwan)
          $ref: '#/components/schemas/article_content'
    create_article_request:
      description: You can create an Article
      type: object
      title: Create Article Request Payload
      nullable: true
      properties:
        title:
          type: string
          description: The title of the article.For multilingual articles, this will be the title of the default language's content.
          example: Thanks for everything
        description:
          type: string
          description: The description of the article. For multilingual articles, this will be the description of the default language's content.
          example: Description of the Article
        body:
          type: string
          description: The content of the article. For multilingual articles, this will be the body of the default language's content.
          example: <p>This is the body in html</p>
        author_id:
          type: integer
          description: The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace.
          example: 1295
        state:
          type: string
          description: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content.
          enum:
            - published
            - draft
          example: draft
        parent_id:
          type: integer
          description: The id of the article's parent collection or section. An article without this field stands alone.
          example: 18
        parent_type:
          type: string
          description: The type of parent, which can either be a `collection` or `section`.
          example: collection
        translated_content:
          $ref: '#/components/schemas/article_translated_content'
      required:
        - title
        - author_id
    error:
      type: object
      title: Error
      description: The API will return an Error List for a failed request, which will contain one or more Error objects.
      properties:
        type:
          type: string
          description: The type is error.list
          example: error.list
        request_id:
          type: string
          nullable: true
          format: uuid
          description: ''
          example: f93ecfa8-d08a-4325-8694-89aeb89c8f85
        errors:
          type: array
          description: An array of one or more error objects
          items:
            properties:
              code:
                type: string
                description: A string indicating the kind of error, used to further qualify the HTTP response code
                example: unauthorized
              message:
                type: string
                nullable: true
                description: Optional. Human readable description of the error.
                example: Access Token Invalid
              field:
                type: string
                nullable: true
                description: Optional. Used to identify a particular field or query parameter that was in error.
                example: email
            required:
              - code
      required:
        - type
        - errors
    intercom_version:
      description: Intercom API version.</br>By default, it's equal to the version set in the app package.
      type: string
      example: '2.12'
      default: '2.12'
      enum:
        - '1.0'
        - '1.1'
        - '1.2'
        - '1.3'
        - '1.4'
        - '2.0'
        - '2.1'
        - '2.2'
        - '2.3'
        - '2.4'
        - '2.5'
        - '2.6'
        - '2.7'
        - '2.8'
        - '2.9'
        - '2.10'
        - '2.11'
        - '2.12'
        - Preview
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
```
