aboutsummaryrefslogtreecommitdiffstats
path: root/packages/meshbay-node/src/meshbay_node/ui/app.py
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-09-23 17:31:06 +0200
committerChristophe Besson <cbesson@gmail.com>2026-09-23 17:31:06 +0200
commitd30e95b2ce1ffe9dc4655855406f2784b5f7af34 (patch)
tree91d86ffd59eb3593a76139ab264e1eb5da1ae687 /packages/meshbay-node/src/meshbay_node/ui/app.py
parent339cb427f886a0177014126bb684335837eff067 (diff)
downloadmeshbay-d30e95b2ce1ffe9dc4655855406f2784b5f7af34.tar.gz
feat(node): invitation links — a code bound to no account until redeemed
New invite kind "link": member of one group, once, never operator, not spendable by an active member, capped at 20 per group, cancellable by handle. Signed ops invite_link_create / invite_cancel, loopback routes, and the known-device join path now accepts a link code. Adds the plan, docs/invite-links.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'packages/meshbay-node/src/meshbay_node/ui/app.py')
-rw-r--r--packages/meshbay-node/src/meshbay_node/ui/app.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/packages/meshbay-node/src/meshbay_node/ui/app.py b/packages/meshbay-node/src/meshbay_node/ui/app.py
index 888487c..f6b93ea 100644
--- a/packages/meshbay-node/src/meshbay_node/ui/app.py
+++ b/packages/meshbay-node/src/meshbay_node/ui/app.py
@@ -322,6 +322,14 @@ def create_ui_app(state: dict) -> FastAPI:
async def create_invite(group_id: str, username: str):
return await _op(lambda: ops.create_invite(state, group_id, username))
+ @app.post("/api/groups/{group_id}/invite-links")
+ async def create_link_invite(group_id: str):
+ return await _op(lambda: ops.create_link_invite(state, group_id))
+
+ @app.delete("/api/groups/{group_id}/invite-links/{invite_id}")
+ async def cancel_invite(group_id: str, invite_id: str):
+ return await _op(lambda: ops.cancel_invite(state, group_id, invite_id))
+
@app.get("/api/resolve")
async def resolve_user(username: str):
return await _op(lambda: ops.resolve_user(state, username))