@madewithremy/admin 0.1.26 → 0.1.27

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/dist/index.d.ts CHANGED
@@ -635,16 +635,17 @@ interface EventsTailFrame {
635
635
 
636
636
  interface EventsScopeParams {
637
637
  /**
638
- * Environment scope to inspect: `live` (default), `preview:<releaseId>`,
639
- * or `dev:<sessionId>` — publishes and subscriptions never cross scopes,
640
- * so a tunnel session's events are visible only under its `dev:` scope.
638
+ * Environment scope to inspect: `live` (the default for reads),
639
+ * `preview:<releaseId>`, or `dev:<sessionId>` — publishes and subscriptions
640
+ * never cross scopes, so a dev session's events are visible only under its
641
+ * `dev:` scope. A publish without one goes to the caller's own dev session.
641
642
  */
642
643
  scope?: string;
643
644
  }
644
645
  interface EventsPublishParams extends EventsScopeParams {
645
646
  /** Exact channel name(s) — no wildcards anywhere in app events. */
646
647
  channels: string | string[];
647
- /** The payload subscribers receive (≤32k serialized characters). */
648
+ /** The payload subscribers receive (≤256k serialized characters). */
648
649
  data: unknown;
649
650
  }
650
651
  /**
@@ -665,10 +666,13 @@ declare function channelsList(ctx: AdminContext, params?: EventsScopeParams): Pr
665
666
  * same validation, same delivery, same metering. Lets a frontend subscriber
666
667
  * be verified before the backend trigger exists.
667
668
  *
668
- * `delivered` counts live subscriber connections per published channel;
669
- * `0` is normal (nobody listening), never an error.
669
+ * Without `scope` it goes to the caller's own dev session, the preview they
670
+ * are building in; `scope: 'live'` reaches real users. The result's `scope`
671
+ * says where it went. `delivered` counts live subscriber connections per
672
+ * published channel; `0` is normal (nobody listening), never an error.
670
673
  *
671
- * @throws AdminApiError `invalid_channels` / `payload_too_large` (400).
674
+ * @throws AdminApiError `invalid_channels` / `payload_too_large` (400), and
675
+ * `no_dev_session` (400) with no `scope` when the caller has no dev session.
672
676
  * @example
673
677
  * const { delivered } = await admin.events.publish({
674
678
  * channels: 'jobs:usr_123',