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

# set up API with your AI agent

> a copy-paste prompt for Claude Code, Codex, Cursor, and ChatGPT to set up the edgeful API securely, install the dashboard skill, and verify a live request.

use this page when you want an AI agent to configure the edgeful API in a local project. it takes you from zero to a working, verified connection, and you only ever paste your key into a local `.env` file, never into the chat.

<Warning>
  heads up: you can't do this in a chat window. claude.ai and chatgpt.com are chat interfaces, they can't run commands, call APIs, or touch files on your computer. you need a coding agent running on your machine.
</Warning>

you'll need two things: a coding agent on your machine, and an edgeful API key (we'll point you to it below).

<Steps>
  <Step title="get a coding agent running">
    you need a coding agent on your machine — Claude Code, Codex, Cursor, or similar. **already have one running? skip to step 2.**

    never installed one, or only ever used AI in a browser? start with [never used AI?](/getting-started/never-used-ai) — it walks you through setting one up in about 10 minutes, then sends you back here for step 2.
  </Step>

  <Step title="paste the prompt">
    paste this into your running agent. it points the agent at a prompt-only setup page, so it does not need to parse this human guide. the agent does the whole job — creating a local `.env`, installing the dashboard skill, and making a verified first call.

    ```text prompt — paste into your agent theme={null}
    Set up the edgeful API for me. Read https://www.edgeful.com/docs/getting-started/ai-agent-setup-prompt and follow the instructions there.
    ```

    the full agent prompt is also available at [ai-agent-setup-prompt](/getting-started/ai-agent-setup-prompt). it is intentionally not in the sidebar.
  </Step>

  <Step title="add your API key">
    the prompt sets up everything except your API key, that part's on you. the agent creates a `.env` file, then pauses and asks for your key. here's where to get it:

    1. sign in to edgeful at <a href="https://www.edgeful.com" target="_blank" rel="noopener noreferrer">edgeful.com</a>.
    2. open the <a href="https://www.edgeful.com/api-dashboard" target="_blank" rel="noopener noreferrer">API dashboard</a> (`edgeful.com/api-dashboard`) and go to API Keys.
    3. click generate API key, name it, and copy the value. it starts with `ef_live_` and is shown only once.
    4. paste it into the `.env` file the agent created (after `EDGEFUL_API_KEY=`), save, and reply `done`.

    <Warning>paste your key into the `.env` file, never into the chat.</Warning>
  </Step>
</Steps>

## works with

Claude Code, ChatGPT, Codex, Cursor, and any agent that can read a URL.
