@glyphteck/veyl 0.51.0 → 0.55.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.
- package/LICENSE +22 -0
- package/dist/account.js +515 -562
- package/dist/auth.js +16 -9
- package/dist/cli.js +674 -694
- package/dist/index.js +674 -694
- package/docs/agents.md +1 -1
- package/docs/api.md +3 -3
- package/docs/validation.md +5 -5
- package/package.json +3 -2
- package/readme.md +28 -26
package/docs/agents.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Use the JavaScript API for a long-running agent and the canonical CLI for one-off shell work. A local read-only MCP resource server can help an MCP-capable host discover the installed SDK documentation, but it cannot operate Veyl.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
The SDK is not a privileged backend. It authenticates, decrypts the vault, signs wallet operations, encrypts/signs chat actions, and maintains encrypted local cache state exactly like web and iOS. Machine credentials and passkeys are authentication capabilities, not human-or-bot classifications. Third-party agents use ordinary public profiles; only namespace-authorized Glyphteck services carry the managed bot marker.
|
|
6
6
|
|
|
7
7
|
## Setup
|
|
8
8
|
|
package/docs/api.md
CHANGED
|
@@ -206,7 +206,7 @@ await veyl.account.logoutAll();
|
|
|
206
206
|
await veyl.account.delete({ confirm: true });
|
|
207
207
|
```
|
|
208
208
|
|
|
209
|
-
- `create` makes a machine
|
|
209
|
+
- `create` makes an ordinary account authenticated by a local machine credential. Authentication does not assign a public bot label.
|
|
210
210
|
- `createPasskey({ username, termsVersion, webUrl, onUrl })` creates a normal passkey account through a browser-assisted WebAuthn flow, then installs a local machine credential for future CLI sessions.
|
|
211
211
|
- `login({ username?, credentialId?, privateKeyPem? })` authenticates a machine credential.
|
|
212
212
|
- `loginPasskey({ username?, webUrl?, onUrl? })` authenticates through the browser-assisted passkey flow.
|
|
@@ -217,7 +217,7 @@ await veyl.account.delete({ confirm: true });
|
|
|
217
217
|
- `logoutAll` revokes every product session generation, tears down this runtime locally, and stops a persistent CLI owner after its in-flight work drains.
|
|
218
218
|
- `delete({ confirm: true })` drains decryptable inbox state, marks all discoverable chats deleted, destroys the complete account/network encrypted cache scope, proves vault possession, deletes identifiable account data, removes the local profile, and stops a persistent CLI owner after its in-flight work drains.
|
|
219
219
|
|
|
220
|
-
Account summaries report identity, network, local credential/vault availability, public wallet/chat keys, auth kind, bot
|
|
220
|
+
Account summaries report identity, network, local credential/vault availability, public wallet/chat keys, auth kind, an explicit managed-bot marker when assigned by Glyphteck's owner namespace, and current signed-in/unlocked state. Private keys and vault secrets are never included in summaries.
|
|
221
221
|
|
|
222
222
|
## Vault
|
|
223
223
|
|
|
@@ -319,7 +319,7 @@ const created = await veyl.invite.link({ kind: 'chat' });
|
|
|
319
319
|
const parsed = veyl.invite.read(created.link);
|
|
320
320
|
```
|
|
321
321
|
|
|
322
|
-
`kind` may be `join`, `chat`, `send`, or `request`; send/request links may include integer `sats`. These are direct URL strings produced and parsed by `core/invite.js`.
|
|
322
|
+
`kind` may be `join`, `chat`, `send`, or `request`; send/request links may include integer `sats`. These are direct URL strings produced and parsed by `core/invite.js`. SDK does not expose camera or QR behavior.
|
|
323
323
|
|
|
324
324
|
## Wallet
|
|
325
325
|
|
package/docs/validation.md
CHANGED
|
@@ -39,7 +39,7 @@ API version 3 establishes `open()` as the public SDK composition root and remove
|
|
|
39
39
|
| Group | CLI / session | Product owner used by the client |
|
|
40
40
|
| --- | ---: | --- |
|
|
41
41
|
| Namespace | 1 / 0 | owner-only local Ed25519 seed and portable reserved-name claim; intentionally not a persistent-session or general client capability |
|
|
42
|
-
| Account | 8 / 8 | `core/account/user.js`, `core/account/session.js`; machine-auth transport in `functions/
|
|
42
|
+
| Account | 8 / 8 | `core/account/user.js`, `core/account/session.js`; machine-auth transport in `functions/machineauth/account.js` |
|
|
43
43
|
| Vault | 4 / 3 | `core/vault.js`, shared vault-seed crypto, and `core/account/session.js`; mnemonic export is not callable through the persistent session |
|
|
44
44
|
| Profile | 3 / 3 | shared user owner and Firebase cloud adapter |
|
|
45
45
|
| Settings | 2 / 2 | shared user settings owner and normalization |
|
|
@@ -48,7 +48,7 @@ API version 3 establishes `open()` as the public SDK composition root and remove
|
|
|
48
48
|
| Chat | 21 / 21 | `core/chat/session.js`, the framework-free mounted message route, shared actions, message batches, history, retention, and attachment owners |
|
|
49
49
|
| Wallet | 10 / 10 | `core/wallet/session.js`, claim, transfer-store, and tx-data owners |
|
|
50
50
|
| Lightning | 5 / 5 | the same shared wallet session and Spark request owners |
|
|
51
|
-
| Withdrawal | 3 / 3 | shared wallet session, fee normalization, and
|
|
51
|
+
| Withdrawal | 3 / 3 | shared wallet session, fee normalization, and generic payment-intent/L1 review owner |
|
|
52
52
|
| Invite | 2 / 2 | `core/invite.js`; direct URL strings only |
|
|
53
53
|
| Passkeys | 3 / 2 | shared passkey eligibility plus the normal cloud passkey owners; bearer-link creation is one-shot only and WebAuthn stays browser-assisted |
|
|
54
54
|
| Support | 3 / 3 | shared feedback, bug, report, message lookup, and evidence builders |
|
|
@@ -87,7 +87,7 @@ API version 3 establishes `open()` as the public SDK composition root and remove
|
|
|
87
87
|
- Deleted-chat tombstones prevent stale owner/list snapshots from resurrecting a locally deleted chat.
|
|
88
88
|
- Multiple event subscribers share the underlying message-batch source lease.
|
|
89
89
|
- Concurrent chat-list publications cannot attach the same event source twice and accidentally release its only lease; two subscribers each received two successive live messages exactly once.
|
|
90
|
-
-
|
|
90
|
+
- SDK history and event projection use the same retention and reaction derivation primitives as route UI, including reaction removal updates to an already-visible message.
|
|
91
91
|
- Explicit message deletion emits immediate removal; retention/source expiry remains held for an already-open route until release.
|
|
92
92
|
- Self-block is rejected, blocked state is reflected in returned/listed peer projections, and blocked chats are hidden.
|
|
93
93
|
- Blocking retires the known opaque generation. If a sender writes into a newly issued generation while delivery remains blocked, the recipient's encrypted first-accepted timestamp floors every later listener, history page, cleanup scan, and direct lookup; the blocked-period record did not appear after unblocking and was rejected by targeted save lookup.
|
|
@@ -101,7 +101,7 @@ API version 3 establishes `open()` as the public SDK composition root and remove
|
|
|
101
101
|
- Ambiguous money mutations expose `operation_outcome_unknown` with the caller operation id. Spark sends, request/invoice payments, and withdrawals are non-retryable until reconciled; Lightning is retryable only with the exact same idempotency key.
|
|
102
102
|
- Invalid withdrawal input fails before wallet mutation.
|
|
103
103
|
- A prepared withdrawal rejects when its post-fee output falls below the destination script's dust floor; the confirmed P2TR boundary is 330 sats.
|
|
104
|
-
- The live CLI confirmation exposed that reviewed fee flags were not entering the command input, so it obtained a second quote; the fee happened to remain 2,190 sats. CLI confirmation now accepts the reviewed quote id and fee amount as one pair, a partial pair rejects before wallet work, and focused dispatch coverage proves the complete pair reaches the shared
|
|
104
|
+
- The live CLI confirmation exposed that reviewed fee flags were not entering the command input, so it obtained a second quote; the fee happened to remain 2,190 sats. CLI confirmation now accepts the reviewed quote id and fee amount as one pair, a partial pair rejects before wallet work, and focused dispatch coverage proves the complete pair reaches the shared Bitcoin payment mutation.
|
|
105
105
|
- Static funding uses one identity-scoped confirmed-UTXO source. The former catch-all address-query fallback was removed so an upstream failure cannot double requests or silently change the privacy shape.
|
|
106
106
|
- A live 810-sat static funding output was claimed once for 711 sats after the 99-sat claim fee. A second explicit claim returned false and history contained one completed funding row, proving idempotent convergence rather than a duplicate claim.
|
|
107
107
|
- The receiver completed its funding claim before the sender's cooperative-exit transfer reached completed status. The existing outgoing reconciler stopped after two unresolved checks, so the sender row stayed pending until an explicit refresh. Cooperative exits now retain a bounded 15-second exact-transfer check for up to ten minutes; ordinary direct transfers keep the earlier low-cost stop policy.
|
|
@@ -112,7 +112,7 @@ API version 3 establishes `open()` as the public SDK composition root and remove
|
|
|
112
112
|
- Account deletion removes the local profile, closes wallet/vault owners, drains in-flight local work, and automatically exits every current persistent runtime as soon as its credential/session watch becomes invalid.
|
|
113
113
|
- Account deletion drains pending cache writes and destroys the account/network cache scope, including its install secret, rather than leaving encrypted remnants after the local profile is removed.
|
|
114
114
|
- A send whose direct write response is ambiguous reuses its CID as the message document id and checks that exact committed document before reporting failure. The separate sealed ping may repeat in this rare case and is reconciled by its encrypted message id.
|
|
115
|
-
- A disposable no-evidence peer report completed through the shared report/evidence builder, and deleting its reporter account removed the UID-owned report while repairing the target aggregate. Feedback/bug
|
|
115
|
+
- A disposable no-evidence peer report completed through the shared report/evidence builder, and deleting its reporter account removed the UID-owned report while repairing the target aggregate. Feedback/bug share one backend input owner whose platform set includes the SDK.
|
|
116
116
|
|
|
117
117
|
The blocked-send experiment exposed a real presentation bug—a committed ciphertext could be reported failed when the later ping was rejected—but its proposed atomic callable centralized sender/recipient IDs, both chat public keys, link ID, and chat ID on every send. The release review removed that architecture. Message and encrypted owner entry now commit directly in one client batch; the separate sealed-inbox call is best effort and cannot reverse the committed result. This preserves the narrow sender/recipient metadata exception required for block checks and sender-identifying push without joining it to the chat route.
|
|
118
118
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@glyphteck/veyl",
|
|
3
|
-
"license": "
|
|
3
|
+
"license": "SEE LICENSE IN LICENSE",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Public JavaScript SDK and CLI for Veyl accounts, chat, and wallet payments.",
|
|
6
6
|
"repository": {
|
|
@@ -25,6 +25,7 @@
|
|
|
25
25
|
"examples/bot-fleet/policy.js",
|
|
26
26
|
"examples/bot-fleet/runtime.js",
|
|
27
27
|
"examples/bot-fleet/readme.md",
|
|
28
|
+
"LICENSE",
|
|
28
29
|
"readme.md",
|
|
29
30
|
"package.json"
|
|
30
31
|
],
|
|
@@ -40,5 +41,5 @@
|
|
|
40
41
|
"start": "node src/cli.js",
|
|
41
42
|
"lint": "eslint src --quiet"
|
|
42
43
|
},
|
|
43
|
-
"version": "0.
|
|
44
|
+
"version": "0.55.0"
|
|
44
45
|
}
|
package/readme.md
CHANGED
|
@@ -6,7 +6,7 @@ The SDK is a real client, not an admin API. It uses the same shared account, vau
|
|
|
6
6
|
|
|
7
7
|
The public `open()` factory selects the Node runtime ports for filesystem profiles, Firebase transport, Spark, machine credentials, browser-assisted passkeys, and local encrypted cache. Official web and iOS clients use the `@glyphteck/veyl/auth` and `@glyphteck/veyl/account` entries with platform ports for the same passkey orchestration, authenticated user, encrypted settings, public-profile mutation, vault, network, presence, wallet, transfer, transaction, public Bitcoin data, chat-session, peer-directory, profile-search, support/reporting, authenticated push leases, account deletion, and teardown owners. They do not carry separate auth, passkey, account, profile, peer, search, chat, wallet, Bitcoin, transfer, transaction, settings, support, or deletion state machines. The browser/native credential ceremony, native notification presentation, and device-local credential cleanup remain platform behavior.
|
|
8
8
|
|
|
9
|
-
## Install
|
|
9
|
+
## Install the SDK
|
|
10
10
|
|
|
11
11
|
```bash
|
|
12
12
|
npm install @glyphteck/veyl
|
|
@@ -14,51 +14,49 @@ npm install @glyphteck/veyl
|
|
|
14
14
|
# or: bun add @glyphteck/veyl
|
|
15
15
|
```
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
## JavaScript quick start
|
|
18
18
|
|
|
19
|
-
```
|
|
20
|
-
|
|
19
|
+
```js
|
|
20
|
+
import { open, TERMS_VERSION } from '@glyphteck/veyl';
|
|
21
|
+
|
|
22
|
+
const veyl = await open({ profile: 'runner', network: 'REGTEST' });
|
|
23
|
+
await veyl.account.create({ username: 'runner', termsVersion: TERMS_VERSION });
|
|
24
|
+
await veyl.vault.create();
|
|
25
|
+
await veyl.chat.send('@alice', 'hello');
|
|
26
|
+
console.log(await veyl.wallet.balance());
|
|
27
|
+
await veyl.close();
|
|
21
28
|
```
|
|
22
29
|
|
|
23
|
-
|
|
30
|
+
The human or controlling application must show the public Terms and Community Rules and obtain explicit agreement before creating an account. Machine credentials and passkeys describe authentication capability, not whether a person or agent operates the account. Third-party agents use ordinary public profiles; only namespace-authorized Glyphteck services carry the managed bot marker. Use `REGTEST` for disposable automation and `MAINNET` only for real funds.
|
|
31
|
+
|
|
32
|
+
## Optional CLI
|
|
33
|
+
|
|
34
|
+
The package also ships a CLI for one-off shell work:
|
|
24
35
|
|
|
25
36
|
```bash
|
|
26
|
-
veyl --network REGTEST account create @runner
|
|
27
|
-
veyl vault create
|
|
28
|
-
veyl account show
|
|
29
|
-
veyl wallet address
|
|
37
|
+
npx veyl --network REGTEST account create @runner
|
|
38
|
+
npx veyl vault create
|
|
39
|
+
npx veyl account show
|
|
40
|
+
npx veyl wallet address
|
|
30
41
|
```
|
|
31
42
|
|
|
32
43
|
Interactive account creation displays the public Terms and Community Rules URLs and asks for acceptance. Non-interactive callers must pass the exact current version:
|
|
33
44
|
|
|
34
45
|
```bash
|
|
35
|
-
veyl --network REGTEST account create @runner --accept-terms 2026-07-15
|
|
46
|
+
npx veyl --network REGTEST account create @runner --accept-terms 2026-07-15
|
|
36
47
|
```
|
|
37
48
|
|
|
38
|
-
|
|
49
|
+
To create or log into a normal passkey account from a browser-capable terminal, add `--passkey` to `account create` or `account login`.
|
|
39
50
|
|
|
40
51
|
Glyphteck's owner-only reserved namespace uses one local key:
|
|
41
52
|
|
|
42
53
|
```bash
|
|
43
|
-
veyl namespace init
|
|
44
|
-
veyl --network REGTEST account create @faucet --reserved
|
|
54
|
+
npx veyl namespace init
|
|
55
|
+
npx veyl --network REGTEST account create @faucet --reserved
|
|
45
56
|
```
|
|
46
57
|
|
|
47
58
|
Initialization writes the private seed only to `~/.veyl/namespace.seed` with mode `0600` and prints its public identity. The explicit `--reserved` account flow and Glyphteck fleet provisioning sign an exact, short-lived reserved-name claim when that file exists. General users do not possess the key and remain unable to claim reserved names.
|
|
48
59
|
|
|
49
|
-
## JavaScript
|
|
50
|
-
|
|
51
|
-
```js
|
|
52
|
-
import { open, TERMS_VERSION } from '@glyphteck/veyl';
|
|
53
|
-
|
|
54
|
-
const veyl = await open({ profile: 'runner', network: 'REGTEST' });
|
|
55
|
-
await veyl.account.create({ username: 'runner', termsVersion: TERMS_VERSION });
|
|
56
|
-
await veyl.vault.create();
|
|
57
|
-
await veyl.chat.send('@alice', 'hello');
|
|
58
|
-
console.log(await veyl.wallet.balance());
|
|
59
|
-
await veyl.close();
|
|
60
|
-
```
|
|
61
|
-
|
|
62
60
|
Long-running agents should keep one unlocked client or foreground session alive. This reuses the same wallet, peer, chat, cache, and live-listener owners instead of paying cold login and wallet boot cost for every command.
|
|
63
61
|
|
|
64
62
|
Agents can also mount one conversation through `veyl.chat.enter('@alice')`, or run one local `openFleetOwner(...)` for many accounts. A versioned fleet root derives isolated machine credentials, vault-unlock secrets, and Veyl master seeds by monotonically allocated account index, so the operator backs up one secret for an unbounded fleet. Fleet policies remain normal API consumers; they receive no Firebase Admin or wallet shortcuts.
|
|
@@ -105,3 +103,7 @@ Use `REGTEST` for development and disposable accounts. Use `MAINNET` only for re
|
|
|
105
103
|
- [Agent operation](docs/agents.md)
|
|
106
104
|
- [Documentation discovery](docs/discovery.md)
|
|
107
105
|
- [Parity and validation](docs/validation.md)
|
|
106
|
+
|
|
107
|
+
## License
|
|
108
|
+
|
|
109
|
+
The official Veyl JavaScript SDK is distributed under its [proprietary SDK license](LICENSE); it is not currently open source. The license permits use of the unmodified SDK with Veyl, including normal compiled or bundled use, but not modified or standalone redistribution.
|