/v1/guard. When you create or open a collector in the console,
its side panel shows the exact steps and a ready-to-paste snippet for the integration you
picked. This section documents each one.
Gateway
Enforce at the AI gateway. TrustGate is first-class; Portkey, LiteLLM, Kong, Apigee,
and Azure APIM are supported.
Application
Wrap model calls in your app with the Python / Node SDKs, middleware, or the REST API.
Browser
Monitor AI web apps from a managed Chrome / Edge / Firefox extension.
Edge / WAF
Run at the CDN edge: Cloudflare Workers, CloudFront Lambda@Edge, Fastly, Akamai.
The call is always the same
Every integration makes one call:Two rules for every integration
- Create the API key on the collector’s Auth tab and pass it as
Authorization: Bearer <key>. - Always send
consumer_idandsession_idwhen you have them. They attribute findings to the right user and conversation in Activity and power the multi-turn and behavioral detectors. Each snippet shows the natural source on its platform (auth context, headers, cookies).
SDKs
For application code, prefer the official TrustGuard SDKs over hand-rolled HTTP — they take the base URL and call/v1/guard for you:
| Language | Package |
|---|---|
| Node / TypeScript | @neuraltrust/trustguard-sdk |
| Python | neuraltrust-trustguard (import from trustguard import TrustGuard) |
| Go | github.com/NeuralTrust/trustguard-sdk/go |
Run several at once
You can run multiple collectors simultaneously (e.g. gateway + browser). Each has its own key and detector chain, and behavioral signals correlate across them byconsumer_id.