Help namespace
Reference for the help center: published categories and articles, the article body, and redirects from old article slugs.
A
JRead the board's help center. board.help returns the categories and articles the operator has published, in the order the operator set. All four methods work with the publishable key alone. Operators write the articles in the dashboard under Help center or through the Operator API; your frontend only reads them.
The paths are BOARD_PATHS.help (/help), helpCategoryPath(slug) and helpArticlePath(slug) from @cavuno/board/paths: the help, helpCategory and helpArticle roles in the board's route manifest. board.context().features.helpCenter is true when the board has at least one published article. The types are PublicHelpCategory, PublicHelpArticleSummary, PublicHelpArticle, HelpCategoryEmbed, HelpCategoriesListQuery and HelpArticlesListQuery. For the page flow, see Help center.
board.help.categories.list()
The categories that hold at least one published article, in the board's order. Each category has id, object: 'public_help_category', slug, title and description (plain text or null).
The list is cursor-paginated. limit sets the page size (1 to 100, default 25), and cursor takes the nextCursor of the previous response.
board.help.categories.retrieve()
One category by slug. A slug that no category with a published article has is help_category_not_found (404).
board.help.articles.list()
Published articles without their bodies, ordered by category and then by position inside the category. Pass categorySlug to keep one category's articles; a slug no category has returns an empty list.
The list is cursor-paginated. limit sets the page size (1 to 100, default 25), and cursor takes the nextCursor of the previous response. Send a cursor back with the same categorySlug it was returned for.
Each summary has id, object: 'public_help_article', slug, title, summary (a short plain-text description, also meant as the page description; null when unset), category (id, slug, title), publishedAt and updatedAt (ISO 8601). updatedAt is when the published article last changed.
To read every article, walk the pages with paginate:
board.help.articles.retrieve()
One published article by slug. It adds html, the body as sanitized HTML, and the slug-history fields redirected and newSlug. When the slug is one the article used to have, redirected is true and newSlug is the current slug: redirect there before rendering.
A slug no published article has, or had, is help_article_not_found (404).
What the reads return
Only published text is returned. A draft article is not listed and is not found by slug. Edits an operator has saved on a published article but not yet published stay out of every response, and they do not move updatedAt.
Errors
categories.retrieve returns help_category_not_found (404). articles.retrieve returns help_article_not_found (404). The two lists return pagination_invalid_cursor (400) for a cursor another list returned. All four return board_not_found (404) for an unknown or private board.