Skip to main content
GET
/
projects
/
{projectId}
/
deployments
/
{deploymentTargetConfigurationId}
Get a single project deployment target
curl --request GET \
  --url {schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId} \
  --header 'Authorization: Bearer <token>'
import requests

url = "{schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId}"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('{schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "{schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "{schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId}"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("{schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId}")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("{schemes}://api.upsun.com/projects/{projectId}/deployments/{deploymentTargetConfigurationId}")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "name": "<string>",
  "deploy_host": "<string>",
  "deploy_port": 123,
  "ssh_host": "<string>",
  "hosts": [
    {
      "id": "<string>",
      "services": [
        "<string>"
      ]
    }
  ],
  "auto_mounts": true,
  "excluded_mounts": [
    "<string>"
  ],
  "enforced_mounts": {},
  "auto_crons": true,
  "auto_nginx": true,
  "maintenance_mode": true,
  "guardrails_phase": 123,
  "id": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

projectId
string
required
deploymentTargetConfigurationId
string
required

Response

default - application/json
type
enum<string>
required

The type of the deployment target

Available options:
dedicated,
enterprise,
foundation,
kubernetes
name
string
required

The name of the deployment target

deploy_host
string | null
required

The host to deploy to

deploy_port
integer | null
required

The port to deploy to

ssh_host
string | null
required

The host to use to SSH to app containers

hosts
Hosts · object[] | null
required

The hosts of the deployment target

auto_mounts
boolean
required

Whether to take application mounts from the pushed data or the deployment target

excluded_mounts
string[]
required

Directories that should not be mounted

enforced_mounts
Enforced Mounts · object
required

Mounts which are always injected into pushed (e.g. enforce /var/log to be a local mount)

auto_crons
boolean
required

Whether to take application crons from the pushed data or the deployment target

auto_nginx
boolean
required

Whether to take application crons from the pushed data or the deployment target

maintenance_mode
boolean
required

Whether to perform deployments or not

guardrails_phase
integer
required

which phase of guardrails are we in

id
string

The identifier of DedicatedDeploymentTarget

Last modified on June 16, 2026