@omni-commerce/cli 0.9.0 → 0.11.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/README.md +20 -1
- package/dist/index.js +2647 -131
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -4,8 +4,27 @@ Command-line client for the OmniCommerce API. Generated from the same OpenAPI sp
|
|
|
4
4
|
|
|
5
5
|
```bash
|
|
6
6
|
npm install -g @omni-commerce/cli
|
|
7
|
-
omni auth login
|
|
7
|
+
omni auth login
|
|
8
8
|
omni products list --q lamp
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
+
Login opens your browser. Sign in, confirm the terminal code, and approve an
|
|
12
|
+
organization to save credentials in `~/.omni/config.json` (mode `0600`).
|
|
13
|
+
Browser login acts as your user with your current role and store permissions,
|
|
14
|
+
including campaign approvals assigned to you. Ordinary API keys act as automation.
|
|
15
|
+
Use `omni auth login --no-browser` to open the printed URL yourself, or
|
|
16
|
+
`omni auth login --api-key omni_sk_...` to save an existing key for automation.
|
|
17
|
+
|
|
11
18
|
See the [CLI docs](https://docs.omnicommerce.sg/cli/omni-cli).
|
|
19
|
+
|
|
20
|
+
Edit campaign promotions and windows with typed flags:
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
omni campaigns update-offers --campaign-id C --expected-revision 4 --offer-ids OFFER_A,OFFER_B --discount-value 15
|
|
24
|
+
omni campaigns update-windows --campaign-id C --expected-revision 4 --window-ids WINDOW_A --ends-at 2027-08-04T00:00:00+08:00
|
|
25
|
+
omni products list --detail summary --include-summary false
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Campaign updates preserve omitted fields. Running changes remain proposals until
|
|
29
|
+
the named approver approves them. Use `--help`, `--schema`, and `--dry-run` to
|
|
30
|
+
inspect a command. Product `--detail full` preserves the existing list response.
|