# Overview ## Navigation ### Start here - [Overview](https://dev.meta.ai/docs/overview.md) - [Quickstart](https://dev.meta.ai/docs/quickstart.md) - [Authentication](https://dev.meta.ai/docs/authentication.md) - [Models](https://dev.meta.ai/docs/models.md) - [SDKs and libraries](https://dev.meta.ai/docs/sdks.md) - [Pricing and rate limits](https://dev.meta.ai/docs/pricing-rate-limits.md) ### Capabilities - [Tool calling](https://dev.meta.ai/docs/tool-calling.md) - [Tool search](https://dev.meta.ai/docs/tool-search.md) - [Search grounding](https://dev.meta.ai/docs/search-grounding.md) - [Image understanding](https://dev.meta.ai/docs/image-understanding.md) - [Image generation](https://dev.meta.ai/docs/image-generation.md) - [Speech to text](https://dev.meta.ai/docs/speech-to-text.md) - [Video understanding](https://dev.meta.ai/docs/video-understanding.md) - [File handling](https://dev.meta.ai/docs/file-handling.md) - [Reasoning](https://dev.meta.ai/docs/reasoning.md) - [Structured output](https://dev.meta.ai/docs/structured-output.md) - [Prompt caching](https://dev.meta.ai/docs/prompt-caching.md) - [Token counting](https://dev.meta.ai/docs/token-counting.md) ### Protocols - [Choosing an API](https://dev.meta.ai/docs/protocols.md) - [Responses API](https://dev.meta.ai/docs/protocols/responses.md) - [Chat Completions API](https://dev.meta.ai/docs/protocols/chat-completions.md) - [Messages API](https://dev.meta.ai/docs/protocols/messages.md) ### Cookbook - [All recipes](https://dev.meta.ai/docs/cookbook.md) - [API fundamentals](https://dev.meta.ai/docs/cookbook/api-fundamentals.md) - [Agent patterns](https://dev.meta.ai/docs/cookbook/agent-patterns.md) - [Use cases](https://dev.meta.ai/docs/cookbook/use-cases.md) - [Building with Muse Code](https://dev.meta.ai/docs/cookbook/muse-code.md) - [Muse Image](https://dev.meta.ai/docs/cookbook/muse-image.md) - [Muse Voice Transcribe](https://dev.meta.ai/docs/cookbook/muse-voice-transcribe.md) ### Muse Code - [Overview](https://dev.meta.ai/docs/muse-code.md) <- this page - [Authentication and billing](https://dev.meta.ai/docs/muse-code/auth.md) - [Subscriptions](https://dev.meta.ai/docs/muse-code/subscriptions.md) - [Permissions and safety](https://dev.meta.ai/docs/muse-code/permissions.md) - [Working with the agent](https://dev.meta.ai/docs/muse-code/interactive.md) - [Workflows](https://dev.meta.ai/docs/muse-code/workflows.md) - [Session messaging](https://dev.meta.ai/docs/muse-code/session-messaging.md) - [Rewind a conversation](https://dev.meta.ai/docs/muse-code/rewind.md) - [Configuration and context](https://dev.meta.ai/docs/muse-code/configuration.md) - [Extending and automating](https://dev.meta.ai/docs/muse-code/extending.md) - [Changelog](https://dev.meta.ai/docs/muse-code/changelog.md) ### Muse Glimmer - [Overview](https://dev.meta.ai/docs/muse-glimmer.md) - [Get the model](https://dev.meta.ai/docs/muse-glimmer/get-the-model.md) - [Prompting guide](https://dev.meta.ai/docs/muse-glimmer/prompting.md) - [Quantization](https://dev.meta.ai/docs/muse-glimmer/quantization.md) - [Speculative decoding](https://dev.meta.ai/docs/muse-glimmer/spec-decode.md) ### Agent guides - [Coding agents](https://dev.meta.ai/docs/coding-agents.md) - [Agent frameworks](https://dev.meta.ai/docs/agent-frameworks.md) - [Computer use](https://dev.meta.ai/docs/computer-use.md) ### API reference - [Introduction](https://dev.meta.ai/docs/api-reference.md) - [Error handling](https://dev.meta.ai/docs/error-handling.md) - [Status](https://dev.meta.ai/docs/api-reference/status.md) --- # Muse Code Muse Code is Meta's coding agent for the terminal and CI, built on [Muse Spark](/docs/models.md#muse-spark). Run it in a project and it plans, edits, and runs commands to do a task, with approvals and an OS sandbox on from the first run. Muse Code and the [Model API](/docs/overview.md) are two ways to use the same model. Call the API directly when you build your own agent or app. Run Muse Code when you want a ready-made coding agent at the command line or in a pipeline. [Workflows](/docs/muse-code/workflows.md) coordinate parallel and staged agent work when the installed build includes the workflow engine and the rollout is enabled. They are not available on every build or platform. [Session messaging](/docs/muse-code/session-messaging.md) lets independent live sessions exchange handoffs, review requests, and status updates. ## Install {#install} Install Muse Code with the one-line shell installer. It installs a native binary on your path for macOS and Linux: ```bash curl -fsSL https://dev.meta.ai/install.sh | sh ``` Confirm it's on your path: ```bash muse --version ``` ## First run {#first-run} Run `muse` in any project directory to start an interactive session. On first entry Muse Code asks whether to [trust the workspace](/docs/muse-code/permissions.md#trust-scopes) and prompts you to authenticate with a browser sign-in or an API key. When you trust the workspace, Muse Code loads the project's skills, rules, and hooks. The default model is `muse-spark-1.2`. ```bash cd /path/to/your/project muse ``` Reopen the sign-in options any time from an interactive session with `/login`. For a non-interactive environment such as [CI](/docs/muse-code/extending.md#headless), set `META_API_KEY` instead. See [authentication and billing](/docs/muse-code/auth.md) for the full sign-in and billing setup flows. ## Interactive or headless {#modes} The same binary runs two ways: - **Interactive**: `muse` opens a terminal UI for a back-and-forth session with slash commands, approvals, and live status. See [working with the agent](/docs/muse-code/interactive.md). - **Headless**: `muse exec ""` runs one prompt to completion for scripts and CI. See [headless and CI](/docs/muse-code/extending.md#headless). ## What to read next {#whats-here} - **[Authentication and billing](/docs/muse-code/auth.md)**: sign in, API keys, and plans. - **[Permissions and safety](/docs/muse-code/permissions.md)**: approval modes, staged shell review, and the sandbox. - **[Working with the agent](/docs/muse-code/interactive.md)**: slash commands to steer a session, manage context, set goals, and more. - **[Rewind a conversation](/docs/muse-code/rewind.md)**: branch from an earlier message while preserving the original session and workspace files. - **[Workflows](/docs/muse-code/workflows.md)**: check availability, coordinate parallel and staged agent work, monitor runs, and save repeatable workflows. - **[Session messaging](/docs/muse-code/session-messaging.md)**: send handoffs, review requests, and status updates between live local sessions. - **[Configuration and context](/docs/muse-code/configuration.md)**: settings, project instructions, model selection, and memory. - **[Extending and automating](/docs/muse-code/extending.md)**: subagents, skills, hooks, MCP, and headless runs. ## Next steps - Sign in and set up billing in [authentication and billing](/docs/muse-code/auth.md). - Understand the guardrails before your first real task in [permissions and safety](/docs/muse-code/permissions.md).