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

# Generate a full system prompt from a short brief

> Expand a 1-2 sentence brief into a production-ready voice-agent system prompt.

The frontend's "Generate" button hits this. The result is returned, not
stored — the operator reviews/edits before posting it as `system_prompt`
in the agent create/update payload.



## OpenAPI

````yaml https://api.mrassistant.ai/openapi.json post /agents/generate-system-prompt
openapi: 3.1.0
info:
  title: Backend - Multilingual Voice Agent System
  description: FastAPI backend for multilingual voice agents with tool use
  version: 1.0.0
servers: []
security: []
paths:
  /agents/generate-system-prompt:
    post:
      tags:
        - agents
      summary: Generate a full system prompt from a short brief
      description: >-
        Expand a 1-2 sentence brief into a production-ready voice-agent system
        prompt.


        The frontend's "Generate" button hits this. The result is returned, not

        stored — the operator reviews/edits before posting it as `system_prompt`

        in the agent create/update payload.
      operationId: generate_system_prompt_agents_generate_system_prompt_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GenerateSystemPromptRequest'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerateSystemPromptResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    GenerateSystemPromptRequest:
      properties:
        brief:
          type: string
          maxLength: 2000
          minLength: 10
          title: Brief
          description: Short description of the agent's purpose, role, and context.
        name:
          anyOf:
            - type: string
              maxLength: 100
            - type: 'null'
          title: Name
          description: Agent name (used in the prompt's identity section).
        language:
          anyOf:
            - type: string
              maxLength: 10
            - type: 'null'
          title: Language
          description: Primary language code, e.g. 'en'.
          default: en
        company:
          anyOf:
            - type: string
              maxLength: 200
            - type: 'null'
          title: Company
          description: Company / organization the agent represents.
        industry:
          anyOf:
            - type: string
              maxLength: 100
            - type: 'null'
          title: Industry
          description: Industry or vertical, e.g. 'telecom', 'healthcare'.
        tone:
          anyOf:
            - type: string
              maxLength: 200
            - type: 'null'
          title: Tone
          description: Tone or personality, e.g. 'friendly and professional'.
        additional_context:
          anyOf:
            - type: string
              maxLength: 2000
            - type: 'null'
          title: Additional Context
          description: >-
            Optional extra notes — common questions, escalation rules, what to
            avoid, etc.
      type: object
      required:
        - brief
      title: GenerateSystemPromptRequest
      description: Brief description the user wants expanded into a full system prompt.
    GenerateSystemPromptResponse:
      properties:
        system_prompt:
          type: string
          title: System Prompt
          description: The full generated system prompt.
        char_count:
          type: integer
          title: Char Count
          description: Character count of the generated prompt.
        model:
          type: string
          title: Model
          description: Model that produced the prompt.
        provider:
          type: string
          title: Provider
          description: LLM provider used.
        tokens_used:
          type: integer
          title: Tokens Used
          description: Total tokens consumed for generation.
          default: 0
      type: object
      required:
        - system_prompt
        - char_count
        - model
        - provider
      title: GenerateSystemPromptResponse
      description: Generated system prompt ready to drop into agent create/update.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````