AgentPort - Open-Source Security Gateway for AI Agents
AgentPort lets you connect AI agents to Stripe, GitHub, Gmail and 50+ services with approval policies, full audit logs, and zero credential exposure.
TL;DR
TL;DR: AgentPort is an open-source gateway that connects AI agents to external services (Stripe, GitHub, Gmail, etc.) with granular approval policies, full audit logs, and API keys hidden from agents.
What Is AgentPort?
AgentPort is an open-source security gateway for AI agents. It sits between your agents and the external services they need to call — Stripe, PostHog, GitHub, Gmail, Google Calendar, and 50+ more — and enforces three approval policies per tool: Auto-approve, Ask for approval, or Deny.
The core problem it solves: today’s agents either get full access to a service or none at all. AgentPort lets you give an agent search_emails freely but require a human click before send_email. Agents never see your API keys. Every call is logged.
“Connect all of your agents to everything they need.” — github.com/yakkomajuri/agentport
Setup Workflow
Prerequisites
- Docker (for local deployment) or a Linux server (for self-hosting)
- An AI agent or claw (e.g., OpenClaw-compatible)
Step 1: Try Locally with Docker
git clone https://github.com/yakkomajuri/agentport
cd agentport
docker compose up
The web UI starts at http://localhost and the MCP server at http://localhost:4321/mcp by default.
Step 2: Connect an Agent via MCP
In your agent’s config, point its MCP endpoint to:
https://app.agentport.sh/mcp
Or, for self-hosted deployments: https://<your-domain>/mcp.
Step 3: Add Your First Integration
- Open the AgentPort dashboard
- Click Integrations → choose a service (e.g., Stripe, GitHub)
- Authenticate with OAuth or API key
- Set per-tool policies (Auto-approve / Ask for approval / Deny)
- Your agent can now see and call those tools
Step 4: Production Self-Hosted Deploy
curl -fsSL https://install.agentport.sh | sh
See the full self-hosting docs for nginx, systemd, and cloud deployment options.
Deeper Analysis
How Approval Policies Work
When a tool is set to “Ask for approval”, the agent receives a response saying the call is gated, along with a direct link you can open to approve or deny. Crucially, you approve the exact parameters — so if the agent tries to call create_refund with customerId=1234, amount=15, it cannot later change those values.
Credential Isolation
Agents authenticate with AgentPort, not directly with third-party services. AgentPort stores credentials in its own secrets vault. Your agent’s API keys never reach the agent’s context window.
Logs and Auditability
Every tool call is logged with: timestamp, tool name, parameters, requesting IP, approving IP (if applicable), and approval status. This gives you a full audit trail for compliance and debugging.
Connecting via CLI
npm install -g agentport-cli
agentport connect
Installing AgentPort Skills for Agents
npx skills add yakkomajuri/agentport-skills
This gives your agent the context it needs to use AgentPort tools effectively.
Practical Evaluation Checklist
- [ ] Local Docker setup works (
docker compose up) - [ ] MCP endpoint is reachable from your agent
- [ ] At least one integration (Stripe/GitHub) connected
- [ ] Approval policy correctly gates sensitive tools
- [ ] Audit log shows a tool call after testing
- [ ] Self-hosted install script runs on a clean Linux VM
Security Notes
- API keys are stored server-side and never exposed to the agent
- Approval links contain exact parameters — agents cannot escalate privileges after approval
- All activity is logged; logs are queryable for compliance reviews
- MIT licensed — github.com/yakkomajuri/agentport
FAQ
Q: Does this work with any AI agent or only OpenClaw-compatible ones? A: AgentPort exposes a generic MCP server and a CLI. Any agent that supports MCP or CLI-based tool calling can use it.
Q: How is this different from giving an agent API keys directly? A: Direct API keys live in the agent’s context and get exposed to the model. AgentPort stores credentials server-side, enforces per-tool policies, logs everything, and lets you revoke access instantly without rotating keys.
Q: What happens when I set a tool to “Ask for approval”? A: The agent receives a structured response with an approval URL. You open that link, review the exact parameters, and approve or deny. The agent waits until you respond.
Q: Is there a hosted/cloud version? A: Yes — app.agentport.sh. Self-hosting is also fully supported.
Conclusion
AgentPort solves the all-or-nothing credential problem for AI agents. Instead of choosing between full API access and none, you get per-tool granularity, human-in-the-loop approvals, full audit logs, and zero credential exposure to the model. If you’re deploying autonomous agents that touch payment processors, email, calendars, or any sensitive API, AgentPort is worth adding to your stack.
Source and Accuracy Notes
- Project page: agentport.sh
- Source repository: github.com/yakkomajuri/agentport
- License: MIT (verified via GitHub API)
- HN launch thread: news.ycombinator.com/item?id=47950752
- Docs: docs.agentport.sh
- Source last checked: 2026-08-03 (commit pushed 2026-06-01, stars 29)
Related Posts
ai-setup
Recall – Persistent Memory for Claude Code via MCP Hooks
Recall gives Claude Code a permanent memory store that survives session restarts and context compaction. Four hooks capture and restore context automatically — with cloud SaaS or self-hosted options.
2/28/2026
dev-tools
awesome-agentic-ai-zh Roadmap Guide
Explore awesome-agentic-ai-zh as a Chinese agentic AI learning roadmap, with setup notes, track selection, study workflow, and evaluation guidance.
5/28/2026
dev-tools
Photo-agents Setup and Privacy Guide
Evaluate Photo-agents for image-agent workflows, including license keys, Python isolation, sample-image testing, metadata checks, and batch safety.
5/28/2026