adoptai-mcp 1.0.0
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.
- package/README.md +70 -0
- package/bin/adoptai-mcp.js +2 -0
- package/dist/apps/canva.js +1 -0
- package/dist/apps/figma.js +1 -0
- package/dist/apps/github.js +2 -0
- package/dist/apps/notion.js +1 -0
- package/dist/apps/registry.js +20 -0
- package/dist/apps/salesforce.js +1 -0
- package/dist/cli/add.js +532 -0
- package/dist/cli/index.js +39 -0
- package/dist/cli/list.js +19 -0
- package/dist/cli/remove.js +37 -0
- package/dist/cli/serve.js +27 -0
- package/dist/cli/status.js +24 -0
- package/dist/config/clients.js +118 -0
- package/dist/config/credentials.js +34 -0
- package/dist/core/auth-manager.js +237 -0
- package/dist/core/config-writer.js +161 -0
- package/dist/core/doctor.js +199 -0
- package/dist/core/package.json +3 -0
- package/dist/core/server-base.js +81 -0
- package/dist/integrations/canva/.env +3 -0
- package/dist/integrations/canva/auth.js +287 -0
- package/dist/integrations/canva/env.js +9 -0
- package/dist/integrations/canva/index.js +12 -0
- package/dist/integrations/canva/package.json +31 -0
- package/dist/integrations/canva/publish-to-adoptai.js +365 -0
- package/dist/integrations/canva/setup.js +90 -0
- package/dist/integrations/canva/tools.js +1315 -0
- package/dist/integrations/canva/tools.original.js +1315 -0
- package/dist/integrations/figma/auth.js +48 -0
- package/dist/integrations/figma/index.js +11 -0
- package/dist/integrations/figma/package.json +27 -0
- package/dist/integrations/figma/publish-to-adoptai.js +384 -0
- package/dist/integrations/figma/setup.js +90 -0
- package/dist/integrations/figma/tools.js +1137 -0
- package/dist/integrations/github/auth.js +53 -0
- package/dist/integrations/github/index.js +11 -0
- package/dist/integrations/github/package.json +28 -0
- package/dist/integrations/github/publish-to-adoptai.js +240 -0
- package/dist/integrations/github/setup.js +103 -0
- package/dist/integrations/github/tools.js +78 -0
- package/dist/integrations/github-actions/auth.js +53 -0
- package/dist/integrations/github-actions/index.js +11 -0
- package/dist/integrations/github-actions/package.json +27 -0
- package/dist/integrations/github-actions/setup.js +103 -0
- package/dist/integrations/github-actions/tools.js +5642 -0
- package/dist/integrations/github-activity/auth.js +53 -0
- package/dist/integrations/github-activity/index.js +11 -0
- package/dist/integrations/github-activity/package.json +27 -0
- package/dist/integrations/github-activity/setup.js +103 -0
- package/dist/integrations/github-activity/tools.js +925 -0
- package/dist/integrations/github-apps/auth.js +53 -0
- package/dist/integrations/github-apps/index.js +11 -0
- package/dist/integrations/github-apps/package.json +27 -0
- package/dist/integrations/github-apps/setup.js +103 -0
- package/dist/integrations/github-apps/tools.js +791 -0
- package/dist/integrations/github-billing/auth.js +53 -0
- package/dist/integrations/github-billing/index.js +11 -0
- package/dist/integrations/github-billing/package.json +27 -0
- package/dist/integrations/github-billing/setup.js +103 -0
- package/dist/integrations/github-billing/tools.js +438 -0
- package/dist/integrations/github-checks/auth.js +53 -0
- package/dist/integrations/github-checks/index.js +11 -0
- package/dist/integrations/github-checks/package.json +27 -0
- package/dist/integrations/github-checks/setup.js +103 -0
- package/dist/integrations/github-checks/tools.js +607 -0
- package/dist/integrations/github-code-scanning/auth.js +53 -0
- package/dist/integrations/github-code-scanning/index.js +11 -0
- package/dist/integrations/github-code-scanning/package.json +27 -0
- package/dist/integrations/github-code-scanning/setup.js +103 -0
- package/dist/integrations/github-code-scanning/tools.js +987 -0
- package/dist/integrations/github-dependabot/auth.js +53 -0
- package/dist/integrations/github-dependabot/index.js +11 -0
- package/dist/integrations/github-dependabot/package.json +27 -0
- package/dist/integrations/github-dependabot/setup.js +103 -0
- package/dist/integrations/github-dependabot/tools.js +915 -0
- package/dist/integrations/github-gists/auth.js +53 -0
- package/dist/integrations/github-gists/index.js +11 -0
- package/dist/integrations/github-gists/package.json +27 -0
- package/dist/integrations/github-gists/setup.js +103 -0
- package/dist/integrations/github-gists/tools.js +545 -0
- package/dist/integrations/github-git/auth.js +53 -0
- package/dist/integrations/github-git/index.js +11 -0
- package/dist/integrations/github-git/package.json +27 -0
- package/dist/integrations/github-git/setup.js +103 -0
- package/dist/integrations/github-git/tools.js +513 -0
- package/dist/integrations/github-issues/auth.js +53 -0
- package/dist/integrations/github-issues/index.js +11 -0
- package/dist/integrations/github-issues/package.json +27 -0
- package/dist/integrations/github-issues/setup.js +103 -0
- package/dist/integrations/github-issues/tools.js +2232 -0
- package/dist/integrations/github-orgs/auth.js +53 -0
- package/dist/integrations/github-orgs/index.js +11 -0
- package/dist/integrations/github-orgs/package.json +27 -0
- package/dist/integrations/github-orgs/setup.js +103 -0
- package/dist/integrations/github-orgs/tools.js +3512 -0
- package/dist/integrations/github-packages/auth.js +53 -0
- package/dist/integrations/github-packages/index.js +11 -0
- package/dist/integrations/github-packages/package.json +27 -0
- package/dist/integrations/github-packages/setup.js +103 -0
- package/dist/integrations/github-packages/tools.js +1088 -0
- package/dist/integrations/github-pulls/auth.js +53 -0
- package/dist/integrations/github-pulls/index.js +11 -0
- package/dist/integrations/github-pulls/package.json +27 -0
- package/dist/integrations/github-pulls/setup.js +103 -0
- package/dist/integrations/github-pulls/tools.js +1252 -0
- package/dist/integrations/github-reactions/auth.js +53 -0
- package/dist/integrations/github-reactions/index.js +11 -0
- package/dist/integrations/github-reactions/package.json +27 -0
- package/dist/integrations/github-reactions/setup.js +103 -0
- package/dist/integrations/github-reactions/tools.js +706 -0
- package/dist/integrations/github-repos/auth.js +53 -0
- package/dist/integrations/github-repos/index.js +11 -0
- package/dist/integrations/github-repos/package.json +27 -0
- package/dist/integrations/github-repos/setup.js +103 -0
- package/dist/integrations/github-repos/tools.js +7286 -0
- package/dist/integrations/github-search/auth.js +53 -0
- package/dist/integrations/github-search/index.js +11 -0
- package/dist/integrations/github-search/package.json +27 -0
- package/dist/integrations/github-search/setup.js +103 -0
- package/dist/integrations/github-search/tools.js +370 -0
- package/dist/integrations/github-teams/auth.js +53 -0
- package/dist/integrations/github-teams/index.js +11 -0
- package/dist/integrations/github-teams/package.json +27 -0
- package/dist/integrations/github-teams/setup.js +103 -0
- package/dist/integrations/github-teams/tools.js +633 -0
- package/dist/integrations/github-users/auth.js +53 -0
- package/dist/integrations/github-users/index.js +11 -0
- package/dist/integrations/github-users/package.json +27 -0
- package/dist/integrations/github-users/setup.js +103 -0
- package/dist/integrations/github-users/tools.js +1118 -0
- package/dist/integrations/notion/api.js +108 -0
- package/dist/integrations/notion/auth.js +59 -0
- package/dist/integrations/notion/endpoints.json +630 -0
- package/dist/integrations/notion/index.js +11 -0
- package/dist/integrations/notion/package.json +33 -0
- package/dist/integrations/notion/publish-to-adoptai.js +271 -0
- package/dist/integrations/notion/scripts/generate-endpoints.mjs +306 -0
- package/dist/integrations/notion/setup.js +89 -0
- package/dist/integrations/notion/tools.js +586 -0
- package/dist/integrations/notion/tools.original.js +568 -0
- package/dist/integrations/salesforce/.env +8 -0
- package/dist/integrations/salesforce/.env.example +15 -0
- package/dist/integrations/salesforce/auth.js +311 -0
- package/dist/integrations/salesforce/endpoints.json +1359 -0
- package/dist/integrations/salesforce/env.js +9 -0
- package/dist/integrations/salesforce/index.js +12 -0
- package/dist/integrations/salesforce/package.json +42 -0
- package/dist/integrations/salesforce/publish-smart-specs.js +890 -0
- package/dist/integrations/salesforce/publish-to-adoptai.js +386 -0
- package/dist/integrations/salesforce/scripts/extract-postman.mjs +222 -0
- package/dist/integrations/salesforce/setup.js +112 -0
- package/dist/integrations/salesforce/tools.js +4544 -0
- package/dist/integrations/salesforce/tools.original.js +4487 -0
- package/dist/server/mcp-server.js +50 -0
- package/dist/server/tool-loader.js +47 -0
- package/dist/specs/figma-api.json +13621 -0
- package/dist/specs/split/salesforce-auth.json +3931 -0
- package/dist/specs/split/salesforce-bulk-v1.json +1489 -0
- package/dist/specs/split/salesforce-bulk-v2.json +1951 -0
- package/dist/specs/split/salesforce-composite.json +1246 -0
- package/dist/specs/split/salesforce-connect.json +11639 -0
- package/dist/specs/split/salesforce-einstein-prediction-service.json +576 -0
- package/dist/specs/split/salesforce-event-platform.json +2682 -0
- package/dist/specs/split/salesforce-graphql.json +1754 -0
- package/dist/specs/split/salesforce-industries.json +4115 -0
- package/dist/specs/split/salesforce-metadata.json +555 -0
- package/dist/specs/split/salesforce-rest.json +4798 -0
- package/dist/specs/split/salesforce-soap.json +210 -0
- package/dist/specs/split/salesforce-subscription-management.json +1299 -0
- package/dist/specs/split/salesforce-tooling.json +2026 -0
- package/dist/specs/split/salesforce-ui.json +7426 -0
- package/package.json +47 -0
|
@@ -0,0 +1,925 @@
|
|
|
1
|
+
import axios from 'axios';
|
|
2
|
+
import { buildAuthHeaders } from './auth.js';
|
|
3
|
+
|
|
4
|
+
const BASE_URL = 'https://api.github.com';
|
|
5
|
+
const APP_ID = 'github-activity';
|
|
6
|
+
|
|
7
|
+
function handleError(err) {
|
|
8
|
+
const status = err.response?.status;
|
|
9
|
+
const msg = err.response?.data?.message || err.response?.data?.error || err.message;
|
|
10
|
+
if (status === 401) throw new Error(`Token invalid.\nRun: npx adoptai-${APP_ID}-mcp --client cursor`);
|
|
11
|
+
if (status === 403) throw new Error('Insufficient permissions. Check your API key scopes.');
|
|
12
|
+
if (status === 404) throw new Error('Resource not found. Check your parameters.');
|
|
13
|
+
if (status === 429) throw new Error('Rate limit exceeded. Please wait and try again.');
|
|
14
|
+
throw new Error(msg || 'API request failed');
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
async function apiRequest(method, pathTemplate, params = {}, opts = {}) {
|
|
18
|
+
const { deleteSendsJsonBody = false } = opts;
|
|
19
|
+
const headers = buildAuthHeaders();
|
|
20
|
+
let url = BASE_URL + pathTemplate;
|
|
21
|
+
const pathKeys = [...pathTemplate.matchAll(/\{([^}]+)\}/g)].map((m) => m[1]);
|
|
22
|
+
for (const key of pathKeys) {
|
|
23
|
+
const value = params[key];
|
|
24
|
+
if (value !== undefined && value !== null) url = url.replace(`{${key}}`, encodeURIComponent(String(value)));
|
|
25
|
+
}
|
|
26
|
+
const rest = { ...params };
|
|
27
|
+
for (const key of pathKeys) delete rest[key];
|
|
28
|
+
const m = method.toUpperCase();
|
|
29
|
+
const useQuery = m === 'GET' || (m === 'DELETE' && !deleteSendsJsonBody);
|
|
30
|
+
const queryParams = {};
|
|
31
|
+
const bodyParams = {};
|
|
32
|
+
for (const [key, value] of Object.entries(rest)) {
|
|
33
|
+
if (value === undefined) continue;
|
|
34
|
+
if (useQuery) queryParams[key] = value; else bodyParams[key] = value;
|
|
35
|
+
}
|
|
36
|
+
try {
|
|
37
|
+
const res = await axios({
|
|
38
|
+
method: m,
|
|
39
|
+
url,
|
|
40
|
+
headers: { 'Content-Type': 'application/json', ...headers },
|
|
41
|
+
params: Object.keys(queryParams).length ? queryParams : undefined,
|
|
42
|
+
data: Object.keys(bodyParams).length ? bodyParams : undefined,
|
|
43
|
+
timeout: 30000,
|
|
44
|
+
});
|
|
45
|
+
if (res.status === 204 || res.data === '' || res.data === undefined) return { ok: true, status: res.status };
|
|
46
|
+
return res.data;
|
|
47
|
+
} catch (err) {
|
|
48
|
+
handleError(err);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
const ENDPOINTS = [
|
|
53
|
+
{
|
|
54
|
+
"name": "activity_list_public_events",
|
|
55
|
+
"description": "List public events",
|
|
56
|
+
"method": "GET",
|
|
57
|
+
"path": "/events",
|
|
58
|
+
"deleteSendsJsonBody": false,
|
|
59
|
+
"inputSchema": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"properties": {
|
|
62
|
+
"per_page": {
|
|
63
|
+
"type": "number",
|
|
64
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
65
|
+
},
|
|
66
|
+
"page": {
|
|
67
|
+
"type": "number",
|
|
68
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
"required": []
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"name": "activity_get_feeds",
|
|
76
|
+
"description": "Get feeds",
|
|
77
|
+
"method": "GET",
|
|
78
|
+
"path": "/feeds",
|
|
79
|
+
"deleteSendsJsonBody": false,
|
|
80
|
+
"inputSchema": {
|
|
81
|
+
"type": "object",
|
|
82
|
+
"properties": {},
|
|
83
|
+
"required": []
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"name": "activity_list_public_events_for_repo_network",
|
|
88
|
+
"description": "List public events for a network of repositories",
|
|
89
|
+
"method": "GET",
|
|
90
|
+
"path": "/networks/{owner}/{repo}/events",
|
|
91
|
+
"deleteSendsJsonBody": false,
|
|
92
|
+
"inputSchema": {
|
|
93
|
+
"type": "object",
|
|
94
|
+
"properties": {
|
|
95
|
+
"owner": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
98
|
+
},
|
|
99
|
+
"repo": {
|
|
100
|
+
"type": "string",
|
|
101
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
102
|
+
},
|
|
103
|
+
"per_page": {
|
|
104
|
+
"type": "number",
|
|
105
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
106
|
+
},
|
|
107
|
+
"page": {
|
|
108
|
+
"type": "number",
|
|
109
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
"required": [
|
|
113
|
+
"owner",
|
|
114
|
+
"repo"
|
|
115
|
+
]
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"name": "activity_list_notifications_for_authenticated_user",
|
|
120
|
+
"description": "List notifications for the authenticated user",
|
|
121
|
+
"method": "GET",
|
|
122
|
+
"path": "/notifications",
|
|
123
|
+
"deleteSendsJsonBody": false,
|
|
124
|
+
"inputSchema": {
|
|
125
|
+
"type": "object",
|
|
126
|
+
"properties": {
|
|
127
|
+
"all": {
|
|
128
|
+
"type": "boolean",
|
|
129
|
+
"description": "If `true`, show notifications marked as read."
|
|
130
|
+
},
|
|
131
|
+
"participating": {
|
|
132
|
+
"type": "boolean",
|
|
133
|
+
"description": "If `true`, only shows notifications in which the user is directly participating or mentioned."
|
|
134
|
+
},
|
|
135
|
+
"since": {
|
|
136
|
+
"type": "string",
|
|
137
|
+
"description": "Only show results that were last updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`."
|
|
138
|
+
},
|
|
139
|
+
"before": {
|
|
140
|
+
"type": "string",
|
|
141
|
+
"description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`."
|
|
142
|
+
},
|
|
143
|
+
"page": {
|
|
144
|
+
"type": "number",
|
|
145
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
146
|
+
},
|
|
147
|
+
"per_page": {
|
|
148
|
+
"type": "number",
|
|
149
|
+
"description": "The number of results per page (max 50). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
150
|
+
}
|
|
151
|
+
},
|
|
152
|
+
"required": []
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
"name": "activity_mark_notifications_as_read",
|
|
157
|
+
"description": "Mark notifications as read",
|
|
158
|
+
"method": "PUT",
|
|
159
|
+
"path": "/notifications",
|
|
160
|
+
"deleteSendsJsonBody": false,
|
|
161
|
+
"inputSchema": {
|
|
162
|
+
"type": "object",
|
|
163
|
+
"properties": {
|
|
164
|
+
"last_read_at": {
|
|
165
|
+
"type": "string",
|
|
166
|
+
"description": "Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. Default: The current timestamp."
|
|
167
|
+
},
|
|
168
|
+
"read": {
|
|
169
|
+
"type": "boolean",
|
|
170
|
+
"description": "Whether the notification has been read."
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
"required": []
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"name": "activity_get_thread",
|
|
178
|
+
"description": "Get a thread",
|
|
179
|
+
"method": "GET",
|
|
180
|
+
"path": "/notifications/threads/{thread_id}",
|
|
181
|
+
"deleteSendsJsonBody": false,
|
|
182
|
+
"inputSchema": {
|
|
183
|
+
"type": "object",
|
|
184
|
+
"properties": {
|
|
185
|
+
"thread_id": {
|
|
186
|
+
"type": "number",
|
|
187
|
+
"description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/rest/activity/notifications#list-notifications-for-the-authenticated-user))."
|
|
188
|
+
}
|
|
189
|
+
},
|
|
190
|
+
"required": [
|
|
191
|
+
"thread_id"
|
|
192
|
+
]
|
|
193
|
+
}
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"name": "activity_mark_thread_as_read",
|
|
197
|
+
"description": "Mark a thread as read",
|
|
198
|
+
"method": "PATCH",
|
|
199
|
+
"path": "/notifications/threads/{thread_id}",
|
|
200
|
+
"deleteSendsJsonBody": false,
|
|
201
|
+
"inputSchema": {
|
|
202
|
+
"type": "object",
|
|
203
|
+
"properties": {
|
|
204
|
+
"thread_id": {
|
|
205
|
+
"type": "number",
|
|
206
|
+
"description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/rest/activity/notifications#list-notifications-for-the-authenticated-user))."
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
"required": [
|
|
210
|
+
"thread_id"
|
|
211
|
+
]
|
|
212
|
+
}
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
"name": "activity_mark_thread_as_done",
|
|
216
|
+
"description": "Mark a thread as done",
|
|
217
|
+
"method": "DELETE",
|
|
218
|
+
"path": "/notifications/threads/{thread_id}",
|
|
219
|
+
"deleteSendsJsonBody": false,
|
|
220
|
+
"inputSchema": {
|
|
221
|
+
"type": "object",
|
|
222
|
+
"properties": {
|
|
223
|
+
"thread_id": {
|
|
224
|
+
"type": "number",
|
|
225
|
+
"description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/rest/activity/notifications#list-notifications-for-the-authenticated-user))."
|
|
226
|
+
}
|
|
227
|
+
},
|
|
228
|
+
"required": [
|
|
229
|
+
"thread_id"
|
|
230
|
+
]
|
|
231
|
+
}
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
"name": "activity_get_thread_subscription_for_authenticated_user",
|
|
235
|
+
"description": "Get a thread subscription for the authenticated user",
|
|
236
|
+
"method": "GET",
|
|
237
|
+
"path": "/notifications/threads/{thread_id}/subscription",
|
|
238
|
+
"deleteSendsJsonBody": false,
|
|
239
|
+
"inputSchema": {
|
|
240
|
+
"type": "object",
|
|
241
|
+
"properties": {
|
|
242
|
+
"thread_id": {
|
|
243
|
+
"type": "number",
|
|
244
|
+
"description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/rest/activity/notifications#list-notifications-for-the-authenticated-user))."
|
|
245
|
+
}
|
|
246
|
+
},
|
|
247
|
+
"required": [
|
|
248
|
+
"thread_id"
|
|
249
|
+
]
|
|
250
|
+
}
|
|
251
|
+
},
|
|
252
|
+
{
|
|
253
|
+
"name": "activity_set_thread_subscription",
|
|
254
|
+
"description": "Set a thread subscription",
|
|
255
|
+
"method": "PUT",
|
|
256
|
+
"path": "/notifications/threads/{thread_id}/subscription",
|
|
257
|
+
"deleteSendsJsonBody": false,
|
|
258
|
+
"inputSchema": {
|
|
259
|
+
"type": "object",
|
|
260
|
+
"properties": {
|
|
261
|
+
"thread_id": {
|
|
262
|
+
"type": "number",
|
|
263
|
+
"description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/rest/activity/notifications#list-notifications-for-the-authenticated-user))."
|
|
264
|
+
},
|
|
265
|
+
"ignored": {
|
|
266
|
+
"type": "boolean",
|
|
267
|
+
"description": "Whether to block all notifications from a thread."
|
|
268
|
+
}
|
|
269
|
+
},
|
|
270
|
+
"required": [
|
|
271
|
+
"thread_id"
|
|
272
|
+
]
|
|
273
|
+
}
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
"name": "activity_delete_thread_subscription",
|
|
277
|
+
"description": "Delete a thread subscription",
|
|
278
|
+
"method": "DELETE",
|
|
279
|
+
"path": "/notifications/threads/{thread_id}/subscription",
|
|
280
|
+
"deleteSendsJsonBody": false,
|
|
281
|
+
"inputSchema": {
|
|
282
|
+
"type": "object",
|
|
283
|
+
"properties": {
|
|
284
|
+
"thread_id": {
|
|
285
|
+
"type": "number",
|
|
286
|
+
"description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/rest/activity/notifications#list-notifications-for-the-authenticated-user))."
|
|
287
|
+
}
|
|
288
|
+
},
|
|
289
|
+
"required": [
|
|
290
|
+
"thread_id"
|
|
291
|
+
]
|
|
292
|
+
}
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"name": "activity_list_public_org_events",
|
|
296
|
+
"description": "List public organization events",
|
|
297
|
+
"method": "GET",
|
|
298
|
+
"path": "/orgs/{org}/events",
|
|
299
|
+
"deleteSendsJsonBody": false,
|
|
300
|
+
"inputSchema": {
|
|
301
|
+
"type": "object",
|
|
302
|
+
"properties": {
|
|
303
|
+
"org": {
|
|
304
|
+
"type": "string",
|
|
305
|
+
"description": "The organization name. The name is not case sensitive."
|
|
306
|
+
},
|
|
307
|
+
"per_page": {
|
|
308
|
+
"type": "number",
|
|
309
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
310
|
+
},
|
|
311
|
+
"page": {
|
|
312
|
+
"type": "number",
|
|
313
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
"required": [
|
|
317
|
+
"org"
|
|
318
|
+
]
|
|
319
|
+
}
|
|
320
|
+
},
|
|
321
|
+
{
|
|
322
|
+
"name": "activity_list_repo_events",
|
|
323
|
+
"description": "List repository events",
|
|
324
|
+
"method": "GET",
|
|
325
|
+
"path": "/repos/{owner}/{repo}/events",
|
|
326
|
+
"deleteSendsJsonBody": false,
|
|
327
|
+
"inputSchema": {
|
|
328
|
+
"type": "object",
|
|
329
|
+
"properties": {
|
|
330
|
+
"owner": {
|
|
331
|
+
"type": "string",
|
|
332
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
333
|
+
},
|
|
334
|
+
"repo": {
|
|
335
|
+
"type": "string",
|
|
336
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
337
|
+
},
|
|
338
|
+
"per_page": {
|
|
339
|
+
"type": "number",
|
|
340
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
341
|
+
},
|
|
342
|
+
"page": {
|
|
343
|
+
"type": "number",
|
|
344
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
345
|
+
}
|
|
346
|
+
},
|
|
347
|
+
"required": [
|
|
348
|
+
"owner",
|
|
349
|
+
"repo"
|
|
350
|
+
]
|
|
351
|
+
}
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"name": "activity_list_repo_notifications_for_authenticated_user",
|
|
355
|
+
"description": "List repository notifications for the authenticated user",
|
|
356
|
+
"method": "GET",
|
|
357
|
+
"path": "/repos/{owner}/{repo}/notifications",
|
|
358
|
+
"deleteSendsJsonBody": false,
|
|
359
|
+
"inputSchema": {
|
|
360
|
+
"type": "object",
|
|
361
|
+
"properties": {
|
|
362
|
+
"owner": {
|
|
363
|
+
"type": "string",
|
|
364
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
365
|
+
},
|
|
366
|
+
"repo": {
|
|
367
|
+
"type": "string",
|
|
368
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
369
|
+
},
|
|
370
|
+
"all": {
|
|
371
|
+
"type": "boolean",
|
|
372
|
+
"description": "If `true`, show notifications marked as read."
|
|
373
|
+
},
|
|
374
|
+
"participating": {
|
|
375
|
+
"type": "boolean",
|
|
376
|
+
"description": "If `true`, only shows notifications in which the user is directly participating or mentioned."
|
|
377
|
+
},
|
|
378
|
+
"since": {
|
|
379
|
+
"type": "string",
|
|
380
|
+
"description": "Only show results that were last updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`."
|
|
381
|
+
},
|
|
382
|
+
"before": {
|
|
383
|
+
"type": "string",
|
|
384
|
+
"description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`."
|
|
385
|
+
},
|
|
386
|
+
"per_page": {
|
|
387
|
+
"type": "number",
|
|
388
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
389
|
+
},
|
|
390
|
+
"page": {
|
|
391
|
+
"type": "number",
|
|
392
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
393
|
+
}
|
|
394
|
+
},
|
|
395
|
+
"required": [
|
|
396
|
+
"owner",
|
|
397
|
+
"repo"
|
|
398
|
+
]
|
|
399
|
+
}
|
|
400
|
+
},
|
|
401
|
+
{
|
|
402
|
+
"name": "activity_mark_repo_notifications_as_read",
|
|
403
|
+
"description": "Mark repository notifications as read",
|
|
404
|
+
"method": "PUT",
|
|
405
|
+
"path": "/repos/{owner}/{repo}/notifications",
|
|
406
|
+
"deleteSendsJsonBody": false,
|
|
407
|
+
"inputSchema": {
|
|
408
|
+
"type": "object",
|
|
409
|
+
"properties": {
|
|
410
|
+
"owner": {
|
|
411
|
+
"type": "string",
|
|
412
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
413
|
+
},
|
|
414
|
+
"repo": {
|
|
415
|
+
"type": "string",
|
|
416
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
417
|
+
},
|
|
418
|
+
"last_read_at": {
|
|
419
|
+
"type": "string",
|
|
420
|
+
"description": "Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. Default: The current timestamp."
|
|
421
|
+
}
|
|
422
|
+
},
|
|
423
|
+
"required": [
|
|
424
|
+
"owner",
|
|
425
|
+
"repo"
|
|
426
|
+
]
|
|
427
|
+
}
|
|
428
|
+
},
|
|
429
|
+
{
|
|
430
|
+
"name": "activity_list_stargazers_for_repo",
|
|
431
|
+
"description": "List stargazers",
|
|
432
|
+
"method": "GET",
|
|
433
|
+
"path": "/repos/{owner}/{repo}/stargazers",
|
|
434
|
+
"deleteSendsJsonBody": false,
|
|
435
|
+
"inputSchema": {
|
|
436
|
+
"type": "object",
|
|
437
|
+
"properties": {
|
|
438
|
+
"owner": {
|
|
439
|
+
"type": "string",
|
|
440
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
441
|
+
},
|
|
442
|
+
"repo": {
|
|
443
|
+
"type": "string",
|
|
444
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
445
|
+
},
|
|
446
|
+
"per_page": {
|
|
447
|
+
"type": "number",
|
|
448
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
449
|
+
},
|
|
450
|
+
"page": {
|
|
451
|
+
"type": "number",
|
|
452
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
453
|
+
}
|
|
454
|
+
},
|
|
455
|
+
"required": [
|
|
456
|
+
"owner",
|
|
457
|
+
"repo"
|
|
458
|
+
]
|
|
459
|
+
}
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
"name": "activity_list_watchers_for_repo",
|
|
463
|
+
"description": "List watchers",
|
|
464
|
+
"method": "GET",
|
|
465
|
+
"path": "/repos/{owner}/{repo}/subscribers",
|
|
466
|
+
"deleteSendsJsonBody": false,
|
|
467
|
+
"inputSchema": {
|
|
468
|
+
"type": "object",
|
|
469
|
+
"properties": {
|
|
470
|
+
"owner": {
|
|
471
|
+
"type": "string",
|
|
472
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
473
|
+
},
|
|
474
|
+
"repo": {
|
|
475
|
+
"type": "string",
|
|
476
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
477
|
+
},
|
|
478
|
+
"per_page": {
|
|
479
|
+
"type": "number",
|
|
480
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
481
|
+
},
|
|
482
|
+
"page": {
|
|
483
|
+
"type": "number",
|
|
484
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
485
|
+
}
|
|
486
|
+
},
|
|
487
|
+
"required": [
|
|
488
|
+
"owner",
|
|
489
|
+
"repo"
|
|
490
|
+
]
|
|
491
|
+
}
|
|
492
|
+
},
|
|
493
|
+
{
|
|
494
|
+
"name": "activity_get_repo_subscription",
|
|
495
|
+
"description": "Get a repository subscription",
|
|
496
|
+
"method": "GET",
|
|
497
|
+
"path": "/repos/{owner}/{repo}/subscription",
|
|
498
|
+
"deleteSendsJsonBody": false,
|
|
499
|
+
"inputSchema": {
|
|
500
|
+
"type": "object",
|
|
501
|
+
"properties": {
|
|
502
|
+
"owner": {
|
|
503
|
+
"type": "string",
|
|
504
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
505
|
+
},
|
|
506
|
+
"repo": {
|
|
507
|
+
"type": "string",
|
|
508
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
509
|
+
}
|
|
510
|
+
},
|
|
511
|
+
"required": [
|
|
512
|
+
"owner",
|
|
513
|
+
"repo"
|
|
514
|
+
]
|
|
515
|
+
}
|
|
516
|
+
},
|
|
517
|
+
{
|
|
518
|
+
"name": "activity_set_repo_subscription",
|
|
519
|
+
"description": "Set a repository subscription",
|
|
520
|
+
"method": "PUT",
|
|
521
|
+
"path": "/repos/{owner}/{repo}/subscription",
|
|
522
|
+
"deleteSendsJsonBody": false,
|
|
523
|
+
"inputSchema": {
|
|
524
|
+
"type": "object",
|
|
525
|
+
"properties": {
|
|
526
|
+
"owner": {
|
|
527
|
+
"type": "string",
|
|
528
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
529
|
+
},
|
|
530
|
+
"repo": {
|
|
531
|
+
"type": "string",
|
|
532
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
533
|
+
},
|
|
534
|
+
"subscribed": {
|
|
535
|
+
"type": "boolean",
|
|
536
|
+
"description": "Determines if notifications should be received from this repository."
|
|
537
|
+
},
|
|
538
|
+
"ignored": {
|
|
539
|
+
"type": "boolean",
|
|
540
|
+
"description": "Determines if all notifications should be blocked from this repository."
|
|
541
|
+
}
|
|
542
|
+
},
|
|
543
|
+
"required": [
|
|
544
|
+
"owner",
|
|
545
|
+
"repo"
|
|
546
|
+
]
|
|
547
|
+
}
|
|
548
|
+
},
|
|
549
|
+
{
|
|
550
|
+
"name": "activity_delete_repo_subscription",
|
|
551
|
+
"description": "Delete a repository subscription",
|
|
552
|
+
"method": "DELETE",
|
|
553
|
+
"path": "/repos/{owner}/{repo}/subscription",
|
|
554
|
+
"deleteSendsJsonBody": false,
|
|
555
|
+
"inputSchema": {
|
|
556
|
+
"type": "object",
|
|
557
|
+
"properties": {
|
|
558
|
+
"owner": {
|
|
559
|
+
"type": "string",
|
|
560
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
561
|
+
},
|
|
562
|
+
"repo": {
|
|
563
|
+
"type": "string",
|
|
564
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
565
|
+
}
|
|
566
|
+
},
|
|
567
|
+
"required": [
|
|
568
|
+
"owner",
|
|
569
|
+
"repo"
|
|
570
|
+
]
|
|
571
|
+
}
|
|
572
|
+
},
|
|
573
|
+
{
|
|
574
|
+
"name": "activity_list_repos_starred_by_authenticated_user",
|
|
575
|
+
"description": "List repositories starred by the authenticated user",
|
|
576
|
+
"method": "GET",
|
|
577
|
+
"path": "/user/starred",
|
|
578
|
+
"deleteSendsJsonBody": false,
|
|
579
|
+
"inputSchema": {
|
|
580
|
+
"type": "object",
|
|
581
|
+
"properties": {
|
|
582
|
+
"sort": {
|
|
583
|
+
"type": "string",
|
|
584
|
+
"description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.",
|
|
585
|
+
"enum": [
|
|
586
|
+
"created",
|
|
587
|
+
"updated"
|
|
588
|
+
]
|
|
589
|
+
},
|
|
590
|
+
"direction": {
|
|
591
|
+
"type": "string",
|
|
592
|
+
"description": "The direction to sort the results by.",
|
|
593
|
+
"enum": [
|
|
594
|
+
"asc",
|
|
595
|
+
"desc"
|
|
596
|
+
]
|
|
597
|
+
},
|
|
598
|
+
"per_page": {
|
|
599
|
+
"type": "number",
|
|
600
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
601
|
+
},
|
|
602
|
+
"page": {
|
|
603
|
+
"type": "number",
|
|
604
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
605
|
+
}
|
|
606
|
+
},
|
|
607
|
+
"required": []
|
|
608
|
+
}
|
|
609
|
+
},
|
|
610
|
+
{
|
|
611
|
+
"name": "activity_check_repo_is_starred_by_authenticated_user",
|
|
612
|
+
"description": "Check if a repository is starred by the authenticated user",
|
|
613
|
+
"method": "GET",
|
|
614
|
+
"path": "/user/starred/{owner}/{repo}",
|
|
615
|
+
"deleteSendsJsonBody": false,
|
|
616
|
+
"inputSchema": {
|
|
617
|
+
"type": "object",
|
|
618
|
+
"properties": {
|
|
619
|
+
"owner": {
|
|
620
|
+
"type": "string",
|
|
621
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
622
|
+
},
|
|
623
|
+
"repo": {
|
|
624
|
+
"type": "string",
|
|
625
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
626
|
+
}
|
|
627
|
+
},
|
|
628
|
+
"required": [
|
|
629
|
+
"owner",
|
|
630
|
+
"repo"
|
|
631
|
+
]
|
|
632
|
+
}
|
|
633
|
+
},
|
|
634
|
+
{
|
|
635
|
+
"name": "activity_star_repo_for_authenticated_user",
|
|
636
|
+
"description": "Star a repository for the authenticated user",
|
|
637
|
+
"method": "PUT",
|
|
638
|
+
"path": "/user/starred/{owner}/{repo}",
|
|
639
|
+
"deleteSendsJsonBody": false,
|
|
640
|
+
"inputSchema": {
|
|
641
|
+
"type": "object",
|
|
642
|
+
"properties": {
|
|
643
|
+
"owner": {
|
|
644
|
+
"type": "string",
|
|
645
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
646
|
+
},
|
|
647
|
+
"repo": {
|
|
648
|
+
"type": "string",
|
|
649
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
650
|
+
}
|
|
651
|
+
},
|
|
652
|
+
"required": [
|
|
653
|
+
"owner",
|
|
654
|
+
"repo"
|
|
655
|
+
]
|
|
656
|
+
}
|
|
657
|
+
},
|
|
658
|
+
{
|
|
659
|
+
"name": "activity_unstar_repo_for_authenticated_user",
|
|
660
|
+
"description": "Unstar a repository for the authenticated user",
|
|
661
|
+
"method": "DELETE",
|
|
662
|
+
"path": "/user/starred/{owner}/{repo}",
|
|
663
|
+
"deleteSendsJsonBody": false,
|
|
664
|
+
"inputSchema": {
|
|
665
|
+
"type": "object",
|
|
666
|
+
"properties": {
|
|
667
|
+
"owner": {
|
|
668
|
+
"type": "string",
|
|
669
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
670
|
+
},
|
|
671
|
+
"repo": {
|
|
672
|
+
"type": "string",
|
|
673
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
674
|
+
}
|
|
675
|
+
},
|
|
676
|
+
"required": [
|
|
677
|
+
"owner",
|
|
678
|
+
"repo"
|
|
679
|
+
]
|
|
680
|
+
}
|
|
681
|
+
},
|
|
682
|
+
{
|
|
683
|
+
"name": "activity_list_watched_repos_for_authenticated_user",
|
|
684
|
+
"description": "List repositories watched by the authenticated user",
|
|
685
|
+
"method": "GET",
|
|
686
|
+
"path": "/user/subscriptions",
|
|
687
|
+
"deleteSendsJsonBody": false,
|
|
688
|
+
"inputSchema": {
|
|
689
|
+
"type": "object",
|
|
690
|
+
"properties": {
|
|
691
|
+
"per_page": {
|
|
692
|
+
"type": "number",
|
|
693
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
694
|
+
},
|
|
695
|
+
"page": {
|
|
696
|
+
"type": "number",
|
|
697
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
698
|
+
}
|
|
699
|
+
},
|
|
700
|
+
"required": []
|
|
701
|
+
}
|
|
702
|
+
},
|
|
703
|
+
{
|
|
704
|
+
"name": "activity_list_events_for_authenticated_user",
|
|
705
|
+
"description": "List events for the authenticated user",
|
|
706
|
+
"method": "GET",
|
|
707
|
+
"path": "/users/{username}/events",
|
|
708
|
+
"deleteSendsJsonBody": false,
|
|
709
|
+
"inputSchema": {
|
|
710
|
+
"type": "object",
|
|
711
|
+
"properties": {
|
|
712
|
+
"username": {
|
|
713
|
+
"type": "string",
|
|
714
|
+
"description": "The handle for the GitHub user account."
|
|
715
|
+
},
|
|
716
|
+
"per_page": {
|
|
717
|
+
"type": "number",
|
|
718
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
719
|
+
},
|
|
720
|
+
"page": {
|
|
721
|
+
"type": "number",
|
|
722
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
723
|
+
}
|
|
724
|
+
},
|
|
725
|
+
"required": [
|
|
726
|
+
"username"
|
|
727
|
+
]
|
|
728
|
+
}
|
|
729
|
+
},
|
|
730
|
+
{
|
|
731
|
+
"name": "activity_list_org_events_for_authenticated_user",
|
|
732
|
+
"description": "List organization events for the authenticated user",
|
|
733
|
+
"method": "GET",
|
|
734
|
+
"path": "/users/{username}/events/orgs/{org}",
|
|
735
|
+
"deleteSendsJsonBody": false,
|
|
736
|
+
"inputSchema": {
|
|
737
|
+
"type": "object",
|
|
738
|
+
"properties": {
|
|
739
|
+
"username": {
|
|
740
|
+
"type": "string",
|
|
741
|
+
"description": "The handle for the GitHub user account."
|
|
742
|
+
},
|
|
743
|
+
"org": {
|
|
744
|
+
"type": "string",
|
|
745
|
+
"description": "The organization name. The name is not case sensitive."
|
|
746
|
+
},
|
|
747
|
+
"per_page": {
|
|
748
|
+
"type": "number",
|
|
749
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
750
|
+
},
|
|
751
|
+
"page": {
|
|
752
|
+
"type": "number",
|
|
753
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
754
|
+
}
|
|
755
|
+
},
|
|
756
|
+
"required": [
|
|
757
|
+
"username",
|
|
758
|
+
"org"
|
|
759
|
+
]
|
|
760
|
+
}
|
|
761
|
+
},
|
|
762
|
+
{
|
|
763
|
+
"name": "activity_list_public_events_for_user",
|
|
764
|
+
"description": "List public events for a user",
|
|
765
|
+
"method": "GET",
|
|
766
|
+
"path": "/users/{username}/events/public",
|
|
767
|
+
"deleteSendsJsonBody": false,
|
|
768
|
+
"inputSchema": {
|
|
769
|
+
"type": "object",
|
|
770
|
+
"properties": {
|
|
771
|
+
"username": {
|
|
772
|
+
"type": "string",
|
|
773
|
+
"description": "The handle for the GitHub user account."
|
|
774
|
+
},
|
|
775
|
+
"per_page": {
|
|
776
|
+
"type": "number",
|
|
777
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
778
|
+
},
|
|
779
|
+
"page": {
|
|
780
|
+
"type": "number",
|
|
781
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
782
|
+
}
|
|
783
|
+
},
|
|
784
|
+
"required": [
|
|
785
|
+
"username"
|
|
786
|
+
]
|
|
787
|
+
}
|
|
788
|
+
},
|
|
789
|
+
{
|
|
790
|
+
"name": "activity_list_received_events_for_user",
|
|
791
|
+
"description": "List events received by the authenticated user",
|
|
792
|
+
"method": "GET",
|
|
793
|
+
"path": "/users/{username}/received_events",
|
|
794
|
+
"deleteSendsJsonBody": false,
|
|
795
|
+
"inputSchema": {
|
|
796
|
+
"type": "object",
|
|
797
|
+
"properties": {
|
|
798
|
+
"username": {
|
|
799
|
+
"type": "string",
|
|
800
|
+
"description": "The handle for the GitHub user account."
|
|
801
|
+
},
|
|
802
|
+
"per_page": {
|
|
803
|
+
"type": "number",
|
|
804
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
805
|
+
},
|
|
806
|
+
"page": {
|
|
807
|
+
"type": "number",
|
|
808
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
809
|
+
}
|
|
810
|
+
},
|
|
811
|
+
"required": [
|
|
812
|
+
"username"
|
|
813
|
+
]
|
|
814
|
+
}
|
|
815
|
+
},
|
|
816
|
+
{
|
|
817
|
+
"name": "activity_list_received_public_events_for_user",
|
|
818
|
+
"description": "List public events received by a user",
|
|
819
|
+
"method": "GET",
|
|
820
|
+
"path": "/users/{username}/received_events/public",
|
|
821
|
+
"deleteSendsJsonBody": false,
|
|
822
|
+
"inputSchema": {
|
|
823
|
+
"type": "object",
|
|
824
|
+
"properties": {
|
|
825
|
+
"username": {
|
|
826
|
+
"type": "string",
|
|
827
|
+
"description": "The handle for the GitHub user account."
|
|
828
|
+
},
|
|
829
|
+
"per_page": {
|
|
830
|
+
"type": "number",
|
|
831
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
832
|
+
},
|
|
833
|
+
"page": {
|
|
834
|
+
"type": "number",
|
|
835
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
836
|
+
}
|
|
837
|
+
},
|
|
838
|
+
"required": [
|
|
839
|
+
"username"
|
|
840
|
+
]
|
|
841
|
+
}
|
|
842
|
+
},
|
|
843
|
+
{
|
|
844
|
+
"name": "activity_list_repos_starred_by_user",
|
|
845
|
+
"description": "List repositories starred by a user",
|
|
846
|
+
"method": "GET",
|
|
847
|
+
"path": "/users/{username}/starred",
|
|
848
|
+
"deleteSendsJsonBody": false,
|
|
849
|
+
"inputSchema": {
|
|
850
|
+
"type": "object",
|
|
851
|
+
"properties": {
|
|
852
|
+
"username": {
|
|
853
|
+
"type": "string",
|
|
854
|
+
"description": "The handle for the GitHub user account."
|
|
855
|
+
},
|
|
856
|
+
"sort": {
|
|
857
|
+
"type": "string",
|
|
858
|
+
"description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.",
|
|
859
|
+
"enum": [
|
|
860
|
+
"created",
|
|
861
|
+
"updated"
|
|
862
|
+
]
|
|
863
|
+
},
|
|
864
|
+
"direction": {
|
|
865
|
+
"type": "string",
|
|
866
|
+
"description": "The direction to sort the results by.",
|
|
867
|
+
"enum": [
|
|
868
|
+
"asc",
|
|
869
|
+
"desc"
|
|
870
|
+
]
|
|
871
|
+
},
|
|
872
|
+
"per_page": {
|
|
873
|
+
"type": "number",
|
|
874
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
875
|
+
},
|
|
876
|
+
"page": {
|
|
877
|
+
"type": "number",
|
|
878
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
879
|
+
}
|
|
880
|
+
},
|
|
881
|
+
"required": [
|
|
882
|
+
"username"
|
|
883
|
+
]
|
|
884
|
+
}
|
|
885
|
+
},
|
|
886
|
+
{
|
|
887
|
+
"name": "activity_list_repos_watched_by_user",
|
|
888
|
+
"description": "List repositories watched by a user",
|
|
889
|
+
"method": "GET",
|
|
890
|
+
"path": "/users/{username}/subscriptions",
|
|
891
|
+
"deleteSendsJsonBody": false,
|
|
892
|
+
"inputSchema": {
|
|
893
|
+
"type": "object",
|
|
894
|
+
"properties": {
|
|
895
|
+
"username": {
|
|
896
|
+
"type": "string",
|
|
897
|
+
"description": "The handle for the GitHub user account."
|
|
898
|
+
},
|
|
899
|
+
"per_page": {
|
|
900
|
+
"type": "number",
|
|
901
|
+
"description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
902
|
+
},
|
|
903
|
+
"page": {
|
|
904
|
+
"type": "number",
|
|
905
|
+
"description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api).\""
|
|
906
|
+
}
|
|
907
|
+
},
|
|
908
|
+
"required": [
|
|
909
|
+
"username"
|
|
910
|
+
]
|
|
911
|
+
}
|
|
912
|
+
}
|
|
913
|
+
];
|
|
914
|
+
|
|
915
|
+
export const tools = ENDPOINTS.map((e) => ({
|
|
916
|
+
name: e.name,
|
|
917
|
+
description: e.description,
|
|
918
|
+
method: e.method,
|
|
919
|
+
path: e.path,
|
|
920
|
+
deleteSendsJsonBody: Boolean(e.deleteSendsJsonBody),
|
|
921
|
+
inputSchema: e.inputSchema,
|
|
922
|
+
handler: async (params) => ({
|
|
923
|
+
content: [{ type: 'text', text: JSON.stringify(await apiRequest(e.method, e.path, params, { deleteSendsJsonBody: e.deleteSendsJsonBody }), null, 2) }],
|
|
924
|
+
}),
|
|
925
|
+
}));
|