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

# Create a custom brief (triggers async brief generation)



## OpenAPI

````yaml /api-reference/openapi.json post /api/v2/brands/{brand_id}/content_studio/briefs
openapi: 3.0.1
info:
  title: Cognizo Public API
  version: v1
  description: >-
    Public REST API for Cognizo. Authenticate with an API key via the
    `X-API-KEY` header.
servers:
  - url: https://core.cognizo.ai
security:
  - apiKey: []
paths:
  /api/v2/brands/{brand_id}/content_studio/briefs:
    parameters:
      - name: brand_id
        in: path
        required: true
        schema:
          type: string
          format: uuid
    post:
      tags:
        - ContentStudio
      summary: Create a custom brief (triggers async brief generation)
      operationId: create_brand_content_studio_brief
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/content_studio_content_brief_create_input'
      responses:
        '201':
          description: brief created, generation enqueued
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/content_studio_content_brief'
                required:
                  - data
        '422':
          description: validation error (empty prompt universe / wrong-brand audience)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '429':
          description: monthly article-generation limit reached (ARTICLE_LIMIT_REACHED)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '500':
          description: unexpected error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
components:
  schemas:
    content_studio_content_brief_create_input:
      type: object
      description: >-
        Creation wizard input. Create mode needs prompt_ids[] (the UI expands
        topic checkboxes to prompt ids client-side); the anchor topic is derived
        server-side. Rewrite mode needs source_url instead.
      properties:
        mode:
          type: string
          enum:
            - create
            - rewrite
          default: create
          description: >-
            rewrite replaces an existing owned page (source_url required,
            selection optional); create is the net-new flow
        prompt_ids:
          type: array
          items:
            type: string
            format: uuid
          description: >-
            The selection — prompts tracked by the brand (topic checkboxes
            expand to their prompts client-side)
        source_url:
          type: string
          nullable: true
          description: >-
            Rewrite mode only (required there): URL of a crawled owned page to
            rewrite
        title:
          type: string
          nullable: true
          description: >-
            Optional — when omitted the brief generator derives a title
            (research / topic name / source page title)
        format:
          type: string
          enum:
            - how_to_guide
            - comparison
            - product_review
            - listicle
            - case_study
            - pricing_breakdown
            - alternative
            - article
            - opinion_piece
            - news_article
            - glossary_page
            - technical
            - features
            - documentation
            - service_page
            - product_page
          description: Pre-fill from GET briefs/recommended_inputs
        audience_id:
          type: string
          format: uuid
        target_word_count:
          type: integer
          nullable: true
        additional_instructions:
          type: string
          nullable: true
          description: >-
            Advanced settings free text — tone, angles, must-cover points;
            honored by research/outline/writing
      required:
        - format
        - audience_id
    content_studio_content_brief:
      type: object
      properties:
        id:
          type: string
          format: uuid
        brand_id:
          type: string
          format: uuid
        audience_id:
          type: string
          format: uuid
        audience_name:
          type: string
          nullable: true
        topic_id:
          type: string
          format: uuid
          nullable: true
          description: >-
            Anchor topic — DERIVED server-side from the selected prompts
            (most-covered topic); null for rewrite/legacy briefs
        topic_name:
          type: string
          nullable: true
        target_prompts:
          type: array
          description: >-
            Resolved target prompts with display data (Inputs panel) — empty
            until brief generation stamps the resolved prompt universe
          items:
            type: object
            properties:
              prompt_id:
                type: string
                format: uuid
              prompt:
                type: string
              country_codes:
                type: array
                items:
                  type: string
            required:
              - prompt_id
              - prompt
              - country_codes
        recommendation_id:
          type: string
          format: uuid
          nullable: true
        recommendation:
          type: object
          nullable: true
          properties:
            id:
              type: string
              format: uuid
            type:
              type: string
              enum:
                - social_post
                - earned_3rd_party
                - owned_create
                - owned_refresh
                - no_action
                - social
                - earned
                - owned
            suggested_title:
              type: string
              nullable: true
        title:
          type: string
          nullable: true
          description: >-
            Null until brief_ready when created without one (derived from
            research)
        format:
          type: string
          enum:
            - how_to_guide
            - comparison
            - product_review
            - listicle
            - case_study
            - pricing_breakdown
            - alternative
            - article
            - opinion_piece
            - news_article
            - glossary_page
            - technical
            - features
            - documentation
            - service_page
            - product_page
        mode:
          type: string
          enum:
            - create
            - rewrite
          description: rewrite briefs replace an existing owned page's content
        source_url:
          type: string
          nullable: true
          description: The owned page being rewritten; null on create-mode briefs
        target_word_count:
          type: integer
          nullable: true
        additional_instructions:
          type: string
          nullable: true
          description: User's free-text steering from the wizard's advanced settings
        outline:
          type: object
          additionalProperties: true
          description: >-
            { sections: [{title, purpose, key_points[], target_words,
            uses_required_element, answers_queries[], delivers_table}] }
        brief_text:
          type: string
          nullable: true
          description: >-
            Markdown brief — the article writer's primary input; null until
            brief_ready
        metadata:
          type: object
          additionalProperties: true
          description: >-
            Pipeline scratchpad: weights snapshot, sources, tool-call trace,
            enhancements
        article:
          type: object
          nullable: true
          properties:
            id:
              type: string
              format: uuid
            state:
              type: string
            progress_pct:
              type: integer
          description: Stub when an article exists — fetch the body via GET /articles/{id}
        state:
          type: string
          enum:
            - new
            - brief_generating
            - brief_ready
            - article_generating
            - article_ready
            - failed
        progress_pct:
          type: integer
        generation_error:
          type: string
          nullable: true
        created_at:
          type: string
          format: date-time
          nullable: true
        updated_at:
          type: string
          format: date-time
          nullable: true
        deleted_at:
          type: string
          format: date-time
          nullable: true
      required:
        - id
        - brand_id
        - audience_id
        - format
        - state
        - progress_pct
        - outline
        - metadata
    error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
            message:
              type: string
            details:
              type: array
              items:
                $ref: '#/components/schemas/error_detail'
          required:
            - code
            - message
      required:
        - error
    error_detail:
      type: object
      properties:
        field:
          type: string
          nullable: true
        code:
          type: string
        message:
          type: string
      required:
        - code
        - message
        - field
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: X-API-KEY

````