init
Initialize OSS Autopilot by setting up your GitHub username to manage open source contributions across repositories.
Instructions
Initialize OSS Autopilot with a GitHub username. Creates the state file and sets up initial configuration.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| username | Yes | Your GitHub username |
Implementation Reference
- packages/core/src/commands/init.ts:22-33 (handler)The runInit handler function which updates the githubUsername configuration using the StateManager.
export async function runInit(options: { username: string }): Promise<InitOutput> { validateGitHubUsername(options.username); const stateManager = getStateManager(); // Set username in config stateManager.updateConfig({ githubUsername: options.username }); return { username: options.username, message: 'Username saved. Run `daily` to fetch your open PRs from GitHub.', }; } - packages/mcp-server/src/tools.ts:228-240 (registration)Registration of the 'init' tool in the MCP server, using the runInit handler.
// 12. init — Initialize with GitHub username server.registerTool( 'init', { description: 'Initialize OSS Autopilot with a GitHub username. Creates the state file and sets up initial configuration.', inputSchema: { username: z.string().describe('Your GitHub username'), }, annotations: { readOnlyHint: false, destructiveHint: false }, }, wrapTool(runInit), ); - Type definition for the output of the init command.
export interface InitOutput { username: string; message: string; }