OverviewFilesCommitsIssuesDocsReleasesPeers

hyper-orgs commits / fa36071

Add README
Quick usage, ops surface, and pointer to hyper-rooms. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
fa36071c1ce421d9580ff1990715ef044d1edbe7
by plankatron <fleeky@gmail.com> · 2026-05-02T21:04:09.000Z

Changed files (1) +45 -0

README.md +45 -0
……@@ -0,0 +1,45 @@
1# hyper-orgs
2
3P2P organization management — a `hyper-rooms` schema for orgs,
4members, resources (repos/datasets/whatever), grants, invites, and
5access requests.
6
7One Autobase per org (a Room). Members are autobase writers
8(role-aware: owner = indexer; writer = plain). Schema validates ops
9and applies them to a Hyperbee view keyed by `org:<id>`,
10`member:<orgId>:<userId>`, `grant:<orgId>:<resourceId>:<userId>`, etc.
11
12Used by `pear-git-v3` (the daemon mounts a `HyperOrgs` instance per
13identity).
14
15## Usage
16
17```js
18import { HyperOrgs } from 'hyper-orgs'
19
20const orgs = new HyperOrgs(corestore, {
21 bootstrapKey: existingOrgsKey || null
22})
23await orgs.ready()
24
25await orgs.createOrg({ id: 'acme', name: 'Acme Inc.', ownerId: alice })
26await orgs.addMember('acme', { userId: bob, role: 'writer' })
27await orgs.grant('acme', { resourceId: 'repo:foo', userId: bob, perm: 'push' })
28```
29
30## Schema
31
32See `lib/schema.js` for the full op list. Reserved names guard the
33namespace; `validateName` is the canonical name check.
34
35## Tests
36
37```bash
38npm test
39```
40
41## Related
42
43- `hyper-rooms` — the underlying Room class.
44- `pear-git-v3` — primary consumer.
45- `hyper-issues` — sibling room schema, same shape.