Skip to main content

Getting Started with Bosun

Welcome to Bosun! This guide will help you quickly get up and running with automating your development tasks. Bosun empowers you to define intelligent, automated tasks that operate directly on your codebase, from simple scripts to complex refactors.

What You'll Learn

In this guide, you will:

  • Understand the core components of a Bosun task.
  • Learn how to set up your Bosun account and connect a repository.
  • Create and run your first automated task involving a coding agent and a pull request.

Core Concepts

Before diving in, it's helpful to understand a few key Bosun concepts:

  • Tasks: The central unit of automation in Bosun. Each task encapsulates a repeatable workflow that performs a specific job.
  • Agents: AI-powered entities that perform intelligent actions within a task, such as writing code, refactoring, or analyzing.
  • Steps: Individual actions within a task, which can be executed by agents (agent step) or as shell commands (run step).
  • Task graphs: The way steps connect. Bosun now lets you define branches and merges between steps—see Task Graphs and Branching for details.

For a deeper dive into these concepts, refer to the Concepts section.

Setup and Repository Connection

To use Bosun, you'll start by connecting your repository to the platform.

  1. Sign in or create your account: Visit app.bosun.ai/login to sign in with GitHub. The dedicated login page remembers where you were headed, so logging out and back in returns you to the right organization or activation flow.

  2. Enable Your Repository: Follow the on-screen instructions to connect your GitHub account and enable the repository where you want to run Bosun tasks. Bosun now syncs repositories—and their forks—in the background, so you can leave the setup screen while the initial scan completes. The sync keeps running after the first import, ensuring tasks always see the latest branches and pull requests.

  3. Review Billing (Optional at Sign-Up): Organizations start with a 14-day trial. If you need to manage payment methods or check credit balances right away, open the Billing screen in the app. Only members with billing access can view it; see Billing and Credits for details.

Your First Bosun task

Let's create a simple task that uses a coding agent to create a file and then opens a draft pull request for it.

  1. Create your first task: In the app, click on Create New Task and add the following YAML configuration to define your task:
# This is your first Bosun task!
# It creates a new file and opens a draft pull request.

name: create-file-and-pr
description: A task to demonstrate a coding agent and pull request creation.

steps:
- name: Create a new file
agent:
extends: Coding
instructions: "Create a new file named 'hello-bosun.txt' in the root directory with the content 'Hello from Bosun! This file was created by an AI agent.'"
role: "You are a helpful assistant that creates files."

- name: Create a draft pull request
agent:
extends: Default
role: "You create pull requests to prepare for automated work."
instructions: "Create a draft pull request for the changes made by the previous step."
toolboxes: [repository_read]
tools:
- name: create_pull_request
extends: create_or_update_pull_request
with:
draft: true
  1. Run your task: Once the task is added, click on the newly created task and hit the Start Task button. Bosun will execute the steps defined in your task.

    After the task runs, you should see a new branch created in your repository with hello-bosun.txt and a draft pull request opened for it. The manifest name and description appear throughout the app—both in the quick-start catalog and on the run screen—so collaborators instantly recognise what this automation does.

Congratulations! You've just run your first Bosun automated task involving an AI agent and pull request creation.

Next Steps

Now that you have a basic understanding of Bosun, explore these sections to deepen your knowledge:

  • Concepts: Dive into the fundamental ideas behind Bosun, including Code Environments, Templating, and Variables.
  • Steps Reference: Learn about all available steps like agent, for-each, and run in detail.
  • Examples: Discover practical examples of how Bosun can automate various development tasks.

Happy automating!