@sanity/cli 8.0.2 → 8.0.3

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 (55) hide show
  1. package/dist/SanityHelp.js.map +1 -1
  2. package/dist/actions/backup/assertDatasetExist.js +2 -1
  3. package/dist/actions/backup/assertDatasetExist.js.map +1 -1
  4. package/dist/actions/build/buildStudio.js +3 -2
  5. package/dist/actions/build/buildStudio.js.map +1 -1
  6. package/dist/actions/build/eventListenerFactory.js +7 -6
  7. package/dist/actions/build/eventListenerFactory.js.map +1 -1
  8. package/dist/actions/build/shouldAutoUpdate.js +2 -1
  9. package/dist/actions/build/shouldAutoUpdate.js.map +1 -1
  10. package/dist/actions/cors/filterAndValidateOrigin.js +3 -2
  11. package/dist/actions/cors/filterAndValidateOrigin.js.map +1 -1
  12. package/dist/actions/deploy/createUserApplication.js +2 -1
  13. package/dist/actions/deploy/createUserApplication.js.map +1 -1
  14. package/dist/actions/deploy/deployRunner.js +3 -2
  15. package/dist/actions/deploy/deployRunner.js.map +1 -1
  16. package/dist/actions/deploy/deployStudio.js +3 -3
  17. package/dist/actions/deploy/deployStudio.js.map +1 -1
  18. package/dist/actions/deploy/findUserApplication.js +8 -7
  19. package/dist/actions/deploy/findUserApplication.js.map +1 -1
  20. package/dist/actions/dev/servers/startAppDevServer.js +2 -1
  21. package/dist/actions/dev/servers/startAppDevServer.js.map +1 -1
  22. package/dist/actions/dev/servers/startStudioDevServer.js +3 -3
  23. package/dist/actions/dev/servers/startStudioDevServer.js.map +1 -1
  24. package/dist/actions/documents/validate.js +5 -2
  25. package/dist/actions/documents/validate.js.map +1 -1
  26. package/dist/actions/init/env/createOrAppendEnvVars.js +2 -1
  27. package/dist/actions/init/env/createOrAppendEnvVars.js.map +1 -1
  28. package/dist/actions/init/env/parseAndUpdateEnvVars.js +2 -2
  29. package/dist/actions/init/env/parseAndUpdateEnvVars.js.map +1 -1
  30. package/dist/actions/schema/extractSchema.js +2 -2
  31. package/dist/actions/schema/extractSchema.js.map +1 -1
  32. package/dist/actions/schema/extractSchemaWatcher.js +2 -1
  33. package/dist/actions/schema/extractSchemaWatcher.js.map +1 -1
  34. package/dist/actions/undeploy/runUndeploy.js +2 -2
  35. package/dist/actions/undeploy/runUndeploy.js.map +1 -1
  36. package/dist/commands/backups/list.js +5 -8
  37. package/dist/commands/backups/list.js.map +1 -1
  38. package/dist/commands/datasets/copy.js +5 -7
  39. package/dist/commands/datasets/copy.js.map +1 -1
  40. package/dist/commands/docs/search.js +2 -2
  41. package/dist/commands/docs/search.js.map +1 -1
  42. package/dist/commands/mcp/configure.js +2 -2
  43. package/dist/commands/mcp/configure.js.map +1 -1
  44. package/dist/commands/typegen/generate.js +6 -6
  45. package/dist/commands/typegen/generate.js.map +1 -1
  46. package/dist/services/mintProject.js +27 -3
  47. package/dist/services/mintProject.js.map +1 -1
  48. package/dist/util/appId.js +2 -1
  49. package/dist/util/appId.js.map +1 -1
  50. package/dist/util/dates.js +125 -0
  51. package/dist/util/dates.js.map +1 -0
  52. package/dist/util/getCliVersion.js +1 -11
  53. package/dist/util/getCliVersion.js.map +1 -1
  54. package/oclif.manifest.json +707 -707
  55. package/package.json +4 -7
@@ -3094,258 +3094,6 @@
3094
3094
  "validate.js"
3095
3095
  ]
3096
3096
  },
3097
- "graphql:deploy": {
3098
- "aliases": [],
3099
- "args": {},
3100
- "description": "Deploy a GraphQL API from the current Sanity schema",
3101
- "examples": [
3102
- {
3103
- "command": "<%= config.bin %> <%= command.id %>",
3104
- "description": "Deploy all defined GraphQL APIs"
3105
- },
3106
- {
3107
- "command": "<%= config.bin %> <%= command.id %> --dry-run",
3108
- "description": "Validate defined GraphQL APIs, check for breaking changes, skip deploy"
3109
- },
3110
- {
3111
- "command": "<%= config.bin %> <%= command.id %> --api staging --api ios",
3112
- "description": "Deploy only the GraphQL APIs with the IDs \"staging\" and \"ios\""
3113
- },
3114
- {
3115
- "command": "<%= config.bin %> <%= command.id %> --playground",
3116
- "description": "Deploy all defined GraphQL APIs, overriding any playground setting"
3117
- }
3118
- ],
3119
- "flags": {
3120
- "api": {
3121
- "description": "Only deploy API with this ID (can be specified multiple times)",
3122
- "name": "api",
3123
- "hasDynamicHelp": false,
3124
- "multiple": true,
3125
- "type": "option"
3126
- },
3127
- "dataset": {
3128
- "char": "d",
3129
- "description": "Deploy API for the given dataset",
3130
- "name": "dataset",
3131
- "hasDynamicHelp": false,
3132
- "helpValue": "<name>",
3133
- "multiple": false,
3134
- "type": "option"
3135
- },
3136
- "dry-run": {
3137
- "description": "Validate defined GraphQL APIs, check for breaking changes, skip deploy",
3138
- "name": "dry-run",
3139
- "allowNo": false,
3140
- "type": "boolean"
3141
- },
3142
- "force": {
3143
- "description": "Deploy API without confirming breaking changes",
3144
- "name": "force",
3145
- "allowNo": false,
3146
- "type": "boolean"
3147
- },
3148
- "generation": {
3149
- "description": "API generation to deploy (defaults to \"gen3\")",
3150
- "name": "generation",
3151
- "hasDynamicHelp": false,
3152
- "multiple": false,
3153
- "options": [
3154
- "gen1",
3155
- "gen2",
3156
- "gen3"
3157
- ],
3158
- "type": "option"
3159
- },
3160
- "non-null-document-fields": {
3161
- "description": "Use non-null document fields (_id, _type etc)",
3162
- "name": "non-null-document-fields",
3163
- "allowNo": false,
3164
- "type": "boolean"
3165
- },
3166
- "playground": {
3167
- "description": "Enable GraphQL playground for easier debugging",
3168
- "name": "playground",
3169
- "allowNo": true,
3170
- "type": "boolean"
3171
- },
3172
- "tag": {
3173
- "description": "Deploy API(s) to given tag (defaults to \"default\")",
3174
- "name": "tag",
3175
- "hasDynamicHelp": false,
3176
- "multiple": false,
3177
- "type": "option"
3178
- },
3179
- "with-union-cache": {
3180
- "description": "Cache union types (faster for schemas with many self-references)",
3181
- "name": "with-union-cache",
3182
- "allowNo": false,
3183
- "type": "boolean"
3184
- }
3185
- },
3186
- "hasDynamicHelp": false,
3187
- "hiddenAliases": [],
3188
- "id": "graphql:deploy",
3189
- "pluginAlias": "@sanity/cli",
3190
- "pluginName": "@sanity/cli",
3191
- "pluginType": "core",
3192
- "strict": true,
3193
- "isESM": true,
3194
- "relativePath": [
3195
- "dist",
3196
- "commands",
3197
- "graphql",
3198
- "deploy.js"
3199
- ]
3200
- },
3201
- "graphql:list": {
3202
- "aliases": [],
3203
- "args": {},
3204
- "description": "List deployed GraphQL endpoints for the project",
3205
- "examples": [
3206
- {
3207
- "command": "<%= config.bin %> <%= command.id %>",
3208
- "description": "List GraphQL endpoints for the project"
3209
- },
3210
- {
3211
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
3212
- "description": "List GraphQL endpoints for a specific project"
3213
- }
3214
- ],
3215
- "flags": {
3216
- "project-id": {
3217
- "char": "p",
3218
- "description": "Project ID to list GraphQL endpoints for (overrides CLI configuration)",
3219
- "helpGroup": "OVERRIDE",
3220
- "name": "project-id",
3221
- "hasDynamicHelp": false,
3222
- "helpValue": "<id>",
3223
- "multiple": false,
3224
- "type": "option"
3225
- }
3226
- },
3227
- "hasDynamicHelp": false,
3228
- "hiddenAliases": [],
3229
- "id": "graphql:list",
3230
- "pluginAlias": "@sanity/cli",
3231
- "pluginName": "@sanity/cli",
3232
- "pluginType": "core",
3233
- "strict": true,
3234
- "isESM": true,
3235
- "relativePath": [
3236
- "dist",
3237
- "commands",
3238
- "graphql",
3239
- "list.js"
3240
- ]
3241
- },
3242
- "graphql:undeploy": {
3243
- "aliases": [],
3244
- "args": {},
3245
- "description": "Remove a deployed GraphQL API",
3246
- "examples": [
3247
- {
3248
- "command": "<%= config.bin %> <%= command.id %>",
3249
- "description": "Undeploy GraphQL API for current project and dataset"
3250
- },
3251
- {
3252
- "command": "<%= config.bin %> <%= command.id %> --api ios",
3253
- "description": "Undeploy API with ID \"ios\""
3254
- },
3255
- {
3256
- "command": "<%= config.bin %> <%= command.id %> --dataset staging",
3257
- "description": "Undeploy GraphQL API for staging dataset"
3258
- },
3259
- {
3260
- "command": "<%= config.bin %> <%= command.id %> --dataset staging --tag next",
3261
- "description": "Undeploy GraphQL API for staging dataset with \"next\" tag"
3262
- },
3263
- {
3264
- "command": "<%= config.bin %> <%= command.id %> --force",
3265
- "description": "Undeploy GraphQL API without confirmation prompt"
3266
- },
3267
- {
3268
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123 --dataset production",
3269
- "description": "Undeploy GraphQL API for a specific project and dataset"
3270
- }
3271
- ],
3272
- "flags": {
3273
- "project-id": {
3274
- "char": "p",
3275
- "description": "Project ID to undeploy GraphQL API from (overrides CLI configuration)",
3276
- "helpGroup": "OVERRIDE",
3277
- "name": "project-id",
3278
- "hasDynamicHelp": false,
3279
- "helpValue": "<id>",
3280
- "multiple": false,
3281
- "type": "option"
3282
- },
3283
- "api": {
3284
- "description": "Undeploy API with this ID",
3285
- "exclusive": [
3286
- "project-id",
3287
- "project"
3288
- ],
3289
- "name": "api",
3290
- "required": false,
3291
- "hasDynamicHelp": false,
3292
- "multiple": false,
3293
- "type": "option"
3294
- },
3295
- "dataset": {
3296
- "char": "d",
3297
- "description": "Dataset to undeploy GraphQL API from (overrides CLI configuration)",
3298
- "helpGroup": "OVERRIDE",
3299
- "name": "dataset",
3300
- "hasDynamicHelp": false,
3301
- "helpValue": "<name>",
3302
- "multiple": false,
3303
- "type": "option"
3304
- },
3305
- "force": {
3306
- "description": "Skip confirmation prompt",
3307
- "name": "force",
3308
- "required": false,
3309
- "allowNo": false,
3310
- "type": "boolean"
3311
- },
3312
- "project": {
3313
- "deprecated": {
3314
- "to": "project-id"
3315
- },
3316
- "description": "Project ID to delete GraphQL API for",
3317
- "hidden": true,
3318
- "name": "project",
3319
- "required": false,
3320
- "hasDynamicHelp": false,
3321
- "multiple": false,
3322
- "type": "option"
3323
- },
3324
- "tag": {
3325
- "description": "Tag to undeploy GraphQL API from",
3326
- "name": "tag",
3327
- "required": false,
3328
- "default": "default",
3329
- "hasDynamicHelp": false,
3330
- "multiple": false,
3331
- "type": "option"
3332
- }
3333
- },
3334
- "hasDynamicHelp": false,
3335
- "hiddenAliases": [],
3336
- "id": "graphql:undeploy",
3337
- "pluginAlias": "@sanity/cli",
3338
- "pluginName": "@sanity/cli",
3339
- "pluginType": "core",
3340
- "strict": true,
3341
- "isESM": true,
3342
- "relativePath": [
3343
- "dist",
3344
- "commands",
3345
- "graphql",
3346
- "undeploy.js"
3347
- ]
3348
- },
3349
3097
  "hooks:attempt": {
3350
3098
  "aliases": [],
3351
3099
  "args": {
@@ -3594,100 +3342,98 @@
3594
3342
  "logs.js"
3595
3343
  ]
3596
3344
  },
3597
- "manifest:extract": {
3345
+ "graphql:deploy": {
3598
3346
  "aliases": [],
3599
3347
  "args": {},
3600
- "description": "Extract studio configuration as JSON manifest files.\n\nNote: This command is experimental and subject to change. It is currently intended for use with Create only.",
3348
+ "description": "Deploy a GraphQL API from the current Sanity schema",
3601
3349
  "examples": [
3602
3350
  {
3603
3351
  "command": "<%= config.bin %> <%= command.id %>",
3604
- "description": "Extracts manifests"
3352
+ "description": "Deploy all defined GraphQL APIs"
3605
3353
  },
3606
3354
  {
3607
- "command": "<%= config.bin %> <%= command.id %> --path /public/static",
3608
- "description": "Extracts manifests into /public/static"
3355
+ "command": "<%= config.bin %> <%= command.id %> --dry-run",
3356
+ "description": "Validate defined GraphQL APIs, check for breaking changes, skip deploy"
3357
+ },
3358
+ {
3359
+ "command": "<%= config.bin %> <%= command.id %> --api staging --api ios",
3360
+ "description": "Deploy only the GraphQL APIs with the IDs \"staging\" and \"ios\""
3361
+ },
3362
+ {
3363
+ "command": "<%= config.bin %> <%= command.id %> --playground",
3364
+ "description": "Deploy all defined GraphQL APIs, overriding any playground setting"
3609
3365
  }
3610
3366
  ],
3611
3367
  "flags": {
3612
- "path": {
3613
- "description": "Optional path to specify destination directory of the manifest files",
3614
- "name": "path",
3615
- "default": "dist/static",
3368
+ "api": {
3369
+ "description": "Only deploy API with this ID (can be specified multiple times)",
3370
+ "name": "api",
3616
3371
  "hasDynamicHelp": false,
3372
+ "multiple": true,
3373
+ "type": "option"
3374
+ },
3375
+ "dataset": {
3376
+ "char": "d",
3377
+ "description": "Deploy API for the given dataset",
3378
+ "name": "dataset",
3379
+ "hasDynamicHelp": false,
3380
+ "helpValue": "<name>",
3617
3381
  "multiple": false,
3618
3382
  "type": "option"
3619
- }
3620
- },
3621
- "hasDynamicHelp": false,
3622
- "hiddenAliases": [],
3623
- "id": "manifest:extract",
3624
- "pluginAlias": "@sanity/cli",
3625
- "pluginName": "@sanity/cli",
3626
- "pluginType": "core",
3627
- "strict": true,
3628
- "isESM": true,
3629
- "relativePath": [
3630
- "dist",
3631
- "commands",
3632
- "manifest",
3633
- "extract.js"
3634
- ]
3635
- },
3636
- "mcp:configure": {
3637
- "aliases": [],
3638
- "args": {},
3639
- "description": "Configure Sanity MCP server for AI editors (Antigravity, Claude Code, Cline, Cline CLI, Codex CLI, Cursor, Gemini CLI, GitHub Copilot CLI, MCPorter, OpenCode, VS Code, VS Code Insiders, Zed)",
3640
- "examples": [
3641
- {
3642
- "command": "<%= config.bin %> <%= command.id %>",
3643
- "description": "Configure Sanity MCP server for detected AI editors"
3644
- }
3645
- ],
3646
- "flags": {},
3647
- "hasDynamicHelp": false,
3648
- "hiddenAliases": [],
3649
- "id": "mcp:configure",
3650
- "pluginAlias": "@sanity/cli",
3651
- "pluginName": "@sanity/cli",
3652
- "pluginType": "core",
3653
- "strict": true,
3654
- "isESM": true,
3655
- "relativePath": [
3656
- "dist",
3657
- "commands",
3658
- "mcp",
3659
- "configure.js"
3660
- ]
3661
- },
3662
- "media:create-aspect": {
3663
- "aliases": [],
3664
- "args": {},
3665
- "description": "Create a new aspect definition file",
3666
- "examples": [
3667
- {
3668
- "command": "<%= config.bin %> <%= command.id %>",
3669
- "description": "Create a new aspect definition file"
3670
- }
3671
- ],
3672
- "flags": {
3673
- "name": {
3674
- "description": "Aspect name. Defaults to the title in camel case",
3675
- "name": "name",
3383
+ },
3384
+ "dry-run": {
3385
+ "description": "Validate defined GraphQL APIs, check for breaking changes, skip deploy",
3386
+ "name": "dry-run",
3387
+ "allowNo": false,
3388
+ "type": "boolean"
3389
+ },
3390
+ "force": {
3391
+ "description": "Deploy API without confirming breaking changes",
3392
+ "name": "force",
3393
+ "allowNo": false,
3394
+ "type": "boolean"
3395
+ },
3396
+ "generation": {
3397
+ "description": "API generation to deploy (defaults to \"gen3\")",
3398
+ "name": "generation",
3676
3399
  "hasDynamicHelp": false,
3677
3400
  "multiple": false,
3401
+ "options": [
3402
+ "gen1",
3403
+ "gen2",
3404
+ "gen3"
3405
+ ],
3678
3406
  "type": "option"
3679
3407
  },
3680
- "title": {
3681
- "description": "Aspect title",
3682
- "name": "title",
3408
+ "non-null-document-fields": {
3409
+ "description": "Use non-null document fields (_id, _type etc)",
3410
+ "name": "non-null-document-fields",
3411
+ "allowNo": false,
3412
+ "type": "boolean"
3413
+ },
3414
+ "playground": {
3415
+ "description": "Enable GraphQL playground for easier debugging",
3416
+ "name": "playground",
3417
+ "allowNo": true,
3418
+ "type": "boolean"
3419
+ },
3420
+ "tag": {
3421
+ "description": "Deploy API(s) to given tag (defaults to \"default\")",
3422
+ "name": "tag",
3683
3423
  "hasDynamicHelp": false,
3684
3424
  "multiple": false,
3685
3425
  "type": "option"
3426
+ },
3427
+ "with-union-cache": {
3428
+ "description": "Cache union types (faster for schemas with many self-references)",
3429
+ "name": "with-union-cache",
3430
+ "allowNo": false,
3431
+ "type": "boolean"
3686
3432
  }
3687
3433
  },
3688
3434
  "hasDynamicHelp": false,
3689
3435
  "hiddenAliases": [],
3690
- "id": "media:create-aspect",
3436
+ "id": "graphql:deploy",
3691
3437
  "pluginAlias": "@sanity/cli",
3692
3438
  "pluginName": "@sanity/cli",
3693
3439
  "pluginType": "core",
@@ -3696,59 +3442,39 @@
3696
3442
  "relativePath": [
3697
3443
  "dist",
3698
3444
  "commands",
3699
- "media",
3700
- "create-aspect.js"
3445
+ "graphql",
3446
+ "deploy.js"
3701
3447
  ]
3702
3448
  },
3703
- "media:delete-aspect": {
3449
+ "graphql:list": {
3704
3450
  "aliases": [],
3705
- "args": {
3706
- "aspectName": {
3707
- "description": "Name of the aspect to delete",
3708
- "name": "aspectName",
3709
- "required": true
3710
- }
3711
- },
3712
- "description": "Delete an aspect definition",
3451
+ "args": {},
3452
+ "description": "List deployed GraphQL endpoints for the project",
3713
3453
  "examples": [
3714
3454
  {
3715
- "command": "<%= config.bin %> <%= command.id %> someAspect",
3716
- "description": "Delete the aspect named \"someAspect\""
3455
+ "command": "<%= config.bin %> <%= command.id %>",
3456
+ "description": "List GraphQL endpoints for the project"
3457
+ },
3458
+ {
3459
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
3460
+ "description": "List GraphQL endpoints for a specific project"
3717
3461
  }
3718
3462
  ],
3719
3463
  "flags": {
3720
3464
  "project-id": {
3721
3465
  "char": "p",
3722
- "description": "Project ID to delete media aspect from (overrides CLI configuration)",
3466
+ "description": "Project ID to list GraphQL endpoints for (overrides CLI configuration)",
3723
3467
  "helpGroup": "OVERRIDE",
3724
3468
  "name": "project-id",
3725
3469
  "hasDynamicHelp": false,
3726
3470
  "helpValue": "<id>",
3727
3471
  "multiple": false,
3728
3472
  "type": "option"
3729
- },
3730
- "media-library-id": {
3731
- "description": "The id of the target media library",
3732
- "name": "media-library-id",
3733
- "required": false,
3734
- "hasDynamicHelp": false,
3735
- "multiple": false,
3736
- "type": "option"
3737
- },
3738
- "yes": {
3739
- "aliases": [
3740
- "y"
3741
- ],
3742
- "description": "Run without prompts and confirm deletion",
3743
- "name": "yes",
3744
- "required": false,
3745
- "allowNo": false,
3746
- "type": "boolean"
3747
3473
  }
3748
3474
  },
3749
3475
  "hasDynamicHelp": false,
3750
3476
  "hiddenAliases": [],
3751
- "id": "media:delete-aspect",
3477
+ "id": "graphql:list",
3752
3478
  "pluginAlias": "@sanity/cli",
3753
3479
  "pluginName": "@sanity/cli",
3754
3480
  "pluginType": "core",
@@ -3757,34 +3483,44 @@
3757
3483
  "relativePath": [
3758
3484
  "dist",
3759
3485
  "commands",
3760
- "media",
3761
- "delete-aspect.js"
3486
+ "graphql",
3487
+ "list.js"
3762
3488
  ]
3763
3489
  },
3764
- "media:deploy-aspect": {
3490
+ "graphql:undeploy": {
3765
3491
  "aliases": [],
3766
- "args": {
3767
- "aspectName": {
3768
- "description": "Name of the aspect to deploy",
3769
- "name": "aspectName",
3770
- "required": false
3771
- }
3772
- },
3773
- "description": "Deploy an aspect",
3492
+ "args": {},
3493
+ "description": "Remove a deployed GraphQL API",
3774
3494
  "examples": [
3775
3495
  {
3776
- "command": "<%= config.bin %> <%= command.id %> someAspect",
3777
- "description": "Deploy the aspect named \"someAspect\""
3496
+ "command": "<%= config.bin %> <%= command.id %>",
3497
+ "description": "Undeploy GraphQL API for current project and dataset"
3778
3498
  },
3779
3499
  {
3780
- "command": "<%= config.bin %> <%= command.id %> --all",
3781
- "description": "Deploy all aspects"
3500
+ "command": "<%= config.bin %> <%= command.id %> --api ios",
3501
+ "description": "Undeploy API with ID \"ios\""
3502
+ },
3503
+ {
3504
+ "command": "<%= config.bin %> <%= command.id %> --dataset staging",
3505
+ "description": "Undeploy GraphQL API for staging dataset"
3506
+ },
3507
+ {
3508
+ "command": "<%= config.bin %> <%= command.id %> --dataset staging --tag next",
3509
+ "description": "Undeploy GraphQL API for staging dataset with \"next\" tag"
3510
+ },
3511
+ {
3512
+ "command": "<%= config.bin %> <%= command.id %> --force",
3513
+ "description": "Undeploy GraphQL API without confirmation prompt"
3514
+ },
3515
+ {
3516
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123 --dataset production",
3517
+ "description": "Undeploy GraphQL API for a specific project and dataset"
3782
3518
  }
3783
3519
  ],
3784
3520
  "flags": {
3785
3521
  "project-id": {
3786
3522
  "char": "p",
3787
- "description": "Project ID to deploy media aspect to (overrides CLI configuration)",
3523
+ "description": "Project ID to undeploy GraphQL API from (overrides CLI configuration)",
3788
3524
  "helpGroup": "OVERRIDE",
3789
3525
  "name": "project-id",
3790
3526
  "hasDynamicHelp": false,
@@ -3792,17 +3528,52 @@
3792
3528
  "multiple": false,
3793
3529
  "type": "option"
3794
3530
  },
3795
- "all": {
3796
- "description": "Deploy all aspects",
3797
- "name": "all",
3531
+ "api": {
3532
+ "description": "Undeploy API with this ID",
3533
+ "exclusive": [
3534
+ "project-id",
3535
+ "project"
3536
+ ],
3537
+ "name": "api",
3538
+ "required": false,
3539
+ "hasDynamicHelp": false,
3540
+ "multiple": false,
3541
+ "type": "option"
3542
+ },
3543
+ "dataset": {
3544
+ "char": "d",
3545
+ "description": "Dataset to undeploy GraphQL API from (overrides CLI configuration)",
3546
+ "helpGroup": "OVERRIDE",
3547
+ "name": "dataset",
3548
+ "hasDynamicHelp": false,
3549
+ "helpValue": "<name>",
3550
+ "multiple": false,
3551
+ "type": "option"
3552
+ },
3553
+ "force": {
3554
+ "description": "Skip confirmation prompt",
3555
+ "name": "force",
3798
3556
  "required": false,
3799
3557
  "allowNo": false,
3800
3558
  "type": "boolean"
3801
3559
  },
3802
- "media-library-id": {
3803
- "description": "The id of the target media library",
3804
- "name": "media-library-id",
3560
+ "project": {
3561
+ "deprecated": {
3562
+ "to": "project-id"
3563
+ },
3564
+ "description": "Project ID to delete GraphQL API for",
3565
+ "hidden": true,
3566
+ "name": "project",
3567
+ "required": false,
3568
+ "hasDynamicHelp": false,
3569
+ "multiple": false,
3570
+ "type": "option"
3571
+ },
3572
+ "tag": {
3573
+ "description": "Tag to undeploy GraphQL API from",
3574
+ "name": "tag",
3805
3575
  "required": false,
3576
+ "default": "default",
3806
3577
  "hasDynamicHelp": false,
3807
3578
  "multiple": false,
3808
3579
  "type": "option"
@@ -3810,7 +3581,7 @@
3810
3581
  },
3811
3582
  "hasDynamicHelp": false,
3812
3583
  "hiddenAliases": [],
3813
- "id": "media:deploy-aspect",
3584
+ "id": "graphql:undeploy",
3814
3585
  "pluginAlias": "@sanity/cli",
3815
3586
  "pluginName": "@sanity/cli",
3816
3587
  "pluginType": "core",
@@ -3819,75 +3590,37 @@
3819
3590
  "relativePath": [
3820
3591
  "dist",
3821
3592
  "commands",
3822
- "media",
3823
- "deploy-aspect.js"
3593
+ "graphql",
3594
+ "undeploy.js"
3824
3595
  ]
3825
3596
  },
3826
- "media:export": {
3597
+ "manifest:extract": {
3827
3598
  "aliases": [],
3828
- "args": {
3829
- "destination": {
3830
- "description": "Output destination file path",
3831
- "name": "destination"
3832
- }
3833
- },
3834
- "description": "Export file and image assets from a media library (excludes video)",
3599
+ "args": {},
3600
+ "description": "Extract studio configuration as JSON manifest files.\n\nNote: This command is experimental and subject to change. It is currently intended for use with Create only.",
3835
3601
  "examples": [
3836
3602
  {
3837
3603
  "command": "<%= config.bin %> <%= command.id %>",
3838
- "description": "Export media library interactively"
3839
- },
3840
- {
3841
- "command": "<%= config.bin %> <%= command.id %> output.tar.gz",
3842
- "description": "Export media library to output.tar.gz"
3604
+ "description": "Extracts manifests"
3843
3605
  },
3844
3606
  {
3845
- "command": "<%= config.bin %> <%= command.id %> --media-library-id my-library-id",
3846
- "description": "Export specific media library"
3607
+ "command": "<%= config.bin %> <%= command.id %> --path /public/static",
3608
+ "description": "Extracts manifests into /public/static"
3847
3609
  }
3848
3610
  ],
3849
3611
  "flags": {
3850
- "project-id": {
3851
- "char": "p",
3852
- "description": "Project ID to export media from (overrides CLI configuration)",
3853
- "helpGroup": "OVERRIDE",
3854
- "name": "project-id",
3855
- "hasDynamicHelp": false,
3856
- "helpValue": "<id>",
3857
- "multiple": false,
3858
- "type": "option"
3859
- },
3860
- "asset-concurrency": {
3861
- "description": "Concurrent number of asset downloads",
3862
- "name": "asset-concurrency",
3863
- "default": 8,
3864
- "hasDynamicHelp": false,
3865
- "multiple": false,
3866
- "type": "option"
3867
- },
3868
- "media-library-id": {
3869
- "description": "The id of the target media library",
3870
- "name": "media-library-id",
3612
+ "path": {
3613
+ "description": "Optional path to specify destination directory of the manifest files",
3614
+ "name": "path",
3615
+ "default": "dist/static",
3871
3616
  "hasDynamicHelp": false,
3872
3617
  "multiple": false,
3873
3618
  "type": "option"
3874
- },
3875
- "no-compress": {
3876
- "description": "Skips compressing tarball entries (still generates a gzip file)",
3877
- "name": "no-compress",
3878
- "allowNo": false,
3879
- "type": "boolean"
3880
- },
3881
- "overwrite": {
3882
- "description": "Overwrite any file with the same name",
3883
- "name": "overwrite",
3884
- "allowNo": false,
3885
- "type": "boolean"
3886
3619
  }
3887
3620
  },
3888
3621
  "hasDynamicHelp": false,
3889
3622
  "hiddenAliases": [],
3890
- "id": "media:export",
3623
+ "id": "manifest:extract",
3891
3624
  "pluginAlias": "@sanity/cli",
3892
3625
  "pluginName": "@sanity/cli",
3893
3626
  "pluginType": "core",
@@ -3896,62 +3629,24 @@
3896
3629
  "relativePath": [
3897
3630
  "dist",
3898
3631
  "commands",
3899
- "media",
3900
- "export.js"
3632
+ "manifest",
3633
+ "extract.js"
3901
3634
  ]
3902
3635
  },
3903
- "media:import": {
3636
+ "mcp:configure": {
3904
3637
  "aliases": [],
3905
- "args": {
3906
- "source": {
3907
- "description": "Image file or folder to import from",
3908
- "name": "source",
3909
- "required": true
3910
- }
3911
- },
3912
- "description": "Import a set of assets to the target media library.",
3638
+ "args": {},
3639
+ "description": "Configure Sanity MCP server for AI editors (Antigravity, Claude Code, Cline, Cline CLI, Codex CLI, Cursor, Gemini CLI, GitHub Copilot CLI, MCPorter, OpenCode, VS Code, VS Code Insiders, Zed)",
3913
3640
  "examples": [
3914
3641
  {
3915
- "command": "<%= config.bin %> <%= command.id %> products",
3916
- "description": "Import all assets from the \"products\" directory"
3917
- },
3918
- {
3919
- "command": "<%= config.bin %> <%= command.id %> gallery.tar.gz",
3920
- "description": "Import all assets from \"gallery\" archive"
3921
- },
3922
- {
3923
- "command": "<%= config.bin %> <%= command.id %> products --replace-aspects",
3924
- "description": "Import all assets from the \"products\" directory and replace aspects"
3925
- }
3926
- ],
3927
- "flags": {
3928
- "project-id": {
3929
- "char": "p",
3930
- "description": "Project ID to import media to (overrides CLI configuration)",
3931
- "helpGroup": "OVERRIDE",
3932
- "name": "project-id",
3933
- "hasDynamicHelp": false,
3934
- "helpValue": "<id>",
3935
- "multiple": false,
3936
- "type": "option"
3937
- },
3938
- "media-library-id": {
3939
- "description": "The id of the target media library",
3940
- "name": "media-library-id",
3941
- "hasDynamicHelp": false,
3942
- "multiple": false,
3943
- "type": "option"
3944
- },
3945
- "replace-aspects": {
3946
- "description": "Replace existing aspect data. All versions will be replaced (e.g. published and draft aspect data)",
3947
- "name": "replace-aspects",
3948
- "allowNo": false,
3949
- "type": "boolean"
3642
+ "command": "<%= config.bin %> <%= command.id %>",
3643
+ "description": "Configure Sanity MCP server for detected AI editors"
3950
3644
  }
3951
- },
3645
+ ],
3646
+ "flags": {},
3952
3647
  "hasDynamicHelp": false,
3953
3648
  "hiddenAliases": [],
3954
- "id": "media:import",
3649
+ "id": "mcp:configure",
3955
3650
  "pluginAlias": "@sanity/cli",
3956
3651
  "pluginName": "@sanity/cli",
3957
3652
  "pluginType": "core",
@@ -3960,8 +3655,8 @@
3960
3655
  "relativePath": [
3961
3656
  "dist",
3962
3657
  "commands",
3963
- "media",
3964
- "import.js"
3658
+ "mcp",
3659
+ "configure.js"
3965
3660
  ]
3966
3661
  },
3967
3662
  "migrations:create": {
@@ -4235,55 +3930,336 @@
4235
3930
  "relativePath": [
4236
3931
  "dist",
4237
3932
  "commands",
4238
- "openapi",
4239
- "list.js"
3933
+ "openapi",
3934
+ "list.js"
3935
+ ]
3936
+ },
3937
+ "organizations:create": {
3938
+ "aliases": [],
3939
+ "args": {},
3940
+ "description": "Create a new organization",
3941
+ "examples": [
3942
+ {
3943
+ "command": "<%= config.bin %> <%= command.id %>",
3944
+ "description": "Interactively create an organization"
3945
+ },
3946
+ {
3947
+ "command": "<%= config.bin %> <%= command.id %> --name \"Acme Corp\"",
3948
+ "description": "Create an organization named \"Acme Corp\""
3949
+ },
3950
+ {
3951
+ "command": "<%= config.bin %> <%= command.id %> --name \"Acme Corp\" --default-role member",
3952
+ "description": "Create an organization with a default member role"
3953
+ }
3954
+ ],
3955
+ "flags": {
3956
+ "default-role": {
3957
+ "description": "Default role assigned to new members",
3958
+ "name": "default-role",
3959
+ "required": false,
3960
+ "hasDynamicHelp": false,
3961
+ "multiple": false,
3962
+ "type": "option"
3963
+ },
3964
+ "name": {
3965
+ "description": "Organization name",
3966
+ "name": "name",
3967
+ "required": false,
3968
+ "hasDynamicHelp": false,
3969
+ "multiple": false,
3970
+ "type": "option"
3971
+ }
3972
+ },
3973
+ "hasDynamicHelp": false,
3974
+ "hiddenAliases": [
3975
+ "organization:create",
3976
+ "organisations:create",
3977
+ "organisation:create",
3978
+ "org:create",
3979
+ "orgs:create"
3980
+ ],
3981
+ "id": "organizations:create",
3982
+ "pluginAlias": "@sanity/cli",
3983
+ "pluginName": "@sanity/cli",
3984
+ "pluginType": "core",
3985
+ "strict": true,
3986
+ "isESM": true,
3987
+ "relativePath": [
3988
+ "dist",
3989
+ "commands",
3990
+ "organizations",
3991
+ "create.js"
3992
+ ]
3993
+ },
3994
+ "organizations:delete": {
3995
+ "aliases": [],
3996
+ "args": {
3997
+ "organizationId": {
3998
+ "description": "Organization ID to delete",
3999
+ "name": "organizationId",
4000
+ "required": true
4001
+ }
4002
+ },
4003
+ "description": "Delete an organization",
4004
+ "examples": [
4005
+ {
4006
+ "command": "<%= config.bin %> <%= command.id %> org-abc123",
4007
+ "description": "Delete an organization (prompts for confirmation)"
4008
+ },
4009
+ {
4010
+ "command": "<%= config.bin %> <%= command.id %> org-abc123 --force",
4011
+ "description": "Delete an organization without confirmation"
4012
+ }
4013
+ ],
4014
+ "flags": {
4015
+ "force": {
4016
+ "description": "Do not prompt for delete confirmation - forcefully delete",
4017
+ "name": "force",
4018
+ "required": false,
4019
+ "allowNo": false,
4020
+ "type": "boolean"
4021
+ }
4022
+ },
4023
+ "hasDynamicHelp": false,
4024
+ "hiddenAliases": [
4025
+ "organization:delete",
4026
+ "organisations:delete",
4027
+ "organisation:delete",
4028
+ "org:delete",
4029
+ "orgs:delete"
4030
+ ],
4031
+ "id": "organizations:delete",
4032
+ "pluginAlias": "@sanity/cli",
4033
+ "pluginName": "@sanity/cli",
4034
+ "pluginType": "core",
4035
+ "strict": true,
4036
+ "isESM": true,
4037
+ "relativePath": [
4038
+ "dist",
4039
+ "commands",
4040
+ "organizations",
4041
+ "delete.js"
4042
+ ]
4043
+ },
4044
+ "organizations:get": {
4045
+ "aliases": [],
4046
+ "args": {
4047
+ "organizationId": {
4048
+ "description": "Organization ID",
4049
+ "name": "organizationId",
4050
+ "required": true
4051
+ }
4052
+ },
4053
+ "description": "Get details of an organization",
4054
+ "examples": [
4055
+ {
4056
+ "command": "<%= config.bin %> <%= command.id %> org-abc123",
4057
+ "description": "Get details of a specific organization"
4058
+ }
4059
+ ],
4060
+ "flags": {},
4061
+ "hasDynamicHelp": false,
4062
+ "hiddenAliases": [
4063
+ "organization:get",
4064
+ "organisations:get",
4065
+ "organisation:get",
4066
+ "org:get",
4067
+ "orgs:get"
4068
+ ],
4069
+ "id": "organizations:get",
4070
+ "pluginAlias": "@sanity/cli",
4071
+ "pluginName": "@sanity/cli",
4072
+ "pluginType": "core",
4073
+ "strict": true,
4074
+ "isESM": true,
4075
+ "relativePath": [
4076
+ "dist",
4077
+ "commands",
4078
+ "organizations",
4079
+ "get.js"
4080
+ ]
4081
+ },
4082
+ "organizations:list": {
4083
+ "aliases": [],
4084
+ "args": {},
4085
+ "description": "List organizations you are a member of",
4086
+ "examples": [
4087
+ {
4088
+ "command": "<%= config.bin %> <%= command.id %>",
4089
+ "description": "List all your organizations"
4090
+ }
4091
+ ],
4092
+ "flags": {},
4093
+ "hasDynamicHelp": false,
4094
+ "hiddenAliases": [
4095
+ "organization:list",
4096
+ "organisations:list",
4097
+ "organisation:list",
4098
+ "org:list",
4099
+ "orgs:list"
4100
+ ],
4101
+ "id": "organizations:list",
4102
+ "pluginAlias": "@sanity/cli",
4103
+ "pluginName": "@sanity/cli",
4104
+ "pluginType": "core",
4105
+ "strict": true,
4106
+ "isESM": true,
4107
+ "relativePath": [
4108
+ "dist",
4109
+ "commands",
4110
+ "organizations",
4111
+ "list.js"
4112
+ ]
4113
+ },
4114
+ "organizations:update": {
4115
+ "aliases": [],
4116
+ "args": {
4117
+ "organizationId": {
4118
+ "description": "Organization ID",
4119
+ "name": "organizationId",
4120
+ "required": true
4121
+ }
4122
+ },
4123
+ "description": "Update an organization",
4124
+ "examples": [
4125
+ {
4126
+ "command": "<%= config.bin %> <%= command.id %> org-abc123 --name \"New Name\"",
4127
+ "description": "Rename an organization"
4128
+ },
4129
+ {
4130
+ "command": "<%= config.bin %> <%= command.id %> org-abc123 --slug new-slug",
4131
+ "description": "Set the organization slug (requires authSAML feature)"
4132
+ },
4133
+ {
4134
+ "command": "<%= config.bin %> <%= command.id %> org-abc123 --default-role viewer",
4135
+ "description": "Change the default member role"
4136
+ }
4137
+ ],
4138
+ "flags": {
4139
+ "default-role": {
4140
+ "description": "New default role for new members",
4141
+ "name": "default-role",
4142
+ "required": false,
4143
+ "hasDynamicHelp": false,
4144
+ "multiple": false,
4145
+ "type": "option"
4146
+ },
4147
+ "name": {
4148
+ "description": "New organization name",
4149
+ "name": "name",
4150
+ "required": false,
4151
+ "hasDynamicHelp": false,
4152
+ "multiple": false,
4153
+ "type": "option"
4154
+ },
4155
+ "slug": {
4156
+ "description": "New URL slug (requires authSAML feature on the organization)",
4157
+ "name": "slug",
4158
+ "required": false,
4159
+ "hasDynamicHelp": false,
4160
+ "multiple": false,
4161
+ "type": "option"
4162
+ }
4163
+ },
4164
+ "hasDynamicHelp": false,
4165
+ "hiddenAliases": [
4166
+ "organization:update",
4167
+ "organisations:update",
4168
+ "organisation:update",
4169
+ "org:update",
4170
+ "orgs:update"
4171
+ ],
4172
+ "id": "organizations:update",
4173
+ "pluginAlias": "@sanity/cli",
4174
+ "pluginName": "@sanity/cli",
4175
+ "pluginType": "core",
4176
+ "strict": true,
4177
+ "isESM": true,
4178
+ "relativePath": [
4179
+ "dist",
4180
+ "commands",
4181
+ "organizations",
4182
+ "update.js"
4240
4183
  ]
4241
4184
  },
4242
- "organizations:create": {
4185
+ "projects:create": {
4243
4186
  "aliases": [],
4244
- "args": {},
4245
- "description": "Create a new organization",
4187
+ "args": {
4188
+ "projectName": {
4189
+ "description": "Name of the project to create",
4190
+ "name": "projectName",
4191
+ "required": false
4192
+ }
4193
+ },
4194
+ "description": "Create a new Sanity project",
4246
4195
  "examples": [
4247
4196
  {
4248
4197
  "command": "<%= config.bin %> <%= command.id %>",
4249
- "description": "Interactively create an organization"
4198
+ "description": "Interactively create a project"
4250
4199
  },
4251
4200
  {
4252
- "command": "<%= config.bin %> <%= command.id %> --name \"Acme Corp\"",
4253
- "description": "Create an organization named \"Acme Corp\""
4201
+ "command": "<%= config.bin %> <%= command.id %> \"My New Project\"",
4202
+ "description": "Create a project named \"My New Project\""
4254
4203
  },
4255
4204
  {
4256
- "command": "<%= config.bin %> <%= command.id %> --name \"Acme Corp\" --default-role member",
4257
- "description": "Create an organization with a default member role"
4205
+ "command": "<%= config.bin %> <%= command.id %> \"My Project\" --organization=my-org",
4206
+ "description": "Create a project in a specific organization"
4207
+ },
4208
+ {
4209
+ "command": "<%= config.bin %> <%= command.id %> \"My Project\" --dataset=staging --dataset-visibility=private",
4210
+ "description": "Create a project with a private dataset named \"staging\""
4211
+ },
4212
+ {
4213
+ "command": "<%= config.bin %> <%= command.id %> \"CI Project\" --yes --json",
4214
+ "description": "Create a project non-interactively with JSON output"
4258
4215
  }
4259
4216
  ],
4260
4217
  "flags": {
4261
- "default-role": {
4262
- "description": "Default role assigned to new members",
4263
- "name": "default-role",
4264
- "required": false,
4218
+ "dataset": {
4219
+ "description": "Create a dataset. Prompts for visibility unless specified or --yes used",
4220
+ "name": "dataset",
4265
4221
  "hasDynamicHelp": false,
4266
4222
  "multiple": false,
4267
4223
  "type": "option"
4268
4224
  },
4269
- "name": {
4270
- "description": "Organization name",
4271
- "name": "name",
4272
- "required": false,
4225
+ "dataset-visibility": {
4226
+ "description": "Dataset visibility: public or private",
4227
+ "name": "dataset-visibility",
4228
+ "hasDynamicHelp": false,
4229
+ "multiple": false,
4230
+ "options": [
4231
+ "private",
4232
+ "public"
4233
+ ],
4234
+ "type": "option"
4235
+ },
4236
+ "json": {
4237
+ "description": "Output in JSON format",
4238
+ "name": "json",
4239
+ "allowNo": false,
4240
+ "type": "boolean"
4241
+ },
4242
+ "organization": {
4243
+ "description": "Organization to create the project in",
4244
+ "name": "organization",
4273
4245
  "hasDynamicHelp": false,
4246
+ "helpValue": "<slug|id>",
4274
4247
  "multiple": false,
4275
4248
  "type": "option"
4249
+ },
4250
+ "yes": {
4251
+ "char": "y",
4252
+ "description": "Skip prompts and use defaults (project: \"My Sanity Project\", dataset: production, visibility: public)",
4253
+ "name": "yes",
4254
+ "allowNo": false,
4255
+ "type": "boolean"
4276
4256
  }
4277
4257
  },
4278
4258
  "hasDynamicHelp": false,
4279
4259
  "hiddenAliases": [
4280
- "organization:create",
4281
- "organisations:create",
4282
- "organisation:create",
4283
- "org:create",
4284
- "orgs:create"
4260
+ "project:create"
4285
4261
  ],
4286
- "id": "organizations:create",
4262
+ "id": "projects:create",
4287
4263
  "pluginAlias": "@sanity/cli",
4288
4264
  "pluginName": "@sanity/cli",
4289
4265
  "pluginType": "core",
@@ -4292,48 +4268,58 @@
4292
4268
  "relativePath": [
4293
4269
  "dist",
4294
4270
  "commands",
4295
- "organizations",
4271
+ "projects",
4296
4272
  "create.js"
4297
4273
  ]
4298
4274
  },
4299
- "organizations:delete": {
4275
+ "projects:list": {
4300
4276
  "aliases": [],
4301
- "args": {
4302
- "organizationId": {
4303
- "description": "Organization ID to delete",
4304
- "name": "organizationId",
4305
- "required": true
4306
- }
4307
- },
4308
- "description": "Delete an organization",
4277
+ "args": {},
4278
+ "description": "List your projects",
4309
4279
  "examples": [
4310
4280
  {
4311
- "command": "<%= config.bin %> <%= command.id %> org-abc123",
4312
- "description": "Delete an organization (prompts for confirmation)"
4281
+ "command": "<%= config.bin %> <%= command.id %>",
4282
+ "description": "List projects"
4313
4283
  },
4314
4284
  {
4315
- "command": "<%= config.bin %> <%= command.id %> org-abc123 --force",
4316
- "description": "Delete an organization without confirmation"
4285
+ "command": "<%= config.bin %> <%= command.id %> --sort=members --order=asc",
4286
+ "description": "List projects sorted by member count, ascending"
4317
4287
  }
4318
4288
  ],
4319
4289
  "flags": {
4320
- "force": {
4321
- "description": "Do not prompt for delete confirmation - forcefully delete",
4322
- "name": "force",
4323
- "required": false,
4324
- "allowNo": false,
4325
- "type": "boolean"
4290
+ "order": {
4291
+ "description": "Sort direction",
4292
+ "name": "order",
4293
+ "default": "desc",
4294
+ "hasDynamicHelp": false,
4295
+ "multiple": false,
4296
+ "options": [
4297
+ "asc",
4298
+ "desc"
4299
+ ],
4300
+ "type": "option"
4301
+ },
4302
+ "sort": {
4303
+ "description": "Sort field",
4304
+ "name": "sort",
4305
+ "default": "created",
4306
+ "hasDynamicHelp": false,
4307
+ "multiple": false,
4308
+ "options": [
4309
+ "id",
4310
+ "members",
4311
+ "name",
4312
+ "url",
4313
+ "created"
4314
+ ],
4315
+ "type": "option"
4326
4316
  }
4327
4317
  },
4328
4318
  "hasDynamicHelp": false,
4329
4319
  "hiddenAliases": [
4330
- "organization:delete",
4331
- "organisations:delete",
4332
- "organisation:delete",
4333
- "org:delete",
4334
- "orgs:delete"
4320
+ "project:list"
4335
4321
  ],
4336
- "id": "organizations:delete",
4322
+ "id": "projects:list",
4337
4323
  "pluginAlias": "@sanity/cli",
4338
4324
  "pluginName": "@sanity/cli",
4339
4325
  "pluginType": "core",
@@ -4342,36 +4328,38 @@
4342
4328
  "relativePath": [
4343
4329
  "dist",
4344
4330
  "commands",
4345
- "organizations",
4346
- "delete.js"
4331
+ "projects",
4332
+ "list.js"
4347
4333
  ]
4348
4334
  },
4349
- "organizations:get": {
4335
+ "projects:unclaimed": {
4350
4336
  "aliases": [],
4351
- "args": {
4352
- "organizationId": {
4353
- "description": "Organization ID",
4354
- "name": "organizationId",
4355
- "required": true
4356
- }
4357
- },
4358
- "description": "Get details of an organization",
4337
+ "args": {},
4338
+ "description": "Recover details for unclaimed projects created on this machine",
4359
4339
  "examples": [
4360
4340
  {
4361
- "command": "<%= config.bin %> <%= command.id %> org-abc123",
4362
- "description": "Get details of a specific organization"
4341
+ "command": "<%= config.bin %> <%= command.id %>",
4342
+ "description": "List locally recorded unclaimed projects"
4343
+ },
4344
+ {
4345
+ "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4346
+ "description": "Show recovery details for one project"
4363
4347
  }
4364
4348
  ],
4365
- "flags": {},
4349
+ "flags": {
4350
+ "project-id": {
4351
+ "description": "Project ID to recover",
4352
+ "name": "project-id",
4353
+ "hasDynamicHelp": false,
4354
+ "multiple": false,
4355
+ "type": "option"
4356
+ }
4357
+ },
4366
4358
  "hasDynamicHelp": false,
4367
4359
  "hiddenAliases": [
4368
- "organization:get",
4369
- "organisations:get",
4370
- "organisation:get",
4371
- "org:get",
4372
- "orgs:get"
4360
+ "project:unclaimed"
4373
4361
  ],
4374
- "id": "organizations:get",
4362
+ "id": "projects:unclaimed",
4375
4363
  "pluginAlias": "@sanity/cli",
4376
4364
  "pluginName": "@sanity/cli",
4377
4365
  "pluginType": "core",
@@ -4380,30 +4368,39 @@
4380
4368
  "relativePath": [
4381
4369
  "dist",
4382
4370
  "commands",
4383
- "organizations",
4384
- "get.js"
4371
+ "projects",
4372
+ "unclaimed.js"
4385
4373
  ]
4386
4374
  },
4387
- "organizations:list": {
4375
+ "media:create-aspect": {
4388
4376
  "aliases": [],
4389
4377
  "args": {},
4390
- "description": "List organizations you are a member of",
4378
+ "description": "Create a new aspect definition file",
4391
4379
  "examples": [
4392
4380
  {
4393
4381
  "command": "<%= config.bin %> <%= command.id %>",
4394
- "description": "List all your organizations"
4382
+ "description": "Create a new aspect definition file"
4395
4383
  }
4396
4384
  ],
4397
- "flags": {},
4385
+ "flags": {
4386
+ "name": {
4387
+ "description": "Aspect name. Defaults to the title in camel case",
4388
+ "name": "name",
4389
+ "hasDynamicHelp": false,
4390
+ "multiple": false,
4391
+ "type": "option"
4392
+ },
4393
+ "title": {
4394
+ "description": "Aspect title",
4395
+ "name": "title",
4396
+ "hasDynamicHelp": false,
4397
+ "multiple": false,
4398
+ "type": "option"
4399
+ }
4400
+ },
4398
4401
  "hasDynamicHelp": false,
4399
- "hiddenAliases": [
4400
- "organization:list",
4401
- "organisations:list",
4402
- "organisation:list",
4403
- "org:list",
4404
- "orgs:list"
4405
- ],
4406
- "id": "organizations:list",
4402
+ "hiddenAliases": [],
4403
+ "id": "media:create-aspect",
4407
4404
  "pluginAlias": "@sanity/cli",
4408
4405
  "pluginName": "@sanity/cli",
4409
4406
  "pluginType": "core",
@@ -4412,69 +4409,59 @@
4412
4409
  "relativePath": [
4413
4410
  "dist",
4414
4411
  "commands",
4415
- "organizations",
4416
- "list.js"
4412
+ "media",
4413
+ "create-aspect.js"
4417
4414
  ]
4418
4415
  },
4419
- "organizations:update": {
4416
+ "media:delete-aspect": {
4420
4417
  "aliases": [],
4421
4418
  "args": {
4422
- "organizationId": {
4423
- "description": "Organization ID",
4424
- "name": "organizationId",
4419
+ "aspectName": {
4420
+ "description": "Name of the aspect to delete",
4421
+ "name": "aspectName",
4425
4422
  "required": true
4426
4423
  }
4427
4424
  },
4428
- "description": "Update an organization",
4425
+ "description": "Delete an aspect definition",
4429
4426
  "examples": [
4430
4427
  {
4431
- "command": "<%= config.bin %> <%= command.id %> org-abc123 --name \"New Name\"",
4432
- "description": "Rename an organization"
4433
- },
4434
- {
4435
- "command": "<%= config.bin %> <%= command.id %> org-abc123 --slug new-slug",
4436
- "description": "Set the organization slug (requires authSAML feature)"
4437
- },
4438
- {
4439
- "command": "<%= config.bin %> <%= command.id %> org-abc123 --default-role viewer",
4440
- "description": "Change the default member role"
4441
- }
4442
- ],
4443
- "flags": {
4444
- "default-role": {
4445
- "description": "New default role for new members",
4446
- "name": "default-role",
4447
- "required": false,
4428
+ "command": "<%= config.bin %> <%= command.id %> someAspect",
4429
+ "description": "Delete the aspect named \"someAspect\""
4430
+ }
4431
+ ],
4432
+ "flags": {
4433
+ "project-id": {
4434
+ "char": "p",
4435
+ "description": "Project ID to delete media aspect from (overrides CLI configuration)",
4436
+ "helpGroup": "OVERRIDE",
4437
+ "name": "project-id",
4448
4438
  "hasDynamicHelp": false,
4439
+ "helpValue": "<id>",
4449
4440
  "multiple": false,
4450
4441
  "type": "option"
4451
4442
  },
4452
- "name": {
4453
- "description": "New organization name",
4454
- "name": "name",
4443
+ "media-library-id": {
4444
+ "description": "The id of the target media library",
4445
+ "name": "media-library-id",
4455
4446
  "required": false,
4456
4447
  "hasDynamicHelp": false,
4457
4448
  "multiple": false,
4458
4449
  "type": "option"
4459
4450
  },
4460
- "slug": {
4461
- "description": "New URL slug (requires authSAML feature on the organization)",
4462
- "name": "slug",
4451
+ "yes": {
4452
+ "aliases": [
4453
+ "y"
4454
+ ],
4455
+ "description": "Run without prompts and confirm deletion",
4456
+ "name": "yes",
4463
4457
  "required": false,
4464
- "hasDynamicHelp": false,
4465
- "multiple": false,
4466
- "type": "option"
4458
+ "allowNo": false,
4459
+ "type": "boolean"
4467
4460
  }
4468
4461
  },
4469
4462
  "hasDynamicHelp": false,
4470
- "hiddenAliases": [
4471
- "organization:update",
4472
- "organisations:update",
4473
- "organisation:update",
4474
- "org:update",
4475
- "orgs:update"
4476
- ],
4477
- "id": "organizations:update",
4463
+ "hiddenAliases": [],
4464
+ "id": "media:delete-aspect",
4478
4465
  "pluginAlias": "@sanity/cli",
4479
4466
  "pluginName": "@sanity/cli",
4480
4467
  "pluginType": "core",
@@ -4483,88 +4470,60 @@
4483
4470
  "relativePath": [
4484
4471
  "dist",
4485
4472
  "commands",
4486
- "organizations",
4487
- "update.js"
4473
+ "media",
4474
+ "delete-aspect.js"
4488
4475
  ]
4489
4476
  },
4490
- "projects:create": {
4477
+ "media:deploy-aspect": {
4491
4478
  "aliases": [],
4492
4479
  "args": {
4493
- "projectName": {
4494
- "description": "Name of the project to create",
4495
- "name": "projectName",
4480
+ "aspectName": {
4481
+ "description": "Name of the aspect to deploy",
4482
+ "name": "aspectName",
4496
4483
  "required": false
4497
4484
  }
4498
4485
  },
4499
- "description": "Create a new Sanity project",
4486
+ "description": "Deploy an aspect",
4500
4487
  "examples": [
4501
4488
  {
4502
- "command": "<%= config.bin %> <%= command.id %>",
4503
- "description": "Interactively create a project"
4504
- },
4505
- {
4506
- "command": "<%= config.bin %> <%= command.id %> \"My New Project\"",
4507
- "description": "Create a project named \"My New Project\""
4508
- },
4509
- {
4510
- "command": "<%= config.bin %> <%= command.id %> \"My Project\" --organization=my-org",
4511
- "description": "Create a project in a specific organization"
4512
- },
4513
- {
4514
- "command": "<%= config.bin %> <%= command.id %> \"My Project\" --dataset=staging --dataset-visibility=private",
4515
- "description": "Create a project with a private dataset named \"staging\""
4489
+ "command": "<%= config.bin %> <%= command.id %> someAspect",
4490
+ "description": "Deploy the aspect named \"someAspect\""
4516
4491
  },
4517
4492
  {
4518
- "command": "<%= config.bin %> <%= command.id %> \"CI Project\" --yes --json",
4519
- "description": "Create a project non-interactively with JSON output"
4493
+ "command": "<%= config.bin %> <%= command.id %> --all",
4494
+ "description": "Deploy all aspects"
4520
4495
  }
4521
4496
  ],
4522
4497
  "flags": {
4523
- "dataset": {
4524
- "description": "Create a dataset. Prompts for visibility unless specified or --yes used",
4525
- "name": "dataset",
4526
- "hasDynamicHelp": false,
4527
- "multiple": false,
4528
- "type": "option"
4529
- },
4530
- "dataset-visibility": {
4531
- "description": "Dataset visibility: public or private",
4532
- "name": "dataset-visibility",
4498
+ "project-id": {
4499
+ "char": "p",
4500
+ "description": "Project ID to deploy media aspect to (overrides CLI configuration)",
4501
+ "helpGroup": "OVERRIDE",
4502
+ "name": "project-id",
4533
4503
  "hasDynamicHelp": false,
4504
+ "helpValue": "<id>",
4534
4505
  "multiple": false,
4535
- "options": [
4536
- "private",
4537
- "public"
4538
- ],
4539
4506
  "type": "option"
4540
4507
  },
4541
- "json": {
4542
- "description": "Output in JSON format",
4543
- "name": "json",
4508
+ "all": {
4509
+ "description": "Deploy all aspects",
4510
+ "name": "all",
4511
+ "required": false,
4544
4512
  "allowNo": false,
4545
4513
  "type": "boolean"
4546
4514
  },
4547
- "organization": {
4548
- "description": "Organization to create the project in",
4549
- "name": "organization",
4515
+ "media-library-id": {
4516
+ "description": "The id of the target media library",
4517
+ "name": "media-library-id",
4518
+ "required": false,
4550
4519
  "hasDynamicHelp": false,
4551
- "helpValue": "<slug|id>",
4552
4520
  "multiple": false,
4553
4521
  "type": "option"
4554
- },
4555
- "yes": {
4556
- "char": "y",
4557
- "description": "Skip prompts and use defaults (project: \"My Sanity Project\", dataset: production, visibility: public)",
4558
- "name": "yes",
4559
- "allowNo": false,
4560
- "type": "boolean"
4561
4522
  }
4562
4523
  },
4563
4524
  "hasDynamicHelp": false,
4564
- "hiddenAliases": [
4565
- "project:create"
4566
- ],
4567
- "id": "projects:create",
4525
+ "hiddenAliases": [],
4526
+ "id": "media:deploy-aspect",
4568
4527
  "pluginAlias": "@sanity/cli",
4569
4528
  "pluginName": "@sanity/cli",
4570
4529
  "pluginType": "core",
@@ -4573,58 +4532,75 @@
4573
4532
  "relativePath": [
4574
4533
  "dist",
4575
4534
  "commands",
4576
- "projects",
4577
- "create.js"
4535
+ "media",
4536
+ "deploy-aspect.js"
4578
4537
  ]
4579
4538
  },
4580
- "projects:list": {
4539
+ "media:export": {
4581
4540
  "aliases": [],
4582
- "args": {},
4583
- "description": "List your projects",
4541
+ "args": {
4542
+ "destination": {
4543
+ "description": "Output destination file path",
4544
+ "name": "destination"
4545
+ }
4546
+ },
4547
+ "description": "Export file and image assets from a media library (excludes video)",
4584
4548
  "examples": [
4585
4549
  {
4586
4550
  "command": "<%= config.bin %> <%= command.id %>",
4587
- "description": "List projects"
4551
+ "description": "Export media library interactively"
4588
4552
  },
4589
4553
  {
4590
- "command": "<%= config.bin %> <%= command.id %> --sort=members --order=asc",
4591
- "description": "List projects sorted by member count, ascending"
4554
+ "command": "<%= config.bin %> <%= command.id %> output.tar.gz",
4555
+ "description": "Export media library to output.tar.gz"
4556
+ },
4557
+ {
4558
+ "command": "<%= config.bin %> <%= command.id %> --media-library-id my-library-id",
4559
+ "description": "Export specific media library"
4592
4560
  }
4593
4561
  ],
4594
4562
  "flags": {
4595
- "order": {
4596
- "description": "Sort direction",
4597
- "name": "order",
4598
- "default": "desc",
4563
+ "project-id": {
4564
+ "char": "p",
4565
+ "description": "Project ID to export media from (overrides CLI configuration)",
4566
+ "helpGroup": "OVERRIDE",
4567
+ "name": "project-id",
4599
4568
  "hasDynamicHelp": false,
4569
+ "helpValue": "<id>",
4600
4570
  "multiple": false,
4601
- "options": [
4602
- "asc",
4603
- "desc"
4604
- ],
4605
4571
  "type": "option"
4606
4572
  },
4607
- "sort": {
4608
- "description": "Sort field",
4609
- "name": "sort",
4610
- "default": "created",
4573
+ "asset-concurrency": {
4574
+ "description": "Concurrent number of asset downloads",
4575
+ "name": "asset-concurrency",
4576
+ "default": 8,
4577
+ "hasDynamicHelp": false,
4578
+ "multiple": false,
4579
+ "type": "option"
4580
+ },
4581
+ "media-library-id": {
4582
+ "description": "The id of the target media library",
4583
+ "name": "media-library-id",
4611
4584
  "hasDynamicHelp": false,
4612
4585
  "multiple": false,
4613
- "options": [
4614
- "id",
4615
- "members",
4616
- "name",
4617
- "url",
4618
- "created"
4619
- ],
4620
4586
  "type": "option"
4587
+ },
4588
+ "no-compress": {
4589
+ "description": "Skips compressing tarball entries (still generates a gzip file)",
4590
+ "name": "no-compress",
4591
+ "allowNo": false,
4592
+ "type": "boolean"
4593
+ },
4594
+ "overwrite": {
4595
+ "description": "Overwrite any file with the same name",
4596
+ "name": "overwrite",
4597
+ "allowNo": false,
4598
+ "type": "boolean"
4621
4599
  }
4622
4600
  },
4623
4601
  "hasDynamicHelp": false,
4624
- "hiddenAliases": [
4625
- "project:list"
4626
- ],
4627
- "id": "projects:list",
4602
+ "hiddenAliases": [],
4603
+ "id": "media:export",
4628
4604
  "pluginAlias": "@sanity/cli",
4629
4605
  "pluginName": "@sanity/cli",
4630
4606
  "pluginType": "core",
@@ -4633,38 +4609,62 @@
4633
4609
  "relativePath": [
4634
4610
  "dist",
4635
4611
  "commands",
4636
- "projects",
4637
- "list.js"
4612
+ "media",
4613
+ "export.js"
4638
4614
  ]
4639
4615
  },
4640
- "projects:unclaimed": {
4616
+ "media:import": {
4641
4617
  "aliases": [],
4642
- "args": {},
4643
- "description": "Recover details for unclaimed projects created on this machine",
4618
+ "args": {
4619
+ "source": {
4620
+ "description": "Image file or folder to import from",
4621
+ "name": "source",
4622
+ "required": true
4623
+ }
4624
+ },
4625
+ "description": "Import a set of assets to the target media library.",
4644
4626
  "examples": [
4645
4627
  {
4646
- "command": "<%= config.bin %> <%= command.id %>",
4647
- "description": "List locally recorded unclaimed projects"
4628
+ "command": "<%= config.bin %> <%= command.id %> products",
4629
+ "description": "Import all assets from the \"products\" directory"
4648
4630
  },
4649
4631
  {
4650
- "command": "<%= config.bin %> <%= command.id %> --project-id abc123",
4651
- "description": "Show recovery details for one project"
4632
+ "command": "<%= config.bin %> <%= command.id %> gallery.tar.gz",
4633
+ "description": "Import all assets from \"gallery\" archive"
4634
+ },
4635
+ {
4636
+ "command": "<%= config.bin %> <%= command.id %> products --replace-aspects",
4637
+ "description": "Import all assets from the \"products\" directory and replace aspects"
4652
4638
  }
4653
4639
  ],
4654
4640
  "flags": {
4655
4641
  "project-id": {
4656
- "description": "Project ID to recover",
4642
+ "char": "p",
4643
+ "description": "Project ID to import media to (overrides CLI configuration)",
4644
+ "helpGroup": "OVERRIDE",
4657
4645
  "name": "project-id",
4658
4646
  "hasDynamicHelp": false,
4647
+ "helpValue": "<id>",
4648
+ "multiple": false,
4649
+ "type": "option"
4650
+ },
4651
+ "media-library-id": {
4652
+ "description": "The id of the target media library",
4653
+ "name": "media-library-id",
4654
+ "hasDynamicHelp": false,
4659
4655
  "multiple": false,
4660
4656
  "type": "option"
4657
+ },
4658
+ "replace-aspects": {
4659
+ "description": "Replace existing aspect data. All versions will be replaced (e.g. published and draft aspect data)",
4660
+ "name": "replace-aspects",
4661
+ "allowNo": false,
4662
+ "type": "boolean"
4661
4663
  }
4662
4664
  },
4663
4665
  "hasDynamicHelp": false,
4664
- "hiddenAliases": [
4665
- "project:unclaimed"
4666
- ],
4667
- "id": "projects:unclaimed",
4666
+ "hiddenAliases": [],
4667
+ "id": "media:import",
4668
4668
  "pluginAlias": "@sanity/cli",
4669
4669
  "pluginName": "@sanity/cli",
4670
4670
  "pluginType": "core",
@@ -4673,8 +4673,8 @@
4673
4673
  "relativePath": [
4674
4674
  "dist",
4675
4675
  "commands",
4676
- "projects",
4677
- "unclaimed.js"
4676
+ "media",
4677
+ "import.js"
4678
4678
  ]
4679
4679
  },
4680
4680
  "schemas:delete": {
@@ -6161,5 +6161,5 @@
6161
6161
  ]
6162
6162
  }
6163
6163
  },
6164
- "version": "8.0.2"
6164
+ "version": "8.0.3"
6165
6165
  }