{"record":{"id":"27694f5f76dbc249","repo":"paperclipai/paperclip","slug":"catalog-skill-reference-is-required","errorCode":null,"errorMessage":"Catalog skill reference is required.","messagePattern":"Catalog skill reference is required\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/src/commands/client/skills.ts","lineNumber":596,"sourceCode":"  return (await ctx.api.get<CompanySkillListItem[]>(`/api/companies/${ctx.companyId}/skills`)) ?? [];\n}\n\nasync function listCatalogSkills(\n  ctx: ResolvedClientContext,\n  opts: CatalogBrowseOptions,\n): Promise<CatalogSkill[]> {\n  const params = new URLSearchParams();\n  appendQueryParam(params, \"kind\", opts.kind);\n  appendQueryParam(params, \"category\", opts.category);\n  appendQueryParam(params, \"q\", opts.query);\n  const query = params.toString();\n  return (await ctx.api.get<CatalogSkill[]>(`/api/skills/catalog${query ? `?${query}` : \"\"}`)) ?? [];\n}\n\nasync function getCatalogSkill(ctx: ResolvedClientContext, catalogRef: string): Promise<CatalogSkill> {\n  const ref = catalogRef.trim();\n  if (!ref) {\n    throw new Error(\"Catalog skill reference is required.\");\n  }\n  const detail = await ctx.api.get<CatalogSkill>(`/api/skills/catalog/ref?ref=${encodeURIComponent(ref)}`);\n  if (!detail) {\n    throw new Error(`Catalog skill not found: ${catalogRef}`);\n  }\n  return detail;\n}\n\nexport function resolveCompanySkillReference(\n  skills: CompanySkillReferenceTarget[],\n  reference: string,\n): CompanySkillReferenceTarget {\n  const trimmed = reference.trim();\n  if (!trimmed) {\n    throw new Error(\"Skill reference is required.\");\n  }\n\n  const byId = skills.find((skill) => skill.id === trimmed);","sourceCodeStart":578,"sourceCodeEnd":614,"githubUrl":"https://github.com/paperclipai/paperclip/blob/120ae5428fa29bee300bcf806491cd4d965fbb7c/cli/src/commands/client/skills.ts#L578-L614","documentation":"getCatalogSkill trimmed the catalog reference argument to an empty string, so there is no catalog skill id/key/slug to look up.","triggerScenarios":"Thrown at cli/src/commands/client/skills.ts:596 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Provide a catalog skill reference (slug or key)."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"120ae5428fa29bee300bcf806491cd4d965fbb7c","analyzedAt":"2026-08-18T22:49:45.177Z","contentChangedAt":"2026-08-18T22:49:45.177Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}