@contentchef/contentchef-types 10.1.0-alpha.5 → 10.1.0-alpha.6

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.
@@ -0,0 +1,97 @@
1
+ import { ContentId } from './Content';
2
+ import { AuthorResponse } from './Author';
3
+ /**
4
+ * The unpublish request unique id
5
+ */
6
+ export type UnpublishRequestId = number;
7
+ /**
8
+ * This type represent the data needed to make an unpublish content API request
9
+ */
10
+ export type UnpublishContentRequest = {
11
+ /**
12
+ * The content id to unpublish. Every staged locale of the content is unpublished
13
+ */
14
+ contentId: number;
15
+ };
16
+ /**
17
+ * This type represent the response of an unpublish content API request
18
+ */
19
+ export type UnpublishContentResponse = {
20
+ /**
21
+ * The staged content version that has been removed.
22
+ * Undefined when nothing was staged, meaning the request was a no-op
23
+ */
24
+ contentVersion?: number;
25
+ /**
26
+ * The content locales whose staged content has actually been removed or reverted to its live version
27
+ */
28
+ locales: string[];
29
+ /**
30
+ * The number of release items dropped from the non archived releases containing the content
31
+ */
32
+ removedReleaseItems: number;
33
+ };
34
+ /**
35
+ * This type represent the data needed to make a list unpublish requests API request
36
+ */
37
+ export type ListUnpublishRequestsRequest = {
38
+ /**
39
+ * The content id to list the unpublish requests of
40
+ */
41
+ contentId: number;
42
+ /**
43
+ * The content version to list the unpublish requests of.
44
+ * When omitted the whole unpublish history of the content is returned
45
+ */
46
+ contentVersion?: number;
47
+ };
48
+ /**
49
+ * This type represent the model of an unpublish request, the audit record of a content
50
+ * having been unpublished. It is written after the unpublish has been applied, so it always
51
+ * describes a completed unpublish
52
+ */
53
+ export type UnpublishRequestResponse = {
54
+ /**
55
+ * The unpublish request unique id
56
+ */
57
+ id: UnpublishRequestId;
58
+ /**
59
+ * The author that unpublished the content
60
+ */
61
+ author: AuthorResponse;
62
+ /**
63
+ * The unique id of the unpublished content
64
+ */
65
+ contentId: ContentId;
66
+ /**
67
+ * The unpublished content version
68
+ */
69
+ contentVersion: number;
70
+ /**
71
+ * The content locales that have been unpublished
72
+ */
73
+ locales: string[];
74
+ /**
75
+ * The date the content has been unpublished, as opposed to [[createdDate]]
76
+ * which is the date this audit record has been written
77
+ */
78
+ unpublishedDate: Date;
79
+ /**
80
+ * The unpublish request creation date
81
+ */
82
+ createdDate: Date;
83
+ /**
84
+ * The unpublish request last modified date
85
+ */
86
+ lastModifiedDate: Date;
87
+ };
88
+ /**
89
+ * This type represent the response of a list unpublish requests API request, sorted by
90
+ * [[UnpublishRequestResponse.unpublishedDate]] descending.
91
+ * Only the [[MAX_LISTED_UNPUBLISH_REQUESTS]] most recent unpublish requests are returned
92
+ */
93
+ export type ListUnpublishRequestsResponse = UnpublishRequestResponse[];
94
+ /**
95
+ * The maximum number of unpublish requests returned by a list unpublish requests API request
96
+ */
97
+ export declare const MAX_LISTED_UNPUBLISH_REQUESTS = 5;
@@ -0,0 +1,7 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MAX_LISTED_UNPUBLISH_REQUESTS = void 0;
4
+ /**
5
+ * The maximum number of unpublish requests returned by a list unpublish requests API request
6
+ */
7
+ exports.MAX_LISTED_UNPUBLISH_REQUESTS = 5;
@@ -13,6 +13,7 @@ export * from './PublishedContent';
13
13
  export * from './PublishingRequest';
14
14
  export * from './Space';
15
15
  export * from './Subscription';
16
+ export * from './UnpublishRequest';
16
17
  export * from './User';
17
18
  export * from './UserConsents';
18
19
  export * from './UserPermission';
package/dist/api/index.js CHANGED
@@ -29,6 +29,7 @@ __exportStar(require("./PublishedContent"), exports);
29
29
  __exportStar(require("./PublishingRequest"), exports);
30
30
  __exportStar(require("./Space"), exports);
31
31
  __exportStar(require("./Subscription"), exports);
32
+ __exportStar(require("./UnpublishRequest"), exports);
32
33
  __exportStar(require("./User"), exports);
33
34
  __exportStar(require("./UserConsents"), exports);
34
35
  __exportStar(require("./UserPermission"), exports);
@@ -0,0 +1,104 @@
1
+ import { ContentId } from './Content';
2
+ import { AuthorResponse } from './Author';
3
+
4
+ /**
5
+ * The unpublish request unique id
6
+ */
7
+ export type UnpublishRequestId = number;
8
+
9
+ /**
10
+ * This type represent the data needed to make an unpublish content API request
11
+ */
12
+ export type UnpublishContentRequest = {
13
+ /**
14
+ * The content id to unpublish. Every staged locale of the content is unpublished
15
+ */
16
+ contentId: number;
17
+ };
18
+
19
+ /**
20
+ * This type represent the response of an unpublish content API request
21
+ */
22
+ export type UnpublishContentResponse = {
23
+ /**
24
+ * The staged content version that has been removed.
25
+ * Undefined when nothing was staged, meaning the request was a no-op
26
+ */
27
+ contentVersion?: number;
28
+ /**
29
+ * The content locales whose staged content has actually been removed or reverted to its live version
30
+ */
31
+ locales: string[];
32
+ /**
33
+ * The number of release items dropped from the non archived releases containing the content
34
+ */
35
+ removedReleaseItems: number;
36
+ };
37
+
38
+ /**
39
+ * This type represent the data needed to make a list unpublish requests API request
40
+ */
41
+ export type ListUnpublishRequestsRequest = {
42
+ /**
43
+ * The content id to list the unpublish requests of
44
+ */
45
+ contentId: number;
46
+ /**
47
+ * The content version to list the unpublish requests of.
48
+ * When omitted the whole unpublish history of the content is returned
49
+ */
50
+ contentVersion?: number;
51
+ };
52
+
53
+ /**
54
+ * This type represent the model of an unpublish request, the audit record of a content
55
+ * having been unpublished. It is written after the unpublish has been applied, so it always
56
+ * describes a completed unpublish
57
+ */
58
+ export type UnpublishRequestResponse = {
59
+ /**
60
+ * The unpublish request unique id
61
+ */
62
+ id: UnpublishRequestId;
63
+ /**
64
+ * The author that unpublished the content
65
+ */
66
+ author: AuthorResponse;
67
+ /**
68
+ * The unique id of the unpublished content
69
+ */
70
+ contentId: ContentId;
71
+ /**
72
+ * The unpublished content version
73
+ */
74
+ contentVersion: number;
75
+ /**
76
+ * The content locales that have been unpublished
77
+ */
78
+ locales: string[];
79
+ /**
80
+ * The date the content has been unpublished, as opposed to [[createdDate]]
81
+ * which is the date this audit record has been written
82
+ */
83
+ unpublishedDate: Date;
84
+ /**
85
+ * The unpublish request creation date
86
+ */
87
+ createdDate: Date;
88
+ /**
89
+ * The unpublish request last modified date
90
+ */
91
+ lastModifiedDate: Date;
92
+ };
93
+
94
+ /**
95
+ * This type represent the response of a list unpublish requests API request, sorted by
96
+ * [[UnpublishRequestResponse.unpublishedDate]] descending.
97
+ * Only the [[MAX_LISTED_UNPUBLISH_REQUESTS]] most recent unpublish requests are returned
98
+ */
99
+ export type ListUnpublishRequestsResponse = UnpublishRequestResponse[];
100
+
101
+ /**
102
+ * The maximum number of unpublish requests returned by a list unpublish requests API request
103
+ */
104
+ export const MAX_LISTED_UNPUBLISH_REQUESTS = 5;
package/lib/api/index.ts CHANGED
@@ -13,6 +13,7 @@ export * from './PublishedContent';
13
13
  export * from './PublishingRequest';
14
14
  export * from './Space';
15
15
  export * from './Subscription';
16
+ export * from './UnpublishRequest';
16
17
  export * from './User';
17
18
  export * from './UserConsents';
18
19
  export * from './UserPermission';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentchef/contentchef-types",
3
- "version": "10.1.0-alpha.5",
3
+ "version": "10.1.0-alpha.6",
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": "395605c7649177141f6ee45bb5c178c946d25fc5"
37
+ "gitHead": "44d000ee30bfadef421bea413b472ee5290a1000"
38
38
  }