> ## Documentation Index
> Fetch the complete documentation index at: https://docs.orchestrahq.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Repository access

> Scope repositories to projects and teams, and choose who can dispatch Orchestra agents into them

A repository can be **scoped** to a project or a team. On its own, scoping
changes nothing: everyone in the workspace still reads the repository's
knowledge, and anyone can still dispatch agents into it. What scoping does is
let the project or team turn on one or both of two switches, which decide who
can dispatch Orchestra agents into its repositories. Both switches are off by
default.

## Scope a repository

* **To a project:** open the project, choose **Repositories** at the top of its
  page, then **Add repository**. Repositories connected to the workspace are
  offered as you type. You can also type any `owner/name`, or paste the
  repository's URL. Choose the x on a repository to take it off.
* **To a team:** open the team, then **Settings**, **What it owns**. Choose
  **Add**, pick **Repository**, and type its `owner/name`.

A repository can be scoped to several projects and teams at once. **Settings**,
**Repositories** lists, for each repository, the projects and teams it is
scoped to that you can see, with a lock on the ones that keep it to their
members.

## The two switches

The switches are in the same place: the project's **Repositories** panel, or
the team's **Settings**, under **Who dispatches agents into its repositories**.

**Only members dispatch agents into these repositories.** People who are not on
the project or team cannot dispatch an agent into its repositories. If several
projects or teams turn this on for the same repository, being on any one of
them is enough.

**Members dispatch agents only into these repositories.** The project's or
team's own people can dispatch agents only into the repositories scoped to it.
If you are on several projects or teams that turn this on, a repository scoped
to any one of them is allowed.

A project's people are its leads, its members, and the person who created it.
A team's people are its members. What counts is the membership of the person
who starts the agent, not who the agent works for afterwards.

## What the switches cover

They cover every agent run started through Orchestra: a cloud run, a run on
your own or a teammate's computer started from Orchestra, a fork that runs in
the cloud, and moving a session to the cloud. A refused run starts nothing and
says why, for example:

> Only members of Payments can dispatch agents into acme/payments. Ask an admin
> of it to add you, or pick another repository.

They do not cover:

* **Reading.** A repository's knowledge, its sessions and its commits stay
  visible to everyone in the workspace who could see them before. Scoping
  never narrows who reads anything.
* **Work you start yourself.** An agent you start in a terminal on your own
  computer, outside Orchestra, is not affected.

A Private team still applies its switches to people who cannot see it. Its
refusal says "a private team" instead of naming it.

## Who can change them

A workspace admin can change any project's or team's switches. Otherwise, a
team's admins change its switches, and a project's leads (or the person who
created it) change the project's.

With both switches off, anyone who can change the project or team can scope
repositories to it, as described in
[Projects and teams](https://docs.orchestrahq.ai/projects-teams.md#who-can-change-a-project-or-team). While
either switch is on, only the people who can change the switches can change
which repositories are scoped to it, since that changes what the switch
covers.

Every change to a switch, and every refused run, is recorded with who made it.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.