List network secrets
curl --request GET \
--url https://controller.platform.simplecloud.app/v0/networks/secrets \
--header 'Content-Type: application/json' \
--header 'X-Network-ID: <x-network-id>' \
--header 'X-Network-Secret: <x-network-secret>' \
--data '{}'import requests
url = "https://controller.platform.simplecloud.app/v0/networks/secrets"
payload = {}
headers = {
"X-Network-ID": "<x-network-id>",
"X-Network-Secret": "<x-network-secret>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Network-ID': '<x-network-id>',
'X-Network-Secret': '<x-network-secret>',
'Content-Type': 'application/json'
},
body: JSON.stringify({})
};
fetch('https://controller.platform.simplecloud.app/v0/networks/secrets', 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://controller.platform.simplecloud.app/v0/networks/secrets",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Network-ID: <x-network-id>",
"X-Network-Secret: <x-network-secret>"
],
]);
$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://controller.platform.simplecloud.app/v0/networks/secrets"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("GET", url, payload)
req.Header.Add("X-Network-ID", "<x-network-id>")
req.Header.Add("X-Network-Secret", "<x-network-secret>")
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.get("https://controller.platform.simplecloud.app/v0/networks/secrets")
.header("X-Network-ID", "<x-network-id>")
.header("X-Network-Secret", "<x-network-secret>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://controller.platform.simplecloud.app/v0/networks/secrets")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Network-ID"] = '<x-network-id>'
request["X-Network-Secret"] = '<x-network-secret>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"count": 5,
"secrets": [
{
"created_at": "2023-01-01T12:00:00Z",
"name": "api-key-1",
"secret_id": "123e4567-e89b-12d3-a456-426614174000"
}
]
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}networks
List network secrets
List all network secrets for the authenticated network
GET
/
v0
/
networks
/
secrets
List network secrets
curl --request GET \
--url https://controller.platform.simplecloud.app/v0/networks/secrets \
--header 'Content-Type: application/json' \
--header 'X-Network-ID: <x-network-id>' \
--header 'X-Network-Secret: <x-network-secret>' \
--data '{}'import requests
url = "https://controller.platform.simplecloud.app/v0/networks/secrets"
payload = {}
headers = {
"X-Network-ID": "<x-network-id>",
"X-Network-Secret": "<x-network-secret>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Network-ID': '<x-network-id>',
'X-Network-Secret': '<x-network-secret>',
'Content-Type': 'application/json'
},
body: JSON.stringify({})
};
fetch('https://controller.platform.simplecloud.app/v0/networks/secrets', 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://controller.platform.simplecloud.app/v0/networks/secrets",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Network-ID: <x-network-id>",
"X-Network-Secret: <x-network-secret>"
],
]);
$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://controller.platform.simplecloud.app/v0/networks/secrets"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("GET", url, payload)
req.Header.Add("X-Network-ID", "<x-network-id>")
req.Header.Add("X-Network-Secret", "<x-network-secret>")
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.get("https://controller.platform.simplecloud.app/v0/networks/secrets")
.header("X-Network-ID", "<x-network-id>")
.header("X-Network-Secret", "<x-network-secret>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://controller.platform.simplecloud.app/v0/networks/secrets")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Network-ID"] = '<x-network-id>'
request["X-Network-Secret"] = '<x-network-secret>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"count": 5,
"secrets": [
{
"created_at": "2023-01-01T12:00:00Z",
"name": "api-key-1",
"secret_id": "123e4567-e89b-12d3-a456-426614174000"
}
]
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}Was this page helpful?
⌘I