@sanity/cli 7.0.0 → 7.0.1

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.
Files changed (2) hide show
  1. package/oclif.manifest.json +687 -687
  2. package/package.json +11 -11
@@ -3779,76 +3779,20 @@
3779
3779
  "list.js"
3780
3780
  ]
3781
3781
  },
3782
- "schemas:delete": {
3782
+ "telemetry:disable": {
3783
3783
  "aliases": [],
3784
3784
  "args": {},
3785
- "description": "Delete schema documents by id",
3785
+ "description": "Disable telemetry for your account",
3786
3786
  "examples": [
3787
3787
  {
3788
- "command": "<%= config.bin %> <%= command.id %> --ids sanity.workspace.schema.workspaceName",
3789
- "description": "Delete a single schema"
3790
- },
3791
- {
3792
- "command": "<%= config.bin %> <%= command.id %> --ids sanity.workspace.schema.workspaceName,prefix.sanity.workspace.schema.otherWorkspace",
3793
- "description": "Delete multiple schemas"
3788
+ "command": "<%= config.bin %> telemetry <%= command.id %>",
3789
+ "description": "Disable telemetry for your account"
3794
3790
  }
3795
3791
  ],
3796
- "flags": {
3797
- "project-id": {
3798
- "char": "p",
3799
- "description": "Project ID to delete schema from (overrides CLI configuration)",
3800
- "helpGroup": "OVERRIDE",
3801
- "name": "project-id",
3802
- "hasDynamicHelp": false,
3803
- "helpValue": "<id>",
3804
- "multiple": false,
3805
- "type": "option"
3806
- },
3807
- "dataset": {
3808
- "char": "d",
3809
- "description": "Delete schemas from a specific dataset",
3810
- "name": "dataset",
3811
- "hasDynamicHelp": false,
3812
- "helpValue": "<name>",
3813
- "multiple": false,
3814
- "type": "option"
3815
- },
3816
- "extract-manifest": {
3817
- "description": "Generate manifest file (disable with --no-extract-manifest)",
3818
- "hidden": true,
3819
- "name": "extract-manifest",
3820
- "allowNo": true,
3821
- "type": "boolean"
3822
- },
3823
- "ids": {
3824
- "description": "Comma-separated list of schema ids to delete",
3825
- "name": "ids",
3826
- "required": true,
3827
- "hasDynamicHelp": false,
3828
- "multiple": false,
3829
- "type": "option"
3830
- },
3831
- "manifest-dir": {
3832
- "description": "Directory containing manifest file",
3833
- "hidden": true,
3834
- "name": "manifest-dir",
3835
- "default": "./dist/static",
3836
- "hasDynamicHelp": false,
3837
- "multiple": false,
3838
- "type": "option"
3839
- },
3840
- "verbose": {
3841
- "description": "Enable verbose logging",
3842
- "name": "verbose",
3843
- "allowNo": false,
3844
- "type": "boolean"
3845
- }
3846
- },
3792
+ "flags": {},
3847
3793
  "hasDynamicHelp": false,
3848
- "hiddenAliases": [
3849
- "schema:delete"
3850
- ],
3851
- "id": "schemas:delete",
3794
+ "hiddenAliases": [],
3795
+ "id": "telemetry:disable",
3852
3796
  "pluginAlias": "@sanity/cli",
3853
3797
  "pluginName": "@sanity/cli",
3854
3798
  "pluginType": "core",
@@ -3857,68 +3801,24 @@
3857
3801
  "relativePath": [
3858
3802
  "dist",
3859
3803
  "commands",
3860
- "schemas",
3861
- "delete.js"
3804
+ "telemetry",
3805
+ "disable.js"
3862
3806
  ]
3863
3807
  },
3864
- "schemas:deploy": {
3808
+ "telemetry:enable": {
3865
3809
  "aliases": [],
3866
3810
  "args": {},
3867
- "description": "Deploy schema documents into workspace datasets.\n\nNote: This command is experimental and subject to change.\n\nRegenerates a manifest file by default. To re-use an existing manifest, use --no-extract-manifest.",
3811
+ "description": "Enable telemetry for your account",
3868
3812
  "examples": [
3869
3813
  {
3870
- "command": "<%= config.bin %> <%= command.id %>",
3871
- "description": "Deploy all workspace schemas"
3872
- },
3873
- {
3874
- "command": "<%= config.bin %> <%= command.id %> --workspace default",
3875
- "description": "Deploy the schema for only the workspace \"default\""
3814
+ "command": "<%= config.bin %> telemetry <%= command.id %>",
3815
+ "description": "Enable telemetry for your account"
3876
3816
  }
3877
3817
  ],
3878
- "flags": {
3879
- "extract-manifest": {
3880
- "description": "Regenerate manifest before deploying (use --no-extract-manifest to skip)",
3881
- "name": "extract-manifest",
3882
- "allowNo": true,
3883
- "type": "boolean"
3884
- },
3885
- "manifest-dir": {
3886
- "description": "Directory containing manifest file",
3887
- "name": "manifest-dir",
3888
- "default": "./dist/static",
3889
- "hasDynamicHelp": false,
3890
- "helpValue": "<directory>",
3891
- "multiple": false,
3892
- "type": "option"
3893
- },
3894
- "tag": {
3895
- "description": "Add a tag suffix to the schema id",
3896
- "name": "tag",
3897
- "hasDynamicHelp": false,
3898
- "helpValue": "<tag>",
3899
- "multiple": false,
3900
- "type": "option"
3901
- },
3902
- "verbose": {
3903
- "description": "Print detailed information during deployment",
3904
- "name": "verbose",
3905
- "allowNo": false,
3906
- "type": "boolean"
3907
- },
3908
- "workspace": {
3909
- "description": "The name of the workspace to deploy a schema for",
3910
- "name": "workspace",
3911
- "hasDynamicHelp": false,
3912
- "helpValue": "<name>",
3913
- "multiple": false,
3914
- "type": "option"
3915
- }
3916
- },
3818
+ "flags": {},
3917
3819
  "hasDynamicHelp": false,
3918
- "hiddenAliases": [
3919
- "schema:deploy"
3920
- ],
3921
- "id": "schemas:deploy",
3820
+ "hiddenAliases": [],
3821
+ "id": "telemetry:enable",
3922
3822
  "pluginAlias": "@sanity/cli",
3923
3823
  "pluginName": "@sanity/cli",
3924
3824
  "pluginType": "core",
@@ -3927,79 +3827,24 @@
3927
3827
  "relativePath": [
3928
3828
  "dist",
3929
3829
  "commands",
3930
- "schemas",
3931
- "deploy.js"
3830
+ "telemetry",
3831
+ "enable.js"
3932
3832
  ]
3933
3833
  },
3934
- "schemas:extract": {
3834
+ "telemetry:status": {
3935
3835
  "aliases": [],
3936
3836
  "args": {},
3937
- "description": "Extract a JSON representation of a Sanity schema within a Studio context.\n\nNote: This command is experimental and subject to change.",
3837
+ "description": "Check telemetry status for your account",
3938
3838
  "examples": [
3939
3839
  {
3940
- "command": "<%= config.bin %> <%= command.id %> --workspace default",
3941
- "description": "Extracts schema types in a Sanity project with more than one workspace"
3942
- },
3943
- {
3944
- "command": "<%= config.bin %> <%= command.id %> --watch",
3945
- "description": "Watch mode - re-extract on changes"
3946
- },
3947
- {
3948
- "command": "<%= config.bin %> <%= command.id %> --watch --watch-patterns \"lib/**/*.ts\"",
3949
- "description": "Watch with custom glob patterns"
3840
+ "command": "<%= config.bin %> telemetry <%= command.id %>",
3841
+ "description": "Check telemetry status for your account"
3950
3842
  }
3951
3843
  ],
3952
- "flags": {
3953
- "enforce-required-fields": {
3954
- "description": "Makes the schema generated treat fields marked as required as non-optional",
3955
- "name": "enforce-required-fields",
3956
- "allowNo": false,
3957
- "type": "boolean"
3958
- },
3959
- "format": {
3960
- "description": "Output format (currently only groq-type-nodes)",
3961
- "name": "format",
3962
- "default": "groq-type-nodes",
3963
- "hasDynamicHelp": false,
3964
- "helpValue": "<format>",
3965
- "multiple": false,
3966
- "type": "option"
3967
- },
3968
- "path": {
3969
- "description": "Optional path to specify destination of the schema file",
3970
- "name": "path",
3971
- "hasDynamicHelp": false,
3972
- "multiple": false,
3973
- "type": "option"
3974
- },
3975
- "watch": {
3976
- "description": "Enable watch mode to re-extract schema on file changes",
3977
- "name": "watch",
3978
- "allowNo": false,
3979
- "type": "boolean"
3980
- },
3981
- "watch-patterns": {
3982
- "description": "Additional glob pattern(s) to watch (can be specified multiple times)",
3983
- "name": "watch-patterns",
3984
- "hasDynamicHelp": false,
3985
- "helpValue": "<glob>",
3986
- "multiple": true,
3987
- "type": "option"
3988
- },
3989
- "workspace": {
3990
- "description": "The name of the workspace to generate a schema for",
3991
- "name": "workspace",
3992
- "hasDynamicHelp": false,
3993
- "helpValue": "<name>",
3994
- "multiple": false,
3995
- "type": "option"
3996
- }
3997
- },
3844
+ "flags": {},
3998
3845
  "hasDynamicHelp": false,
3999
- "hiddenAliases": [
4000
- "schema:extract"
4001
- ],
4002
- "id": "schemas:extract",
3846
+ "hiddenAliases": [],
3847
+ "id": "telemetry:status",
4003
3848
  "pluginAlias": "@sanity/cli",
4004
3849
  "pluginName": "@sanity/cli",
4005
3850
  "pluginType": "core",
@@ -4008,151 +3853,80 @@
4008
3853
  "relativePath": [
4009
3854
  "dist",
4010
3855
  "commands",
4011
- "schemas",
4012
- "extract.js"
3856
+ "telemetry",
3857
+ "status.js"
4013
3858
  ]
4014
3859
  },
4015
- "schemas:list": {
3860
+ "tokens:add": {
4016
3861
  "aliases": [],
4017
- "args": {},
4018
- "description": "List all schemas in the current dataset.\n\nNote: This command is experimental and subject to change.\n\nRegenerates a manifest file by default. To reuse an existing manifest, use --no-extract-manifest.",
3862
+ "args": {
3863
+ "label": {
3864
+ "description": "Label for the new token",
3865
+ "name": "label",
3866
+ "required": false
3867
+ }
3868
+ },
3869
+ "description": "Create a new API token for the project",
4019
3870
  "examples": [
4020
3871
  {
4021
- "command": "<%= config.bin %> <%= command.id %>",
4022
- "description": "List all schemas found in any workspace dataset in a table"
3872
+ "command": "<%= config.bin %> <%= command.id %> \"My API Token\"",
3873
+ "description": "Create a token with a label"
4023
3874
  },
4024
3875
  {
4025
- "command": "<%= config.bin %> <%= command.id %> --id _.schemas.workspaceName",
4026
- "description": "Get a schema for a given id"
3876
+ "command": "<%= config.bin %> <%= command.id %> \"My API Token\" --role=editor",
3877
+ "description": "Create a token with editor role"
4027
3878
  },
4028
3879
  {
4029
- "command": "<%= config.bin %> <%= command.id %> --json",
4030
- "description": "Get stored schemas as pretty-printed json-array"
3880
+ "command": "<%= config.bin %> <%= command.id %> \"CI Token\" --role=editor --yes",
3881
+ "description": "Create a token in unattended mode"
4031
3882
  },
4032
3883
  {
4033
- "command": "<%= config.bin %> <%= command.id %> --json --id _.schemas.workspaceName",
4034
- "description": "Get singular stored schema as pretty-printed json-object"
3884
+ "command": "<%= config.bin %> <%= command.id %> \"API Token\" --json",
3885
+ "description": "Output token information as JSON"
3886
+ },
3887
+ {
3888
+ "command": "<%= config.bin %> <%= command.id %> \"My Token\" --project-id abc123 --role=editor",
3889
+ "description": "Create a token for a specific project"
4035
3890
  }
4036
3891
  ],
4037
3892
  "flags": {
4038
- "extract-manifest": {
4039
- "description": "Regenerate manifest before listing (use --no-extract-manifest to skip)",
4040
- "hidden": true,
4041
- "name": "extract-manifest",
4042
- "allowNo": true,
4043
- "type": "boolean"
4044
- },
4045
- "id": {
4046
- "description": "Fetch a single schema by id",
4047
- "name": "id",
3893
+ "project-id": {
3894
+ "char": "p",
3895
+ "description": "Project ID to add token to (overrides CLI configuration)",
3896
+ "helpGroup": "OVERRIDE",
3897
+ "name": "project-id",
4048
3898
  "hasDynamicHelp": false,
4049
- "helpValue": "<schema_id>",
3899
+ "helpValue": "<id>",
4050
3900
  "multiple": false,
4051
3901
  "type": "option"
4052
3902
  },
4053
3903
  "json": {
4054
- "description": "Get schema as json",
3904
+ "description": "Output as JSON",
4055
3905
  "name": "json",
4056
3906
  "allowNo": false,
4057
3907
  "type": "boolean"
4058
- },
4059
- "manifest-dir": {
4060
- "description": "Directory containing manifest file",
4061
- "hidden": true,
4062
- "name": "manifest-dir",
4063
- "default": "./dist/static",
4064
- "hasDynamicHelp": false,
4065
- "helpValue": "<directory>",
4066
- "multiple": false,
4067
- "type": "option"
4068
- }
4069
- },
4070
- "hasDynamicHelp": false,
4071
- "hiddenAliases": [
4072
- "schema:list"
4073
- ],
4074
- "id": "schemas:list",
4075
- "pluginAlias": "@sanity/cli",
4076
- "pluginName": "@sanity/cli",
4077
- "pluginType": "core",
4078
- "strict": true,
4079
- "isESM": true,
4080
- "relativePath": [
4081
- "dist",
4082
- "commands",
4083
- "schemas",
4084
- "list.js"
4085
- ]
4086
- },
4087
- "schemas:validate": {
4088
- "aliases": [],
4089
- "args": {},
4090
- "description": "Validates all schema types specified in a workspace",
4091
- "examples": [
4092
- {
4093
- "command": "<%= config.bin %> <%= command.id %> --workspace default",
4094
- "description": "Validates all schema types in a Sanity project with more than one workspace"
4095
- },
4096
- {
4097
- "command": "<%= config.bin %> <%= command.id %> > report.txt",
4098
- "description": "Save the results of the report into a file"
4099
- },
4100
- {
4101
- "command": "<%= config.bin %> <%= command.id %> --level error",
4102
- "description": "Report out only errors"
4103
- },
4104
- {
4105
- "command": "<%= config.bin %> <%= command.id %> --debug-metafile-path metafile.json",
4106
- "description": "Generate a report which can be analyzed with https://esbuild.github.io/analyze/"
4107
- }
4108
- ],
4109
- "flags": {
4110
- "debug-metafile-path": {
4111
- "description": "Optional path where a metafile will be written for build analysis. Only written on successful validation. Can be analyzed at https://esbuild.github.io/analyze/",
4112
- "helpGroup": "DEBUG",
4113
- "name": "debug-metafile-path",
4114
- "hasDynamicHelp": false,
4115
- "multiple": false,
4116
- "type": "option"
4117
- },
4118
- "format": {
4119
- "description": "The output format used to print schema errors and warnings",
4120
- "name": "format",
4121
- "default": "pretty",
4122
- "hasDynamicHelp": false,
4123
- "multiple": false,
4124
- "options": [
4125
- "pretty",
4126
- "ndjson",
4127
- "json"
4128
- ],
4129
- "type": "option"
4130
- },
4131
- "level": {
4132
- "description": "The minimum level reported out",
4133
- "name": "level",
4134
- "default": "warning",
4135
- "hasDynamicHelp": false,
4136
- "multiple": false,
4137
- "options": [
4138
- "error",
4139
- "warning"
4140
- ],
4141
- "type": "option"
4142
- },
4143
- "workspace": {
4144
- "description": "The name of the workspace to use when validating all schema types",
4145
- "name": "workspace",
3908
+ },
3909
+ "role": {
3910
+ "description": "Role to assign to the token",
3911
+ "name": "role",
4146
3912
  "hasDynamicHelp": false,
3913
+ "helpValue": "viewer",
4147
3914
  "multiple": false,
4148
3915
  "type": "option"
3916
+ },
3917
+ "yes": {
3918
+ "char": "y",
3919
+ "description": "Skip prompts and use defaults (unattended mode)",
3920
+ "name": "yes",
3921
+ "allowNo": false,
3922
+ "type": "boolean"
4149
3923
  }
4150
3924
  },
4151
3925
  "hasDynamicHelp": false,
4152
3926
  "hiddenAliases": [
4153
- "schema:validate"
3927
+ "token:add"
4154
3928
  ],
4155
- "id": "schemas:validate",
3929
+ "id": "tokens:add",
4156
3930
  "pluginAlias": "@sanity/cli",
4157
3931
  "pluginName": "@sanity/cli",
4158
3932
  "pluginType": "core",
@@ -4161,24 +3935,65 @@
4161
3935
  "relativePath": [
4162
3936
  "dist",
4163
3937
  "commands",
4164
- "schemas",
4165
- "validate.js"
3938
+ "tokens",
3939
+ "add.js"
4166
3940
  ]
4167
3941
  },
4168
- "telemetry:disable": {
3942
+ "tokens:delete": {
4169
3943
  "aliases": [],
4170
- "args": {},
4171
- "description": "Disable telemetry for your account",
3944
+ "args": {
3945
+ "tokenId": {
3946
+ "description": "Token ID to delete (will prompt if not provided)",
3947
+ "name": "tokenId",
3948
+ "required": false
3949
+ }
3950
+ },
3951
+ "description": "Delete an API token from the project",
4172
3952
  "examples": [
4173
3953
  {
4174
- "command": "<%= config.bin %> telemetry <%= command.id %>",
4175
- "description": "Disable telemetry for your account"
3954
+ "command": "<%= config.bin %> <%= command.id %>",
3955
+ "description": "Interactively select and delete a token"
3956
+ },
3957
+ {
3958
+ "command": "<%= config.bin %> <%= command.id %> silJ2lFmK6dONB",
3959
+ "description": "Delete a specific token by ID"
3960
+ },
3961
+ {
3962
+ "command": "<%= config.bin %> <%= command.id %> silJ2lFmK6dONB --yes",
3963
+ "description": "Delete a specific token without confirmation prompt"
3964
+ },
3965
+ {
3966
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
3967
+ "description": "Delete a token from a specific project"
4176
3968
  }
4177
3969
  ],
4178
- "flags": {},
3970
+ "flags": {
3971
+ "project-id": {
3972
+ "char": "p",
3973
+ "description": "Project ID to delete token from (overrides CLI configuration)",
3974
+ "helpGroup": "OVERRIDE",
3975
+ "name": "project-id",
3976
+ "hasDynamicHelp": false,
3977
+ "helpValue": "<id>",
3978
+ "multiple": false,
3979
+ "type": "option"
3980
+ },
3981
+ "yes": {
3982
+ "aliases": [
3983
+ "y"
3984
+ ],
3985
+ "description": "Skip confirmation prompt (unattended mode)",
3986
+ "name": "yes",
3987
+ "required": false,
3988
+ "allowNo": false,
3989
+ "type": "boolean"
3990
+ }
3991
+ },
4179
3992
  "hasDynamicHelp": false,
4180
- "hiddenAliases": [],
4181
- "id": "telemetry:disable",
3993
+ "hiddenAliases": [
3994
+ "token:delete"
3995
+ ],
3996
+ "id": "tokens:delete",
4182
3997
  "pluginAlias": "@sanity/cli",
4183
3998
  "pluginName": "@sanity/cli",
4184
3999
  "pluginType": "core",
@@ -4187,24 +4002,51 @@
4187
4002
  "relativePath": [
4188
4003
  "dist",
4189
4004
  "commands",
4190
- "telemetry",
4191
- "disable.js"
4005
+ "tokens",
4006
+ "delete.js"
4192
4007
  ]
4193
4008
  },
4194
- "telemetry:enable": {
4009
+ "tokens:list": {
4195
4010
  "aliases": [],
4196
4011
  "args": {},
4197
- "description": "Enable telemetry for your account",
4012
+ "description": "List API tokens for the project",
4198
4013
  "examples": [
4199
4014
  {
4200
- "command": "<%= config.bin %> telemetry <%= command.id %>",
4201
- "description": "Enable telemetry for your account"
4015
+ "command": "<%= config.bin %> <%= command.id %>",
4016
+ "description": "List tokens for the project"
4017
+ },
4018
+ {
4019
+ "command": "<%= config.bin %> <%= command.id %> --json",
4020
+ "description": "List tokens in JSON format"
4021
+ },
4022
+ {
4023
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4024
+ "description": "List tokens for a specific project"
4202
4025
  }
4203
4026
  ],
4204
- "flags": {},
4027
+ "flags": {
4028
+ "project-id": {
4029
+ "char": "p",
4030
+ "description": "Project ID to list tokens for (overrides CLI configuration)",
4031
+ "helpGroup": "OVERRIDE",
4032
+ "name": "project-id",
4033
+ "hasDynamicHelp": false,
4034
+ "helpValue": "<id>",
4035
+ "multiple": false,
4036
+ "type": "option"
4037
+ },
4038
+ "json": {
4039
+ "description": "Output tokens in JSON format",
4040
+ "name": "json",
4041
+ "allowNo": false,
4042
+ "type": "boolean"
4043
+ }
4044
+ },
4205
4045
  "hasDynamicHelp": false,
4206
- "hiddenAliases": [],
4207
- "id": "telemetry:enable",
4046
+ "hiddenAliases": [
4047
+ "token:list"
4048
+ ],
4049
+ "id": "tokens:list",
4208
4050
  "pluginAlias": "@sanity/cli",
4209
4051
  "pluginName": "@sanity/cli",
4210
4052
  "pluginType": "core",
@@ -4213,24 +4055,63 @@
4213
4055
  "relativePath": [
4214
4056
  "dist",
4215
4057
  "commands",
4216
- "telemetry",
4217
- "enable.js"
4058
+ "tokens",
4059
+ "list.js"
4218
4060
  ]
4219
4061
  },
4220
- "telemetry:status": {
4062
+ "users:invite": {
4221
4063
  "aliases": [],
4222
- "args": {},
4223
- "description": "Check telemetry status for your account",
4064
+ "args": {
4065
+ "email": {
4066
+ "description": "Email address to invite",
4067
+ "name": "email",
4068
+ "required": false
4069
+ }
4070
+ },
4071
+ "description": "Invite a new user to the project",
4224
4072
  "examples": [
4225
4073
  {
4226
- "command": "<%= config.bin %> telemetry <%= command.id %>",
4227
- "description": "Check telemetry status for your account"
4074
+ "command": "<%= config.bin %> <%= command.id %>",
4075
+ "description": "Invite a new user to the project (prompt for details)"
4076
+ },
4077
+ {
4078
+ "command": "<%= config.bin %> <%= command.id %> pippi@sanity.io",
4079
+ "description": "Send a new user invite to the email \"pippi@sanity.io\", prompt for role"
4080
+ },
4081
+ {
4082
+ "command": "<%= config.bin %> <%= command.id %> pippi@sanity.io --role administrator",
4083
+ "description": "Send a new user invite to the email \"pippi@sanity.io\", as administrator"
4084
+ },
4085
+ {
4086
+ "command": "<%= config.bin %> <%= command.id %> pippi@sanity.io --project-id abc123",
4087
+ "description": "Invite a user to a specific project"
4228
4088
  }
4229
4089
  ],
4230
- "flags": {},
4090
+ "flags": {
4091
+ "project-id": {
4092
+ "char": "p",
4093
+ "description": "Project ID to invite user to (overrides CLI configuration)",
4094
+ "helpGroup": "OVERRIDE",
4095
+ "name": "project-id",
4096
+ "hasDynamicHelp": false,
4097
+ "helpValue": "<id>",
4098
+ "multiple": false,
4099
+ "type": "option"
4100
+ },
4101
+ "role": {
4102
+ "description": "Role to invite the user as",
4103
+ "name": "role",
4104
+ "required": false,
4105
+ "hasDynamicHelp": false,
4106
+ "multiple": false,
4107
+ "type": "option"
4108
+ }
4109
+ },
4231
4110
  "hasDynamicHelp": false,
4232
- "hiddenAliases": [],
4233
- "id": "telemetry:status",
4111
+ "hiddenAliases": [
4112
+ "user:invite"
4113
+ ],
4114
+ "id": "users:invite",
4234
4115
  "pluginAlias": "@sanity/cli",
4235
4116
  "pluginName": "@sanity/cli",
4236
4117
  "pluginType": "core",
@@ -4239,46 +4120,36 @@
4239
4120
  "relativePath": [
4240
4121
  "dist",
4241
4122
  "commands",
4242
- "telemetry",
4243
- "status.js"
4123
+ "users",
4124
+ "invite.js"
4244
4125
  ]
4245
4126
  },
4246
- "tokens:add": {
4127
+ "users:list": {
4247
4128
  "aliases": [],
4248
- "args": {
4249
- "label": {
4250
- "description": "Label for the new token",
4251
- "name": "label",
4252
- "required": false
4253
- }
4254
- },
4255
- "description": "Create a new API token for the project",
4129
+ "args": {},
4130
+ "description": "List project members",
4256
4131
  "examples": [
4257
4132
  {
4258
- "command": "<%= config.bin %> <%= command.id %> \"My API Token\"",
4259
- "description": "Create a token with a label"
4260
- },
4261
- {
4262
- "command": "<%= config.bin %> <%= command.id %> \"My API Token\" --role=editor",
4263
- "description": "Create a token with editor role"
4133
+ "command": "<%= config.bin %> <%= command.id %>",
4134
+ "description": "List all users of the project"
4264
4135
  },
4265
4136
  {
4266
- "command": "<%= config.bin %> <%= command.id %> \"CI Token\" --role=editor --yes",
4267
- "description": "Create a token in unattended mode"
4137
+ "command": "<%= config.bin %> <%= command.id %> --no-invitations --no-robots",
4138
+ "description": "List all users of the project, but exclude pending invitations and robots"
4268
4139
  },
4269
4140
  {
4270
- "command": "<%= config.bin %> <%= command.id %> \"API Token\" --json",
4271
- "description": "Output token information as JSON"
4141
+ "command": "<%= config.bin %> <%= command.id %> --sort role",
4142
+ "description": "List all users, sorted by role"
4272
4143
  },
4273
4144
  {
4274
- "command": "<%= config.bin %> <%= command.id %> \"My Token\" --project-id abc123 --role=editor",
4275
- "description": "Create a token for a specific project"
4145
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4146
+ "description": "List users for a specific project"
4276
4147
  }
4277
4148
  ],
4278
4149
  "flags": {
4279
4150
  "project-id": {
4280
4151
  "char": "p",
4281
- "description": "Project ID to add token to (overrides CLI configuration)",
4152
+ "description": "Project ID to list users for (overrides CLI configuration)",
4282
4153
  "helpGroup": "OVERRIDE",
4283
4154
  "name": "project-id",
4284
4155
  "hasDynamicHelp": false,
@@ -4286,33 +4157,50 @@
4286
4157
  "multiple": false,
4287
4158
  "type": "option"
4288
4159
  },
4289
- "json": {
4290
- "description": "Output as JSON",
4291
- "name": "json",
4292
- "allowNo": false,
4160
+ "invitations": {
4161
+ "description": "Includes or excludes pending invitations",
4162
+ "name": "invitations",
4163
+ "allowNo": true,
4293
4164
  "type": "boolean"
4294
4165
  },
4295
- "role": {
4296
- "description": "Role to assign to the token",
4297
- "name": "role",
4166
+ "order": {
4167
+ "description": "Sort output ascending/descending",
4168
+ "name": "order",
4169
+ "default": "asc",
4170
+ "hasDynamicHelp": false,
4171
+ "multiple": false,
4172
+ "options": [
4173
+ "asc",
4174
+ "desc"
4175
+ ],
4176
+ "type": "option"
4177
+ },
4178
+ "robots": {
4179
+ "description": "Includes or excludes robots (token users)",
4180
+ "name": "robots",
4181
+ "allowNo": true,
4182
+ "type": "boolean"
4183
+ },
4184
+ "sort": {
4185
+ "description": "Sort users by specified column",
4186
+ "name": "sort",
4187
+ "default": "date",
4298
4188
  "hasDynamicHelp": false,
4299
- "helpValue": "viewer",
4300
4189
  "multiple": false,
4190
+ "options": [
4191
+ "id",
4192
+ "name",
4193
+ "role",
4194
+ "date"
4195
+ ],
4301
4196
  "type": "option"
4302
- },
4303
- "yes": {
4304
- "char": "y",
4305
- "description": "Skip prompts and use defaults (unattended mode)",
4306
- "name": "yes",
4307
- "allowNo": false,
4308
- "type": "boolean"
4309
4197
  }
4310
4198
  },
4311
4199
  "hasDynamicHelp": false,
4312
4200
  "hiddenAliases": [
4313
- "token:add"
4201
+ "user:list"
4314
4202
  ],
4315
- "id": "tokens:add",
4203
+ "id": "users:list",
4316
4204
  "pluginAlias": "@sanity/cli",
4317
4205
  "pluginName": "@sanity/cli",
4318
4206
  "pluginType": "core",
@@ -4321,65 +4209,60 @@
4321
4209
  "relativePath": [
4322
4210
  "dist",
4323
4211
  "commands",
4324
- "tokens",
4325
- "add.js"
4212
+ "users",
4213
+ "list.js"
4326
4214
  ]
4327
4215
  },
4328
- "tokens:delete": {
4216
+ "datasets:alias:create": {
4329
4217
  "aliases": [],
4330
4218
  "args": {
4331
- "tokenId": {
4332
- "description": "Token ID to delete (will prompt if not provided)",
4333
- "name": "tokenId",
4219
+ "aliasName": {
4220
+ "description": "Dataset alias name to create",
4221
+ "name": "aliasName",
4222
+ "required": false
4223
+ },
4224
+ "targetDataset": {
4225
+ "description": "Target dataset name to link the alias to",
4226
+ "name": "targetDataset",
4334
4227
  "required": false
4335
4228
  }
4336
4229
  },
4337
- "description": "Delete an API token from the project",
4230
+ "description": "Create a dataset alias for the project",
4338
4231
  "examples": [
4339
4232
  {
4340
- "command": "<%= config.bin %> <%= command.id %>",
4341
- "description": "Interactively select and delete a token"
4233
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123 conference conf-2025",
4234
+ "description": "Create alias in a specific project"
4342
4235
  },
4343
4236
  {
4344
- "command": "<%= config.bin %> <%= command.id %> silJ2lFmK6dONB",
4345
- "description": "Delete a specific token by ID"
4237
+ "command": "<%= config.bin %> <%= command.id %>",
4238
+ "description": "Create an alias with interactive prompts"
4346
4239
  },
4347
4240
  {
4348
- "command": "<%= config.bin %> <%= command.id %> silJ2lFmK6dONB --yes",
4349
- "description": "Delete a specific token without confirmation prompt"
4241
+ "command": "<%= config.bin %> <%= command.id %> conference",
4242
+ "description": "Create alias named \"conference\" with interactive dataset selection"
4350
4243
  },
4351
4244
  {
4352
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4353
- "description": "Delete a token from a specific project"
4245
+ "command": "<%= config.bin %> <%= command.id %> conference conf-2025",
4246
+ "description": "Create alias \"conference\" linked to \"conf-2025\" dataset"
4354
4247
  }
4355
4248
  ],
4356
4249
  "flags": {
4357
4250
  "project-id": {
4358
4251
  "char": "p",
4359
- "description": "Project ID to delete token from (overrides CLI configuration)",
4252
+ "description": "Project ID to create dataset alias in (overrides CLI configuration)",
4360
4253
  "helpGroup": "OVERRIDE",
4361
4254
  "name": "project-id",
4362
4255
  "hasDynamicHelp": false,
4363
4256
  "helpValue": "<id>",
4364
4257
  "multiple": false,
4365
4258
  "type": "option"
4366
- },
4367
- "yes": {
4368
- "aliases": [
4369
- "y"
4370
- ],
4371
- "description": "Skip confirmation prompt (unattended mode)",
4372
- "name": "yes",
4373
- "required": false,
4374
- "allowNo": false,
4375
- "type": "boolean"
4376
4259
  }
4377
4260
  },
4378
4261
  "hasDynamicHelp": false,
4379
4262
  "hiddenAliases": [
4380
- "token:delete"
4263
+ "dataset:alias:create"
4381
4264
  ],
4382
- "id": "tokens:delete",
4265
+ "id": "datasets:alias:create",
4383
4266
  "pluginAlias": "@sanity/cli",
4384
4267
  "pluginName": "@sanity/cli",
4385
4268
  "pluginType": "core",
@@ -4388,32 +4271,35 @@
4388
4271
  "relativePath": [
4389
4272
  "dist",
4390
4273
  "commands",
4391
- "tokens",
4392
- "delete.js"
4274
+ "datasets",
4275
+ "alias",
4276
+ "create.js"
4393
4277
  ]
4394
4278
  },
4395
- "tokens:list": {
4279
+ "datasets:alias:delete": {
4396
4280
  "aliases": [],
4397
- "args": {},
4398
- "description": "List API tokens for the project",
4281
+ "args": {
4282
+ "aliasName": {
4283
+ "description": "Dataset alias name to delete",
4284
+ "name": "aliasName",
4285
+ "required": true
4286
+ }
4287
+ },
4288
+ "description": "Delete a dataset alias from the project",
4399
4289
  "examples": [
4400
4290
  {
4401
- "command": "<%= config.bin %> <%= command.id %>",
4402
- "description": "List tokens for the project"
4403
- },
4404
- {
4405
- "command": "<%= config.bin %> <%= command.id %> --json",
4406
- "description": "List tokens in JSON format"
4291
+ "command": "<%= config.bin %> <%= command.id %> conference",
4292
+ "description": "Delete alias named \"conference\" with confirmation prompt"
4407
4293
  },
4408
4294
  {
4409
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4410
- "description": "List tokens for a specific project"
4295
+ "command": "<%= config.bin %> <%= command.id %> conference --force",
4296
+ "description": "Delete alias named \"conference\" without confirmation prompt"
4411
4297
  }
4412
4298
  ],
4413
4299
  "flags": {
4414
4300
  "project-id": {
4415
4301
  "char": "p",
4416
- "description": "Project ID to list tokens for (overrides CLI configuration)",
4302
+ "description": "Project ID to delete dataset alias from (overrides CLI configuration)",
4417
4303
  "helpGroup": "OVERRIDE",
4418
4304
  "name": "project-id",
4419
4305
  "hasDynamicHelp": false,
@@ -4421,18 +4307,19 @@
4421
4307
  "multiple": false,
4422
4308
  "type": "option"
4423
4309
  },
4424
- "json": {
4425
- "description": "Output tokens in JSON format",
4426
- "name": "json",
4310
+ "force": {
4311
+ "description": "Skip confirmation prompt and delete immediately",
4312
+ "name": "force",
4313
+ "required": false,
4427
4314
  "allowNo": false,
4428
4315
  "type": "boolean"
4429
4316
  }
4430
4317
  },
4431
4318
  "hasDynamicHelp": false,
4432
4319
  "hiddenAliases": [
4433
- "token:list"
4320
+ "dataset:alias:delete"
4434
4321
  ],
4435
- "id": "tokens:list",
4322
+ "id": "datasets:alias:delete",
4436
4323
  "pluginAlias": "@sanity/cli",
4437
4324
  "pluginName": "@sanity/cli",
4438
4325
  "pluginType": "core",
@@ -4441,42 +4328,48 @@
4441
4328
  "relativePath": [
4442
4329
  "dist",
4443
4330
  "commands",
4444
- "tokens",
4445
- "list.js"
4331
+ "datasets",
4332
+ "alias",
4333
+ "delete.js"
4446
4334
  ]
4447
4335
  },
4448
- "users:invite": {
4336
+ "datasets:alias:link": {
4449
4337
  "aliases": [],
4450
4338
  "args": {
4451
- "email": {
4452
- "description": "Email address to invite",
4453
- "name": "email",
4339
+ "aliasName": {
4340
+ "description": "Dataset alias name to link",
4341
+ "name": "aliasName",
4342
+ "required": false
4343
+ },
4344
+ "targetDataset": {
4345
+ "description": "Target dataset name to link the alias to",
4346
+ "name": "targetDataset",
4454
4347
  "required": false
4455
4348
  }
4456
4349
  },
4457
- "description": "Invite a new user to the project",
4350
+ "description": "Link a dataset alias to a dataset in the project",
4458
4351
  "examples": [
4459
4352
  {
4460
4353
  "command": "<%= config.bin %> <%= command.id %>",
4461
- "description": "Invite a new user to the project (prompt for details)"
4354
+ "description": "Link an alias with interactive prompts"
4462
4355
  },
4463
4356
  {
4464
- "command": "<%= config.bin %> <%= command.id %> pippi@sanity.io",
4465
- "description": "Send a new user invite to the email \"pippi@sanity.io\", prompt for role"
4357
+ "command": "<%= config.bin %> <%= command.id %> conference",
4358
+ "description": "Link alias named \"conference\" with interactive dataset selection"
4466
4359
  },
4467
4360
  {
4468
- "command": "<%= config.bin %> <%= command.id %> pippi@sanity.io --role administrator",
4469
- "description": "Send a new user invite to the email \"pippi@sanity.io\", as administrator"
4361
+ "command": "<%= config.bin %> <%= command.id %> conference conf-2025",
4362
+ "description": "Link alias \"conference\" to \"conf-2025\" dataset"
4470
4363
  },
4471
4364
  {
4472
- "command": "<%= config.bin %> <%= command.id %> pippi@sanity.io --project-id abc123",
4473
- "description": "Invite a user to a specific project"
4365
+ "command": "<%= config.bin %> <%= command.id %> conference conf-2025 --force",
4366
+ "description": "Force link without confirmation (skip relink prompt)"
4474
4367
  }
4475
4368
  ],
4476
4369
  "flags": {
4477
4370
  "project-id": {
4478
4371
  "char": "p",
4479
- "description": "Project ID to invite user to (overrides CLI configuration)",
4372
+ "description": "Project ID to link dataset alias in (overrides CLI configuration)",
4480
4373
  "helpGroup": "OVERRIDE",
4481
4374
  "name": "project-id",
4482
4375
  "hasDynamicHelp": false,
@@ -4484,20 +4377,19 @@
4484
4377
  "multiple": false,
4485
4378
  "type": "option"
4486
4379
  },
4487
- "role": {
4488
- "description": "Role to invite the user as",
4489
- "name": "role",
4380
+ "force": {
4381
+ "description": "Skip confirmation prompt when relinking existing alias",
4382
+ "name": "force",
4490
4383
  "required": false,
4491
- "hasDynamicHelp": false,
4492
- "multiple": false,
4493
- "type": "option"
4384
+ "allowNo": false,
4385
+ "type": "boolean"
4494
4386
  }
4495
4387
  },
4496
4388
  "hasDynamicHelp": false,
4497
4389
  "hiddenAliases": [
4498
- "user:invite"
4390
+ "dataset:alias:link"
4499
4391
  ],
4500
- "id": "users:invite",
4392
+ "id": "datasets:alias:link",
4501
4393
  "pluginAlias": "@sanity/cli",
4502
4394
  "pluginName": "@sanity/cli",
4503
4395
  "pluginType": "core",
@@ -4506,36 +4398,39 @@
4506
4398
  "relativePath": [
4507
4399
  "dist",
4508
4400
  "commands",
4509
- "users",
4510
- "invite.js"
4401
+ "datasets",
4402
+ "alias",
4403
+ "link.js"
4511
4404
  ]
4512
4405
  },
4513
- "users:list": {
4406
+ "datasets:alias:unlink": {
4514
4407
  "aliases": [],
4515
- "args": {},
4516
- "description": "List project members",
4408
+ "args": {
4409
+ "aliasName": {
4410
+ "description": "Dataset alias name to unlink",
4411
+ "name": "aliasName",
4412
+ "required": false
4413
+ }
4414
+ },
4415
+ "description": "Unlink a dataset alias from its dataset in the project",
4517
4416
  "examples": [
4518
4417
  {
4519
4418
  "command": "<%= config.bin %> <%= command.id %>",
4520
- "description": "List all users of the project"
4521
- },
4522
- {
4523
- "command": "<%= config.bin %> <%= command.id %> --no-invitations --no-robots",
4524
- "description": "List all users of the project, but exclude pending invitations and robots"
4419
+ "description": "Unlink an alias with interactive selection"
4525
4420
  },
4526
4421
  {
4527
- "command": "<%= config.bin %> <%= command.id %> --sort role",
4528
- "description": "List all users, sorted by role"
4422
+ "command": "<%= config.bin %> <%= command.id %> conference",
4423
+ "description": "Unlink alias \"conference\" with confirmation prompt"
4529
4424
  },
4530
4425
  {
4531
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4532
- "description": "List users for a specific project"
4426
+ "command": "<%= config.bin %> <%= command.id %> conference --force",
4427
+ "description": "Unlink alias \"conference\" without confirmation prompt"
4533
4428
  }
4534
4429
  ],
4535
4430
  "flags": {
4536
4431
  "project-id": {
4537
4432
  "char": "p",
4538
- "description": "Project ID to list users for (overrides CLI configuration)",
4433
+ "description": "Project ID to unlink dataset alias in (overrides CLI configuration)",
4539
4434
  "helpGroup": "OVERRIDE",
4540
4435
  "name": "project-id",
4541
4436
  "hasDynamicHelp": false,
@@ -4543,50 +4438,65 @@
4543
4438
  "multiple": false,
4544
4439
  "type": "option"
4545
4440
  },
4546
- "invitations": {
4547
- "description": "Includes or excludes pending invitations",
4548
- "name": "invitations",
4549
- "allowNo": true,
4550
- "type": "boolean"
4551
- },
4552
- "order": {
4553
- "description": "Sort output ascending/descending",
4554
- "name": "order",
4555
- "default": "asc",
4556
- "hasDynamicHelp": false,
4557
- "multiple": false,
4558
- "options": [
4559
- "asc",
4560
- "desc"
4561
- ],
4562
- "type": "option"
4563
- },
4564
- "robots": {
4565
- "description": "Includes or excludes robots (token users)",
4566
- "name": "robots",
4567
- "allowNo": true,
4441
+ "force": {
4442
+ "description": "Skip confirmation prompt and unlink immediately",
4443
+ "name": "force",
4444
+ "required": false,
4445
+ "allowNo": false,
4568
4446
  "type": "boolean"
4569
- },
4570
- "sort": {
4571
- "description": "Sort users by specified column",
4572
- "name": "sort",
4573
- "default": "date",
4447
+ }
4448
+ },
4449
+ "hasDynamicHelp": false,
4450
+ "hiddenAliases": [
4451
+ "dataset:alias:unlink"
4452
+ ],
4453
+ "id": "datasets:alias:unlink",
4454
+ "pluginAlias": "@sanity/cli",
4455
+ "pluginName": "@sanity/cli",
4456
+ "pluginType": "core",
4457
+ "strict": true,
4458
+ "isESM": true,
4459
+ "relativePath": [
4460
+ "dist",
4461
+ "commands",
4462
+ "datasets",
4463
+ "alias",
4464
+ "unlink.js"
4465
+ ]
4466
+ },
4467
+ "datasets:embeddings:disable": {
4468
+ "aliases": [],
4469
+ "args": {
4470
+ "dataset": {
4471
+ "description": "Dataset name to disable embeddings for",
4472
+ "name": "dataset",
4473
+ "required": false
4474
+ }
4475
+ },
4476
+ "description": "Disable embeddings for a dataset",
4477
+ "examples": [
4478
+ {
4479
+ "command": "<%= config.bin %> <%= command.id %> production",
4480
+ "description": "Disable embeddings for the production dataset"
4481
+ }
4482
+ ],
4483
+ "flags": {
4484
+ "project-id": {
4485
+ "char": "p",
4486
+ "description": "Project ID to disable embeddings for (overrides CLI configuration)",
4487
+ "helpGroup": "OVERRIDE",
4488
+ "name": "project-id",
4574
4489
  "hasDynamicHelp": false,
4490
+ "helpValue": "<id>",
4575
4491
  "multiple": false,
4576
- "options": [
4577
- "id",
4578
- "name",
4579
- "role",
4580
- "date"
4581
- ],
4582
4492
  "type": "option"
4583
4493
  }
4584
4494
  },
4585
4495
  "hasDynamicHelp": false,
4586
4496
  "hiddenAliases": [
4587
- "user:list"
4497
+ "dataset:embeddings:disable"
4588
4498
  ],
4589
- "id": "users:list",
4499
+ "id": "datasets:embeddings:disable",
4590
4500
  "pluginAlias": "@sanity/cli",
4591
4501
  "pluginName": "@sanity/cli",
4592
4502
  "pluginType": "core",
@@ -4595,60 +4505,66 @@
4595
4505
  "relativePath": [
4596
4506
  "dist",
4597
4507
  "commands",
4598
- "users",
4599
- "list.js"
4508
+ "datasets",
4509
+ "embeddings",
4510
+ "disable.js"
4600
4511
  ]
4601
4512
  },
4602
- "datasets:alias:create": {
4513
+ "datasets:embeddings:enable": {
4603
4514
  "aliases": [],
4604
4515
  "args": {
4605
- "aliasName": {
4606
- "description": "Dataset alias name to create",
4607
- "name": "aliasName",
4608
- "required": false
4609
- },
4610
- "targetDataset": {
4611
- "description": "Target dataset name to link the alias to",
4612
- "name": "targetDataset",
4516
+ "dataset": {
4517
+ "description": "Dataset name to enable embeddings for",
4518
+ "name": "dataset",
4613
4519
  "required": false
4614
4520
  }
4615
4521
  },
4616
- "description": "Create a dataset alias for the project",
4522
+ "description": "Enable embeddings for a dataset",
4617
4523
  "examples": [
4618
4524
  {
4619
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123 conference conf-2025",
4620
- "description": "Create alias in a specific project"
4621
- },
4622
- {
4623
- "command": "<%= config.bin %> <%= command.id %>",
4624
- "description": "Create an alias with interactive prompts"
4525
+ "command": "<%= config.bin %> <%= command.id %> production",
4526
+ "description": "Enable embeddings for the production dataset"
4625
4527
  },
4626
4528
  {
4627
- "command": "<%= config.bin %> <%= command.id %> conference",
4628
- "description": "Create alias named \"conference\" with interactive dataset selection"
4529
+ "command": "<%= config.bin %> <%= command.id %> production --projection \"{ title, body }\"",
4530
+ "description": "Enable embeddings with a specific projection"
4629
4531
  },
4630
4532
  {
4631
- "command": "<%= config.bin %> <%= command.id %> conference conf-2025",
4632
- "description": "Create alias \"conference\" linked to \"conf-2025\" dataset"
4533
+ "command": "<%= config.bin %> <%= command.id %> production --wait",
4534
+ "description": "Enable embeddings and wait for processing to complete"
4633
4535
  }
4634
4536
  ],
4635
4537
  "flags": {
4636
4538
  "project-id": {
4637
4539
  "char": "p",
4638
- "description": "Project ID to create dataset alias in (overrides CLI configuration)",
4540
+ "description": "Project ID to enable embeddings for (overrides CLI configuration)",
4639
4541
  "helpGroup": "OVERRIDE",
4640
4542
  "name": "project-id",
4641
4543
  "hasDynamicHelp": false,
4642
4544
  "helpValue": "<id>",
4643
4545
  "multiple": false,
4644
4546
  "type": "option"
4547
+ },
4548
+ "projection": {
4549
+ "description": "GROQ projection defining which fields to embed (e.g. \"{ title, body }\")",
4550
+ "name": "projection",
4551
+ "required": false,
4552
+ "hasDynamicHelp": false,
4553
+ "multiple": false,
4554
+ "type": "option"
4555
+ },
4556
+ "wait": {
4557
+ "description": "Wait for embeddings processing to complete before returning",
4558
+ "name": "wait",
4559
+ "allowNo": false,
4560
+ "type": "boolean"
4645
4561
  }
4646
4562
  },
4647
4563
  "hasDynamicHelp": false,
4648
4564
  "hiddenAliases": [
4649
- "dataset:alias:create"
4565
+ "dataset:embeddings:enable"
4650
4566
  ],
4651
- "id": "datasets:alias:create",
4567
+ "id": "datasets:embeddings:enable",
4652
4568
  "pluginAlias": "@sanity/cli",
4653
4569
  "pluginName": "@sanity/cli",
4654
4570
  "pluginType": "core",
@@ -4658,54 +4574,43 @@
4658
4574
  "dist",
4659
4575
  "commands",
4660
4576
  "datasets",
4661
- "alias",
4662
- "create.js"
4577
+ "embeddings",
4578
+ "enable.js"
4663
4579
  ]
4664
4580
  },
4665
- "datasets:alias:delete": {
4581
+ "datasets:embeddings:status": {
4666
4582
  "aliases": [],
4667
4583
  "args": {
4668
- "aliasName": {
4669
- "description": "Dataset alias name to delete",
4670
- "name": "aliasName",
4671
- "required": true
4584
+ "dataset": {
4585
+ "description": "The name of the dataset to check embeddings status for",
4586
+ "name": "dataset",
4587
+ "required": false
4672
4588
  }
4673
4589
  },
4674
- "description": "Delete a dataset alias from the project",
4590
+ "description": "Show embeddings settings and status for a dataset",
4675
4591
  "examples": [
4676
4592
  {
4677
- "command": "<%= config.bin %> <%= command.id %> conference",
4678
- "description": "Delete alias named \"conference\" with confirmation prompt"
4679
- },
4680
- {
4681
- "command": "<%= config.bin %> <%= command.id %> conference --force",
4682
- "description": "Delete alias named \"conference\" without confirmation prompt"
4593
+ "command": "<%= config.bin %> <%= command.id %> production",
4594
+ "description": "Show embeddings status for the production dataset"
4683
4595
  }
4684
4596
  ],
4685
4597
  "flags": {
4686
4598
  "project-id": {
4687
4599
  "char": "p",
4688
- "description": "Project ID to delete dataset alias from (overrides CLI configuration)",
4600
+ "description": "Project ID to check embeddings status for (overrides CLI configuration)",
4689
4601
  "helpGroup": "OVERRIDE",
4690
4602
  "name": "project-id",
4691
4603
  "hasDynamicHelp": false,
4692
4604
  "helpValue": "<id>",
4693
4605
  "multiple": false,
4694
4606
  "type": "option"
4695
- },
4696
- "force": {
4697
- "description": "Skip confirmation prompt and delete immediately",
4698
- "name": "force",
4699
- "required": false,
4700
- "allowNo": false,
4701
- "type": "boolean"
4702
4607
  }
4703
4608
  },
4704
4609
  "hasDynamicHelp": false,
4705
4610
  "hiddenAliases": [
4706
- "dataset:alias:delete"
4611
+ "dataset:embeddings:status"
4707
4612
  ],
4708
- "id": "datasets:alias:delete",
4613
+ "id": "datasets:embeddings:status",
4709
4614
  "pluginAlias": "@sanity/cli",
4710
4615
  "pluginName": "@sanity/cli",
4711
4616
  "pluginType": "core",
@@ -4715,47 +4620,28 @@
4715
4620
  "dist",
4716
4621
  "commands",
4717
4622
  "datasets",
4718
- "alias",
4719
- "delete.js"
4623
+ "embeddings",
4624
+ "status.js"
4720
4625
  ]
4721
4626
  },
4722
- "datasets:alias:link": {
4627
+ "schemas:delete": {
4723
4628
  "aliases": [],
4724
- "args": {
4725
- "aliasName": {
4726
- "description": "Dataset alias name to link",
4727
- "name": "aliasName",
4728
- "required": false
4729
- },
4730
- "targetDataset": {
4731
- "description": "Target dataset name to link the alias to",
4732
- "name": "targetDataset",
4733
- "required": false
4734
- }
4735
- },
4736
- "description": "Link a dataset alias to a dataset in the project",
4629
+ "args": {},
4630
+ "description": "Delete schema documents by id",
4737
4631
  "examples": [
4738
4632
  {
4739
- "command": "<%= config.bin %> <%= command.id %>",
4740
- "description": "Link an alias with interactive prompts"
4741
- },
4742
- {
4743
- "command": "<%= config.bin %> <%= command.id %> conference",
4744
- "description": "Link alias named \"conference\" with interactive dataset selection"
4745
- },
4746
- {
4747
- "command": "<%= config.bin %> <%= command.id %> conference conf-2025",
4748
- "description": "Link alias \"conference\" to \"conf-2025\" dataset"
4633
+ "command": "<%= config.bin %> <%= command.id %> --ids sanity.workspace.schema.workspaceName",
4634
+ "description": "Delete a single schema"
4749
4635
  },
4750
4636
  {
4751
- "command": "<%= config.bin %> <%= command.id %> conference conf-2025 --force",
4752
- "description": "Force link without confirmation (skip relink prompt)"
4637
+ "command": "<%= config.bin %> <%= command.id %> --ids sanity.workspace.schema.workspaceName,prefix.sanity.workspace.schema.otherWorkspace",
4638
+ "description": "Delete multiple schemas"
4753
4639
  }
4754
4640
  ],
4755
4641
  "flags": {
4756
4642
  "project-id": {
4757
4643
  "char": "p",
4758
- "description": "Project ID to link dataset alias in (overrides CLI configuration)",
4644
+ "description": "Project ID to delete schema from (overrides CLI configuration)",
4759
4645
  "helpGroup": "OVERRIDE",
4760
4646
  "name": "project-id",
4761
4647
  "hasDynamicHelp": false,
@@ -4763,19 +4649,51 @@
4763
4649
  "multiple": false,
4764
4650
  "type": "option"
4765
4651
  },
4766
- "force": {
4767
- "description": "Skip confirmation prompt when relinking existing alias",
4768
- "name": "force",
4769
- "required": false,
4652
+ "dataset": {
4653
+ "char": "d",
4654
+ "description": "Delete schemas from a specific dataset",
4655
+ "name": "dataset",
4656
+ "hasDynamicHelp": false,
4657
+ "helpValue": "<name>",
4658
+ "multiple": false,
4659
+ "type": "option"
4660
+ },
4661
+ "extract-manifest": {
4662
+ "description": "Generate manifest file (disable with --no-extract-manifest)",
4663
+ "hidden": true,
4664
+ "name": "extract-manifest",
4665
+ "allowNo": true,
4666
+ "type": "boolean"
4667
+ },
4668
+ "ids": {
4669
+ "description": "Comma-separated list of schema ids to delete",
4670
+ "name": "ids",
4671
+ "required": true,
4672
+ "hasDynamicHelp": false,
4673
+ "multiple": false,
4674
+ "type": "option"
4675
+ },
4676
+ "manifest-dir": {
4677
+ "description": "Directory containing manifest file",
4678
+ "hidden": true,
4679
+ "name": "manifest-dir",
4680
+ "default": "./dist/static",
4681
+ "hasDynamicHelp": false,
4682
+ "multiple": false,
4683
+ "type": "option"
4684
+ },
4685
+ "verbose": {
4686
+ "description": "Enable verbose logging",
4687
+ "name": "verbose",
4770
4688
  "allowNo": false,
4771
4689
  "type": "boolean"
4772
4690
  }
4773
4691
  },
4774
4692
  "hasDynamicHelp": false,
4775
4693
  "hiddenAliases": [
4776
- "dataset:alias:link"
4694
+ "schema:delete"
4777
4695
  ],
4778
- "id": "datasets:alias:link",
4696
+ "id": "schemas:delete",
4779
4697
  "pluginAlias": "@sanity/cli",
4780
4698
  "pluginName": "@sanity/cli",
4781
4699
  "pluginType": "core",
@@ -4784,59 +4702,68 @@
4784
4702
  "relativePath": [
4785
4703
  "dist",
4786
4704
  "commands",
4787
- "datasets",
4788
- "alias",
4789
- "link.js"
4705
+ "schemas",
4706
+ "delete.js"
4790
4707
  ]
4791
4708
  },
4792
- "datasets:alias:unlink": {
4709
+ "schemas:deploy": {
4793
4710
  "aliases": [],
4794
- "args": {
4795
- "aliasName": {
4796
- "description": "Dataset alias name to unlink",
4797
- "name": "aliasName",
4798
- "required": false
4799
- }
4800
- },
4801
- "description": "Unlink a dataset alias from its dataset in the project",
4711
+ "args": {},
4712
+ "description": "Deploy schema documents into workspace datasets.\n\nNote: This command is experimental and subject to change.\n\nRegenerates a manifest file by default. To re-use an existing manifest, use --no-extract-manifest.",
4802
4713
  "examples": [
4803
4714
  {
4804
4715
  "command": "<%= config.bin %> <%= command.id %>",
4805
- "description": "Unlink an alias with interactive selection"
4806
- },
4807
- {
4808
- "command": "<%= config.bin %> <%= command.id %> conference",
4809
- "description": "Unlink alias \"conference\" with confirmation prompt"
4716
+ "description": "Deploy all workspace schemas"
4810
4717
  },
4811
4718
  {
4812
- "command": "<%= config.bin %> <%= command.id %> conference --force",
4813
- "description": "Unlink alias \"conference\" without confirmation prompt"
4719
+ "command": "<%= config.bin %> <%= command.id %> --workspace default",
4720
+ "description": "Deploy the schema for only the workspace \"default\""
4814
4721
  }
4815
4722
  ],
4816
4723
  "flags": {
4817
- "project-id": {
4818
- "char": "p",
4819
- "description": "Project ID to unlink dataset alias in (overrides CLI configuration)",
4820
- "helpGroup": "OVERRIDE",
4821
- "name": "project-id",
4724
+ "extract-manifest": {
4725
+ "description": "Regenerate manifest before deploying (use --no-extract-manifest to skip)",
4726
+ "name": "extract-manifest",
4727
+ "allowNo": true,
4728
+ "type": "boolean"
4729
+ },
4730
+ "manifest-dir": {
4731
+ "description": "Directory containing manifest file",
4732
+ "name": "manifest-dir",
4733
+ "default": "./dist/static",
4734
+ "hasDynamicHelp": false,
4735
+ "helpValue": "<directory>",
4736
+ "multiple": false,
4737
+ "type": "option"
4738
+ },
4739
+ "tag": {
4740
+ "description": "Add a tag suffix to the schema id",
4741
+ "name": "tag",
4742
+ "hasDynamicHelp": false,
4743
+ "helpValue": "<tag>",
4744
+ "multiple": false,
4745
+ "type": "option"
4746
+ },
4747
+ "verbose": {
4748
+ "description": "Print detailed information during deployment",
4749
+ "name": "verbose",
4750
+ "allowNo": false,
4751
+ "type": "boolean"
4752
+ },
4753
+ "workspace": {
4754
+ "description": "The name of the workspace to deploy a schema for",
4755
+ "name": "workspace",
4822
4756
  "hasDynamicHelp": false,
4823
- "helpValue": "<id>",
4757
+ "helpValue": "<name>",
4824
4758
  "multiple": false,
4825
4759
  "type": "option"
4826
- },
4827
- "force": {
4828
- "description": "Skip confirmation prompt and unlink immediately",
4829
- "name": "force",
4830
- "required": false,
4831
- "allowNo": false,
4832
- "type": "boolean"
4833
4760
  }
4834
4761
  },
4835
4762
  "hasDynamicHelp": false,
4836
4763
  "hiddenAliases": [
4837
- "dataset:alias:unlink"
4764
+ "schema:deploy"
4838
4765
  ],
4839
- "id": "datasets:alias:unlink",
4766
+ "id": "schemas:deploy",
4840
4767
  "pluginAlias": "@sanity/cli",
4841
4768
  "pluginName": "@sanity/cli",
4842
4769
  "pluginType": "core",
@@ -4845,44 +4772,79 @@
4845
4772
  "relativePath": [
4846
4773
  "dist",
4847
4774
  "commands",
4848
- "datasets",
4849
- "alias",
4850
- "unlink.js"
4775
+ "schemas",
4776
+ "deploy.js"
4851
4777
  ]
4852
4778
  },
4853
- "datasets:embeddings:disable": {
4779
+ "schemas:extract": {
4854
4780
  "aliases": [],
4855
- "args": {
4856
- "dataset": {
4857
- "description": "Dataset name to disable embeddings for",
4858
- "name": "dataset",
4859
- "required": false
4860
- }
4861
- },
4862
- "description": "Disable embeddings for a dataset",
4781
+ "args": {},
4782
+ "description": "Extract a JSON representation of a Sanity schema within a Studio context.\n\nNote: This command is experimental and subject to change.",
4863
4783
  "examples": [
4864
4784
  {
4865
- "command": "<%= config.bin %> <%= command.id %> production",
4866
- "description": "Disable embeddings for the production dataset"
4785
+ "command": "<%= config.bin %> <%= command.id %> --workspace default",
4786
+ "description": "Extracts schema types in a Sanity project with more than one workspace"
4787
+ },
4788
+ {
4789
+ "command": "<%= config.bin %> <%= command.id %> --watch",
4790
+ "description": "Watch mode - re-extract on changes"
4791
+ },
4792
+ {
4793
+ "command": "<%= config.bin %> <%= command.id %> --watch --watch-patterns \"lib/**/*.ts\"",
4794
+ "description": "Watch with custom glob patterns"
4867
4795
  }
4868
4796
  ],
4869
4797
  "flags": {
4870
- "project-id": {
4871
- "char": "p",
4872
- "description": "Project ID to disable embeddings for (overrides CLI configuration)",
4873
- "helpGroup": "OVERRIDE",
4874
- "name": "project-id",
4798
+ "enforce-required-fields": {
4799
+ "description": "Makes the schema generated treat fields marked as required as non-optional",
4800
+ "name": "enforce-required-fields",
4801
+ "allowNo": false,
4802
+ "type": "boolean"
4803
+ },
4804
+ "format": {
4805
+ "description": "Output format (currently only groq-type-nodes)",
4806
+ "name": "format",
4807
+ "default": "groq-type-nodes",
4875
4808
  "hasDynamicHelp": false,
4876
- "helpValue": "<id>",
4809
+ "helpValue": "<format>",
4810
+ "multiple": false,
4811
+ "type": "option"
4812
+ },
4813
+ "path": {
4814
+ "description": "Optional path to specify destination of the schema file",
4815
+ "name": "path",
4816
+ "hasDynamicHelp": false,
4817
+ "multiple": false,
4818
+ "type": "option"
4819
+ },
4820
+ "watch": {
4821
+ "description": "Enable watch mode to re-extract schema on file changes",
4822
+ "name": "watch",
4823
+ "allowNo": false,
4824
+ "type": "boolean"
4825
+ },
4826
+ "watch-patterns": {
4827
+ "description": "Additional glob pattern(s) to watch (can be specified multiple times)",
4828
+ "name": "watch-patterns",
4829
+ "hasDynamicHelp": false,
4830
+ "helpValue": "<glob>",
4831
+ "multiple": true,
4832
+ "type": "option"
4833
+ },
4834
+ "workspace": {
4835
+ "description": "The name of the workspace to generate a schema for",
4836
+ "name": "workspace",
4837
+ "hasDynamicHelp": false,
4838
+ "helpValue": "<name>",
4877
4839
  "multiple": false,
4878
4840
  "type": "option"
4879
4841
  }
4880
4842
  },
4881
4843
  "hasDynamicHelp": false,
4882
4844
  "hiddenAliases": [
4883
- "dataset:embeddings:disable"
4845
+ "schema:extract"
4884
4846
  ],
4885
- "id": "datasets:embeddings:disable",
4847
+ "id": "schemas:extract",
4886
4848
  "pluginAlias": "@sanity/cli",
4887
4849
  "pluginName": "@sanity/cli",
4888
4850
  "pluginType": "core",
@@ -4891,66 +4853,70 @@
4891
4853
  "relativePath": [
4892
4854
  "dist",
4893
4855
  "commands",
4894
- "datasets",
4895
- "embeddings",
4896
- "disable.js"
4856
+ "schemas",
4857
+ "extract.js"
4897
4858
  ]
4898
4859
  },
4899
- "datasets:embeddings:enable": {
4860
+ "schemas:list": {
4900
4861
  "aliases": [],
4901
- "args": {
4902
- "dataset": {
4903
- "description": "Dataset name to enable embeddings for",
4904
- "name": "dataset",
4905
- "required": false
4906
- }
4907
- },
4908
- "description": "Enable embeddings for a dataset",
4862
+ "args": {},
4863
+ "description": "List all schemas in the current dataset.\n\nNote: This command is experimental and subject to change.\n\nRegenerates a manifest file by default. To reuse an existing manifest, use --no-extract-manifest.",
4909
4864
  "examples": [
4910
4865
  {
4911
- "command": "<%= config.bin %> <%= command.id %> production",
4912
- "description": "Enable embeddings for the production dataset"
4866
+ "command": "<%= config.bin %> <%= command.id %>",
4867
+ "description": "List all schemas found in any workspace dataset in a table"
4913
4868
  },
4914
4869
  {
4915
- "command": "<%= config.bin %> <%= command.id %> production --projection \"{ title, body }\"",
4916
- "description": "Enable embeddings with a specific projection"
4870
+ "command": "<%= config.bin %> <%= command.id %> --id _.schemas.workspaceName",
4871
+ "description": "Get a schema for a given id"
4917
4872
  },
4918
4873
  {
4919
- "command": "<%= config.bin %> <%= command.id %> production --wait",
4920
- "description": "Enable embeddings and wait for processing to complete"
4874
+ "command": "<%= config.bin %> <%= command.id %> --json",
4875
+ "description": "Get stored schemas as pretty-printed json-array"
4876
+ },
4877
+ {
4878
+ "command": "<%= config.bin %> <%= command.id %> --json --id _.schemas.workspaceName",
4879
+ "description": "Get singular stored schema as pretty-printed json-object"
4921
4880
  }
4922
4881
  ],
4923
4882
  "flags": {
4924
- "project-id": {
4925
- "char": "p",
4926
- "description": "Project ID to enable embeddings for (overrides CLI configuration)",
4927
- "helpGroup": "OVERRIDE",
4928
- "name": "project-id",
4929
- "hasDynamicHelp": false,
4930
- "helpValue": "<id>",
4931
- "multiple": false,
4932
- "type": "option"
4883
+ "extract-manifest": {
4884
+ "description": "Regenerate manifest before listing (use --no-extract-manifest to skip)",
4885
+ "hidden": true,
4886
+ "name": "extract-manifest",
4887
+ "allowNo": true,
4888
+ "type": "boolean"
4933
4889
  },
4934
- "projection": {
4935
- "description": "GROQ projection defining which fields to embed (e.g. \"{ title, body }\")",
4936
- "name": "projection",
4937
- "required": false,
4890
+ "id": {
4891
+ "description": "Fetch a single schema by id",
4892
+ "name": "id",
4938
4893
  "hasDynamicHelp": false,
4894
+ "helpValue": "<schema_id>",
4939
4895
  "multiple": false,
4940
4896
  "type": "option"
4941
4897
  },
4942
- "wait": {
4943
- "description": "Wait for embeddings processing to complete before returning",
4944
- "name": "wait",
4898
+ "json": {
4899
+ "description": "Get schema as json",
4900
+ "name": "json",
4945
4901
  "allowNo": false,
4946
4902
  "type": "boolean"
4903
+ },
4904
+ "manifest-dir": {
4905
+ "description": "Directory containing manifest file",
4906
+ "hidden": true,
4907
+ "name": "manifest-dir",
4908
+ "default": "./dist/static",
4909
+ "hasDynamicHelp": false,
4910
+ "helpValue": "<directory>",
4911
+ "multiple": false,
4912
+ "type": "option"
4947
4913
  }
4948
4914
  },
4949
4915
  "hasDynamicHelp": false,
4950
4916
  "hiddenAliases": [
4951
- "dataset:embeddings:enable"
4917
+ "schema:list"
4952
4918
  ],
4953
- "id": "datasets:embeddings:enable",
4919
+ "id": "schemas:list",
4954
4920
  "pluginAlias": "@sanity/cli",
4955
4921
  "pluginName": "@sanity/cli",
4956
4922
  "pluginType": "core",
@@ -4959,44 +4925,79 @@
4959
4925
  "relativePath": [
4960
4926
  "dist",
4961
4927
  "commands",
4962
- "datasets",
4963
- "embeddings",
4964
- "enable.js"
4928
+ "schemas",
4929
+ "list.js"
4965
4930
  ]
4966
4931
  },
4967
- "datasets:embeddings:status": {
4932
+ "schemas:validate": {
4968
4933
  "aliases": [],
4969
- "args": {
4970
- "dataset": {
4971
- "description": "The name of the dataset to check embeddings status for",
4972
- "name": "dataset",
4973
- "required": false
4974
- }
4975
- },
4976
- "description": "Show embeddings settings and status for a dataset",
4934
+ "args": {},
4935
+ "description": "Validates all schema types specified in a workspace",
4977
4936
  "examples": [
4978
4937
  {
4979
- "command": "<%= config.bin %> <%= command.id %> production",
4980
- "description": "Show embeddings status for the production dataset"
4938
+ "command": "<%= config.bin %> <%= command.id %> --workspace default",
4939
+ "description": "Validates all schema types in a Sanity project with more than one workspace"
4940
+ },
4941
+ {
4942
+ "command": "<%= config.bin %> <%= command.id %> > report.txt",
4943
+ "description": "Save the results of the report into a file"
4944
+ },
4945
+ {
4946
+ "command": "<%= config.bin %> <%= command.id %> --level error",
4947
+ "description": "Report out only errors"
4948
+ },
4949
+ {
4950
+ "command": "<%= config.bin %> <%= command.id %> --debug-metafile-path metafile.json",
4951
+ "description": "Generate a report which can be analyzed with https://esbuild.github.io/analyze/"
4981
4952
  }
4982
4953
  ],
4983
4954
  "flags": {
4984
- "project-id": {
4985
- "char": "p",
4986
- "description": "Project ID to check embeddings status for (overrides CLI configuration)",
4987
- "helpGroup": "OVERRIDE",
4988
- "name": "project-id",
4955
+ "debug-metafile-path": {
4956
+ "description": "Optional path where a metafile will be written for build analysis. Only written on successful validation. Can be analyzed at https://esbuild.github.io/analyze/",
4957
+ "helpGroup": "DEBUG",
4958
+ "name": "debug-metafile-path",
4959
+ "hasDynamicHelp": false,
4960
+ "multiple": false,
4961
+ "type": "option"
4962
+ },
4963
+ "format": {
4964
+ "description": "The output format used to print schema errors and warnings",
4965
+ "name": "format",
4966
+ "default": "pretty",
4967
+ "hasDynamicHelp": false,
4968
+ "multiple": false,
4969
+ "options": [
4970
+ "pretty",
4971
+ "ndjson",
4972
+ "json"
4973
+ ],
4974
+ "type": "option"
4975
+ },
4976
+ "level": {
4977
+ "description": "The minimum level reported out",
4978
+ "name": "level",
4979
+ "default": "warning",
4980
+ "hasDynamicHelp": false,
4981
+ "multiple": false,
4982
+ "options": [
4983
+ "error",
4984
+ "warning"
4985
+ ],
4986
+ "type": "option"
4987
+ },
4988
+ "workspace": {
4989
+ "description": "The name of the workspace to use when validating all schema types",
4990
+ "name": "workspace",
4989
4991
  "hasDynamicHelp": false,
4990
- "helpValue": "<id>",
4991
4992
  "multiple": false,
4992
4993
  "type": "option"
4993
4994
  }
4994
4995
  },
4995
4996
  "hasDynamicHelp": false,
4996
4997
  "hiddenAliases": [
4997
- "dataset:embeddings:status"
4998
+ "schema:validate"
4998
4999
  ],
4999
- "id": "datasets:embeddings:status",
5000
+ "id": "schemas:validate",
5000
5001
  "pluginAlias": "@sanity/cli",
5001
5002
  "pluginName": "@sanity/cli",
5002
5003
  "pluginType": "core",
@@ -5005,9 +5006,8 @@
5005
5006
  "relativePath": [
5006
5007
  "dist",
5007
5008
  "commands",
5008
- "datasets",
5009
- "embeddings",
5010
- "status.js"
5009
+ "schemas",
5010
+ "validate.js"
5011
5011
  ]
5012
5012
  },
5013
5013
  "datasets:visibility:get": {
@@ -5116,5 +5116,5 @@
5116
5116
  ]
5117
5117
  }
5118
5118
  },
5119
- "version": "7.0.0"
5119
+ "version": "7.0.1"
5120
5120
  }