OAuth 2.0 Callback URLs with AgentDomains
Register stable HTTPS redirect URIs (https://oauth-stage.agentdomains.co/auth/callback) for Google, GitHub, Discord, and Slack OAuth apps.
OAuth providers reject random tunnel URLs and require pre-registered exact HTTPS redirect URIs. Keeping one stable AgentDomains hostname lets you swap underlying cloud/tunnel origins without editing OAuth apps.
1. 3-Stage Sequence Diagram
3-stage sequence: AI agent claims oauth-stage.agentdomains.co, maps it to auth-stage.up.railway.app, and verifies HTTPS 200 OK.
2. 4-Step MCP Tool-Call Transcript
Your agent sends these exact calls to https://mcp.agentdomains.co or local stdio.
{
"tool": "check_availability",
"arguments": {
"label": "oauth-stage",
"domain": "agentdomains.co"
}
}
// Response:
{
"fqdn": "oauth-stage.agentdomains.co",
"available": true,
"reason": "available"
}
{
"tool": "claim_domain",
"arguments": {
"label": "oauth-stage",
"domain": "agentdomains.co",
"email": "ops@example.com"
}
}
// Response:
{
"fqdn": "oauth-stage.agentdomains.co",
"status": "claimed",
"confirm_within_days": 30
}
{
"tool": "set_proxy",
"arguments": {
"label": "oauth-stage",
"domain": "agentdomains.co",
"origin": "auth-stage.up.railway.app"
}
}
// Response:
{
"ok": true,
"fqdn": "oauth-stage.agentdomains.co",
"origin": "auth-stage.up.railway.app",
"https": "https://oauth-stage.agentdomains.co"
}
curl -fsSI https://oauth-stage.agentdomains.co
# HTTP/2 200
# content-type: application/json
# strict-transport-security: max-age=31536000
3. Clean Teardown (GitHub Action & CLI)
Remember to remove unused redirect URIs from your OAuth provider before deleting the subdomain. Delete the DNS mapping before you destroy your cloud server to block dangling takeovers.
name: Teardown oauth-stage
on:
workflow_dispatch:
pull_request:
types: [closed]
jobs:
cleanup:
runs-on: ubuntu-latest
steps:
- name: Delete AgentDomains hostname before destroying compute
env:
AGENTDOMAINS_API_KEY: ${{ secrets.AGENTDOMAINS_API_KEY }}
run: |
curl -fsSL -X DELETE \
-H "Authorization: Bearer $AGENTDOMAINS_API_KEY" \
"https://api.agentdomains.co/v1/subdomains/oauth-stage?domain=agentdomains.co"
# Or with the Go CLI:
# agentdomains delete oauth-stage --domain agentdomains.co
More Workflow Blueprints
Ephemeral Pull-Request Previews
Spin up pr-142-web.makes.fyi automatically when a GitHub PR opens and delete it cleanly on merge.
Remote MCP Server Hosting
Publish your own Streamable HTTP MCP server over trusted HTTPS (https://my-mcp-srv.agentdomains.co) so Claude, Cursor, and ChatGPT can connect.
Hackathon Demo URLs
Claim a short demo domain in 10 seconds during a hackathon. Free for 30 days with no card.
AI InferenceLocal LLM API Endpoint
Point an A record at your Ollama or vLLM box behind Caddy. Call your private API over HTTPS.
Claim your agent domain now
Start with 10 free HTTPS domains under agentdomains.co or makes.fyi for 30 days. Upgrade to Pro for $10/year to keep up to 100 names with visitor stats.