Repository navigation
Closed
Labels
Description
Build: v1.0.5-rc2 (af465288a), enterprise edition, local, PostgreSQL. Matrix row: B2. Same kind of dead end as #4501, on a different path.
What happens
- A person is seated as the agent's primary, and the agent is not shared with them. (The API allows this state, as it does for an approver.)
- The agent raises a
credentialask. A credential ask can only be addressed toprimary. - The receipt says
201,to_role: primary,resolved: true,expires_at: null. - The seated person does not see the ask in their Workspace Inbox.
GET …/asks/{id}/contextandPOST …/asks/{id}/credentialanswer404 not_foundfor them. - Nobody else can fill it either:
- Operations:
POST /api/operator-queue/{id}/respondas the owner (an admin) answers422 credential_answer_via_field("answered in the person's Workspace through the secret field"). - The owner's own Workspace does not list it, and
POST …/asks/{id}/credentialas the owner answers404.
- Operations:
So the ask waits on one person who cannot see it, the only door that can end it as answered is closed to everyone else, and it never expires. Only a cancel ends it. The agent was told resolved: true.
Why
- A credential ask has one reader by design: it is answered only through the Workspace secret field (
ask_service.answerrefuses anything else withCredentialAnswerRefused). - That field's door is
client_portal/asks/service.py::_owned_ask: the addressee and on the agent's roster. - The raise resolves
primarythroughrole_addressing.resolve_addresseewith no reach check, so a seated primary who cannot open the agent becomes the single addressee. - fix(asks): an ask to the approver reaches only approvers who can open the agent, and is refused by name when none can (#4501) #4506 added the reach check for
to: approveronly. Ondevtheprimaryarm is unchanged (read in the code, not run there).
Expected
One of:
- refuse the raise by name when the single addressee cannot open the agent, as
role:<id>and (since fix(asks): an ask to the approver reaches only approvers who can open the agent, and is refused by name when none can (#4501) #4506)approverdo; or - let the owner stand in, as when nobody fills
primary.
Repro (local, rc2)
POST /api/enterprise/assignments/agents/<agent>{"user_id": <id>, "kind": "primary"}for a person the agent is not shared with → 201.- With the agent's key:
POST /api/agents/<agent>/operator-queue{"request_id": "x", "title": "x", "type": "credential", "to": "primary", "context": {"credential_name": "SOME_TOKEN"}}→ 201,resolved: true. - As the seated person:
GET /api/enterprise/client-portal/asksdoes not list it;GET …/asks/<id>/context→ 404;POST …/asks/<id>/credential→ 404. - As the owner:
POST /api/operator-queue/<id>/respond→ 422credential_answer_via_field;POST …/client-portal/asks/<id>/credential→ 404. - Control: share the agent with the person → the ask appears in their list and its context reads 200.
Also seen
- The raise attaches the ask to a Main chat for the person and the agent (
context.workspace_session_id), a chat the person cannot open.
Severity
Suggested P2, like #4501: an agent can wait forever on a credential nobody can give it, with a receipt that says a person will see it. The way out today is to share the agent with the primary, or cancel the ask.
Not the same as
- credential ask: the addressee is frozen at raise time, not re-resolved as the agent's primary at answer time #4189 (the addressee is not re-resolved at answer time after a reassignment).
- bug(asks): an ask to: approver is filed for a seated approver who cannot open the agent, and then nobody can answer it #4501 (the approver fence; fixed by fix(asks): an ask to the approver reaches only approvers who can open the agent, and is refused by name when none can (#4501) #4506).
Activity
webmixgamer commentedon Nov 14, 2026
/claim
github-actions commentedon Nov 14, 2026
Claimed by @webmixgamer. Label
status-in-progressadded.Next steps:
feature/4579-<short-slug>Fixes #4579fix(asks): an admin's re-address by rule keeps a credential ask with …
fix(asks): a credential ask goes to a person who can open its field —…
fix(asks): a credential ask is never recorded for a reader who cannot…