Feature: Bot Account Type #53
Labels
No labels
area:api
area:core
area:docs
area:infra
area:ux
dependencies
documentation
duplicate
good first issue
help wanted
invalid
question
rust
status:complete
status:partial
status:planned
type:bug
type:design
type:feature
type:infra
type:refactor
type:research
type:ux
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
icub3d/decentcom#53
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Migrated from GitHub issue icub3d/decentcom#75
Original Author: @icub3d
Original Date: 2026-04-17T21:41:45Z
Feature: Bot Account Type
Overview
Introduce a first-class bot account type so servers can distinguish automated participants from humans, apply scoped permissions, and let first-party and third-party bots integrate cleanly using the same identity model as humans.
Background
Per #68, bots are the right tool for moderation, onboarding, and utility tasks that don't belong on the auth/permissions critical path. Rather than introduce a parallel auth system (long-lived tokens), bots use the same Ed25519 challenge-response flow as humans — the only differences are an
is_botflag bound to the signed challenge payload and a manual admin approval gate before the bot can act on the server.Requirements
is_bot: trueclaim so the server can distinguish bot authentications from human ones.Design
Auth Flow
POST /api/v1/auth/challengewith{ pubkey, is_bot: true }.is_botclaim (e.g. signs overnonce || is_bot) so the claim cannot be stripped or swapped.bot_approvals, the server records it as pending and either rejects the session or issues a read-only session (TBD in design). Admin sees the pending bot in the admin UI.Data Model Changes
userstable: addis_bot INTEGER NOT NULL DEFAULT 0(set the first time a pubkey authenticates with theis_botclaim).bot_approvalstable:(pubkey TEXT PRIMARY KEY, approved_by TEXT REFERENCES users(id), approved_at TEXT, revoked_at TEXT, note TEXT).API / Interface Changes
POST /api/v1/auth/challengeaccepts an optionalis_botflag in the request body; the flag is bound into the signed payload.GET /api/v1/admin/bots/pending— list bots awaiting approval.POST /api/v1/admin/bots/{pubkey}/approve— approve a bot.POST /api/v1/admin/bots/{pubkey}/revoke— revoke a previously approved bot.GET /api/v1/membersresponse includesis_botand approval state.Component Changes
client/src/components/members/MemberList.tsx— render bot badge (with optional "pending" state for unapproved bots if they're visible).Task List
Phase 1: Server
is_botcolumn andbot_approvalstable.is_botclaim.is_botand approval state.Phase 2: Client UI
Test List
is_botclaim is bound to the signed payload and auth fails if it is tampered with.Open Questions
is_botclaim be self-asserted (current design) or issued by someone? (Recommendation: self-asserted. The approval gate, not the claim, is what grants trust.)Dependencies