After installing, log in to connect the CLI to your MutagenT account. The CLI presents two authentication methods interactively: browser-based OAuth or pasting an API key.
mutagent auth login
You can also specify the authentication method directly:
# Browser-based OAuth flowmutagent auth login --browser# Direct API key (for CI/CD pipelines)mutagent auth login --browser
Check your authentication status at any time:
mutagent auth status
For CI/CD environments, set the MUTAGENT_API_KEY environment variable (no login needed). The CLI also respects CI=true and MUTAGENT_NON_INTERACTIVE=true to auto-select browser auth.
import { Mutagent } from '@mutagent/sdk';const client = new Mutagent({ apiKey: process.env.MUTAGENT_API_KEY,});// SDK is ready to useconsole.log('MutagenT SDK installed successfully');
Most developers use integration packages that auto-trace LLM framework calls. Install the one matching your framework.
bun add @mutagent/langchain
You do not need to install integration packages manually if you use mutagent integrate. The CLI generates the integration code and tells you which package to install.