Skip to content

Paused friend chat points the owner to the Bot Social /ui console, which a FlyBot owner cannot sign in to; add in-FlyBot Extend (in-chat approval) and fix the 403 wording #404

Closed

Description

@Birfy

Found by product self-test 2026-10-19 (focus F), ~08:20–08:30 Asia/Shanghai.
Follow-up to #72 (closed). This needs a companion change in Birfy/bot-social (cross-linked below).

Summary

When Bot Social pauses a friend chat (turn budget reached, loop suspected), FlyBot tells the owner to "extend the conversation in the Bot Social console at https://…/ui". A FlyBot owner cannot sign in to that console. FlyBot onboarding throws away the generated web password, and the connector token FlyBot keeps is refused by every route the console uses. MCP has no extend tool either. So the only working recovery is "remove and re-add this friend", and the message sends people to a dead end.

Environment

Exact repro

  1. Fresh FlyBot install → it auto-registers through POST /v1/onboard/flybot (plugins/social/src/social.js onboard() / onboardHome(), ~L228–L241). The server returns a generated owner username (live: selfa0820413719) and a generated_password "for /ui". FlyBot stores only the connector token in flybot-social.json. The UI never shows the username or the password.
  2. Get a friend chat paused (exhaust the turn budget, e.g. 20/20 turns), then send another message from FlyBot.
  3. FlyBot shows (social.js mapSendError, ~L1217–L1225): "Bot Social paused this conversation (…). Resending cannot help: approve pending messages or extend the conversation in the Bot Social console at https://…/ui, or remove and re-add this friend to start a new one." The remote-chat path (core/src/host/remote-chat.js L33, mirrored in patches/ds-bot/files/src/host/remote-chat.js) says "Not sent: this chat is paused. Open the Bot Social console to resume it."
  4. Open https://47-80-69-220.sslip.io/ui.
    • Log in: the owner has no password (step 1).
    • Token tab with the only credential FlyBot has (the connector token, otk_…): GET /v1/me → 403 connector_token_rest_forbidden "connector tokens only work at /mcp; log in for the REST API". The page silently returns to the login form (filed separately in bot-social).
  5. MCP /mcp with the same token: 46 tools, no extend_conversation (only close_conversation). change_password needs the current password. REST POST /v1/conversations/:id/extend needs a login token.

What you see

  • FlyBot's paused-chat error points to a website and gives no way in. Following it leads to a login card the owner has no credentials for.
  • The server's 403 text says connector tokens "only work at /mcp". The same token does work on face rooms, presence, /v1/remote-bots, /v1/bots/{id}/grants, /v1/connector/webhook and PATCH /v1/bots/{id}/profile. bot-social README L62 lists those FlyBot REST routes, while the routes table (~L341, /v1/connector-tokens row) says "usable only at /mcp". The two contradict each other.

Expected behavior

  • A FlyBot owner can recover a paused chat inside FlyBot, approved in chat like any other gated action: an Extend action on the paused message or notice, which raises the normal approval card. The owner never has to visit a separate website with credentials they never saw.
  • FlyBot's error text names only steps the owner can actually take ("Extend this chat" / "remove and re-add this friend"). No pointer to "/ui console" unless the owner can really sign in there.
  • Bot Social's 403 message and README describe exactly what connector tokens can do.

Suggested change scope

Birfy/bot-social (companion; the FlyBot part depends on it, so file and land it first or together):

  • src/owner-mcp.ts: add MCP tool extend_conversation {conversation_id, extra_turns?}, gated like decide_approval (owner-confirmed). Alternatively, allow POST /v1/conversations/:id/extend in src/server.ts for connector tokens issued to a trusted host (the FlyBot onboarding token, like attest_typed_by_owner).
  • src/server.ts L31: reword connector_token_rest_forbidden to e.g. "This route needs an owner login. Connector tokens work at /mcp and the FlyBot routes (face rooms, presence, grants, remote Bots, webhook, Bot profile)."
  • README.md L62 vs the routes-table /v1/connector-tokens row (~L341): make them say the same thing.
  • Tests for the new tool or route: extend works for the FlyBot token, is refused for a plain connector token and for a Bot token, and adds turns.

ThinkFlowLab/FlyBot:

  • plugins/social/src/social.js: in mapSendError (isPaused branch), return a structured error/code (e.g. paused: true, conversationId) instead of only text. Drop the "/ui console" pointer.
  • Client and host: render an Extend action on the paused notice. It calls the new bot-social extend through the existing approval-card flow (no auto-execute) and then retries the held message.
  • core/src/host/remote-chat.js (+ patches/ds-bot/files/src/host/remote-chat.js): same wording change for L33, L58, L60 ("open the Bot Social console").
  • docs/subsystems/social.md §3 (L47): update the "names the Bot Social console" statement.
  • Optional, needs a decision: FlyBot Settings → Bot Social "Set a password for the Bot Social website" (shows the generated username and lets the owner set a password). Not required if Extend is handled in FlyBot.

Acceptance criteria

  • On a paused friend chat, FlyBot shows an Extend action. Clicking it shows an approval card. Approving extends the conversation on Bot Social (turn max increases), and the next send succeeds without re-adding the friend.
  • Declining the card changes nothing on the server.
  • No FlyBot error text tells the owner to use the Bot Social console/website (grep for "Bot Social console" in plugins/social and core/src/host returns nothing user-facing), unless the optional password feature ships.
  • Bot Social: the connector_token_rest_forbidden message no longer says "only work at /mcp"; README L62 and the routes table agree.
  • Tests: social.test.js covers the paused → Extend → approved → sent path and the declined path; bot-social tests cover extend permissions.
  • English only; no CHANGELOG.md or version changes in the fix PR (changelog.d fragment as usual).

Related

Activity

  1. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    Started the FlyBot-only part in #413 (T3, copy only): no error text points to the Bot Social console / /ui any more; a paused chat names only approve-in-chat or remove-and-re-add. The in-chat Extend action is blocked on the Bot Social companion (owner-confirmed extend_conversation MCP tool, 403 wording, README L62 vs routes table in Birfy/bot-social), which has no issue/PR there yet.

  2. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    Owner decision (2026-10-19): Go with the recommended design. Bot Social gets an owner-confirmed extend_conversation MCP tool (the owner confirmation code is never supplied by an assistant; no REST extend path for connector tokens, which stay /mcp-only). FlyBot then surfaces it as an in-chat approval. The FlyBot-side 403 wording and the README are fixed separately (#413 already covers the wording part). Bot Social companion issue: Birfy/bot-social#22 . Any production deploy still needs the owner's explicit yes.

  3. added
    bugSomething isn't working
    area:socialFriends, invites, grants, Bot Social
    area:securityAuth, grants, approvals, secrets
    on Oct 19, 2026
  4. added
    self-testFiled by the product self-test routine (issues only)
    needs-humanThe agent loop stopped; a person must decide (reason in the last comment)
    on Oct 19, 2026
  5. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    Triage on main 7b9e90b, 2026-10-19 ~12:10 Asia/Shanghai: needs-human. The FlyBot wording part landed in #413. The in-FlyBot Extend action waits for Birfy/bot-social#22 (owner-confirmed extend_conversation MCP tool), which is still open, and then for the owner's yes to deploy it to production Bot Social. It becomes agent-ready once that tool is live.

  6. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    Triage on main a7f51e8, 2026-10-19 ~14:15 Asia/Shanghai: design conflicts resolved, spec clear; ready to develop. Checked: Birfy/bot-social#22 is done (#25) and deployed to production at 13:40 Asia/Shanghai (master 7fb211c): owner MCP tool extend_conversation {conversation_id, extra_turns?} (1-20, default 4), two-step like decide_approval (first call returns a summary and a one-time code, the second call with that code extends). The Owner decision above (in-FlyBot Extend as an in-chat approval; no REST path for connector tokens) and #349 (approve only by an explicit button). Scope: a structured paused error from mapSendError, an Extend action on the paused notice that raises the normal approval card; only the owner's Approve click lets the FlyBot host make the confirming second call; Decline does nothing on the server.

  7. added
    agent-readyMaintainer-approved spec: an agent may take it. Only maintainers set this; never in a template
    agent-workingAn agent has claimed this issue (the claim comment names the branch)
    and removed
    needs-humanThe agent loop stopped; a person must decide (reason in the last comment)
    on Oct 19, 2026
  8. self-assigned this
    on Oct 19, 2026
  9. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    Claimed by the maintenance routine (2026-10-19 16:40 Asia/Shanghai). Branch: Birfy:fix/404-in-chat-extend off main 31c4c2a. Scope per the 06:07 UTC triage: structured paused error from mapSendError, an Extend action on the paused notice that raises the normal approval card; only the owner's Approve click makes the confirming extend_conversation call; Decline does nothing on the server.

  10. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    PR #429. Minor details decided by the routine (owner-delegated): one Extend adds 4 turns (Bot Social's default); the card uses Approve / Reject like every other approval card (Reject calls nothing on the server); after Extend the owner sends the message again (no automatic resend of the refused line); the paused conversation is found with list_conversations because the conversation_paused error does not name it.

  11. added a commit that references this issue on Oct 19, 2026
    0852b3f
  12. Birfy commented on Oct 19, 2026

    @Birfy
    CollaboratorAuthor

    Owner decision 2026-10-19 18:05 (Asia/Shanghai): remove the conversation turn limit entirely. Friend chats should not run out of turns or need Extend. Loop detection stays only where it does not block an owner's own typed messages. That supersedes the in-chat Extend added here. Bug and plan: #439. Server side: Birfy/bot-social#28.

  13. removed
    agent-workingAn agent has claimed this issue (the claim comment names the branch)
    agent-readyMaintainer-approved spec: an agent may take it. Only maintainers set this; never in a template
    on Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:securityAuth, grants, approvals, secretsarea:socialFriends, invites, grants, Bot SocialbugSomething isn't workingself-testFiled by the product self-test routine (issues only)

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions