{
  "ml.start_trained_model_deployment": {
    "documentation": {
      "url": "https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-trained-model-deployment",
      "description": "Start a trained model deployment"
    },
    "stability": "stable",
    "visibility": "public",
    "headers": {
      "accept": [
        "application/json"
      ],
      "content_type": [
        "application/json"
      ]
    },
    "url": {
      "paths": [
        {
          "path": "/_ml/trained_models/{model_id}/deployment/_start",
          "methods": [
            "POST"
          ],
          "parts": {
            "model_id": {
              "type": "string",
              "description": "The unique identifier of the trained model."
            }
          }
        }
      ]
    },
    "params": {
      "cache_size": {
        "type": "string",
        "description": "A byte-size value for configuring the inference cache size. For example, 20mb."
      },
      "deployment_id": {
        "type": "string",
        "description": "The Id of the new deployment. Defaults to the model_id if not set."
      },
      "number_of_allocations": {
        "type": "int",
        "description": "The total number of allocations this model is assigned across machine learning nodes.",
        "default": 1
      },
      "threads_per_allocation": {
        "type": "int",
        "description": "The number of threads used by each model allocation during inference.",
        "default": 1
      },
      "priority": {
        "type": "enum",
        "description": "The deployment priority.",
        "options": [
          "normal",
          "low"
        ]
      },
      "queue_capacity": {
        "type": "int",
        "description": "Controls how many inference requests are allowed in the queue at a time.",
        "default": 1024
      },
      "timeout": {
        "type": "time",
        "description": "Controls the amount of time to wait for the model to deploy.",
        "default": "20s"
      },
      "wait_for": {
        "type": "enum",
        "description": "Specifies the allocation status to wait for before returning.",
        "options": [
          "started",
          "starting",
          "fully_allocated"
        ],
        "default": "started"
      }
    },
    "body": {
      "description": "The settings for the trained model deployment",
      "required": false
    }
  }
}
