# GitHub Projects plugin

The GitHub Projects plugin lets a Vaubaan Gateway mission use GitHub Projects without handing the agent a credential. An organization's GitHub Projects board: its fields, views and items.

Version `0.1.0` · 5 permissions · 4 macro-actions · 12 tools · 3 gateways run this plugin (over the last 90 days).

## How GitHub Projects is modelled

1 plane, 6 things. The things that exist at the service and how they nest. Every permission is written over these; a resource of an account is one of them, named by its ref.

- **Account** — One account is one project of a GitHub organization, opened with a fine-grained personal access token.
  - Plane `project` — A GitHub Projects board of an organization: its fields, views and items.
    - `project` (1; the resource) — The resource: one project of an organization, \`\<org\>/\<number\>\`.
      - `field` (1 *) — A field of the project (text, number, date, single select, iteration).
      - `view` (1) — A saved view of the project (table, board, roadmap), by its number.
      - `item` (1 *) — A card: a linked issue or pull request, or a draft issue.
        - `value` (1) — The value of one field on one item, keyed by the field id.
        - `delete` (1) — Verb leaf: an item removed from the project, with its field values.

Marks: 1 exactly one, named; n a finite, known set; * an unknown number, possibly all.

- **Account**: One account is one project of a GitHub organization, opened with a fine-grained personal access token.
- **Resource**: It is the account's one resource. A mission reads the board, adds cards, changes their fields, removes them, or creates fields and views.
- **Environment**: No permission of this service depends on an environment: each is held once, whatever the resource. Known: none. Carried by: nothing in the model. No environment: projects carry none.

## What an agent does at GitHub Projects: 4 macro-actions

A mission is made of them: the person ticks the ones the task needs and sets each to a trust level.

1. **Read the board** — Read the project, its fields, its views and its items. Reading the board: the project, its fields, the items of a view or of the whole project. Nothing is modified, but the titles and bodies of the linked issues and pull requests are written by people outside the mission and land in the agent's context. (1 permission)
2. **Track work** — Add cards and change their fields. Keeping the board in step with the work: adding the issue or pull request an agent works on, writing a draft, moving a card to another status or iteration. Adding and changing are kept apart so a mission can move cards without filling the board. (2 permissions)
3. **Remove cards** — Remove items from the project. Taking cards off the board. A permission of its own because it cannot be undone: an issue loses the values it held on the board, a draft is deleted with its text. (1 permission)
4. **Shape the board** — Create fields and views. Changing how the board is organised: a new field for the whole team, a new saved view. Nothing is lost, but GitHub offers no way to remove them through its API: someone removes them by hand. (1 permission)

## The map

5 permissions of 4 macro-actions, in the four rows of the tree. For the chosen trust level, each cell gives yes, ask me or no, and the quota a day.

Careful ×1: Mild actions run freely; sensitive or costly ones ask first; irreversible ones are left out. Trusting ×3: Up to sensitive actions run freely; costly and irreversible ones ask first. Limits ×3. Autonomous ×10: Everything but irreversible actions runs freely; those ask first. Limits ×10.

yes: runs freely; ask me: ask me first; no: not included. A permission sits in the first row its facts answer: irreversible; costly to undo or unbounded cost; secret or personal data, whole account or bulk, moderate cost, public; otherwise harmless.

### Cannot be repaired

Careful: no. Trusting, Autonomous: ask me.

- Remove cards: Remove an item from the project `github-projects.item-delete`, irreversible — A removed issue or pull request loses every field value it held on the board; a removed draft is deleted with its text. Neither can be restored. Careful: no · Trusting: ask me · 30 a day · Autonomous: ask me · 100 a day.

### Repairable, at a price

Careful, Trusting: ask me. Autonomous: runs freely.

None.

### Worth a look

Careful: ask me. Trusting, Autonomous: runs freely.

None.

### Harmless

Runs freely at every level.

- Read the board: Read the project, its fields, views and items `github-projects.read` — Nothing is modified. Item titles and bodies come from issues and pull requests anyone in the organization may write, and land in the agent's context (OWASP LLM01). Careful: yes · 1,000 a day · Trusting: yes · 3,000 a day · Autonomous: yes · 10,000 a day.
- Track work: Add an issue, a pull request or a draft to the project `github-projects.item-add` — A new card everyone who sees the board sees, removed again in one click. An added issue can come from any repository the token reads. Careful: yes · 50 a day · Trusting: yes · 150 a day · Autonomous: yes · 500 a day.
- Track work: Change an item's fields (status, iteration, dates…) `github-projects.item-write` — Moves a card or changes what the team reads on it; the previous value can be set back. A mission can be narrowed to one field, such as the status. Careful: yes · 200 a day · Trusting: yes · 600 a day · Autonomous: yes · 2,000 a day.
- Shape the board: Create a field or a view `github-projects.board-shape` — A new column or saved view everyone on the board sees. Creating one destroys nothing; GitHub offers no API to remove it, so it is removed by hand on the board. Careful: yes · 10 a day · Trusting: yes · 30 a day · Autonomous: yes · 100 a day.

Careful: runs freely 4, ask me first 0, not included 1.
Trusting: runs freely 4, ask me first 1.
Autonomous: runs freely 4, ask me first 1.

Limits are counted over a mission's period: a day unless its creator picks another, or the mission's whole life for a one-off. The figures here are per day.

## A few calls, classified by the plugin

14 declared calls, run through the plugin's own classifier when this page was built; here one per macro-action and the first the catalog refuses at Careful. [The 14 calls, as code](https://github.com/vaubaan/gateway/blob/main/plugins/github-projects/src/examples.ts).

- `github_projects__get_project {"project":"acme/12"}`
  - the plugin sees: `github-projects.project[acme/12].R`
  - the catalog answers: Read the project, its fields, views and items `github-projects.read`
  - a Careful mission: yes
- `github_projects__add_project_item {"project":"acme/12","type":"Issue","owner":"acme","repo":"api","number":"42"}`
  - the plugin sees: `github-projects.project[acme/12].item.W`
  - the catalog answers: Add an issue, a pull request or a draft to the project `github-projects.item-add`
  - a Careful mission: yes
- `github_projects__delete_project_item {"project":"acme/12","item_id":"981"}`
  - the plugin sees: `github-projects.project[acme/12].item[981].delete.W`
  - the catalog answers: Remove an item from the project `github-projects.item-delete`
  - a Careful mission: no
- `github_projects__create_project_field {"project":"acme/12","name":"Priority","data_type":"single_select","single_select_options":[{"name":"P0","color":"RED","description":"Now"}]}`
  - the plugin sees: `github-projects.project[acme/12].field.W`
  - the catalog answers: Create a field or a view `github-projects.board-shape`
  - a Careful mission: yes

## Anything else

A call no permission covers touches `github-projects.uncategorized-write` instead of slipping through. No macro-action holds it; a person ticks it knowingly.

| Permission | Risk | Careful ×1 | Trusting ×3 | Autonomous ×10 |
| --- | --- | --- | --- | --- |
| Uncategorized write `github-projects.uncategorized-write`: Catch-all for writes without a dedicated entry. A mission creator who includes it allows the writes this catalog has not reviewed. | Repairable, at a price (costly to undo) | ask me · 50 a day | ask me · 150 a day | yes · 500 a day |

Left out on purpose — tools of the service this plugin does not expose:

- `github_projects__list_projects`: list\_projects reads every project of the organization; this account is one project: call get\_project.

## Tools

12 tools. A tool's permissions depend on its arguments, so a mission is made of the macro-actions above, not of tools.

| Tool | What it does | Usually touches |
| --- | --- | --- |
| `github_projects__get_project` | Read the project | `github-projects.read` |
| `github_projects__list_project_fields` | List the fields of the project | `github-projects.read` |
| `github_projects__get_project_field` | Read a field | `github-projects.read` |
| `github_projects__list_project_items` | List the items of the project | `github-projects.read` |
| `github_projects__get_project_item` | Read an item | `github-projects.read` |
| `github_projects__list_project_view_items` | List the items of a view | `github-projects.read` |
| `github_projects__add_project_item` | Add an issue or pull request | `github-projects.item-add` |
| `github_projects__add_project_draft` | Add a draft issue | `github-projects.item-add` |
| `github_projects__update_project_item` | Change an item's fields | `github-projects.item-write` |
| `github_projects__delete_project_item` | Remove an item from the project | `github-projects.item-delete` |
| `github_projects__create_project_field` | Create a field | `github-projects.board-shape` |
| `github_projects__create_project_view` | Create a view | `github-projects.board-shape` |

## Connecting an account

**1 of 3 · a key you create and paste** — `fine-grained personal access token`

A fine-grained personal access token the person creates at GitHub Projects and pastes once; nobody declares anything beforehand.

**Resource owner and repository access** — The organization, All repositories, Projects read and write. GitHub grants Projects for the whole organization, and a card can link an issue of any of its repositories. This gateway keeps every mission to the one project of this account, and to the acts it names.

1. Sign in to GitHub as the account the agents will act as, a member of the organization.
2. **Settings › Developer settings › Personal access tokens › Fine-grained tokens › Generate new token** — Open the page and start a new fine-grained token. ([open](https://github.com/settings/personal-access-tokens))
3. **Resource owner** — Choose the organization that owns the project.
4. **Repository access › All repositories** — Choose All repositories, so the cards of every repository can be read.
5. **Permissions** — Tick every permission below at the access shown, under each of the two lists.
6. **Generate token** — Generate the token, copy it, and paste it here with the organization and the project number. GitHub shows it once.

| Permission at GitHub Projects | Access |
| --- | --- |
| Issues | read |
| Pull requests | read |
| Projects | read-write |

Where: [https://github.com/settings/personal-access-tokens](https://github.com/settings/personal-access-tokens)

Expiry: the service tells the gateway the date, and the account page warns before it.

The connect page asks: Fine-grained personal access token (secret), Organization, Project number.

The service's documentation: [https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens)

Disconnecting: Delete the token on GitHub: Settings, Developer settings, Personal access tokens, Fine-grained tokens.

## Health

3 gateways run this plugin (over the last 90 days).

| Version | Gateways | Calls | Success | Validated |
| --- | --- | --- | --- | --- |
| `0.1.0` | 3 | no call yet | — |  |

A version is marked validated by the community with at least 200 reports and a success rate of at least 90 %, over the last 90 days; a gateway shows that mark on the accounts of this service. The figures are refreshed at most hourly ([what they mean](/plugins/health)). It is a community signal, not a security guarantee.

Calls are counted over the last 90 days from the instances that share plugin health. Gateways are counted over the same window among the instances that also share usage statistics, so they are a lower bound. The success rate leaves out calls refused for a rejected credential: a revoked token is the user's configuration, not the plugin.

## Links

- [Connect a GitHub Projects account](/plugins/github-projects#connect)
- [How GitHub Projects is modelled](https://github.com/vaubaan/gateway/blob/main/docs/handbook/services/github-projects.md)
- [The catalog, as code](https://github.com/vaubaan/gateway/blob/main/plugins/github-projects/src/risk-catalog.yaml)
- [The plugin source](https://github.com/vaubaan/gateway/tree/main/plugins/github-projects)
- The page: [/plugins/github-projects](/plugins/github-projects)
