curl --request GET \
--url https://api.onecli.sh/v1/policy/effective-app-permissions \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.onecli.sh/v1/policy/effective-app-permissions"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.onecli.sh/v1/policy/effective-app-permissions', 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.onecli.sh/v1/policy/effective-app-permissions",
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.onecli.sh/v1/policy/effective-app-permissions"
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.onecli.sh/v1/policy/effective-app-permissions")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.onecli.sh/v1/policy/effective-app-permissions")
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{
"provider": "<string>",
"basis": {
"agentId": "<string>",
"credentialAttached": true,
"scope": "organization"
},
"variesByIdentity": 123,
"groups": [
{
"category": "read",
"verdict": "allow",
"tools": [
{
"toolId": "<string>",
"verdict": "allow",
"rateLimit": 123,
"rateLimitWindow": "<string>",
"decidedBy": {
"scope": "organization",
"redacted": true,
"rule": {
"logicalId": "<string>",
"name": "<string>"
}
},
"orgCeiling": "allow"
}
]
}
]
}Effective app permissions (project)
What the enforced policy actually allows for an app, per tool — a read-only reflection of the compiled grants plus organization rules, not an editor. Project-level access is written through the Grants endpoints; organization guardrails through /org/policy/*.
Omit agentId for the all-agents baseline. Pass connectionId to reflect one specific account when several accounts of the app are connected. variesByIdentity counts identity-scoped rules the baseline cannot show. Each tool’s orgCeiling reports what the organization level alone would decide — the value a project grant can never exceed. An organization rule’s name is visible only to organization admins; other viewers receive redacted: true.
curl --request GET \
--url https://api.onecli.sh/v1/policy/effective-app-permissions \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.onecli.sh/v1/policy/effective-app-permissions"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.onecli.sh/v1/policy/effective-app-permissions', 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.onecli.sh/v1/policy/effective-app-permissions",
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.onecli.sh/v1/policy/effective-app-permissions"
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.onecli.sh/v1/policy/effective-app-permissions")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.onecli.sh/v1/policy/effective-app-permissions")
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{
"provider": "<string>",
"basis": {
"agentId": "<string>",
"credentialAttached": true,
"scope": "organization"
},
"variesByIdentity": 123,
"groups": [
{
"category": "read",
"verdict": "allow",
"tools": [
{
"toolId": "<string>",
"verdict": "allow",
"rateLimit": 123,
"rateLimitWindow": "<string>",
"decidedBy": {
"scope": "organization",
"redacted": true,
"rule": {
"logicalId": "<string>",
"name": "<string>"
}
},
"orgCeiling": "allow"
}
]
}
]
}Authorizations
API key obtained from the dashboard or GET /user/api-key
Query Parameters
App provider, e.g. gmail.
Narrow to one agent's identity.
Reflect one specific account (connection) of the app.