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

# Deploy Aligned Model

> Deploy an aligned model for inference use.


This endpoint deploys a domain-aligned model, making it available for inference.


**Path Parameters:**

- `model_id`: Unique identifier of the aligned model to deploy


**Returns:**

String containing the model ID for tracking deployment status


**Raises:**

- `400`: If model is already deployed or deployment provider is invalid
- `404`: If model or alignment task not found


**Example Request:**

```json
POST /api/v3/models/deploy-model/alignment-xyz789
Headers: {"Authorization": "Bearer <api_key>"}
```


**Example Response:**

```json
"alignment-xyz789"
```


**Notes:**

- Deployment is asynchronous and may take 5-15 minutes to complete
- Use `/models/aligned` to check deployment status (`DEPLOYING`, `DEPLOYED`)
- Once deployed, the model will be available at its inference endpoint
- Model must be in `UNDEPLOYED` state before deployment



## OpenAPI

````yaml https://api.nugen.in/openapi-public.json post /api/v3/models/deploy-model/{model_id}
openapi: 3.1.0
info:
  title: Nugen Intelligence API
  description: 'Nugen Intelligence : Powering Specialized Intelligence At Scale'
  version: 25.4.20
servers: []
security: []
paths:
  /api/v3/models/deploy-model/{model_id}:
    post:
      tags:
        - Models
      summary: Deploy Aligned Model
      description: >-
        Deploy an aligned model for inference use.



        This endpoint deploys a domain-aligned model, making it available for
        inference.



        **Path Parameters:**


        - `model_id`: Unique identifier of the aligned model to deploy



        **Returns:**


        String containing the model ID for tracking deployment status



        **Raises:**


        - `400`: If model is already deployed or deployment provider is invalid

        - `404`: If model or alignment task not found



        **Example Request:**


        ```json

        POST /api/v3/models/deploy-model/alignment-xyz789

        Headers: {"Authorization": "Bearer <api_key>"}

        ```



        **Example Response:**


        ```json

        "alignment-xyz789"

        ```



        **Notes:**


        - Deployment is asynchronous and may take 5-15 minutes to complete

        - Use `/models/aligned` to check deployment status (`DEPLOYING`,
        `DEPLOYED`)

        - Once deployed, the model will be available at its inference endpoint

        - Model must be in `UNDEPLOYED` state before deployment
      operationId: deploy_aligned_model
      parameters:
        - name: model_id
          in: path
          required: true
          schema:
            type: string
            title: Model Id
      responses:
        '200':
          description: Successfully initiated model deployment
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeployAlignedModelResponse'
              example:
                model_id: alignment-xyz789
        '400':
          description: Bad request - model already deployed or deployment limit reached
          content:
            application/json:
              example:
                detail: >-
                  Model is already deployed. Current status: DEPLOYED. Please
                  undeploy first.
        '404':
          description: Model or alignment task not found
          content:
            application/json:
              example:
                detail: Model not found
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    DeployAlignedModelResponse:
      properties:
        model_id:
          type: string
          title: Model Id
          description: Model ID of the aligned model being deployed
          example: alignment-xyz789-deployed
      type: object
      required:
        - model_id
      title: DeployAlignedModelResponse
    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
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````