@contentchef/contentchef-types 11.2.0-alpha.1 → 11.2.0-alpha.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.
@@ -1103,6 +1103,14 @@ export type GetContentHistoryEntryResponse = ContentHistoryEntry & {
1103
1103
  }[];
1104
1104
  restorable: boolean;
1105
1105
  violations: RestoreViolations;
1106
+ /**
1107
+ * Values of fields removed from the definition by hand since, `path` in the key format of translation
1108
+ * entries. They are left out of `payload` and `translations`, as a save leaves them out, so they do not
1109
+ * keep the version from being restored
1110
+ */
1111
+ dropped: {
1112
+ path: string;
1113
+ }[];
1106
1114
  };
1107
1115
  /**
1108
1116
  * This type represent the data needed to make a restore content API request
@@ -396,18 +396,25 @@ export type ListMediaRequest = {
396
396
  */
397
397
  export type ListMediaResponse = PagedMediaResponse<Media>;
398
398
  /**
399
- * This type represent the data needed to make a get media API request
399
+ * This type represent the data needed to make a get media API request: the media by its id, or by its full
400
+ * public id, looked up in the space
400
401
  */
401
402
  export type GetMediaRequest = {
402
403
  /**
403
- * The media gallery unique id
404
+ * The media gallery unique id, only needed for a `mediaPublicId` relative to the gallery root
404
405
  */
405
- mediaGalleryId: MediaGalleryId;
406
+ mediaGalleryId?: MediaGalleryId;
407
+ } & ({
406
408
  /**
407
409
  * The media entity unique id
408
410
  */
409
411
  mediaId: MediaId;
410
- };
412
+ } | {
413
+ /**
414
+ * The media full public id, as [[Media.mediaPublicId]] holds it
415
+ */
416
+ mediaPublicId: MediaPublicId;
417
+ });
411
418
  /**
412
419
  * This type represent the response of a get media API request
413
420
  */
@@ -1180,6 +1180,12 @@ export type GetContentHistoryEntryResponse = ContentHistoryEntry & {
1180
1180
  translations: { locale: string; translations: FieldTranslation[] }[];
1181
1181
  restorable: boolean;
1182
1182
  violations: RestoreViolations;
1183
+ /**
1184
+ * Values of fields removed from the definition by hand since, `path` in the key format of translation
1185
+ * entries. They are left out of `payload` and `translations`, as a save leaves them out, so they do not
1186
+ * keep the version from being restored
1187
+ */
1188
+ dropped: { path: string }[];
1183
1189
  };
1184
1190
 
1185
1191
  /**
@@ -421,18 +421,28 @@ export type ListMediaRequest = {
421
421
  export type ListMediaResponse = PagedMediaResponse<Media>;
422
422
 
423
423
  /**
424
- * This type represent the data needed to make a get media API request
424
+ * This type represent the data needed to make a get media API request: the media by its id, or by its full
425
+ * public id, looked up in the space
425
426
  */
426
427
  export type GetMediaRequest = {
427
428
  /**
428
- * The media gallery unique id
429
- */
430
- mediaGalleryId: MediaGalleryId;
431
- /**
432
- * The media entity unique id
433
- */
434
- mediaId: MediaId;
435
- };
429
+ * The media gallery unique id, only needed for a `mediaPublicId` relative to the gallery root
430
+ */
431
+ mediaGalleryId?: MediaGalleryId;
432
+ } & (
433
+ | {
434
+ /**
435
+ * The media entity unique id
436
+ */
437
+ mediaId: MediaId;
438
+ }
439
+ | {
440
+ /**
441
+ * The media full public id, as [[Media.mediaPublicId]] holds it
442
+ */
443
+ mediaPublicId: MediaPublicId;
444
+ }
445
+ );
436
446
 
437
447
  /**
438
448
  * This type represent the response of a get media API request
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentchef/contentchef-types",
3
- "version": "11.2.0-alpha.1",
3
+ "version": "11.2.0-alpha.3",
4
4
  "description": "ContentChef types",
5
5
  "author": "PierpaoloIannone <piannone@byte-code.com>",
6
6
  "homepage": "https://github.com/ContentChef/contentchef-management-js-client#readme",
@@ -34,5 +34,5 @@
34
34
  "devDependencies": {
35
35
  "typescript": "^5.9.3"
36
36
  },
37
- "gitHead": "411c20107357815791bd9bfaa1af348f40e88aa5"
37
+ "gitHead": "2c7d06e055598e85bcd776844dc388f0633009a3"
38
38
  }