@gitbook/api 0.71.0 → 0.73.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 +104 -309
- package/dist/index.cjs +10 -86
- package/dist/index.js +10 -86
- package/package.json +1 -1
- package/spec/openapi.json +358 -1046
- package/spec/openapi.yaml +206 -616
package/dist/index.cjs
CHANGED
|
@@ -242,7 +242,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
242
242
|
|
|
243
243
|
// package.json
|
|
244
244
|
var name = "@gitbook/api";
|
|
245
|
-
var version = "0.
|
|
245
|
+
var version = "0.73.0";
|
|
246
246
|
|
|
247
247
|
// src/client.ts
|
|
248
248
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -1165,14 +1165,6 @@ var Api = class extends HttpClient {
|
|
|
1165
1165
|
type: "application/json" /* Json */,
|
|
1166
1166
|
...params
|
|
1167
1167
|
}),
|
|
1168
|
-
syncGitRepository: (spaceId, data, params = {}) => this.request({
|
|
1169
|
-
path: `/spaces/${spaceId}/git/sync`,
|
|
1170
|
-
method: "POST",
|
|
1171
|
-
body: data,
|
|
1172
|
-
secure: true,
|
|
1173
|
-
type: "application/json" /* Json */,
|
|
1174
|
-
...params
|
|
1175
|
-
}),
|
|
1176
1168
|
getSpaceGitInfo: (spaceId, params = {}) => this.request({
|
|
1177
1169
|
path: `/spaces/${spaceId}/git/info`,
|
|
1178
1170
|
method: "GET",
|
|
@@ -1622,15 +1614,6 @@ var Api = class extends HttpClient {
|
|
|
1622
1614
|
format: "json",
|
|
1623
1615
|
...params
|
|
1624
1616
|
}),
|
|
1625
|
-
touchContentInChangeRequest: (spaceId, changeRequestId, data, params = {}) => this.request({
|
|
1626
|
-
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/touched-content`,
|
|
1627
|
-
method: "POST",
|
|
1628
|
-
body: data,
|
|
1629
|
-
secure: true,
|
|
1630
|
-
type: "application/json" /* Json */,
|
|
1631
|
-
format: "json",
|
|
1632
|
-
...params
|
|
1633
|
-
}),
|
|
1634
1617
|
getChangeRequestPdf: (spaceId, changeRequestId, query, params = {}) => this.request({
|
|
1635
1618
|
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/pdf`,
|
|
1636
1619
|
method: "GET",
|
|
@@ -1639,13 +1622,6 @@ var Api = class extends HttpClient {
|
|
|
1639
1622
|
format: "json",
|
|
1640
1623
|
...params
|
|
1641
1624
|
}),
|
|
1642
|
-
getSyncedBlockContentInChangeRequest: (spaceId, changeRequestId, syncedBlockId, params = {}) => this.request({
|
|
1643
|
-
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/synced-blocks/${syncedBlockId}/content`,
|
|
1644
|
-
method: "GET",
|
|
1645
|
-
secure: true,
|
|
1646
|
-
format: "json",
|
|
1647
|
-
...params
|
|
1648
|
-
}),
|
|
1649
1625
|
getRevisionById: (spaceId, revisionId, query, params = {}) => this.request({
|
|
1650
1626
|
path: `/spaces/${spaceId}/revisions/${revisionId}`,
|
|
1651
1627
|
method: "GET",
|
|
@@ -2802,67 +2778,6 @@ var Api = class extends HttpClient {
|
|
|
2802
2778
|
format: "json",
|
|
2803
2779
|
...params
|
|
2804
2780
|
}),
|
|
2805
|
-
listSyncedBlocks: (organizationId, query, params = {}) => this.request({
|
|
2806
|
-
path: `/orgs/${organizationId}/synced-blocks`,
|
|
2807
|
-
method: "GET",
|
|
2808
|
-
query,
|
|
2809
|
-
secure: true,
|
|
2810
|
-
format: "json",
|
|
2811
|
-
...params
|
|
2812
|
-
}),
|
|
2813
|
-
createSyncedBlock: (organizationId, data, params = {}) => this.request({
|
|
2814
|
-
path: `/orgs/${organizationId}/synced-blocks`,
|
|
2815
|
-
method: "POST",
|
|
2816
|
-
body: data,
|
|
2817
|
-
secure: true,
|
|
2818
|
-
type: "application/json" /* Json */,
|
|
2819
|
-
format: "json",
|
|
2820
|
-
...params
|
|
2821
|
-
}),
|
|
2822
|
-
getSyncedBlock: (organizationId, syncedBlockId, params = {}) => this.request({
|
|
2823
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}`,
|
|
2824
|
-
method: "GET",
|
|
2825
|
-
secure: true,
|
|
2826
|
-
format: "json",
|
|
2827
|
-
...params
|
|
2828
|
-
}),
|
|
2829
|
-
updateSyncedBlock: (organizationId, syncedBlockId, data, params = {}) => this.request({
|
|
2830
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}`,
|
|
2831
|
-
method: "PATCH",
|
|
2832
|
-
body: data,
|
|
2833
|
-
secure: true,
|
|
2834
|
-
type: "application/json" /* Json */,
|
|
2835
|
-
...params
|
|
2836
|
-
}),
|
|
2837
|
-
deleteSyncedBlock: (organizationId, syncedBlockId, params = {}) => this.request({
|
|
2838
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}`,
|
|
2839
|
-
method: "DELETE",
|
|
2840
|
-
secure: true,
|
|
2841
|
-
...params
|
|
2842
|
-
}),
|
|
2843
|
-
getSyncedBlockContent: (organizationId, syncedBlockId, params = {}) => this.request({
|
|
2844
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}/content`,
|
|
2845
|
-
method: "GET",
|
|
2846
|
-
secure: true,
|
|
2847
|
-
format: "json",
|
|
2848
|
-
...params
|
|
2849
|
-
}),
|
|
2850
|
-
listSyncedBlockBacklinks: (organizationId, syncedBlockId, query, params = {}) => this.request({
|
|
2851
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}/backlinks`,
|
|
2852
|
-
method: "GET",
|
|
2853
|
-
query,
|
|
2854
|
-
secure: true,
|
|
2855
|
-
format: "json",
|
|
2856
|
-
...params
|
|
2857
|
-
}),
|
|
2858
|
-
listSyncedBlockSpaces: (organizationId, syncedBlockId, query, params = {}) => this.request({
|
|
2859
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}/usage/spaces`,
|
|
2860
|
-
method: "GET",
|
|
2861
|
-
query,
|
|
2862
|
-
secure: true,
|
|
2863
|
-
format: "json",
|
|
2864
|
-
...params
|
|
2865
|
-
}),
|
|
2866
2781
|
askInOrganization: (organizationId, data, query, params = {}) => this.request({
|
|
2867
2782
|
path: `/orgs/${organizationId}/ask`,
|
|
2868
2783
|
method: "POST",
|
|
@@ -3197,6 +3112,15 @@ var Api = class extends HttpClient {
|
|
|
3197
3112
|
format: "json",
|
|
3198
3113
|
...params
|
|
3199
3114
|
}),
|
|
3115
|
+
moveSiteSection: (organizationId, siteId, siteSectionId, data, params = {}) => this.request({
|
|
3116
|
+
path: `/orgs/${organizationId}/sites/${siteId}/sections/${siteSectionId}/move`,
|
|
3117
|
+
method: "POST",
|
|
3118
|
+
body: data,
|
|
3119
|
+
secure: true,
|
|
3120
|
+
type: "application/json" /* Json */,
|
|
3121
|
+
format: "json",
|
|
3122
|
+
...params
|
|
3123
|
+
}),
|
|
3200
3124
|
moveSiteSpace: (organizationId, siteId, siteSpaceId, data, params = {}) => this.request({
|
|
3201
3125
|
path: `/orgs/${organizationId}/sites/${siteId}/site-spaces/${siteSpaceId}/move`,
|
|
3202
3126
|
method: "POST",
|
package/dist/index.js
CHANGED
|
@@ -172,7 +172,7 @@ var require_node = __commonJS({
|
|
|
172
172
|
|
|
173
173
|
// package.json
|
|
174
174
|
var name = "@gitbook/api";
|
|
175
|
-
var version = "0.
|
|
175
|
+
var version = "0.73.0";
|
|
176
176
|
|
|
177
177
|
// src/client.ts
|
|
178
178
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -1095,14 +1095,6 @@ var Api = class extends HttpClient {
|
|
|
1095
1095
|
type: "application/json" /* Json */,
|
|
1096
1096
|
...params
|
|
1097
1097
|
}),
|
|
1098
|
-
syncGitRepository: (spaceId, data, params = {}) => this.request({
|
|
1099
|
-
path: `/spaces/${spaceId}/git/sync`,
|
|
1100
|
-
method: "POST",
|
|
1101
|
-
body: data,
|
|
1102
|
-
secure: true,
|
|
1103
|
-
type: "application/json" /* Json */,
|
|
1104
|
-
...params
|
|
1105
|
-
}),
|
|
1106
1098
|
getSpaceGitInfo: (spaceId, params = {}) => this.request({
|
|
1107
1099
|
path: `/spaces/${spaceId}/git/info`,
|
|
1108
1100
|
method: "GET",
|
|
@@ -1552,15 +1544,6 @@ var Api = class extends HttpClient {
|
|
|
1552
1544
|
format: "json",
|
|
1553
1545
|
...params
|
|
1554
1546
|
}),
|
|
1555
|
-
touchContentInChangeRequest: (spaceId, changeRequestId, data, params = {}) => this.request({
|
|
1556
|
-
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/touched-content`,
|
|
1557
|
-
method: "POST",
|
|
1558
|
-
body: data,
|
|
1559
|
-
secure: true,
|
|
1560
|
-
type: "application/json" /* Json */,
|
|
1561
|
-
format: "json",
|
|
1562
|
-
...params
|
|
1563
|
-
}),
|
|
1564
1547
|
getChangeRequestPdf: (spaceId, changeRequestId, query, params = {}) => this.request({
|
|
1565
1548
|
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/pdf`,
|
|
1566
1549
|
method: "GET",
|
|
@@ -1569,13 +1552,6 @@ var Api = class extends HttpClient {
|
|
|
1569
1552
|
format: "json",
|
|
1570
1553
|
...params
|
|
1571
1554
|
}),
|
|
1572
|
-
getSyncedBlockContentInChangeRequest: (spaceId, changeRequestId, syncedBlockId, params = {}) => this.request({
|
|
1573
|
-
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/synced-blocks/${syncedBlockId}/content`,
|
|
1574
|
-
method: "GET",
|
|
1575
|
-
secure: true,
|
|
1576
|
-
format: "json",
|
|
1577
|
-
...params
|
|
1578
|
-
}),
|
|
1579
1555
|
getRevisionById: (spaceId, revisionId, query, params = {}) => this.request({
|
|
1580
1556
|
path: `/spaces/${spaceId}/revisions/${revisionId}`,
|
|
1581
1557
|
method: "GET",
|
|
@@ -2732,67 +2708,6 @@ var Api = class extends HttpClient {
|
|
|
2732
2708
|
format: "json",
|
|
2733
2709
|
...params
|
|
2734
2710
|
}),
|
|
2735
|
-
listSyncedBlocks: (organizationId, query, params = {}) => this.request({
|
|
2736
|
-
path: `/orgs/${organizationId}/synced-blocks`,
|
|
2737
|
-
method: "GET",
|
|
2738
|
-
query,
|
|
2739
|
-
secure: true,
|
|
2740
|
-
format: "json",
|
|
2741
|
-
...params
|
|
2742
|
-
}),
|
|
2743
|
-
createSyncedBlock: (organizationId, data, params = {}) => this.request({
|
|
2744
|
-
path: `/orgs/${organizationId}/synced-blocks`,
|
|
2745
|
-
method: "POST",
|
|
2746
|
-
body: data,
|
|
2747
|
-
secure: true,
|
|
2748
|
-
type: "application/json" /* Json */,
|
|
2749
|
-
format: "json",
|
|
2750
|
-
...params
|
|
2751
|
-
}),
|
|
2752
|
-
getSyncedBlock: (organizationId, syncedBlockId, params = {}) => this.request({
|
|
2753
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}`,
|
|
2754
|
-
method: "GET",
|
|
2755
|
-
secure: true,
|
|
2756
|
-
format: "json",
|
|
2757
|
-
...params
|
|
2758
|
-
}),
|
|
2759
|
-
updateSyncedBlock: (organizationId, syncedBlockId, data, params = {}) => this.request({
|
|
2760
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}`,
|
|
2761
|
-
method: "PATCH",
|
|
2762
|
-
body: data,
|
|
2763
|
-
secure: true,
|
|
2764
|
-
type: "application/json" /* Json */,
|
|
2765
|
-
...params
|
|
2766
|
-
}),
|
|
2767
|
-
deleteSyncedBlock: (organizationId, syncedBlockId, params = {}) => this.request({
|
|
2768
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}`,
|
|
2769
|
-
method: "DELETE",
|
|
2770
|
-
secure: true,
|
|
2771
|
-
...params
|
|
2772
|
-
}),
|
|
2773
|
-
getSyncedBlockContent: (organizationId, syncedBlockId, params = {}) => this.request({
|
|
2774
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}/content`,
|
|
2775
|
-
method: "GET",
|
|
2776
|
-
secure: true,
|
|
2777
|
-
format: "json",
|
|
2778
|
-
...params
|
|
2779
|
-
}),
|
|
2780
|
-
listSyncedBlockBacklinks: (organizationId, syncedBlockId, query, params = {}) => this.request({
|
|
2781
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}/backlinks`,
|
|
2782
|
-
method: "GET",
|
|
2783
|
-
query,
|
|
2784
|
-
secure: true,
|
|
2785
|
-
format: "json",
|
|
2786
|
-
...params
|
|
2787
|
-
}),
|
|
2788
|
-
listSyncedBlockSpaces: (organizationId, syncedBlockId, query, params = {}) => this.request({
|
|
2789
|
-
path: `/orgs/${organizationId}/synced-blocks/${syncedBlockId}/usage/spaces`,
|
|
2790
|
-
method: "GET",
|
|
2791
|
-
query,
|
|
2792
|
-
secure: true,
|
|
2793
|
-
format: "json",
|
|
2794
|
-
...params
|
|
2795
|
-
}),
|
|
2796
2711
|
askInOrganization: (organizationId, data, query, params = {}) => this.request({
|
|
2797
2712
|
path: `/orgs/${organizationId}/ask`,
|
|
2798
2713
|
method: "POST",
|
|
@@ -3127,6 +3042,15 @@ var Api = class extends HttpClient {
|
|
|
3127
3042
|
format: "json",
|
|
3128
3043
|
...params
|
|
3129
3044
|
}),
|
|
3045
|
+
moveSiteSection: (organizationId, siteId, siteSectionId, data, params = {}) => this.request({
|
|
3046
|
+
path: `/orgs/${organizationId}/sites/${siteId}/sections/${siteSectionId}/move`,
|
|
3047
|
+
method: "POST",
|
|
3048
|
+
body: data,
|
|
3049
|
+
secure: true,
|
|
3050
|
+
type: "application/json" /* Json */,
|
|
3051
|
+
format: "json",
|
|
3052
|
+
...params
|
|
3053
|
+
}),
|
|
3130
3054
|
moveSiteSpace: (organizationId, siteId, siteSpaceId, data, params = {}) => this.request({
|
|
3131
3055
|
path: `/orgs/${organizationId}/sites/${siteId}/site-spaces/${siteSpaceId}/move`,
|
|
3132
3056
|
method: "POST",
|