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,791 @@
|
|
|
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-apps';
|
|
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": "apps_get_authenticated",
|
|
55
|
+
"description": "Get the authenticated app",
|
|
56
|
+
"method": "GET",
|
|
57
|
+
"path": "/app",
|
|
58
|
+
"deleteSendsJsonBody": false,
|
|
59
|
+
"inputSchema": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"properties": {},
|
|
62
|
+
"required": []
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"name": "apps_create_from_manifest",
|
|
67
|
+
"description": "Create a GitHub App from a manifest",
|
|
68
|
+
"method": "POST",
|
|
69
|
+
"path": "/app-manifests/{code}/conversions",
|
|
70
|
+
"deleteSendsJsonBody": false,
|
|
71
|
+
"inputSchema": {
|
|
72
|
+
"type": "object",
|
|
73
|
+
"properties": {
|
|
74
|
+
"code": {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"description": "The code parameter"
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
"required": [
|
|
80
|
+
"code"
|
|
81
|
+
]
|
|
82
|
+
}
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"name": "apps_get_webhook_config_for_app",
|
|
86
|
+
"description": "Get a webhook configuration for an app",
|
|
87
|
+
"method": "GET",
|
|
88
|
+
"path": "/app/hook/config",
|
|
89
|
+
"deleteSendsJsonBody": false,
|
|
90
|
+
"inputSchema": {
|
|
91
|
+
"type": "object",
|
|
92
|
+
"properties": {},
|
|
93
|
+
"required": []
|
|
94
|
+
}
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
"name": "apps_update_webhook_config_for_app",
|
|
98
|
+
"description": "Update a webhook configuration for an app",
|
|
99
|
+
"method": "PATCH",
|
|
100
|
+
"path": "/app/hook/config",
|
|
101
|
+
"deleteSendsJsonBody": false,
|
|
102
|
+
"inputSchema": {
|
|
103
|
+
"type": "object",
|
|
104
|
+
"properties": {
|
|
105
|
+
"url": {
|
|
106
|
+
"type": "string",
|
|
107
|
+
"description": "The URL to which the payloads will be delivered."
|
|
108
|
+
},
|
|
109
|
+
"content_type": {
|
|
110
|
+
"type": "string",
|
|
111
|
+
"description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`."
|
|
112
|
+
},
|
|
113
|
+
"secret": {
|
|
114
|
+
"type": "string",
|
|
115
|
+
"description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/webhooks/event-payloads/#delivery-headers)."
|
|
116
|
+
},
|
|
117
|
+
"insecure_ssl": {
|
|
118
|
+
"type": "string",
|
|
119
|
+
"description": "The insecure_ssl field"
|
|
120
|
+
}
|
|
121
|
+
},
|
|
122
|
+
"required": []
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
"name": "apps_list_webhook_deliveries",
|
|
127
|
+
"description": "List deliveries for an app webhook",
|
|
128
|
+
"method": "GET",
|
|
129
|
+
"path": "/app/hook/deliveries",
|
|
130
|
+
"deleteSendsJsonBody": false,
|
|
131
|
+
"inputSchema": {
|
|
132
|
+
"type": "object",
|
|
133
|
+
"properties": {
|
|
134
|
+
"per_page": {
|
|
135
|
+
"type": "number",
|
|
136
|
+
"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).\""
|
|
137
|
+
},
|
|
138
|
+
"cursor": {
|
|
139
|
+
"type": "string",
|
|
140
|
+
"description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors."
|
|
141
|
+
},
|
|
142
|
+
"status": {
|
|
143
|
+
"type": "string",
|
|
144
|
+
"description": "Returns webhook deliveries filtered by delivery outcome classification based on `status_code` range. A `status` of `success` returns deliveries with a `status_code` in the 200-399 range (inclusive). A `status` of `failure` returns deliveries with a `status_code` in the 400-599 range (inclusive).",
|
|
145
|
+
"enum": [
|
|
146
|
+
"success",
|
|
147
|
+
"failure"
|
|
148
|
+
]
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
"required": []
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
"name": "apps_get_webhook_delivery",
|
|
156
|
+
"description": "Get a delivery for an app webhook",
|
|
157
|
+
"method": "GET",
|
|
158
|
+
"path": "/app/hook/deliveries/{delivery_id}",
|
|
159
|
+
"deleteSendsJsonBody": false,
|
|
160
|
+
"inputSchema": {
|
|
161
|
+
"type": "object",
|
|
162
|
+
"properties": {
|
|
163
|
+
"delivery_id": {
|
|
164
|
+
"type": "number",
|
|
165
|
+
"description": "The delivery_id parameter"
|
|
166
|
+
}
|
|
167
|
+
},
|
|
168
|
+
"required": [
|
|
169
|
+
"delivery_id"
|
|
170
|
+
]
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"name": "apps_redeliver_webhook_delivery",
|
|
175
|
+
"description": "Redeliver a delivery for an app webhook",
|
|
176
|
+
"method": "POST",
|
|
177
|
+
"path": "/app/hook/deliveries/{delivery_id}/attempts",
|
|
178
|
+
"deleteSendsJsonBody": false,
|
|
179
|
+
"inputSchema": {
|
|
180
|
+
"type": "object",
|
|
181
|
+
"properties": {
|
|
182
|
+
"delivery_id": {
|
|
183
|
+
"type": "number",
|
|
184
|
+
"description": "The delivery_id parameter"
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
"required": [
|
|
188
|
+
"delivery_id"
|
|
189
|
+
]
|
|
190
|
+
}
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
"name": "apps_list_installation_requests_for_authenticated_app",
|
|
194
|
+
"description": "List installation requests for the authenticated app",
|
|
195
|
+
"method": "GET",
|
|
196
|
+
"path": "/app/installation-requests",
|
|
197
|
+
"deleteSendsJsonBody": false,
|
|
198
|
+
"inputSchema": {
|
|
199
|
+
"type": "object",
|
|
200
|
+
"properties": {
|
|
201
|
+
"per_page": {
|
|
202
|
+
"type": "number",
|
|
203
|
+
"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).\""
|
|
204
|
+
},
|
|
205
|
+
"page": {
|
|
206
|
+
"type": "number",
|
|
207
|
+
"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).\""
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
"required": []
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"name": "apps_list_installations",
|
|
215
|
+
"description": "List installations for the authenticated app",
|
|
216
|
+
"method": "GET",
|
|
217
|
+
"path": "/app/installations",
|
|
218
|
+
"deleteSendsJsonBody": false,
|
|
219
|
+
"inputSchema": {
|
|
220
|
+
"type": "object",
|
|
221
|
+
"properties": {
|
|
222
|
+
"per_page": {
|
|
223
|
+
"type": "number",
|
|
224
|
+
"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).\""
|
|
225
|
+
},
|
|
226
|
+
"page": {
|
|
227
|
+
"type": "number",
|
|
228
|
+
"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).\""
|
|
229
|
+
},
|
|
230
|
+
"since": {
|
|
231
|
+
"type": "string",
|
|
232
|
+
"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`."
|
|
233
|
+
},
|
|
234
|
+
"outdated": {
|
|
235
|
+
"type": "string",
|
|
236
|
+
"description": "The outdated parameter"
|
|
237
|
+
}
|
|
238
|
+
},
|
|
239
|
+
"required": []
|
|
240
|
+
}
|
|
241
|
+
},
|
|
242
|
+
{
|
|
243
|
+
"name": "apps_get_installation",
|
|
244
|
+
"description": "Get an installation for the authenticated app",
|
|
245
|
+
"method": "GET",
|
|
246
|
+
"path": "/app/installations/{installation_id}",
|
|
247
|
+
"deleteSendsJsonBody": false,
|
|
248
|
+
"inputSchema": {
|
|
249
|
+
"type": "object",
|
|
250
|
+
"properties": {
|
|
251
|
+
"installation_id": {
|
|
252
|
+
"type": "number",
|
|
253
|
+
"description": "The unique identifier of the installation."
|
|
254
|
+
}
|
|
255
|
+
},
|
|
256
|
+
"required": [
|
|
257
|
+
"installation_id"
|
|
258
|
+
]
|
|
259
|
+
}
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
"name": "apps_delete_installation",
|
|
263
|
+
"description": "Delete an installation for the authenticated app",
|
|
264
|
+
"method": "DELETE",
|
|
265
|
+
"path": "/app/installations/{installation_id}",
|
|
266
|
+
"deleteSendsJsonBody": false,
|
|
267
|
+
"inputSchema": {
|
|
268
|
+
"type": "object",
|
|
269
|
+
"properties": {
|
|
270
|
+
"installation_id": {
|
|
271
|
+
"type": "number",
|
|
272
|
+
"description": "The unique identifier of the installation."
|
|
273
|
+
}
|
|
274
|
+
},
|
|
275
|
+
"required": [
|
|
276
|
+
"installation_id"
|
|
277
|
+
]
|
|
278
|
+
}
|
|
279
|
+
},
|
|
280
|
+
{
|
|
281
|
+
"name": "apps_create_installation_access_token",
|
|
282
|
+
"description": "Create an installation access token for an app",
|
|
283
|
+
"method": "POST",
|
|
284
|
+
"path": "/app/installations/{installation_id}/access_tokens",
|
|
285
|
+
"deleteSendsJsonBody": false,
|
|
286
|
+
"inputSchema": {
|
|
287
|
+
"type": "object",
|
|
288
|
+
"properties": {
|
|
289
|
+
"installation_id": {
|
|
290
|
+
"type": "number",
|
|
291
|
+
"description": "The unique identifier of the installation."
|
|
292
|
+
},
|
|
293
|
+
"repositories": {
|
|
294
|
+
"type": "array",
|
|
295
|
+
"description": "List of repository names that the token should have access to"
|
|
296
|
+
},
|
|
297
|
+
"repository_ids": {
|
|
298
|
+
"type": "array",
|
|
299
|
+
"description": "List of repository IDs that the token should have access to"
|
|
300
|
+
},
|
|
301
|
+
"permissions": {
|
|
302
|
+
"type": "object",
|
|
303
|
+
"description": "The permissions granted to the user access token."
|
|
304
|
+
}
|
|
305
|
+
},
|
|
306
|
+
"required": [
|
|
307
|
+
"installation_id"
|
|
308
|
+
]
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
"name": "apps_suspend_installation",
|
|
313
|
+
"description": "Suspend an app installation",
|
|
314
|
+
"method": "PUT",
|
|
315
|
+
"path": "/app/installations/{installation_id}/suspended",
|
|
316
|
+
"deleteSendsJsonBody": false,
|
|
317
|
+
"inputSchema": {
|
|
318
|
+
"type": "object",
|
|
319
|
+
"properties": {
|
|
320
|
+
"installation_id": {
|
|
321
|
+
"type": "number",
|
|
322
|
+
"description": "The unique identifier of the installation."
|
|
323
|
+
}
|
|
324
|
+
},
|
|
325
|
+
"required": [
|
|
326
|
+
"installation_id"
|
|
327
|
+
]
|
|
328
|
+
}
|
|
329
|
+
},
|
|
330
|
+
{
|
|
331
|
+
"name": "apps_unsuspend_installation",
|
|
332
|
+
"description": "Unsuspend an app installation",
|
|
333
|
+
"method": "DELETE",
|
|
334
|
+
"path": "/app/installations/{installation_id}/suspended",
|
|
335
|
+
"deleteSendsJsonBody": false,
|
|
336
|
+
"inputSchema": {
|
|
337
|
+
"type": "object",
|
|
338
|
+
"properties": {
|
|
339
|
+
"installation_id": {
|
|
340
|
+
"type": "number",
|
|
341
|
+
"description": "The unique identifier of the installation."
|
|
342
|
+
}
|
|
343
|
+
},
|
|
344
|
+
"required": [
|
|
345
|
+
"installation_id"
|
|
346
|
+
]
|
|
347
|
+
}
|
|
348
|
+
},
|
|
349
|
+
{
|
|
350
|
+
"name": "apps_delete_authorization",
|
|
351
|
+
"description": "Delete an app authorization",
|
|
352
|
+
"method": "DELETE",
|
|
353
|
+
"path": "/applications/{client_id}/grant",
|
|
354
|
+
"deleteSendsJsonBody": true,
|
|
355
|
+
"inputSchema": {
|
|
356
|
+
"type": "object",
|
|
357
|
+
"properties": {
|
|
358
|
+
"client_id": {
|
|
359
|
+
"type": "string",
|
|
360
|
+
"description": "The client ID of the GitHub app."
|
|
361
|
+
},
|
|
362
|
+
"access_token": {
|
|
363
|
+
"type": "string",
|
|
364
|
+
"description": "The OAuth access token used to authenticate to the GitHub API."
|
|
365
|
+
}
|
|
366
|
+
},
|
|
367
|
+
"required": [
|
|
368
|
+
"client_id",
|
|
369
|
+
"access_token"
|
|
370
|
+
]
|
|
371
|
+
}
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
"name": "apps_get_by_slug",
|
|
375
|
+
"description": "Get an app",
|
|
376
|
+
"method": "GET",
|
|
377
|
+
"path": "/apps/{app_slug}",
|
|
378
|
+
"deleteSendsJsonBody": false,
|
|
379
|
+
"inputSchema": {
|
|
380
|
+
"type": "object",
|
|
381
|
+
"properties": {
|
|
382
|
+
"app_slug": {
|
|
383
|
+
"type": "string",
|
|
384
|
+
"description": "The app_slug parameter"
|
|
385
|
+
}
|
|
386
|
+
},
|
|
387
|
+
"required": [
|
|
388
|
+
"app_slug"
|
|
389
|
+
]
|
|
390
|
+
}
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
"name": "apps_list_repos_accessible_to_installation",
|
|
394
|
+
"description": "List repositories accessible to the app installation",
|
|
395
|
+
"method": "GET",
|
|
396
|
+
"path": "/installation/repositories",
|
|
397
|
+
"deleteSendsJsonBody": false,
|
|
398
|
+
"inputSchema": {
|
|
399
|
+
"type": "object",
|
|
400
|
+
"properties": {
|
|
401
|
+
"per_page": {
|
|
402
|
+
"type": "number",
|
|
403
|
+
"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).\""
|
|
404
|
+
},
|
|
405
|
+
"page": {
|
|
406
|
+
"type": "number",
|
|
407
|
+
"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).\""
|
|
408
|
+
}
|
|
409
|
+
},
|
|
410
|
+
"required": []
|
|
411
|
+
}
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
"name": "apps_get_subscription_plan_for_account",
|
|
415
|
+
"description": "Get a subscription plan for an account",
|
|
416
|
+
"method": "GET",
|
|
417
|
+
"path": "/marketplace_listing/accounts/{account_id}",
|
|
418
|
+
"deleteSendsJsonBody": false,
|
|
419
|
+
"inputSchema": {
|
|
420
|
+
"type": "object",
|
|
421
|
+
"properties": {
|
|
422
|
+
"account_id": {
|
|
423
|
+
"type": "number",
|
|
424
|
+
"description": "account_id parameter"
|
|
425
|
+
}
|
|
426
|
+
},
|
|
427
|
+
"required": [
|
|
428
|
+
"account_id"
|
|
429
|
+
]
|
|
430
|
+
}
|
|
431
|
+
},
|
|
432
|
+
{
|
|
433
|
+
"name": "apps_list_plans",
|
|
434
|
+
"description": "List plans",
|
|
435
|
+
"method": "GET",
|
|
436
|
+
"path": "/marketplace_listing/plans",
|
|
437
|
+
"deleteSendsJsonBody": false,
|
|
438
|
+
"inputSchema": {
|
|
439
|
+
"type": "object",
|
|
440
|
+
"properties": {
|
|
441
|
+
"per_page": {
|
|
442
|
+
"type": "number",
|
|
443
|
+
"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).\""
|
|
444
|
+
},
|
|
445
|
+
"page": {
|
|
446
|
+
"type": "number",
|
|
447
|
+
"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).\""
|
|
448
|
+
}
|
|
449
|
+
},
|
|
450
|
+
"required": []
|
|
451
|
+
}
|
|
452
|
+
},
|
|
453
|
+
{
|
|
454
|
+
"name": "apps_list_accounts_for_plan",
|
|
455
|
+
"description": "List accounts for a plan",
|
|
456
|
+
"method": "GET",
|
|
457
|
+
"path": "/marketplace_listing/plans/{plan_id}/accounts",
|
|
458
|
+
"deleteSendsJsonBody": false,
|
|
459
|
+
"inputSchema": {
|
|
460
|
+
"type": "object",
|
|
461
|
+
"properties": {
|
|
462
|
+
"plan_id": {
|
|
463
|
+
"type": "number",
|
|
464
|
+
"description": "The unique identifier of the plan."
|
|
465
|
+
},
|
|
466
|
+
"sort": {
|
|
467
|
+
"type": "string",
|
|
468
|
+
"description": "The property to sort the results by.",
|
|
469
|
+
"enum": [
|
|
470
|
+
"created",
|
|
471
|
+
"updated"
|
|
472
|
+
]
|
|
473
|
+
},
|
|
474
|
+
"direction": {
|
|
475
|
+
"type": "string",
|
|
476
|
+
"description": "To return the oldest accounts first, set to `asc`. Ignored without the `sort` parameter.",
|
|
477
|
+
"enum": [
|
|
478
|
+
"asc",
|
|
479
|
+
"desc"
|
|
480
|
+
]
|
|
481
|
+
},
|
|
482
|
+
"per_page": {
|
|
483
|
+
"type": "number",
|
|
484
|
+
"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).\""
|
|
485
|
+
},
|
|
486
|
+
"page": {
|
|
487
|
+
"type": "number",
|
|
488
|
+
"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).\""
|
|
489
|
+
}
|
|
490
|
+
},
|
|
491
|
+
"required": [
|
|
492
|
+
"plan_id"
|
|
493
|
+
]
|
|
494
|
+
}
|
|
495
|
+
},
|
|
496
|
+
{
|
|
497
|
+
"name": "apps_get_subscription_plan_for_account_stubbed",
|
|
498
|
+
"description": "Get a subscription plan for an account (stubbed)",
|
|
499
|
+
"method": "GET",
|
|
500
|
+
"path": "/marketplace_listing/stubbed/accounts/{account_id}",
|
|
501
|
+
"deleteSendsJsonBody": false,
|
|
502
|
+
"inputSchema": {
|
|
503
|
+
"type": "object",
|
|
504
|
+
"properties": {
|
|
505
|
+
"account_id": {
|
|
506
|
+
"type": "number",
|
|
507
|
+
"description": "account_id parameter"
|
|
508
|
+
}
|
|
509
|
+
},
|
|
510
|
+
"required": [
|
|
511
|
+
"account_id"
|
|
512
|
+
]
|
|
513
|
+
}
|
|
514
|
+
},
|
|
515
|
+
{
|
|
516
|
+
"name": "apps_list_plans_stubbed",
|
|
517
|
+
"description": "List plans (stubbed)",
|
|
518
|
+
"method": "GET",
|
|
519
|
+
"path": "/marketplace_listing/stubbed/plans",
|
|
520
|
+
"deleteSendsJsonBody": false,
|
|
521
|
+
"inputSchema": {
|
|
522
|
+
"type": "object",
|
|
523
|
+
"properties": {
|
|
524
|
+
"per_page": {
|
|
525
|
+
"type": "number",
|
|
526
|
+
"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).\""
|
|
527
|
+
},
|
|
528
|
+
"page": {
|
|
529
|
+
"type": "number",
|
|
530
|
+
"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).\""
|
|
531
|
+
}
|
|
532
|
+
},
|
|
533
|
+
"required": []
|
|
534
|
+
}
|
|
535
|
+
},
|
|
536
|
+
{
|
|
537
|
+
"name": "apps_list_accounts_for_plan_stubbed",
|
|
538
|
+
"description": "List accounts for a plan (stubbed)",
|
|
539
|
+
"method": "GET",
|
|
540
|
+
"path": "/marketplace_listing/stubbed/plans/{plan_id}/accounts",
|
|
541
|
+
"deleteSendsJsonBody": false,
|
|
542
|
+
"inputSchema": {
|
|
543
|
+
"type": "object",
|
|
544
|
+
"properties": {
|
|
545
|
+
"plan_id": {
|
|
546
|
+
"type": "number",
|
|
547
|
+
"description": "The unique identifier of the plan."
|
|
548
|
+
},
|
|
549
|
+
"sort": {
|
|
550
|
+
"type": "string",
|
|
551
|
+
"description": "The property to sort the results by.",
|
|
552
|
+
"enum": [
|
|
553
|
+
"created",
|
|
554
|
+
"updated"
|
|
555
|
+
]
|
|
556
|
+
},
|
|
557
|
+
"direction": {
|
|
558
|
+
"type": "string",
|
|
559
|
+
"description": "To return the oldest accounts first, set to `asc`. Ignored without the `sort` parameter.",
|
|
560
|
+
"enum": [
|
|
561
|
+
"asc",
|
|
562
|
+
"desc"
|
|
563
|
+
]
|
|
564
|
+
},
|
|
565
|
+
"per_page": {
|
|
566
|
+
"type": "number",
|
|
567
|
+
"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).\""
|
|
568
|
+
},
|
|
569
|
+
"page": {
|
|
570
|
+
"type": "number",
|
|
571
|
+
"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).\""
|
|
572
|
+
}
|
|
573
|
+
},
|
|
574
|
+
"required": [
|
|
575
|
+
"plan_id"
|
|
576
|
+
]
|
|
577
|
+
}
|
|
578
|
+
},
|
|
579
|
+
{
|
|
580
|
+
"name": "apps_get_org_installation",
|
|
581
|
+
"description": "Get an organization installation for the authenticated app",
|
|
582
|
+
"method": "GET",
|
|
583
|
+
"path": "/orgs/{org}/installation",
|
|
584
|
+
"deleteSendsJsonBody": false,
|
|
585
|
+
"inputSchema": {
|
|
586
|
+
"type": "object",
|
|
587
|
+
"properties": {
|
|
588
|
+
"org": {
|
|
589
|
+
"type": "string",
|
|
590
|
+
"description": "The organization name. The name is not case sensitive."
|
|
591
|
+
}
|
|
592
|
+
},
|
|
593
|
+
"required": [
|
|
594
|
+
"org"
|
|
595
|
+
]
|
|
596
|
+
}
|
|
597
|
+
},
|
|
598
|
+
{
|
|
599
|
+
"name": "apps_get_repo_installation",
|
|
600
|
+
"description": "Get a repository installation for the authenticated app",
|
|
601
|
+
"method": "GET",
|
|
602
|
+
"path": "/repos/{owner}/{repo}/installation",
|
|
603
|
+
"deleteSendsJsonBody": false,
|
|
604
|
+
"inputSchema": {
|
|
605
|
+
"type": "object",
|
|
606
|
+
"properties": {
|
|
607
|
+
"owner": {
|
|
608
|
+
"type": "string",
|
|
609
|
+
"description": "The account owner of the repository. The name is not case sensitive."
|
|
610
|
+
},
|
|
611
|
+
"repo": {
|
|
612
|
+
"type": "string",
|
|
613
|
+
"description": "The name of the repository without the `.git` extension. The name is not case sensitive."
|
|
614
|
+
}
|
|
615
|
+
},
|
|
616
|
+
"required": [
|
|
617
|
+
"owner",
|
|
618
|
+
"repo"
|
|
619
|
+
]
|
|
620
|
+
}
|
|
621
|
+
},
|
|
622
|
+
{
|
|
623
|
+
"name": "apps_list_installations_for_authenticated_user",
|
|
624
|
+
"description": "List app installations accessible to the user access token",
|
|
625
|
+
"method": "GET",
|
|
626
|
+
"path": "/user/installations",
|
|
627
|
+
"deleteSendsJsonBody": false,
|
|
628
|
+
"inputSchema": {
|
|
629
|
+
"type": "object",
|
|
630
|
+
"properties": {
|
|
631
|
+
"per_page": {
|
|
632
|
+
"type": "number",
|
|
633
|
+
"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).\""
|
|
634
|
+
},
|
|
635
|
+
"page": {
|
|
636
|
+
"type": "number",
|
|
637
|
+
"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).\""
|
|
638
|
+
}
|
|
639
|
+
},
|
|
640
|
+
"required": []
|
|
641
|
+
}
|
|
642
|
+
},
|
|
643
|
+
{
|
|
644
|
+
"name": "apps_list_installation_repos_for_authenticated_user",
|
|
645
|
+
"description": "List repositories accessible to the user access token",
|
|
646
|
+
"method": "GET",
|
|
647
|
+
"path": "/user/installations/{installation_id}/repositories",
|
|
648
|
+
"deleteSendsJsonBody": false,
|
|
649
|
+
"inputSchema": {
|
|
650
|
+
"type": "object",
|
|
651
|
+
"properties": {
|
|
652
|
+
"installation_id": {
|
|
653
|
+
"type": "number",
|
|
654
|
+
"description": "The unique identifier of the installation."
|
|
655
|
+
},
|
|
656
|
+
"per_page": {
|
|
657
|
+
"type": "number",
|
|
658
|
+
"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).\""
|
|
659
|
+
},
|
|
660
|
+
"page": {
|
|
661
|
+
"type": "number",
|
|
662
|
+
"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).\""
|
|
663
|
+
}
|
|
664
|
+
},
|
|
665
|
+
"required": [
|
|
666
|
+
"installation_id"
|
|
667
|
+
]
|
|
668
|
+
}
|
|
669
|
+
},
|
|
670
|
+
{
|
|
671
|
+
"name": "apps_add_repo_to_installation_for_authenticated_user",
|
|
672
|
+
"description": "Add a repository to an app installation",
|
|
673
|
+
"method": "PUT",
|
|
674
|
+
"path": "/user/installations/{installation_id}/repositories/{repository_id}",
|
|
675
|
+
"deleteSendsJsonBody": false,
|
|
676
|
+
"inputSchema": {
|
|
677
|
+
"type": "object",
|
|
678
|
+
"properties": {
|
|
679
|
+
"installation_id": {
|
|
680
|
+
"type": "number",
|
|
681
|
+
"description": "The unique identifier of the installation."
|
|
682
|
+
},
|
|
683
|
+
"repository_id": {
|
|
684
|
+
"type": "number",
|
|
685
|
+
"description": "The unique identifier of the repository."
|
|
686
|
+
}
|
|
687
|
+
},
|
|
688
|
+
"required": [
|
|
689
|
+
"installation_id",
|
|
690
|
+
"repository_id"
|
|
691
|
+
]
|
|
692
|
+
}
|
|
693
|
+
},
|
|
694
|
+
{
|
|
695
|
+
"name": "apps_remove_repo_from_installation_for_authenticated_user",
|
|
696
|
+
"description": "Remove a repository from an app installation",
|
|
697
|
+
"method": "DELETE",
|
|
698
|
+
"path": "/user/installations/{installation_id}/repositories/{repository_id}",
|
|
699
|
+
"deleteSendsJsonBody": false,
|
|
700
|
+
"inputSchema": {
|
|
701
|
+
"type": "object",
|
|
702
|
+
"properties": {
|
|
703
|
+
"installation_id": {
|
|
704
|
+
"type": "number",
|
|
705
|
+
"description": "The unique identifier of the installation."
|
|
706
|
+
},
|
|
707
|
+
"repository_id": {
|
|
708
|
+
"type": "number",
|
|
709
|
+
"description": "The unique identifier of the repository."
|
|
710
|
+
}
|
|
711
|
+
},
|
|
712
|
+
"required": [
|
|
713
|
+
"installation_id",
|
|
714
|
+
"repository_id"
|
|
715
|
+
]
|
|
716
|
+
}
|
|
717
|
+
},
|
|
718
|
+
{
|
|
719
|
+
"name": "apps_list_subscriptions_for_authenticated_user",
|
|
720
|
+
"description": "List subscriptions for the authenticated user",
|
|
721
|
+
"method": "GET",
|
|
722
|
+
"path": "/user/marketplace_purchases",
|
|
723
|
+
"deleteSendsJsonBody": false,
|
|
724
|
+
"inputSchema": {
|
|
725
|
+
"type": "object",
|
|
726
|
+
"properties": {
|
|
727
|
+
"per_page": {
|
|
728
|
+
"type": "number",
|
|
729
|
+
"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).\""
|
|
730
|
+
},
|
|
731
|
+
"page": {
|
|
732
|
+
"type": "number",
|
|
733
|
+
"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).\""
|
|
734
|
+
}
|
|
735
|
+
},
|
|
736
|
+
"required": []
|
|
737
|
+
}
|
|
738
|
+
},
|
|
739
|
+
{
|
|
740
|
+
"name": "apps_list_subscriptions_for_authenticated_user_stubbed",
|
|
741
|
+
"description": "List subscriptions for the authenticated user (stubbed)",
|
|
742
|
+
"method": "GET",
|
|
743
|
+
"path": "/user/marketplace_purchases/stubbed",
|
|
744
|
+
"deleteSendsJsonBody": false,
|
|
745
|
+
"inputSchema": {
|
|
746
|
+
"type": "object",
|
|
747
|
+
"properties": {
|
|
748
|
+
"per_page": {
|
|
749
|
+
"type": "number",
|
|
750
|
+
"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).\""
|
|
751
|
+
},
|
|
752
|
+
"page": {
|
|
753
|
+
"type": "number",
|
|
754
|
+
"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).\""
|
|
755
|
+
}
|
|
756
|
+
},
|
|
757
|
+
"required": []
|
|
758
|
+
}
|
|
759
|
+
},
|
|
760
|
+
{
|
|
761
|
+
"name": "apps_get_user_installation",
|
|
762
|
+
"description": "Get a user installation for the authenticated app",
|
|
763
|
+
"method": "GET",
|
|
764
|
+
"path": "/users/{username}/installation",
|
|
765
|
+
"deleteSendsJsonBody": false,
|
|
766
|
+
"inputSchema": {
|
|
767
|
+
"type": "object",
|
|
768
|
+
"properties": {
|
|
769
|
+
"username": {
|
|
770
|
+
"type": "string",
|
|
771
|
+
"description": "The handle for the GitHub user account."
|
|
772
|
+
}
|
|
773
|
+
},
|
|
774
|
+
"required": [
|
|
775
|
+
"username"
|
|
776
|
+
]
|
|
777
|
+
}
|
|
778
|
+
}
|
|
779
|
+
];
|
|
780
|
+
|
|
781
|
+
export const tools = ENDPOINTS.map((e) => ({
|
|
782
|
+
name: e.name,
|
|
783
|
+
description: e.description,
|
|
784
|
+
method: e.method,
|
|
785
|
+
path: e.path,
|
|
786
|
+
deleteSendsJsonBody: Boolean(e.deleteSendsJsonBody),
|
|
787
|
+
inputSchema: e.inputSchema,
|
|
788
|
+
handler: async (params) => ({
|
|
789
|
+
content: [{ type: 'text', text: JSON.stringify(await apiRequest(e.method, e.path, params, { deleteSendsJsonBody: e.deleteSendsJsonBody }), null, 2) }],
|
|
790
|
+
}),
|
|
791
|
+
}));
|