Generate Document
POST /api/v1/generate
Generate documents based on prompts and retrieved context from the knowledge base with optional filtering to control context sources. Similar to chat but optimized for document generation with optional style/format rules. Authentication: Project API Key from https://platform.useskald.com Request (using Project API Key):prompt(string, required): Description of what document to generate.rules(string, optional): Style guidelines, format requirements, or structural rules for the generated document.project_id(UUID, optional): Only required when using Token Authentication.stream(boolean, optional): Enable streaming responses (default: false).filters(array of filter objects, optional): Filters to control which memos are used as context. See Filters for detailed documentation.
- Generate documents from specific sources only (e.g., only technical docs)
- Use only recent content via metadata timestamps
- Include/exclude specific categories
- Combine multiple sources strategically
stream: true, returns Server-Sent Events:
- Missing prompt (400):
- Invalid filter structure (400):
- Generate documentation from existing knowledge.
- Create reports based on stored information.
- Compile research summaries with specific formatting.
- Generate technical specifications with style constraints.
- Create focused documents using filtered context sources.
- System retrieves relevant context from knowledge base based on prompt (with optional filters applied).
- Context is combined with prompt and optional rules.
- AI agent generates structured document.
- Response includes citations to source memos.