List Service Keys
curl --request GET \
--url https://api.peachdeskai.com/api/v1/admin/service-keys \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.peachdeskai.com/api/v1/admin/service-keys"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.peachdeskai.com/api/v1/admin/service-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://api.peachdeskai.com/api/v1/admin/service-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 => [
"Authorization: Bearer <token>"
],
]);
$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://api.peachdeskai.com/api/v1/admin/service-keys"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.peachdeskai.com/api/v1/admin/service-keys")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.peachdeskai.com/api/v1/admin/service-keys")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"id": 123,
"organization_id": 123,
"key_prefix": "<string>",
"tier_name": "<string>",
"reserved_concurrent_slots": 123,
"commitment_months": 123,
"used_minutes_this_month": 123,
"is_active": true,
"created_at": "2023-11-07T05:31:56Z",
"name": "<string>",
"overage_rate_usd_per_min_override": "<string>",
"included_minutes_per_month_override": 123,
"addons": {},
"floor_override_reason": "<string>",
"floor_override_approved_by": 123,
"month_anchor": "2023-12-25",
"last_used_at": "2023-11-07T05:31:56Z",
"expires_at": "2023-11-07T05:31:56Z",
"revoked_at": "2023-11-07T05:31:56Z",
"created_by": 123
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}main
List Service Keys
List the service keys belonging to one organization.
organization_id is required and scopes the query at the DB layer —
a key issued to one org never leaks into another org’s listing
(tenant isolation, see api/AGENTS.md Organization Scoping).
GET
/
api
/
v1
/
admin
/
service-keys
List Service Keys
curl --request GET \
--url https://api.peachdeskai.com/api/v1/admin/service-keys \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.peachdeskai.com/api/v1/admin/service-keys"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.peachdeskai.com/api/v1/admin/service-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://api.peachdeskai.com/api/v1/admin/service-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 => [
"Authorization: Bearer <token>"
],
]);
$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://api.peachdeskai.com/api/v1/admin/service-keys"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.peachdeskai.com/api/v1/admin/service-keys")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.peachdeskai.com/api/v1/admin/service-keys")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"id": 123,
"organization_id": 123,
"key_prefix": "<string>",
"tier_name": "<string>",
"reserved_concurrent_slots": 123,
"commitment_months": 123,
"used_minutes_this_month": 123,
"is_active": true,
"created_at": "2023-11-07T05:31:56Z",
"name": "<string>",
"overage_rate_usd_per_min_override": "<string>",
"included_minutes_per_month_override": 123,
"addons": {},
"floor_override_reason": "<string>",
"floor_override_approved_by": 123,
"month_anchor": "2023-12-25",
"last_used_at": "2023-11-07T05:31:56Z",
"expires_at": "2023-11-07T05:31:56Z",
"revoked_at": "2023-11-07T05:31:56Z",
"created_by": 123
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Interactive user session: the login JWT, sent as Authorization: Bearer <token>.
Query Parameters
Filter to this org's keys
Response
Successful Response
First 12 characters of the key (e.g. 'pk_live_abcd'). Safe to display in the UI for identification.
Pattern:
^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
