---
url: /examples/share-a-team-agent.md
---
# Share a code-review agent with your team

Share one code-review agent through a private Git repository, so that every engineer on the team runs the same release the same way.

## 1. Create the project

Create a private repository for the agent, `github.com/acme/reviewer`, and in its checkout write `instructions.md` and a review skill in `skills/review/SKILL.md`. Then create `pandra.toml`, which keeps your `instructions.md`:

```sh
git clone git@github.com:acme/reviewer.git && cd reviewer
mkdir -p skills/review
pandra init
```

## 2. Add the components

Add the local skill, a skill from GitHub, and the GitHub MCP server:

```sh
pandra add ./skills/review
pandra add https://github.com/obra/superpowers/tree/v7.0.2/skills/test-driven-development
pandra add --mcp io.github.github/github-mcp-server
```

Each `add` prints what it pinned (output abridged):

```text
Added `[skills.review]` to pandra.toml.
pandra.lock is not needed: nothing in pandra.toml is pinned
Added `[skills.test-driven-development]` to pandra.toml and updated pandra.lock.
  pinned skill test-driven-development from https://github.com/obra/superpowers/skills/test-driven-development (commit 22f0b463e7a5)
Method: remote, https://api.githubcopilot.com/mcp/ (requests go to api.githubcopilot.com), the only supported method
  ...
Added `[mcp-servers.github]` to pandra.toml and updated pandra.lock.
  pinned MCP server github from io.github.github/github-mcp-server 1.4.0
```

After you set the version and description, the definition is:

```toml
# pandra.toml
name = "reviewer"
version = "1.2.0"
description = "Reviews pull requests for correctness and style"

[[instructions]]
path = "instructions.md"

[skills.review]
path = "skills/review"

[skills.test-driven-development]
git = "https://github.com/obra/superpowers"
path = "skills/test-driven-development"
tag = "v7.0.2"

[mcp-servers.github]
registry = "io.github.github/github-mcp-server"
version = "1.4.0"
method = "remote"
```

[Learn more about building an agent →](/build.md)

## 3. Try it

Open it in the harness's own interface on a real repository, work with it, and exit the harness when you are done. The `github` server's token is optional, so the trial needs no setup:

```sh
pandra run . --harness claude-code --workspace ~/src/payments
```

Without the token, the `github` server does not connect, and the trial runs without GitHub's tools.

## 4. Commit and release

Commit the project with its lockfile, tag the release with its version, and push both. Engineers run the release as `github.com/acme/reviewer@v1.2.0`, with the Git credentials they already use for the team's repositories.

```sh
git add pandra.toml pandra.lock instructions.md skills \
    && git commit -m "Add the reviewer agent"
git tag v1.2.0
git push origin main v1.2.0
```

A team that prefers built packages, for example to reach machines without access to the repository, can also [publish the release to an OCI registry](/share/publishing.md#publishing-a-package-to-an-oci-registry) with `pandra push ghcr.io/acme/reviewer` in the release's checkout; engineers then use `ghcr.io/acme/reviewer:1.2.0` in place of the Git reference.

[Learn more about sharing through Git →](/share/publishing.md#sharing-through-git)

## 5. Set it up on each engineer's machine

Each engineer reviews and approves the release once, then sets up its GitHub token. `config setup` asks where the token comes from, such as an environment variable, and whether to send it as it is or as `Bearer <token>` ([setting up an agent](/configure/setup.md)):

```sh
pandra pull github.com/acme/reviewer@v1.2.0
pandra agent trust github.com/acme/reviewer@v1.2.0
pandra config setup github.com/acme/reviewer@v1.2.0
```

Settings are kept per agent, without the tag, so they carry over to later releases. A release that adds an MCP server, changes one, or lets a skill run a new tool without asking asks for approval again.

[Learn more about trusting agents →](/run/trust.md)

## 6. Run it

In their own checkout, each engineer runs the release; the review goes to stdout:

```sh
pandra run github.com/acme/reviewer@v1.2.0 --workspace ~/src/payments \
    --prompt "Review my uncommitted changes." > review.md
```

So that nobody has to remember the release, a repository can declare the agent in a guild file, `pandra-guild.toml`, with the other agents it works with, and pin them all for everyone who clones it: [Pin the agents your repository works with](/examples/pin-repository-agents.md).
