Workspace
List workspace keys
The workspace’s tenant-scoped keys — the primary and the named ps_workspace_ ones — masked, never the raw key. Owner or Admin in that workspace (apikeys:read). Not a member, or a workspace that does not exist or is archived: the same 403 WORKSPACE_MEMBERSHIP_REQUIRED. Number keys are listed on GET /v1/api-keys.
Requires an account key (ps_account_, created in Profile → API). Workspace keys, number keys and OAuth/MCP tokens get 403 ACCOUNT_KEY_REQUIRED. Sent with Cache-Control: no-store.
GET
/
v1
/
workspaces
/
{workspaceId}
/
api-keys
List workspace keys
curl --request GET \
--url https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys \
--header 'x-api-key: <api-key>'import requests
url = "https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys', 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://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "cmh2aa0010003ak8example4d",
"name": "Workspace API Key",
"prefix": "ps_workspace_",
"last4": "3b5d",
"isPrimary": true,
"createdAt": "2026-10-28T09:15:00.000Z",
"lastUsedAt": "2026-10-28T09:20:11.000Z"
},
{
"id": "cmh2ab7770004ak8example9m",
"name": "Billing integration",
"prefix": "ps_workspace_",
"last4": "a1c0",
"isPrimary": false,
"createdAt": "2026-10-28T09:15:00.000Z",
"lastUsedAt": null
}
]
}{
"error": "Invalid API key"
}{
"error": "This endpoint requires an account API key (ps_account_…), created in Profile → API. Workspace keys, number keys and OAuth tokens cannot use it | Este endpoint exige uma API key de conta (ps_account_…), criada em Perfil → API. Chaves de workspace, de número e tokens OAuth não podem usá-lo",
"code": "ACCOUNT_KEY_REQUIRED"
}Was this page helpful?
⌘I
List workspace keys
curl --request GET \
--url https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys \
--header 'x-api-key: <api-key>'import requests
url = "https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys', 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://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://pilotstatus.com.br/v1/workspaces/{workspaceId}/api-keys")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "cmh2aa0010003ak8example4d",
"name": "Workspace API Key",
"prefix": "ps_workspace_",
"last4": "3b5d",
"isPrimary": true,
"createdAt": "2026-10-28T09:15:00.000Z",
"lastUsedAt": "2026-10-28T09:20:11.000Z"
},
{
"id": "cmh2ab7770004ak8example9m",
"name": "Billing integration",
"prefix": "ps_workspace_",
"last4": "a1c0",
"isPrimary": false,
"createdAt": "2026-10-28T09:15:00.000Z",
"lastUsedAt": null
}
]
}{
"error": "Invalid API key"
}{
"error": "This endpoint requires an account API key (ps_account_…), created in Profile → API. Workspace keys, number keys and OAuth tokens cannot use it | Este endpoint exige uma API key de conta (ps_account_…), criada em Perfil → API. Chaves de workspace, de número e tokens OAuth não podem usá-lo",
"code": "ACCOUNT_KEY_REQUIRED"
}