Add a support centre article

This method allows you to create a support centre article.

URL

/api/v2/support_centres/add_article

Access

This method can be accessed by account tokens.

Supported Parameters

  • support_centre - ID or local domain of a support centre. (required)
  • topic - ID of a topic. (required)
  • title - the title of the article (required)
  • content - the permalink of the article (required)
  • description - the description of the article
  • position - the position of the article
  • popular -

Returned Data

If the article is created successfully, you will receive a 201 Created status and information about the article will be provided. If a validation error occurs, you will receive a 422 Unprocessable Entity status along with an array of errors (see below)

Example JSON

A successful article

{
    "id": 12154,
    "name": "test",
    "permalink": "test",
    "content": "ere",
    "author": {
        "id": 111,
        "username": "danq",
        "first_name": "Dan",
        "last_name": "Quinney",
        "job_title": "",
        "avatar_url": "https://secure.gravatar.com/avatar/144bf62bac97854d81eb4e1eb02e748d?rating=PG&size={{size}}&d=mm"
    },
    "position": 3,
    "draft": false,
    "popular": false
}

A failed article

{
    "errors": {
        "title": [
            "can't be blank"
        ],
        "content": [
            "can't be blank"
        ],
        "permalink": [
            "can't be blank"
        ]
    }
}

Proudly powered by Katapult. Running on 100% renewable energy.