@logbrew/sdk 0.1.34 → 0.1.35

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.
Files changed (2) hide show
  1. package/README.md +18 -0
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -252,6 +252,24 @@ const response = await client.shutdown(transport);
252
252
  console.error(JSON.stringify({ ok: true, status: response.statusCode, attempts: response.attempts, events: 6 }));
253
253
  ```
254
254
 
255
+ ## Read Events Back
256
+
257
+ A successful send shows that LogBrew accepted the request. It does not show
258
+ that you can read the event. After your app sends one event, read it
259
+ back with a project read key:
260
+
261
+ ```bash
262
+ logbrew projects keys create "<project_id>" --kind read \
263
+ --ingest-key-file "$HOME/.logbrew/setup-check.read" --json
264
+ export LOGBREW_TOKEN="$(< "$HOME/.logbrew/setup-check.read")"
265
+ logbrew read logs --since 1h --json
266
+ logbrew issues --since 1h --json
267
+ ```
268
+
269
+ A read key reads 1 project and cannot send telemetry. Run `unset LOGBREW_TOKEN`
270
+ when you finish. [Read your events back](https://docs.logbrew.co/guides/verify-setup)
271
+ covers key kinds, empty results, and how to revoke the key.
272
+
255
273
  ## Explicit Metrics
256
274
 
257
275
  Use `client.metric()` when application code already knows the measurement name, value, unit, and aggregation shape. Metrics are queued like other events and are not collected automatically.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@logbrew/sdk",
3
- "version": "0.1.34",
3
+ "version": "0.1.35",
4
4
  "description": "Public LogBrew JavaScript SDK for building, validating, and flushing event batches.",
5
5
  "type": "module",
6
6
  "main": "./index.cjs",