ChatWoot icon

ChatWoot

Interact with ChatWoot API

Actions100

Overview

This n8n node operation allows you to add a new article to a Help Center within a ChatWoot account. It is designed for scenarios where you need to programmatically create or manage knowledge base articles, such as automating onboarding documentation, updating FAQs, or integrating with other content management workflows.

Practical examples:

  • Automatically publish product update articles when a new release is deployed.
  • Sync external documentation sources into your ChatWoot Help Center.
  • Batch-create articles based on user feedback or support ticket analysis.

Properties

Below are the supported input properties for this operation:

Display Name Type Description
Account Id Number The numeric ID of the account. Required.
Portal Id Number The Portal ID parameter. Required.
Content String The text content of the article.
Meta JSON Metadata for search, including tags, title, and description. Example:
{"tags":["article_name"],"title":"article title","description":"article description"}
Position Number Article position in category.
Status Number Status of the article (e.g., published, draft).
Title String The title of the article.
Slug String URL-friendly identifier for the article.
Views Number Number of views for the article.
Author Id Number ID of the author creating the article.
Category Id Number ID of the category to which the article belongs.
Folder Id Number ID of the folder for organizing the article.
Associated Article Id Number To associate similar articles, e.g., provide reference links.

Output

The output will be a json object representing the newly created article. While the exact structure depends on the ChatWoot API response, it typically includes fields such as:

{
  "id": 123,
  "account_id": 1,
  "portal_id": 2,
  "category_id": 3,
  "folder_id": 4,
  "author_id": 5,
  "title": "Article Title",
  "slug": "article-title",
  "content": "The text content.",
  "meta": {
    "tags": ["article_name"],
    "title": "article title",
    "description": "article description"
  },
  "position": 1,
  "status": 1,
  "views": 0,
  "associated_article_id": 6,
  "created_at": "2024-06-01T12:00:00Z",
  "updated_at": "2024-06-01T12:00:00Z"
}

Note: The actual output may include additional fields depending on the ChatWoot API.

Dependencies

  • External Service: Requires access to a ChatWoot instance with API enabled.
  • API Key: You must configure valid ChatWoot API credentials (chatwootApi) in n8n.
  • Environment Variable: The base URL for the ChatWoot instance must be set in the credentials as url.

Troubleshooting

Common Issues:

  • Missing or Invalid Credentials: If the API key or base URL is missing or incorrect, authentication errors will occur.
  • Required Fields Missing: Both "Account Id" and "Portal Id" are required. Omitting them will result in validation errors from the API.
  • Invalid Data Types: Ensure that all number fields receive numeric values and JSON fields are properly formatted.

Common Error Messages:

  • "401 Unauthorized": Check your API credentials and ensure they have sufficient permissions.
  • "400 Bad Request": One or more required fields are missing or incorrectly formatted.
  • "404 Not Found": The specified account, portal, or related resource does not exist.

How to resolve:

  • Double-check all required property values.
  • Verify your ChatWoot API credentials and permissions.
  • Ensure the ChatWoot instance URL is correct and accessible.

Links and References

Discussion