Interview Chatbot Backend API

This is a stateless backend with automatic context management.

Long interviews are automatically summarized to stay within token limits.

Available Endpoints

POST /api/chat

Input: [history, user_message]

  • history: Array of message objects [{role, content}, ...]
  • user_message: String

Output: {history, error}

Context Management: Automatically creates summaries when approaching token limits

POST /api/generate_article

Input: [history]

  • history: Array of message objects

Output: {article, error}

POST /api/submit_article

Input: [article_content]

  • article_content: Markdown string

Output: {status, url, filename, error}

GET /api/get_initial_greeting

Output: Initial greeting string

Settings

  • Max Context: 25,000 tokens
  • Recent Messages Kept: 20 (last exchanges preserved)
  • Article Generator: Gemini 2.5 Pro (2M token context - no limit)