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

# Finalize

> Start finalization process to create custom image, instance template, and MIG from Installation VM. Process runs in background (5-15 minutes). Poll /setup/status to track progress. (Admin only)



## OpenAPI

````yaml post /api/mig/setup/finalize
openapi: 3.1.0
info:
  title: Axion Backend API
  description: Backend API for Axion platform with desktop automation capabilities
  version: 1.0.0
servers:
  - url: https://api.getgranite.ai
    description: Production server
  - url: http://localhost:8000
    description: Local development server
security: []
tags:
  - name: Authentication
    description: User authentication and session management
  - name: Organizations
    description: Organization management and membership
  - name: Health
    description: API health and status monitoring
  - name: Automations
    description: Automation planning and execution
  - name: MIG
    description: Managed Instance Group operations
  - name: Agent
    description: Agent execution and streaming
  - name: Onboarding
    description: Organization onboarding flow
  - name: Organization Automations
    description: Organization automation endpoint management
  - name: Organization Endpoints
    description: Public endpoints for organization automations
  - name: Analytics
    description: Analytics and reporting endpoints
paths:
  /api/mig/setup/finalize:
    post:
      tags:
        - MIG
      summary: Finalize Installation VM and create MIG
      description: >-
        Start finalization process to create custom image, instance template,
        and MIG from Installation VM. Process runs in background (5-15 minutes).
        Poll /setup/status to track progress. (Admin only)
      operationId: finalizeInstallationVM
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InstallationVMFinalizeRequest'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InstallationVMFinalizeResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    InstallationVMFinalizeRequest:
      properties:
        mig_name:
          type: string
          title: Mig Name
          description: Name for the MIG to create
        machine_size:
          type: string
          title: Machine Size
          description: Machine size (small, medium, large)
          default: medium
      type: object
      required:
        - mig_name
      title: InstallationVMFinalizeRequest
      description: Request to finalize Installation VM
    InstallationVMFinalizeResponse:
      properties:
        status:
          type: string
          title: Status
          description: Operation status
        message:
          type: string
          title: Message
          description: Status message
        data:
          additionalProperties: true
          type: object
          title: Data
          description: Finalization details
      type: object
      required:
        - status
        - message
        - data
      title: InstallationVMFinalizeResponse
      description: Response from Installation VM finalization
    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
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````