{"record":{"id":"5652d541ddc8f8eb","repo":"paperclipai/paperclip","slug":"profile-ctx-profilename-is-persona-ctx-prof-5652d5","errorCode":null,"errorMessage":"Profile '${ctx.profileName}' is persona=${ctx.profile.persona}; use an agent prompt command or a board profile.","messagePattern":"Profile '(.+?)' is persona=(.+?); use an agent prompt command or a board profile\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/src/commands/client/prompt.ts","lineNumber":147,"sourceCode":"    actor: \"agent\",\n    agent: me,\n    companyId: me.companyId,\n    prompt: body,\n    issueId: opts.issue,\n    title: opts.title,\n    wake: opts.wake !== false,\n  });\n  return result;\n}\n\nexport async function runBoardPrompt(\n  agentRef: string,\n  prompt: string,\n  opts: PromptOptions,\n): Promise<PromptResult> {\n  const ctx = resolveCommandContext(opts, { requireCompany: true });\n  if (ctx.profile.persona && ctx.profile.persona !== \"board\") {\n    throw new Error(`Profile '${ctx.profileName}' is persona=${ctx.profile.persona}; use an agent prompt command or a board profile.`);\n  }\n  const body = normalizePrompt(prompt);\n  const query = new URLSearchParams({ companyId: ctx.companyId ?? \"\" });\n  const agent = await ctx.api.get<Agent>(`${apiPath`/api/agents/${agentRef}`}?${query.toString()}`);\n  if (!agent) throw new Error(`Agent not found: ${agentRef}`);\n\n  return createOrCommentForAgent({\n    api: ctx.api,\n    actor: \"board\",\n    agent,\n    companyId: ctx.companyId ?? agent.companyId,\n    prompt: body,\n    issueId: opts.issue,\n    title: opts.title,\n    wake: opts.wake !== false,\n  });\n}\n","sourceCodeStart":129,"sourceCodeEnd":165,"githubUrl":"https://github.com/paperclipai/paperclip/blob/120ae5428fa29bee300bcf806491cd4d965fbb7c/cli/src/commands/client/prompt.ts#L129-L165","documentation":"runBoardPrompt checks the profile persona; an agent profile cannot use the board prompt path because board prompts need board-level authentication and company scope.","triggerScenarios":"Thrown at cli/src/commands/client/prompt.ts:147 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use a board-persona profile, or run the agent prompt variant of the command."],"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"}