@artifactshare/cli 0.1.6 → 0.1.7

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.6",
3
+ "version": "0.1.7",
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",
@@ -4,7 +4,7 @@ description: Publish, update, and read back shared files with the Artifact Share
4
4
  ---
5
5
 
6
6
  <!-- artifactshare-skill
7
- version: 12
7
+ version: 13
8
8
  managed: true
9
9
  -->
10
10
 
@@ -58,6 +58,7 @@ automation, but prefer `edit` for new flows.
58
58
  ## Core commands
59
59
 
60
60
  ```bash
61
+ npx --yes @artifactshare/cli agent open <artifact-id-or-url> --json
61
62
  npx --yes @artifactshare/cli publish ./report.html --json
62
63
  npx --yes @artifactshare/cli publish ./site-dir --project-id <id> --json
63
64
  npx --yes @artifactshare/cli projects create "Client reports" --json
@@ -77,8 +78,11 @@ npx --yes @artifactshare/cli comments reopen <artifact-id-or-url> --thread-id <t
77
78
  npx --yes @artifactshare/cli comments delete <artifact-id-or-url> --thread-id <thread-id> --message-id <message-id> --json
78
79
  ```
79
80
 
81
+ - When the user gives an Artifact Share URL, start with `agent open <artifact-id-or-url> --json`. It ensures this skill is installed or updated, then reads single-file artifacts or returns a `download` next command for static sites and multi-file artifacts.
80
82
  - `publish` accepts a single `.html` / `.md` file or a static-site directory. The returned `share_url` is the link to give the user.
81
- - `update` adds a new version to an existing file; pass the same kind of input (single file vs directory) it was created with.
83
+ - To keep an existing share URL, do not run `publish --artifact-id`; run `update <artifact-id-or-url> <path> --json` instead.
84
+ - For repeat jobs where the caller can choose a stable name, use `publish <path> --key <key> --json`: the first run creates the artifact, later runs add versions to the same artifact.
85
+ - `update` adds a new version to an existing file; pass the same kind of input (single file vs directory) it was created with. It does not change title, visibility, explicit viewers, or project placement.
82
86
  - `edit` changes the display title, visibility, explicit viewers, or project placement after publishing.
83
87
  - `projects edit` changes a project name, description, sharing scope, audience, or archive state. Use IDs from `projects list --json`.
84
88
  - `delete` permanently removes an artifact you published, including its version history. Use it only when the user explicitly asks to delete.
@@ -4,7 +4,7 @@ alwaysApply: false
4
4
  ---
5
5
 
6
6
  <!-- artifactshare-skill
7
- version: 12
7
+ version: 13
8
8
  managed: true
9
9
  -->
10
10
 
@@ -23,11 +23,14 @@ 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
+ - When the user gives an Artifact Share URL, start with `agent open <artifact-id-or-url> --json`. It ensures this rule is installed or updated, then reads single-file artifacts or returns a `download` next command for static sites and multi-file artifacts.
26
27
  - Pick the destination with `projects list --json`, `projects create <name> --json`, `init --project-id <id>`, or `--project-id`.
27
28
  - 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
29
  - 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
30
  - `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
+ - Publish with `publish <path> --json`. To keep an existing share URL, do not use `publish --artifact-id`; add a version with `update <artifact-id-or-url> <path> --json`.
32
+ - For repeat jobs with a stable caller-owned name, use `publish <path> --key <key> --json`: the first run creates the artifact, later runs add versions to the same artifact.
33
+ - Permanently remove an artifact only when the user explicitly asks with `delete <artifact-id-or-url> --json`.
31
34
  - Find recent artifact IDs with `artifacts list --json`; filter with `--project-id <id>`, `--home`, or `--query <text>`.
32
35
  - Resolve titles, project names, and URLs to IDs with `resolve <value> --json` before writing.
33
36
  - 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`.