Credentials. Tenant keys are bearer credentials, so distribute each one only to the team it belongs to and rotate it if it leaks.
Who it is forA team lead or platform owner who must keep AI spend within a monthly amount and stop runaway loops.
The problemA runaway loop or heavy workload can produce a large bill that nobody notices until it arrives.
The outcomeEach tenant has its own key and limits, so calls are blocked before they exceed the ceiling or budget.
What you need first
- Docker with Docker Compose, curl, and jq, or Go and Make for the native build
- At least one provider API key such as OPENAI_API_KEY or ANTHROPIC_API_KEY in .env
- A host with ports 8080 and 3000 free, or a changed GATEWAY_PORT
Steps
- Run
./scripts/deploy.shto start the stack, then sign in to the dashboard at the URL the script prints. - Create one tenant per team in the dashboard and set daily or monthly budgets and token or request rate limits.
- Mint a separate key per tenant with
curl -s $GATEWAY/admin/v1/keys -H "Authorization: Bearer $SYNAPASS_ADMIN_KEY"and the tenant id. (inferred, check the README) - Set a per-request cost ceiling in a policy, then run
bash scripts/smoke.shto check the stack end to end.
Prompt for your agent
In the ShadowSafin/Synapass repo, create a tenant named <team_name> with a daily budget and a rate limit through the dashboard or admin API, then mint one key for it. Report the tenant id and confirm that a request above the configured ceiling is refused. Verify the refusal in the response before reporting success.
Caveat. The README names budgets and ceilings as features but does not show the exact dashboard steps or limit fields, so confirm the settings in the Dashboard documentation before you rely on them.
Get 5 new use cases every morning. Free, one short email, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Disclaimer
Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked "Seen in the wild", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email [email protected] and we will look at it promptly. Full disclaimer page