@apitap/core 1.8.2 → 1.9.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/dist/cli.js +325 -0
- package/dist/cli.js.map +1 -1
- package/dist/skill/github.d.ts +105 -0
- package/dist/skill/github.js +410 -0
- package/dist/skill/github.js.map +1 -0
- package/package.json +1 -1
- package/src/cli.ts +368 -0
- package/src/skill/github.ts +542 -0
|
@@ -0,0 +1,410 @@
|
|
|
1
|
+
// src/skill/github.ts
|
|
2
|
+
import { execFileSync as _execFileSync } from 'node:child_process';
|
|
3
|
+
import { resolveAndValidateUrl as _resolveAndValidateUrl } from './ssrf.js';
|
|
4
|
+
// ─── Token resolution ─────────────────────────────────────────────────────────
|
|
5
|
+
// Indirection so tests can inject a fake without patching non-configurable
|
|
6
|
+
// built-in module exports.
|
|
7
|
+
let _execFileSyncImpl = _execFileSync;
|
|
8
|
+
/**
|
|
9
|
+
* Override the execFileSync implementation — for testing only.
|
|
10
|
+
* Returns the previous implementation so callers can restore it.
|
|
11
|
+
*/
|
|
12
|
+
export function _setExecFileSync(impl) {
|
|
13
|
+
const prev = _execFileSyncImpl;
|
|
14
|
+
_execFileSyncImpl = impl;
|
|
15
|
+
return prev;
|
|
16
|
+
}
|
|
17
|
+
let cachedToken; // undefined = not yet resolved
|
|
18
|
+
/** Reset token cache — for testing only. */
|
|
19
|
+
export function resetTokenCache() {
|
|
20
|
+
cachedToken = undefined;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Resolve a GitHub token. Tries gh CLI first, then GITHUB_TOKEN env var.
|
|
24
|
+
* Caches the result (even null) for the session.
|
|
25
|
+
*/
|
|
26
|
+
export async function resolveGitHubToken() {
|
|
27
|
+
if (cachedToken !== undefined)
|
|
28
|
+
return cachedToken;
|
|
29
|
+
try {
|
|
30
|
+
cachedToken = _execFileSyncImpl('gh', ['auth', 'token'], { timeout: 2000 })
|
|
31
|
+
.toString()
|
|
32
|
+
.trim();
|
|
33
|
+
if (!cachedToken) {
|
|
34
|
+
// gh returned empty output — treat as failure
|
|
35
|
+
throw new Error('empty token');
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
catch {
|
|
39
|
+
cachedToken = process.env.GITHUB_TOKEN ?? null;
|
|
40
|
+
}
|
|
41
|
+
if (cachedToken === null) {
|
|
42
|
+
console.error("Warning: No GitHub token found — rate limited to 60 req/hr. " +
|
|
43
|
+
"Run 'gh auth login' or set GITHUB_TOKEN.");
|
|
44
|
+
}
|
|
45
|
+
return cachedToken;
|
|
46
|
+
}
|
|
47
|
+
const MAX_RESPONSE_SIZE = 10 * 1024 * 1024; // 10 MB
|
|
48
|
+
/**
|
|
49
|
+
* Fetch a GitHub API path and return parsed JSON plus rate-limit metadata.
|
|
50
|
+
* Throws with a descriptive message on HTTP errors and size overruns.
|
|
51
|
+
*/
|
|
52
|
+
export async function githubFetch(path, token) {
|
|
53
|
+
const url = `https://api.github.com${path}`;
|
|
54
|
+
const headers = {
|
|
55
|
+
Accept: 'application/vnd.github+json',
|
|
56
|
+
'User-Agent': 'apitap-import',
|
|
57
|
+
};
|
|
58
|
+
if (token) {
|
|
59
|
+
headers['Authorization'] = `Bearer ${token}`;
|
|
60
|
+
}
|
|
61
|
+
const response = await fetch(url, {
|
|
62
|
+
headers,
|
|
63
|
+
signal: AbortSignal.timeout(30_000),
|
|
64
|
+
});
|
|
65
|
+
// Parse rate limit before checking status (available even on error responses).
|
|
66
|
+
const rateLimit = {
|
|
67
|
+
remaining: parseInt(response.headers.get('x-ratelimit-remaining') ?? '0', 10),
|
|
68
|
+
limit: parseInt(response.headers.get('x-ratelimit-limit') ?? '0', 10),
|
|
69
|
+
resetAt: new Date(parseInt(response.headers.get('x-ratelimit-reset') ?? '0', 10) * 1000),
|
|
70
|
+
};
|
|
71
|
+
if (!response.ok) {
|
|
72
|
+
if (response.status === 403 && rateLimit.remaining === 0) {
|
|
73
|
+
const err = new Error(`GitHub API rate limit exhausted. Resets at ${rateLimit.resetAt.toLocaleTimeString()}.` +
|
|
74
|
+
` Run 'gh auth login' for higher limits.`);
|
|
75
|
+
err.status = 403;
|
|
76
|
+
throw err;
|
|
77
|
+
}
|
|
78
|
+
if (response.status === 429) {
|
|
79
|
+
const retryAfter = response.headers.get('retry-after');
|
|
80
|
+
const waitMsg = retryAfter ? ` Retry after ${retryAfter}s.` : '';
|
|
81
|
+
const err = new Error(`GitHub secondary rate limit hit.${waitMsg}`);
|
|
82
|
+
err.status = 429;
|
|
83
|
+
err.retryAfter = retryAfter ? parseInt(retryAfter, 10) : undefined;
|
|
84
|
+
throw err;
|
|
85
|
+
}
|
|
86
|
+
const err = new Error(`GitHub API ${response.status} ${response.statusText} for ${path}`);
|
|
87
|
+
err.status = response.status;
|
|
88
|
+
throw err;
|
|
89
|
+
}
|
|
90
|
+
// Size check via Content-Length header (fast path, avoids reading body).
|
|
91
|
+
const contentLength = response.headers.get('content-length');
|
|
92
|
+
if (contentLength && parseInt(contentLength, 10) > MAX_RESPONSE_SIZE) {
|
|
93
|
+
throw new Error(`GitHub API response too large: ${contentLength} bytes (limit: ${MAX_RESPONSE_SIZE})`);
|
|
94
|
+
}
|
|
95
|
+
const text = await response.text();
|
|
96
|
+
if (text.length > MAX_RESPONSE_SIZE) {
|
|
97
|
+
throw new Error(`GitHub API response body too large: ${text.length} bytes (limit: ${MAX_RESPONSE_SIZE})`);
|
|
98
|
+
}
|
|
99
|
+
return { data: JSON.parse(text), rateLimit };
|
|
100
|
+
}
|
|
101
|
+
// ─── Template domain normalizer ───────────────────────────────────────────────
|
|
102
|
+
/**
|
|
103
|
+
* Strips leading `{var}.` template segments from a domain name.
|
|
104
|
+
* e.g. "{region}.api.example.com" → "api.example.com"
|
|
105
|
+
*/
|
|
106
|
+
export function normalizeTemplatedDomain(domain) {
|
|
107
|
+
let d = domain;
|
|
108
|
+
while (d.startsWith('{')) {
|
|
109
|
+
const next = d.replace(/^\{[^}]+\}\./, '');
|
|
110
|
+
if (next === d)
|
|
111
|
+
break; // malformed template — stop
|
|
112
|
+
d = next;
|
|
113
|
+
}
|
|
114
|
+
return d;
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Pre-process spec's server URLs to normalize templated domains.
|
|
118
|
+
* Mutates the spec object in place — intentional, called before convertOpenAPISpec() consumes it.
|
|
119
|
+
*/
|
|
120
|
+
export function normalizeSpecServerUrls(spec) {
|
|
121
|
+
if (!spec.servers)
|
|
122
|
+
return;
|
|
123
|
+
for (const server of spec.servers) {
|
|
124
|
+
if (!server.url || !server.url.includes('{'))
|
|
125
|
+
continue;
|
|
126
|
+
try {
|
|
127
|
+
const url = new URL(server.url);
|
|
128
|
+
url.hostname = normalizeTemplatedDomain(url.hostname);
|
|
129
|
+
server.url = url.toString();
|
|
130
|
+
}
|
|
131
|
+
catch {
|
|
132
|
+
// URL with leading template like https://{region}.sentry.io fails new URL()
|
|
133
|
+
const match = server.url.match(/^(https?:\/\/)([^/]+)(.*)/);
|
|
134
|
+
if (match) {
|
|
135
|
+
const normalized = normalizeTemplatedDomain(match[2]);
|
|
136
|
+
server.url = match[1] + normalized + match[3];
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
/** Repos not pushed to in 3 years are considered stale. */
|
|
142
|
+
const STALE_THRESHOLD_MS = 3 * 365 * 24 * 60 * 60 * 1000;
|
|
143
|
+
/**
|
|
144
|
+
* Run results through the metadata filter pipeline.
|
|
145
|
+
* Skips forks, archived repos, stale repos (>3 years, unless includeStale),
|
|
146
|
+
* and repos below the minStars threshold.
|
|
147
|
+
*/
|
|
148
|
+
export function filterResults(results, options) {
|
|
149
|
+
const passed = [];
|
|
150
|
+
const skips = [];
|
|
151
|
+
for (const result of results) {
|
|
152
|
+
if (result.isFork) {
|
|
153
|
+
skips.push({ repo: result.repoFullName, reason: 'fork' });
|
|
154
|
+
continue;
|
|
155
|
+
}
|
|
156
|
+
if (result.isArchived) {
|
|
157
|
+
skips.push({ repo: result.repoFullName, reason: 'archived' });
|
|
158
|
+
continue;
|
|
159
|
+
}
|
|
160
|
+
if (!options.includeStale) {
|
|
161
|
+
const pushedMs = new Date(result.pushedAt).getTime();
|
|
162
|
+
if (Date.now() - pushedMs > STALE_THRESHOLD_MS) {
|
|
163
|
+
const pushedDate = new Date(result.pushedAt).toISOString().slice(0, 10);
|
|
164
|
+
skips.push({ repo: result.repoFullName, reason: `stale, last push ${pushedDate}` });
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
if (options.minStars !== undefined && result.stars < options.minStars) {
|
|
169
|
+
skips.push({ repo: result.repoFullName, reason: `${result.stars} stars, below --min-stars ${options.minStars}` });
|
|
170
|
+
continue;
|
|
171
|
+
}
|
|
172
|
+
passed.push(result);
|
|
173
|
+
}
|
|
174
|
+
return { passed, skips };
|
|
175
|
+
}
|
|
176
|
+
// ─── Org Scan — Code Search ───────────────────────────────────────────────────
|
|
177
|
+
export const SPEC_FILENAMES = ['openapi.json', 'openapi.yaml', 'swagger.json', 'swagger.yaml'];
|
|
178
|
+
/**
|
|
179
|
+
* Uses GitHub's Code Search API to find OpenAPI spec files across an org's repos.
|
|
180
|
+
* Queries run sequentially — GitHub's code search has a secondary rate limit of
|
|
181
|
+
* 30 req/min (authenticated). Parallel fan-out risks immediate 403.
|
|
182
|
+
*/
|
|
183
|
+
export async function searchOrgSpecs(org, token) {
|
|
184
|
+
const allItems = [];
|
|
185
|
+
const seen = new Set();
|
|
186
|
+
// Sequential queries — GitHub's code search has a secondary rate limit
|
|
187
|
+
// of 30 req/min (authenticated). Parallel fan-out risks immediate 403.
|
|
188
|
+
for (const filename of SPEC_FILENAMES) {
|
|
189
|
+
const q = encodeURIComponent(`filename:${filename} org:${org}`);
|
|
190
|
+
let response;
|
|
191
|
+
try {
|
|
192
|
+
response = await githubFetch(`/search/code?q=${q}&per_page=100`, token);
|
|
193
|
+
}
|
|
194
|
+
catch (err) {
|
|
195
|
+
if (err.status === 422) {
|
|
196
|
+
throw new Error(`GitHub org '${org}' not found.`);
|
|
197
|
+
}
|
|
198
|
+
throw err;
|
|
199
|
+
}
|
|
200
|
+
for (const item of response.data.items ?? []) {
|
|
201
|
+
const htmlUrl = item.html_url;
|
|
202
|
+
if (seen.has(htmlUrl))
|
|
203
|
+
continue;
|
|
204
|
+
seen.add(htmlUrl);
|
|
205
|
+
const repo = item.repository;
|
|
206
|
+
allItems.push({
|
|
207
|
+
owner: repo.owner?.login ?? org,
|
|
208
|
+
repo: repo.name,
|
|
209
|
+
repoFullName: repo.full_name,
|
|
210
|
+
filePath: item.path,
|
|
211
|
+
htmlUrl,
|
|
212
|
+
specUrl: `https://raw.githubusercontent.com/${repo.full_name}/${repo.default_branch ?? 'main'}/${item.path}`,
|
|
213
|
+
stars: repo.stargazers_count ?? 0,
|
|
214
|
+
isFork: repo.fork ?? false,
|
|
215
|
+
isArchived: repo.archived ?? false,
|
|
216
|
+
pushedAt: repo.pushed_at ?? '',
|
|
217
|
+
description: repo.description ?? '',
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
// Rank: stars desc, then path depth asc (shallower = more likely canonical)
|
|
222
|
+
allItems.sort((a, b) => {
|
|
223
|
+
if (b.stars !== a.stars)
|
|
224
|
+
return b.stars - a.stars;
|
|
225
|
+
const depthA = a.filePath.split('/').length;
|
|
226
|
+
const depthB = b.filePath.split('/').length;
|
|
227
|
+
return depthA - depthB;
|
|
228
|
+
});
|
|
229
|
+
return allItems;
|
|
230
|
+
}
|
|
231
|
+
// ─── Topic Search — Repo Discovery + Spec Probing ─────────────────────────────
|
|
232
|
+
export const CANONICAL_TOPICS = ['openapi-specification', 'openapi', 'openapi3', 'swagger-api'];
|
|
233
|
+
const PROBE_DIRS = ['', 'api', 'spec', 'docs'];
|
|
234
|
+
async function probeForSpecs(owner, repo, token) {
|
|
235
|
+
const found = [];
|
|
236
|
+
for (const dir of PROBE_DIRS) {
|
|
237
|
+
const contentsPath = dir
|
|
238
|
+
? `/repos/${owner}/${repo}/contents/${dir}`
|
|
239
|
+
: `/repos/${owner}/${repo}/contents`;
|
|
240
|
+
try {
|
|
241
|
+
const { data } = await githubFetch(contentsPath, token);
|
|
242
|
+
if (!Array.isArray(data))
|
|
243
|
+
continue;
|
|
244
|
+
for (const entry of data) {
|
|
245
|
+
if (SPEC_FILENAMES.includes(entry.name)) {
|
|
246
|
+
found.push({
|
|
247
|
+
path: entry.path,
|
|
248
|
+
htmlUrl: entry.html_url,
|
|
249
|
+
});
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
catch {
|
|
254
|
+
// Directory doesn't exist or 404 — continue to next
|
|
255
|
+
continue;
|
|
256
|
+
}
|
|
257
|
+
// If we found specs in this dir, don't probe deeper
|
|
258
|
+
if (found.length > 0)
|
|
259
|
+
break;
|
|
260
|
+
}
|
|
261
|
+
return found;
|
|
262
|
+
}
|
|
263
|
+
export async function searchTopicSpecs(topics, token, options) {
|
|
264
|
+
// Fan out topic queries in parallel — repository search has more
|
|
265
|
+
// generous secondary rate limits than code search.
|
|
266
|
+
const responses = await Promise.all(topics.map(topic => githubFetch(`/search/repositories?q=${encodeURIComponent(`topic:${topic}`)}&sort=stars&order=desc&per_page=100`, token)));
|
|
267
|
+
// Dedup by full_name
|
|
268
|
+
const seen = new Set();
|
|
269
|
+
const repos = [];
|
|
270
|
+
for (const { data } of responses) {
|
|
271
|
+
for (const item of data.items ?? []) {
|
|
272
|
+
if (seen.has(item.full_name))
|
|
273
|
+
continue;
|
|
274
|
+
seen.add(item.full_name);
|
|
275
|
+
if (item.stargazers_count < options.minStars)
|
|
276
|
+
continue;
|
|
277
|
+
if (options.query) {
|
|
278
|
+
const q = options.query.toLowerCase();
|
|
279
|
+
const name = (item.name ?? '').toLowerCase();
|
|
280
|
+
const desc = (item.description ?? '').toLowerCase();
|
|
281
|
+
if (!name.includes(q) && !desc.includes(q))
|
|
282
|
+
continue;
|
|
283
|
+
}
|
|
284
|
+
repos.push({
|
|
285
|
+
owner: item.owner?.login,
|
|
286
|
+
repo: item.name,
|
|
287
|
+
fullName: item.full_name,
|
|
288
|
+
stars: item.stargazers_count ?? 0,
|
|
289
|
+
isFork: item.fork ?? false,
|
|
290
|
+
isArchived: item.archived ?? false,
|
|
291
|
+
pushedAt: item.pushed_at ?? '',
|
|
292
|
+
description: item.description ?? '',
|
|
293
|
+
defaultBranch: item.default_branch ?? 'main',
|
|
294
|
+
});
|
|
295
|
+
}
|
|
296
|
+
}
|
|
297
|
+
// Probe each repo for spec files
|
|
298
|
+
const results = [];
|
|
299
|
+
for (const repo of repos) {
|
|
300
|
+
const specs = await probeForSpecs(repo.owner, repo.repo, token);
|
|
301
|
+
for (const spec of specs) {
|
|
302
|
+
results.push({
|
|
303
|
+
owner: repo.owner,
|
|
304
|
+
repo: repo.repo,
|
|
305
|
+
repoFullName: repo.fullName,
|
|
306
|
+
filePath: spec.path,
|
|
307
|
+
htmlUrl: spec.htmlUrl,
|
|
308
|
+
specUrl: `https://raw.githubusercontent.com/${repo.fullName}/${repo.defaultBranch}/${spec.path}`,
|
|
309
|
+
stars: repo.stars,
|
|
310
|
+
isFork: repo.isFork,
|
|
311
|
+
isArchived: repo.isArchived,
|
|
312
|
+
pushedAt: repo.pushedAt,
|
|
313
|
+
description: repo.description,
|
|
314
|
+
});
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
// Sort by stars desc
|
|
318
|
+
results.sort((a, b) => b.stars - a.stars);
|
|
319
|
+
return results;
|
|
320
|
+
}
|
|
321
|
+
// ─── Spec content predicates ──────────────────────────────────────────────────
|
|
322
|
+
/**
|
|
323
|
+
* Returns true if the spec has a usable server URL —
|
|
324
|
+
* either OpenAPI 3.x `servers[0].url` or Swagger 2.0 `host`.
|
|
325
|
+
*/
|
|
326
|
+
export function hasServerUrl(spec) {
|
|
327
|
+
if (spec.host)
|
|
328
|
+
return true;
|
|
329
|
+
if (Array.isArray(spec.servers) && spec.servers.length > 0 && spec.servers[0].url) {
|
|
330
|
+
return true;
|
|
331
|
+
}
|
|
332
|
+
return false;
|
|
333
|
+
}
|
|
334
|
+
// ─── SSRF DI hook ─────────────────────────────────────────────────────────────
|
|
335
|
+
// Indirection so tests can inject a fake resolveAndValidateUrl without network.
|
|
336
|
+
let _resolveAndValidateUrlImpl = _resolveAndValidateUrl;
|
|
337
|
+
/**
|
|
338
|
+
* Override the resolveAndValidateUrl implementation — for testing only.
|
|
339
|
+
* Returns the previous implementation so callers can restore it.
|
|
340
|
+
*/
|
|
341
|
+
export function _setResolveAndValidateUrl(impl) {
|
|
342
|
+
const prev = _resolveAndValidateUrlImpl;
|
|
343
|
+
_resolveAndValidateUrlImpl = impl;
|
|
344
|
+
return prev;
|
|
345
|
+
}
|
|
346
|
+
// ─── Spec content fetching ────────────────────────────────────────────────────
|
|
347
|
+
const MAX_SPEC_SIZE = 10 * 1024 * 1024; // 10 MB
|
|
348
|
+
/**
|
|
349
|
+
* Fetch an OpenAPI spec from raw.githubusercontent.com.
|
|
350
|
+
* Uses direct fetch() — does NOT use githubFetch() since this is a different host.
|
|
351
|
+
* raw.githubusercontent.com requests do not count against the GitHub API rate limit.
|
|
352
|
+
* Auth token is sent to raw.githubusercontent.com (GitHub-controlled domain) for private repo support.
|
|
353
|
+
*/
|
|
354
|
+
export async function fetchGitHubSpec(specUrl, token) {
|
|
355
|
+
const ssrf = await _resolveAndValidateUrlImpl(specUrl);
|
|
356
|
+
if (!ssrf.safe) {
|
|
357
|
+
throw new Error(`SSRF check failed for spec URL ${specUrl}: ${ssrf.reason}`);
|
|
358
|
+
}
|
|
359
|
+
const headers = { 'User-Agent': 'apitap-import' };
|
|
360
|
+
if (token) {
|
|
361
|
+
headers['Authorization'] = `Bearer ${token}`;
|
|
362
|
+
}
|
|
363
|
+
const response = await fetch(specUrl, {
|
|
364
|
+
headers,
|
|
365
|
+
signal: AbortSignal.timeout(30_000),
|
|
366
|
+
});
|
|
367
|
+
if (!response.ok) {
|
|
368
|
+
throw new Error(`HTTP ${response.status} ${response.statusText} for ${specUrl}`);
|
|
369
|
+
}
|
|
370
|
+
const contentLength = response.headers.get('content-length');
|
|
371
|
+
if (contentLength && parseInt(contentLength, 10) > MAX_SPEC_SIZE) {
|
|
372
|
+
throw new Error(`Spec too large: ${contentLength} bytes (limit: ${MAX_SPEC_SIZE})`);
|
|
373
|
+
}
|
|
374
|
+
const text = await response.text();
|
|
375
|
+
if (text.length > MAX_SPEC_SIZE) {
|
|
376
|
+
throw new Error(`Spec body too large: ${text.length} bytes`);
|
|
377
|
+
}
|
|
378
|
+
// Try JSON first, then YAML
|
|
379
|
+
try {
|
|
380
|
+
return JSON.parse(text);
|
|
381
|
+
}
|
|
382
|
+
catch {
|
|
383
|
+
const yaml = await import('js-yaml');
|
|
384
|
+
const parsed = yaml.load(text);
|
|
385
|
+
if (typeof parsed !== 'object' || parsed === null) {
|
|
386
|
+
throw new Error(`Invalid JSON/YAML from ${specUrl}`);
|
|
387
|
+
}
|
|
388
|
+
return parsed;
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
/** Placeholder domains that indicate a spec is not pointing at a real API. */
|
|
392
|
+
const PLACEHOLDER_HOSTS = ['localhost', '127.0.0.1', 'example.com', 'petstore.swagger.io'];
|
|
393
|
+
/**
|
|
394
|
+
* Returns true if the spec's server URL points at localhost, a loopback address,
|
|
395
|
+
* or a well-known placeholder domain (example.com, petstore.swagger.io).
|
|
396
|
+
*/
|
|
397
|
+
export function isLocalhostSpec(spec) {
|
|
398
|
+
const urls = [];
|
|
399
|
+
if (spec.host) {
|
|
400
|
+
urls.push(spec.host);
|
|
401
|
+
}
|
|
402
|
+
if (Array.isArray(spec.servers)) {
|
|
403
|
+
for (const server of spec.servers) {
|
|
404
|
+
if (server.url)
|
|
405
|
+
urls.push(server.url);
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
return urls.some(u => PLACEHOLDER_HOSTS.some(ph => u.includes(ph)));
|
|
409
|
+
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,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC/B,IAAI,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,KAAK,IAAI,EAAE,CAAC;YAClD,MAAM,IAAI,KAAK,CAAC,0BAA0B,OAAO,EAAE,CAAC,CAAC;QACvD,CAAC;QACD,OAAO,MAA6B,CAAC;IACvC,CAAC;AACH,CAAC;AAED,8EAA8E;AAC9E,MAAM,iBAAiB,GAAG,CAAC,WAAW,EAAE,WAAW,EAAE,aAAa,EAAE,qBAAqB,CAAC,CAAC;AAE3F;;;GAGG;AACH,MAAM,UAAU,eAAe,CAAC,IAAyB;IACvD,MAAM,IAAI,GAAa,EAAE,CAAC;IAE1B,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC;QACd,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACvB,CAAC;IACD,IAAI,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC;QAChC,KAAK,MAAM,MAAM,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;YAClC,IAAI,MAAM,CAAC,GAAG;gBAAE,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;QACxC,CAAC;IACH,CAAC;IAED,OAAO,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CACnB,iBAAiB,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAC7C,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@apitap/core",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.9.0",
|
|
4
4
|
"description": "Intercept web API traffic during browsing. Generate portable skill files so AI agents can call APIs directly instead of scraping.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|