curl --request POST \
--url https://app.miget.com/api/v1/services/{id}/mount_app \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"app_id": "<string>",
"mount_point": "<string>",
"sub_path": "<string>",
"label": "<string>"
}
'import requests
url = "https://app.miget.com/api/v1/services/{id}/mount_app"
payload = {
"app_id": "<string>",
"mount_point": "<string>",
"sub_path": "<string>",
"label": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
app_id: '<string>',
mount_point: '<string>',
sub_path: '<string>',
label: '<string>'
})
};
fetch('https://app.miget.com/api/v1/services/{id}/mount_app', 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 => "https://app.miget.com/api/v1/services/{id}/mount_app",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'app_id' => '<string>',
'mount_point' => '<string>',
'sub_path' => '<string>',
'label' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.miget.com/api/v1/services/{id}/mount_app"
payload := strings.NewReader("{\n \"app_id\": \"<string>\",\n \"mount_point\": \"<string>\",\n \"sub_path\": \"<string>\",\n \"label\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.miget.com/api/v1/services/{id}/mount_app")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"app_id\": \"<string>\",\n \"mount_point\": \"<string>\",\n \"sub_path\": \"<string>\",\n \"label\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.miget.com/api/v1/services/{id}/mount_app")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"app_id\": \"<string>\",\n \"mount_point\": \"<string>\",\n \"sub_path\": \"<string>\",\n \"label\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"uuid": "<string>",
"name": "<string>",
"label": "<string>",
"service_type": "<string>",
"state": "<string>",
"project_id": "<string>",
"resource_id": "<string>",
"miget_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"connection_details": {
"internal": {
"hostname": "my-service-xxx.internal",
"database": "db_name",
"port": 5432,
"username": "db_user",
"password": "db_password",
"connection_url": "postgres://db_user:db_password@my-service-xxx.internal:5432/db_name"
},
"external": {
"external_connection_url": "postgres://db_user:db_password@my-service-xxx.external:5432/db_name",
"psql_command": "PGPASSWORD=db_password psql -h my-service-xxx.external -U db_user db_name"
}
}
}Mount an application to a service
Mounts an application to a shared storage service, creating a storage addon on the app linked to this service. A service mounts to a given application once: calling this again for the same pair is refused with 422, because unmount_app matches a single addon by service. To change where an application mounts a volume, unmount it first.
curl --request POST \
--url https://app.miget.com/api/v1/services/{id}/mount_app \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"app_id": "<string>",
"mount_point": "<string>",
"sub_path": "<string>",
"label": "<string>"
}
'import requests
url = "https://app.miget.com/api/v1/services/{id}/mount_app"
payload = {
"app_id": "<string>",
"mount_point": "<string>",
"sub_path": "<string>",
"label": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
app_id: '<string>',
mount_point: '<string>',
sub_path: '<string>',
label: '<string>'
})
};
fetch('https://app.miget.com/api/v1/services/{id}/mount_app', 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 => "https://app.miget.com/api/v1/services/{id}/mount_app",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'app_id' => '<string>',
'mount_point' => '<string>',
'sub_path' => '<string>',
'label' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.miget.com/api/v1/services/{id}/mount_app"
payload := strings.NewReader("{\n \"app_id\": \"<string>\",\n \"mount_point\": \"<string>\",\n \"sub_path\": \"<string>\",\n \"label\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.miget.com/api/v1/services/{id}/mount_app")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"app_id\": \"<string>\",\n \"mount_point\": \"<string>\",\n \"sub_path\": \"<string>\",\n \"label\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.miget.com/api/v1/services/{id}/mount_app")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"app_id\": \"<string>\",\n \"mount_point\": \"<string>\",\n \"sub_path\": \"<string>\",\n \"label\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"uuid": "<string>",
"name": "<string>",
"label": "<string>",
"service_type": "<string>",
"state": "<string>",
"project_id": "<string>",
"resource_id": "<string>",
"miget_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"connection_details": {
"internal": {
"hostname": "my-service-xxx.internal",
"database": "db_name",
"port": 5432,
"username": "db_user",
"password": "db_password",
"connection_url": "postgres://db_user:db_password@my-service-xxx.internal:5432/db_name"
},
"external": {
"external_connection_url": "postgres://db_user:db_password@my-service-xxx.external:5432/db_name",
"psql_command": "PGPASSWORD=db_password psql -h my-service-xxx.external -U db_user db_name"
}
}
}Authorizations
Bearer token for authentication. Format: 'Bearer {token}'
Headers
Workspace ID (uses default workspace if not provided)
Path Parameters
Service UUID
Body
Mount an application to a service
UUID of the application to mount
Container mount path (e.g., /data). Defaults to the service's mount point.
Subdirectory of the shared volume to mount instead of its root (relative path, e.g. media/uploads). Created automatically if missing.
Human-readable label for the mounted addon
Response
Mount an application to a service
Api_V1_Entities_Service model
Service UUID
Service name
Display name
Service type (postgres, shared_storage)
Current state. While provisioning: pending, processing, creating, stopped. Once running, the live Kubernetes status: healthy (postgres/mysql/valkey), bound (storage), or running when the status is unavailable. Unhealthy: degraded, degradated, failing, lost, crashloopbackoff, failed
Associated project UUID
Assigned resource UUID
DEPRECATED: use resource_id instead
Creation timestamp
Last update timestamp
Connection details for the service
{
"internal": {
"hostname": "my-service-xxx.internal",
"database": "db_name",
"port": 5432,
"username": "db_user",
"password": "db_password",
"connection_url": "postgres://db_user:db_password@my-service-xxx.internal:5432/db_name"
},
"external": {
"external_connection_url": "postgres://db_user:db_password@my-service-xxx.external:5432/db_name",
"psql_command": "PGPASSWORD=db_password psql -h my-service-xxx.external -U db_user db_name"
}
}

