Merge remote-tracking branch 'upstream/master' into dev

# Conflicts:
#	packages/shared/src/validators/company-skill.ts
#	packages/shared/src/validators/index.ts
#	server/src/__tests__/company-skills-routes.test.ts
#	server/src/routes/company-skills.ts
#	server/src/services/company-skills.ts
#	ui/src/pages/CompanySkills.tsx
This commit is contained in:
2026-05-31 08:02:16 -04:00
216 changed files with 81380 additions and 1492 deletions
+3
View File
@@ -384,6 +384,9 @@ export const accessApi = {
claimBoard: (token: string, code: string) =>
api.post<{ claimed: true; userId: string }>(`/board-claim/${token}/claim`, { code }),
claimBootstrapAdmin: () =>
api.post<{ claimed: true; userId: string }>("/bootstrap/claim", {}),
getCliAuthChallenge: (id: string, token: string) =>
api.get<CliAuthChallengeStatus>(`/cli-auth/challenges/${id}?token=${encodeURIComponent(token)}`),
+30
View File
@@ -1,9 +1,14 @@
import type {
CatalogSkill,
CatalogSkillFileDetail,
CatalogSkillKind,
CompanySkill,
CompanySkillCreateRequest,
CompanySkillDetail,
CompanySkillFileDetail,
CompanySkillImportResult,
CompanySkillInstallCatalogRequest,
CompanySkillInstallCatalogResult,
CompanySkillListItem,
CompanySkillProjectScanRequest,
CompanySkillProjectScanResult,
@@ -11,6 +16,12 @@ import type {
} from "@paperclipai/shared";
import { api } from "./client";
export interface CatalogListQuery {
kind?: CatalogSkillKind;
category?: string;
q?: string;
}
export const companySkillsApi = {
list: (companyId: string) =>
api.get<CompanySkillListItem[]>(`/companies/${encodeURIComponent(companyId)}/skills`),
@@ -60,4 +71,23 @@ export const companySkillsApi = {
api.delete<CompanySkill>(
`/companies/${encodeURIComponent(companyId)}/skills/${encodeURIComponent(skillId)}`,
),
catalogList: (query: CatalogListQuery = {}) => {
const params = new URLSearchParams();
if (query.kind) params.set("kind", query.kind);
if (query.category) params.set("category", query.category);
if (query.q) params.set("q", query.q);
const search = params.toString();
return api.get<CatalogSkill[]>(`/skills/catalog${search ? `?${search}` : ""}`);
},
catalogDetail: (catalogRef: string) =>
api.get<CatalogSkill>(`/skills/catalog/${encodeURIComponent(catalogRef)}`),
catalogFile: (catalogRef: string, relativePath: string = "SKILL.md") =>
api.get<CatalogSkillFileDetail>(
`/skills/catalog/${encodeURIComponent(catalogRef)}/files?path=${encodeURIComponent(relativePath)}`,
),
installCatalog: (companyId: string, payload: CompanySkillInstallCatalogRequest) =>
api.post<CompanySkillInstallCatalogResult>(
`/companies/${encodeURIComponent(companyId)}/skills/install-catalog`,
payload,
),
};
+59
View File
@@ -0,0 +1,59 @@
import type {
CreateDocumentAnnotationCommentRequest,
CreateDocumentAnnotationThreadRequest,
DocumentAnnotationComment,
DocumentAnnotationThread,
DocumentAnnotationThreadStatus,
DocumentAnnotationThreadWithComments,
UpdateDocumentAnnotationThreadRequest,
} from "@paperclipai/shared";
import { api } from "./client";
export type DocumentAnnotationListFilter = "open" | "resolved" | "all";
export const documentAnnotationsApi = {
list: (
issueId: string,
key: string,
options: { status?: DocumentAnnotationListFilter; includeComments?: boolean } = {},
) => {
const params = new URLSearchParams();
if (options.status) params.set("status", options.status);
if (options.includeComments) params.set("includeComments", "true");
const qs = params.toString();
return api.get<DocumentAnnotationThreadWithComments[]>(
`/issues/${issueId}/documents/${encodeURIComponent(key)}/annotations${qs ? `?${qs}` : ""}`,
);
},
get: (issueId: string, key: string, threadId: string) =>
api.get<DocumentAnnotationThreadWithComments>(
`/issues/${issueId}/documents/${encodeURIComponent(key)}/annotations/${threadId}`,
),
create: (issueId: string, key: string, data: CreateDocumentAnnotationThreadRequest) =>
api.post<DocumentAnnotationThreadWithComments>(
`/issues/${issueId}/documents/${encodeURIComponent(key)}/annotations`,
data,
),
addComment: (
issueId: string,
key: string,
threadId: string,
data: CreateDocumentAnnotationCommentRequest,
) =>
api.post<DocumentAnnotationComment>(
`/issues/${issueId}/documents/${encodeURIComponent(key)}/annotations/${threadId}/comments`,
data,
),
updateStatus: (
issueId: string,
key: string,
threadId: string,
status: DocumentAnnotationThreadStatus,
) => {
const payload: UpdateDocumentAnnotationThreadRequest = { status };
return api.patch<DocumentAnnotationThread>(
`/issues/${issueId}/documents/${encodeURIComponent(key)}/annotations/${threadId}`,
payload,
);
},
};
+3
View File
@@ -1,4 +1,5 @@
import type {
AcceptedPlanDecompositionSummary,
AskUserQuestionsAnswer,
Approval,
CreateIssueTreeHold,
@@ -201,6 +202,8 @@ export const issuesApi = {
},
listInteractions: (id: string) =>
api.get<IssueThreadInteraction[]>(`/issues/${id}/interactions`),
listAcceptedPlanDecompositions: (id: string) =>
api.get<AcceptedPlanDecompositionSummary[]>(`/issues/${id}/accepted-plan-decompositions`),
createInteraction: (id: string, data: Record<string, unknown>) =>
api.post<IssueThreadInteraction>(`/issues/${id}/interactions`, data),
acceptInteraction: (
+5 -4
View File
@@ -132,13 +132,14 @@ export interface PluginDashboardData {
checkedAt: string;
}
export interface AvailablePluginExample {
export interface AvailableBundledPlugin {
packageName: string;
pluginKey: string;
displayName: string;
description: string;
localPath: string;
tag: "example" | "first-party";
experimental: boolean;
}
export interface PluginLocalFolderProblem {
@@ -215,10 +216,10 @@ export const pluginsApi = {
api.get<PluginRecord[]>(`/plugins${status ? `?status=${status}` : ""}`),
/**
* List bundled example plugins available from the current repo checkout.
* List bundled plugin packages available from the current repo checkout.
*/
listExamples: () =>
api.get<AvailablePluginExample[]>("/plugins/examples"),
listBundled: () =>
api.get<AvailableBundledPlugin[]>("/plugins/examples"),
/**
* Fetch a single plugin record by its UUID or plugin key.