Create cluster
curl --request POST \
--url https://nks.nks.europe-west4.nscale.com/api/v1/clusters \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"metadata": {
"name": "production-cluster",
"description": "Production Kubernetes cluster",
"tags": [
{
"name": "environment",
"value": "production"
}
]
},
"spec": {
"networkId": "61f0ad85-3001-41cb-824a-e6a047668dfe",
"platformReleaseId": "nks-1-32-3",
"apiServer": {
"publicIP": false
}
}
}
'import requests
url = "https://nks.nks.europe-west4.nscale.com/api/v1/clusters"
payload = {
"metadata": {
"name": "production-cluster",
"description": "Production Kubernetes cluster",
"tags": [
{
"name": "environment",
"value": "production"
}
]
},
"spec": {
"networkId": "61f0ad85-3001-41cb-824a-e6a047668dfe",
"platformReleaseId": "nks-1-32-3",
"apiServer": { "publicIP": False }
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
metadata: {
name: 'production-cluster',
description: 'Production Kubernetes cluster',
tags: [{name: 'environment', value: 'production'}]
},
spec: {
networkId: '61f0ad85-3001-41cb-824a-e6a047668dfe',
platformReleaseId: 'nks-1-32-3',
apiServer: {publicIP: false}
}
})
};
fetch('https://nks.nks.europe-west4.nscale.com/api/v1/clusters', 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://nks.nks.europe-west4.nscale.com/api/v1/clusters",
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([
'metadata' => [
'name' => 'production-cluster',
'description' => 'Production Kubernetes cluster',
'tags' => [
[
'name' => 'environment',
'value' => 'production'
]
]
],
'spec' => [
'networkId' => '61f0ad85-3001-41cb-824a-e6a047668dfe',
'platformReleaseId' => 'nks-1-32-3',
'apiServer' => [
'publicIP' => false
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://nks.nks.europe-west4.nscale.com/api/v1/clusters"
payload := strings.NewReader("{\n \"metadata\": {\n \"name\": \"production-cluster\",\n \"description\": \"Production Kubernetes cluster\",\n \"tags\": [\n {\n \"name\": \"environment\",\n \"value\": \"production\"\n }\n ]\n },\n \"spec\": {\n \"networkId\": \"61f0ad85-3001-41cb-824a-e6a047668dfe\",\n \"platformReleaseId\": \"nks-1-32-3\",\n \"apiServer\": {\n \"publicIP\": false\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://nks.nks.europe-west4.nscale.com/api/v1/clusters")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"metadata\": {\n \"name\": \"production-cluster\",\n \"description\": \"Production Kubernetes cluster\",\n \"tags\": [\n {\n \"name\": \"environment\",\n \"value\": \"production\"\n }\n ]\n },\n \"spec\": {\n \"networkId\": \"61f0ad85-3001-41cb-824a-e6a047668dfe\",\n \"platformReleaseId\": \"nks-1-32-3\",\n \"apiServer\": {\n \"publicIP\": false\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://nks.nks.europe-west4.nscale.com/api/v1/clusters")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"metadata\": {\n \"name\": \"production-cluster\",\n \"description\": \"Production Kubernetes cluster\",\n \"tags\": [\n {\n \"name\": \"environment\",\n \"value\": \"production\"\n }\n ]\n },\n \"spec\": {\n \"networkId\": \"61f0ad85-3001-41cb-824a-e6a047668dfe\",\n \"platformReleaseId\": \"nks-1-32-3\",\n \"apiServer\": {\n \"publicIP\": false\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"metadata": {
"id": "1e44f19a-21a9-43cc-a460-5d6f21247f65",
"generation": 1,
"name": "production-cluster",
"organizationId": "9a8c6370-4065-4d4a-9da0-7678df40cd9d",
"projectId": "e36c058a-8eba-4f5b-91f4-f6ffb983795c",
"creationTime": "2026-05-14T10:00:00.000Z",
"provisioningStatus": "provisioning",
"healthStatus": "unknown"
},
"spec": {
"networkId": "61f0ad85-3001-41cb-824a-e6a047668dfe",
"platformReleaseId": "nks-1-32-3",
"apiServer": {
"publicIP": false
},
"addons": {
"hardware": {
"enabled": true
},
"nodeHealth": {
"enabled": true
}
}
},
"status": {
"regionId": "uk-lon-1"
}
}{
"error": "invalid_request",
"error_description": "request body invalid",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "access_denied",
"error_description": "authentication failed",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "forbidden",
"error_description": "user credentials do not have the required privileges",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "request_entity_too_large",
"error_description": "request body exceeds the maximum allowed size",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "unprocessable_content",
"error_description": "the request body was in the wrong format",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "server_error",
"error_description": "failed to token claim",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}Clusters
Create cluster
Create a cluster.
POST
/
api
/
v1
/
clusters
Create cluster
curl --request POST \
--url https://nks.nks.europe-west4.nscale.com/api/v1/clusters \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"metadata": {
"name": "production-cluster",
"description": "Production Kubernetes cluster",
"tags": [
{
"name": "environment",
"value": "production"
}
]
},
"spec": {
"networkId": "61f0ad85-3001-41cb-824a-e6a047668dfe",
"platformReleaseId": "nks-1-32-3",
"apiServer": {
"publicIP": false
}
}
}
'import requests
url = "https://nks.nks.europe-west4.nscale.com/api/v1/clusters"
payload = {
"metadata": {
"name": "production-cluster",
"description": "Production Kubernetes cluster",
"tags": [
{
"name": "environment",
"value": "production"
}
]
},
"spec": {
"networkId": "61f0ad85-3001-41cb-824a-e6a047668dfe",
"platformReleaseId": "nks-1-32-3",
"apiServer": { "publicIP": False }
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
metadata: {
name: 'production-cluster',
description: 'Production Kubernetes cluster',
tags: [{name: 'environment', value: 'production'}]
},
spec: {
networkId: '61f0ad85-3001-41cb-824a-e6a047668dfe',
platformReleaseId: 'nks-1-32-3',
apiServer: {publicIP: false}
}
})
};
fetch('https://nks.nks.europe-west4.nscale.com/api/v1/clusters', 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://nks.nks.europe-west4.nscale.com/api/v1/clusters",
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([
'metadata' => [
'name' => 'production-cluster',
'description' => 'Production Kubernetes cluster',
'tags' => [
[
'name' => 'environment',
'value' => 'production'
]
]
],
'spec' => [
'networkId' => '61f0ad85-3001-41cb-824a-e6a047668dfe',
'platformReleaseId' => 'nks-1-32-3',
'apiServer' => [
'publicIP' => false
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://nks.nks.europe-west4.nscale.com/api/v1/clusters"
payload := strings.NewReader("{\n \"metadata\": {\n \"name\": \"production-cluster\",\n \"description\": \"Production Kubernetes cluster\",\n \"tags\": [\n {\n \"name\": \"environment\",\n \"value\": \"production\"\n }\n ]\n },\n \"spec\": {\n \"networkId\": \"61f0ad85-3001-41cb-824a-e6a047668dfe\",\n \"platformReleaseId\": \"nks-1-32-3\",\n \"apiServer\": {\n \"publicIP\": false\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://nks.nks.europe-west4.nscale.com/api/v1/clusters")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"metadata\": {\n \"name\": \"production-cluster\",\n \"description\": \"Production Kubernetes cluster\",\n \"tags\": [\n {\n \"name\": \"environment\",\n \"value\": \"production\"\n }\n ]\n },\n \"spec\": {\n \"networkId\": \"61f0ad85-3001-41cb-824a-e6a047668dfe\",\n \"platformReleaseId\": \"nks-1-32-3\",\n \"apiServer\": {\n \"publicIP\": false\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://nks.nks.europe-west4.nscale.com/api/v1/clusters")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"metadata\": {\n \"name\": \"production-cluster\",\n \"description\": \"Production Kubernetes cluster\",\n \"tags\": [\n {\n \"name\": \"environment\",\n \"value\": \"production\"\n }\n ]\n },\n \"spec\": {\n \"networkId\": \"61f0ad85-3001-41cb-824a-e6a047668dfe\",\n \"platformReleaseId\": \"nks-1-32-3\",\n \"apiServer\": {\n \"publicIP\": false\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"metadata": {
"id": "1e44f19a-21a9-43cc-a460-5d6f21247f65",
"generation": 1,
"name": "production-cluster",
"organizationId": "9a8c6370-4065-4d4a-9da0-7678df40cd9d",
"projectId": "e36c058a-8eba-4f5b-91f4-f6ffb983795c",
"creationTime": "2026-05-14T10:00:00.000Z",
"provisioningStatus": "provisioning",
"healthStatus": "unknown"
},
"spec": {
"networkId": "61f0ad85-3001-41cb-824a-e6a047668dfe",
"platformReleaseId": "nks-1-32-3",
"apiServer": {
"publicIP": false
},
"addons": {
"hardware": {
"enabled": true
},
"nodeHealth": {
"enabled": true
}
}
},
"status": {
"regionId": "uk-lon-1"
}
}{
"error": "invalid_request",
"error_description": "request body invalid",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "access_denied",
"error_description": "authentication failed",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "forbidden",
"error_description": "user credentials do not have the required privileges",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "request_entity_too_large",
"error_description": "request body exceeds the maximum allowed size",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "unprocessable_content",
"error_description": "the request body was in the wrong format",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}{
"error": "server_error",
"error_description": "failed to token claim",
"trace_id": "57bc14d9bd461f0b5a72db830149b67a"
}Authorizations
The access token received from the authorization server in the OAuth 2.0 flow.
Body
application/json
Cluster creation request.
Response
A newly created cluster whose desired state has been persisted but not yet observed.
Was this page helpful?