@medialane/sdk 0.21.0 → 0.22.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/dist/index.d.cts CHANGED
@@ -573,10 +573,21 @@ interface ApiOrder {
573
573
  updatedAt: string;
574
574
  /** Embedded token metadata (name/image/description). Null when not yet indexed. */
575
575
  token: ApiOrderTokenMeta | null;
576
- /** Set when this is a counter-offer listing — points to the original buyer bid. */
576
+ /** Set when this is a counter-offer listing — points to the original buyer bid.
577
+ * Now always emitted by the backend (was conditional); kept optional in the
578
+ * type for back-compat with older response shapes. */
577
579
  parentOrderHash?: string | null;
578
580
  /** Optional seller message accompanying a counter-offer. */
579
581
  counterOfferMessage?: string | null;
582
+ /** True when this order is a bid (ERC-20 offer) AND at least one ACTIVE counter
583
+ * exists with `parentOrderHash = this.orderHash`. Set by endpoints that compute
584
+ * it (currently `GET /v1/orders/user/:address` and `GET /v1/orders/:orderHash`);
585
+ * undefined on endpoints that don't.
586
+ *
587
+ * Use this instead of `status === "COUNTER_OFFERED"` for "this bid has been
588
+ * countered" affordances. The status pattern is being phased out per
589
+ * 01-core-model §V — counter-offers are linked orders, not a lifecycle state. */
590
+ hasActiveCounterOffer?: boolean;
580
591
  }
581
592
  /**
582
593
  * A single OpenSea-compatible ERC-721 attribute.
package/dist/index.d.ts CHANGED
@@ -573,10 +573,21 @@ interface ApiOrder {
573
573
  updatedAt: string;
574
574
  /** Embedded token metadata (name/image/description). Null when not yet indexed. */
575
575
  token: ApiOrderTokenMeta | null;
576
- /** Set when this is a counter-offer listing — points to the original buyer bid. */
576
+ /** Set when this is a counter-offer listing — points to the original buyer bid.
577
+ * Now always emitted by the backend (was conditional); kept optional in the
578
+ * type for back-compat with older response shapes. */
577
579
  parentOrderHash?: string | null;
578
580
  /** Optional seller message accompanying a counter-offer. */
579
581
  counterOfferMessage?: string | null;
582
+ /** True when this order is a bid (ERC-20 offer) AND at least one ACTIVE counter
583
+ * exists with `parentOrderHash = this.orderHash`. Set by endpoints that compute
584
+ * it (currently `GET /v1/orders/user/:address` and `GET /v1/orders/:orderHash`);
585
+ * undefined on endpoints that don't.
586
+ *
587
+ * Use this instead of `status === "COUNTER_OFFERED"` for "this bid has been
588
+ * countered" affordances. The status pattern is being phased out per
589
+ * 01-core-model §V — counter-offers are linked orders, not a lifecycle state. */
590
+ hasActiveCounterOffer?: boolean;
580
591
  }
581
592
  /**
582
593
  * A single OpenSea-compatible ERC-721 attribute.