On this page
01
What you'll set up
You will connect one safety service to a guardrail profile, choose what happens if it cannot run, and test that it catches what you expect. Local rules keep running first, so the provider only sees what they let through.
- Content safety on a guardrail profile
- A credential for the provider, or Cloptima-run scanning
- A choice for when the scan cannot run
- A test request that proves it works
You need an existing guardrail profile and an owner or admin role. Content safety comes with AI Growth and Enterprise. It goes in the org baseline or in policy profiles, not both, so each request is checked once.
02
Why add a provider scan
Local rules find credentials and patterns you define. A provider scan adds meaning-aware checks that rules cannot do.
Local rules
- Fast, with no extra network call
- Credentials and patterns you define
- No per-scan cost
Provider scan
- Understands meaning, not just format
- Prompt injection, jailbreaks, harmful content, sensitive information
- Adds a call, and the provider bills for it
1Local rules
A block here skips the scan
2Provider scan
3The model
03
Choose an implementation
Pick the service you already trust. You can use your own cloud account, or let Cloptima run the scan and draw from your AI credits.
| Implementation | Checks | You bring |
|---|---|---|
| Azure AI Content Safety | Prompt Shields on requests, plus every harm category: Hate, SelfHarm, Sexual, Violence | A Content Safety resource and key |
| AWS Bedrock Guardrails | Your guardrail's filters, topics, words, sensitive information, grounding | A guardrail id, version, and region |
| Google Model Armor | Prompt injection, responsible-AI filters, malicious URLs, sensitive data | A template and a service account |
| Webhook | Whatever your service checks | An HTTPS endpoint |
04
Turn on content safety
Open the profile in AI → Guardrails and choose Edit. Switch on Content safety, and choose the Implementation. The rest of the form changes to match.
- Content safety
- Checks requests and responses for harmful content and blocks it. The check sees text after your data rules redact it. Content safety goes in the org baseline or in policy profiles, not both, so a request is checked once.On
- Implementation
- Webhook
- Webhook auth credential
- No authentication
- Webhook URL
- https://guardrail.example.com/scan
05
Azure AI Content Safety
Create a Content Safety resource in Azure and copy its endpoint and a key.
- 1
Add an Azure credential
In the profile, add an Azure credential with the endpoint and key.
- 2
Enter the Content Safety endpoint
It must match the credential's endpoint, use HTTPS, and end in .cognitiveservices.azure.com, .cognitiveservices.azure.us, or .cognitiveservices.azure.cn.
Cloptima runs every Azure check for you: Prompt Shields on requests, against jailbreak and prompt-injection attacks, and every harm category on requests and responses.
06
AWS Bedrock Guardrails
In AWS, create a guardrail and a version. You can use DRAFT or a numbered version.
- 1
Add a Bedrock credential
Use AWS access credentials that are allowed to apply the guardrail.
- 2
Enter the details
Provide the AWS region, the Guardrail ID, and the Guardrail version.
07
Google Model Armor
In Google Cloud, enable the Model Armor API and create a template with the filters you want.
- 1
Create a service account
Give it Model Armor User access on the template's project.
- 2
Add the service account key
Add it as a Google service account credential in the profile.
- 3
Paste the template name
Use the form projects/PROJECT/locations/REGION/templates/NAME.
08
Your own webhook
A webhook is the most flexible option. Host an HTTPS endpoint on a public address. The gateway sends the text and which direction it came from, and expects a yes or no.
POST https://guardrails.example.com/check
{ "text": "...", "direction": "input", "request_id": "..." }
200 OK
{ "allowed": false, "category": "confidential", "confidence": 0.92 }from fastapi import FastAPI
app = FastAPI()
@app.post("/check")
def check(body: dict):
flagged = "confidential" in body["text"].lower()
return {"allowed": not flagged, "category": "confidential" if flagged else None}- The address must use HTTPS and be reachable on the public internet
- A reply without a true or false allowed field counts as a failure
- To authenticate calls, add a webhook auth credential and name the header. The default header is Authorization.
09
Let Cloptima run the scan
Instead of your own vendor, you can choose Cloptima-managed content safety: Cloptima runs it in its own accounts, and the scan is billed to your AI credits.
- You need AI credits available
- You do not need a cloud account with the provider
- Scans use Cloptima's resource, so you cannot choose a custom guardrail id or template
10
What it checks and what it does
Content safety checks your requests and responses as they pass through the gateway, and blocks what it flags. It sees the text after your data rules redact it.
| What | What is checked | On a finding |
|---|---|---|
| Requests | The new message, after your data rules | The request is refused before it reaches the model |
| Responses | The answer, and streamed answers in short batches | The answer stops before your user sees the rest |
To mask text in place, use a Redact rule in the profile. Under a policy in Monitor only, findings are recorded instead of blocked, except in the org baseline profile, which always enforces.
In the same section, If the scan can't run chooses what a request does when the provider cannot be reached: continue on your local rules, or block the request.
11
Test it
Send a request the provider should flag, then confirm the result.
- 1
Send a test prompt
Use content your provider is configured to flag. For a webhook, use text your handler rejects.
- 2
Check the response
You should see HTTP 403 and the reason gateway_guardrail_blocked. The violation name starts with guardrail_provider_.
- 3
Check the audit log
Provider findings under a policy in Monitor only appear there.
12
If something goes wrong
Most problems are credentials or endpoints.
| What you see | Likely cause | Fix |
|---|---|---|
| Requests show as Not checked in Audit | The provider timed out, rejected the call, or the credential is unusable. Requests continue on your local rules meanwhile, unless the profile blocks | Follow the fix Audit shows for the cause, then check the credential and endpoint |
| The profile will not save | The credential type does not match the provider, or an Azure endpoint does not match the credential | Use the credential type for that provider and the same endpoint |
| The profile will not save with content safety | The org baseline, or a profile a policy uses, already has content safety | Keep content safety in the baseline or in policy profiles, not both |
| Nothing is ever flagged | Local rules block first, or the provider's own filters do not cover the content | Check the provider's filter settings, and test with content only the provider flags |