@gitbook/api 0.76.0 → 0.77.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 +136 -30
- package/dist/index.cjs +41 -1
- package/dist/index.js +41 -1
- package/package.json +1 -1
- package/spec/openapi.json +448 -31
- package/spec/openapi.yaml +266 -17
package/dist/client.d.ts
CHANGED
|
@@ -1597,28 +1597,10 @@ export interface Collection {
|
|
|
1597
1597
|
title: CollectionTitle;
|
|
1598
1598
|
/** Description of the collection */
|
|
1599
1599
|
description?: CollectionDescription;
|
|
1600
|
-
/** Path in the published URL */
|
|
1601
|
-
path?: string;
|
|
1602
|
-
/**
|
|
1603
|
-
* * `public`: Anyone can access the content, and the content is indexed by search engines.
|
|
1604
|
-
* * `unlisted`: Anyone can access the content, and the content is not indexed by search engines
|
|
1605
|
-
* * `share-link`: Anyone with a secret token in the url can access the content.
|
|
1606
|
-
* * `visitor-auth`: Anyone authenticated through a JWT token can access the content.
|
|
1607
|
-
* * `in-collection`: Anyone who can access the parent collection can access the content.
|
|
1608
|
-
* Only available for spaces in a collection.
|
|
1609
|
-
* * `private`: Authorized members can access the content.
|
|
1610
|
-
*/
|
|
1611
|
-
visibility: ContentVisibility;
|
|
1612
|
-
publishingType?: 'variants';
|
|
1613
1600
|
/** ID of the organization owning this collection */
|
|
1614
1601
|
organization: string;
|
|
1615
1602
|
/** ID of the parent collection, if any */
|
|
1616
1603
|
parent?: string;
|
|
1617
|
-
/**
|
|
1618
|
-
* ID of the parent collection, if any
|
|
1619
|
-
* @deprecated
|
|
1620
|
-
*/
|
|
1621
|
-
collection?: string;
|
|
1622
1604
|
/** Default level for a piece of content */
|
|
1623
1605
|
defaultLevel: DefaultLevel;
|
|
1624
1606
|
/** URLs associated with the object */
|
|
@@ -1634,6 +1616,13 @@ export interface Collection {
|
|
|
1634
1616
|
*/
|
|
1635
1617
|
app: string;
|
|
1636
1618
|
};
|
|
1619
|
+
/** The set of permissions for the collection */
|
|
1620
|
+
permissions: {
|
|
1621
|
+
/** Can the user edit the title/description. */
|
|
1622
|
+
admin: boolean;
|
|
1623
|
+
/** Can the user create spaces/collections in this collection. */
|
|
1624
|
+
create: boolean;
|
|
1625
|
+
};
|
|
1637
1626
|
}
|
|
1638
1627
|
export interface ContentLocationCollection {
|
|
1639
1628
|
kind: 'collection';
|
|
@@ -4305,6 +4294,38 @@ export interface InsightsContentPage {
|
|
|
4305
4294
|
/** Icon of the page, if one has been set. */
|
|
4306
4295
|
icon?: Icon;
|
|
4307
4296
|
}
|
|
4297
|
+
/**
|
|
4298
|
+
* The source path to redirect from.
|
|
4299
|
+
* @maxLength 512
|
|
4300
|
+
* @pattern ^/[a-zA-Z0-9-_.\/]+[a-zA-Z0-9-_.]$
|
|
4301
|
+
*/
|
|
4302
|
+
export type SiteRedirectSourcePath = string;
|
|
4303
|
+
export interface SiteRedirectDestinationSiteSection {
|
|
4304
|
+
kind: 'site-section';
|
|
4305
|
+
/** Unique identifier for the site section to redirect to */
|
|
4306
|
+
siteSectionId: string;
|
|
4307
|
+
}
|
|
4308
|
+
export interface SiteRedirectDestinationSiteSpace {
|
|
4309
|
+
kind: 'site-space';
|
|
4310
|
+
/** Unique identifier for the site space to redirect to */
|
|
4311
|
+
siteSpaceId: string;
|
|
4312
|
+
}
|
|
4313
|
+
export interface SiteRedirectDestinationPage {
|
|
4314
|
+
kind: 'site-page';
|
|
4315
|
+
/** Unique identifier for the site space of the page */
|
|
4316
|
+
siteSpaceId: string;
|
|
4317
|
+
/** Unique identifier for the page within the site space to redirect to */
|
|
4318
|
+
pageId: string;
|
|
4319
|
+
}
|
|
4320
|
+
export type SiteRedirectDestination = SiteRedirectDestinationSiteSection | SiteRedirectDestinationSiteSpace | SiteRedirectDestinationPage;
|
|
4321
|
+
export interface SiteRedirect {
|
|
4322
|
+
object: 'site-redirect';
|
|
4323
|
+
/** The unique identifier for the redirect. */
|
|
4324
|
+
id: string;
|
|
4325
|
+
/** The source path to redirect from. */
|
|
4326
|
+
source: SiteRedirectSourcePath;
|
|
4327
|
+
destination: SiteRedirectDestination;
|
|
4328
|
+
}
|
|
4308
4329
|
export declare enum CustomHostnameDnsStatus {
|
|
4309
4330
|
DnsPassed = "dns_passed",
|
|
4310
4331
|
DnsWrongCname = "dns_wrong_cname",
|
|
@@ -4970,6 +4991,10 @@ export interface PublishedContentSiteChannel {
|
|
|
4970
4991
|
channel: 'published-content-site';
|
|
4971
4992
|
site: string;
|
|
4972
4993
|
}
|
|
4994
|
+
export interface SiteRedirectsChannel {
|
|
4995
|
+
channel: 'site-redirects';
|
|
4996
|
+
site: string;
|
|
4997
|
+
}
|
|
4973
4998
|
export interface SiteChannel {
|
|
4974
4999
|
channel: 'site';
|
|
4975
5000
|
site: string;
|
|
@@ -5029,7 +5054,7 @@ export interface GitSyncOperationChannel {
|
|
|
5029
5054
|
space: string;
|
|
5030
5055
|
}
|
|
5031
5056
|
/** Channel to subscribe to for realtime updates. */
|
|
5032
|
-
export type SubscriptionChannel = SpaceInfoChannel | SpaceContentChannel | SpaceGitInfoChannel | SpacePublishingAuthChannel | SpacePublishingCustomizationChannel | SpaceCustomFieldsChannel | SpaceContentRefsChannel | SpaceIntegrationsChannel | OrganizationCustomFieldsChannel | UserAPITokensChannel | UserOrganizationsChannel | UserProfileChannel | ChangeRequestChannel | ChangeRequestsChannel | ChangeRequestReviewsChannel | ChangeRequestContentRefsChannel | CollectionChannel | CollectionPublishingCustomizationChannel | OrganizationInfoChannel | OrganizationInviteLinksChannel | OrganizationMembersChannel | OrganizationMemberChannel | OrganizationSAMLChannel | OrganizationTeamsChannel | OrganizationTeamChannel | OrganizationTeamMembersChannel | OrganizationTeamMemberChannel | OrganizationSpacesChannel | OrganizationCollectionsChannel | OrganizationCapturesChannel | OrganizationIntegrationsChannel | OrganizationInstallationsChannel | OrganizationSitesChannel | OrganizationExperimentalFeaturesChannel | SpaceCommentsChannel | ChangeRequestCommentsChannel | CommentInfoChannel | CommentReplyInfoChannel | CommentRepliesChannel | IntegrationChannel | IntegrationInstallationChannel | IntegrationSpaceInstallationChannel | IntegrationSpaceInstallationsChannel | IntegrationSiteInstallationChannel | IntegrationSiteInstallationsChannel | PublishedContentSiteChannel | SiteChannel | SiteCustomizationChannel | SiteIntegrationsChannel | SiteSpaceChannel | SiteSpaceCustomizationChannel | SiteStructureChannel | SitePublishingAuthChannel | SiteShareLinksChannel | SiteShareLinkChannel | SiteSectionChannel | CustomHostnameChannel | GitSyncSettingsChannel | GitSyncOperationChannel;
|
|
5057
|
+
export type SubscriptionChannel = SpaceInfoChannel | SpaceContentChannel | SpaceGitInfoChannel | SpacePublishingAuthChannel | SpacePublishingCustomizationChannel | SpaceCustomFieldsChannel | SpaceContentRefsChannel | SpaceIntegrationsChannel | OrganizationCustomFieldsChannel | UserAPITokensChannel | UserOrganizationsChannel | UserProfileChannel | ChangeRequestChannel | ChangeRequestsChannel | ChangeRequestReviewsChannel | ChangeRequestContentRefsChannel | CollectionChannel | CollectionPublishingCustomizationChannel | OrganizationInfoChannel | OrganizationInviteLinksChannel | OrganizationMembersChannel | OrganizationMemberChannel | OrganizationSAMLChannel | OrganizationTeamsChannel | OrganizationTeamChannel | OrganizationTeamMembersChannel | OrganizationTeamMemberChannel | OrganizationSpacesChannel | OrganizationCollectionsChannel | OrganizationCapturesChannel | OrganizationIntegrationsChannel | OrganizationInstallationsChannel | OrganizationSitesChannel | OrganizationExperimentalFeaturesChannel | SpaceCommentsChannel | ChangeRequestCommentsChannel | CommentInfoChannel | CommentReplyInfoChannel | CommentRepliesChannel | IntegrationChannel | IntegrationInstallationChannel | IntegrationSpaceInstallationChannel | IntegrationSpaceInstallationsChannel | IntegrationSiteInstallationChannel | IntegrationSiteInstallationsChannel | PublishedContentSiteChannel | SiteRedirectsChannel | SiteChannel | SiteCustomizationChannel | SiteIntegrationsChannel | SiteSpaceChannel | SiteSpaceCustomizationChannel | SiteStructureChannel | SitePublishingAuthChannel | SiteShareLinksChannel | SiteShareLinkChannel | SiteSectionChannel | CustomHostnameChannel | GitSyncSettingsChannel | GitSyncOperationChannel;
|
|
5033
5058
|
export interface GitSyncOperationChannelData {
|
|
5034
5059
|
channel: 'space-gitsync-operation';
|
|
5035
5060
|
/** Data passed on the channel messages for GitSync running in a space. */
|
|
@@ -5120,6 +5145,7 @@ export type SpaceVisitorAuth = VisitorAuth;
|
|
|
5120
5145
|
export type SpaceVisitorAuthCustomBackend = VisitorAuthCustomBackend;
|
|
5121
5146
|
export type SpaceVisitorAuthIntegrationBackend = VisitorAuthIntegrationBackend;
|
|
5122
5147
|
export type UserPermissions = Index;
|
|
5148
|
+
export type SiteRedirectDestinationSpace = SiteRedirectDestinationSiteSpace;
|
|
5123
5149
|
import { EventIterator } from 'event-iterator';
|
|
5124
5150
|
export type QueryParamsType = Record<string | number, any>;
|
|
5125
5151
|
export type ResponseFormat = keyof Omit<Body, 'body' | 'bodyUsed'>;
|
|
@@ -5211,6 +5237,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
5211
5237
|
* @secure
|
|
5212
5238
|
*/
|
|
5213
5239
|
searchContent: (query: {
|
|
5240
|
+
/** @maxLength 512 */
|
|
5214
5241
|
query: string;
|
|
5215
5242
|
/** Identifier of the page results to fetch. */
|
|
5216
5243
|
page?: string;
|
|
@@ -5459,6 +5486,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
5459
5486
|
* @secure
|
|
5460
5487
|
*/
|
|
5461
5488
|
searchSpaceContent: (spaceId: string, query: {
|
|
5489
|
+
/** @maxLength 512 */
|
|
5462
5490
|
query: string;
|
|
5463
5491
|
/** Identifier of the page results to fetch. */
|
|
5464
5492
|
page?: string;
|
|
@@ -7163,16 +7191,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
7163
7191
|
* @secure
|
|
7164
7192
|
*/
|
|
7165
7193
|
updateCollectionById: (collectionId: string, data: {
|
|
7166
|
-
/**
|
|
7167
|
-
* * `public`: Anyone can access the content, and the content is indexed by search engines.
|
|
7168
|
-
* * `unlisted`: Anyone can access the content, and the content is not indexed by search engines
|
|
7169
|
-
* * `share-link`: Anyone with a secret token in the url can access the content.
|
|
7170
|
-
* * `visitor-auth`: Anyone authenticated through a JWT token can access the content.
|
|
7171
|
-
* * `in-collection`: Anyone who can access the parent collection can access the content.
|
|
7172
|
-
* Only available for spaces in a collection.
|
|
7173
|
-
* * `private`: Authorized members can access the content.
|
|
7174
|
-
*/
|
|
7175
|
-
visibility?: ContentVisibility;
|
|
7176
7194
|
/** Title of the collection */
|
|
7177
7195
|
title?: CollectionTitle;
|
|
7178
7196
|
/** Description of the collection */
|
|
@@ -7983,7 +8001,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
7983
8001
|
/**
|
|
7984
8002
|
* @description Lists all spaces, collections, sites accessible by current user in the current organization. This endpoint is internal for now as the data structure is optimized for the sidebar.
|
|
7985
8003
|
*
|
|
7986
|
-
* @tags organizations
|
|
8004
|
+
* @tags organizations, critical
|
|
7987
8005
|
* @name GetOrganizationAllContent
|
|
7988
8006
|
* @summary List all content in an organization
|
|
7989
8007
|
* @request GET:/orgs/{organizationId}/content
|
|
@@ -8435,6 +8453,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8435
8453
|
* @secure
|
|
8436
8454
|
*/
|
|
8437
8455
|
searchOrganizationContent: (organizationId: string, query: {
|
|
8456
|
+
/** @maxLength 512 */
|
|
8438
8457
|
query: string;
|
|
8439
8458
|
/** Identifier of the page results to fetch. */
|
|
8440
8459
|
page?: string;
|
|
@@ -9743,15 +9762,18 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
9743
9762
|
mode?: "specific";
|
|
9744
9763
|
/** @minLength 1 */
|
|
9745
9764
|
siteSpaceIds: string[];
|
|
9765
|
+
/** @maxLength 512 */
|
|
9746
9766
|
query: string;
|
|
9747
9767
|
} | {
|
|
9748
9768
|
/** Search in the current site space and all section's defaults */
|
|
9749
9769
|
mode: "current";
|
|
9750
9770
|
siteSpaceId: string;
|
|
9771
|
+
/** @maxLength 512 */
|
|
9751
9772
|
query: string;
|
|
9752
9773
|
} | {
|
|
9753
9774
|
/** search in all site-spaces */
|
|
9754
9775
|
mode: "all";
|
|
9776
|
+
/** @maxLength 512 */
|
|
9755
9777
|
query: string;
|
|
9756
9778
|
}, query?: {
|
|
9757
9779
|
/** Identifier of the page results to fetch. */
|
|
@@ -10105,6 +10127,90 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10105
10127
|
/** Topic of the content */
|
|
10106
10128
|
topic?: SiteAdsTopic;
|
|
10107
10129
|
}, params?: RequestParams) => Promise<HttpResponse<void, Error>>;
|
|
10130
|
+
/**
|
|
10131
|
+
* No description
|
|
10132
|
+
*
|
|
10133
|
+
* @tags sites
|
|
10134
|
+
* @name CreateSiteRedirect
|
|
10135
|
+
* @summary Configure a redirect explicitly for a site.
|
|
10136
|
+
* @request POST:/orgs/{organizationId}/sites/{siteId}/redirects
|
|
10137
|
+
* @secure
|
|
10138
|
+
*/
|
|
10139
|
+
createSiteRedirect: (organizationId: string, siteId: string, data: {
|
|
10140
|
+
/** The source path to redirect from. */
|
|
10141
|
+
source: SiteRedirectSourcePath;
|
|
10142
|
+
destination: SiteRedirectDestination;
|
|
10143
|
+
}, params?: RequestParams) => Promise<HttpResponse<SiteRedirect, Error>>;
|
|
10144
|
+
/**
|
|
10145
|
+
* No description
|
|
10146
|
+
*
|
|
10147
|
+
* @tags sites
|
|
10148
|
+
* @name ListSiteRedirects
|
|
10149
|
+
* @summary List the redirects configured for a site.
|
|
10150
|
+
* @request GET:/orgs/{organizationId}/sites/{siteId}/redirects
|
|
10151
|
+
* @secure
|
|
10152
|
+
*/
|
|
10153
|
+
listSiteRedirects: (organizationId: string, siteId: string, query?: {
|
|
10154
|
+
/** Identifier of the page results to fetch. */
|
|
10155
|
+
page?: string;
|
|
10156
|
+
/**
|
|
10157
|
+
* The number of results per page
|
|
10158
|
+
* @min 0
|
|
10159
|
+
* @max 1000
|
|
10160
|
+
*/
|
|
10161
|
+
limit?: number;
|
|
10162
|
+
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
10163
|
+
items: SiteRedirect[];
|
|
10164
|
+
}, Error>>;
|
|
10165
|
+
/**
|
|
10166
|
+
* No description
|
|
10167
|
+
*
|
|
10168
|
+
* @tags sites
|
|
10169
|
+
* @name UpdateSiteRedirectById
|
|
10170
|
+
* @summary Update a redirect for a site
|
|
10171
|
+
* @request PATCH:/orgs/{organizationId}/sites/{siteId}/redirects/{siteRedirectId}
|
|
10172
|
+
* @secure
|
|
10173
|
+
*/
|
|
10174
|
+
updateSiteRedirectById: (organizationId: string, siteId: string, siteRedirectId: string, data: {
|
|
10175
|
+
/** The source path to redirect from. */
|
|
10176
|
+
source?: SiteRedirectSourcePath;
|
|
10177
|
+
destination?: SiteRedirectDestination;
|
|
10178
|
+
}, params?: RequestParams) => Promise<HttpResponse<SiteRedirect, Error>>;
|
|
10179
|
+
/**
|
|
10180
|
+
* No description
|
|
10181
|
+
*
|
|
10182
|
+
* @tags sites
|
|
10183
|
+
* @name DeleteSiteRedirectById
|
|
10184
|
+
* @summary Delete a redirect for a site
|
|
10185
|
+
* @request DELETE:/orgs/{organizationId}/sites/{siteId}/redirects/{siteRedirectId}
|
|
10186
|
+
* @secure
|
|
10187
|
+
*/
|
|
10188
|
+
deleteSiteRedirectById: (organizationId: string, siteId: string, siteRedirectId: string, params?: RequestParams) => Promise<HttpResponse<void, Error>>;
|
|
10189
|
+
/**
|
|
10190
|
+
* No description
|
|
10191
|
+
*
|
|
10192
|
+
* @tags sites
|
|
10193
|
+
* @name GetSiteRedirectBySource
|
|
10194
|
+
* @summary Resolve a redirect in a site by its source path.
|
|
10195
|
+
* @request GET:/orgs/{organizationId}/sites/{siteId}/redirect
|
|
10196
|
+
* @secure
|
|
10197
|
+
*/
|
|
10198
|
+
getSiteRedirectBySource: (organizationId: string, siteId: string, query: {
|
|
10199
|
+
/** For sites published via share-links, the share key is useful to resolve published URLs. */
|
|
10200
|
+
shareKey?: string;
|
|
10201
|
+
/** The source path of the redirect. */
|
|
10202
|
+
source: SiteRedirectSourcePath;
|
|
10203
|
+
}, params?: RequestParams) => Promise<HttpResponse<{
|
|
10204
|
+
redirect: SiteRedirect;
|
|
10205
|
+
/** URL of the destination of the redirect. */
|
|
10206
|
+
target: string;
|
|
10207
|
+
}, Error | {
|
|
10208
|
+
error: {
|
|
10209
|
+
/** @format int32 */
|
|
10210
|
+
code: 404;
|
|
10211
|
+
message: string;
|
|
10212
|
+
};
|
|
10213
|
+
}>>;
|
|
10108
10214
|
};
|
|
10109
10215
|
customHostnames: {
|
|
10110
10216
|
/**
|
package/dist/index.cjs
CHANGED
|
@@ -244,7 +244,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
244
244
|
|
|
245
245
|
// package.json
|
|
246
246
|
var name = "@gitbook/api";
|
|
247
|
-
var version = "0.
|
|
247
|
+
var version = "0.77.0";
|
|
248
248
|
|
|
249
249
|
// src/client.ts
|
|
250
250
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -3210,6 +3210,46 @@ var Api = class extends HttpClient {
|
|
|
3210
3210
|
secure: true,
|
|
3211
3211
|
type: "application/json" /* Json */,
|
|
3212
3212
|
...params
|
|
3213
|
+
}),
|
|
3214
|
+
createSiteRedirect: (organizationId, siteId, data, params = {}) => this.request({
|
|
3215
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects`,
|
|
3216
|
+
method: "POST",
|
|
3217
|
+
body: data,
|
|
3218
|
+
secure: true,
|
|
3219
|
+
type: "application/json" /* Json */,
|
|
3220
|
+
format: "json",
|
|
3221
|
+
...params
|
|
3222
|
+
}),
|
|
3223
|
+
listSiteRedirects: (organizationId, siteId, query, params = {}) => this.request({
|
|
3224
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects`,
|
|
3225
|
+
method: "GET",
|
|
3226
|
+
query,
|
|
3227
|
+
secure: true,
|
|
3228
|
+
format: "json",
|
|
3229
|
+
...params
|
|
3230
|
+
}),
|
|
3231
|
+
updateSiteRedirectById: (organizationId, siteId, siteRedirectId, data, params = {}) => this.request({
|
|
3232
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects/${siteRedirectId}`,
|
|
3233
|
+
method: "PATCH",
|
|
3234
|
+
body: data,
|
|
3235
|
+
secure: true,
|
|
3236
|
+
type: "application/json" /* Json */,
|
|
3237
|
+
format: "json",
|
|
3238
|
+
...params
|
|
3239
|
+
}),
|
|
3240
|
+
deleteSiteRedirectById: (organizationId, siteId, siteRedirectId, params = {}) => this.request({
|
|
3241
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects/${siteRedirectId}`,
|
|
3242
|
+
method: "DELETE",
|
|
3243
|
+
secure: true,
|
|
3244
|
+
...params
|
|
3245
|
+
}),
|
|
3246
|
+
getSiteRedirectBySource: (organizationId, siteId, query, params = {}) => this.request({
|
|
3247
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirect`,
|
|
3248
|
+
method: "GET",
|
|
3249
|
+
query,
|
|
3250
|
+
secure: true,
|
|
3251
|
+
format: "json",
|
|
3252
|
+
...params
|
|
3213
3253
|
})
|
|
3214
3254
|
};
|
|
3215
3255
|
customHostnames = {
|
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.77.0";
|
|
176
176
|
|
|
177
177
|
// src/client.ts
|
|
178
178
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -3138,6 +3138,46 @@ var Api = class extends HttpClient {
|
|
|
3138
3138
|
secure: true,
|
|
3139
3139
|
type: "application/json" /* Json */,
|
|
3140
3140
|
...params
|
|
3141
|
+
}),
|
|
3142
|
+
createSiteRedirect: (organizationId, siteId, data, params = {}) => this.request({
|
|
3143
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects`,
|
|
3144
|
+
method: "POST",
|
|
3145
|
+
body: data,
|
|
3146
|
+
secure: true,
|
|
3147
|
+
type: "application/json" /* Json */,
|
|
3148
|
+
format: "json",
|
|
3149
|
+
...params
|
|
3150
|
+
}),
|
|
3151
|
+
listSiteRedirects: (organizationId, siteId, query, params = {}) => this.request({
|
|
3152
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects`,
|
|
3153
|
+
method: "GET",
|
|
3154
|
+
query,
|
|
3155
|
+
secure: true,
|
|
3156
|
+
format: "json",
|
|
3157
|
+
...params
|
|
3158
|
+
}),
|
|
3159
|
+
updateSiteRedirectById: (organizationId, siteId, siteRedirectId, data, params = {}) => this.request({
|
|
3160
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects/${siteRedirectId}`,
|
|
3161
|
+
method: "PATCH",
|
|
3162
|
+
body: data,
|
|
3163
|
+
secure: true,
|
|
3164
|
+
type: "application/json" /* Json */,
|
|
3165
|
+
format: "json",
|
|
3166
|
+
...params
|
|
3167
|
+
}),
|
|
3168
|
+
deleteSiteRedirectById: (organizationId, siteId, siteRedirectId, params = {}) => this.request({
|
|
3169
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirects/${siteRedirectId}`,
|
|
3170
|
+
method: "DELETE",
|
|
3171
|
+
secure: true,
|
|
3172
|
+
...params
|
|
3173
|
+
}),
|
|
3174
|
+
getSiteRedirectBySource: (organizationId, siteId, query, params = {}) => this.request({
|
|
3175
|
+
path: `/orgs/${organizationId}/sites/${siteId}/redirect`,
|
|
3176
|
+
method: "GET",
|
|
3177
|
+
query,
|
|
3178
|
+
secure: true,
|
|
3179
|
+
format: "json",
|
|
3180
|
+
...params
|
|
3141
3181
|
})
|
|
3142
3182
|
};
|
|
3143
3183
|
customHostnames = {
|