Link a GitHub repository to the project
link_repositoryConnects a GitHub repository to the project as a linked folder. A project manager authorizes their own GitHub account using a device code, lists repositories that account can access through the installed read app, and reviews the branch, folder, readers and hidden paths. The person confirms the review before Alcoven links it. The state is an encrypted, expiring reference bound to the person and project; it contains no readable GitHub token. For a request to connect a GitHub repository to a project without opening Alcoven's repository picker.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"action": "<action>"
},
"name": "link_repository"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | No | Filter repository names in the list. | |
| state | No | The encrypted state returned by the preceding step; do not put it on the project. | |
| action | Yes | start begins GitHub authorization; poll checks it; list shows the person's repositories; review prepares a link for confirmation. | |
| branch | No | The branch to follow; defaults to the GitHub repository's default branch. | |
| folder | No | The project folder for the linked repository; defaults to its name. | |
| hidden | No | Additional paths to hide from the linked folder. | |
| offset | No | The next list position; starts at zero. | |
| project | No | The project's slug, from open_project, like acme. Not needed when a § address names the project, or when the person is on one project. | |
| repository | No | The owner/name of a repository from the list, for review. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cut | No | ||
| next | No | ||
| state | No | ||
| folder | No | ||
| linked | No | ||
| preview | No | ||
| interval | No | ||
| proposal | No | ||
| userCode | No | ||
| expiresAt | No | ||
| installUrl | No | ||
| repositories | No | ||
| verificationUrl | No |