cURL
curl --request GET \ --url https://rai-prod.studio.lyzr.ai/v1/rai/policies \ --header 'x-api-key: <api-key>'
{ "policies": [ { "_id": "<string>", "name": "<string>", "description": "<string>", "allowed_topics": { "enabled": true, "topics": [ "<string>" ] }, "banned_topics": { "enabled": true, "topics": [ "<string>" ] }, "keywords": { "enabled": true, "keywords": [ "<string>" ] }, "toxicity_check": { "enabled": true, "threshold": 123 }, "prompt_injection": { "enabled": true, "threshold": 123 }, "secrets_detection": { "enabled": true, "action": "<string>" }, "pii_detection": { "enabled": true, "types": {}, "custom_pii": [ "<string>" ] }, "user_id": "<string>", "created_at": "2023-11-07T05:31:56Z", "updated_at": "2023-11-07T05:31:56Z" } ] }
Get all RAI policies for the authenticated user.
/v1/rai/policies
https://rai-prod.studio.lyzr.ai
x-api-key
curl -X GET "https://rai-prod.studio.lyzr.ai/v1/rai/policies" \ -H "accept: application/json" \ -H "x-api-key: sk-default-REDACTED"
Successful Response
Show child attributes