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

# Create Prompt



## OpenAPI

````yaml post /v1/prompts/create
openapi: 3.1.0
info:
  title: Vocode Hosted API
  description: |2-

            Vocode's Hosted API helps you automate phone calls in minutes. 🚀

            ## Numbers

            You can buy phone lines and place agents on them.

            ## Calls

            You can start, end, and get information about calls.
            
  termsOfService: http://example.com/terms/
  contact:
    name: Support
    email: support@vocode.dev
  version: 1.0.0
servers:
  - url: https://api.vocode.dev
    description: Production environment
    x-fern-server-name: Production
security: []
tags:
  - name: numbers
    description: Operations with phone numbers.
  - name: calls
    description: Manage calls.
paths:
  /v1/prompts/create:
    post:
      tags:
        - prompts
      summary: Create Prompt
      operationId: create_prompt
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PromptParams'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Prompt'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    PromptParams:
      properties:
        content:
          type: string
          title: Content
          default: ''
        collect_fields:
          anyOf:
            - items:
                $ref: '#/components/schemas/CollectField'
              type: array
            - type: 'null'
          title: Collect Fields
        context_endpoint:
          anyOf:
            - type: string
            - type: 'null'
          title: Context Endpoint
        prompt_template:
          anyOf:
            - type: string
              format: uuid
            - $ref: '#/components/schemas/PromptTemplate'
            - type: 'null'
          title: Prompt Template
      type: object
      title: PromptParams
    Prompt:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        user_id:
          type: string
          format: uuid
          title: User Id
        content:
          type: string
          title: Content
          default: ''
        collect_fields:
          anyOf:
            - items:
                $ref: '#/components/schemas/CollectField'
              type: array
            - type: 'null'
          title: Collect Fields
        context_endpoint:
          anyOf:
            - type: string
            - type: 'null'
          title: Context Endpoint
        prompt_template:
          anyOf:
            - $ref: '#/components/schemas/PromptTemplate'
            - type: 'null'
      type: object
      required:
        - id
        - user_id
      title: Prompt
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    CollectField:
      properties:
        field_type:
          type: string
          enum:
            - field_type_email
          const: field_type_email
          title: Field Type
        label:
          type: string
          title: Label
        name:
          type: string
          title: Name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
      type: object
      required:
        - field_type
        - label
        - name
      title: CollectField
    PromptTemplate:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        user_id:
          type: string
          format: uuid
          title: User Id
        label:
          type: string
          title: Label
          default: ''
        required_context_keys:
          items:
            type: string
          type: array
          title: Required Context Keys
      type: object
      required:
        - id
        - user_id
        - required_context_keys
      title: PromptTemplate
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````