MarginGate

Security

Last updated 2 December 2026

Your provider keys are never stored

You send your own provider key with each request. MarginGate uses it to forward that one call and then discards it. It is never written to our database, logs or captures, and keys passed in URLs are refused.

MarginGate keys are stored as hashes

We keep only a one-way SHA-256 hash of each MarginGate key. The key itself is shown to you once, when you create it. If a key leaks, revoke it in the dashboard and it stops working immediately.

Each account sees only its own data

Dashboard reads go through database functions that check the signed-in user owns the key, enforced in the database itself (row-level security), not only in the app.

Limits are enforced before the call

The worst-case cost of a call is reserved in the database before the call is sent, inside one transaction. Concurrent calls can't jointly overshoot a budget, and a call that ends abnormally stays held against the budget until it is resolved, so it can never free up money it may have spent.

Captures are opt-in and redacted

Prompts and answers are saved only for keys where you turn capture on. Secrets and keys are redacted before storage; captures are compressed, kept for the 1, 7 or 30 days you choose, then deleted automatically.

Signed webhooks

Alert webhooks are signed with a per-target secret so you can verify they came from us. After a secret rotation, the old and new secrets both sign for 24 hours so you can switch without missing alerts. Webhook addresses must use HTTPS and a public host name; raw IP addresses and local or internal names are refused.

In transit and at rest

All traffic uses HTTPS. Data is stored with Supabase and Cloudflare, which encrypt data at rest. The dashboard sends strict security headers, including a content security policy.

Reporting a problem

If you find a security issue, please email support@margingate.dev with "Security" in the subject. We will reply within 3 business days and keep you updated until it is fixed. Please don't access other people's data or disrupt the Service while testing.