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

# Create mission



## OpenAPI

````yaml /agent-openapi.json post /api/v1/missions
openapi: 3.1.0
info:
  title: Polpo API
  version: 1.0.0
  description: >-
    REST API for Polpo — an AI agent that manages teams of AI coding agents.
    Manage tasks, missions, agents, playbooks, skills, and approvals. For
    conversational interaction, use the OpenAI-compatible POST
    /v1/chat/completions endpoint.
servers:
  - url: http://localhost:3890
    description: Local development
security:
  - bearerAuth: []
paths:
  /api/v1/missions:
    post:
      tags:
        - Missions
      summary: Create mission
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                data:
                  type: string
                  minLength: 1
                prompt:
                  type: string
                name:
                  type: string
                status:
                  type: string
                  enum:
                    - draft
                    - scheduled
                    - recurring
                    - active
                    - paused
                    - completed
                    - failed
                    - cancelled
                endDate:
                  type: string
                  format: date-time
                notifications:
                  type: object
                  properties:
                    rules:
                      type: array
                      items:
                        type: object
                        properties:
                          id:
                            type: string
                            minLength: 1
                          name:
                            type: string
                            minLength: 1
                          events:
                            type: array
                            items:
                              type: string
                              minLength: 1
                            minItems: 1
                          condition:
                            nullable: true
                          channels:
                            type: array
                            items:
                              type: string
                              minLength: 1
                            minItems: 1
                          severity:
                            type: string
                            enum:
                              - info
                              - warning
                              - critical
                          template:
                            type: string
                          cooldownMs:
                            type: integer
                            minimum: 0
                          includeOutcomes:
                            type: boolean
                          outcomeFilter:
                            type: array
                            items:
                              type: string
                              enum:
                                - file
                                - text
                                - url
                                - json
                                - media
                          maxAttachmentSize:
                            type: integer
                            minimum: 0
                        required:
                          - id
                          - name
                          - events
                          - channels
                    inherit:
                      type: boolean
                  required:
                    - rules
              required:
                - data
      responses:
        '201':
          description: Mission created
          content:
            application/json:
              schema:
                type: object
                properties:
                  ok:
                    type: boolean
                  data:
                    nullable: true
                required:
                  - ok
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key passed as a Bearer token. Configure via the apiKeys field in
        polpo.json or the POLPO_API_KEY environment variable.

````