Domains /
Assign subdomain path
Assign a subdomain path to a port.
Required permission
Account > SubdomainPaths > General > Update
Path parameters
domain
string requiredName of the domainsubdomain
string requiredName of the subdomainsubdomainPath
string requiredName of the path
Request body
- {object}
assignment
{object} requiredData about the subdomain path assignment.project
string requiredThe ID of the service to assign the subdomain path to.min length3max length39pattern^[a-zA-Z](-?[a-zA-Z0-9]+(-[a-zA-Z0-9]+)*)?$service
string requiredThe ID of the project the service belongs to.min length3max length39pattern^[a-zA-Z](-?[a-zA-Z0-9]+(-[a-zA-Z0-9]+)*)?$port
string requiredThe name of the port that will be assigned to the subdomain path.
Response body
- {object}Response object.
data
{object} requiredResult data.
API
CLI
JS Client
POST /v1/domains/{domain}/subdomains/{subdomain}/paths/{subdomainPath}/assign
Example request
Request body
curl
curl --header "Content-Type: application/json" \
--header "Authorization: Bearer NORTHFLANK_API_TOKEN" \
--request POST \
--data '{"assignment":{"project":"default-project","service":"example-service","port":"p01"}}' \
https://api.northflank.com/v1/domains/{domain}/subdomains/{subdomain}/paths/{subdomainPath}/assign
Example response
200 OK
The operation was performed successfully.
JSON
{
"data": {}
}