@sanity/client 6.21.4-canary.1 → 6.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.
@@ -956,6 +956,10 @@ class LiveClient {
956
956
  throw new Error(
957
957
  "The live events API requires a token when 'includeDrafts: true'. Please update your client configuration. The token should have the lowest possible access role."
958
958
  );
959
+ if (includeDrafts && apiVersion !== "X")
960
+ throw new Error(
961
+ "The live events API requires API version X when 'includeDrafts: true'. This API is experimental and may change or even be removed."
962
+ );
959
963
  const path = _getDataUrl(this.#client, "live/events"), url = new URL(this.#client.getUrl(path, !1));
960
964
  includeDrafts && url.searchParams.set("includeDrafts", "true");
961
965
  const listenFor = ["restart", "message"], esOptions = {};