Skip to main content
Lesson 2 of 18·5 min

Run Your First Agent

You're early in the course, and this lesson is all about getting your Mastra environment up and running so you can iterate quickly as we build the theme park agent. You'll scaffold a new standalone project, configure a model provider, and verify everything works end-to-end.

You'll run the dev server and use Mastra Studio to interact with the default agent, test tools in isolation, and execute a sample workflow step-by-step. Along the way, you'll see how Studio helps you inspect outputs and understand what the system is doing without building any frontend yet.

This matters because the CLI-generated project structure becomes the home for all of your agents, tools, workflows, and configuration as the course progresses. And by getting comfortable with Studio and observability now, you'll have a reliable way to debug surprising outputs and track quality as the agent grows more complex.

"Studio is where you develop and test your Mastra app—you can run everything, inspect what happened, and iterate fast before you ever touch a frontend."

— Guil Hernandez

Mentioned in the Lesson
Direct link to Mentioned in the Lesson

Code:

Relevant Mastra docs:

Join the Community
Direct link to Join the Community

Ask questions:

Follow Mastra:

  • X — follow Mastra for updates
  • YouTube — watch more tutorials
  • LinkedIn — follow for updates

Don’t miss the next Mastra lessons

Be notified the moment new lessons release and stay ahead of every update. We’ll email you about course improvements, new Mastra features, and upcoming live workshops. Unsubscribe anytime.