mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-25 17:45:53 +01:00
Fix teams catalog CI regressions
This commit is contained in:
1 parent
4cdef05fe2
commit
8ded763e8c
5 files changed
+89
-2
No files matched your search
@@ -138,8 +138,8 @@ export interface CompanyPortabilityAgentManifestEntry {
|
||||
icon: string | null;
|
||||
capabilities: string | null;
|
||||
reportsToSlug: string | null;
|
||||
reportsToExistingAgentId: string | null;
|
||||
reportsToExistingAgentSlug: string | null;
|
||||
reportsToExistingAgentId?: string | null;
|
||||
reportsToExistingAgentSlug?: string | null;
|
||||
adapterType: string;
|
||||
adapterConfig: Record<string, unknown>;
|
||||
runtimeConfig: Record<string, unknown>;
|
||||
|
||||
@@ -89,6 +89,7 @@ export type {
|
||||
CatalogTeamSourceRef,
|
||||
CatalogTeamFile,
|
||||
CatalogTeam,
|
||||
CatalogManifest,
|
||||
CatalogTeamListQuery,
|
||||
CatalogTeamFileDetail,
|
||||
CatalogTeamSourcePolicy,
|
||||
|
||||
@@ -110,6 +110,14 @@ export interface CatalogTeam {
|
||||
packageVersion?: string;
|
||||
}
|
||||
|
||||
export interface CatalogManifest {
|
||||
schemaVersion: 1;
|
||||
packageName: "@paperclipai/teams-catalog";
|
||||
packageVersion: string;
|
||||
generatedAt: string;
|
||||
teams: CatalogTeam[];
|
||||
}
|
||||
|
||||
export interface CatalogTeamListQuery {
|
||||
kind?: CatalogTeamKind;
|
||||
category?: string;
|
||||
|
||||
@@ -42,6 +42,7 @@ const apiPrefixes: Record<string, string> = {
|
||||
"secrets.ts": "/api",
|
||||
"sidebar-badges.ts": "/api",
|
||||
"sidebar-preferences.ts": "/api",
|
||||
"teams-catalog.ts": "/api",
|
||||
"user-profiles.ts": "/api",
|
||||
};
|
||||
|
||||
|
||||
@@ -124,6 +124,10 @@ import {
|
||||
secretProviderConfigDiscoveryPreviewSchema,
|
||||
remoteSecretImportPreviewSchema,
|
||||
remoteSecretImportSchema,
|
||||
// Team catalog
|
||||
catalogTeamInstallSchema,
|
||||
catalogTeamListQuerySchema,
|
||||
catalogTeamPreviewSchema,
|
||||
} from "@paperclipai/shared";
|
||||
|
||||
type JsonSchema = Record<string, unknown>;
|
||||
@@ -871,6 +875,79 @@ registry.registerPath({
|
||||
responses: { 200: r.ok(), 400: r.badRequest, 401: r.unauthorized },
|
||||
});
|
||||
|
||||
// ─── Team Catalog ────────────────────────────────────────────────────────────
|
||||
|
||||
registry.registerPath({
|
||||
method: "get",
|
||||
path: "/api/teams/catalog",
|
||||
tags: ["team-catalog"],
|
||||
summary: "List catalog teams",
|
||||
request: { query: catalogTeamListQuerySchema },
|
||||
responses: { 200: r.ok(), 400: r.badRequest, 401: r.unauthorized },
|
||||
});
|
||||
|
||||
registry.registerPath({
|
||||
method: "get",
|
||||
path: "/api/teams/catalog/{catalogId}/files",
|
||||
tags: ["team-catalog"],
|
||||
summary: "Read a catalog team file",
|
||||
request: {
|
||||
params: z.object({ catalogId: z.string() }),
|
||||
query: z.object({
|
||||
ref: z.string().optional(),
|
||||
path: z.string().optional(),
|
||||
}),
|
||||
},
|
||||
responses: { 200: r.ok(), 400: r.badRequest, 401: r.unauthorized, 404: r.notFound },
|
||||
});
|
||||
|
||||
registry.registerPath({
|
||||
method: "get",
|
||||
path: "/api/teams/catalog/{catalogId}",
|
||||
tags: ["team-catalog"],
|
||||
summary: "Get a catalog team",
|
||||
request: {
|
||||
params: z.object({ catalogId: z.string() }),
|
||||
query: z.object({ ref: z.string().optional() }),
|
||||
},
|
||||
responses: { 200: r.ok(), 400: r.badRequest, 401: r.unauthorized, 404: r.notFound },
|
||||
});
|
||||
|
||||
registry.registerPath({
|
||||
method: "get",
|
||||
path: "/api/companies/{companyId}/teams/catalog/installed",
|
||||
tags: ["team-catalog"],
|
||||
summary: "List installed catalog teams for a company",
|
||||
request: { params: z.object({ companyId: z.string() }) },
|
||||
responses: { 200: r.ok(), 401: r.unauthorized, 403: r.forbidden },
|
||||
});
|
||||
|
||||
registry.registerPath({
|
||||
method: "post",
|
||||
path: "/api/companies/{companyId}/teams/catalog/{catalogId}/preview",
|
||||
tags: ["team-catalog"],
|
||||
summary: "Preview catalog team installation",
|
||||
request: {
|
||||
params: z.object({ companyId: z.string(), catalogId: z.string() }),
|
||||
query: z.object({ ref: z.string().optional() }),
|
||||
body: jsonBody(catalogTeamPreviewSchema),
|
||||
},
|
||||
responses: { 200: r.ok(), 400: r.badRequest, 401: r.unauthorized, 403: r.forbidden, 404: r.notFound },
|
||||
});
|
||||
|
||||
registry.registerPath({
|
||||
method: "post",
|
||||
path: "/api/companies/{companyId}/teams/catalog/{catalogId}/install",
|
||||
tags: ["team-catalog"],
|
||||
summary: "Install a catalog team",
|
||||
request: {
|
||||
params: z.object({ companyId: z.string(), catalogId: z.string() }),
|
||||
query: z.object({ ref: z.string().optional() }),
|
||||
body: jsonBody(catalogTeamInstallSchema),
|
||||
},
|
||||
responses: { 201: r.ok(), 400: r.badRequest, 401: r.unauthorized, 403: r.forbidden, 404: r.notFound },
|
||||
});
|
||||
|
||||
// ─── Agents ──────────────────────────────────────────────────────────────────
|
||||
|
||||
registry.registerPath({
|
||||
|
||||
Reference in new issue
Block a user