@secondlayer/stacks 6.2.1 → 6.2.2

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.
@@ -1591,21 +1591,22 @@ interface AbiContract {
1591
1591
  defined_traits?: ReadonlyArray<AbiTraitDefinition>;
1592
1592
  }
1593
1593
  /**
1594
- * `<contract>::<asset-name>` — the shape a fungible/non-fungible asset filter
1595
- * takes, expressed so the compiler can check it.
1594
+ * A fungible or non-fungible asset identifier: `<contract>::<asset-name>`.
1595
+ *
1596
+ * This is the shape an asset filter takes, expressed so the compiler can check it.
1596
1597
  *
1597
1598
  * The most common mistake in this API is passing a CONTRACT ID
1598
1599
  * (`SP….sbtc-token`) where an asset identifier (`SP….sbtc-token::sbtc-token`)
1599
1600
  * belongs, and the failure mode is a query that quietly returns zero rows. The
1600
1601
  * two differ structurally by `::`, so a template-literal type catches it at the
1601
- * call site — no brand, no cast, literals just work.
1602
+ * call site. No brand, no cast, literals just work.
1602
1603
  *
1603
1604
  * A value that is only known at runtime (config, env) is not narrow enough on
1604
1605
  * purpose; run it through {@link assetId} once, which validates and narrows.
1605
1606
  *
1606
- * Wildcard patterns (Webhooks/Subgraphs-only) are admitted by the second arm — they
1607
- * are legitimately not full identifiers (`SPB.*`), and the runtime validator
1608
- * short-circuits on them for the same reason.
1607
+ * Wildcard patterns (Webhooks/Subgraphs-only) are admitted by the second arm.
1608
+ * They are legitimately not full identifiers (`SPB.*`), and the runtime
1609
+ * validator short-circuits on them for the same reason.
1609
1610
  */
1610
1611
  type AssetIdentifier = `${string}::${string}` | `${string}*${string}`;
1611
1612
  /** Scalar print field types (structural mirror of the subgraphs `ColumnType`). */
@@ -1783,6 +1784,7 @@ interface SbtcWithdrawalSweptConfirmedSpec {
1783
1784
  sweepTxid?: string;
1784
1785
  }
1785
1786
  type ChainEventFilterSpec = StxTransferSpec | StxMintSpec | StxBurnSpec | StxLockSpec | FtTransferSpec | FtMintSpec | FtBurnSpec | NftTransferSpec | NftMintSpec | NftBurnSpec | ContractCallSpec | ContractDeploySpec | NestedContractCallSpec | VarSetSpec | MapSetSpec | MapInsertSpec | MapDeleteSpec | PrintEventSpec | SbtcDepositSpec | SbtcWithdrawalCreateSpec | SbtcWithdrawalAcceptSpec | SbtcWithdrawalRejectSpec | SbtcWithdrawalSweptConfirmedSpec;
1787
+ /** The filter spec for one chain event type. */
1786
1788
  type SpecFor<T extends ChainEventFilterType> = Extract<ChainEventFilterSpec, {
1787
1789
  type: T
1788
1790
  }>;
@@ -1858,10 +1860,11 @@ type ProjectionsFor<
1858
1860
  toSubgraphSource(): S
1859
1861
  } : {});
1860
1862
  /**
1861
- * A canonical chain-event filter: the spec fields plus the projections its
1862
- * member supports. Write the filter once; project it to a query
1863
- * (`toIndexParams`), a stream (`toStreamsParams`), a webhook trigger
1864
- * (`toChainTrigger`), or a subgraph source (`toSubgraphSource`).
1863
+ * A chain-event filter: the spec fields plus its member's projections.
1864
+ *
1865
+ * Write the filter once; project it to a query (`toIndexParams`), a stream
1866
+ * (`toStreamsParams`), a webhook trigger (`toChainTrigger`), or a subgraph
1867
+ * source (`toSubgraphSource`).
1865
1868
  */
1866
1869
  type ChainEventFilter<
1867
1870
  T extends ChainEventFilterType = ChainEventFilterType,
@@ -1869,6 +1872,7 @@ type ChainEventFilter<
1869
1872
  type: T
1870
1873
  } = SpecFor<T>
1871
1874
  > = S & ProjectionsFor<T, S>;
1875
+ /** The fields a filter factory takes for one event type, without `type`. */
1872
1876
  type Fields<T extends ChainEventFilterType> = Omit<SpecFor<T>, "type">;
1873
1877
  /** The `on.*` namespace, annotated explicitly — bunup's dts emitter needs an
1874
1878
  * annotation on exported values (an inferred object of generic factories
@@ -1591,21 +1591,22 @@ interface AbiContract {
1591
1591
  defined_traits?: ReadonlyArray<AbiTraitDefinition>;
1592
1592
  }
1593
1593
  /**
1594
- * `<contract>::<asset-name>` — the shape a fungible/non-fungible asset filter
1595
- * takes, expressed so the compiler can check it.
1594
+ * A fungible or non-fungible asset identifier: `<contract>::<asset-name>`.
1595
+ *
1596
+ * This is the shape an asset filter takes, expressed so the compiler can check it.
1596
1597
  *
1597
1598
  * The most common mistake in this API is passing a CONTRACT ID
1598
1599
  * (`SP….sbtc-token`) where an asset identifier (`SP….sbtc-token::sbtc-token`)
1599
1600
  * belongs, and the failure mode is a query that quietly returns zero rows. The
1600
1601
  * two differ structurally by `::`, so a template-literal type catches it at the
1601
- * call site — no brand, no cast, literals just work.
1602
+ * call site. No brand, no cast, literals just work.
1602
1603
  *
1603
1604
  * A value that is only known at runtime (config, env) is not narrow enough on
1604
1605
  * purpose; run it through {@link assetId} once, which validates and narrows.
1605
1606
  *
1606
- * Wildcard patterns (Webhooks/Subgraphs-only) are admitted by the second arm — they
1607
- * are legitimately not full identifiers (`SPB.*`), and the runtime validator
1608
- * short-circuits on them for the same reason.
1607
+ * Wildcard patterns (Webhooks/Subgraphs-only) are admitted by the second arm.
1608
+ * They are legitimately not full identifiers (`SPB.*`), and the runtime
1609
+ * validator short-circuits on them for the same reason.
1609
1610
  */
1610
1611
  type AssetIdentifier = `${string}::${string}` | `${string}*${string}`;
1611
1612
  /** Scalar print field types (structural mirror of the subgraphs `ColumnType`). */
@@ -1783,6 +1784,7 @@ interface SbtcWithdrawalSweptConfirmedSpec {
1783
1784
  sweepTxid?: string;
1784
1785
  }
1785
1786
  type ChainEventFilterSpec = StxTransferSpec | StxMintSpec | StxBurnSpec | StxLockSpec | FtTransferSpec | FtMintSpec | FtBurnSpec | NftTransferSpec | NftMintSpec | NftBurnSpec | ContractCallSpec | ContractDeploySpec | NestedContractCallSpec | VarSetSpec | MapSetSpec | MapInsertSpec | MapDeleteSpec | PrintEventSpec | SbtcDepositSpec | SbtcWithdrawalCreateSpec | SbtcWithdrawalAcceptSpec | SbtcWithdrawalRejectSpec | SbtcWithdrawalSweptConfirmedSpec;
1787
+ /** The filter spec for one chain event type. */
1786
1788
  type SpecFor<T extends ChainEventFilterType> = Extract<ChainEventFilterSpec, {
1787
1789
  type: T
1788
1790
  }>;
@@ -1858,10 +1860,11 @@ type ProjectionsFor<
1858
1860
  toSubgraphSource(): S
1859
1861
  } : {});
1860
1862
  /**
1861
- * A canonical chain-event filter: the spec fields plus the projections its
1862
- * member supports. Write the filter once; project it to a query
1863
- * (`toIndexParams`), a stream (`toStreamsParams`), a webhook trigger
1864
- * (`toChainTrigger`), or a subgraph source (`toSubgraphSource`).
1863
+ * A chain-event filter: the spec fields plus its member's projections.
1864
+ *
1865
+ * Write the filter once; project it to a query (`toIndexParams`), a stream
1866
+ * (`toStreamsParams`), a webhook trigger (`toChainTrigger`), or a subgraph
1867
+ * source (`toSubgraphSource`).
1865
1868
  */
1866
1869
  type ChainEventFilter<
1867
1870
  T extends ChainEventFilterType = ChainEventFilterType,
@@ -1869,6 +1872,7 @@ type ChainEventFilter<
1869
1872
  type: T
1870
1873
  } = SpecFor<T>
1871
1874
  > = S & ProjectionsFor<T, S>;
1875
+ /** The fields a filter factory takes for one event type, without `type`. */
1872
1876
  type Fields<T extends ChainEventFilterType> = Omit<SpecFor<T>, "type">;
1873
1877
  /** The `on.*` namespace, annotated explicitly — bunup's dts emitter needs an
1874
1878
  * annotation on exported values (an inferred object of generic factories
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@secondlayer/stacks",
3
- "version": "6.2.1",
3
+ "version": "6.2.2",
4
4
  "description": "Typed Stacks client for TypeScript: read contracts, decode Clarity, build and send transactions.",
5
5
  "license": "MIT",
6
6
  "repository": {