> ## Documentation Index
> Fetch the complete documentation index at: https://docs.athenahq.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Start Content Pipeline

> Start the content pipeline in one of four modes — draft (write new content from promptIds), snipe (outrank a competitor url), optimize (improve an existing url for AI search), slice (split one url into several articles). Required fields by mode: draft needs promptIds (resolve real prompt ids first — via prompts.selectForDraft in chat, or get_prompts / GET /v1/prompts over MCP and the API; never invent ids) AND title; snipe needs url AND title; optimize needs url AND title; slice needs url (and must NOT include promptIds). Returns durable contentIds (job handles); poll get_content_status (content.pipeline.status) per id. Credit op; requires approval.



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/content/generate
openapi: 3.1.0
info:
  title: AthenaHQ API
  description: >-
    AthenaHQ API provides programmatic access to manage your websites and
    prompts for AI-powered content optimization.
  version: 1.0.0
  contact:
    email: support@athenahq.ai
servers:
  - url: https://api.athenahq.ai
    description: Production server
security:
  - apiKey: []
tags:
  - name: Basics
    description: Core API operations for managing websites and prompts
  - name: Metrics
    description: Metrics and analytics endpoints for tracking AI visibility
  - name: Billing
    description: Billing and credits endpoints for managing usage
  - name: Team Management
    description: Endpoints for managing team members and invitations
  - name: Groups
    description: Endpoints for managing groups of websites
  - name: Content
    description: >-
      Endpoints for accessing Content Hub data — tabs, tracked URLs, and per-URL
      prompt breakdowns.
  - name: Pitch Workspace
    description: >-
      Endpoints for accessing pitch workspace reports — org-scoped pitch runs
      with competitors, prompts, attributes, and aggregate metrics.
  - name: Knowledge Base
    description: >-
      Endpoints for reading the brand Knowledge Base — approved brand facts and
      the pillars that organize them.
paths:
  /api/v1/content/generate:
    post:
      tags:
        - Content
      summary: Start Content Pipeline
      description: >-
        Start the content pipeline in one of four modes — draft (write new
        content from promptIds), snipe (outrank a competitor url), optimize
        (improve an existing url for AI search), slice (split one url into
        several articles). Required fields by mode: draft needs promptIds
        (resolve real prompt ids first — via prompts.selectForDraft in chat, or
        get_prompts / GET /v1/prompts over MCP and the API; never invent ids)
        AND title; snipe needs url AND title; optimize needs url AND title;
        slice needs url (and must NOT include promptIds). Returns durable
        contentIds (job handles); poll get_content_status
        (content.pipeline.status) per id. Credit op; requires approval.
      operationId: content.pipeline.start
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                website_id:
                  type: string
                mode:
                  type: string
                  enum:
                    - draft
                    - snipe
                    - optimize
                    - slice
                title:
                  type: string
                url:
                  type: string
                prompt_ids:
                  type: array
                  items:
                    type: string
                custom_instructions:
                  type: string
                brand_kit_id:
                  type: string
                sheet_id:
                  anyOf:
                    - type: string
                    - type: 'null'
                use_content_memories:
                  type: boolean
                auto_approve:
                  type: boolean
                content_format_type:
                  type: string
                scrape_additional_links:
                  type: boolean
                kb_mode:
                  type: string
                  enum:
                    - auto
                    - manual
                    - none
                selected_topic_ids:
                  type: array
                  items:
                    type: string
                pinned_claim_ids:
                  type: array
                  items:
                    type: string
                use_kb_internal_links:
                  type: boolean
                rec_id:
                  type: string
                rec_kind:
                  type: string
                  enum:
                    - on_page_topic
                    - on_page_snipe
                pdf_file_name_or_r2_key:
                  type: string
              required:
                - website_id
                - mode
      responses:
        '202':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  content_ids:
                    type: array
                    items:
                      type: string
                  status:
                    enum:
                      - generating
                    type: string
                  slice_titles:
                    type: array
                    items:
                      type: string
                required:
                  - content_ids
                  - status
        '400':
          description: Bad Request — validation failed
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '429':
          description: Rate Limited
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '500':
          description: Internal Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
components:
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key for authentication. You can create one
        [here](https://app.athenahq.ai/organization?tab=api).

````