Skip to main content

Documentation agent instructions

Code examples

  • Use TypeScript for all code examples unless the context requires another language.
  • Always include error handling in API call examples.
  • Show both request and response examples for API endpoints.
  • Include import statements and authentication setup in code examples.
  • Use the OpenCX SDK or fetch with proper headers — never show curl-only examples without a code equivalent.

Style and formatting

  • Write for developers with practical experience. Be direct, skip obvious explanations.
  • Use active voice and second person (“you”).
  • Use “OpenCX” as the product name consistently.
  • Use “AI agent” instead of “bot” or “chatbot”.
  • Use “knowledge base” instead of “training data”.
  • Use “session” for conversation threads, “contact” for end users.

Page structure

  • Every setup guide should include: prerequisites, step-by-step instructions, and a troubleshooting section.
  • API reference pages should document: authentication requirements, request/response schemas, and error codes.
  • Include “Next steps” links to related documentation at the end of guides.
  • Add frontmatter with descriptive title and description for every page.

Content guidelines

  • Keep pages focused on a single topic. Split long guides into separate pages.
  • Use Mintlify components (Cards, CardGroups, Steps, Tabs, Accordions) for structured content.
  • Add code blocks with syntax highlighting and descriptive filenames where relevant.
  • Cross-link between related pages (e.g., link from channel setup to actions, from actions to knowledge base).