articles

Update an article

Changed on

Updates an existing article. Only provided fields are modified.

Rate limit: 120 requests per minute

patch/knowledge-bases/{id}/articles/{article_id}

Request

  • Base URL
    https://api.usepylon.com
  • URL
    https://api.usepylon.com/knowledge-bases/{id}/articles/{article_id}
  • Auth
    HTTP bearer

Path parameters

idstring required

The KnowledgeBaseID of the article to update.

article_idstring required

The ID of the article to update.

Request body

author_user_idstring

The ID of the user in this organization attributed as the author of the article. Does not change version authorship.

body_htmlstring

The HTML body of the article. Saved as a new draft; the published article changes only if publish_updated_body_html or is_published is true.

body_markdownstring

The body of the article in markdown, instead of body_html. Saved and published the same way.

collection_idstring

The ID of the collection containing the article.

is_publishedboolean

Whether the article should be published or unpublished.

is_unlistedboolean

Whether the article is accessible only via a direct link.

languagestring

The language code of the translation to update. If not provided, the default language (original article) will be updated.

positioninteger

The zero-based position among the parent's articles and subcollections. Omit to keep the current position, or append when moving to another collection. Positions beyond the end append the article. When collection_id is provided, applies within the destination collection.

publish_updated_body_htmlboolean

Whether to publish the updated body_html. Defaults to false, which leaves the change as a draft.

tag_idsstring[]

IDs of article tags to assign. If provided, replaces all tags currently assigned to the article.

titlestring

The title of the article. For the default language, applies to the live article immediately.

Example request

{
  "visibility_config": {
    "customer_visibility_condition": {
      "subfilters": [
        {
          "field": "state",
          "operator": "equals",
          "value": "new"
        }
      ]
    }
  }
}

Response

request_idstring required

The request ID for tracking.

Example response

{
  "data": {
    "tags": [
      {
        "object_type": "issue"
      }
    ],
    "visibility_config": {
      "customer_visibility_condition": {
        "subfilters": [
          {
            "field": "state",
            "operator": "equals",
            "value": "new"
          }
        ]
      }
    }
  }
}

Changes

    • warning

      added the new not enum value to the /// response property for the response status

    • warning

      added the new time_is_in_last enum value to the /// response property for the response status

    • warning

      added the new time_is_in_next enum value to the /// response property for the response status

    • warning

      added the new time_is_not_in_last enum value to the /// response property for the response status

    • warning

      added the new time_is_not_in_next enum value to the /// response property for the response status

    • info

      added the new not enum value to the request property //

    • info

      added the new time_is_in_last enum value to the request property //

    • info

      added the new time_is_in_next enum value to the request property //

    • info

      added the new time_is_not_in_last enum value to the request property //

    • info

      added the new time_is_not_in_next enum value to the request property //

    • info

      added the new optional request property /

    • info

      added the optional property // to the response with the status