Out of the box, Help Center doesn't support publishing one article in multiple locations.
Using the Help Center API, however, you or a technically minded colleague can build a small application that publishes copies of any article in one or more specified locations in your Help Center, or in any branded Help Center in your Guide Professional plan. Such an application could also periodically update the copies with the latest versions of the source article.
You can use the following Help Center API endpoints to publish and sync copies of articles.
To make a copy of an article in another Help Center location
-
Make a GET request to get the source article's data:
GET /api/v2/help_center/{locale}/articles/{article_id}.json
See Show Article in the developer docs.
-
Make a POST request to create a copy using the data from the GET request:
POST /api/v2/help_center/{locale}/sections/{section_id}/articles.json
See Create Article.
To sync the content of a source article with one of its copies
-
Make a GET request to get the current content of the source article:
GET /api/v2/help_center/articles/{article_id}/translations/{locale}.json
See Show Translation in the developer docs.
-
Make a PUT request to update the article copy using the data from the GET request:
PUT /api/v2/help_center/articles/{article_id}/translations/{locale}.json
See Update Translation.
To learn how you might build a copy-sync application with these endpoints, see Mimeo, a small, command-line application on Github. Start with the project's documentation. Then clone or download the source code to try it out or just to see how it works. You can also modify or extend the application any way you want to build your own solution.
3 Comments
Can I use this API to sync articles in our help desk to ZD help center?
Hello Charles,
Sorry i'm not a tech guy but does this means we can create a multilingual library outside Zendesk which contains all the articles and the Help Center API automatically update the articles in the Help Centre based on this source?
Hi Christophe,
The use case in this article is really about publishing the same article in different sections of the same Help Center.
You can still use the Help Center API to publish content maintained outside the Help Center. Many ways to do it, but one would be to build a cron script to check folders periodically for updated or new articles, then publishing them to Help Center using the Create Translation or Update Translation endpoints.
Charles
Please sign in to leave a comment.