curl --request GET \
--url https://{host}/api/versionimport requests
url = "https://{host}/api/version"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{host}/api/version', 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://{host}/api/version",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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 := "https://{host}/api/version"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{host}/api/version")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/api/version")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyWhat this control plane is, and which JobSpec dialect it speaks.
api is the field that matters: server and core are for support tickets, but the
contract version is what decides whether a given CLI can submit here at all.
edition rides along because it is the same kind of fact — what is this
deployment — and because the console shows it beside the version in the
sidebar, where everybody can see it rather than only an administrator. It is
not a secret: the licence scheme, the plan table and the whole commercial
directory are published in this repository, and the version number already
here tells a stranger more.
Read per request rather than through _versions’s cache: a licence pasted
into the admin page takes effect on the next request, and a cached edition
would keep saying “community” until somebody restarted the process — which
is exactly the half-state the per-request entitlement check exists to avoid.
curl --request GET \
--url https://{host}/api/versionimport requests
url = "https://{host}/api/version"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{host}/api/version', 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://{host}/api/version",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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 := "https://{host}/api/version"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{host}/api/version")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/api/version")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body响应
Successful Response