@gitbook/api 0.6.0 → 0.7.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/index.js CHANGED
@@ -105,7 +105,7 @@ var AnalyticsTrafficInterval = /* @__PURE__ */ ((AnalyticsTrafficInterval2) => {
105
105
  return AnalyticsTrafficInterval2;
106
106
  })(AnalyticsTrafficInterval || {});
107
107
  var IntegrationScope = /* @__PURE__ */ ((IntegrationScope2) => {
108
- IntegrationScope2["OrganizationEntitiesWrite"] = "organization:entities:write";
108
+ IntegrationScope2["EntitiesWrite"] = "entities:write";
109
109
  IntegrationScope2["RecordingWrite"] = "recording:write";
110
110
  IntegrationScope2["SpaceViewsRead"] = "space:views:read";
111
111
  IntegrationScope2["SpaceContentRead"] = "space:content:read";
@@ -216,6 +216,7 @@ var CustomFieldType = /* @__PURE__ */ ((CustomFieldType2) => {
216
216
  CustomFieldType2["Text"] = "text";
217
217
  CustomFieldType2["Number"] = "number";
218
218
  CustomFieldType2["Boolean"] = "boolean";
219
+ CustomFieldType2["Tags"] = "tags";
219
220
  return CustomFieldType2;
220
221
  })(CustomFieldType || {});
221
222
  var ContentType = /* @__PURE__ */ ((ContentType2) => {
@@ -991,43 +992,6 @@ var Api = class extends HttpClient {
991
992
  secure: true,
992
993
  type: "application/json" /* Json */,
993
994
  ...params
994
- }),
995
- listSpaceEntities: (spaceId, query, params = {}) => this.request({
996
- path: `/spaces/${spaceId}/entities`,
997
- method: "GET",
998
- query,
999
- secure: true,
1000
- format: "json",
1001
- ...params
1002
- }),
1003
- addSpaceEntities: (spaceId, data, params = {}) => this.request({
1004
- path: `/spaces/${spaceId}/entities`,
1005
- method: "POST",
1006
- body: data,
1007
- secure: true,
1008
- type: "application/json" /* Json */,
1009
- ...params
1010
- }),
1011
- getSpaceEntity: (spaceId, integrationName, entityId, params = {}) => this.request({
1012
- path: `/spaces/${spaceId}/entities/${integrationName}/${entityId}`,
1013
- method: "GET",
1014
- secure: true,
1015
- format: "json",
1016
- ...params
1017
- }),
1018
- updateSpaceEntity: (spaceId, integrationName, entityId, data, params = {}) => this.request({
1019
- path: `/spaces/${spaceId}/entities/${integrationName}/${entityId}`,
1020
- method: "PATCH",
1021
- body: data,
1022
- secure: true,
1023
- type: "application/json" /* Json */,
1024
- ...params
1025
- }),
1026
- deleteSpaceEntity: (spaceId, integrationName, entityId, params = {}) => this.request({
1027
- path: `/spaces/${spaceId}/entities/${integrationName}/${entityId}`,
1028
- method: "DELETE",
1029
- secure: true,
1030
- ...params
1031
995
  })
1032
996
  };
1033
997
  this.collections = {
@@ -1220,6 +1184,13 @@ var Api = class extends HttpClient {
1220
1184
  format: "json",
1221
1185
  ...params
1222
1186
  }),
1187
+ getIntegrationSpaceInstallation: (integrationName, installationId, spaceId, params = {}) => this.request({
1188
+ path: `/integrations/${integrationName}/installations/${installationId}/spaces/${spaceId}`,
1189
+ method: "GET",
1190
+ secure: true,
1191
+ format: "json",
1192
+ ...params
1193
+ }),
1223
1194
  updateIntegrationSpaceInstallation: (integrationName, installationId, spaceId, data, params = {}) => this.request({
1224
1195
  path: `/integrations/${integrationName}/installations/${installationId}/spaces/${spaceId}`,
1225
1196
  method: "PATCH",
@@ -1234,21 +1205,6 @@ var Api = class extends HttpClient {
1234
1205
  method: "DELETE",
1235
1206
  secure: true,
1236
1207
  ...params
1237
- }),
1238
- getIntegrationEntities: (integrationName, installationId, params = {}) => this.request({
1239
- path: `/integrations/${integrationName}/installations/${installationId}/entities`,
1240
- method: "GET",
1241
- secure: true,
1242
- format: "json",
1243
- ...params
1244
- }),
1245
- syncIntegrationEntities: (integrationName, installationId, data, params = {}) => this.request({
1246
- path: `/integrations/${integrationName}/installations/${installationId}/entities`,
1247
- method: "POST",
1248
- body: data,
1249
- secure: true,
1250
- type: "application/json" /* Json */,
1251
- ...params
1252
1208
  })
1253
1209
  };
1254
1210
  this.orgs = {
@@ -1565,14 +1521,6 @@ var Api = class extends HttpClient {
1565
1521
  format: "json",
1566
1522
  ...params
1567
1523
  }),
1568
- listEntitiesInOrganization: (organizationId, query, params = {}) => this.request({
1569
- path: `/orgs/${organizationId}/entities`,
1570
- method: "GET",
1571
- query,
1572
- secure: true,
1573
- format: "json",
1574
- ...params
1575
- }),
1576
1524
  listEnvironments: (organizationId, query, params = {}) => this.request({
1577
1525
  path: `/orgs/${organizationId}/environments`,
1578
1526
  method: "GET",
@@ -1612,6 +1560,58 @@ var Api = class extends HttpClient {
1612
1560
  secure: true,
1613
1561
  ...params
1614
1562
  }),
1563
+ listEntitySchemas: (organizationId, query, params = {}) => this.request({
1564
+ path: `/orgs/${organizationId}/schemas`,
1565
+ method: "GET",
1566
+ query,
1567
+ secure: true,
1568
+ format: "json",
1569
+ ...params
1570
+ }),
1571
+ getEntitySchema: (organizationId, entityType, params = {}) => this.request({
1572
+ path: `/orgs/${organizationId}/schemas/${entityType}`,
1573
+ method: "GET",
1574
+ secure: true,
1575
+ format: "json",
1576
+ ...params
1577
+ }),
1578
+ setEntitySchema: (organizationId, entityType, data, params = {}) => this.request({
1579
+ path: `/orgs/${organizationId}/schemas/${entityType}`,
1580
+ method: "PUT",
1581
+ body: data,
1582
+ secure: true,
1583
+ type: "application/json" /* Json */,
1584
+ ...params
1585
+ }),
1586
+ deleteEntitySchema: (organizationId, entityType, params = {}) => this.request({
1587
+ path: `/orgs/${organizationId}/schemas/${entityType}`,
1588
+ method: "DELETE",
1589
+ secure: true,
1590
+ ...params
1591
+ }),
1592
+ listSchemaEntities: (organizationId, entityType, query, params = {}) => this.request({
1593
+ path: `/orgs/${organizationId}/schemas/${entityType}/entities`,
1594
+ method: "GET",
1595
+ query,
1596
+ secure: true,
1597
+ format: "json",
1598
+ ...params
1599
+ }),
1600
+ upsertSchemaEntities: (organizationId, entityType, data, params = {}) => this.request({
1601
+ path: `/orgs/${organizationId}/schemas/${entityType}/entities`,
1602
+ method: "PUT",
1603
+ body: data,
1604
+ secure: true,
1605
+ type: "application/json" /* Json */,
1606
+ ...params
1607
+ }),
1608
+ getEntity: (organizationId, entityType, entityId, params = {}) => this.request({
1609
+ path: `/orgs/${organizationId}/schemas/${entityType}/entities/${entityId}`,
1610
+ method: "GET",
1611
+ secure: true,
1612
+ format: "json",
1613
+ ...params
1614
+ }),
1615
1615
  listRecordings: (organizationId, query, params = {}) => this.request({
1616
1616
  path: `/orgs/${organizationId}/recordings`,
1617
1617
  method: "GET",
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "main": "./dist/index.cjs",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
7
- "version": "0.6.0",
7
+ "version": "0.7.0",
8
8
  "sideEffects": false,
9
9
  "files": [
10
10
  "spec/**",