Blog / Build an AI agent with Claude

How to build an AI agent with Claude: every agent lives in a project

Connect FlyMy.AI to Claude, ChatGPT, Cursor or Codex once, describe the job in plain words, and your assistant builds the agent inside a project: its page in the app, the agent, its first chat, saved versions and a schedule. A step-by-step guide with prompts to paste and the real answers our test project got on 12 November 2026.

What happens when you ask your assistant for an agent: a plan you approve, then one call that makes the project, its agent and the first chat. A run you accept becomes a version that runs without the chat.

What it means to build an AI agent with Claude

An AI agent is a model that works toward a goal by itself: it plans the steps, calls tools such as web search, a browser, Slack or a spreadsheet, and keeps going until the job is done. Building one used to mean writing that loop yourself, or wiring a framework to your own keys and servers.

With the Model Context Protocol (MCP), the assistant you already use can do the building. Claude, ChatGPT, Cursor and Codex call tools on MCP servers, and the FlyMy.AI MCP holds the tools that make, run, freeze and schedule agents in the cloud, next to 1,500+ tools for the services those agents work with. So in this guide, building an AI agent with Claude means: you describe the job to Claude in plain words, Claude calls FlyMy.AI, and the agent runs on FlyMy.AI, not in your chat window or on your laptop. You can close the chat; the project keeps the agent, its runs, its versions, its schedule and its budget.

What's new: every agent lives in a project

Headless Cloud 2.0.0, released on 12 November 2026, changes how an assistant makes an agent. It is a major version because one tool is gone, and the platform log lists each change. An agent rarely works alone: it starts helper agents, keeps saved versions, runs on a schedule and spends a budget. A project holds all of that in one place - the agent you talk to, the helpers it starts, their versions, schedules and triggers, its files and its budget - and gives it one page in the app.

One call makes the project and its agent

projects_plan previews the project and its budget. projects_create with your task as brief makes the project, its agent and the first chat.

Links to the right page

A new project and every project in the list carry url, its page in the app. A run you start carries the page of its agent's project.

The project list, a page at a time

projects_list takes limit and cursor and answers with next and count, how many projects you have. The most recently active come first.

A saved guide that knows it is old

When whats_new reports a newer version than your saved copy of the guide, the assistant reads the current one and saves it over the old copy.

create_agent is removed

The Agents MCP no longer has it. A call by that name creates nothing and answers with the tools to use instead.

The other agent tools stay

run_agent, update_agent, freeze_agent, run_frozen and schedule_agent take the agent id the project gives you.

How to create an AI agent with Claude, step by step

Seven steps take you from an empty chat to an agent that runs on its own. Each step names the tool your assistant calls, so you can follow along in its tool log; you only type the requests. The answers below are the real ones our test project got on 12 November 2026, with the owner renamed to alex, ids replaced and long fields trimmed.

1. Connect FlyMy.AI to Claude

The FlyMy.AI MCP lives at one URL: https://mcp-agents.flymy.ai/mcp. Sign in with your FlyMy.AI account when the client asks.

  • Claude Code: run claude mcp add --transport http flymyai https://mcp-agents.flymy.ai/mcp, then /mcp to sign in. The plugin works too: /plugin marketplace add FlyMyAI/claude-plugins, then /plugin install flymyai@flymyai.
  • Claude and Claude Desktop: Settings, Connectors, Add custom connector, then paste the URL and sign in.
  • ChatGPT, Cursor and Codex: the same URL; the setup for each is in the next section.

Check the connection by asking which account you are on. The assistant calls whoami and answers with your FlyMy.AI account.

Setup request
Read https://flymy.ai/skill.md and connect FlyMy.AI to this assistant. Then tell me which FlyMy.AI account we are on.

2. Describe the job

Write the task the way you would brief a colleague. The first chat runs it once, so make it small enough to check by eye.

  • The input and the sources: "the Hacker News front page", "these three pricing pages".
  • The output: "title, link and points", "a table with company, date and source".
  • Where results go once it works: your inbox, a Slack channel, a sheet. The assistant gives you a link to connect a service it needs; keys never go into the chat.
Try it
Create a project for this job: read the Hacker News front page and give me the three top stories right now, with title, link and points. Use GLM 5.3 Flash and a budget of $1 a day. Show me the plan before you create anything.

3. Review the plan: projects_plan

The assistant calls projects_plan first. A plan creates and charges nothing. It shows the project's id, what creating it will make, the price per hour of any servers it rents and the budget caps, and it returns a plan_token for the create call. Our plan:

{
  "schema": "flymy.project-create.v1",
  "project": "app:alex/hn-top-stories",
  "plan": {
    "release": 1,
    "changes": [
      {
        "resource": "files",
        "kind": "storage",
        "action": "create",
        "detail": "files values kept for app (...); up to 1 GiB and 10,000 objects; ..."
      }
    ],
    "usd_per_hour": "0.000000",
    "budgets": {
      "project": {
        "caps": { "per_day_usd": "1.00", "per_week_usd": "2.00", "per_month_usd": "3.00" }
      }
    },
    "share_link": false
  },
  "plan_token": "project-create-v1:..."
}

The budget caps what the project spends per day, week and month: at a cap, the next call is refused until the period ends. Ask for a budget in your request, so the plan shows it before anything is created.

4. Create the project: projects_create

After your OK, the assistant sends the same name, budget, model and brief with the plan_token to projects_create. One call makes the project, its agent and the first chat, which starts working on your brief right away:

{
  "schema": "flymy.project-create.v1",
  "project": "app:alex/hn-top-stories",
  "url": "https://app.flymy.ai/projects/alex/hn-top-stories",
  "release": {
    "number": 1,
    "status": "succeeded",
    "state": "running",
    "steps": [
      { "step": "budget project alex/hn-top-stories: holds $1.00/day, $2.00/week, $3.00/month" },
      { "step": "storage files: created (no retention: objects stay until the storage is removed)" },
      { "step": "done" }
    ]
  },
  "agent": "<agent id>",
  "chat": "<chat id>"
}

url is the project's page in the app: its agents, the conversation, money and errors. Your assistant gives you that link as it is. agent is the id every other agent tool takes, and chat is the first run. The model is optional: without one, the project's agent runs on the platform's top model.

5. Watch the first chat and refine it

The assistant follows the chat with get_run until it finishes, and you can watch the same chat on the project's page. In our project the agent handed the task to a helper, and a completion review checked the answer before the run finished.

If the result is not what you wanted, say so in the same chat. The assistant sends your follow-up with append_message and the agent continues with what it already knows; there is no need to make a second project for a correction.

Try it
Show me what the agent answered. Then ask it to add the number of comments for each story.

6. Freeze the run you accept

A chat is for getting the job right; a frozen version is for running it again. First ask for the price: get_execution_price with cost_options shows what each frozen run will cost, and cheaper models of the same family when there are any. Then freeze_agent turns the accepted run into a fixed instruction, get_compilation says when it has compiled, and run_frozen tests it. Freezing a project's agent freezes the helpers it used first, then pins their versions.

If a freeze answers that a helper has to be frozen first, do what the answer says: ask the agent in the same chat to run that helper once, then freeze again.

7. Put it to work

  • On a schedule: schedule_agent freezes and schedules in one call, with a cron expression and a time zone; update_compilation changes the schedule of a version you already have.
  • On events: triggers_v1_create starts it from a webhook, and triggers_v1_subscribe from events such as a Telegram bot message.
  • From your code: call the frozen version over the REST API or the Python SDK.
  • Shared: projects_share makes a public link that others can copy into their own account.
Try it
Freeze the last good run of my hn-top-stories project and schedule it every weekday at 8:00 in my time zone.

Build it from ChatGPT, Cursor or Codex

Nothing in these steps is specific to Claude: the tools are the same in every MCP client. How to build an AI agent with ChatGPT is the same request after you add the connector, and in Cursor or Codex the agent you make runs in FlyMy.AI's cloud, not in your editor, so it keeps working after you close it.

AssistantHow to connect FlyMy.AI
Claude Codeclaude mcp add --transport http flymyai https://mcp-agents.flymy.ai/mcp, then /mcp to sign in
Claude, Claude DesktopSettings, Connectors, Add custom connector, paste the URL and sign in
ChatGPTSettings, Connectors, Add custom connector, paste the URL and sign in
CursorAdd the URL to ~/.cursor/mcp.json with your FlyMy.AI API key in the X-API-Key header
Codexcodex mcp add flymy --url https://mcp-agents.flymy.ai/mcp, then codex mcp login flymy

Keys for header-based clients are on your profile page; keep them in a local file, never in a chat or a shared repository. Every client: Connect Claude and any MCP client.

If you keep the guide as a file - SKILL.md for Claude Code, AGENTS.md for Codex and Cursor - it now tells the assistant what to do when it is out of date: when whats_new reports a newer version than the file's, the assistant reads https://flymy.ai/skill.md again and saves it over the old copy, so an old copy does not keep teaching a removed tool.

If you used create_agent

Headless Cloud 2.0.0 removes the Agents MCP tool create_agent. That is the breaking change behind the major version number, and here is what it means in practice.

  • What to call instead: projects_plan, then projects_create with the old agent's task as brief, and the same model and effort if you set them. The agent in the answer is the id the other tools take.
  • A call to create_agent creates nothing; its answer names the project tools to use instead.
  • Agents you already have keep working with the same ids in run_agent, update_agent, freeze_agent, run_frozen and schedule_agent.
  • Saved prompts and scripts that tell an assistant to call create_agent need one change: ask it to create a project with the task as its brief.
Try it
I used to make agents with create_agent. Make this one as a project instead, with the same task as its brief, and show me the plan first: every Friday, summarize what changed on https://example.com/pricing this week.

Use cases with ready prompts

Paste any of these into an assistant connected to FlyMy.AI. Each one starts with a plan you approve.

1. A morning digest of AI news

The first chat finds today's three stories; once you like the result, freeze it and put it on a morning schedule.

Try it
Create a project that finds three AI news stories every morning and sends me the links.

2. Watch a run on its project page

The answer to a run you start carries the page of its project, so the link opens where the work is.

Try it
Start my newest project on a short test task and give me the link to watch it.

3. Your projects at a glance

The project list comes a page at a time, the most recently active first, with a count of all of them.

Try it
How many projects do I have, and which five did I touch last?

4. A weekly team report

It needs GitHub and Slack connected. The assistant gives you a link for each service that is not connected yet; you sign in there, not in the chat.

Try it
Create a project that every Monday at 9:00 collects the issues closed last week in my GitHub repository and posts a short summary to #team in Slack. Plan it with a weekly budget of $2 first.

5. A daily price check

Comparing pages day to day is a good first job for an agent. A longer version of this job is the price monitoring use case.

Try it
Create a project that checks the pricing pages of these three products every morning and tells me only what changed: https://example.com/pricing, https://example.org/pricing, https://example.net/pricing.

Four ways to build an AI agent with Claude

Anthropic offers its own ways to build agents with Claude. They differ in where the agent runs and in how you define it. The table sticks to what each product documents; the sources are linked below it and were checked on 12 November 2026.

ApproachA FlyMy.AI project from your assistantClaude Managed AgentsClaude Agent SDKClaude Code subagents
How you make itDescribe the job in chat; the assistant calls projects_plan and projects_createCreate an agent, an environment and a session through the Claude APIWrite Python or TypeScript that runs the agent loopA Markdown file with YAML frontmatter in .claude/agents/, or ask Claude to write it
Where it runsFlyMy.AI's cloud, after you close the chatAn Anthropic-managed cloud sandbox, or a self-hosted sandboxIn a process you operateInside a Claude Code session, in its own context window
ModelsClaude, GPT, Gemini, Grok and open-weight models such as GLM 5.3 FlashClaude modelsClaude modelsClaude models
What you needA FlyMy.AI account and one MCP URLA Claude API key; Managed Agents is in betaA Claude API keyClaude Code

Sources: Claude Managed Agents overview, Claude Agent SDK overview, Claude Code subagents, FlyMy.AI projects.

How to choose. Pick the Agent SDK when the agent belongs inside your own application and infrastructure. Pick Managed Agents when you build on the Claude API and want Anthropic to host the sessions. Pick subagents for focused helpers inside your own Claude Code session. Pick a FlyMy.AI project when you want to build the agent by talking to the assistant you already use, run it in the cloud with your connected services, and freeze, schedule and share it.

What it costs

Signing up is free, and there are no seats and no monthly minimum: runs are billed to your FlyMy.AI balance as they happen, at the rates on the pricing page. A plan is free. What a run costs depends on the model, the tokens and the tools it calls, so here is what our test project cost:

Our test, 12 November 2026ModelCost
projects_plan: the plan of the project-$0
First chat: the project's agent and the helper it created read the Hacker News front pageglm-5.3-flash$0.022

Costs as get_execution_price reported them for these runs. Prices follow the current model and tool rates.

  • Before you freeze, get_execution_price with cost_options shows the price of each frozen run and cheaper models of the same family, when there are any.
  • A project's budget caps what it spends per day, week and month, helpers included.

FAQ

Can I use Claude to build AI agents?

Yes. Connect the FlyMy.AI MCP to Claude, Claude Desktop or Claude Code and describe the job. Claude calls projects_plan to show you the plan and its budget, then projects_create with your job as the brief. The agent runs in a FlyMy.AI project in the cloud, where you can refine it, freeze it and schedule it.

Can I create my own AI agent for free?

Signing up and planning are free, and there are no seats or monthly minimum. Runs are paid from your FlyMy.AI balance as they happen: in our test, the first chat of a project on GLM 5.3 Flash cost $0.022. A budget per day, week and month caps what a project can spend.

How do I build an AI agent with ChatGPT?

Add FlyMy.AI in ChatGPT under Settings, Connectors, Add custom connector, with the URL https://mcp-agents.flymy.ai/mcp, and sign in. Then ask for the agent the same way as in Claude: ChatGPT calls projects_plan and projects_create, and the agent runs in a FlyMy.AI project, not in the chat.

Do I need to write code to build an AI agent?

No. You describe the job in plain words and approve the plan; the assistant makes the project and the agent. Code is optional: a frozen version can also be called from your own app over the REST API or the Python SDK.

What happened to create_agent?

Headless Cloud 2.0.0 removed it from the Agents MCP on 12 November 2026: every agent is now made with its project. Call projects_plan, then projects_create with the task as brief. Agents made before keep their ids and keep working with run_agent, update_agent, freeze_agent, run_frozen and schedule_agent.

How do I run an AI agent on a schedule?

Freeze a run you are happy with and schedule it: schedule_agent freezes and schedules in one call with a cron expression and a time zone, and update_compilation changes the schedule later. Ask your assistant, for example: freeze my last good run and schedule it every weekday at 8:00 in my time zone.

Where does the agent run, and does my computer need to stay on?

The agent runs on FlyMy.AI, in its project. Claude, ChatGPT, Cursor or Codex only build and steer it, so you can close the chat or turn off your computer: a scheduled version still runs, and the project's page in the app shows its runs.

How do I see what my agent did?

Open the project's page: the url that projects_create returns, or the page a run you start names. It shows the project's agents, their conversations, money and errors. In the chat, your assistant reads a run with get_run and read_run_result.

What is MCP?

The Model Context Protocol is an open protocol that lets an AI assistant call tools on a server. Claude, ChatGPT, Cursor and Codex support it, and one MCP URL gives them FlyMy.AI's agent tools and 1,500+ tools for other services.

Build your first agent in a project

Connect FlyMy.AI to your assistant and describe the job. The plan shows what will be made and its budget before anything is created.

Keep reading