> ## Documentation Index
> Fetch the complete documentation index at: https://usefoil.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# What is Gate?

> Learn how Foil Gate enables agentic signup, letting AI coding agents create accounts and log in on behalf of developers with hosted consent and bot detection.

Gate is a hosted signup service that lets developers create accounts for your product using coding agents (Claude Code, Cursor, Codex). Instead of filling out a web form, developers run a single command:

```bash theme={"dark"}
npx signup yourproduct
```

A browser window opens for human consent (scored by Foil for bot detection), and API keys are delivered directly to the developer's `.env` file.

## How it works

```
Developer runs:  npx signup yourproduct
                    ↓
CLI opens browser → Consent page (Foil-scored)
                    ↓
User clicks Approve → Gate calls your webhook
                    ↓
Your webhook creates account → Returns credentials
                    ↓
Gate issues agent token + delivers credentials → .env
```

## What Gate handles

* **Consent UI** — hosted, branded consent page with your logo, colors, and ToS
* **Bot detection** — every signup is scored by Foil. Bots are blocked automatically.
* **Agent tokens** — Gate issues `agt_` tokens that authenticate all post-signup interactions
* **Credential delivery** — encrypted handoff of API keys to the CLI
* **Dashboard login** — `npx signup yourproduct login` opens your dashboard via magic link

## What you handle

* **Account creation** — your webhook creates the account in your system
* **API key issuance** — your webhook returns whatever credentials the developer needs
* **Dashboard auth** — one route on your server to verify Gate's magic link tokens

## Relationship to Foil

Gate uses Foil's browser agent detection to score every signup. You don't need to integrate Foil separately — Gate handles it. However, the API keys Gate delivers can be for any product, not just Foil.

## What's next

* [Add Gate to your product](/gate/add-gate) — step-by-step integration guide
* [CLI reference](/gate/cli-reference) — all `npx signup` commands
