When You Need Routes
Common use cases:- Your agent runs a web app (React, Vue, etc.) and you want users to access it
- Your agent exposes an API that other services need to call
- You’re running a dev server with hot reload and need external access
Add a Route
Open your agent → Routes → ADD. You have two options: Path Route or Custom Domain.Path Routes
Path routes are the simplest option. Your service becomes available at a URL like:- Click ADD → Path Route
- Enter a path prefix (like
/appor/api) - Enter the port your service runs on inside the container
- Choose whether it’s protected or public
- Save
/app/users/123, your service sees /users/123.
Custom Domains
Custom domains are currently in beta.
swift-fox-347.apps.pinata.cloud) or let you use your own domain.
For a Pinata subdomain:
- Click ADD → Custom Domain → Pinata Subdomain
- Enter the port
- Choose protected or public
- Save — you’ll get a random subdomain instantly
- Click ADD → Custom Domain → Bring Your Own
- Enter your domain (like
app.yourdomain.com) - Enter the port
- Save
- Add the DNS records shown (a TXT record for verification, then a CNAME)
Protected vs Public
Protected routes require a gateway token to access. Use this when you want to control who can reach your service. Public routes are open to anyone on the internet. Only use this if your service handles its own authentication, or if you genuinely want it public.Limits
- Up to 10 path routes per agent
- Up to 5 custom domains per agent
- Ports must be between 1025 and 65535 (port 18789 is reserved)