@relayfile/adapter-core 0.3.25 → 0.3.26
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/src/cli.js +44 -0
- package/dist/src/cli.js.map +1 -1
- package/dist/src/index.d.ts +2 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +2 -0
- package/dist/src/index.js.map +1 -1
- package/dist/src/proactive/review-adapter.d.ts +107 -0
- package/dist/src/proactive/review-adapter.d.ts.map +1 -0
- package/dist/src/proactive/review-adapter.js +2 -0
- package/dist/src/proactive/review-adapter.js.map +1 -0
- package/dist/src/scope-keys/catalog-generator.d.ts +39 -0
- package/dist/src/scope-keys/catalog-generator.d.ts.map +1 -0
- package/dist/src/scope-keys/catalog-generator.js +393 -0
- package/dist/src/scope-keys/catalog-generator.js.map +1 -0
- package/dist/src/scope-keys/catalog.generated.d.ts +209 -0
- package/dist/src/scope-keys/catalog.generated.d.ts.map +1 -0
- package/dist/src/scope-keys/catalog.generated.js +250 -0
- package/dist/src/scope-keys/catalog.generated.js.map +1 -0
- package/dist/src/triggers/catalog-generator.js +2 -1
- package/dist/src/triggers/catalog-generator.js.map +1 -1
- package/dist/src/triggers/catalog.generated.d.ts +1 -5
- package/dist/src/triggers/catalog.generated.d.ts.map +1 -1
- package/dist/src/triggers/catalog.generated.js +3 -6
- package/dist/src/triggers/catalog.generated.js.map +1 -1
- package/dist/tests/scope-keys/catalog-generator.test.d.ts +2 -0
- package/dist/tests/scope-keys/catalog-generator.test.d.ts.map +1 -0
- package/dist/tests/scope-keys/catalog-generator.test.js +23 -0
- package/dist/tests/scope-keys/catalog-generator.test.js.map +1 -0
- package/package.json +5 -1
|
@@ -0,0 +1,393 @@
|
|
|
1
|
+
import { access, mkdir, readdir, readFile, writeFile } from "node:fs/promises";
|
|
2
|
+
import { dirname, join, relative, resolve } from "node:path";
|
|
3
|
+
import { pathToFileURL } from "node:url";
|
|
4
|
+
import YAML from "yaml";
|
|
5
|
+
import { findRepoRoot } from "../triggers/catalog-generator.js";
|
|
6
|
+
const GENERATED_HEADER = `/**
|
|
7
|
+
* Generated by \`adapter-core scope-keys generate\`.
|
|
8
|
+
*
|
|
9
|
+
* Scope keys are emitted verbatim from adapter supportedScopeKeys() methods or
|
|
10
|
+
* mapping.yaml \`scopeKeys:\` keys. They name the per-provider connection filters
|
|
11
|
+
* a persona may set under \`integrations.<provider>.scope\`.
|
|
12
|
+
*/
|
|
13
|
+
`;
|
|
14
|
+
const NON_ADAPTER_PACKAGES = new Set(["@relayfile/adapter-core", "@relayfile/webhook-server"]);
|
|
15
|
+
export async function generateScopeKeyCatalog(repoRoot) {
|
|
16
|
+
repoRoot = repoRoot ? resolve(repoRoot) : await findRepoRoot();
|
|
17
|
+
const packages = await listAdapterPackages(repoRoot);
|
|
18
|
+
const entries = [];
|
|
19
|
+
const sources = [];
|
|
20
|
+
const adaptersWithoutKnownScopeKeys = [];
|
|
21
|
+
for (const adapterPackage of packages) {
|
|
22
|
+
const mappingScopeKeys = await readMappingScopeKeys(repoRoot, adapterPackage);
|
|
23
|
+
const supportedScopeKeys = await readSupportedScopeKeys(adapterPackage);
|
|
24
|
+
let hasKnownScopeKeys = false;
|
|
25
|
+
if (supportedScopeKeys.keys.length > 0) {
|
|
26
|
+
// `supportedScopeKeys()` is authoritative. Unlike triggers (where mapping
|
|
27
|
+
// webhooks are a legitimate second delivery contract), scope keys have
|
|
28
|
+
// one source of truth, so the mapping block is a FALLBACK only — never
|
|
29
|
+
// merged. Merging would let a stale `scopeKeys:` YAML entry outlive an
|
|
30
|
+
// adapter that renamed/removed a scope, and persona tooling would then
|
|
31
|
+
// autocomplete/lint a key the adapter no longer supports.
|
|
32
|
+
entries.push({ provider: supportedScopeKeys.provider, keys: supportedScopeKeys.keys });
|
|
33
|
+
sources.push({
|
|
34
|
+
packageName: adapterPackage.packageName,
|
|
35
|
+
packagePath: adapterPackage.relativePath,
|
|
36
|
+
provider: supportedScopeKeys.provider,
|
|
37
|
+
source: "supportedScopeKeys",
|
|
38
|
+
});
|
|
39
|
+
hasKnownScopeKeys = true;
|
|
40
|
+
}
|
|
41
|
+
else if (mappingScopeKeys.length > 0) {
|
|
42
|
+
entries.push({ provider: adapterPackage.provider, keys: mappingScopeKeys });
|
|
43
|
+
sources.push({
|
|
44
|
+
packageName: adapterPackage.packageName,
|
|
45
|
+
packagePath: adapterPackage.relativePath,
|
|
46
|
+
provider: adapterPackage.provider,
|
|
47
|
+
source: "mapping.scopeKeys",
|
|
48
|
+
});
|
|
49
|
+
hasKnownScopeKeys = true;
|
|
50
|
+
}
|
|
51
|
+
if (hasKnownScopeKeys) {
|
|
52
|
+
continue;
|
|
53
|
+
}
|
|
54
|
+
adaptersWithoutKnownScopeKeys.push({
|
|
55
|
+
packageName: adapterPackage.packageName,
|
|
56
|
+
packagePath: adapterPackage.relativePath,
|
|
57
|
+
provider: adapterPackage.provider,
|
|
58
|
+
reason: supportedScopeKeys.error ??
|
|
59
|
+
"No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block",
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
return {
|
|
63
|
+
catalog: sortCatalog(entries),
|
|
64
|
+
sources: sources.sort(compareByPackagePath),
|
|
65
|
+
adaptersWithoutKnownScopeKeys: adaptersWithoutKnownScopeKeys.sort(compareByPackagePath),
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
export async function writeScopeKeyCatalog(options = {}) {
|
|
69
|
+
const repoRoot = options.repoRoot ? resolve(options.repoRoot) : await findRepoRoot();
|
|
70
|
+
const generation = await generateScopeKeyCatalog(repoRoot);
|
|
71
|
+
const paths = scopeKeyCatalogPaths(repoRoot);
|
|
72
|
+
const expectedFiles = new Map([
|
|
73
|
+
[paths.catalogJson, renderJson(generation.catalog)],
|
|
74
|
+
[paths.noScopeKeyJson, renderJson(generation.adaptersWithoutKnownScopeKeys)],
|
|
75
|
+
[paths.catalogTs, renderScopeKeyCatalogModule(generation)],
|
|
76
|
+
]);
|
|
77
|
+
if (options.check) {
|
|
78
|
+
const mismatches = [];
|
|
79
|
+
for (const [filePath, expected] of expectedFiles) {
|
|
80
|
+
let actual = "";
|
|
81
|
+
try {
|
|
82
|
+
actual = await readFile(filePath, "utf8");
|
|
83
|
+
}
|
|
84
|
+
catch {
|
|
85
|
+
mismatches.push(relative(repoRoot, filePath));
|
|
86
|
+
continue;
|
|
87
|
+
}
|
|
88
|
+
if (actual !== expected) {
|
|
89
|
+
mismatches.push(relative(repoRoot, filePath));
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
if (mismatches.length > 0) {
|
|
93
|
+
throw new Error(`Scope-key catalog is out of sync. Run \`adapter-core scope-keys generate\`. Stale files: ${mismatches.join(", ")}`);
|
|
94
|
+
}
|
|
95
|
+
return generation;
|
|
96
|
+
}
|
|
97
|
+
for (const [filePath, contents] of expectedFiles) {
|
|
98
|
+
await mkdir(dirname(filePath), { recursive: true });
|
|
99
|
+
await writeFile(filePath, contents);
|
|
100
|
+
}
|
|
101
|
+
return generation;
|
|
102
|
+
}
|
|
103
|
+
export function scopeKeyCatalogPaths(repoRoot) {
|
|
104
|
+
const scopeDir = join(repoRoot, "packages", "core", "src", "scope-keys");
|
|
105
|
+
return {
|
|
106
|
+
catalogJson: join(scopeDir, "catalog.generated.json"),
|
|
107
|
+
noScopeKeyJson: join(scopeDir, "adapters-without-known-scope-keys.generated.json"),
|
|
108
|
+
catalogTs: join(scopeDir, "catalog.generated.ts"),
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
export function renderScopeKeyCatalogModule(generation) {
|
|
112
|
+
return `${GENERATED_HEADER}
|
|
113
|
+
export const KNOWN_SCOPE_KEY_CATALOG = ${renderInlineJson(generation.catalog)} as const satisfies Record<
|
|
114
|
+
string,
|
|
115
|
+
readonly string[]
|
|
116
|
+
>;
|
|
117
|
+
|
|
118
|
+
export const ADAPTERS_WITHOUT_KNOWN_SCOPE_KEYS = ${renderInlineJson(generation.adaptersWithoutKnownScopeKeys)} as const;
|
|
119
|
+
|
|
120
|
+
export type ScopeKeyProvider = keyof typeof KNOWN_SCOPE_KEY_CATALOG;
|
|
121
|
+
export type ScopeKey<P extends ScopeKeyProvider> =
|
|
122
|
+
(typeof KNOWN_SCOPE_KEY_CATALOG)[P][number];
|
|
123
|
+
`;
|
|
124
|
+
}
|
|
125
|
+
async function listAdapterPackages(repoRoot) {
|
|
126
|
+
const packagesDir = join(repoRoot, "packages");
|
|
127
|
+
const names = await readdir(packagesDir);
|
|
128
|
+
const packages = [];
|
|
129
|
+
for (const name of names.sort()) {
|
|
130
|
+
const dir = join(packagesDir, name);
|
|
131
|
+
const packageJsonPath = join(dir, "package.json");
|
|
132
|
+
let packageJson;
|
|
133
|
+
try {
|
|
134
|
+
packageJson = JSON.parse(await readFile(packageJsonPath, "utf8"));
|
|
135
|
+
}
|
|
136
|
+
catch {
|
|
137
|
+
continue;
|
|
138
|
+
}
|
|
139
|
+
if (!packageJson.name || NON_ADAPTER_PACKAGES.has(packageJson.name)) {
|
|
140
|
+
continue;
|
|
141
|
+
}
|
|
142
|
+
packages.push({
|
|
143
|
+
dir,
|
|
144
|
+
packageName: packageJson.name,
|
|
145
|
+
provider: inferProviderSlug(packageJson.name, name),
|
|
146
|
+
relativePath: relative(repoRoot, dir),
|
|
147
|
+
});
|
|
148
|
+
}
|
|
149
|
+
return packages;
|
|
150
|
+
}
|
|
151
|
+
async function readSupportedScopeKeys(adapterPackage) {
|
|
152
|
+
const sourceEntryPoint = join(adapterPackage.dir, "src", "index.ts");
|
|
153
|
+
const sourceScopes = await readSupportedScopesFromSource(sourceEntryPoint);
|
|
154
|
+
const builtEntryPoint = await firstExistingPath([
|
|
155
|
+
join(adapterPackage.dir, "dist", "index.js"),
|
|
156
|
+
join(adapterPackage.dir, "dist", "src", "index.js"),
|
|
157
|
+
]);
|
|
158
|
+
let importError;
|
|
159
|
+
if (builtEntryPoint) {
|
|
160
|
+
const supportedScopeKeys = await readSupportedScopeKeysFromModule(adapterPackage, builtEntryPoint);
|
|
161
|
+
if (supportedScopeKeys.keys.length > 0) {
|
|
162
|
+
return supportedScopeKeys;
|
|
163
|
+
}
|
|
164
|
+
// Remember an import failure so it surfaces as the adapter's "no scope
|
|
165
|
+
// keys" reason instead of the generic "no implementation" message — a
|
|
166
|
+
// swallowed import error otherwise hides a real build/runtime problem.
|
|
167
|
+
importError = supportedScopeKeys.error;
|
|
168
|
+
}
|
|
169
|
+
if (sourceScopes.length > 0) {
|
|
170
|
+
return { keys: sourceScopes, provider: adapterPackage.provider };
|
|
171
|
+
}
|
|
172
|
+
if (importError) {
|
|
173
|
+
return { keys: [], provider: adapterPackage.provider, error: importError };
|
|
174
|
+
}
|
|
175
|
+
if (!builtEntryPoint && !(await pathExists(sourceEntryPoint))) {
|
|
176
|
+
return {
|
|
177
|
+
keys: [],
|
|
178
|
+
provider: adapterPackage.provider,
|
|
179
|
+
error: "No adapter entrypoint at dist/index.js, dist/src/index.js, or src/index.ts",
|
|
180
|
+
};
|
|
181
|
+
}
|
|
182
|
+
return { keys: [], provider: adapterPackage.provider };
|
|
183
|
+
}
|
|
184
|
+
async function readSupportedScopeKeysFromModule(adapterPackage, entryPoint) {
|
|
185
|
+
let moduleExports;
|
|
186
|
+
try {
|
|
187
|
+
moduleExports = (await import(pathToFileURL(entryPoint).href));
|
|
188
|
+
}
|
|
189
|
+
catch (error) {
|
|
190
|
+
return {
|
|
191
|
+
keys: [],
|
|
192
|
+
provider: adapterPackage.provider,
|
|
193
|
+
error: `Could not import built adapter entrypoint: ${errorMessage(error)}`,
|
|
194
|
+
};
|
|
195
|
+
}
|
|
196
|
+
const candidates = Object.entries(moduleExports)
|
|
197
|
+
.filter(([, value]) => hasSupportedScopeKeysPrototype(value))
|
|
198
|
+
.sort(([left], [right]) => left.localeCompare(right));
|
|
199
|
+
for (const [, Candidate] of candidates) {
|
|
200
|
+
const instance = instantiateAdapter(Candidate);
|
|
201
|
+
if (!instance) {
|
|
202
|
+
continue;
|
|
203
|
+
}
|
|
204
|
+
let keys;
|
|
205
|
+
try {
|
|
206
|
+
keys = instance.supportedScopeKeys();
|
|
207
|
+
}
|
|
208
|
+
catch {
|
|
209
|
+
continue;
|
|
210
|
+
}
|
|
211
|
+
const normalized = normalizeKeys(keys);
|
|
212
|
+
if (normalized.length > 0) {
|
|
213
|
+
return {
|
|
214
|
+
keys: normalized,
|
|
215
|
+
provider: typeof instance.name === "string" && instance.name ? instance.name : adapterPackage.provider,
|
|
216
|
+
};
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
return { keys: [], provider: adapterPackage.provider };
|
|
220
|
+
}
|
|
221
|
+
async function readSupportedScopesFromSource(entryPoint) {
|
|
222
|
+
let contents;
|
|
223
|
+
try {
|
|
224
|
+
contents = await readFile(entryPoint, "utf8");
|
|
225
|
+
}
|
|
226
|
+
catch {
|
|
227
|
+
return [];
|
|
228
|
+
}
|
|
229
|
+
const supportedScopeKeysMethod = /\bsupportedScopeKeys\s*\([^)]*\)\s*(?::[^{]+)?\{\s*return\s*\[([\s\S]*?)\]\s*;?\s*\}/u.exec(contents);
|
|
230
|
+
if (!supportedScopeKeysMethod) {
|
|
231
|
+
return [];
|
|
232
|
+
}
|
|
233
|
+
const keys = new Set();
|
|
234
|
+
const stringLiteral = /["']([^"']+)["']/gu;
|
|
235
|
+
let match;
|
|
236
|
+
while ((match = stringLiteral.exec(supportedScopeKeysMethod[1] ?? "")) !== null) {
|
|
237
|
+
keys.add(match[1]);
|
|
238
|
+
}
|
|
239
|
+
return [...keys].sort();
|
|
240
|
+
}
|
|
241
|
+
async function readMappingScopeKeys(repoRoot, adapterPackage) {
|
|
242
|
+
const packageKeys = await readMappingScopeKeysFromDir(adapterPackage.dir);
|
|
243
|
+
if (packageKeys.length > 0) {
|
|
244
|
+
return packageKeys;
|
|
245
|
+
}
|
|
246
|
+
const coreMappingDir = join(repoRoot, "packages", "core", "mappings");
|
|
247
|
+
return readMappingScopeKeysFromFiles([join(coreMappingDir, `${adapterPackage.provider}.mapping.yaml`)]);
|
|
248
|
+
}
|
|
249
|
+
async function readMappingScopeKeysFromDir(packageDir) {
|
|
250
|
+
const filenames = (await readdir(packageDir)).filter((name) => name.endsWith(".mapping.yaml")).sort();
|
|
251
|
+
return readMappingScopeKeysFromFiles(filenames.map((filename) => join(packageDir, filename)));
|
|
252
|
+
}
|
|
253
|
+
async function readMappingScopeKeysFromFiles(paths) {
|
|
254
|
+
const keys = new Set();
|
|
255
|
+
for (const path of paths) {
|
|
256
|
+
let contents;
|
|
257
|
+
try {
|
|
258
|
+
contents = await readFile(path, "utf8");
|
|
259
|
+
}
|
|
260
|
+
catch {
|
|
261
|
+
continue;
|
|
262
|
+
}
|
|
263
|
+
const parsed = YAML.parse(contents);
|
|
264
|
+
if (!parsed)
|
|
265
|
+
continue;
|
|
266
|
+
// Accept either a list (`scopeKeys: [owner, repo]`) or a map keyed by name.
|
|
267
|
+
if (Array.isArray(parsed.scopeKeys)) {
|
|
268
|
+
for (const key of parsed.scopeKeys)
|
|
269
|
+
if (typeof key === "string")
|
|
270
|
+
keys.add(key);
|
|
271
|
+
}
|
|
272
|
+
else if (isRecord(parsed.scopeKeys)) {
|
|
273
|
+
for (const key of Object.keys(parsed.scopeKeys))
|
|
274
|
+
keys.add(key);
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
return [...keys].sort();
|
|
278
|
+
}
|
|
279
|
+
async function firstExistingPath(paths) {
|
|
280
|
+
for (const path of paths) {
|
|
281
|
+
if (await pathExists(path)) {
|
|
282
|
+
return path;
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
return undefined;
|
|
286
|
+
}
|
|
287
|
+
async function pathExists(path) {
|
|
288
|
+
try {
|
|
289
|
+
await access(path);
|
|
290
|
+
return true;
|
|
291
|
+
}
|
|
292
|
+
catch {
|
|
293
|
+
return false;
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
function instantiateAdapter(Candidate) {
|
|
297
|
+
const client = createClientStub();
|
|
298
|
+
const provider = createProviderStub();
|
|
299
|
+
const attempts = [
|
|
300
|
+
[client, provider, {}],
|
|
301
|
+
[provider, {}],
|
|
302
|
+
[client, {}],
|
|
303
|
+
[client, provider],
|
|
304
|
+
[provider],
|
|
305
|
+
[client],
|
|
306
|
+
[{}],
|
|
307
|
+
[],
|
|
308
|
+
];
|
|
309
|
+
for (const args of attempts) {
|
|
310
|
+
try {
|
|
311
|
+
return new Candidate(...args);
|
|
312
|
+
}
|
|
313
|
+
catch {
|
|
314
|
+
// Try the next common adapter constructor shape.
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
return undefined;
|
|
318
|
+
}
|
|
319
|
+
function createClientStub() {
|
|
320
|
+
return {
|
|
321
|
+
async deleteFile() {
|
|
322
|
+
return undefined;
|
|
323
|
+
},
|
|
324
|
+
getWrittenRevision() {
|
|
325
|
+
return undefined;
|
|
326
|
+
},
|
|
327
|
+
async readFile() {
|
|
328
|
+
return undefined;
|
|
329
|
+
},
|
|
330
|
+
async writeFile() {
|
|
331
|
+
return {};
|
|
332
|
+
},
|
|
333
|
+
};
|
|
334
|
+
}
|
|
335
|
+
function createProviderStub() {
|
|
336
|
+
return {
|
|
337
|
+
name: "scope-catalog-generator",
|
|
338
|
+
async proxy() {
|
|
339
|
+
return { status: 200, headers: {}, body: null };
|
|
340
|
+
},
|
|
341
|
+
async healthCheck() {
|
|
342
|
+
return { ok: true };
|
|
343
|
+
},
|
|
344
|
+
};
|
|
345
|
+
}
|
|
346
|
+
function hasSupportedScopeKeysPrototype(value) {
|
|
347
|
+
return (typeof value === "function" &&
|
|
348
|
+
isRecord(value.prototype) &&
|
|
349
|
+
typeof value.prototype.supportedScopeKeys === "function");
|
|
350
|
+
}
|
|
351
|
+
function normalizeKeys(value) {
|
|
352
|
+
if (!Array.isArray(value)) {
|
|
353
|
+
return [];
|
|
354
|
+
}
|
|
355
|
+
return [...new Set(value.filter((key) => typeof key === "string" && key.length > 0))].sort();
|
|
356
|
+
}
|
|
357
|
+
function sortCatalog(entries) {
|
|
358
|
+
const catalog = new Map();
|
|
359
|
+
for (const entry of entries) {
|
|
360
|
+
const existing = catalog.get(entry.provider) ?? new Set();
|
|
361
|
+
for (const key of entry.keys)
|
|
362
|
+
existing.add(key);
|
|
363
|
+
catalog.set(entry.provider, existing);
|
|
364
|
+
}
|
|
365
|
+
return Object.fromEntries([...catalog.entries()]
|
|
366
|
+
.sort(([left], [right]) => left.localeCompare(right))
|
|
367
|
+
.map(([provider, keys]) => [provider, [...keys].sort()]));
|
|
368
|
+
}
|
|
369
|
+
function inferProviderSlug(packageName, directoryName) {
|
|
370
|
+
if (packageName.startsWith("@relayfile/adapter-")) {
|
|
371
|
+
return packageName.slice("@relayfile/adapter-".length);
|
|
372
|
+
}
|
|
373
|
+
if (packageName.startsWith("@relayfile/")) {
|
|
374
|
+
return packageName.slice("@relayfile/".length);
|
|
375
|
+
}
|
|
376
|
+
return directoryName;
|
|
377
|
+
}
|
|
378
|
+
function compareByPackagePath(left, right) {
|
|
379
|
+
return left.packagePath.localeCompare(right.packagePath) || left.provider.localeCompare(right.provider);
|
|
380
|
+
}
|
|
381
|
+
function renderJson(value) {
|
|
382
|
+
return `${JSON.stringify(value, null, 2)}\n`;
|
|
383
|
+
}
|
|
384
|
+
function renderInlineJson(value) {
|
|
385
|
+
return JSON.stringify(value, null, 2);
|
|
386
|
+
}
|
|
387
|
+
function isRecord(value) {
|
|
388
|
+
return value !== null && typeof value === "object";
|
|
389
|
+
}
|
|
390
|
+
function errorMessage(error) {
|
|
391
|
+
return error instanceof Error ? error.message : String(error);
|
|
392
|
+
}
|
|
393
|
+
//# sourceMappingURL=catalog-generator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog-generator.js","sourceRoot":"","sources":["../../../src/scope-keys/catalog-generator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,E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O,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAChE,CAAC"}
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by `adapter-core scope-keys generate`.
|
|
3
|
+
*
|
|
4
|
+
* Scope keys are emitted verbatim from adapter supportedScopeKeys() methods or
|
|
5
|
+
* mapping.yaml `scopeKeys:` keys. They name the per-provider connection filters
|
|
6
|
+
* a persona may set under `integrations.<provider>.scope`.
|
|
7
|
+
*/
|
|
8
|
+
export declare const KNOWN_SCOPE_KEY_CATALOG: {
|
|
9
|
+
readonly github: readonly ["owner", "repo"];
|
|
10
|
+
};
|
|
11
|
+
export declare const ADAPTERS_WITHOUT_KNOWN_SCOPE_KEYS: readonly [{
|
|
12
|
+
readonly packageName: "@relayfile/adapter-airtable";
|
|
13
|
+
readonly packagePath: "packages/airtable";
|
|
14
|
+
readonly provider: "airtable";
|
|
15
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
16
|
+
}, {
|
|
17
|
+
readonly packageName: "@relayfile/adapter-asana";
|
|
18
|
+
readonly packagePath: "packages/asana";
|
|
19
|
+
readonly provider: "asana";
|
|
20
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
21
|
+
}, {
|
|
22
|
+
readonly packageName: "@relayfile/azure-blob";
|
|
23
|
+
readonly packagePath: "packages/azure-blob";
|
|
24
|
+
readonly provider: "azure-blob";
|
|
25
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
26
|
+
}, {
|
|
27
|
+
readonly packageName: "@relayfile/box";
|
|
28
|
+
readonly packagePath: "packages/box";
|
|
29
|
+
readonly provider: "box";
|
|
30
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
31
|
+
}, {
|
|
32
|
+
readonly packageName: "@relayfile/adapter-calendly";
|
|
33
|
+
readonly packagePath: "packages/calendly";
|
|
34
|
+
readonly provider: "calendly";
|
|
35
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
36
|
+
}, {
|
|
37
|
+
readonly packageName: "@relayfile/adapter-clickup";
|
|
38
|
+
readonly packagePath: "packages/clickup";
|
|
39
|
+
readonly provider: "clickup";
|
|
40
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
41
|
+
}, {
|
|
42
|
+
readonly packageName: "@relayfile/adapter-confluence";
|
|
43
|
+
readonly packagePath: "packages/confluence";
|
|
44
|
+
readonly provider: "confluence";
|
|
45
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
46
|
+
}, {
|
|
47
|
+
readonly packageName: "@relayfile/adapter-docker-hub";
|
|
48
|
+
readonly packagePath: "packages/docker-hub";
|
|
49
|
+
readonly provider: "docker-hub";
|
|
50
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
51
|
+
}, {
|
|
52
|
+
readonly packageName: "@relayfile/adapter-dropbox";
|
|
53
|
+
readonly packagePath: "packages/dropbox";
|
|
54
|
+
readonly provider: "dropbox";
|
|
55
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
56
|
+
}, {
|
|
57
|
+
readonly packageName: "@relayfile/adapter-fathom";
|
|
58
|
+
readonly packagePath: "packages/fathom";
|
|
59
|
+
readonly provider: "fathom";
|
|
60
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
61
|
+
}, {
|
|
62
|
+
readonly packageName: "@relayfile/gcs";
|
|
63
|
+
readonly packagePath: "packages/gcs";
|
|
64
|
+
readonly provider: "gcs";
|
|
65
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
66
|
+
}, {
|
|
67
|
+
readonly packageName: "@relayfile/adapter-gitlab";
|
|
68
|
+
readonly packagePath: "packages/gitlab";
|
|
69
|
+
readonly provider: "gitlab";
|
|
70
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
71
|
+
}, {
|
|
72
|
+
readonly packageName: "@relayfile/gmail";
|
|
73
|
+
readonly packagePath: "packages/gmail";
|
|
74
|
+
readonly provider: "gmail";
|
|
75
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
76
|
+
}, {
|
|
77
|
+
readonly packageName: "@relayfile/adapter-google-calendar";
|
|
78
|
+
readonly packagePath: "packages/google-calendar";
|
|
79
|
+
readonly provider: "google-calendar";
|
|
80
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
81
|
+
}, {
|
|
82
|
+
readonly packageName: "@relayfile/google-drive";
|
|
83
|
+
readonly packagePath: "packages/google-drive";
|
|
84
|
+
readonly provider: "google-drive";
|
|
85
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
86
|
+
}, {
|
|
87
|
+
readonly packageName: "@relayfile/adapter-granola";
|
|
88
|
+
readonly packagePath: "packages/granola";
|
|
89
|
+
readonly provider: "granola";
|
|
90
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
91
|
+
}, {
|
|
92
|
+
readonly packageName: "@relayfile/adapter-hubspot";
|
|
93
|
+
readonly packagePath: "packages/hubspot";
|
|
94
|
+
readonly provider: "hubspot";
|
|
95
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
96
|
+
}, {
|
|
97
|
+
readonly packageName: "@relayfile/adapter-intercom";
|
|
98
|
+
readonly packagePath: "packages/intercom";
|
|
99
|
+
readonly provider: "intercom";
|
|
100
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
101
|
+
}, {
|
|
102
|
+
readonly packageName: "@relayfile/adapter-jira";
|
|
103
|
+
readonly packagePath: "packages/jira";
|
|
104
|
+
readonly provider: "jira";
|
|
105
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
106
|
+
}, {
|
|
107
|
+
readonly packageName: "@relayfile/adapter-linear";
|
|
108
|
+
readonly packagePath: "packages/linear";
|
|
109
|
+
readonly provider: "linear";
|
|
110
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
111
|
+
}, {
|
|
112
|
+
readonly packageName: "@relayfile/adapter-mailgun";
|
|
113
|
+
readonly packagePath: "packages/mailgun";
|
|
114
|
+
readonly provider: "mailgun";
|
|
115
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
116
|
+
}, {
|
|
117
|
+
readonly packageName: "@relayfile/adapter-mixpanel";
|
|
118
|
+
readonly packagePath: "packages/mixpanel";
|
|
119
|
+
readonly provider: "mixpanel";
|
|
120
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
121
|
+
}, {
|
|
122
|
+
readonly packageName: "@relayfile/adapter-notion";
|
|
123
|
+
readonly packagePath: "packages/notion";
|
|
124
|
+
readonly provider: "notion";
|
|
125
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
126
|
+
}, {
|
|
127
|
+
readonly packageName: "@relayfile/onedrive";
|
|
128
|
+
readonly packagePath: "packages/onedrive";
|
|
129
|
+
readonly provider: "onedrive";
|
|
130
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
131
|
+
}, {
|
|
132
|
+
readonly packageName: "@relayfile/adapter-pipedrive";
|
|
133
|
+
readonly packagePath: "packages/pipedrive";
|
|
134
|
+
readonly provider: "pipedrive";
|
|
135
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
136
|
+
}, {
|
|
137
|
+
readonly packageName: "@relayfile/postgres";
|
|
138
|
+
readonly packagePath: "packages/postgres";
|
|
139
|
+
readonly provider: "postgres";
|
|
140
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
141
|
+
}, {
|
|
142
|
+
readonly packageName: "@relayfile/adapter-reddit";
|
|
143
|
+
readonly packagePath: "packages/reddit";
|
|
144
|
+
readonly provider: "reddit";
|
|
145
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
146
|
+
}, {
|
|
147
|
+
readonly packageName: "@relayfile/redis";
|
|
148
|
+
readonly packagePath: "packages/redis";
|
|
149
|
+
readonly provider: "redis";
|
|
150
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
151
|
+
}, {
|
|
152
|
+
readonly packageName: "@relayfile/s3";
|
|
153
|
+
readonly packagePath: "packages/s3";
|
|
154
|
+
readonly provider: "s3";
|
|
155
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
156
|
+
}, {
|
|
157
|
+
readonly packageName: "@relayfile/adapter-salesforce";
|
|
158
|
+
readonly packagePath: "packages/salesforce";
|
|
159
|
+
readonly provider: "salesforce";
|
|
160
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
161
|
+
}, {
|
|
162
|
+
readonly packageName: "@relayfile/adapter-segment";
|
|
163
|
+
readonly packagePath: "packages/segment";
|
|
164
|
+
readonly provider: "segment";
|
|
165
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
166
|
+
}, {
|
|
167
|
+
readonly packageName: "@relayfile/adapter-sendgrid";
|
|
168
|
+
readonly packagePath: "packages/sendgrid";
|
|
169
|
+
readonly provider: "sendgrid";
|
|
170
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
171
|
+
}, {
|
|
172
|
+
readonly packageName: "@relayfile/sharepoint";
|
|
173
|
+
readonly packagePath: "packages/sharepoint";
|
|
174
|
+
readonly provider: "sharepoint";
|
|
175
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
176
|
+
}, {
|
|
177
|
+
readonly packageName: "@relayfile/adapter-shopify";
|
|
178
|
+
readonly packagePath: "packages/shopify";
|
|
179
|
+
readonly provider: "shopify";
|
|
180
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
181
|
+
}, {
|
|
182
|
+
readonly packageName: "@relayfile/adapter-slack";
|
|
183
|
+
readonly packagePath: "packages/slack";
|
|
184
|
+
readonly provider: "slack";
|
|
185
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
186
|
+
}, {
|
|
187
|
+
readonly packageName: "@relayfile/adapter-stripe";
|
|
188
|
+
readonly packagePath: "packages/stripe";
|
|
189
|
+
readonly provider: "stripe";
|
|
190
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
191
|
+
}, {
|
|
192
|
+
readonly packageName: "@relayfile/adapter-teams";
|
|
193
|
+
readonly packagePath: "packages/teams";
|
|
194
|
+
readonly provider: "teams";
|
|
195
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
196
|
+
}, {
|
|
197
|
+
readonly packageName: "@relayfile/adapter-x";
|
|
198
|
+
readonly packagePath: "packages/x";
|
|
199
|
+
readonly provider: "x";
|
|
200
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
201
|
+
}, {
|
|
202
|
+
readonly packageName: "@relayfile/adapter-zendesk";
|
|
203
|
+
readonly packagePath: "packages/zendesk";
|
|
204
|
+
readonly provider: "zendesk";
|
|
205
|
+
readonly reason: "No supportedScopeKeys() implementation and no mapping.yaml scopeKeys block";
|
|
206
|
+
}];
|
|
207
|
+
export type ScopeKeyProvider = keyof typeof KNOWN_SCOPE_KEY_CATALOG;
|
|
208
|
+
export type ScopeKey<P extends ScopeKeyProvider> = (typeof KNOWN_SCOPE_KEY_CATALOG)[P][number];
|
|
209
|
+
//# sourceMappingURL=catalog.generated.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog.generated.d.ts","sourceRoot":"","sources":["../../../src/scope-keys/catalog.generated.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,eAAO,MAAM,uBAAuB;;CAQnC,CAAC;AAEF,eAAO,MAAM,iCAAiC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2OpC,CAAC;AAEX,MAAM,MAAM,gBAAgB,GAAG,MAAM,OAAO,uBAAuB,CAAC;AACpE,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,gBAAgB,IAC7C,CAAC,OAAO,uBAAuB,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC"}
|