@tokenoftrust/cli 6.13.0 → 6.13.1

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": "@tokenoftrust/cli",
3
- "version": "6.13.0",
3
+ "version": "6.13.1",
4
4
  "description": "Token of Trust developer CLI — clone a tenant store, run it locally with save→reload, and submit it for preview. Installs the `tot` command.",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Token of Trust",
@@ -125,6 +125,21 @@ the preview stage without waiting on the store owner:
125
125
  RFC-reserved recipient fixtures. Preview tokens and webhooks are isolated by the stage wall
126
126
  (`403 stage_mismatch` if used against live publication hosts).
127
127
 
128
+ ### Calling the API in test
129
+
130
+ A `test` install calls its store's preview stage at `https://storefront.tokenoftrust.store/<tenant>`.
131
+ No preview token is needed: your app's own credential selects the test stage, and it acts only on
132
+ preview data. No `Origin` header is needed; server-to-server is fine. Production installs call the
133
+ store's own live domain, never the shared host. A request with no credential gets 401
134
+ `store-not-public`.
135
+
136
+ ```bash
137
+ curl -s -X POST https://storefront.tokenoftrust.store/<tenant>/api/apps/oauth/token \
138
+ -d grant_type=client_credentials -d client_id=<clientId> -d client_secret=<clientSecret>
139
+ curl -s https://storefront.tokenoftrust.store/<tenant>/api/apps/v1/<path> \
140
+ -H "Authorization: Bearer <access_token>"
141
+ ```
142
+
128
143
  ## Going live (`private_key_jwt` candidate staging & 1-click Owner approval)
129
144
 
130
145
  1. Point `webhooks.endpoint` at your real, publicly reachable HTTPS receiver and swap the dev-only