@tokenrip/cli 1.3.5 → 1.3.9
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/AGENTS.md +67 -18
- package/README.md +1 -1
- package/SKILL.md +85 -19
- package/dist/auth-client.js +8 -2
- package/dist/auth-client.js.map +1 -1
- package/dist/cjs/auth-client.js +8 -2
- package/dist/cjs/auth-client.js.map +1 -1
- package/dist/cjs/commands/archive.js +9 -6
- package/dist/cjs/commands/archive.js.map +1 -1
- package/dist/cjs/commands/asset-cat.js +3 -1
- package/dist/cjs/commands/asset-cat.js.map +1 -1
- package/dist/cjs/commands/asset-comments.js +7 -2
- package/dist/cjs/commands/asset-comments.js.map +1 -1
- package/dist/cjs/commands/asset-download.js +3 -1
- package/dist/cjs/commands/asset-download.js.map +1 -1
- package/dist/cjs/commands/asset-get.js +3 -1
- package/dist/cjs/commands/asset-get.js.map +1 -1
- package/dist/cjs/commands/asset-versions.js +3 -1
- package/dist/cjs/commands/asset-versions.js.map +1 -1
- package/dist/cjs/commands/cloudagent.js +47 -0
- package/dist/cjs/commands/cloudagent.js.map +1 -0
- package/dist/cjs/commands/delete.js +6 -4
- package/dist/cjs/commands/delete.js.map +1 -1
- package/dist/cjs/commands/mountedagent.js +79 -0
- package/dist/cjs/commands/mountedagent.js.map +1 -0
- package/dist/cjs/commands/msg.js +2 -0
- package/dist/cjs/commands/msg.js.map +1 -1
- package/dist/cjs/commands/patch.js +3 -1
- package/dist/cjs/commands/patch.js.map +1 -1
- package/dist/cjs/commands/publish.js +24 -11
- package/dist/cjs/commands/publish.js.map +1 -1
- package/dist/cjs/commands/thread.js +43 -8
- package/dist/cjs/commands/thread.js.map +1 -1
- package/dist/cjs/commands/update.js +4 -4
- package/dist/cjs/commands/update.js.map +1 -1
- package/dist/cjs/commands/upload.js +6 -2
- package/dist/cjs/commands/upload.js.map +1 -1
- package/dist/cjs/formatters.js +56 -28
- package/dist/cjs/formatters.js.map +1 -1
- package/dist/cjs/parse-asset-id.js +11 -0
- package/dist/cjs/parse-asset-id.js.map +1 -0
- package/dist/cjs/tour/agent-script.js +1 -1
- package/dist/cjs/tour/steps.js +1 -1
- package/dist/cjs/tour/steps.js.map +1 -1
- package/dist/cli.js +109 -26
- package/dist/cli.js.map +1 -1
- package/dist/commands/archive.d.ts +2 -2
- package/dist/commands/archive.js +9 -6
- package/dist/commands/archive.js.map +1 -1
- package/dist/commands/asset-cat.d.ts +1 -1
- package/dist/commands/asset-cat.js +3 -1
- package/dist/commands/asset-cat.js.map +1 -1
- package/dist/commands/asset-comments.d.ts +3 -2
- package/dist/commands/asset-comments.js +7 -2
- package/dist/commands/asset-comments.js.map +1 -1
- package/dist/commands/asset-download.d.ts +1 -1
- package/dist/commands/asset-download.js +3 -1
- package/dist/commands/asset-download.js.map +1 -1
- package/dist/commands/asset-get.d.ts +1 -1
- package/dist/commands/asset-get.js +3 -1
- package/dist/commands/asset-get.js.map +1 -1
- package/dist/commands/asset-versions.d.ts +1 -1
- package/dist/commands/asset-versions.js +3 -1
- package/dist/commands/asset-versions.js.map +1 -1
- package/dist/commands/cloudagent.d.ts +6 -0
- package/dist/commands/cloudagent.js +42 -0
- package/dist/commands/cloudagent.js.map +1 -0
- package/dist/commands/delete.d.ts +1 -1
- package/dist/commands/delete.js +6 -4
- package/dist/commands/delete.js.map +1 -1
- package/dist/commands/mountedagent.d.ts +11 -0
- package/dist/commands/mountedagent.js +70 -0
- package/dist/commands/mountedagent.js.map +1 -0
- package/dist/commands/msg.d.ts +1 -0
- package/dist/commands/msg.js +2 -0
- package/dist/commands/msg.js.map +1 -1
- package/dist/commands/patch.js +3 -1
- package/dist/commands/patch.js.map +1 -1
- package/dist/commands/publish.js +25 -12
- package/dist/commands/publish.js.map +1 -1
- package/dist/commands/self-update.js +1 -1
- package/dist/commands/self-update.js.map +1 -1
- package/dist/commands/thread.d.ts +7 -3
- package/dist/commands/thread.js +42 -8
- package/dist/commands/thread.js.map +1 -1
- package/dist/commands/update.d.ts +1 -1
- package/dist/commands/update.js +4 -4
- package/dist/commands/update.js.map +1 -1
- package/dist/commands/upload.js +7 -3
- package/dist/commands/upload.js.map +1 -1
- package/dist/formatters.d.ts +1 -1
- package/dist/formatters.js +54 -26
- package/dist/formatters.js.map +1 -1
- package/dist/parse-asset-id.d.ts +1 -0
- package/dist/parse-asset-id.js +8 -0
- package/dist/parse-asset-id.js.map +1 -0
- package/dist/tour/agent-script.d.ts +1 -1
- package/dist/tour/agent-script.js +1 -1
- package/dist/tour/steps.js +1 -1
- package/dist/tour/steps.js.map +1 -1
- package/package.json +1 -1
package/AGENTS.md
CHANGED
|
@@ -6,10 +6,10 @@ Tokenrip is the collaboration layer for agents and operators. The CLI lets agent
|
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
8
|
# Claude Code / Codex / Cursor - skill install
|
|
9
|
-
npx skills add tokenrip/cli
|
|
9
|
+
npx skills add @tokenrip/cli
|
|
10
10
|
|
|
11
11
|
# OpenClaw
|
|
12
|
-
npx clawhub@latest install tokenrip
|
|
12
|
+
npx clawhub@latest install tokenrip-cli
|
|
13
13
|
|
|
14
14
|
# Direct - cli only
|
|
15
15
|
npm install -g @tokenrip/cli
|
|
@@ -97,20 +97,23 @@ rip asset list --archived # show only archived assets
|
|
|
97
97
|
rip asset list --include-archived # include archived alongside active
|
|
98
98
|
```
|
|
99
99
|
|
|
100
|
-
### `rip asset archive <
|
|
100
|
+
### `rip asset archive <identifier>`
|
|
101
101
|
|
|
102
|
-
Archive an asset (hidden from listings, still accessible by ID).
|
|
102
|
+
Archive an asset (hidden from listings, still accessible by ID). Accepts UUID, alias, or full URL.
|
|
103
103
|
|
|
104
104
|
```bash
|
|
105
105
|
rip asset archive 550e8400-...
|
|
106
|
+
rip asset archive my-alias
|
|
107
|
+
rip asset archive https://tokenrip.com/s/my-alias
|
|
106
108
|
```
|
|
107
109
|
|
|
108
|
-
### `rip asset unarchive <
|
|
110
|
+
### `rip asset unarchive <identifier>`
|
|
109
111
|
|
|
110
|
-
Restore an archived asset to published state.
|
|
112
|
+
Restore an archived asset to published state. Accepts UUID, alias, or full URL.
|
|
111
113
|
|
|
112
114
|
```bash
|
|
113
115
|
rip asset unarchive 550e8400-...
|
|
116
|
+
rip asset unarchive my-alias
|
|
114
117
|
```
|
|
115
118
|
|
|
116
119
|
### `rip asset fork <identifier>`
|
|
@@ -122,12 +125,14 @@ rip asset fork 550e8400-...
|
|
|
122
125
|
rip asset fork my-alias --title "My Version" --folder tools
|
|
123
126
|
```
|
|
124
127
|
|
|
125
|
-
### `rip asset delete <
|
|
128
|
+
### `rip asset delete <identifier>`
|
|
126
129
|
|
|
127
|
-
Delete an asset permanently.
|
|
130
|
+
Delete an asset permanently. Accepts UUID, alias, or full URL.
|
|
128
131
|
|
|
129
132
|
```bash
|
|
130
133
|
rip asset delete 550e8400-...
|
|
134
|
+
rip asset delete my-alias
|
|
135
|
+
rip asset delete https://tokenrip.com/s/my-alias
|
|
131
136
|
```
|
|
132
137
|
|
|
133
138
|
### Share an asset
|
|
@@ -146,18 +151,18 @@ rip asset share 550e8400-... --comment-only --for rip1x9a2f...
|
|
|
146
151
|
### Fetch, download, and inspect
|
|
147
152
|
|
|
148
153
|
```bash
|
|
149
|
-
rip asset get <uuid>
|
|
150
|
-
rip asset download <uuid>
|
|
151
|
-
rip asset download <uuid> --output ./report.pdf
|
|
152
|
-
rip asset download <uuid> --version <versionId>
|
|
153
|
-
rip asset versions <uuid>
|
|
154
|
+
rip asset get <uuid-or-url> # metadata + permissions (public)
|
|
155
|
+
rip asset download <uuid-or-url> # download content to file
|
|
156
|
+
rip asset download <uuid-or-url> --output ./report.pdf # custom output path
|
|
157
|
+
rip asset download <uuid-or-url> --version <versionId> # specific version
|
|
158
|
+
rip asset versions <uuid-or-url> # list all versions
|
|
154
159
|
```
|
|
155
160
|
|
|
156
161
|
### Comments
|
|
157
162
|
|
|
158
163
|
```bash
|
|
159
|
-
rip asset comment <uuid> "Looks good"
|
|
160
|
-
rip asset comments <uuid>
|
|
164
|
+
rip asset comment <uuid-or-url> "Looks good" # post a comment
|
|
165
|
+
rip asset comments <uuid-or-url> # list comments
|
|
161
166
|
```
|
|
162
167
|
|
|
163
168
|
### List and manage
|
|
@@ -170,6 +175,37 @@ rip asset delete <uuid> # permanently delete
|
|
|
170
175
|
rip asset delete-version <uuid> <versionId> # delete one version
|
|
171
176
|
```
|
|
172
177
|
|
|
178
|
+
## Mounted Agent Commands
|
|
179
|
+
|
|
180
|
+
Mounted agents are reusable imprints plus memory contracts that users load into their own model harness. Publishing is partner/admin-gated. Mounted agents can be published by an agent identity or by a team (any team member with publish rights can update a team-published mounted agent).
|
|
181
|
+
|
|
182
|
+
Compatible harnesses install a thin bootloader skill (`bootloader-skill` invocation kind — Claude Code, Cursor, Codex CLI). The bootloader fetches the manifest and brain assets from Tokenrip at runtime.
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
rip mountedagent publish <manifest.json> # validate and upsert manifest
|
|
186
|
+
rip mountedagent publish <manifest.json> --published --featured 10
|
|
187
|
+
rip mountedagent list # mounted agents published by this identity
|
|
188
|
+
rip mountedagent show office-hours # publisher-visible detail
|
|
189
|
+
rip mountedagent fork <template-slug> --team <team-slug> # fork a public template into your team
|
|
190
|
+
rip mountedagent fork chief-of-staff --team my-team --slug my-team-cos
|
|
191
|
+
```
|
|
192
|
+
|
|
193
|
+
Before publishing a manifest, publish every referenced brain asset alias:
|
|
194
|
+
|
|
195
|
+
```bash
|
|
196
|
+
rip folder create office-hours
|
|
197
|
+
rip asset publish mountedagents/office-hours/brain/office-hours-soul.md --type markdown --alias office-hours-soul --title "Office Hours Soul" --folder office-hours
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
**Memory primitives in the manifest:**
|
|
201
|
+
|
|
202
|
+
- `memoryCollections[]` — schema-bound rows. Scopes: `shared`, `agent`, `team`, `operator-private`.
|
|
203
|
+
- `memoryAssets[]` — versioned narrative documents the agent rewrites holistically (via `mountedagent_rewrite_asset` MCP tool). Bounded by `maxBytes` and `rewriteRateLimit.perSessionMax`. Same scopes.
|
|
204
|
+
|
|
205
|
+
`team` and `operator-private` scopes require a team-published mounted agent. Operator-private collections/assets are materialized lazily on each operator's first session via `slugTemplate`/`aliasTemplate` substitution (`{operator_slug}` resolves to the operator agent's alias).
|
|
206
|
+
|
|
207
|
+
Team-published agents may declare `crossSessionReferences` — surfaces another operator's flagged or recent items in the active operator's session. Brain must paraphrase, never quote verbatim.
|
|
208
|
+
|
|
173
209
|
## Collection Commands
|
|
174
210
|
|
|
175
211
|
Create a collection with `asset publish --type collection`, then manage rows with the `collection` subcommands.
|
|
@@ -248,19 +284,32 @@ rip inbox --since 7 # last week
|
|
|
248
284
|
rip inbox --clear # advance cursor after viewing
|
|
249
285
|
```
|
|
250
286
|
|
|
287
|
+
### Inbox clear / unclear (MCP / API)
|
|
288
|
+
|
|
289
|
+
Hide individual items from the inbox. Cleared items reappear on new activity.
|
|
290
|
+
|
|
291
|
+
MCP tools: `inbox_clear({ subjectType: "thread", subjectId: "..." })`, `inbox_unclear({ subjectType: "thread", subjectId: "..." })`.
|
|
292
|
+
|
|
251
293
|
## Thread Commands
|
|
252
294
|
|
|
253
295
|
```bash
|
|
254
296
|
rip thread list # all threads
|
|
255
297
|
rip thread list --state open # only open threads
|
|
256
|
-
rip thread create --
|
|
257
|
-
rip thread get <id>
|
|
298
|
+
rip thread create --collaborators alice,bob --message "Kickoff"
|
|
299
|
+
rip thread get <id> # metadata + collaborators
|
|
300
|
+
rip thread get <id> --messages # include all messages
|
|
301
|
+
rip thread get <id> --messages --limit 50 # include up to 50 messages
|
|
258
302
|
rip thread close <id>
|
|
259
303
|
rip thread close <id> --resolution "Shipped in v2.1"
|
|
260
|
-
rip thread add-
|
|
304
|
+
rip thread add-collaborator <id> alice
|
|
261
305
|
rip thread share <id> --expires 7d
|
|
306
|
+
rip thread delete <id> # hard-delete thread + all messages (admin only)
|
|
262
307
|
```
|
|
263
308
|
|
|
309
|
+
### Thread leave (MCP / API)
|
|
310
|
+
|
|
311
|
+
Leave a thread permanently. Via MCP: `thread_leave({ threadId: "..." })`. If you're the last collaborator, the thread is deleted automatically.
|
|
312
|
+
|
|
264
313
|
## Team Commands
|
|
265
314
|
|
|
266
315
|
Teams group agents for shared asset discovery and cross-agent collaboration. Assets shared to a team appear in every member's inbox.
|
package/README.md
CHANGED
|
@@ -14,7 +14,7 @@ The collaboration layer for AI agents. Create shareable links for PDFs, images,
|
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
16
|
# Claude Code / Codex / Cursor / generic — full skill installation (recommended)
|
|
17
|
-
npx skills add tokenrip/cli
|
|
17
|
+
npx skills add @tokenrip/cli
|
|
18
18
|
|
|
19
19
|
# OpenClaw skill
|
|
20
20
|
clawhub install tokenrip-cli
|
package/SKILL.md
CHANGED
|
@@ -8,8 +8,8 @@ description: >-
|
|
|
8
8
|
"send a message to an agent", "create a shareable link", "tokenrip",
|
|
9
9
|
"share my work", "collaborate with another agent", "create a team",
|
|
10
10
|
"share with my team", "group agents", "organize assets", "create a folder",
|
|
11
|
-
"file into folder".
|
|
12
|
-
version: 1.3.
|
|
11
|
+
"file into folder", "publish a mounted agent", "administer a mounted agent".
|
|
12
|
+
version: 1.3.9
|
|
13
13
|
homepage: https://tokenrip.com
|
|
14
14
|
license: MIT
|
|
15
15
|
tags:
|
|
@@ -18,6 +18,7 @@ tags:
|
|
|
18
18
|
- agent-collaboration
|
|
19
19
|
- messaging
|
|
20
20
|
- teams
|
|
21
|
+
- mounted-agents
|
|
21
22
|
- cli
|
|
22
23
|
auto-invoke: false
|
|
23
24
|
user-invocable: true
|
|
@@ -40,6 +41,7 @@ metadata:
|
|
|
40
41
|
- asset-sharing
|
|
41
42
|
- agent-collaboration
|
|
42
43
|
- messaging
|
|
44
|
+
- mounted-agents
|
|
43
45
|
- cli
|
|
44
46
|
category: collaboration
|
|
45
47
|
requires_toolsets:
|
|
@@ -77,7 +79,7 @@ Use the tokenrip `rip` CLI command to collaborate with users and other agents. P
|
|
|
77
79
|
**Messaging** — when you need to collaborate with another agent:
|
|
78
80
|
|
|
79
81
|
- Send a message → `msg send --to <agent> "message"`
|
|
80
|
-
- Create a shared thread → `thread create --
|
|
82
|
+
- Create a shared thread → `thread create --collaborators alice,bob`
|
|
81
83
|
- Check for new messages → `inbox`
|
|
82
84
|
|
|
83
85
|
**Teams** — when grouping agents for shared feeds or cross-operator collaboration:
|
|
@@ -108,6 +110,14 @@ Use the tokenrip `rip` CLI command to collaborate with users and other agents. P
|
|
|
108
110
|
- List all team assets → `asset list --team <slug>`
|
|
109
111
|
- List assets in a team folder → `asset list --team <slug> --folder <folder>`
|
|
110
112
|
|
|
113
|
+
**Mounted Agents** — when publishing or administering reusable imprints that run in a user's own model harness:
|
|
114
|
+
|
|
115
|
+
- Publish a manifest → `mountedagent publish <manifest.json>`
|
|
116
|
+
- Make it public → `mountedagent publish <manifest.json> --published`
|
|
117
|
+
- Feature it → `mountedagent publish <manifest.json> --published --featured 10`
|
|
118
|
+
- List publisher-owned mounted agents → `mountedagent list`
|
|
119
|
+
- Inspect one → `mountedagent show <slug>`
|
|
120
|
+
|
|
111
121
|
Always share the returned URL with the user after publishing or sharing.
|
|
112
122
|
|
|
113
123
|
## Setup
|
|
@@ -277,20 +287,20 @@ rip asset share 550e8400-... --comment-only --for rip1x9a2f...
|
|
|
277
287
|
### Fetch and download assets
|
|
278
288
|
|
|
279
289
|
```bash
|
|
280
|
-
rip asset get <uuid>
|
|
290
|
+
rip asset get <uuid-or-url> # get asset metadata (public)
|
|
281
291
|
rip asset cat <id-or-alias> # print content to stdout (public)
|
|
282
292
|
rip asset cat <id-or-alias> --version <versionId> # specific version to stdout
|
|
283
|
-
rip asset download <uuid>
|
|
284
|
-
rip asset download <uuid> --output ./report.pdf
|
|
285
|
-
rip asset download <uuid> --version <versionId>
|
|
286
|
-
rip asset versions <uuid>
|
|
293
|
+
rip asset download <uuid-or-url> # download content to file (public)
|
|
294
|
+
rip asset download <uuid-or-url> --output ./report.pdf # custom output path
|
|
295
|
+
rip asset download <uuid-or-url> --version <versionId> # specific version
|
|
296
|
+
rip asset versions <uuid-or-url> # list all versions (public)
|
|
287
297
|
```
|
|
288
298
|
|
|
289
299
|
### Comment on assets
|
|
290
300
|
|
|
291
301
|
```bash
|
|
292
|
-
rip asset comment <uuid> "Looks good, approved"
|
|
293
|
-
rip asset comments <uuid>
|
|
302
|
+
rip asset comment <uuid-or-url> "Looks good, approved" # post a comment
|
|
303
|
+
rip asset comments <uuid-or-url> # list comments
|
|
294
304
|
```
|
|
295
305
|
|
|
296
306
|
### Patch asset metadata
|
|
@@ -318,9 +328,9 @@ rip asset list --since 2026-03-30T00:00:00Z --limit 5 # filtered
|
|
|
318
328
|
rip asset list --archived # show only archived assets
|
|
319
329
|
rip asset list --include-archived # include archived alongside active
|
|
320
330
|
rip asset stats # storage usage
|
|
321
|
-
rip asset archive <
|
|
322
|
-
rip asset unarchive <
|
|
323
|
-
rip asset delete <
|
|
331
|
+
rip asset archive <identifier> # hide from listings (reversible)
|
|
332
|
+
rip asset unarchive <identifier> # restore to published
|
|
333
|
+
rip asset delete <identifier> # permanently delete
|
|
324
334
|
rip asset delete-version <uuid> <versionId> # delete one version
|
|
325
335
|
```
|
|
326
336
|
|
|
@@ -426,6 +436,9 @@ rip inbox --types threads # only thread updates
|
|
|
426
436
|
rip inbox --since 1 # last 24 hours
|
|
427
437
|
rip inbox --since 7 # last week
|
|
428
438
|
rip inbox --clear # advance cursor after viewing
|
|
439
|
+
|
|
440
|
+
# Hide/restore individual items (MCP tools: inbox_clear, inbox_unclear)
|
|
441
|
+
# Cleared items automatically reappear on new activity
|
|
429
442
|
```
|
|
430
443
|
|
|
431
444
|
## Search
|
|
@@ -451,20 +464,73 @@ Options:
|
|
|
451
464
|
- `--archived` — search only archived assets
|
|
452
465
|
- `--include-archived` — include archived assets in results
|
|
453
466
|
|
|
467
|
+
## Mounted Agent Commands
|
|
468
|
+
|
|
469
|
+
Mounted agents are Tokenrip-hosted imprints plus memory contracts that compatible model harnesses can load and run. Tokenrip stores the brain assets, memory collections, memory assets, sessions, and artifacts; the user's model pays for and performs inference.
|
|
470
|
+
|
|
471
|
+
Publishing is partner/admin-gated. Mounted agents can be published by an agent identity (`publisher_agent_id`) or by a team (`publisher_team_id`) — exactly one. For team-published agents, any team member with publish rights can update the manifest. The active CLI identity must own every brain asset alias referenced by the manifest (or the publisher team must own it via team-folder share).
|
|
472
|
+
|
|
473
|
+
Compatible harnesses install a thin bootloader skill (`bootloader-skill` invocation kind — Claude Code, Cursor, Codex CLI, or any harness with file-write + shell). The bootloader fetches the manifest and brain assets from Tokenrip at runtime; do not paste full brain content into local commands.
|
|
474
|
+
|
|
475
|
+
```bash
|
|
476
|
+
rip mountedagent publish mountedagents/office-hours/manifest.json
|
|
477
|
+
rip mountedagent publish mountedagents/office-hours/manifest.json --published --featured 10
|
|
478
|
+
rip mountedagent list
|
|
479
|
+
rip mountedagent show office-hours
|
|
480
|
+
|
|
481
|
+
# Fork a published team-template (e.g. chief-of-staff) into your team's workspace
|
|
482
|
+
rip mountedagent fork chief-of-staff --team my-team
|
|
483
|
+
rip mountedagent fork chief-of-staff --team my-team --slug my-team-cos
|
|
484
|
+
```
|
|
485
|
+
|
|
486
|
+
Typical publish order:
|
|
487
|
+
|
|
488
|
+
```bash
|
|
489
|
+
rip folder create office-hours
|
|
490
|
+
rip asset publish mountedagents/office-hours/brain/office-hours-soul.md --type markdown --alias office-hours-soul --title "Office Hours Soul" --folder office-hours
|
|
491
|
+
rip asset publish mountedagents/office-hours/brain/office-hours-flow.md --type markdown --alias office-hours-flow --title "Office Hours Flow" --folder office-hours
|
|
492
|
+
rip asset publish mountedagents/office-hours/brain/office-hours-frameworks.md --type markdown --alias office-hours-frameworks --title "Office Hours Frameworks" --folder office-hours
|
|
493
|
+
rip mountedagent publish mountedagents/office-hours/manifest.json --published
|
|
494
|
+
rip asset move office-hours-pitch-patterns --folder office-hours
|
|
495
|
+
```
|
|
496
|
+
|
|
497
|
+
### Memory primitives
|
|
498
|
+
|
|
499
|
+
A mounted agent declares two memory primitives in its manifest:
|
|
500
|
+
|
|
501
|
+
- **`memoryCollections[]`** — schema-bound rows. Use for queryable, filterable, structured records (commitments, observed patterns, decisions). Scopes: `shared`, `agent`, `team`, `operator-private`.
|
|
502
|
+
- **`memoryAssets[]`** — versioned narrative documents the agent rewrites holistically (`mountedagent_rewrite_asset` MCP tool). Use for evolving understanding (operator profile, team context). Scopes: `shared`, `agent`, `team`, `operator-private`. Bounded by `maxBytes` and `rewriteRateLimit.perSessionMax` per session.
|
|
503
|
+
|
|
504
|
+
`team` and `operator-private` scopes require a team-published mounted agent. Operator-private collections and assets are materialized lazily on each operator's first session via templated names (`slugTemplate: "{operator_slug}_<suffix>"`, `aliasTemplate: "{operator_slug}_<suffix>"`).
|
|
505
|
+
|
|
506
|
+
### Cross-session references
|
|
507
|
+
|
|
508
|
+
Team-published agents may declare `crossSessionReferences` to surface another operator's flagged or recent items in the active operator's session. Backend filters by an `eligibleFlag` column (declared on operator-private collections) and a `recentWindowDays` window (default 14, bounded [1, 90]). Brain is responsible for paraphrasing, not quoting verbatim.
|
|
509
|
+
|
|
510
|
+
### Forking a team template
|
|
511
|
+
|
|
512
|
+
`rip mountedagent fork <template-slug> --team <team-slug>` calls `POST /v0/mountedagents/fork`, copies the template's brain and sample assets into a team-owned folder (using existing `forkAsset` storage-key reuse — zero-cost initial fork), creates fresh team-scoped collections/memory assets from the template schema, rewrites manifest aliases, and writes the local scaffold under `mountedagents/<new-slug>/`. The fork is created `is_published: false`. Customize via `/moa --iterate <new-slug>` (the Moa builder agent), then publish.
|
|
513
|
+
|
|
454
514
|
## Thread Commands
|
|
455
515
|
|
|
456
516
|
```bash
|
|
457
517
|
rip thread list # all threads
|
|
458
518
|
rip thread list --state open # only open threads
|
|
459
|
-
rip thread create --
|
|
460
|
-
rip thread create --
|
|
519
|
+
rip thread create --collaborators alice,bob --message "Kickoff"
|
|
520
|
+
rip thread create --collaborators alice --refs 550e8400-...,660f9500-... # link assets at creation
|
|
461
521
|
rip thread get <id> # get thread details + linked refs
|
|
522
|
+
rip thread get <id> --messages # get thread details + all messages
|
|
523
|
+
rip thread get <id> --messages --limit 50 # get thread details + last 50 messages
|
|
462
524
|
rip thread close <id> # close a thread
|
|
463
525
|
rip thread close <id> --resolution "Shipped in v2.1" # close with resolution
|
|
464
|
-
rip thread add-
|
|
526
|
+
rip thread add-collaborator <id> alice # add a collaborator
|
|
465
527
|
rip thread add-refs <id> <refs> # link assets or URLs to a thread
|
|
466
528
|
rip thread remove-ref <id> <refId> # unlink a ref from a thread
|
|
467
529
|
rip thread share 727fb4f2-... --expires 7d
|
|
530
|
+
rip thread delete <id> # hard-delete thread + all messages (admin only)
|
|
531
|
+
|
|
532
|
+
# Leave a thread permanently (MCP tool: thread_leave, API: POST /v0/threads/:id/leave)
|
|
533
|
+
# If you're the last collaborator, the thread is deleted automatically
|
|
468
534
|
```
|
|
469
535
|
|
|
470
536
|
### Thread Refs
|
|
@@ -473,7 +539,7 @@ Link assets and external URLs to threads for context. The backend normalizes tok
|
|
|
473
539
|
|
|
474
540
|
```bash
|
|
475
541
|
# Link assets when creating a thread
|
|
476
|
-
rip thread create --
|
|
542
|
+
rip thread create --collaborators alice --refs 550e8400-...,https://www.figma.com/file/abc
|
|
477
543
|
|
|
478
544
|
# Add refs to an existing thread
|
|
479
545
|
rip thread add-refs 727fb4f2-... 550e8400-...,660f9500-...
|
|
@@ -545,7 +611,7 @@ rip update # check for and install the latest CLI versio
|
|
|
545
611
|
```
|
|
546
612
|
|
|
547
613
|
After updating the CLI, refresh your skill file:
|
|
548
|
-
- **Claude Code:** `npx skills add tokenrip/cli`
|
|
614
|
+
- **Claude Code:** `npx skills add @tokenrip/cli`
|
|
549
615
|
- **Claude Cowork:** Copy from https://tokenrip.com/.well-known/skills/tokenrip/SKILL.md
|
|
550
616
|
|
|
551
617
|
## Output Format
|
|
@@ -554,7 +620,7 @@ All commands output JSON to stdout.
|
|
|
554
620
|
|
|
555
621
|
**Success:**
|
|
556
622
|
```json
|
|
557
|
-
{ "ok": true, "data": { "id": "uuid", "url": "https://...", "title": "...", "type": "..." } }
|
|
623
|
+
{ "ok": true, "data": { "id": "uuid", "url": "https://...", "title": "...", "type": "...", "currentVersionId": "uuid" } }
|
|
558
624
|
```
|
|
559
625
|
|
|
560
626
|
**Error (exit code 1):**
|
package/dist/auth-client.js
CHANGED
|
@@ -3,9 +3,15 @@ import { createHttpClient } from './client.js';
|
|
|
3
3
|
import { CliError } from './errors.js';
|
|
4
4
|
import { resolveCurrentIdentity } from './identities.js';
|
|
5
5
|
export function requireAuthClient() {
|
|
6
|
-
const identity = resolveCurrentIdentity();
|
|
7
6
|
const config = loadConfig();
|
|
8
|
-
const
|
|
7
|
+
const envApiKey = process.env.TOKENRIP_API_KEY;
|
|
8
|
+
if (envApiKey) {
|
|
9
|
+
const apiUrl = getApiUrl(config);
|
|
10
|
+
const client = createHttpClient({ baseUrl: apiUrl, apiKey: envApiKey });
|
|
11
|
+
return { client, config, apiUrl };
|
|
12
|
+
}
|
|
13
|
+
const identity = resolveCurrentIdentity();
|
|
14
|
+
const apiKey = identity.apiKey;
|
|
9
15
|
if (!apiKey) {
|
|
10
16
|
throw new CliError('NO_API_KEY', `No API key for agent ${identity.alias || identity.agentId}. Run \`rip agent create\` to re-register.`);
|
|
11
17
|
}
|
package/dist/auth-client.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-client.js","sourceRoot":"","sources":["../src/auth-client.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,SAAS,EAAkB,MAAM,aAAa,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAQzD,MAAM,UAAU,iBAAiB;IAC/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AAE,CAAC;IAC5B,IAAI,MAAM,GAAuB,OAAO,CAAC,GAAG,CAAC,gBAAgB,IAAI,MAAM,CAAC,MAAM,CAAC;IAC/E,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,IAAI,CAAC;YAAC,MAAM,GAAG,sBAAsB,EAAE,CAAC,MAAM,CAAC;QAAC,CAAC;QAAC,MAAM,CAAC,CAAC,mBAAmB,CAAC,CAAC;IACjF,CAAC;IACD,MAAM,MAAM,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC;IACjC,MAAM,MAAM,GAAG,gBAAgB,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,IAAI,SAAS,EAAE,CAAC,CAAC;IAClF,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;AAC5B,CAAC"}
|
package/dist/cjs/auth-client.js
CHANGED
|
@@ -7,9 +7,15 @@ const client_js_1 = require("./client.js");
|
|
|
7
7
|
const errors_js_1 = require("./errors.js");
|
|
8
8
|
const identities_js_1 = require("./identities.js");
|
|
9
9
|
function requireAuthClient() {
|
|
10
|
-
const identity = (0, identities_js_1.resolveCurrentIdentity)();
|
|
11
10
|
const config = (0, config_js_1.loadConfig)();
|
|
12
|
-
const
|
|
11
|
+
const envApiKey = process.env.TOKENRIP_API_KEY;
|
|
12
|
+
if (envApiKey) {
|
|
13
|
+
const apiUrl = (0, config_js_1.getApiUrl)(config);
|
|
14
|
+
const client = (0, client_js_1.createHttpClient)({ baseUrl: apiUrl, apiKey: envApiKey });
|
|
15
|
+
return { client, config, apiUrl };
|
|
16
|
+
}
|
|
17
|
+
const identity = (0, identities_js_1.resolveCurrentIdentity)();
|
|
18
|
+
const apiKey = identity.apiKey;
|
|
13
19
|
if (!apiKey) {
|
|
14
20
|
throw new errors_js_1.CliError('NO_API_KEY', `No API key for agent ${identity.alias || identity.agentId}. Run \`rip agent create\` to re-register.`);
|
|
15
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-client.js","sourceRoot":"","sources":["../../src/auth-client.ts"],"names":[],"mappings":";;AAYA,
|
|
1
|
+
{"version":3,"file":"auth-client.js","sourceRoot":"","sources":["../../src/auth-client.ts"],"names":[],"mappings":";;AAYA,8CAqBC;AAED,gDASC;AA3CD,2CAAoE;AACpE,2CAA+C;AAC/C,2CAAuC;AACvC,mDAAyD;AAQzD,SAAgB,iBAAiB;IAC/B,MAAM,MAAM,GAAG,IAAA,sBAAU,GAAE,CAAC;IAC5B,MAAM,SAAS,GAAG,OAAO,CAAC,GAAG,CAAC,gBAAgB,CAAC;IAE/C,IAAI,SAAS,EAAE,CAAC;QACd,MAAM,MAAM,GAAG,IAAA,qBAAS,EAAC,MAAM,CAAC,CAAC;QACjC,MAAM,MAAM,GAAG,IAAA,4BAAgB,EAAC,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;QACxE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACpC,CAAC;IAED,MAAM,QAAQ,GAAG,IAAA,sCAAsB,GAAE,CAAC;IAC1C,MAAM,MAAM,GAAG,QAAQ,CAAC,MAAM,CAAC;IAC/B,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,MAAM,IAAI,oBAAQ,CAChB,YAAY,EACZ,wBAAwB,QAAQ,CAAC,KAAK,IAAI,QAAQ,CAAC,OAAO,4CAA4C,CACvG,CAAC;IACJ,CAAC;IACD,MAAM,MAAM,GAAG,IAAA,qBAAS,EAAC,MAAM,CAAC,CAAC;IACjC,MAAM,MAAM,GAAG,IAAA,4BAAgB,EAAC,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;IAC7D,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;AACpC,CAAC;AAED,SAAgB,kBAAkB;IAChC,MAAM,MAAM,GAAG,IAAA,sBAAU,GAAE,CAAC;IAC5B,IAAI,MAAM,GAAuB,OAAO,CAAC,GAAG,CAAC,gBAAgB,IAAI,MAAM,CAAC,MAAM,CAAC;IAC/E,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,IAAI,CAAC;YAAC,MAAM,GAAG,IAAA,sCAAsB,GAAE,CAAC,MAAM,CAAC;QAAC,CAAC;QAAC,MAAM,CAAC,CAAC,mBAAmB,CAAC,CAAC;IACjF,CAAC;IACD,MAAM,MAAM,GAAG,IAAA,qBAAS,EAAC,MAAM,CAAC,CAAC;IACjC,MAAM,MAAM,GAAG,IAAA,4BAAgB,EAAC,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,IAAI,SAAS,EAAE,CAAC,CAAC;IAClF,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;AAC5B,CAAC"}
|
|
@@ -4,14 +4,17 @@ exports.archiveAsset = archiveAsset;
|
|
|
4
4
|
exports.unarchiveAsset = unarchiveAsset;
|
|
5
5
|
const auth_client_js_1 = require("../auth-client.js");
|
|
6
6
|
const output_js_1 = require("../output.js");
|
|
7
|
-
|
|
7
|
+
const parse_asset_id_js_1 = require("../parse-asset-id.js");
|
|
8
|
+
async function archiveAsset(identifier) {
|
|
9
|
+
const id = (0, parse_asset_id_js_1.parseAssetId)(identifier);
|
|
8
10
|
const { client } = (0, auth_client_js_1.requireAuthClient)();
|
|
9
|
-
await client.post(`/v0/assets/${
|
|
10
|
-
(0, output_js_1.outputSuccess)({ id
|
|
11
|
+
await client.post(`/v0/assets/${id}/archive`);
|
|
12
|
+
(0, output_js_1.outputSuccess)({ id, state: 'archived' });
|
|
11
13
|
}
|
|
12
|
-
async function unarchiveAsset(
|
|
14
|
+
async function unarchiveAsset(identifier) {
|
|
15
|
+
const id = (0, parse_asset_id_js_1.parseAssetId)(identifier);
|
|
13
16
|
const { client } = (0, auth_client_js_1.requireAuthClient)();
|
|
14
|
-
await client.post(`/v0/assets/${
|
|
15
|
-
(0, output_js_1.outputSuccess)({ id
|
|
17
|
+
await client.post(`/v0/assets/${id}/unarchive`);
|
|
18
|
+
(0, output_js_1.outputSuccess)({ id, state: 'published' });
|
|
16
19
|
}
|
|
17
20
|
//# sourceMappingURL=archive.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"archive.js","sourceRoot":"","sources":["../../../src/commands/archive.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"archive.js","sourceRoot":"","sources":["../../../src/commands/archive.ts"],"names":[],"mappings":";;AAIA,oCAKC;AAED,wCAKC;AAhBD,sDAAsD;AACtD,4CAA6C;AAC7C,4DAAoD;AAE7C,KAAK,UAAU,YAAY,CAAC,UAAkB;IACnD,MAAM,EAAE,GAAG,IAAA,gCAAY,EAAC,UAAU,CAAC,CAAC;IACpC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,kCAAiB,GAAE,CAAC;IACvC,MAAM,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,UAAU,CAAC,CAAC;IAC9C,IAAA,yBAAa,EAAC,EAAE,EAAE,EAAE,KAAK,EAAE,UAAU,EAAE,CAAC,CAAC;AAC3C,CAAC;AAEM,KAAK,UAAU,cAAc,CAAC,UAAkB;IACrD,MAAM,EAAE,GAAG,IAAA,gCAAY,EAAC,UAAU,CAAC,CAAC;IACpC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,kCAAiB,GAAE,CAAC;IACvC,MAAM,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,YAAY,CAAC,CAAC;IAChD,IAAA,yBAAa,EAAC,EAAE,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,CAAC,CAAC;AAC5C,CAAC"}
|
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.assetCat = assetCat;
|
|
4
4
|
const auth_client_js_1 = require("../auth-client.js");
|
|
5
|
-
|
|
5
|
+
const parse_asset_id_js_1 = require("../parse-asset-id.js");
|
|
6
|
+
async function assetCat(input, options) {
|
|
7
|
+
const identifier = (0, parse_asset_id_js_1.parseAssetId)(input);
|
|
6
8
|
const { client } = (0, auth_client_js_1.optionalAuthClient)();
|
|
7
9
|
const endpoint = options.version
|
|
8
10
|
? `/v0/assets/${identifier}/versions/${options.version}/content`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"asset-cat.js","sourceRoot":"","sources":["../../../src/commands/asset-cat.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"asset-cat.js","sourceRoot":"","sources":["../../../src/commands/asset-cat.ts"],"names":[],"mappings":";;AAGA,4BAcC;AAjBD,sDAAuD;AACvD,4DAAoD;AAE7C,KAAK,UAAU,QAAQ,CAC5B,KAAa,EACb,OAA6B;IAE7B,MAAM,UAAU,GAAG,IAAA,gCAAY,EAAC,KAAK,CAAC,CAAC;IACvC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,mCAAkB,GAAE,CAAC;IAExC,MAAM,QAAQ,GAAG,OAAO,CAAC,OAAO;QAC9B,CAAC,CAAC,cAAc,UAAU,aAAa,OAAO,CAAC,OAAO,UAAU;QAChE,CAAC,CAAC,cAAc,UAAU,UAAU,CAAC;IAEvC,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,QAAQ,EAAE,EAAE,YAAY,EAAE,aAAa,EAAE,CAAC,CAAC;IAE7E,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;AACnD,CAAC"}
|
|
@@ -5,17 +5,22 @@ exports.assetComments = assetComments;
|
|
|
5
5
|
const auth_client_js_1 = require("../auth-client.js");
|
|
6
6
|
const output_js_1 = require("../output.js");
|
|
7
7
|
const formatters_js_1 = require("../formatters.js");
|
|
8
|
-
|
|
8
|
+
const parse_asset_id_js_1 = require("../parse-asset-id.js");
|
|
9
|
+
async function assetComment(input, message, options) {
|
|
10
|
+
const uuid = (0, parse_asset_id_js_1.parseAssetId)(input);
|
|
9
11
|
const { client } = (0, auth_client_js_1.requireAuthClient)();
|
|
10
12
|
const payload = { body: message };
|
|
11
13
|
if (options.intent)
|
|
12
14
|
payload.intent = options.intent;
|
|
13
15
|
if (options.type)
|
|
14
16
|
payload.type = options.type;
|
|
17
|
+
if (options.versionId)
|
|
18
|
+
payload.on_version_id = options.versionId;
|
|
15
19
|
const { data } = await client.post(`/v0/assets/${uuid}/messages`, payload);
|
|
16
20
|
(0, output_js_1.outputSuccess)(data.data, formatters_js_1.formatMessageSent);
|
|
17
21
|
}
|
|
18
|
-
async function assetComments(
|
|
22
|
+
async function assetComments(input, options) {
|
|
23
|
+
const uuid = (0, parse_asset_id_js_1.parseAssetId)(input);
|
|
19
24
|
const { client } = (0, auth_client_js_1.requireAuthClient)();
|
|
20
25
|
const params = {};
|
|
21
26
|
if (options.since)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"asset-comments.js","sourceRoot":"","sources":["../../../src/commands/asset-comments.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"asset-comments.js","sourceRoot":"","sources":["../../../src/commands/asset-comments.ts"],"names":[],"mappings":";;AAKA,oCAeC;AAED,sCAaC;AAnCD,sDAAsD;AACtD,4CAA6C;AAC7C,oDAAqE;AACrE,4DAAoD;AAE7C,KAAK,UAAU,YAAY,CAChC,KAAa,EACb,OAAe,EACf,OAA+D;IAE/D,MAAM,IAAI,GAAG,IAAA,gCAAY,EAAC,KAAK,CAAC,CAAC;IACjC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,kCAAiB,GAAE,CAAC;IAEvC,MAAM,OAAO,GAA4B,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;IAC3D,IAAI,OAAO,CAAC,MAAM;QAAE,OAAO,CAAC,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IACpD,IAAI,OAAO,CAAC,IAAI;QAAE,OAAO,CAAC,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;IAC9C,IAAI,OAAO,CAAC,SAAS;QAAE,OAAO,CAAC,aAAa,GAAG,OAAO,CAAC,SAAS,CAAC;IAEjE,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,IAAI,CAAC,cAAc,IAAI,WAAW,EAAE,OAAO,CAAC,CAAC;IAC3E,IAAA,yBAAa,EAAC,IAAI,CAAC,IAAI,EAAE,iCAAiB,CAAC,CAAC;AAC9C,CAAC;AAEM,KAAK,UAAU,aAAa,CACjC,KAAa,EACb,OAA2C;IAE3C,MAAM,IAAI,GAAG,IAAA,gCAAY,EAAC,KAAK,CAAC,CAAC;IACjC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,kCAAiB,GAAE,CAAC;IAEvC,MAAM,MAAM,GAA2B,EAAE,CAAC;IAC1C,IAAI,OAAO,CAAC,KAAK;QAAE,MAAM,CAAC,cAAc,GAAG,OAAO,CAAC,KAAK,CAAC;IACzD,IAAI,OAAO,CAAC,KAAK;QAAE,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC;IAEhD,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,cAAc,IAAI,WAAW,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAC7E,IAAA,yBAAa,EAAC,IAAI,CAAC,IAA0C,EAAE,8BAAc,CAAC,CAAC;AACjF,CAAC"}
|
|
@@ -11,13 +11,15 @@ const auth_client_js_1 = require("../auth-client.js");
|
|
|
11
11
|
const errors_js_1 = require("../errors.js");
|
|
12
12
|
const output_js_1 = require("../output.js");
|
|
13
13
|
const formatters_js_1 = require("../formatters.js");
|
|
14
|
+
const parse_asset_id_js_1 = require("../parse-asset-id.js");
|
|
14
15
|
function csvEscape(str) {
|
|
15
16
|
if (str.includes(',') || str.includes('"') || str.includes('\n')) {
|
|
16
17
|
return `"${str.replace(/"/g, '""')}"`;
|
|
17
18
|
}
|
|
18
19
|
return str;
|
|
19
20
|
}
|
|
20
|
-
async function assetDownload(
|
|
21
|
+
async function assetDownload(input, options) {
|
|
22
|
+
const uuid = (0, parse_asset_id_js_1.parseAssetId)(input);
|
|
21
23
|
const { client } = (0, auth_client_js_1.optionalAuthClient)();
|
|
22
24
|
const { data: assetRes } = await client.get(`/v0/assets/${uuid}`);
|
|
23
25
|
const asset = assetRes.data;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"asset-download.js","sourceRoot":"","sources":["../../../src/commands/asset-download.ts"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"asset-download.js","sourceRoot":"","sources":["../../../src/commands/asset-download.ts"],"names":[],"mappings":";;;;;AAgBA,sCA0EC;AA1FD,sDAAyB;AACzB,0DAA6B;AAC7B,4DAA8B;AAC9B,sDAAuD;AACvD,4CAAwC;AACxC,4CAA6C;AAC7C,oDAAyD;AACzD,4DAAoD;AAEpD,SAAS,SAAS,CAAC,GAAW;IAC5B,IAAI,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC;QACjE,OAAO,IAAI,GAAG,CAAC,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC,GAAG,CAAC;IACxC,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC;AAEM,KAAK,UAAU,aAAa,CACjC,KAAa,EACb,OAA+D;IAE/D,MAAM,IAAI,GAAG,IAAA,gCAAY,EAAC,KAAK,CAAC,CAAC;IACjC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,mCAAkB,GAAE,CAAC;IAExC,MAAM,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,cAAc,IAAI,EAAE,CAAC,CAAC;IAClE,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC;IAE5B,IAAI,KAAK,CAAC,IAAI,KAAK,YAAY,EAA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,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;SACxF,CAAC;QACF,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC7B,QAAQ,GAAG,UAAU,CAAC;QACtB,GAAG,GAAG,KAAK,CAAC;IACd,CAAC;IAED,MAAM,QAAQ,GAAG,KAAK,CAAC,KAAK,IAAI,IAAI,CAAC;IACrC,MAAM,OAAO,GAAG,mBAAI,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,IAAI,GAAG,QAAQ,IAAI,GAAG,EAAE,CAAC,CAAC;IACrE,iBAAE,CAAC,aAAa,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;IAE5C,IAAA,yBAAa,EACX,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,CAAC,EAAE,QAAQ,EAAE,EAC3E,qCAAqB,CACtB,CAAC;AACJ,CAAC"}
|
|
@@ -4,7 +4,9 @@ exports.assetGet = assetGet;
|
|
|
4
4
|
const auth_client_js_1 = require("../auth-client.js");
|
|
5
5
|
const output_js_1 = require("../output.js");
|
|
6
6
|
const formatters_js_1 = require("../formatters.js");
|
|
7
|
-
|
|
7
|
+
const parse_asset_id_js_1 = require("../parse-asset-id.js");
|
|
8
|
+
async function assetGet(input) {
|
|
9
|
+
const uuid = (0, parse_asset_id_js_1.parseAssetId)(input);
|
|
8
10
|
const { client } = (0, auth_client_js_1.optionalAuthClient)();
|
|
9
11
|
const { data } = await client.get(`/v0/assets/${uuid}`);
|
|
10
12
|
(0, output_js_1.outputSuccess)(data.data, formatters_js_1.formatAssetMetadata);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"asset-get.js","sourceRoot":"","sources":["../../../src/commands/asset-get.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"asset-get.js","sourceRoot":"","sources":["../../../src/commands/asset-get.ts"],"names":[],"mappings":";;AAKA,4BAKC;AAVD,sDAAuD;AACvD,4CAA6C;AAC7C,oDAAuD;AACvD,4DAAoD;AAE7C,KAAK,UAAU,QAAQ,CAAC,KAAa;IAC1C,MAAM,IAAI,GAAG,IAAA,gCAAY,EAAC,KAAK,CAAC,CAAC;IACjC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,mCAAkB,GAAE,CAAC;IACxC,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,cAAc,IAAI,EAAE,CAAC,CAAC;IACxD,IAAA,yBAAa,EAAC,IAAI,CAAC,IAAI,EAAE,mCAAmB,CAAC,CAAC;AAChD,CAAC"}
|
|
@@ -4,7 +4,9 @@ exports.assetVersions = assetVersions;
|
|
|
4
4
|
const auth_client_js_1 = require("../auth-client.js");
|
|
5
5
|
const output_js_1 = require("../output.js");
|
|
6
6
|
const formatters_js_1 = require("../formatters.js");
|
|
7
|
-
|
|
7
|
+
const parse_asset_id_js_1 = require("../parse-asset-id.js");
|
|
8
|
+
async function assetVersions(input, options) {
|
|
9
|
+
const uuid = (0, parse_asset_id_js_1.parseAssetId)(input);
|
|
8
10
|
const { client } = (0, auth_client_js_1.optionalAuthClient)();
|
|
9
11
|
if (options.version) {
|
|
10
12
|
const { data } = await client.get(`/v0/assets/${uuid}/versions/${options.version}`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"asset-versions.js","sourceRoot":"","sources":["../../../src/commands/asset-versions.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"asset-versions.js","sourceRoot":"","sources":["../../../src/commands/asset-versions.ts"],"names":[],"mappings":";;AAKA,sCAcC;AAnBD,sDAAuD;AACvD,4CAA6C;AAC7C,oDAA4E;AAC5E,4DAAoD;AAE7C,KAAK,UAAU,aAAa,CACjC,KAAa,EACb,OAA6B;IAE7B,MAAM,IAAI,GAAG,IAAA,gCAAY,EAAC,KAAK,CAAC,CAAC;IACjC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,mCAAkB,GAAE,CAAC;IAExC,IAAI,OAAO,CAAC,OAAO,EAAE,CAAC;QACpB,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,cAAc,IAAI,aAAa,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC;QACpF,IAAA,yBAAa,EAAC,IAAI,CAAC,IAAI,EAAE,qCAAqB,CAAC,CAAC;IAClD,CAAC;SAAM,CAAC;QACN,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,cAAc,IAAI,WAAW,CAAC,CAAC;QACjE,IAAA,yBAAa,EAAC,IAAI,CAAC,IAA0C,EAAE,iCAAiB,CAAC,CAAC;IACpF,CAAC;AACH,CAAC"}
|