@gitbook/api 0.20.1 → 0.22.0
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.
- package/dist/client.d.ts +208 -82
- package/dist/index.cjs +74 -23
- package/dist/index.js +73 -23
- package/package.json +1 -1
- package/spec/openapi.json +647 -275
- package/spec/openapi.yaml +376 -178
package/dist/index.js
CHANGED
|
@@ -295,6 +295,12 @@ var CustomizationCorners = /* @__PURE__ */ ((CustomizationCorners2) => {
|
|
|
295
295
|
CustomizationCorners2["Rounded"] = "rounded";
|
|
296
296
|
return CustomizationCorners2;
|
|
297
297
|
})(CustomizationCorners || {});
|
|
298
|
+
var PageFeedbackRating = /* @__PURE__ */ ((PageFeedbackRating2) => {
|
|
299
|
+
PageFeedbackRating2["Bad"] = "bad";
|
|
300
|
+
PageFeedbackRating2["Ok"] = "ok";
|
|
301
|
+
PageFeedbackRating2["Good"] = "good";
|
|
302
|
+
return PageFeedbackRating2;
|
|
303
|
+
})(PageFeedbackRating || {});
|
|
298
304
|
var ContentType = /* @__PURE__ */ ((ContentType2) => {
|
|
299
305
|
ContentType2["Json"] = "application/json";
|
|
300
306
|
ContentType2["FormData"] = "multipart/form-data";
|
|
@@ -516,6 +522,12 @@ var Api = class extends HttpClient {
|
|
|
516
522
|
format: "json",
|
|
517
523
|
...params
|
|
518
524
|
}),
|
|
525
|
+
deleteSpaceById: (spaceId, params = {}) => this.request({
|
|
526
|
+
path: `/spaces/${spaceId}`,
|
|
527
|
+
method: "DELETE",
|
|
528
|
+
secure: true,
|
|
529
|
+
...params
|
|
530
|
+
}),
|
|
519
531
|
generateSpaceHiveReadAccessToken: (spaceId, params = {}) => this.request({
|
|
520
532
|
path: `/spaces/${spaceId}/hive/token`,
|
|
521
533
|
method: "POST",
|
|
@@ -530,6 +542,13 @@ var Api = class extends HttpClient {
|
|
|
530
542
|
format: "json",
|
|
531
543
|
...params
|
|
532
544
|
}),
|
|
545
|
+
restoreSpace: (spaceId, params = {}) => this.request({
|
|
546
|
+
path: `/spaces/${spaceId}/restore`,
|
|
547
|
+
method: "POST",
|
|
548
|
+
secure: true,
|
|
549
|
+
format: "json",
|
|
550
|
+
...params
|
|
551
|
+
}),
|
|
533
552
|
searchSpaceContent: (spaceId, query, params = {}) => this.request({
|
|
534
553
|
path: `/spaces/${spaceId}/search`,
|
|
535
554
|
method: "GET",
|
|
@@ -1089,6 +1108,13 @@ var Api = class extends HttpClient {
|
|
|
1089
1108
|
format: "json",
|
|
1090
1109
|
...params
|
|
1091
1110
|
}),
|
|
1111
|
+
listSpaceIntegrationScripts: (spaceId, params = {}) => this.request({
|
|
1112
|
+
path: `/spaces/${spaceId}/integration-scripts`,
|
|
1113
|
+
method: "GET",
|
|
1114
|
+
secure: true,
|
|
1115
|
+
format: "json",
|
|
1116
|
+
...params
|
|
1117
|
+
}),
|
|
1092
1118
|
getSpaceCustomFields: (spaceId, params = {}) => this.request({
|
|
1093
1119
|
path: `/spaces/${spaceId}/custom-fields`,
|
|
1094
1120
|
method: "GET",
|
|
@@ -1103,6 +1129,22 @@ var Api = class extends HttpClient {
|
|
|
1103
1129
|
secure: true,
|
|
1104
1130
|
type: "application/json" /* Json */,
|
|
1105
1131
|
...params
|
|
1132
|
+
}),
|
|
1133
|
+
getPageFeedback: (spaceId, pageId, visitorId, params = {}) => this.request({
|
|
1134
|
+
path: `/spaces/${spaceId}/pages/${pageId}/feedbacks/${visitorId}`,
|
|
1135
|
+
method: "GET",
|
|
1136
|
+
secure: true,
|
|
1137
|
+
format: "json",
|
|
1138
|
+
...params
|
|
1139
|
+
}),
|
|
1140
|
+
createPageFeedback: (spaceId, pageId, visitorId, data, params = {}) => this.request({
|
|
1141
|
+
path: `/spaces/${spaceId}/pages/${pageId}/feedbacks/${visitorId}`,
|
|
1142
|
+
method: "PUT",
|
|
1143
|
+
body: data,
|
|
1144
|
+
secure: true,
|
|
1145
|
+
type: "application/json" /* Json */,
|
|
1146
|
+
format: "json",
|
|
1147
|
+
...params
|
|
1106
1148
|
})
|
|
1107
1149
|
};
|
|
1108
1150
|
this.collections = {
|
|
@@ -1122,6 +1164,12 @@ var Api = class extends HttpClient {
|
|
|
1122
1164
|
format: "json",
|
|
1123
1165
|
...params
|
|
1124
1166
|
}),
|
|
1167
|
+
deleteCollectionById: (collectionId, params = {}) => this.request({
|
|
1168
|
+
path: `/collections/${collectionId}`,
|
|
1169
|
+
method: "DELETE",
|
|
1170
|
+
secure: true,
|
|
1171
|
+
...params
|
|
1172
|
+
}),
|
|
1125
1173
|
listSpacesInCollectionById: (collectionId, query, params = {}) => this.request({
|
|
1126
1174
|
path: `/collections/${collectionId}/spaces`,
|
|
1127
1175
|
method: "GET",
|
|
@@ -1607,29 +1655,6 @@ var Api = class extends HttpClient {
|
|
|
1607
1655
|
format: "json",
|
|
1608
1656
|
...params
|
|
1609
1657
|
}),
|
|
1610
|
-
setupDirectorySync: (organizationId, params = {}) => this.request({
|
|
1611
|
-
path: `/orgs/${organizationId}/dsync`,
|
|
1612
|
-
method: "POST",
|
|
1613
|
-
secure: true,
|
|
1614
|
-
format: "json",
|
|
1615
|
-
...params
|
|
1616
|
-
}),
|
|
1617
|
-
listDirectorySyncGroups: (organizationId, params = {}) => this.request({
|
|
1618
|
-
path: `/orgs/${organizationId}/dsync/groups`,
|
|
1619
|
-
method: "GET",
|
|
1620
|
-
secure: true,
|
|
1621
|
-
format: "json",
|
|
1622
|
-
...params
|
|
1623
|
-
}),
|
|
1624
|
-
syncDirectorySyncGroupsToTeams: (organizationId, data, params = {}) => this.request({
|
|
1625
|
-
path: `/orgs/${organizationId}/dsync/teams`,
|
|
1626
|
-
method: "POST",
|
|
1627
|
-
body: data,
|
|
1628
|
-
secure: true,
|
|
1629
|
-
type: "application/json" /* Json */,
|
|
1630
|
-
format: "json",
|
|
1631
|
-
...params
|
|
1632
|
-
}),
|
|
1633
1658
|
listOrganizationCustomFields: (organizationId, query, params = {}) => this.request({
|
|
1634
1659
|
path: `/orgs/${organizationId}/custom-fields`,
|
|
1635
1660
|
method: "GET",
|
|
@@ -1857,6 +1882,23 @@ var Api = class extends HttpClient {
|
|
|
1857
1882
|
format: "json",
|
|
1858
1883
|
...params
|
|
1859
1884
|
}),
|
|
1885
|
+
moveSnippet: (organizationId, snippetId, data, params = {}) => this.request({
|
|
1886
|
+
path: `/orgs/${organizationId}/snippets/${snippetId}/move`,
|
|
1887
|
+
method: "POST",
|
|
1888
|
+
body: data,
|
|
1889
|
+
secure: true,
|
|
1890
|
+
type: "application/json" /* Json */,
|
|
1891
|
+
format: "json",
|
|
1892
|
+
...params
|
|
1893
|
+
}),
|
|
1894
|
+
getSnippetSuggestedLocations: (organizationId, snippetId, query, params = {}) => this.request({
|
|
1895
|
+
path: `/orgs/${organizationId}/snippets/${snippetId}/move`,
|
|
1896
|
+
method: "GET",
|
|
1897
|
+
query,
|
|
1898
|
+
secure: true,
|
|
1899
|
+
format: "json",
|
|
1900
|
+
...params
|
|
1901
|
+
}),
|
|
1860
1902
|
askInOrganization: (organizationId, data, params = {}) => this.request({
|
|
1861
1903
|
path: `/orgs/${organizationId}/ask`,
|
|
1862
1904
|
method: "POST",
|
|
@@ -1866,6 +1908,13 @@ var Api = class extends HttpClient {
|
|
|
1866
1908
|
format: "json",
|
|
1867
1909
|
...params
|
|
1868
1910
|
}),
|
|
1911
|
+
getRecommendedQuestionsInOrganization: (organizationId, params = {}) => this.request({
|
|
1912
|
+
path: `/orgs/${organizationId}/ask/questions`,
|
|
1913
|
+
method: "GET",
|
|
1914
|
+
secure: true,
|
|
1915
|
+
format: "json",
|
|
1916
|
+
...params
|
|
1917
|
+
}),
|
|
1869
1918
|
listContentAuditRelations: (organizationId, query, params = {}) => this.request({
|
|
1870
1919
|
path: `/orgs/${organizationId}/insights/audit-relations`,
|
|
1871
1920
|
method: "GET",
|
|
@@ -2040,6 +2089,7 @@ export {
|
|
|
2040
2089
|
OrganizationCommunityType,
|
|
2041
2090
|
OrganizationType,
|
|
2042
2091
|
OrganizationUseCase,
|
|
2092
|
+
PageFeedbackRating,
|
|
2043
2093
|
PurgeCDNCacheContextType,
|
|
2044
2094
|
RevisionPageLayoutOptionsCoverSize,
|
|
2045
2095
|
RevisionPageLayoutPreset,
|