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

# Initialize jira sandbox with data

> Initialize the sandbox with jira-specific data following the defined schema.



## OpenAPI

````yaml post /sandbox/jira/{sandbox_id}/initialize
openapi: 3.1.0
info:
  title: Klavis AI (https://www.klavis.ai)
  description: Klavis AI - Open Source MCP Integrations for AI Applications
  version: 0.1.0
servers:
  - url: https://api.klavis.ai
    description: US Production server
  - url: https://api.eu.klavis.ai
    description: EU Production server
security: []
paths:
  /sandbox/jira/{sandbox_id}/initialize:
    post:
      tags:
        - sandbox
      summary: Initialize jira sandbox with data
      description: >-
        Initialize the sandbox with jira-specific data following the defined
        schema.
      operationId: initialize_sandbox_sandbox_jira__sandbox_id__initialize_post
      parameters:
        - name: sandbox_id
          in: path
          required: true
          schema:
            type: string
            description: The unique sandbox identifier
            title: Sandbox Id
          description: The unique sandbox identifier
        - name: init_default_data
          in: query
          required: false
          schema:
            type: boolean
            description: If true, use default test data for initialization
            default: false
            title: Init Default Data
          description: If true, use default test data for initialization
      requestBody:
        content:
          application/json:
            schema:
              anyOf:
                - $ref: '#/components/schemas/JiraData-Input'
                - type: 'null'
              title: Request Body
            examples:
              default:
                summary: Example initialization data
                value:
                  projects:
                    - key: SAND
                      name: Sandbox Project Alpha
                      description: Main sandbox project for testing and development
                      project_type: software
                      issues:
                        - summary: Set up project infrastructure
                          description: >-
                            Initialize project repository, CI/CD pipeline, and
                            development environment
                          issue_type: Task
                          priority: High
                          sprint_name: Sprint 1 - Foundation
                          comments:
                            - body: Repository created and initial structure set up
                            - body: CI/CD pipeline configured with GitHub Actions
                        - summary: Implement user authentication
                          description: Create authentication system with JWT tokens
                          issue_type: Story
                          priority: Highest
                          sprint_name: Sprint 1 - Foundation
                          comments:
                            - body: >-
                                Should we use OAuth2 or custom JWT
                                implementation?
                            - body: >-
                                Let's go with OAuth2 for better security and
                                flexibility
                            - body: OAuth2 implementation completed and tested
                        - summary: Design database schema
                          description: >-
                            Create entity-relationship diagrams and database
                            migrations
                          issue_type: Task
                          priority: High
                          sprint_name: Sprint 1 - Foundation
                          comments:
                            - body: ER diagram draft completed, ready for review
                        - summary: Build REST API endpoints
                          description: Implement CRUD operations for core entities
                          issue_type: Story
                          priority: High
                          sprint_name: Sprint 2 - Core Features
                          comments:
                            - body: API specification documented using OpenAPI 3.0
                            - body: Endpoints for user management completed
                        - summary: Implement data validation
                          description: Add input validation and error handling
                          issue_type: Task
                          priority: Medium
                          sprint_name: Sprint 2 - Core Features
                          comments: []
                        - summary: Create frontend components
                          description: Build reusable React components for the UI
                          issue_type: Story
                          priority: Medium
                          sprint_name: Sprint 2 - Core Features
                          comments:
                            - body: Using shadcn/ui for component library
                        - summary: Write unit tests
                          description: Achieve 80% code coverage with unit tests
                          issue_type: Task
                          priority: High
                          sprint_name: Sprint 3 - Testing & Polish
                          comments:
                            - body: Using pytest for backend tests
                            - body: Jest configured for frontend testing
                        - summary: Fix login bug on mobile
                          description: Users cannot log in on iOS devices
                          issue_type: Bug
                          priority: Highest
                          sprint_name: Sprint 3 - Testing & Polish
                          comments:
                            - body: Bug confirmed on iPhone 14 and 15
                            - body: Issue was related to viewport height calculation
                            - body: Fix deployed and verified
                        - summary: Research new technology stack
                          description: Evaluate alternatives for current tech stack
                          issue_type: Task
                          priority: Low
                          comments:
                            - body: Considering FastAPI vs Flask for backend
                        - summary: Update documentation
                          description: Keep API documentation up to date
                          issue_type: Task
                          priority: Medium
                          comments: []
                        - summary: Performance optimization backlog
                          description: List of performance improvements to consider
                          issue_type: Epic
                          priority: Low
                          comments:
                            - body: >-
                                Database query optimization should be
                                prioritized
                            - body: Consider implementing Redis caching
                    - key: TEST
                      name: Testing Project Beta
                      description: Secondary project for QA and integration testing
                      project_type: software
                      issues:
                        - summary: Conduct integration testing
                          description: Test integration between frontend and backend
                          issue_type: Task
                          priority: High
                          sprint_name: QA Sprint 1
                          comments:
                            - body: All critical paths tested successfully
                        - summary: Perform security audit
                          description: Run security scans and penetration testing
                          issue_type: Task
                          priority: Highest
                          sprint_name: QA Sprint 1
                          comments:
                            - body: Using OWASP ZAP for security testing
                            - body: Two medium severity issues found
                        - summary: Set up test data generators
                          description: Create utilities to generate test data
                          issue_type: Task
                          priority: Medium
                          comments:
                            - body: Using Faker library for test data generation
                        - summary: Document test scenarios
                          description: Create comprehensive test case documentation
                          issue_type: Task
                          priority: Medium
                          comments: []
                    - key: DOCS
                      name: Documentation Project
                      description: Project for managing documentation and knowledge base
                      project_type: business
                      issues:
                        - summary: Write getting started guide
                          description: Create beginner-friendly onboarding documentation
                          issue_type: Task
                          priority: High
                          comments:
                            - body: Draft completed and ready for review
                        - summary: Create API reference documentation
                          description: Auto-generate API docs from OpenAPI spec
                          issue_type: Task
                          priority: High
                          comments: []
                        - summary: Record tutorial videos
                          description: Create video tutorials for common workflows
                          issue_type: Task
                          priority: Low
                          comments:
                            - body: Script written for first video
                            - body: Need to set up recording equipment
                  boards:
                    - name: Alpha Development Board
                      type: scrum
                      project_key: SAND
                    - name: Alpha Kanban Board
                      type: kanban
                      project_key: SAND
                    - name: Beta Testing Board
                      type: scrum
                      project_key: TEST
                  sprints:
                    - name: Sprint 1 - Foundation
                      start_date: '2024-01-01T00:00:00.000Z'
                      end_date: '2024-01-14T23:59:59.999Z'
                      origin_board_name: Alpha Development Board
                    - name: Sprint 2 - Core Features
                      start_date: '2024-01-15T00:00:00.000Z'
                      end_date: '2024-01-28T23:59:59.999Z'
                      origin_board_name: Alpha Development Board
                    - name: Sprint 3 - Testing & Polish
                      start_date: '2024-01-29T00:00:00.000Z'
                      end_date: '2024-02-11T23:59:59.999Z'
                      origin_board_name: Alpha Development Board
                    - name: QA Sprint 1
                      start_date: '2024-02-01T00:00:00.000Z'
                      end_date: '2024-02-14T23:59:59.999Z'
                      origin_board_name: Beta Testing Board
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InitializeSandboxResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    JiraData-Input:
      properties:
        projects:
          items:
            $ref: '#/components/schemas/JiraProject-Input'
          type: array
          title: Projects
          description: List of projects with their issues
        boards:
          items:
            $ref: '#/components/schemas/JiraBoard-Input'
          type: array
          title: Boards
          description: List of boards
        sprints:
          items:
            $ref: '#/components/schemas/JiraSprint-Input'
          type: array
          title: Sprints
          description: List of sprints
      type: object
      title: JiraData
      description: |-
        Complete Jira sandbox data structure.

        Relational structure for initialization:
        - Projects contain Issues
        - Boards refer to Projects (via key)
        - Sprints refer to Boards (via name)
        - Issues can refer to Sprints (via name)
    InitializeSandboxResponse:
      properties:
        sandbox_id:
          type: string
          title: Sandbox Id
          description: Sandbox identifier
        status:
          $ref: '#/components/schemas/SandboxStatus'
          description: Current status
        message:
          type: string
          title: Message
          description: Initialization result message
      type: object
      required:
        - sandbox_id
        - status
        - message
      title: InitializeSandboxResponse
      description: Response model for sandbox initialization
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    JiraProject-Input:
      properties:
        key:
          type: string
          title: Key
          description: Project key (e.g., PROJ)
        name:
          type: string
          title: Name
          description: Project name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Project description
        project_type:
          type: string
          title: Project Type
          description: Project type (software, business, etc.)
          default: software
        issues:
          anyOf:
            - items:
                $ref: '#/components/schemas/JiraIssue-Input'
              type: array
            - type: 'null'
          title: Issues
          description: Issues in this project
      type: object
      required:
        - key
        - name
      title: JiraProject
      description: Jira Project object
    JiraBoard-Input:
      properties:
        name:
          type: string
          title: Name
          description: Board name
        type:
          type: string
          title: Type
          description: Board type (scrum or kanban)
          default: scrum
        project_key:
          anyOf:
            - type: string
            - type: 'null'
          title: Project Key
          description: Key of the project this board belongs to (for initialization)
        filter_jql:
          anyOf:
            - type: string
            - type: 'null'
          title: Filter Jql
          description: JQL for the board filter
      type: object
      required:
        - name
      title: JiraBoard
      description: Jira Board object
    JiraSprint-Input:
      properties:
        name:
          type: string
          title: Name
          description: Sprint name
        start_date:
          anyOf:
            - type: string
            - type: 'null'
          title: Start Date
          description: Sprint start date (ISO 8601 format)
        end_date:
          anyOf:
            - type: string
            - type: 'null'
          title: End Date
          description: Sprint end date (ISO 8601 format)
        origin_board_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Origin Board Name
          description: Name of the board this sprint belongs to (for initialization)
        goal:
          anyOf:
            - type: string
            - type: 'null'
          title: Goal
          description: Sprint goal
        state:
          anyOf:
            - type: string
            - type: 'null'
          title: State
          description: Sprint state (future, active, closed)
      type: object
      required:
        - name
      title: JiraSprint
      description: Jira Sprint object
    SandboxStatus:
      type: string
      enum:
        - idle
        - occupied
        - error
      title: SandboxStatus
      description: Status of a sandbox instance - matches database enum
    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
    JiraIssue-Input:
      properties:
        summary:
          type: string
          title: Summary
          description: Issue summary/title
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Issue description
        issue_type:
          type: string
          title: Issue Type
          description: Issue type (Task, Bug, Story, etc.)
          default: Task
        priority:
          anyOf:
            - type: string
            - type: 'null'
          title: Priority
          description: Issue priority (Highest, High, Medium, Low, Lowest)
        sprint_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Sprint Name
          description: Name of the sprint this issue belongs to (for initialization)
        comments:
          anyOf:
            - items:
                $ref: '#/components/schemas/JiraComment'
              type: array
            - type: 'null'
          title: Comments
          description: Comments on this issue
      type: object
      required:
        - summary
      title: JiraIssue
      description: Jira Issue object
    JiraComment:
      properties:
        body:
          type: string
          title: Body
          description: Comment text content
      type: object
      required:
        - body
      title: JiraComment
      description: Jira Comment object
  securitySchemes:
    HTTPBearer:
      type: http
      description: Your Klavis AI API key.
      scheme: bearer
      x-fern-bearer:
        name: api_key

````