Skip to main content
POST
/
v1
/
projects
/
{project_id}
/
deployments
Create Deployment
curl --request POST \
  --url https://api.landing.ai/v1/projects/{project_id}/deployments \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "modelId": "<string>",
  "threshold": 123
}
'
import requests

url = "https://api.landing.ai/v1/projects/{project_id}/deployments"

payload = {
    "name": "<string>",
    "modelId": "<string>",
    "threshold": 123
}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: JSON.stringify({name: '<string>', modelId: '<string>', threshold: 123})
};

fetch('https://api.landing.ai/v1/projects/{project_id}/deployments', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
{
  "data": {
    "id": "<string>",
    "predictionUrl": "<string>",
    "name": "<string>",
    "modelId": "<string>",
    "threshold": 123
  }
}
{
  "detail": [
    {
      "loc": [
        "<string>"
      ],
      "msg": "<string>",
      "type": "<string>"
    }
  ]
}

Headers

apikey
string | null

Path Parameters

project_id
integer
required

Query Parameters

timeout
integer | null
default:60

Body

application/json
name
string
required
modelId
string<uuid4> | null
threshold
number | null

Response

Successful Response

data
DeploymentItem · object | null
required