@artifactshare/cli 0.1.4 → 0.1.6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@artifactshare/cli",
3
- "version": "0.1.4",
3
+ "version": "0.1.6",
4
4
  "description": "Upload and share HTML, Markdown, folders, and static sites from terminals, AI agents, automation, and CI.",
5
5
  "homepage": "https://artifactshare.com/connect",
6
6
  "license": "Apache-2.0",
@@ -33,7 +33,7 @@
33
33
  },
34
34
  "dependencies": {
35
35
  "gunshi": "^0.33.0",
36
- "undici": "^7.24.8"
36
+ "undici": "^7.28.0"
37
37
  },
38
38
  "devDependencies": {
39
39
  "@types/node": "24.12.4",
@@ -1,23 +1,23 @@
1
1
  ---
2
2
  name: artifactshare
3
- description: Publish, update, and read back shared artifacts with the Artifact Share CLI. Use when the user asks to share an HTML/Markdown report, a static site, or other generated artifacts, or to read back or comment on a shared artifact.
3
+ description: Publish, update, and read back shared files with the Artifact Share CLI. Use when the user asks to share an HTML/Markdown report, a static site, or other generated file, or to read back or comment on a shared file.
4
4
  ---
5
5
 
6
6
  <!-- artifactshare-skill
7
- version: 5
7
+ version: 12
8
8
  managed: true
9
9
  -->
10
10
 
11
11
  # Artifact Share CLI
12
12
 
13
- Artifact Share hosts shared artifacts (HTML pages, Markdown documents, static
13
+ Artifact Share hosts shared files (HTML pages, Markdown documents, static
14
14
  sites) with versions and comments. The CLI publishes from the terminal and is
15
15
  designed for agents: every command supports `--json` with a stable contract.
16
16
 
17
17
  Run commands with `npx --yes @artifactshare/cli`. When unsure about a
18
18
  command or flag, read `npx --yes @artifactshare/cli --help` first.
19
19
 
20
- Use the CLI whenever the artifact already exists as a local file or folder.
20
+ Use the CLI whenever the file already exists locally as a file or folder.
21
21
  The remote MCP tools accept HTML or Markdown source strings; they cannot read
22
22
  paths like `/Users/.../report.html` from the user's filesystem.
23
23
 
@@ -43,23 +43,47 @@ paths like `/Users/.../report.html` from the user's filesystem.
43
43
  ## Choosing the destination
44
44
 
45
45
  1. `projects list --json` shows the projects this account can publish into; `is_default` marks the working-directory default.
46
- 2. `init --project-id <id> --json` saves a default project for the working directory.
47
- 3. `publish` resolves the destination from `--project-id`, then the saved default, then `--home` (the unfiled home destination). Without any of these it fails with `destination_required`.
46
+ 2. `projects create <name> --json` creates a project and returns `project.id` plus a `next_command` using `publish --project-id <id>`.
47
+ 3. `projects edit <id> --name "New name" --json`, `projects edit <id> --visibility private --json`, `projects edit <id> --add-email person@example.com --json`, `projects edit <id> --remove-email person@example.com --json`, `projects edit <id> --archive --json`, and `projects edit <id> --unarchive --json` change the project settings and audience.
48
+ 4. `init --project-id <id> --json` saves a default project for the working directory.
49
+ 5. `publish` resolves the destination from `--project-id`, then the saved default, then `--home` (the home destination for files not placed in a project). Without any of these it fails with `destination_required`.
50
+ 6. `edit <artifact-id-or-url> --project-id <id> --json` moves an existing file into a project; `edit <artifact-id-or-url> --home --json` moves it back home.
51
+ 7. `edit <artifact-id-or-url> --title "New title" --json`, `edit <artifact-id-or-url> --visibility private --json`, `edit <artifact-id-or-url> --grant-email person@example.com --json`, and `edit <artifact-id-or-url> --revoke-email person@example.com --json` change post-publish settings.
52
+
53
+ `edit` changes settings without adding a new version. Moving a `project`
54
+ visibility artifact home makes it `private`, because home has no project
55
+ audience. The older `move` command remains available for placement-only
56
+ automation, but prefer `edit` for new flows.
48
57
 
49
58
  ## Core commands
50
59
 
51
60
  ```bash
52
61
  npx --yes @artifactshare/cli publish ./report.html --json
53
62
  npx --yes @artifactshare/cli publish ./site-dir --project-id <id> --json
63
+ npx --yes @artifactshare/cli projects create "Client reports" --json
64
+ npx --yes @artifactshare/cli projects edit <id> --add-email viewer@example.com --json
65
+ npx --yes @artifactshare/cli edit <artifact-id-or-url> --project-id <id> --json
66
+ npx --yes @artifactshare/cli edit <artifact-id-or-url> --visibility private --grant-email viewer@example.com --json
54
67
  npx --yes @artifactshare/cli update <artifact-id-or-url> ./report.html --json
68
+ npx --yes @artifactshare/cli delete <artifact-id-or-url> --json
69
+ npx --yes @artifactshare/cli artifacts list --json
55
70
  npx --yes @artifactshare/cli artifacts get <artifact-id-or-url> --json
56
71
  npx --yes @artifactshare/cli download <artifact-id-or-url> --output ./out --json
57
72
  npx --yes @artifactshare/cli comments list <artifact-id-or-url> --json
58
73
  npx --yes @artifactshare/cli comments post <artifact-id-or-url> --body "<text>" --json
74
+ npx --yes @artifactshare/cli comments edit <artifact-id-or-url> --message-id <message-id> --body "<text>" --json
75
+ npx --yes @artifactshare/cli comments resolve <artifact-id-or-url> --thread-id <thread-id> --json
76
+ npx --yes @artifactshare/cli comments reopen <artifact-id-or-url> --thread-id <thread-id> --json
77
+ npx --yes @artifactshare/cli comments delete <artifact-id-or-url> --thread-id <thread-id> --message-id <message-id> --json
59
78
  ```
60
79
 
61
80
  - `publish` accepts a single `.html` / `.md` file or a static-site directory. The returned `share_url` is the link to give the user.
62
- - `update` adds a new version to an existing artifact; pass the same kind of input (file vs directory) it was created with.
81
+ - `update` adds a new version to an existing file; pass the same kind of input (single file vs directory) it was created with.
82
+ - `edit` changes the display title, visibility, explicit viewers, or project placement after publishing.
83
+ - `projects edit` changes a project name, description, sharing scope, audience, or archive state. Use IDs from `projects list --json`.
84
+ - `delete` permanently removes an artifact you published, including its version history. Use it only when the user explicitly asks to delete.
85
+ - Use `artifacts list --json` to find recent artifact IDs for `update`, `edit`, `move`, `delete`, `artifacts get`, or `comments list`. Filter with `--project-id <id>`, `--home`, or `--query <text>`.
86
+ - Use IDs from `comments list --json` for `comments edit`, `comments resolve`, `comments reopen`, and `comments delete`. Comment deletion cannot be undone; omit `--message-id` only when the user wants the whole thread deleted.
63
87
  - When the user gives a title, project name, or URL instead of an ID, run `resolve <value> --json` first and use the returned ID.
64
88
  - `artifacts get` reads back single-file sources (use `--offset` to continue truncated reads); `download` saves static-site bundles.
65
89
 
@@ -1,16 +1,16 @@
1
1
  ---
2
- description: Use the Artifact Share CLI to publish, update, and read back shared artifacts.
2
+ description: Use the Artifact Share CLI to publish, update, and read back shared files.
3
3
  alwaysApply: false
4
4
  ---
5
5
 
6
6
  <!-- artifactshare-skill
7
- version: 5
7
+ version: 12
8
8
  managed: true
9
9
  -->
10
10
 
11
11
  # Artifact Share CLI
12
12
 
13
- Artifact Share hosts shared artifacts (HTML pages, Markdown documents, static
13
+ Artifact Share hosts shared files (HTML pages, Markdown documents, static
14
14
  sites) with versions and comments. Use `npx --yes @artifactshare/cli` to
15
15
  publish from the terminal, and read
16
16
  `npx --yes @artifactshare/cli --help` before choosing a command.
@@ -23,8 +23,13 @@ from the user's filesystem.
23
23
  - In agents, CI, or scripts, ask the user to issue an API token at `https://artifactshare.com/settings/tokens`, then run normal commands with `ARTIFACTSHARE_TOKEN` or `--token`; do not pass API tokens to `login`.
24
24
  - To save that token as a named profile without TTY or browser login, pipe it on standard input: `printf '%s' "$TOKEN" | npx --yes @artifactshare/cli profiles import-token --profile <name> --json`. Add `--allow-plaintext-token-store` only on a trusted machine without a native token store.
25
25
  - Use `login --profile <name>` only in an interactive terminal where the user can approve the browser device flow.
26
- - Pick the destination with `projects list --json`, `init --project-id <id>`, or `--project-id`.
27
- - Publish with `publish <path> --json`; add a version with `update <artifact-id-or-url> <path> --json`.
26
+ - Pick the destination with `projects list --json`, `projects create <name> --json`, `init --project-id <id>`, or `--project-id`.
27
+ - Change project settings with `projects edit <id> --name "New name" --json`, `projects edit <id> --visibility private --json`, `projects edit <id> --add-email person@example.com --json`, `projects edit <id> --remove-email person@example.com --json`, `projects edit <id> --archive --json`, or `projects edit <id> --unarchive --json`.
28
+ - Change post-publish settings with `edit <artifact-id-or-url> --title "New title" --json`, `edit <artifact-id-or-url> --visibility private --json`, `edit <artifact-id-or-url> --grant-email person@example.com --json`, `edit <artifact-id-or-url> --revoke-email person@example.com --json`, `edit <artifact-id-or-url> --project-id <id> --json`, or `edit <artifact-id-or-url> --home --json`. Moving a `project` visibility file home makes it `private`.
29
+ - `move <artifact-id-or-url> --project-id <id> --json` and `move <artifact-id-or-url> --home --json` remain available for placement-only automation, but prefer `edit` for new flows.
30
+ - Publish with `publish <path> --json`; add a version with `update <artifact-id-or-url> <path> --json`; permanently remove an artifact only when the user explicitly asks with `delete <artifact-id-or-url> --json`.
31
+ - Find recent artifact IDs with `artifacts list --json`; filter with `--project-id <id>`, `--home`, or `--query <text>`.
28
32
  - Resolve titles, project names, and URLs to IDs with `resolve <value> --json` before writing.
29
- - Read back with `artifacts get` / `download`; comment with `comments list` / `comments post`.
33
+ - Read back with `artifacts get` / `download`; comment with `comments list` / `comments post`; use `comments edit`, `comments resolve`, `comments reopen`, and `comments delete` with IDs from `comments list`.
34
+ - Comment deletion cannot be undone. Omit `--message-id` from `comments delete` only when the user wants the whole thread deleted.
30
35
  - On `upload_not_allowed`, run `request-access --note "<why>" --json` and tell the user an operator opens publishing; do not retry in a loop.