Manage knowledge base articles and categories.
Get KB article
/organizations/{organizationId}/projects/{projectId}/apps/kb/{appId}/articles/{articleId}Retrieves a single knowledge base article by its ID, including its full rich text content, publish status, SEO metadata, and associated category IDs. Returns 404 if the article does not exist or has been soft-deleted.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: article } = await gc.kb.getKbArticle({ organizationId: "org_123", projectId: "proj_123", appId: "app_123", articleId: "art_123"});Get KB articles
/organizations/{organizationId}/projects/{projectId}/apps/kb/{appId}/articlesLists all knowledge base articles for the specified app, with support for pagination, filtering by category, filtering by publish status, and full-text search across names and slugs. Returns articles sorted by creation date (newest first) by default.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const organizationId = "org_123";const projectId = "proj_123";const appId = "app_123";
const { data: articles } = await gc.kb.listKbArticles({ organizationId, projectId, appId });Get KB category
/organizations/{organizationId}/projects/{projectId}/apps/kb/{appId}/categories/{categoryId}Retrieves a single knowledge base category by its ID, including its name, slug, description, parent relationship, icon, and display order. Returns 404 if the category does not exist or has been soft-deleted.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: category } = await gc.kb.getKbCategory({ organizationId: "org-id", projectId: "project-id", appId: "app-id", categoryId: "category-id"});Get KB categories
/organizations/{organizationId}/projects/{projectId}/apps/kb/{appId}/categoriesLists all knowledge base categories for the specified app, returned as a hierarchical tree structure. Categories are nested under their parent categories and sorted by their display order. Includes all active (non-deleted) categories.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: categories } = await gc.kb.listKbCategories({ organizationId: "org_123", projectId: "proj_123", appId: "app_123"});Get KB settings
/organizations/{organizationId}/projects/{projectId}/apps/kb/{appId}/settingsRetrieves the current configuration settings for the knowledge base app, including display preferences, branding, and behavioral options stored as a JSON settings object on the app record.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: kbSettings } = await gc.kb.getKbSettings({ organizationId: "org-id", projectId: "project-id", appId: "app-id"});