Returns the projects whose effective allowlist would become empty if the given organization allowlist policy is saved, so an admin is warned before tightening a tool or model allowlist to a disjoint set. Non-allowlist or disabled policies have no blast radius.
Body
Required
Proposed org policy
-
Whether the proposed policy would be enforced. Defaults to true when omitted, matching policy creation.
-
Values are
MAX_TOOL_CALLS_PER_EXECUTION,MAX_LLM_CALLS_PER_EXECUTION,MAX_EXECUTION_DURATION_MS,MAX_TOKENS_PER_EXECUTION,MAX_TOKENS_PER_SESSION,AUTHORIZED_TOOLS, orAUTHORIZED_MODELS.
Responses
-
Unsupported or malformed API version, an operation unavailable in the selected published contract, or an unacceptable representation (including unsupported media-type parameters or excluded SSE). Existing authentication, authorization, and rate-limit failures take precedence.
-
OK
-
Bad Request
-
Forbidden
-
Internal Server Error
curl \
--request POST 'https://agentengine.mongodb.com/api/v1/organizations/{id}/policies/preview' \
--header "Authorization: $API_KEY" \
--header "Content-Type: application/json" \
--data '{
"enabled": true,
"string_list": [
"string"
],
"type": "MAX_TOOL_CALLS_PER_EXECUTION"
}'
{
"enabled": true,
"string_list": [
"string"
],
"type": "MAX_TOOL_CALLS_PER_EXECUTION"
}
{
"detail": "This operation is not available in API version 2026-09-20-preview.",
"error": 406,
"errorCode": "OPERATION_NOT_IN_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "This operation supports text/event-stream, which the Accept header excludes. Remove unsupported media-type parameters or accept this type with a positive q value.",
"error": 406,
"errorCode": "UNACCEPTABLE_MEDIA_TYPE",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "The requested API version is not supported. Supported versions: 2026-09-20-preview.",
"error": 406,
"errorCode": "UNSUPPORTED_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "This operation is not available in API version 2026-09-20-preview.",
"error": 406,
"errorCode": "OPERATION_NOT_IN_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"affected_projects": [
{
"current_allowlist": [
"string"
],
"project_id": "string",
"project_name": "string"
}
]
}
{
"affected_projects": [
{
"current_allowlist": [
"string"
],
"project_id": "string",
"project_name": "string"
}
]
}
{
"code": "string",
"error": "string",
"success": true
}
{
"code": "string",
"error": "string",
"success": true
}
{
"code": "string",
"error": "string",
"success": true
}
{
"code": "string",
"error": "string",
"success": true
}
{
"code": "string",
"error": "string",
"success": true
}
{
"code": "string",
"error": "string",
"success": true
}