@sanity/client 7.8.1 → 7.8.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.
@@ -798,6 +798,14 @@ export declare type ClientPerspective =
798
798
  | 'raw'
799
799
  | StackablePerspective[]
800
800
 
801
+ /** @public */
802
+ declare type ClientPerspective_2 =
803
+ | DeprecatedPreviewDrafts_2
804
+ | 'published'
805
+ | 'drafts'
806
+ | 'raw'
807
+ | StackablePerspective_2[]
808
+
801
809
  /** @public */
802
810
  export declare type ClientReturn<
803
811
  GroqString extends string,
@@ -1147,6 +1155,11 @@ export default deprecatedCreateClient
1147
1155
  */
1148
1156
  declare type DeprecatedPreviewDrafts = 'previewDrafts'
1149
1157
 
1158
+ /**
1159
+ * @deprecated use 'drafts' instead
1160
+ */
1161
+ declare type DeprecatedPreviewDrafts_2 = 'previewDrafts'
1162
+
1150
1163
  /**
1151
1164
  * Delete the draft version of a document.
1152
1165
  * It is an error if it does not exist. If the purge flag is set, the document history is also deleted.
@@ -1745,6 +1758,7 @@ export declare interface GroqAgentActionParam {
1745
1758
  type: 'groq'
1746
1759
  query: string
1747
1760
  params?: Record<string, string>
1761
+ perspective?: ClientPerspective_2
1748
1762
  }
1749
1763
 
1750
1764
  /**
@@ -3822,10 +3836,8 @@ export declare class ProjectsClient {
3822
3836
  declare interface PromptJsonResponse<T extends Record<string, Any> = Record<string, Any>> {
3823
3837
  /**
3824
3838
  *
3825
- * When true, the response body will be json according to the instruction.
3826
- * When false, the response is the raw text response to the instruction.
3827
- *
3828
- * Note: In addition to setting this to true, `instruction` MUST include the word 'JSON', or 'json' for this to work.
3839
+ * When format is 'json', the response will be json according to the instruction.
3840
+ * Note: In addition to setting this to 'json', `instruction` MUST include the word 'JSON', or 'json' for this to work.
3829
3841
  */
3830
3842
  format: 'json'
3831
3843
  }
@@ -3932,13 +3944,9 @@ declare interface PromptRequestBase {
3932
3944
 
3933
3945
  declare interface PromptTextResponse {
3934
3946
  /**
3935
- *
3936
- * When true, the response body will be json according to the instruction.
3937
- * When false, the response is the raw text response to the instruction.
3938
- *
3939
- * Note: In addition to setting this to true, `instruction` MUST include the word 'JSON', or 'json' for this to work.
3947
+ * When format is 'string', the response will be a raw text response to the instruction.
3940
3948
  */
3941
- format?: 'text'
3949
+ format?: 'string'
3942
3950
  }
3943
3951
 
3944
3952
  /**
@@ -5490,6 +5498,9 @@ export declare interface SingleMutationResult {
5490
5498
  /** @public */
5491
5499
  export declare type StackablePerspective = ('published' | 'drafts' | string) & {}
5492
5500
 
5501
+ /** @public */
5502
+ declare type StackablePerspective_2 = ('published' | 'drafts' | string) & {}
5503
+
5493
5504
  /** @public */
5494
5505
  export declare interface StegaConfig {
5495
5506
  /**
@@ -798,6 +798,14 @@ export declare type ClientPerspective =
798
798
  | 'raw'
799
799
  | StackablePerspective[]
800
800
 
801
+ /** @public */
802
+ declare type ClientPerspective_2 =
803
+ | DeprecatedPreviewDrafts_2
804
+ | 'published'
805
+ | 'drafts'
806
+ | 'raw'
807
+ | StackablePerspective_2[]
808
+
801
809
  /** @public */
802
810
  export declare type ClientReturn<
803
811
  GroqString extends string,
@@ -1147,6 +1155,11 @@ export default deprecatedCreateClient
1147
1155
  */
1148
1156
  declare type DeprecatedPreviewDrafts = 'previewDrafts'
1149
1157
 
1158
+ /**
1159
+ * @deprecated use 'drafts' instead
1160
+ */
1161
+ declare type DeprecatedPreviewDrafts_2 = 'previewDrafts'
1162
+
1150
1163
  /**
1151
1164
  * Delete the draft version of a document.
1152
1165
  * It is an error if it does not exist. If the purge flag is set, the document history is also deleted.
@@ -1745,6 +1758,7 @@ export declare interface GroqAgentActionParam {
1745
1758
  type: 'groq'
1746
1759
  query: string
1747
1760
  params?: Record<string, string>
1761
+ perspective?: ClientPerspective_2
1748
1762
  }
1749
1763
 
1750
1764
  /**
@@ -3822,10 +3836,8 @@ export declare class ProjectsClient {
3822
3836
  declare interface PromptJsonResponse<T extends Record<string, Any> = Record<string, Any>> {
3823
3837
  /**
3824
3838
  *
3825
- * When true, the response body will be json according to the instruction.
3826
- * When false, the response is the raw text response to the instruction.
3827
- *
3828
- * Note: In addition to setting this to true, `instruction` MUST include the word 'JSON', or 'json' for this to work.
3839
+ * When format is 'json', the response will be json according to the instruction.
3840
+ * Note: In addition to setting this to 'json', `instruction` MUST include the word 'JSON', or 'json' for this to work.
3829
3841
  */
3830
3842
  format: 'json'
3831
3843
  }
@@ -3932,13 +3944,9 @@ declare interface PromptRequestBase {
3932
3944
 
3933
3945
  declare interface PromptTextResponse {
3934
3946
  /**
3935
- *
3936
- * When true, the response body will be json according to the instruction.
3937
- * When false, the response is the raw text response to the instruction.
3938
- *
3939
- * Note: In addition to setting this to true, `instruction` MUST include the word 'JSON', or 'json' for this to work.
3947
+ * When format is 'string', the response will be a raw text response to the instruction.
3940
3948
  */
3941
- format?: 'text'
3949
+ format?: 'string'
3942
3950
  }
3943
3951
 
3944
3952
  /**
@@ -5490,6 +5498,9 @@ export declare interface SingleMutationResult {
5490
5498
  /** @public */
5491
5499
  export declare type StackablePerspective = ('published' | 'drafts' | string) & {}
5492
5500
 
5501
+ /** @public */
5502
+ declare type StackablePerspective_2 = ('published' | 'drafts' | string) & {}
5503
+
5493
5504
  /** @public */
5494
5505
  export declare interface StegaConfig {
5495
5506
  /**