config.json is local and gitignored; config.example.json is the template. To use another file, set SHEPHERD_CONFIG to its path relative to the project folder. The server checks the config at startup and lists every problem it finds.
| Key | Purpose |
|---|---|
port |
Port to listen on. PORT in the environment wins. Defaults to 5050. |
me |
The id of the team member the dashboard treats as "you". |
team[] |
id, name, short (the label on screen), and logins: one login per host key, for example { "github": "octocat", "work": "ocat" }. Optional pushPolicy: how this person wants to receive changes on their PRs (review-only, stacked-pr or push; see Push policies). |
hosts.<key> |
hostname, label, concurrency (the cap on parallel gh processes, default 4), bot (the AI-review bot's login, or null; see AI-review bots), optional botsByOwner (another bot for the repos of some orgs; same section), optional proxychains (a proxychains config path; see GitHub Enterprise and proxies), optional reviewTeams (see Review teams), optional anyRepo (find the team's PRs in any repo of some orgs) and defaultOrgs (the orgs a host with no listed repos searches; see PRs in any repo), and optional rowRefreshFloorMs and rowRefreshLowBudgetMs (see Refresh rules). |
repos[] |
Can be empty: a host with no listed repos searches its defaultOrgs (see PRs in any repo). Each repo has host (a key from hosts), owner, name, and short (the label on screen). Optional maxBaseAgeHours: flag PRs whose base is older than this many hours. Optional allAuthors: true lists every open PR in the repo, including PRs by people outside team (see PRs from outside the team). Optional pushPolicy and pushPolicyByAuthor (keyed by team id or login): how authors in this repo want to receive changes (see Push policies). |
linear |
Optional. workspace (the slug in Linear URLs) and keys (team prefixes to find in titles and branch names). Use null to turn ticket links off. |
aiReviewLabel |
Optional. The name shown for the AI-review column and tile. Defaults to AI review. |
herdr |
Optional. See herdr terminal panes. enabled (default true; used only when herdr is installed and running) and transcriptTailKb (how much of each agent transcript to search, default 192). |
refresh |
Optional. "rows" (the default) or "list". Sets when the page loads a row again. See Refresh rules. |
features |
Optional. Turns dashboard features off: shipped, followups and herdr, each true or false. A missing key means on. See Turn features off. |
limits |
Optional. Cost limits that the server enforces: maxPeople, maxRepos, maxOrgs, maxBells and requestBudget. See Cost limits. |
ignoreParticipants |
Logins to leave out of Participants. Use it for bots and service accounts that appear as ordinary users. Logins ending in [bot] or -bot are always left out, and so is any actor that GitHub types as a Bot (a GitHub App such as github-actions has neither suffix), in Participants and in follow-ups. An approval from one of these logins does not count for the no approval label. |
The server binds to 127.0.0.1 only. The MCP endpoint refuses browser requests from other origins.
The gear button opens the settings panel. It edits config.json through GET and PUT /api/settings, so you can change the team and the repos without opening the file. The settings come in two groups:
| Group | Settings | Who changes them |
|---|---|---|
| Personal | team and each person's logins, repos (with allAuthors, maxBaseAgeHours, pushPolicy and pushPolicyByAuthor), where each host finds PRs (hosts.<key>.anyRepo), the review teams (hosts.<key>.reviewTeams), linear and features |
You, in the panel or in config.json |
| Hosts | Each host's hostname, label, bot and botsByOwner; adding and removing hosts |
You, in the panel's Server section or in config.json |
| Deployment | The other host fields (concurrency, proxychains, rowRefreshFloorMs, rowRefreshLowBudgetMs, defaultOrgs), port, herdr, refresh, aiReviewLabel, ignoreParticipants, limits, and the token |
The person who runs the server, in config.json |
The panel lists its sections on the left: You, People, Repos, Review teams, Linear, Features and Server. It shows one section at a time. People and repos are rows with their logins and push policy; click a row to edit it. The Server section edits the GitHub hosts and their AI-review bots, and shows the other server settings. When a save is refused, the panel opens the section and the row of the first refused field, and the list of sections shows how many fields to fix in each one. On a narrow screen, the sections are tabs above the panel.
Each field in the settings has an editable flag. The panel shows a field that is not editable read-only, with the reason. On this server, me and the deployment settings are not editable in the panel, apart from the host fields in the table above, and features.herdr is not editable when "herdr": { "enabled": false }. When the server runs with GH_ENTERPRISE_TOKEN or GITHUB_ENTERPRISE_TOKEN set, the panel cannot add or remove hosts or change a host name, because gh sends that token to any GitHub Enterprise host; a host's label and bots stay editable. GH_TOKEN and GITHUB_TOKEN are safe either way: the server gives them to gh only for github.com, so a host that the panel or an import adds never receives them. A host other than github.com uses the login that gh auth login --hostname <host> stored for it. A PUT /api/settings that changes a field that is not editable is refused, also when it is sent on purpose.
Export in the panel downloads your saved settings as a file, and Import reads such a file into the panel; nothing is saved until you click Save. Use them to move your settings to another Shepherd, such as one embedded in another app, or back. The file lists each host by host name, so an import moves logins, repos and review teams to the host with the same name, whatever its key. A host that the server lacks is added when the server lets you add hosts, as this one does; otherwise its logins and repos are left out, and the panel says so. You stay who you are on the server you import into: the file's entry with one of your logins becomes yours. An entry that has only your id, and none of your logins, is someone else, so it gets another id (<id>-imported) and the panel says so. A file with values of the wrong type is refused. When an import adds a host, the panel lists the AI-review bots that come with it. A setting that the server does not let you change keeps its value there.
Push policies are personal settings too. In the panel you can set the pushPolicy of anyone on your team, a repo's default pushPolicy, and a repo's pushPolicyByAuthor entries (add an author by team id or login). They record how each person wants to receive changes, so set them to what that person asked for.
A save writes a new config.json (a temp file with the same permissions, then a rename), so the old file stays when a write fails. When config.json is a symlink, the save writes to the file it points to. It keeps the keys that the panel does not show, such as port, and each kept host's proxychains, concurrency and refresh floors (removing a host, or giving a new host another key, removes them for that host), but it writes the file again with two-space indents. The server applies a save at once, without a restart.
The server also reads config.json again when it changes on disk, at most once a second, on the next API or MCP request. A change to a personal setting or to hosts applies without a restart. A change to another deployment setting applies only after a restart; until then, the panel says so. When the file on disk has a problem, the server keeps the last good settings and the panel lists the problems. At startup, a file with a problem still stops the server.
When two tabs, or a tab and an edit on disk, change the settings at the same time, the second save is refused, and the panel offers to load the current settings. Each settings response has a version, and a PUT sends the version that it started from.
Bells, the filters, the sort order, the refresh interval and the theme are not in config.json. They stay in the browser's storage (shepherd.settings), one copy for each browser.
By default Shepherd lists open PRs written by people in team, plus PRs that request a review from someone whose bell is on or from one of the host's reviewTeams, and PRs that have someone whose bell is on as an assignee. A PR by a contributor outside the team that requests nobody, and that no bell catches, never appears.
Set allAuthors: true on a repo to list every open PR in it, whoever wrote it:
{ "host": "github", "owner": "example-org", "name": "plugin", "short": "plugin", "allAuthors": true }Use it on repos where the team reviews most outside work. On a busy repo it fills the dashboard with PRs the team doesn't own, and the server fetches the details of each listed PR that is not dormant, in batches (see Fetching details in batches). Those PRs still only wait on someone through the usual rules in What "waiting on" means; being listed doesn't put them in anyone's queue. Shipped and merged_prs stay limited to the team's PRs.
By default a host finds PRs only in the repos listed in repos. Set anyRepo on a host to find the team's PRs in any non-archived repo of some orgs (or users) on that host:
"github": { "hostname": "github.com", "label": "GitHub", "bot": null, "anyRepo": { "orgs": ["example-org", "other-org"] } }orgs needs at least one org: there is no setting for every repo on a host, which on github.com would include personal repos and outside open-source work. The listed repos on the host are searched too, also when they are outside the orgs.
The person who runs the server can set defaultOrgs on a host. It is a server setting, set only in config.json (a host that embeds Shepherd sets it with its other server settings); the panel shows it and cannot change it. It does two things:
- A host with no listed repos and no
anyReposearches itsdefaultOrgs, when someone inteamhas a login there. WithoutdefaultOrgs, such a host is not searched. - When you turn Any repo on in the panel, the org list starts as the host's
defaultOrgs.
"github": { "hostname": "github.com", "label": "GitHub", "bot": null, "defaultOrgs": ["example-org", "other-org"] }The org scope covers every search on the host: the team's open PRs, review requests and assignments from bells, review teams, Shipped and the follow-ups endpoint. It does not limit reads of one PR by its link: the row refresh (/api/pr) and the MCP get_pr tool with a url read any PR on a configured host that the server's GitHub login can read, as they did before. The listed repos keep their settings (short, allAuthors, maxBaseAgeHours and the push policies). A repo that is not listed has the repo name as its label, no base-age limit and no repo push policy. Each search still returns at most 500 PRs.
In the settings panel, the Repos section has a switch for each host ("Any repo on …") and a field for its orgs. When a host is in any-repo mode, the dashboard shows a filter chip for each repo that has PRs, and the Repos section of the panel lists the repos that are not listed under Add more repos. Click one to add it to your repos with its name as the label, then Save. When the host had no listed repos and searched its defaultOrgs, adding a repo from Add more repos also turns Any repo on with those orgs, so the host keeps searching them. Add a repo does not: the host then searches only its listed repos.
The server sends these values to the page, so the person who runs the server controls how often each page asks for rows. Without them, the page uses the rules in How refreshing works.
hosts.<key>.rowRefreshFloorMs: the shortest time, in milliseconds, before the page loads a row on this host again. The default is 120000 (2 minutes) on github.com and on hosts that report a GraphQL budget, and 20000 (20 seconds) on other hosts. The page still waits at least the refresh interval that the user selects. The value must be 10000 (10 seconds) or more.hosts.<key>.rowRefreshLowBudgetMs: the time, in milliseconds, between row loads on this host when fewer than 500 GraphQL points remain. The default is 600000 (10 minutes). The value must be 10000 (10 seconds) or more. A low budget never makes rows load sooner: when this value is less than the floor, the page uses the floor. When both values are set and this one is less thanrowRefreshFloorMs, the server prints a warning at startup.refresh: "list": the page loads a row only when the list shows a new updated time for it, when the row has no details yet, when the user clicks the refresh button of the row, or when the PR leaves the list. If that load fails, or the row is hidden at that time, the page tries again on a later tick. The page does not load a row from the list more often than every 10 seconds. Refresh now asks for a new list and does not ask for each row. The server reuses a list that is less than 10 seconds old for all list calls, and after a failed search it returns the same error for 10 seconds. A row load, also a forced one, reuses details that are less than 10 seconds old, and so does the server when it fetches details in batches after a list call (see Fetching details in batches). The floors above then have no effect. GitHub does not change a PR's updated time when its checks finish or when its base branch moves. So in this mode, the status and base age of a row can stay old until the PR changes in another way, or until the user clicks the refresh button of the row.
{
"refresh": "list",
"hosts": {
"github": { "hostname": "github.com", "label": "GitHub", "bot": null, "rowRefreshFloorMs": 300000 }
}
}Use "list" on a server that many people use. All pages share the server's gh logins, so the cost of a page load or a refresh must not grow with the number of rows. With "list", a change that does not move a PR's updated time, for example a new check result, shows only after the user clicks the refresh button of the row.
Set a feature to false to remove it from the dashboard:
"features": { "shipped": false, "followups": false, "herdr": false }| Key | What false removes |
|---|---|
shipped |
The Shipped section and its controls. Follow-ups show only in Shipped, so this also turns followups off. |
followups |
The follow-up pills, the Needs follow-up chip and the follow-up count in the Shipped summary. Shipped stays. |
herdr |
The herdr chips on PR rows. "herdr": { "enabled": false } also turns this off. |
When a feature is off, the page sends no request for it and shows no error for it. The server answers 404 on the endpoint of that feature (/api/merged, /api/followups, or /api/herdr/*). The page keeps your saved choices for a feature that is off, such as the range or the Needs follow-up chip, and uses them again when the feature is on. The MCP tools do not change.
GET /api/config sends the result as features, with all three keys, plus settings: true (this server has the settings API). A different server that has only the open-PR endpoints can send the same object with false values. When a server sends no features object, or leaves a key out, the page treats that feature as on. settings is the exception: the page uses the settings API only when the server sends "settings": true.
limits caps what one person's settings can cost the server's GitHub logins:
"limits": { "maxPeople": 12, "maxRepos": 20, "maxOrgs": 5, "maxBells": 6, "requestBudget": { "requests": 600, "perSeconds": 3600 } }| Key | What the server does |
|---|---|
maxPeople |
Refuses a settings save with more people in team. |
maxRepos |
Refuses a settings save with more repos. |
maxOrgs |
Refuses a settings save with more orgs in anyRepo, all hosts together. An org opens every repo in it, so it can cost more than a repo. |
maxBells |
Uses only this many bells in one list request. |
requestBudget |
The most API requests one viewer can make in perSeconds seconds. This server has one user and does not enforce it; a host with many viewers does. |
Each value is a whole number, 1 or more. A missing key means no limit. The settings panel shows the limits. Only the server enforces them.
On a machine with more than one user, anyone on it can reach 127.0.0.1. To lock /mcp and /api/*, start the server with a token:
export SHEPHERD_TOKEN=$(openssl rand -hex 32) # to keep it across restarts, store it in a file only you can read (chmod 600)
bun run startEvery request to /mcp and /api/* then needs Authorization: Bearer <token>, or it gets a 401. The token is read from the environment, not config.json, because config files are often readable by other users. The server prints the dashboard link as http://127.0.0.1:5050/#token=…. Open it once: the page keeps the token in this browser's storage for that address and sends it as a header. The part after # never reaches the server. Without SHEPHERD_TOKEN, nothing changes. While Shepherd is stopped, another user could listen on the same port and receive the token from an open tab or agent. The browser also keeps the token for that address after the tab closes, so a server that takes the port later can read it the next time you open the dashboard. Stop open tabs and agents with Shepherd, and change the token after a while.
Set bot on a host to the login of a bot that leaves inline review comments. Shepherd counts the review threads that bot opened and that are still unresolved. It reads severity and kind when the comment opens with a bold title followed by ·-separated tags:
**Throttle check is not atomic** · fix here · medium
When the orgs on one host use different bots, give the host botsByOwner: the bot login for each org (or user) whose repos have another bot, or null for none. The host's bot stays the bot of every other owner:
"github": { "hostname": "github.com", "label": "GitHub", "bot": null, "botsByOwner": { "example-org": "example-review-bot", "other-org": "other-review-bot" } }Severities are critical, high, medium, low and info. A tag of nit, or a tail that starts with below, marks a finding as minor. Comments in any other shape still count, as info.
Some bots review again after every push. An approved PR is then not ready while the new review is on its way. Shepherd compares two times:
- When the bot last reviewed: the last edit of its newest comment on the PR, or its newest review when that is later. The newest comment is the one the bot made last. Its time is its last edit, because a bot can update its review in place.
- The date of the newest commit. GitHub gives no push time, so a commit that was made long before its push looks older than it is.
The review is current when it is not older than the newest commit. A review that is behind keeps an approved PR out of Ready to ship, and so does an unresolved fix thread. A PR that the bot has not reviewed at all is not held back. Four limits:
- Every comment and every review of the bot counts, a short reply in a thread too. This fits a bot that writes only to review.
- A bot that reviews a PR once, and not again after a push, leaves every PR behind after its next commit. Do not set such a bot as
bot. - A fix thread on code that has changed since still holds the PR until someone resolves it.
- Shepherd reads only the last 50 comments and the last 50 reviews of a PR. When the bot reviewed before those, Shepherd finds no review, and the PR is not held back.