@baldaworks/balda-linux-x64 0.4.1 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +64 -17
  2. package/bin/balda +2 -2
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -50,6 +50,24 @@ password once. Save it securely, then start:
50
50
  balda start
51
51
  ```
52
52
 
53
+ The primary administrator's display name is also `superuser`. In Backoffice,
54
+ use **Account → Change password** to replace your own password. Administrators
55
+ manage each user's chat bindings under **Access**: a user may have Telegram,
56
+ Slack Agent (`slackagent`), Zulip, and Mattermost principals where those
57
+ integrations are configured. Each channel has its own invitation panel: generate
58
+ an invitation for the selected user and send it from their provider account.
59
+ The value appears once; Refresh bindings shows status and confirmed identities.
60
+ Use explicit Replace invitation or Cancel invitation for a pending value. Removing one binding revokes bot access for that principal without
61
+ removing the user's other bindings or browser account.
62
+
63
+ **Account** shows your active browser sessions with the current one first.
64
+ Use **Older active sessions** to reach further sessions, or **End session**
65
+ to revoke one; ending the current session requires confirmation. **Access**
66
+ lets administrators find users and manage their sessions and bindings. **Audit**
67
+ shows recent security events with filters. The **Overview** integration cards
68
+ show configuration, not a live health check. See the
69
+ [Backoffice reference](docs/reference/backoffice.md) for session and security details.
70
+
53
71
  `balda init` creates `.config/balda/config.yaml`, initializes
54
72
  `.config/balda/state.db` by default, detects available provider CLIs, and prints
55
73
  the next step for your selected chat provider.
@@ -58,37 +76,62 @@ SQLite is the default state database. To select PostgreSQL, configure
58
76
  `balda.database.type: postgres`; launch remains `balda start`.
59
77
  See [database configuration and operations](docs/reference/database.md).
60
78
 
61
- `balda start` applies embedded schema migrations to the selected database,
79
+ `balda start` applies embedded schema and data migrations to the selected database,
62
80
  checks canonical users and administrator bootstrap, then starts the bot,
63
- Backoffice, and enabled integrations in one process. Before the first start,
64
- the administrator is already bootstrapped on a fresh database. For an existing installation,
65
- stop Balda, back up the database, and convert legacy owner/collaborator records
66
- with an exclusive credentials-output file. See the
81
+ Backoffice, and enabled integrations in one process. On a fresh database,
82
+ `balda init` has already bootstrapped the administrator. For an existing
83
+ installation, stop Balda, back up the database, and deploy the new binary.
84
+ Goose automatically converts owner/collaborator records when Balda opens the
85
+ database, preserving their roles and bot bindings. See the
67
86
  [Backoffice startup and security contract](docs/reference/backoffice.md).
68
87
 
69
88
  ```bash
70
- # Existing installation with legacy users, while Balda is stopped and after a database backup:
71
- balda backoffice migrate-users --credentials-output /run/secrets/balda-migrated-users.txt
72
- balda backoffice bootstrap-admin --reset
89
+ # Existing installation with owner/collaborator records, after stopping Balda and backing up:
90
+ balda backoffice bootstrap-admin
73
91
  balda start
74
92
  ```
75
93
 
76
- The existing-install `--reset` step generates and prints a new password for the
77
- migrated primary user. It is needed when that user
78
- has a temporary credential; it revokes that user's browser refresh-token
79
- families. Never pass passwords or generated migration credentials as command
80
- arguments. Distribute the plaintext migration manifest out of band and
81
- securely remove it after verified delivery.
94
+ Conversion does not generate passwords. The converted primary user is named
95
+ `superuser`; `bootstrap-admin` generates and prints its first browser password
96
+ once. Already-converted users retain their credentials and browser sessions.
97
+ If the administrator already has a usable credential, start directly; replacing
98
+ that password requires `bootstrap-admin --reset` and revokes its browser session
99
+ families. Never pass passwords as command arguments.
100
+
101
+ Browser refresh tokens default to 30 days (`720h`), renewed after every successful
102
+ refresh. Existing explicit `12h` config or environment overrides must be changed
103
+ to `720h` to use the monthly window. Expired sessions require sign-in; refresh
104
+ does not renew passkey verification freshness. See the
105
+ [browser session contract](docs/reference/backoffice.md#browser-sessions-and-refresh-rotation).
106
+
107
+ Administrator passkey 2FA is optional and off by default. Enable it in Account
108
+ using the current password and a verified passkey at an HTTPS origin or localhost.
109
+ Enrolled accounts require their passkey at sign-in and for sensitive actions;
110
+ password resets preserve it. If a key is lost, an authorized host administrator
111
+ can run `balda backoffice recover-2fa --username superuser --confirm`, which
112
+ revokes browser sessions while retaining the password and bot bindings. See the
113
+ [2FA and recovery contract](docs/reference/backoffice.md#optional-administrator-passkey-2fa).
82
114
 
83
115
  ## First run
84
116
 
85
- For Telegram, authenticate the owner with the command printed by `balda init`:
117
+ For Telegram, sign in to Backoffice, select the existing user in Access and use
118
+ its Telegram invitation link, or send the generated payload:
119
+
120
+ ```text
121
+ /start bind_<opaque_token>
122
+ ```
123
+
124
+ The exact payload also works as a direct message. It connects the verified sender
125
+ to that selected user, preserving their role. Invitations expire after 24 hours
126
+ and can be used once; refresh the user's bindings in Backoffice to confirm.
127
+
128
+ The existing owner bootstrap command printed by `balda init` remains supported:
86
129
 
87
130
  ```text
88
131
  /start owner=<owner_token>
89
132
  ```
90
133
 
91
- Then send a normal direct message to the bot, or open an isolated topic:
134
+ After connecting the account, send a normal direct message to the bot, or open an isolated topic:
92
135
 
93
136
  ```text
94
137
  /topic release
@@ -219,7 +262,11 @@ ENTRYPOINT ["balda"]
219
262
  Balda provides onboarding, session control, GoalKeeper, locator, usage, skill,
220
263
  user, and plugin commands. Telegram and Zulip use `/skill`, `/locator`, and
221
264
  `/reset`; Slack exposes the conversation-scoped forms `/balda skill`,
222
- `/balda locator`, and `/balda reset`.
265
+ `/balda locator`, and `/balda reset`. For Backoffice account binding, Zulip accepts `/start bind_<token>` or the exact
266
+ `bind_<token>` DM generated for its configured bot. In Slack, send the
267
+ generated `bind_<token>` in the configured bot’s DM or use `/balda start bind_<token>`.
268
+ Mattermost accepts the exact DM payload (including `/msg @<bot_username> bind_<token>`);
269
+ `/balda start bind_<token>` is available when its slash receiver is enabled.
223
270
 
224
271
  Slack formats the response for scanning and copying:
225
272
 
package/bin/balda CHANGED
@@ -1,4 +1,4 @@
1
1
  [diffend] Oversized file quarantined before diffing.
2
2
  name: package/bin/balda
3
- size: 62468258 bytes
4
- sha256: 8a1dad5ba1be6cb1cc76bb2cca9cc12b874a4290b884a4bf6171d1b9503f635a
3
+ size: 65335458 bytes
4
+ sha256: d40f49068f45fb3c7610905d5d339d625a11d90df12db248b70763546711a420
package/package.json CHANGED
@@ -17,5 +17,5 @@
17
17
  "type": "git",
18
18
  "url": "git+https://github.com/baldaworks/balda.git"
19
19
  },
20
- "version": "0.4.1"
20
+ "version": "0.5.0"
21
21
  }