Repository navigation
Face-to-face: Auto-send setting over MCP, friend Bot avatars - #109
Conversation
Connector tokens cannot GET/PATCH /v1/me (403 connector_token_rest_forbidden). Read auto_approve_face_rooms via MCP whoami and write it with set_auto_approve in the same owner click (confirm_code). Face-room join/list/messages stay on the REST routes that accept the connector token. A friend's Bot in the room member list, message headers, waiting grid and Friends' Bots uses its chat look or a stable handle-seeded avatar. Bot Social does not store profile images; member avatar/color is passed through when present. Local verify passed (patches check, arch-docs, bundle --check, core/social/tree tests). Co-authored-by: Danyang Chen <birfychen@gmail.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f14e8a4838
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (!config.server || !token) throw new Error('Bot Social is not connected') | ||
| try { | ||
| const result = await confirmedCall('set_auto_approve', { auto_approve_face_rooms: Boolean(on) }) | ||
| const next = viewMe(result)?.autoApproveFaceRooms === true |
There was a problem hiding this comment.
Reject repeated confirmation challenges
When Bot Social returns confirmation_required again after the confirm_code retry (for example because the code expired or was rejected), confirmedCall returns that second challenge and this line maps its missing flag to false as though the write succeeded. An attempted disable can therefore make the UI report Auto-send off while the server remains on and continues sending room messages without approval; validate the retried result before updating the cache, as the removed REST implementation did.
Useful? React with 👍 / 👎.
| ...(m.color ? { color: m.color } : {}), | ||
| ...(m.avatar ? { avatar: m.avatar } : {}), |
There was a problem hiding this comment.
Declare the new face member look fields
When a TypeScript plugin supplies the newly supported face-member look, the public FlyBotService.rooms.upsertFace declaration still types members without color or avatar (core/types/flybot.d.ts:248-256). Object literals containing these fields are therefore rejected even though this code now consumes them (and rooms.list() can return them), so update the exported member and participant types with the runtime contract.
Useful? React with 👍 / 👎.
Fixes two bugs seen in a Face-to-face room.
Tests added; see commit for details.