matimo-github 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- matimo_github-0.1.0/.gitignore +63 -0
- matimo_github-0.1.0/PKG-INFO +151 -0
- matimo_github-0.1.0/README.md +137 -0
- matimo_github-0.1.0/pyproject.toml +27 -0
- matimo_github-0.1.0/src/matimo_github/__init__.py +17 -0
- matimo_github-0.1.0/src/matimo_github/tools/add-collaborator/definition.yaml +73 -0
- matimo_github-0.1.0/src/matimo_github/tools/create-issue/definition.yaml +96 -0
- matimo_github-0.1.0/src/matimo_github/tools/create-pull-request/definition.yaml +103 -0
- matimo_github-0.1.0/src/matimo_github/tools/create-release/definition.yaml +103 -0
- matimo_github-0.1.0/src/matimo_github/tools/create-repository/definition.yaml +112 -0
- matimo_github-0.1.0/src/matimo_github/tools/delete-repository/definition.yaml +51 -0
- matimo_github-0.1.0/src/matimo_github/tools/get-issue/definition.yaml +70 -0
- matimo_github-0.1.0/src/matimo_github/tools/get-repository/definition.yaml +83 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-code-alerts/definition.yaml +85 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-collaborators/definition.yaml +77 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-commits/definition.yaml +81 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-issues/definition.yaml +96 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-pull-requests/definition.yaml +93 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-releases/definition.yaml +66 -0
- matimo_github-0.1.0/src/matimo_github/tools/list-repositories/definition.yaml +79 -0
- matimo_github-0.1.0/src/matimo_github/tools/merge-pull-request/definition.yaml +88 -0
- matimo_github-0.1.0/src/matimo_github/tools/search-code/definition.yaml +75 -0
- matimo_github-0.1.0/src/matimo_github/tools/search-issues/definition.yaml +75 -0
- matimo_github-0.1.0/src/matimo_github/tools/search-repositories/definition.yaml +83 -0
- matimo_github-0.1.0/src/matimo_github/tools/search-users/definition.yaml +75 -0
- matimo_github-0.1.0/src/matimo_github/tools/update-code-alert/definition.yaml +86 -0
- matimo_github-0.1.0/src/matimo_github/tools/update-issue/definition.yaml +98 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Dependencies
|
|
2
|
+
**/node_modules/
|
|
3
|
+
package-lock.json
|
|
4
|
+
yarn.lock
|
|
5
|
+
|
|
6
|
+
# Build output
|
|
7
|
+
**/dist/
|
|
8
|
+
*.tsbuildinfo
|
|
9
|
+
|
|
10
|
+
# Python compiled / build
|
|
11
|
+
**/__pycache__/
|
|
12
|
+
*.py[cod]
|
|
13
|
+
*$py.class
|
|
14
|
+
*.egg-info/
|
|
15
|
+
*.egg
|
|
16
|
+
**/build/
|
|
17
|
+
**/.eggs/
|
|
18
|
+
**/.venv/
|
|
19
|
+
**/.mypy_cache/
|
|
20
|
+
**/.ruff_cache/
|
|
21
|
+
**/.pytest_cache/
|
|
22
|
+
|
|
23
|
+
# Test coverage
|
|
24
|
+
**/coverage/
|
|
25
|
+
**/.nyc_output/
|
|
26
|
+
|
|
27
|
+
# IDE
|
|
28
|
+
.vscode/
|
|
29
|
+
.idea/
|
|
30
|
+
*.swp
|
|
31
|
+
*.swo
|
|
32
|
+
*~
|
|
33
|
+
.DS_Store
|
|
34
|
+
|
|
35
|
+
# Environment
|
|
36
|
+
.env
|
|
37
|
+
.env.local
|
|
38
|
+
.env.*.local
|
|
39
|
+
|
|
40
|
+
# Logs
|
|
41
|
+
*.log
|
|
42
|
+
npm-debug.log*
|
|
43
|
+
yarn-debug.log*
|
|
44
|
+
yarn-error.log*
|
|
45
|
+
|
|
46
|
+
# OS
|
|
47
|
+
.DS_Store
|
|
48
|
+
Thumbs.db
|
|
49
|
+
|
|
50
|
+
# Temporary files
|
|
51
|
+
tmp/
|
|
52
|
+
temp/
|
|
53
|
+
*.tmp
|
|
54
|
+
typescript/examples/mcp/matimo-tools/.matimo-approvals.json
|
|
55
|
+
typescript/examples/mcp/matimo-tools/fetch-weather/definition.yaml
|
|
56
|
+
typescript/examples/mcp/matimo-tools/npm_downloads/definition.yaml
|
|
57
|
+
typescript/examples/mcp/matimo-tools/skills/ecosystem-health/SKILL.md
|
|
58
|
+
typescript/examples/mcp/matimo-tools/skills/matimo-health-check/SKILL.md
|
|
59
|
+
typescript/examples/mcp/matimo-tools/skills/moltbook-identity/SKILL.md
|
|
60
|
+
typescript/packages/cli/.matimo/certs/server.crt
|
|
61
|
+
typescript/packages/cli/.matimo/certs/server.key
|
|
62
|
+
typescript/examples/mcp/.matimo/certs/server.crt
|
|
63
|
+
typescript/examples/mcp/.matimo/certs/server.key
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: matimo-github
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Matimo provider — GitHub tools (repos, issues, PRs, releases)
|
|
5
|
+
License: MIT
|
|
6
|
+
Keywords: agents,ai,github,matimo,tools
|
|
7
|
+
Classifier: Development Status :: 4 - Beta
|
|
8
|
+
Classifier: Intended Audience :: Developers
|
|
9
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
10
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
11
|
+
Requires-Python: >=3.11
|
|
12
|
+
Requires-Dist: matimo-core<0.2.0,>=0.1.0
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
|
|
15
|
+
# matimo-github
|
|
16
|
+
|
|
17
|
+
> GitHub tools for [Matimo](https://matimo.dev) — manage repositories, issues, pull requests, releases, and more.
|
|
18
|
+
|
|
19
|
+
[](https://pypi.org/project/matimo-github/)
|
|
20
|
+
[](https://matimo.dev/docs)
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Installation
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
pip install matimo matimo-github
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Available Tools (27 Total)
|
|
33
|
+
|
|
34
|
+
| Category | Tool | Description |
|
|
35
|
+
|----------|------|-------------|
|
|
36
|
+
| **Repositories** | `get-repository` | Get repository details |
|
|
37
|
+
| | `list-repositories` | List repositories for user/org |
|
|
38
|
+
| | `create-repository` | Create a new repository |
|
|
39
|
+
| | `delete-repository` | Delete a repository |
|
|
40
|
+
| | `search-repositories` | Search GitHub repositories |
|
|
41
|
+
| **Issues** | `list-issues` | List issues in a repository |
|
|
42
|
+
| | `get-issue` | Get a single issue |
|
|
43
|
+
| | `create-issue` | Create a new issue |
|
|
44
|
+
| | `update-issue` | Update issue title, body, state, labels |
|
|
45
|
+
| | `search-issues` | Search issues across GitHub |
|
|
46
|
+
| **Pull Requests** | `list-pull-requests` | List PRs in a repository |
|
|
47
|
+
| | `create-pull-request` | Open a new pull request |
|
|
48
|
+
| | `merge-pull-request` | Merge a pull request |
|
|
49
|
+
| **Releases** | `list-releases` | List releases for a repository |
|
|
50
|
+
| | `create-release` | Create a new release with tag |
|
|
51
|
+
| **Commits** | `list-commits` | List commits on a branch |
|
|
52
|
+
| **Collaborators** | `list-collaborators` | List repository collaborators |
|
|
53
|
+
| | `add-collaborator` | Add a collaborator |
|
|
54
|
+
| **Code Search** | `search-code` | Search code across repositories |
|
|
55
|
+
| | `search-users` | Search GitHub users |
|
|
56
|
+
| **Security** | `list-code-alerts` | List Dependabot/code scanning alerts |
|
|
57
|
+
| | `update-code-alert` | Dismiss or resolve a code alert |
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
## Quick Start
|
|
62
|
+
|
|
63
|
+
```python
|
|
64
|
+
import asyncio
|
|
65
|
+
import os
|
|
66
|
+
from matimo import Matimo
|
|
67
|
+
from matimo_github import get_tools_path
|
|
68
|
+
|
|
69
|
+
async def main():
|
|
70
|
+
matimo = await Matimo.init(get_tools_path())
|
|
71
|
+
|
|
72
|
+
# List open issues
|
|
73
|
+
result = await matimo.execute('list-issues', {
|
|
74
|
+
'owner': 'my-org',
|
|
75
|
+
'repo': 'my-repo',
|
|
76
|
+
'state': 'open',
|
|
77
|
+
})
|
|
78
|
+
|
|
79
|
+
# Create an issue
|
|
80
|
+
await matimo.execute('create-issue', {
|
|
81
|
+
'owner': 'my-org',
|
|
82
|
+
'repo': 'my-repo',
|
|
83
|
+
'title': 'Bug: login fails on mobile',
|
|
84
|
+
'body': 'Steps to reproduce...',
|
|
85
|
+
})
|
|
86
|
+
|
|
87
|
+
asyncio.run(main())
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
## Authentication
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
export GITHUB_TOKEN="ghp_your-personal-access-token"
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Required Scopes
|
|
99
|
+
|
|
100
|
+
| Operations | Required Scope |
|
|
101
|
+
|-----------|---------------|
|
|
102
|
+
| Read public repos, issues, PRs | `public_repo` |
|
|
103
|
+
| Read private repositories | `repo` |
|
|
104
|
+
| Create/update issues, PRs | `repo` |
|
|
105
|
+
| Manage collaborators | `repo` + `admin:org` |
|
|
106
|
+
| Delete repositories | `delete_repo` |
|
|
107
|
+
| Read security alerts | `security_events` |
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
## LangChain Agent Example
|
|
112
|
+
|
|
113
|
+
```python
|
|
114
|
+
from matimo import Matimo
|
|
115
|
+
from matimo_github import get_tools_path
|
|
116
|
+
from matimo.integrations.langchain import convert_tools_to_langchain
|
|
117
|
+
from langchain_openai import ChatOpenAI
|
|
118
|
+
from langchain.agents import AgentExecutor, create_tool_calling_agent
|
|
119
|
+
from langchain_core.prompts import ChatPromptTemplate
|
|
120
|
+
|
|
121
|
+
matimo = await Matimo.init(get_tools_path())
|
|
122
|
+
lc_tools = convert_tools_to_langchain(
|
|
123
|
+
matimo.list_tools(), matimo,
|
|
124
|
+
credentials={'GITHUB_TOKEN': os.environ['GITHUB_TOKEN']},
|
|
125
|
+
)
|
|
126
|
+
llm = ChatOpenAI(model='gpt-4o-mini')
|
|
127
|
+
prompt = ChatPromptTemplate.from_messages([
|
|
128
|
+
('system', 'You are a GitHub assistant.'),
|
|
129
|
+
('human', '{input}'),
|
|
130
|
+
('placeholder', '{agent_scratchpad}'),
|
|
131
|
+
])
|
|
132
|
+
agent = create_tool_calling_agent(llm, lc_tools, prompt)
|
|
133
|
+
executor = AgentExecutor(agent=agent, tools=lc_tools)
|
|
134
|
+
result = await executor.ainvoke({'input': 'List all open issues in tallclub/matimo'})
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
139
|
+
## Documentation
|
|
140
|
+
|
|
141
|
+
- [GitHub REST API Reference](https://docs.github.com/en/rest)
|
|
142
|
+
- [Python Examples](https://github.com/tallclub/matimo/tree/main/python/examples/native/github)
|
|
143
|
+
|
|
144
|
+
---
|
|
145
|
+
|
|
146
|
+
## Links
|
|
147
|
+
|
|
148
|
+
- **PyPI:** https://pypi.org/project/matimo-github/
|
|
149
|
+
- **GitHub:** https://github.com/tallclub/matimo
|
|
150
|
+
- **GitHub Docs:** https://docs.github.com/en/rest
|
|
151
|
+
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
# matimo-github
|
|
2
|
+
|
|
3
|
+
> GitHub tools for [Matimo](https://matimo.dev) — manage repositories, issues, pull requests, releases, and more.
|
|
4
|
+
|
|
5
|
+
[](https://pypi.org/project/matimo-github/)
|
|
6
|
+
[](https://matimo.dev/docs)
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
pip install matimo matimo-github
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## Available Tools (27 Total)
|
|
19
|
+
|
|
20
|
+
| Category | Tool | Description |
|
|
21
|
+
|----------|------|-------------|
|
|
22
|
+
| **Repositories** | `get-repository` | Get repository details |
|
|
23
|
+
| | `list-repositories` | List repositories for user/org |
|
|
24
|
+
| | `create-repository` | Create a new repository |
|
|
25
|
+
| | `delete-repository` | Delete a repository |
|
|
26
|
+
| | `search-repositories` | Search GitHub repositories |
|
|
27
|
+
| **Issues** | `list-issues` | List issues in a repository |
|
|
28
|
+
| | `get-issue` | Get a single issue |
|
|
29
|
+
| | `create-issue` | Create a new issue |
|
|
30
|
+
| | `update-issue` | Update issue title, body, state, labels |
|
|
31
|
+
| | `search-issues` | Search issues across GitHub |
|
|
32
|
+
| **Pull Requests** | `list-pull-requests` | List PRs in a repository |
|
|
33
|
+
| | `create-pull-request` | Open a new pull request |
|
|
34
|
+
| | `merge-pull-request` | Merge a pull request |
|
|
35
|
+
| **Releases** | `list-releases` | List releases for a repository |
|
|
36
|
+
| | `create-release` | Create a new release with tag |
|
|
37
|
+
| **Commits** | `list-commits` | List commits on a branch |
|
|
38
|
+
| **Collaborators** | `list-collaborators` | List repository collaborators |
|
|
39
|
+
| | `add-collaborator` | Add a collaborator |
|
|
40
|
+
| **Code Search** | `search-code` | Search code across repositories |
|
|
41
|
+
| | `search-users` | Search GitHub users |
|
|
42
|
+
| **Security** | `list-code-alerts` | List Dependabot/code scanning alerts |
|
|
43
|
+
| | `update-code-alert` | Dismiss or resolve a code alert |
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## Quick Start
|
|
48
|
+
|
|
49
|
+
```python
|
|
50
|
+
import asyncio
|
|
51
|
+
import os
|
|
52
|
+
from matimo import Matimo
|
|
53
|
+
from matimo_github import get_tools_path
|
|
54
|
+
|
|
55
|
+
async def main():
|
|
56
|
+
matimo = await Matimo.init(get_tools_path())
|
|
57
|
+
|
|
58
|
+
# List open issues
|
|
59
|
+
result = await matimo.execute('list-issues', {
|
|
60
|
+
'owner': 'my-org',
|
|
61
|
+
'repo': 'my-repo',
|
|
62
|
+
'state': 'open',
|
|
63
|
+
})
|
|
64
|
+
|
|
65
|
+
# Create an issue
|
|
66
|
+
await matimo.execute('create-issue', {
|
|
67
|
+
'owner': 'my-org',
|
|
68
|
+
'repo': 'my-repo',
|
|
69
|
+
'title': 'Bug: login fails on mobile',
|
|
70
|
+
'body': 'Steps to reproduce...',
|
|
71
|
+
})
|
|
72
|
+
|
|
73
|
+
asyncio.run(main())
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
## Authentication
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
export GITHUB_TOKEN="ghp_your-personal-access-token"
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
### Required Scopes
|
|
85
|
+
|
|
86
|
+
| Operations | Required Scope |
|
|
87
|
+
|-----------|---------------|
|
|
88
|
+
| Read public repos, issues, PRs | `public_repo` |
|
|
89
|
+
| Read private repositories | `repo` |
|
|
90
|
+
| Create/update issues, PRs | `repo` |
|
|
91
|
+
| Manage collaborators | `repo` + `admin:org` |
|
|
92
|
+
| Delete repositories | `delete_repo` |
|
|
93
|
+
| Read security alerts | `security_events` |
|
|
94
|
+
|
|
95
|
+
---
|
|
96
|
+
|
|
97
|
+
## LangChain Agent Example
|
|
98
|
+
|
|
99
|
+
```python
|
|
100
|
+
from matimo import Matimo
|
|
101
|
+
from matimo_github import get_tools_path
|
|
102
|
+
from matimo.integrations.langchain import convert_tools_to_langchain
|
|
103
|
+
from langchain_openai import ChatOpenAI
|
|
104
|
+
from langchain.agents import AgentExecutor, create_tool_calling_agent
|
|
105
|
+
from langchain_core.prompts import ChatPromptTemplate
|
|
106
|
+
|
|
107
|
+
matimo = await Matimo.init(get_tools_path())
|
|
108
|
+
lc_tools = convert_tools_to_langchain(
|
|
109
|
+
matimo.list_tools(), matimo,
|
|
110
|
+
credentials={'GITHUB_TOKEN': os.environ['GITHUB_TOKEN']},
|
|
111
|
+
)
|
|
112
|
+
llm = ChatOpenAI(model='gpt-4o-mini')
|
|
113
|
+
prompt = ChatPromptTemplate.from_messages([
|
|
114
|
+
('system', 'You are a GitHub assistant.'),
|
|
115
|
+
('human', '{input}'),
|
|
116
|
+
('placeholder', '{agent_scratchpad}'),
|
|
117
|
+
])
|
|
118
|
+
agent = create_tool_calling_agent(llm, lc_tools, prompt)
|
|
119
|
+
executor = AgentExecutor(agent=agent, tools=lc_tools)
|
|
120
|
+
result = await executor.ainvoke({'input': 'List all open issues in tallclub/matimo'})
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
---
|
|
124
|
+
|
|
125
|
+
## Documentation
|
|
126
|
+
|
|
127
|
+
- [GitHub REST API Reference](https://docs.github.com/en/rest)
|
|
128
|
+
- [Python Examples](https://github.com/tallclub/matimo/tree/main/python/examples/native/github)
|
|
129
|
+
|
|
130
|
+
---
|
|
131
|
+
|
|
132
|
+
## Links
|
|
133
|
+
|
|
134
|
+
- **PyPI:** https://pypi.org/project/matimo-github/
|
|
135
|
+
- **GitHub:** https://github.com/tallclub/matimo
|
|
136
|
+
- **GitHub Docs:** https://docs.github.com/en/rest
|
|
137
|
+
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "matimo-github"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Matimo provider — GitHub tools (repos, issues, PRs, releases)"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
license = { text = "MIT" }
|
|
11
|
+
requires-python = ">=3.11"
|
|
12
|
+
keywords = ["ai", "tools", "agents", "matimo", "github"]
|
|
13
|
+
classifiers = [
|
|
14
|
+
"Development Status :: 4 - Beta",
|
|
15
|
+
"Intended Audience :: Developers",
|
|
16
|
+
"License :: OSI Approved :: MIT License",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
]
|
|
19
|
+
dependencies = [
|
|
20
|
+
"matimo-core>=0.1.0,<0.2.0",
|
|
21
|
+
]
|
|
22
|
+
|
|
23
|
+
[project.entry-points."matimo.providers"]
|
|
24
|
+
github = "matimo_github:get_tools_path"
|
|
25
|
+
|
|
26
|
+
[tool.hatch.build.targets.wheel]
|
|
27
|
+
packages = ["src/matimo_github"]
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"""Matimo github provider — exposes the path to YAML tool definitions."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
import importlib.resources
|
|
5
|
+
from pathlib import Path
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
def get_tools_path() -> str:
|
|
9
|
+
"""Return the absolute path to the bundled github tool definitions."""
|
|
10
|
+
try:
|
|
11
|
+
ref = importlib.resources.files("matimo_github") / "tools"
|
|
12
|
+
return str(ref)
|
|
13
|
+
except Exception:
|
|
14
|
+
return str(Path(__file__).parent / "tools")
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
__all__ = ["get_tools_path"]
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
name: github-add-collaborator
|
|
2
|
+
description: Add a user as a collaborator to a repository
|
|
3
|
+
version: '1.0.0'
|
|
4
|
+
requires_approval: true
|
|
5
|
+
|
|
6
|
+
parameters:
|
|
7
|
+
owner:
|
|
8
|
+
type: string
|
|
9
|
+
required: true
|
|
10
|
+
description: Repository owner username or organization
|
|
11
|
+
repo:
|
|
12
|
+
type: string
|
|
13
|
+
required: true
|
|
14
|
+
description: Repository name
|
|
15
|
+
username:
|
|
16
|
+
type: string
|
|
17
|
+
required: true
|
|
18
|
+
description: GitHub username to add
|
|
19
|
+
permission:
|
|
20
|
+
type: string
|
|
21
|
+
required: false
|
|
22
|
+
description: Permission level - pull, triage, push, maintain, or admin
|
|
23
|
+
default: push
|
|
24
|
+
|
|
25
|
+
execution:
|
|
26
|
+
type: http
|
|
27
|
+
method: PUT
|
|
28
|
+
url: 'https://api.github.com/repos/{owner}/{repo}/collaborators/{username}'
|
|
29
|
+
headers:
|
|
30
|
+
Accept: application/vnd.github+json
|
|
31
|
+
Authorization: 'Bearer {GITHUB_TOKEN}'
|
|
32
|
+
X-GitHub-Api-Version: '2022-11-28'
|
|
33
|
+
Content-Type: application/json
|
|
34
|
+
body:
|
|
35
|
+
permission: '{permission}'
|
|
36
|
+
timeout: 15000
|
|
37
|
+
|
|
38
|
+
authentication:
|
|
39
|
+
type: bearer
|
|
40
|
+
location: header
|
|
41
|
+
notes:
|
|
42
|
+
env: GITHUB_TOKEN
|
|
43
|
+
required: true
|
|
44
|
+
permission: Repository administration
|
|
45
|
+
|
|
46
|
+
output_schema:
|
|
47
|
+
type: object
|
|
48
|
+
properties:
|
|
49
|
+
id:
|
|
50
|
+
type: number
|
|
51
|
+
invitee:
|
|
52
|
+
type: object
|
|
53
|
+
permissions:
|
|
54
|
+
type: string
|
|
55
|
+
|
|
56
|
+
error_handling:
|
|
57
|
+
retry: 1
|
|
58
|
+
backoff_type: exponential
|
|
59
|
+
initial_delay_ms: 1000
|
|
60
|
+
|
|
61
|
+
examples:
|
|
62
|
+
- name: Add collaborator with push access
|
|
63
|
+
params:
|
|
64
|
+
owner: myorg
|
|
65
|
+
repo: myrepo
|
|
66
|
+
username: newuser
|
|
67
|
+
permission: push
|
|
68
|
+
- name: Add collaborator with admin access
|
|
69
|
+
params:
|
|
70
|
+
owner: myorg
|
|
71
|
+
repo: myrepo
|
|
72
|
+
username: admin_user
|
|
73
|
+
permission: admin
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
name: github-create-issue
|
|
2
|
+
description: Create a new issue in a repository
|
|
3
|
+
version: '1.0.0'
|
|
4
|
+
requires_approval: true
|
|
5
|
+
|
|
6
|
+
parameters:
|
|
7
|
+
owner:
|
|
8
|
+
type: string
|
|
9
|
+
required: true
|
|
10
|
+
description: Repository owner username or organization
|
|
11
|
+
repo:
|
|
12
|
+
type: string
|
|
13
|
+
required: true
|
|
14
|
+
description: Repository name
|
|
15
|
+
title:
|
|
16
|
+
type: string
|
|
17
|
+
required: true
|
|
18
|
+
description: Issue title
|
|
19
|
+
body:
|
|
20
|
+
type: string
|
|
21
|
+
required: false
|
|
22
|
+
description: Issue description (markdown supported)
|
|
23
|
+
assignees:
|
|
24
|
+
type: array
|
|
25
|
+
required: false
|
|
26
|
+
description: Array of github usernames to assign
|
|
27
|
+
labels:
|
|
28
|
+
type: array
|
|
29
|
+
required: false
|
|
30
|
+
description: Array of label names
|
|
31
|
+
milestone:
|
|
32
|
+
type: number
|
|
33
|
+
required: false
|
|
34
|
+
description: Milestone ID number
|
|
35
|
+
|
|
36
|
+
execution:
|
|
37
|
+
type: http
|
|
38
|
+
method: POST
|
|
39
|
+
url: 'https://api.github.com/repos/{owner}/{repo}/issues'
|
|
40
|
+
headers:
|
|
41
|
+
Accept: application/vnd.github+json
|
|
42
|
+
Authorization: 'Bearer {GITHUB_TOKEN}'
|
|
43
|
+
X-GitHub-Api-Version: '2022-11-28'
|
|
44
|
+
Content-Type: application/json
|
|
45
|
+
body:
|
|
46
|
+
title: '{title}'
|
|
47
|
+
body: '{body}'
|
|
48
|
+
assignees: '{assignees}'
|
|
49
|
+
labels: '{labels}'
|
|
50
|
+
milestone: '{milestone}'
|
|
51
|
+
timeout: 15000
|
|
52
|
+
|
|
53
|
+
authentication:
|
|
54
|
+
type: bearer
|
|
55
|
+
location: header
|
|
56
|
+
notes:
|
|
57
|
+
env: GITHUB_TOKEN
|
|
58
|
+
required: true
|
|
59
|
+
permission: Issues write
|
|
60
|
+
|
|
61
|
+
output_schema:
|
|
62
|
+
type: object
|
|
63
|
+
properties:
|
|
64
|
+
id:
|
|
65
|
+
type: number
|
|
66
|
+
number:
|
|
67
|
+
type: number
|
|
68
|
+
description: Issue number in repository
|
|
69
|
+
title:
|
|
70
|
+
type: string
|
|
71
|
+
state:
|
|
72
|
+
type: string
|
|
73
|
+
html_url:
|
|
74
|
+
type: string
|
|
75
|
+
|
|
76
|
+
error_handling:
|
|
77
|
+
retry: 1
|
|
78
|
+
backoff_type: exponential
|
|
79
|
+
initial_delay_ms: 1000
|
|
80
|
+
|
|
81
|
+
examples:
|
|
82
|
+
- name: Create simple issue
|
|
83
|
+
params:
|
|
84
|
+
owner: myorg
|
|
85
|
+
repo: myrepo
|
|
86
|
+
title: Bug in login flow
|
|
87
|
+
body: Users cannot log in with SSO
|
|
88
|
+
- name: Create issue with labels
|
|
89
|
+
params:
|
|
90
|
+
owner: myorg
|
|
91
|
+
repo: myrepo
|
|
92
|
+
title: Add dark mode
|
|
93
|
+
body: Implement dark theme
|
|
94
|
+
labels:
|
|
95
|
+
- enhancement
|
|
96
|
+
- ui
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
name: github-create-pull-request
|
|
2
|
+
description: Create a new pull request
|
|
3
|
+
version: '1.0.0'
|
|
4
|
+
requires_approval: true
|
|
5
|
+
|
|
6
|
+
parameters:
|
|
7
|
+
owner:
|
|
8
|
+
type: string
|
|
9
|
+
required: true
|
|
10
|
+
description: Repository owner username or organization
|
|
11
|
+
repo:
|
|
12
|
+
type: string
|
|
13
|
+
required: true
|
|
14
|
+
description: Repository name
|
|
15
|
+
title:
|
|
16
|
+
type: string
|
|
17
|
+
required: true
|
|
18
|
+
description: Pull request title
|
|
19
|
+
body:
|
|
20
|
+
type: string
|
|
21
|
+
required: false
|
|
22
|
+
description: Pull request description
|
|
23
|
+
head:
|
|
24
|
+
type: string
|
|
25
|
+
required: true
|
|
26
|
+
description: Head branch name or user:ref
|
|
27
|
+
base:
|
|
28
|
+
type: string
|
|
29
|
+
required: true
|
|
30
|
+
description: Base branch name
|
|
31
|
+
draft:
|
|
32
|
+
type: boolean
|
|
33
|
+
required: false
|
|
34
|
+
description: Whether PR is a draft
|
|
35
|
+
default: false
|
|
36
|
+
maintainer_can_modify:
|
|
37
|
+
type: boolean
|
|
38
|
+
required: false
|
|
39
|
+
description: Allow maintainers to edit PR
|
|
40
|
+
default: true
|
|
41
|
+
|
|
42
|
+
execution:
|
|
43
|
+
type: http
|
|
44
|
+
method: POST
|
|
45
|
+
url: 'https://api.github.com/repos/{owner}/{repo}/pulls'
|
|
46
|
+
headers:
|
|
47
|
+
Accept: application/vnd.github+json
|
|
48
|
+
Authorization: 'Bearer {GITHUB_TOKEN}'
|
|
49
|
+
X-GitHub-Api-Version: '2022-11-28'
|
|
50
|
+
Content-Type: application/json
|
|
51
|
+
body:
|
|
52
|
+
title: '{title}'
|
|
53
|
+
body: '{body}'
|
|
54
|
+
head: '{head}'
|
|
55
|
+
base: '{base}'
|
|
56
|
+
draft: '{draft}'
|
|
57
|
+
maintainer_can_modify: '{maintainer_can_modify}'
|
|
58
|
+
timeout: 15000
|
|
59
|
+
|
|
60
|
+
authentication:
|
|
61
|
+
type: bearer
|
|
62
|
+
location: header
|
|
63
|
+
notes:
|
|
64
|
+
env: GITHUB_TOKEN
|
|
65
|
+
required: true
|
|
66
|
+
permission: Pull requests write
|
|
67
|
+
|
|
68
|
+
output_schema:
|
|
69
|
+
type: object
|
|
70
|
+
properties:
|
|
71
|
+
id:
|
|
72
|
+
type: number
|
|
73
|
+
number:
|
|
74
|
+
type: number
|
|
75
|
+
title:
|
|
76
|
+
type: string
|
|
77
|
+
state:
|
|
78
|
+
type: string
|
|
79
|
+
html_url:
|
|
80
|
+
type: string
|
|
81
|
+
|
|
82
|
+
error_handling:
|
|
83
|
+
retry: 1
|
|
84
|
+
backoff_type: exponential
|
|
85
|
+
initial_delay_ms: 1000
|
|
86
|
+
|
|
87
|
+
examples:
|
|
88
|
+
- name: Create pull request
|
|
89
|
+
params:
|
|
90
|
+
owner: myorg
|
|
91
|
+
repo: myrepo
|
|
92
|
+
title: Add new feature
|
|
93
|
+
body: This PR adds support for...
|
|
94
|
+
head: feature/new-feature
|
|
95
|
+
base: main
|
|
96
|
+
- name: Create draft PR
|
|
97
|
+
params:
|
|
98
|
+
owner: myorg
|
|
99
|
+
repo: myrepo
|
|
100
|
+
title: WIP - Feature in progress
|
|
101
|
+
head: feature/experimental
|
|
102
|
+
base: main
|
|
103
|
+
draft: true
|