@datocms/cma-client 5.2.0-alpha.4 → 5.2.0-alpha.5

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 (31) hide show
  1. package/README.md +4 -0
  2. package/dist/cjs/generated/Client.js +1 -1
  3. package/dist/cjs/generated/resources/ItemType.js +12 -12
  4. package/dist/cjs/generated/resources/SearchIndex.js +10 -22
  5. package/dist/cjs/generated/resources/SearchIndex.js.map +1 -1
  6. package/dist/cjs/utilities/schemaRepository.js +131 -0
  7. package/dist/cjs/utilities/schemaRepository.js.map +1 -1
  8. package/dist/esm/generated/ApiTypes.d.ts +161 -158
  9. package/dist/esm/generated/Client.js +1 -1
  10. package/dist/esm/generated/RawApiTypes.d.ts +148 -141
  11. package/dist/esm/generated/resources/ItemType.d.ts +12 -12
  12. package/dist/esm/generated/resources/ItemType.js +12 -12
  13. package/dist/esm/generated/resources/SearchIndex.d.ts +8 -8
  14. package/dist/esm/generated/resources/SearchIndex.js +10 -22
  15. package/dist/esm/generated/resources/SearchIndex.js.map +1 -1
  16. package/dist/esm/utilities/schemaRepository.d.ts +42 -2
  17. package/dist/esm/utilities/schemaRepository.js +132 -1
  18. package/dist/esm/utilities/schemaRepository.js.map +1 -1
  19. package/dist/types/generated/ApiTypes.d.ts +161 -158
  20. package/dist/types/generated/RawApiTypes.d.ts +148 -141
  21. package/dist/types/generated/resources/ItemType.d.ts +12 -12
  22. package/dist/types/generated/resources/SearchIndex.d.ts +8 -8
  23. package/dist/types/utilities/schemaRepository.d.ts +42 -2
  24. package/package.json +3 -3
  25. package/resources.json +10 -12
  26. package/src/generated/ApiTypes.ts +161 -158
  27. package/src/generated/Client.ts +1 -1
  28. package/src/generated/RawApiTypes.ts +148 -141
  29. package/src/generated/resources/ItemType.ts +12 -12
  30. package/src/generated/resources/SearchIndex.ts +10 -22
  31. package/src/utilities/schemaRepository.ts +167 -9
@@ -764,19 +764,19 @@ export type ItemInstancesHrefSchema<
764
764
  */
765
765
  filter?: {
766
766
  /**
767
- * Record (or block record) IDs to fetch, comma separated. If you use this filter, you _must not_ use `filter[type]` or `filter[fields]`
767
+ * Record (or block record) IDs to fetch, comma separated. If you use this filter, you _must not_ use `filter[type]`. You can combine it with meta fields (like `_published_at`, `_status`), but _must not_ use model-specific fields
768
768
  */
769
769
  ids?: string;
770
770
  /**
771
- * Model ID or `api_key` to filter. If you use this filter, you _must not_ use `filter[ids]`. Comma separated values are accepted, but you _must not_ use `filter[fields]` in this case
771
+ * Model/Block model ID or `api_key` to filter. If you use this filter, you _must not_ use `filter[ids]`. When passing a single element, you can use both meta fields and model-specific fields (note: model-specific fields only work with models, not block models). When passing multiple comma-separated values, you can use meta fields but _must not_ use model-specific fields
772
772
  */
773
773
  type?: string;
774
774
  /**
775
- * Textual query to match. You _must not_ use `filter[ids]`. If `locale` is defined, search within that locale. Otherwise environment's main locale will be used.
775
+ * Textual query to match. Can be combined with other filters. When used, only records (not blocks) are returned. If `locale` is defined, search within that locale. Otherwise environment's main locale will be used.
776
776
  */
777
777
  query?: string;
778
778
  /**
779
- * Same as [GraphQL API records filters](/docs/content-delivery-api/filtering-records): you must use square brackets to indicate nesting levels. E.g. if you wanna [filter by parent record](/docs/content-delivery-api/filtering-records#parent) in a tree of records, you must use `filter[fields][parent][eq]=<ID_VALUE>`. Use snake_case for fields names. If `locale` is defined, search within that locale. Otherwise environment's main locale will be used.
779
+ * Filter by record fields. Meta fields (like `_published_at`, `_status`) can be used in most cases. Model-specific fields (like `title`, `name`) require `filter[type]` to specify a single model, and only work with models (not block models). Same syntax as [GraphQL API records filters](/docs/content-delivery-api/filtering-records): use square brackets to indicate nesting levels. E.g. `filter[fields][parent][eq]=<ID_VALUE>`. Use snake_case for field names. If `locale` is defined, search within that locale. Otherwise environment's main locale will be used.
780
780
  */
781
781
  fields?: ToItemHrefSchemaField<D>;
782
782
  /**
@@ -837,7 +837,7 @@ export type ItemSelfHrefSchema = {
837
837
  */
838
838
  nested?: boolean;
839
839
  /**
840
- * Whether you want the currently published versions (`published`, default) of your records, or the latest available (`current`)
840
+ * Whether you want the currently published versions (`published`) of your records, or the latest available (`current`, default)
841
841
  */
842
842
  version?: string;
843
843
  [k: string]: unknown;
@@ -1150,11 +1150,11 @@ export type SearchResultInstancesHrefSchema = {
1150
1150
  */
1151
1151
  query: string;
1152
1152
  /**
1153
- * The search index ID or name on which the search will be performed. If not provided, the first enabled search index will be used.
1153
+ * The search index ID on which the search will be performed. If not provided, the first enabled search index will be used.
1154
1154
  */
1155
1155
  search_index_id?: string;
1156
1156
  /**
1157
- * **[Deprecated]** Use `search_index_id` instead. The build trigger ID or name on which the search will be performed. This parameter is only supported for backward compatibility and will return an error if the build trigger has multiple search indexes associated.
1157
+ * The build trigger ID or name on which the search will be performed.
1158
1158
  */
1159
1159
  build_trigger_id?: string;
1160
1160
  /**
@@ -1679,7 +1679,7 @@ export type RoleAttributes = {
1679
1679
  */
1680
1680
  can_edit_site: boolean;
1681
1681
  /**
1682
- * Can create/edit models and plugins
1682
+ * Can create and edit models and plugins
1683
1683
  */
1684
1684
  can_edit_schema: boolean;
1685
1685
  /**
@@ -1699,31 +1699,31 @@ export type RoleAttributes = {
1699
1699
  */
1700
1700
  environments_access: 'all' | 'primary_only' | 'sandbox_only' | 'none';
1701
1701
  /**
1702
- * Can create/edit roles and invite/remove collaborators
1702
+ * Can create and edit roles and invite/remove collaborators
1703
1703
  */
1704
1704
  can_manage_users: boolean;
1705
1705
  /**
1706
- * Can create/edit shared filters (both for models and the media area)
1706
+ * Can create and edit shared filters (both for models and the media area)
1707
1707
  */
1708
1708
  can_manage_shared_filters: boolean;
1709
1709
  /**
1710
- * Can create/edit upload collections
1710
+ * Can create and edit upload collections
1711
1711
  */
1712
1712
  can_manage_upload_collections: boolean;
1713
1713
  /**
1714
- * Can create/edit Build triggers
1714
+ * Can create and edit build triggers
1715
1715
  */
1716
1716
  can_manage_build_triggers: boolean;
1717
1717
  /**
1718
- * Can create/edit Search Indexes
1718
+ * Can create and edit search indexes
1719
1719
  */
1720
1720
  can_manage_search_indexes: boolean;
1721
1721
  /**
1722
- * Can create/edit webhooks
1722
+ * Can create and edit webhooks
1723
1723
  */
1724
1724
  can_manage_webhooks: boolean;
1725
1725
  /**
1726
- * Can create/delete sandbox environments and promote them to primary environment
1726
+ * Can create and delete sandbox environments and promote them to primary environment
1727
1727
  */
1728
1728
  can_manage_environments: boolean;
1729
1729
  /**
@@ -1735,7 +1735,7 @@ export type RoleAttributes = {
1735
1735
  */
1736
1736
  can_access_audit_log: boolean;
1737
1737
  /**
1738
- * Can create/edit workflows
1738
+ * Can create and edit workflows
1739
1739
  */
1740
1740
  can_manage_workflows: boolean;
1741
1741
  /**
@@ -1897,13 +1897,13 @@ export type RoleAttributes = {
1897
1897
  build_trigger?: BuildTriggerIdentity | null;
1898
1898
  }[];
1899
1899
  /**
1900
- * Allowed search indexes for a role
1900
+ * Search indexes that can be triggered by a role
1901
1901
  */
1902
1902
  positive_search_index_permissions: {
1903
1903
  search_index?: SearchIndexIdentity | null;
1904
1904
  }[];
1905
1905
  /**
1906
- * Prohibited search indexes for a role
1906
+ * Search indexes that can't be triggered by a role
1907
1907
  */
1908
1908
  negative_search_index_permissions: {
1909
1909
  search_index?: SearchIndexIdentity | null;
@@ -1953,7 +1953,7 @@ export type RoleMeta = {
1953
1953
  */
1954
1954
  can_edit_site: boolean;
1955
1955
  /**
1956
- * Can create/edit models and plugins
1956
+ * Can create and edit models and plugins
1957
1957
  */
1958
1958
  can_edit_schema: boolean;
1959
1959
  /**
@@ -1973,31 +1973,31 @@ export type RoleMeta = {
1973
1973
  */
1974
1974
  environments_access: 'all' | 'primary_only' | 'sandbox_only' | 'none';
1975
1975
  /**
1976
- * Can create/edit roles and invite/remove collaborators
1976
+ * Can create and edit roles and invite/remove collaborators
1977
1977
  */
1978
1978
  can_manage_users: boolean;
1979
1979
  /**
1980
- * Can create/edit shared filters (both for models and the media area)
1980
+ * Can create and edit shared filters (both for models and the media area)
1981
1981
  */
1982
1982
  can_manage_shared_filters: boolean;
1983
1983
  /**
1984
- * Can create/edit upload collections
1984
+ * Can create and edit upload collections
1985
1985
  */
1986
1986
  can_manage_upload_collections: boolean;
1987
1987
  /**
1988
- * Can create/edit Build triggers
1988
+ * Can create and edit build triggers
1989
1989
  */
1990
1990
  can_manage_build_triggers: boolean;
1991
1991
  /**
1992
- * Can create/edit Search Indexes
1992
+ * Can create and edit search indexes
1993
1993
  */
1994
1994
  can_manage_search_indexes: boolean;
1995
1995
  /**
1996
- * Can create/edit webhooks
1996
+ * Can create and edit webhooks
1997
1997
  */
1998
1998
  can_manage_webhooks: boolean;
1999
1999
  /**
2000
- * Can create/delete sandbox environments and promote them to primary environment
2000
+ * Can create and delete sandbox environments and promote them to primary environment
2001
2001
  */
2002
2002
  can_manage_environments: boolean;
2003
2003
  /**
@@ -2009,7 +2009,7 @@ export type RoleMeta = {
2009
2009
  */
2010
2010
  can_access_audit_log: boolean;
2011
2011
  /**
2012
- * Can create/edit workflows
2012
+ * Can create and edit workflows
2013
2013
  */
2014
2014
  can_manage_workflows: boolean;
2015
2015
  /**
@@ -2171,13 +2171,13 @@ export type RoleMeta = {
2171
2171
  build_trigger?: BuildTriggerIdentity | null;
2172
2172
  }[];
2173
2173
  /**
2174
- * Allowed search indexes for a role
2174
+ * Search indexes that can be triggered by a role
2175
2175
  */
2176
2176
  positive_search_index_permissions: {
2177
2177
  search_index?: SearchIndexIdentity | null;
2178
2178
  }[];
2179
2179
  /**
2180
- * Prohibited search indexes for a role
2180
+ * Search indexes that can't be triggered by a role
2181
2181
  */
2182
2182
  negative_search_index_permissions: {
2183
2183
  search_index?: SearchIndexIdentity | null;
@@ -2208,7 +2208,7 @@ export type RoleCreateSchema = {
2208
2208
  */
2209
2209
  can_edit_site?: boolean;
2210
2210
  /**
2211
- * Can create/edit models and plugins
2211
+ * Can create and edit models and plugins
2212
2212
  */
2213
2213
  can_edit_schema?: boolean;
2214
2214
  /**
@@ -2228,31 +2228,31 @@ export type RoleCreateSchema = {
2228
2228
  */
2229
2229
  environments_access?: 'all' | 'primary_only' | 'sandbox_only' | 'none';
2230
2230
  /**
2231
- * Can create/edit roles and invite/remove collaborators
2231
+ * Can create and edit roles and invite/remove collaborators
2232
2232
  */
2233
2233
  can_manage_users?: boolean;
2234
2234
  /**
2235
- * Can create/edit shared filters (both for models and the media area)
2235
+ * Can create and edit shared filters (both for models and the media area)
2236
2236
  */
2237
2237
  can_manage_shared_filters?: boolean;
2238
2238
  /**
2239
- * Can create/edit Search Indexes
2239
+ * Can create and edit search indexes
2240
2240
  */
2241
2241
  can_manage_search_indexes?: boolean;
2242
2242
  /**
2243
- * Can create/edit upload collections
2243
+ * Can create and edit upload collections
2244
2244
  */
2245
2245
  can_manage_upload_collections?: boolean;
2246
2246
  /**
2247
- * Can create/edit Build triggers
2247
+ * Can create and edit build triggers
2248
2248
  */
2249
2249
  can_manage_build_triggers?: boolean;
2250
2250
  /**
2251
- * Can create/edit webhooks
2251
+ * Can create and edit webhooks
2252
2252
  */
2253
2253
  can_manage_webhooks?: boolean;
2254
2254
  /**
2255
- * Can create/delete sandbox environments and promote them to primary environment
2255
+ * Can create and delete sandbox environments and promote them to primary environment
2256
2256
  */
2257
2257
  can_manage_environments?: boolean;
2258
2258
  /**
@@ -2264,7 +2264,7 @@ export type RoleCreateSchema = {
2264
2264
  */
2265
2265
  can_access_audit_log?: boolean;
2266
2266
  /**
2267
- * Can create/edit workflows
2267
+ * Can create and edit workflows
2268
2268
  */
2269
2269
  can_manage_workflows?: boolean;
2270
2270
  /**
@@ -2426,13 +2426,13 @@ export type RoleCreateSchema = {
2426
2426
  build_trigger?: BuildTriggerIdentity | null;
2427
2427
  }[];
2428
2428
  /**
2429
- * Allowed search indexes for a role
2429
+ * Search indexes that can be triggered by a role
2430
2430
  */
2431
2431
  positive_search_index_permissions?: {
2432
2432
  search_index?: SearchIndexIdentity | null;
2433
2433
  }[];
2434
2434
  /**
2435
- * Prohibited search indexes for a role
2435
+ * Search indexes that can't be triggered by a role
2436
2436
  */
2437
2437
  negative_search_index_permissions?: {
2438
2438
  search_index?: SearchIndexIdentity | null;
@@ -2484,7 +2484,7 @@ export type RoleUpdateSchema = {
2484
2484
  */
2485
2485
  can_edit_site?: boolean;
2486
2486
  /**
2487
- * Can create/edit models and plugins
2487
+ * Can create and edit models and plugins
2488
2488
  */
2489
2489
  can_edit_schema?: boolean;
2490
2490
  /**
@@ -2504,31 +2504,31 @@ export type RoleUpdateSchema = {
2504
2504
  */
2505
2505
  environments_access?: 'all' | 'primary_only' | 'sandbox_only' | 'none';
2506
2506
  /**
2507
- * Can create/edit roles and invite/remove collaborators
2507
+ * Can create and edit roles and invite/remove collaborators
2508
2508
  */
2509
2509
  can_manage_users?: boolean;
2510
2510
  /**
2511
- * Can create/edit shared filters (both for models and the media area)
2511
+ * Can create and edit shared filters (both for models and the media area)
2512
2512
  */
2513
2513
  can_manage_shared_filters?: boolean;
2514
2514
  /**
2515
- * Can create/edit Search Indexes
2515
+ * Can create and edit search indexes
2516
2516
  */
2517
2517
  can_manage_search_indexes?: boolean;
2518
2518
  /**
2519
- * Can create/edit upload collections
2519
+ * Can create and edit upload collections
2520
2520
  */
2521
2521
  can_manage_upload_collections?: boolean;
2522
2522
  /**
2523
- * Can create/edit Build triggers
2523
+ * Can create and edit build triggers
2524
2524
  */
2525
2525
  can_manage_build_triggers?: boolean;
2526
2526
  /**
2527
- * Can create/edit webhooks
2527
+ * Can create and edit webhooks
2528
2528
  */
2529
2529
  can_manage_webhooks?: boolean;
2530
2530
  /**
2531
- * Can create/delete sandbox environments and promote them to primary environment
2531
+ * Can create and delete sandbox environments and promote them to primary environment
2532
2532
  */
2533
2533
  can_manage_environments?: boolean;
2534
2534
  /**
@@ -2540,7 +2540,7 @@ export type RoleUpdateSchema = {
2540
2540
  */
2541
2541
  can_access_audit_log?: boolean;
2542
2542
  /**
2543
- * Can create/edit workflows
2543
+ * Can create and edit workflows
2544
2544
  */
2545
2545
  can_manage_workflows?: boolean;
2546
2546
  /**
@@ -2702,13 +2702,13 @@ export type RoleUpdateSchema = {
2702
2702
  build_trigger?: BuildTriggerIdentity | null;
2703
2703
  }[];
2704
2704
  /**
2705
- * Allowed search indexes for a role
2705
+ * Search indexes that can be triggered by a role
2706
2706
  */
2707
2707
  positive_search_index_permissions?: {
2708
2708
  search_index?: SearchIndexIdentity | null;
2709
2709
  }[];
2710
2710
  /**
2711
- * Prohibited search indexes for a role
2711
+ * Search indexes that can't be triggered by a role
2712
2712
  */
2713
2713
  negative_search_index_permissions?: {
2714
2714
  search_index?: SearchIndexIdentity | null;
@@ -4411,7 +4411,26 @@ export type UploadCollectionReorderJobSchema = {
4411
4411
  data: UploadCollection[];
4412
4412
  };
4413
4413
  /**
4414
- * The way you define the kind of content you can edit inside your administrative area passes through the concept of Models, which are much like database tables. For backward-compatibility reasons, the API refers to models as "item types".
4414
+ * The way you define the kind of content you can edit inside a DatoCMS project passes through the concept of **models** and **block models**. For backward-compatibility reasons, the API refers to both as "item types".
4415
+ *
4416
+ * ## Models
4417
+ *
4418
+ * Models are much like database tables — they define the structure of your main content types (e.g., blog posts, products, landing pages). Each model is composed of fields with custom validations. Records created from models exist independently and can be referenced by other records through link fields.
4419
+ *
4420
+ * ## Block Models
4421
+ *
4422
+ * Block models define complex and repeatable structures that can be embedded inside records. They are the foundation behind features like [Modular Content](/docs/content-modelling/modular-content.md) and [Structured Text](/docs/content-modelling/structured-text.md).
4423
+ *
4424
+ * ### Key differences:
4425
+ *
4426
+ * - **Models** create standalone records that can be referenced and have independent value
4427
+ * - **Block models** create blocks that only exist within parent records and cannot be referenced via link fields
4428
+ * - Block models defined in the library can be reused across different models
4429
+ * - When a record gets deleted, all the blocks it contains are deleted with it
4430
+ * - Blocks do not count towards your plan's records limit
4431
+ *
4432
+ * You can distinguish between models and block models using the `modular_block` attribute: `true` indicates a block model, `false` indicates a regular model.
4433
+ *
4415
4434
  *
4416
4435
  * This interface was referenced by `DatoApi`'s JSON-Schema
4417
4436
  * via the `definition` "item_type".
@@ -4431,11 +4450,11 @@ export type ItemType = {
4431
4450
  */
4432
4451
  export type ItemTypeAttributes = {
4433
4452
  /**
4434
- * Name of the model
4453
+ * Name of the model/block model
4435
4454
  */
4436
4455
  name: string;
4437
4456
  /**
4438
- * API key of the model
4457
+ * API key of the model/block model
4439
4458
  */
4440
4459
  api_key: string;
4441
4460
  /**
@@ -4443,11 +4462,11 @@ export type ItemTypeAttributes = {
4443
4462
  */
4444
4463
  collection_appeareance?: 'compact' | 'table';
4445
4464
  /**
4446
- * The way the model collection should be presented to the editors
4465
+ * The way the model/block model collection should be presented to the editors
4447
4466
  */
4448
4467
  collection_appearance: 'compact' | 'table';
4449
4468
  /**
4450
- * Whether the model is single-instance or not
4469
+ * Whether the model is single-instance or not. This property only applies to models, not block models
4451
4470
  */
4452
4471
  singleton: boolean;
4453
4472
  /**
@@ -4455,31 +4474,31 @@ export type ItemTypeAttributes = {
4455
4474
  */
4456
4475
  all_locales_required: boolean;
4457
4476
  /**
4458
- * Whether editors can sort records via drag & drop or not
4477
+ * Whether editors can sort records via drag & drop or not. Must be false for block models
4459
4478
  */
4460
4479
  sortable: boolean;
4461
4480
  /**
4462
- * Whether this model is a modular content block or not
4481
+ * Whether this is a block model or not. Block models define structures that can be embedded inside records, while regular models create standalone records
4463
4482
  */
4464
4483
  modular_block: boolean;
4465
4484
  /**
4466
- * Whether draft/published mode is active or not
4485
+ * Whether draft/published mode is active or not. Must be false for block models
4467
4486
  */
4468
4487
  draft_mode_active: boolean;
4469
4488
  /**
4470
- * Whether draft records can be saved without satisfying the validations or not
4489
+ * Whether draft records can be saved without satisfying the validations or not. Must be false for block models
4471
4490
  */
4472
4491
  draft_saving_active: boolean;
4473
4492
  /**
4474
- * Whether editors can organize records in a tree or not
4493
+ * Whether editors can organize records in a tree or not. Must be false for block models
4475
4494
  */
4476
4495
  tree: boolean;
4477
4496
  /**
4478
- * If an ordering field is set, this fields specify the sorting direction
4497
+ * If an ordering field is set, this field specifies the sorting direction. This property does not apply to block models
4479
4498
  */
4480
4499
  ordering_direction: null | 'asc' | 'desc';
4481
4500
  /**
4482
- * Specifies the model's sorting method. Cannot be set in concurrency with ordering_field
4501
+ * Specifies the model's sorting method. Cannot be set in concurrency with ordering_field. This property does not apply to block models
4483
4502
  */
4484
4503
  ordering_meta:
4485
4504
  | null
@@ -4488,15 +4507,15 @@ export type ItemTypeAttributes = {
4488
4507
  | 'first_published_at'
4489
4508
  | 'published_at';
4490
4509
  /**
4491
- * If this model is single-instance, this tells the single-instance record has already been created or not
4510
+ * If this model is single-instance, this tells whether the single-instance record has already been created or not. This property only applies to models, not block models
4492
4511
  */
4493
4512
  has_singleton_item: boolean;
4494
4513
  /**
4495
- * A hint shown to editors to help them understand the purpose of this model/block
4514
+ * A hint shown to editors to help them understand the purpose of this model/block model
4496
4515
  */
4497
4516
  hint: string | null;
4498
4517
  /**
4499
- * Whether inverse relationships fields are expressed in GraphQL or not
4518
+ * Whether inverse relationships fields are expressed in GraphQL or not. Must be false for block models
4500
4519
  */
4501
4520
  inverse_relationships_enabled: boolean;
4502
4521
  };
@@ -4508,19 +4527,19 @@ export type ItemTypeAttributes = {
4508
4527
  */
4509
4528
  export type ItemTypeRelationships = {
4510
4529
  /**
4511
- * The item instance related to this item type
4530
+ * The record instance related to this model. This relationship only applies to single-instance models, not block models
4512
4531
  */
4513
4532
  singleton_item: {
4514
4533
  data: ItemData | null;
4515
4534
  };
4516
4535
  /**
4517
- * The list of item type fields
4536
+ * The list of fields for this model/block model
4518
4537
  */
4519
4538
  fields: {
4520
4539
  data: FieldData[];
4521
4540
  };
4522
4541
  /**
4523
- * The list of item type fieldsets
4542
+ * The list of fieldsets for this model/block model
4524
4543
  */
4525
4544
  fieldsets: {
4526
4545
  data: FieldsetData[];
@@ -4538,25 +4557,25 @@ export type ItemTypeRelationships = {
4538
4557
  data: FieldData | null;
4539
4558
  };
4540
4559
  /**
4541
- * The field to use as fallback title for SEO purposes
4560
+ * The field to use as fallback title for SEO purposes. This relationship does not apply to block models
4542
4561
  */
4543
4562
  title_field: {
4544
4563
  data: FieldData | null;
4545
4564
  };
4546
4565
  /**
4547
- * The field to use as fallback image for SEO purposes
4566
+ * The field to use as fallback image for SEO purposes. This relationship does not apply to block models
4548
4567
  */
4549
4568
  image_preview_field: {
4550
4569
  data: FieldData | null;
4551
4570
  };
4552
4571
  /**
4553
- * The field to use as fallback description for SEO purposes
4572
+ * The field to use as fallback description for SEO purposes. This relationship does not apply to block models
4554
4573
  */
4555
4574
  excerpt_field: {
4556
4575
  data: FieldData | null;
4557
4576
  };
4558
4577
  /**
4559
- * The field upon which the collection is sorted
4578
+ * The field upon which the collection is sorted. This relationship does not apply to block models
4560
4579
  */
4561
4580
  ordering_field: {
4562
4581
  data: FieldData | null;
@@ -4609,14 +4628,14 @@ export type WorkflowData = {
4609
4628
  id: WorkflowIdentity;
4610
4629
  };
4611
4630
  /**
4612
- * Meta information regarding the item type
4631
+ * Meta information regarding the model/block model
4613
4632
  *
4614
4633
  * This interface was referenced by `ItemType`'s JSON-Schema
4615
4634
  * via the `definition` "meta".
4616
4635
  */
4617
4636
  export type ItemTypeMeta = {
4618
4637
  /**
4619
- * If this model is single-instance, this tells the single-instance record has already been created or not
4638
+ * If this model is single-instance, this tells whether the single-instance record has already been created or not. This property only applies to models, not block models
4620
4639
  */
4621
4640
  has_singleton_item: boolean;
4622
4641
  };
@@ -4633,15 +4652,15 @@ export type ItemTypeCreateSchema = {
4633
4652
  */
4634
4653
  attributes: {
4635
4654
  /**
4636
- * Name of the model
4655
+ * Name of the model/block model
4637
4656
  */
4638
4657
  name: string;
4639
4658
  /**
4640
- * API key of the model
4659
+ * API key of the model/block model
4641
4660
  */
4642
4661
  api_key: string;
4643
4662
  /**
4644
- * Whether the model is single-instance or not
4663
+ * Whether the model is single-instance or not. This property only applies to models, not block models
4645
4664
  */
4646
4665
  singleton?: boolean;
4647
4666
  /**
@@ -4649,31 +4668,31 @@ export type ItemTypeCreateSchema = {
4649
4668
  */
4650
4669
  all_locales_required?: boolean;
4651
4670
  /**
4652
- * Whether editors can sort records via drag & drop or not
4671
+ * Whether editors can sort records via drag & drop or not. Must be false for block models
4653
4672
  */
4654
4673
  sortable?: boolean;
4655
4674
  /**
4656
- * Whether this model is a modular content block or not
4675
+ * Whether this is a block model or not. Block models define structures that can be embedded inside records, while regular models create standalone records
4657
4676
  */
4658
4677
  modular_block?: boolean;
4659
4678
  /**
4660
- * Whether draft/published mode is active or not
4679
+ * Whether draft/published mode is active or not. Must be false for block models
4661
4680
  */
4662
4681
  draft_mode_active?: boolean;
4663
4682
  /**
4664
- * Whether draft records can be saved without satisfying the validations or not
4683
+ * Whether draft records can be saved without satisfying the validations or not. Must be false for block models
4665
4684
  */
4666
4685
  draft_saving_active?: boolean;
4667
4686
  /**
4668
- * Whether editors can organize records in a tree or not
4687
+ * Whether editors can organize records in a tree or not. Must be false for block models
4669
4688
  */
4670
4689
  tree?: boolean;
4671
4690
  /**
4672
- * If an ordering field is set, this fields specify the sorting direction
4691
+ * If an ordering field is set, this field specifies the sorting direction. This property does not apply to block models
4673
4692
  */
4674
4693
  ordering_direction?: null | 'asc' | 'desc';
4675
4694
  /**
4676
- * Specifies the model's sorting method. Cannot be set in concurrency with ordering_field
4695
+ * Specifies the model's sorting method. Cannot be set in concurrency with ordering_field. This property does not apply to block models
4677
4696
  */
4678
4697
  ordering_meta?:
4679
4698
  | null
@@ -4686,21 +4705,21 @@ export type ItemTypeCreateSchema = {
4686
4705
  */
4687
4706
  collection_appeareance?: 'compact' | 'table';
4688
4707
  /**
4689
- * The way the model collection should be presented to the editors
4708
+ * The way the model/block model collection should be presented to the editors
4690
4709
  */
4691
4710
  collection_appearance?: 'compact' | 'table';
4692
4711
  /**
4693
- * A hint shown to editors to help them understand the purpose of this model/block
4712
+ * A hint shown to editors to help them understand the purpose of this model/block model
4694
4713
  */
4695
4714
  hint?: string | null;
4696
4715
  /**
4697
- * Whether inverse relationships fields are expressed in GraphQL or not
4716
+ * Whether inverse relationships fields are expressed in GraphQL or not. Must be false for block models
4698
4717
  */
4699
4718
  inverse_relationships_enabled?: boolean;
4700
4719
  };
4701
4720
  relationships?: {
4702
4721
  /**
4703
- * The field upon which the collection is sorted
4722
+ * The field upon which the collection is sorted. This relationship does not apply to block models
4704
4723
  */
4705
4724
  ordering_field?: {
4706
4725
  data: FieldData | null;
@@ -4718,19 +4737,19 @@ export type ItemTypeCreateSchema = {
4718
4737
  data: FieldData | null;
4719
4738
  };
4720
4739
  /**
4721
- * The field to use as fallback title for SEO purposes
4740
+ * The field to use as fallback title for SEO purposes. This relationship does not apply to block models
4722
4741
  */
4723
4742
  title_field?: {
4724
4743
  data: FieldData | null;
4725
4744
  };
4726
4745
  /**
4727
- * The field to use as fallback image for SEO purposes
4746
+ * The field to use as fallback image for SEO purposes. This relationship does not apply to block models
4728
4747
  */
4729
4748
  image_preview_field?: {
4730
4749
  data: FieldData | null;
4731
4750
  };
4732
4751
  /**
4733
- * The field to use as fallback description for SEO purposes
4752
+ * The field to use as fallback description for SEO purposes. This relationship does not apply to block models
4734
4753
  */
4735
4754
  excerpt_field?: {
4736
4755
  data: FieldData | null;
@@ -4765,11 +4784,11 @@ export type ItemTypeUpdateSchema = {
4765
4784
  */
4766
4785
  attributes?: {
4767
4786
  /**
4768
- * Name of the model
4787
+ * Name of the model/block model
4769
4788
  */
4770
4789
  name?: string;
4771
4790
  /**
4772
- * API key of the model
4791
+ * API key of the model/block model
4773
4792
  */
4774
4793
  api_key?: string;
4775
4794
  /**
@@ -4777,11 +4796,11 @@ export type ItemTypeUpdateSchema = {
4777
4796
  */
4778
4797
  collection_appeareance?: 'compact' | 'table';
4779
4798
  /**
4780
- * The way the model collection should be presented to the editors
4799
+ * The way the model/block model collection should be presented to the editors
4781
4800
  */
4782
4801
  collection_appearance?: 'compact' | 'table';
4783
4802
  /**
4784
- * Whether the model is single-instance or not
4803
+ * Whether the model is single-instance or not. This property only applies to models, not block models
4785
4804
  */
4786
4805
  singleton?: boolean;
4787
4806
  /**
@@ -4789,31 +4808,31 @@ export type ItemTypeUpdateSchema = {
4789
4808
  */
4790
4809
  all_locales_required?: boolean;
4791
4810
  /**
4792
- * Whether editors can sort records via drag & drop or not
4811
+ * Whether editors can sort records via drag & drop or not. Must be false for block models
4793
4812
  */
4794
4813
  sortable?: boolean;
4795
4814
  /**
4796
- * Whether this model is a modular content block or not
4815
+ * Whether this is a block model or not. Block models define structures that can be embedded inside records, while regular models create standalone records
4797
4816
  */
4798
4817
  modular_block?: boolean;
4799
4818
  /**
4800
- * Whether draft/published mode is active or not
4819
+ * Whether draft/published mode is active or not. Must be false for block models
4801
4820
  */
4802
4821
  draft_mode_active?: boolean;
4803
4822
  /**
4804
- * Whether draft records can be saved without satisfying the validations or not
4823
+ * Whether draft records can be saved without satisfying the validations or not. Must be false for block models
4805
4824
  */
4806
4825
  draft_saving_active?: boolean;
4807
4826
  /**
4808
- * Whether editors can organize records in a tree or not
4827
+ * Whether editors can organize records in a tree or not. Must be false for block models
4809
4828
  */
4810
4829
  tree?: boolean;
4811
4830
  /**
4812
- * If an ordering field is set, this fields specify the sorting direction
4831
+ * If an ordering field is set, this field specifies the sorting direction. This property does not apply to block models
4813
4832
  */
4814
4833
  ordering_direction?: null | 'asc' | 'desc';
4815
4834
  /**
4816
- * Specifies the model's sorting method. Cannot be set in concurrency with ordering_field
4835
+ * Specifies the model's sorting method. Cannot be set in concurrency with ordering_field. This property does not apply to block models
4817
4836
  */
4818
4837
  ordering_meta?:
4819
4838
  | null
@@ -4822,21 +4841,21 @@ export type ItemTypeUpdateSchema = {
4822
4841
  | 'first_published_at'
4823
4842
  | 'published_at';
4824
4843
  /**
4825
- * If this model is single-instance, this tells the single-instance record has already been created or not
4844
+ * If this model is single-instance, this tells whether the single-instance record has already been created or not. This property only applies to models, not block models
4826
4845
  */
4827
4846
  has_singleton_item?: boolean;
4828
4847
  /**
4829
- * A hint shown to editors to help them understand the purpose of this model/block
4848
+ * A hint shown to editors to help them understand the purpose of this model/block model
4830
4849
  */
4831
4850
  hint?: string | null;
4832
4851
  /**
4833
- * Whether inverse relationships fields are expressed in GraphQL or not
4852
+ * Whether inverse relationships fields are expressed in GraphQL or not. Must be false for block models
4834
4853
  */
4835
4854
  inverse_relationships_enabled?: boolean;
4836
4855
  };
4837
4856
  relationships?: {
4838
4857
  /**
4839
- * The field upon which the collection is sorted
4858
+ * The field upon which the collection is sorted. This relationship does not apply to block models
4840
4859
  */
4841
4860
  ordering_field?: {
4842
4861
  data: FieldData | null;
@@ -4854,19 +4873,19 @@ export type ItemTypeUpdateSchema = {
4854
4873
  data: FieldData | null;
4855
4874
  };
4856
4875
  /**
4857
- * The field to use as fallback title for SEO purposes
4876
+ * The field to use as fallback title for SEO purposes. This relationship does not apply to block models
4858
4877
  */
4859
4878
  title_field?: {
4860
4879
  data: FieldData | null;
4861
4880
  };
4862
4881
  /**
4863
- * The field to use as fallback image for SEO purposes
4882
+ * The field to use as fallback image for SEO purposes. This relationship does not apply to block models
4864
4883
  */
4865
4884
  image_preview_field?: {
4866
4885
  data: FieldData | null;
4867
4886
  };
4868
4887
  /**
4869
- * The field to use as fallback description for SEO purposes
4888
+ * The field to use as fallback description for SEO purposes. This relationship does not apply to block models
4870
4889
  */
4871
4890
  excerpt_field?: {
4872
4891
  data: FieldData | null;
@@ -4880,7 +4899,7 @@ export type ItemTypeUpdateSchema = {
4880
4899
  };
4881
4900
  meta?: {
4882
4901
  /**
4883
- * If this model is single-instance, this tells the single-instance record has already been created or not
4902
+ * If this model is single-instance, this tells whether the single-instance record has already been created or not. This property only applies to models, not block models
4884
4903
  */
4885
4904
  has_singleton_item?: boolean;
4886
4905
  };
@@ -7094,7 +7113,7 @@ export type SubscriptionFeatureInstancesTargetSchema = {
7094
7113
  data: SubscriptionFeature[];
7095
7114
  };
7096
7115
  /**
7097
- * Represents an event occurred during the deploy process of your administrative area.
7116
+ * Represents an event occurred during the deploy process of a build trigger.
7098
7117
  *
7099
7118
  * This interface was referenced by `DatoApi`'s JSON-Schema
7100
7119
  * via the `definition` "build_event".
@@ -7185,7 +7204,7 @@ export type BuildEventSelfTargetSchema = {
7185
7204
  data: BuildEvent;
7186
7205
  };
7187
7206
  /**
7188
- * Represents an event occurred during the search indexing process.
7207
+ * Represents an event occurred during the indexing process via search indexes.
7189
7208
  *
7190
7209
  * This interface was referenced by `DatoApi`'s JSON-Schema
7191
7210
  * via the `definition` "search_index_event".
@@ -9870,6 +9889,10 @@ export type BuildTriggerAttributes = {
9870
9889
  * Name of the build trigger
9871
9890
  */
9872
9891
  name: string;
9892
+ /**
9893
+ * Whether the build trigger is enabled or not
9894
+ */
9895
+ enabled: boolean;
9873
9896
  /**
9874
9897
  * The type of build trigger
9875
9898
  */
@@ -9901,7 +9924,7 @@ export type BuildTriggerAttributes = {
9901
9924
  */
9902
9925
  indexing_status: string;
9903
9926
  /**
9904
- * The public URL of the frontend. If Site Search is enabled (indicated by `indexing_enabled`), this is the starting point from which the website's spidering will start
9927
+ * The public URL of the frontend.
9905
9928
  */
9906
9929
  frontend_url: string | null;
9907
9930
  /**
@@ -9912,10 +9935,6 @@ export type BuildTriggerAttributes = {
9912
9935
  * Wether Site Search is enabled or not. With Site Search, everytime the website is built, DatoCMS will respider it to get updated content
9913
9936
  */
9914
9937
  indexing_enabled: boolean;
9915
- /**
9916
- * Whether the build trigger is enabled or not
9917
- */
9918
- enabled: boolean;
9919
9938
  };
9920
9939
  /**
9921
9940
  * This interface was referenced by `BuildTrigger`'s JSON-Schema
@@ -9960,13 +9979,13 @@ export type BuildTriggerCreateSchema = {
9960
9979
  /**
9961
9980
  * Wether Site Search is enabled or not. With Site Search, everytime the website is built, DatoCMS will respider it to get updated content
9962
9981
  */
9963
- indexing_enabled: boolean;
9982
+ indexing_enabled?: boolean;
9964
9983
  /**
9965
9984
  * Whether the build trigger is enabled or not
9966
9985
  */
9967
9986
  enabled?: boolean;
9968
9987
  /**
9969
- * The public URL of the frontend. If Site Search is enabled (indicated by `indexing_enabled`), this is the starting point from which the website's spidering will start
9988
+ * The public URL of the frontend.
9970
9989
  */
9971
9990
  frontend_url: string | null;
9972
9991
  /**
@@ -10021,7 +10040,7 @@ export type BuildTriggerUpdateSchema = {
10021
10040
  */
10022
10041
  enabled?: boolean;
10023
10042
  /**
10024
- * The public URL of the frontend. If Site Search is enabled (indicated by `indexing_enabled`), this is the starting point from which the website's spidering will start
10043
+ * The public URL of the frontend.
10025
10044
  */
10026
10045
  frontend_url?: string | null;
10027
10046
  /**
@@ -10052,7 +10071,7 @@ export type BuildTriggerDestroyTargetSchema = {
10052
10071
  data: BuildTrigger;
10053
10072
  };
10054
10073
  /**
10055
- * A Search Index represents a website that should be indexed by DatoCMS Site Search. When enabled, DatoCMS will periodically spider the website to update the search index.
10074
+ * A Search Index is used to index a website to provide DatoCMS Site Search functionality.
10056
10075
  *
10057
10076
  * This interface was referenced by `DatoApi`'s JSON-Schema
10058
10077
  * via the `definition` "search_index".
@@ -10080,11 +10099,7 @@ export type SearchIndexAttributes = {
10080
10099
  */
10081
10100
  enabled: boolean;
10082
10101
  /**
10083
- * Whether the spidering should automatically run after associated build triggers complete
10084
- */
10085
- build_trigger_indexing_enabled: boolean;
10086
- /**
10087
- * The public URL of the frontend. This is the starting point from which the website's spidering will start
10102
+ * The public URL of the website. This is the starting point from which the website's spidering will start
10088
10103
  */
10089
10104
  frontend_url: string | null;
10090
10105
  /**
@@ -10100,7 +10115,7 @@ export type SearchIndexAttributes = {
10100
10115
  */
10101
10116
  export type SearchIndexRelationships = {
10102
10117
  /**
10103
- * The build triggers connected to this search index
10118
+ * The build triggers that can trigger this search index
10104
10119
  */
10105
10120
  build_triggers: {
10106
10121
  data: BuildTriggerData[];
@@ -10114,7 +10129,7 @@ export type SearchIndexRelationships = {
10114
10129
  */
10115
10130
  export type SearchIndexMeta = {
10116
10131
  /**
10117
- * Status of the site search indexing
10132
+ * Status of the search indexing
10118
10133
  */
10119
10134
  indexing_status: 'unstarted' | 'pending' | 'success' | 'failed';
10120
10135
  /**
@@ -10153,11 +10168,7 @@ export type SearchIndexCreateSchema = {
10153
10168
  */
10154
10169
  enabled: boolean;
10155
10170
  /**
10156
- * Whether the spidering should automatically run after associated build triggers complete
10157
- */
10158
- build_trigger_indexing_enabled?: boolean;
10159
- /**
10160
- * The public URL of the frontend. This is the starting point from which the website's spidering will start
10171
+ * The public URL of the website. This is the starting point from which the website's spidering will start
10161
10172
  */
10162
10173
  frontend_url: string | null;
10163
10174
  /**
@@ -10170,7 +10181,7 @@ export type SearchIndexCreateSchema = {
10170
10181
  */
10171
10182
  relationships?: {
10172
10183
  /**
10173
- * The build triggers connected to this search index
10184
+ * The build triggers that can trigger this search index
10174
10185
  */
10175
10186
  build_triggers?: {
10176
10187
  data: BuildTriggerData[];
@@ -10203,11 +10214,7 @@ export type SearchIndexUpdateSchema = {
10203
10214
  */
10204
10215
  enabled?: boolean;
10205
10216
  /**
10206
- * Whether the spidering should automatically run after associated build triggers complete
10207
- */
10208
- build_trigger_indexing_enabled?: boolean;
10209
- /**
10210
- * The public URL of the frontend. This is the starting point from which the website's spidering will start
10217
+ * The public URL of the website. This is the starting point from which the website's spidering will start
10211
10218
  */
10212
10219
  frontend_url?: string | null;
10213
10220
  /**
@@ -10220,7 +10227,7 @@ export type SearchIndexUpdateSchema = {
10220
10227
  */
10221
10228
  relationships?: {
10222
10229
  /**
10223
- * The build triggers connected to this search index
10230
+ * The build triggers that can trigger this search index
10224
10231
  */
10225
10232
  build_triggers?: {
10226
10233
  data: BuildTriggerData[];