@cakemail-org/ui-components-v2 2.2.91 → 2.2.92
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/cjs/factories/customDomains/index.d.ts +13 -0
- package/dist/cjs/factories/index.d.ts +1 -0
- package/dist/cjs/index.js +164 -1
- package/dist/cjs/models/customDomains/index.d.ts +22 -0
- package/dist/cjs/models/customDomains/types.d.ts +34 -0
- package/dist/cjs/models/index.d.ts +1 -0
- package/dist/cjs/models/pages/index.d.ts +2 -0
- package/dist/cjs/models/pages/types.d.ts +2 -0
- package/dist/cjs/services/customDomains/index.d.ts +18 -0
- package/dist/cjs/services/index.d.ts +1 -0
- package/dist/esm/factories/customDomains/index.d.ts +13 -0
- package/dist/esm/factories/index.d.ts +1 -0
- package/dist/esm/index.js +158 -2
- package/dist/esm/models/customDomains/index.d.ts +22 -0
- package/dist/esm/models/customDomains/types.d.ts +34 -0
- package/dist/esm/models/index.d.ts +1 -0
- package/dist/esm/models/pages/index.d.ts +2 -0
- package/dist/esm/models/pages/types.d.ts +2 -0
- package/dist/esm/services/customDomains/index.d.ts +18 -0
- package/dist/esm/services/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { CustomDomainModel } from "../../models/customDomains";
|
|
2
|
+
import { TGenericListParams, TGenericListReturn } from "../../types";
|
|
3
|
+
export declare class CustomDomainsFactory {
|
|
4
|
+
static list({ ...params }: TGenericListParams & {
|
|
5
|
+
verificationStatus?: string;
|
|
6
|
+
}): Promise<TGenericListReturn<CustomDomainModel>>;
|
|
7
|
+
static get({ id }: {
|
|
8
|
+
id: string;
|
|
9
|
+
}): Promise<CustomDomainModel>;
|
|
10
|
+
static create({ domain }: {
|
|
11
|
+
domain: string;
|
|
12
|
+
}): Promise<CustomDomainModel>;
|
|
13
|
+
}
|
package/dist/cjs/index.js
CHANGED
|
@@ -11032,6 +11032,75 @@ function untagContact(_a) {
|
|
|
11032
11032
|
});
|
|
11033
11033
|
}
|
|
11034
11034
|
|
|
11035
|
+
var baseUrl = function () { return uiKitConfig.GATEWAY_PROXY + "/customDomains"; };
|
|
11036
|
+
function listCustomDomains(_a) {
|
|
11037
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
11038
|
+
var options = __rest(_a, []);
|
|
11039
|
+
return __generator(this, function (_b) {
|
|
11040
|
+
return [2 /*return*/, callApi({
|
|
11041
|
+
url: baseUrl(),
|
|
11042
|
+
query: camelCase(options),
|
|
11043
|
+
fetchOptions: {
|
|
11044
|
+
method: exports.EMethods.get,
|
|
11045
|
+
},
|
|
11046
|
+
})];
|
|
11047
|
+
});
|
|
11048
|
+
});
|
|
11049
|
+
}
|
|
11050
|
+
function createCustomDomain(_a) {
|
|
11051
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11052
|
+
var domain = _b.domain;
|
|
11053
|
+
return __generator(this, function (_c) {
|
|
11054
|
+
return [2 /*return*/, callApi({
|
|
11055
|
+
url: baseUrl(),
|
|
11056
|
+
fetchOptions: {
|
|
11057
|
+
method: exports.EMethods.post,
|
|
11058
|
+
body: { domain: domain },
|
|
11059
|
+
},
|
|
11060
|
+
})];
|
|
11061
|
+
});
|
|
11062
|
+
});
|
|
11063
|
+
}
|
|
11064
|
+
function getCustomDomain(_a) {
|
|
11065
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11066
|
+
var id = _b.id;
|
|
11067
|
+
return __generator(this, function (_c) {
|
|
11068
|
+
return [2 /*return*/, callApi({
|
|
11069
|
+
url: "".concat(baseUrl(), "/").concat(id),
|
|
11070
|
+
fetchOptions: {
|
|
11071
|
+
method: exports.EMethods.get,
|
|
11072
|
+
},
|
|
11073
|
+
})];
|
|
11074
|
+
});
|
|
11075
|
+
});
|
|
11076
|
+
}
|
|
11077
|
+
function deleteCustomDomain(_a) {
|
|
11078
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11079
|
+
var id = _b.id;
|
|
11080
|
+
return __generator(this, function (_c) {
|
|
11081
|
+
return [2 /*return*/, callApi({
|
|
11082
|
+
url: "".concat(baseUrl(), "/").concat(id),
|
|
11083
|
+
fetchOptions: {
|
|
11084
|
+
method: exports.EMethods.delete,
|
|
11085
|
+
},
|
|
11086
|
+
})];
|
|
11087
|
+
});
|
|
11088
|
+
});
|
|
11089
|
+
}
|
|
11090
|
+
function verifyCustomDomain(_a) {
|
|
11091
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11092
|
+
var id = _b.id;
|
|
11093
|
+
return __generator(this, function (_c) {
|
|
11094
|
+
return [2 /*return*/, callApi({
|
|
11095
|
+
url: "".concat(baseUrl(), "/").concat(id, "/verify"),
|
|
11096
|
+
fetchOptions: {
|
|
11097
|
+
method: exports.EMethods.post,
|
|
11098
|
+
},
|
|
11099
|
+
})];
|
|
11100
|
+
});
|
|
11101
|
+
});
|
|
11102
|
+
}
|
|
11103
|
+
|
|
11035
11104
|
exports.EEmailLogTypeParam = void 0;
|
|
11036
11105
|
(function (EEmailLogTypeParam) {
|
|
11037
11106
|
EEmailLogTypeParam["all"] = "all";
|
|
@@ -12049,6 +12118,57 @@ var ContactModel = /** @class */ (function () {
|
|
|
12049
12118
|
return ContactModel;
|
|
12050
12119
|
}());
|
|
12051
12120
|
|
|
12121
|
+
exports.ECustomDomainVerificationStatus = void 0;
|
|
12122
|
+
(function (ECustomDomainVerificationStatus) {
|
|
12123
|
+
ECustomDomainVerificationStatus["pending"] = "pending";
|
|
12124
|
+
ECustomDomainVerificationStatus["verified"] = "verified";
|
|
12125
|
+
ECustomDomainVerificationStatus["failed"] = "failed";
|
|
12126
|
+
})(exports.ECustomDomainVerificationStatus || (exports.ECustomDomainVerificationStatus = {}));
|
|
12127
|
+
|
|
12128
|
+
var CustomDomainModel = /** @class */ (function () {
|
|
12129
|
+
function CustomDomainModel(params) {
|
|
12130
|
+
this.id = params.id;
|
|
12131
|
+
this.account_id = params.account_id;
|
|
12132
|
+
this.domain = params.domain;
|
|
12133
|
+
this.verification_status = params.verification_status;
|
|
12134
|
+
this.verified_on = params.verified_on;
|
|
12135
|
+
this.created_on = params.created_on;
|
|
12136
|
+
this.updated_on = params.updated_on;
|
|
12137
|
+
this.dns_instructions = params.dns_instructions;
|
|
12138
|
+
}
|
|
12139
|
+
Object.defineProperty(CustomDomainModel.prototype, "isVerified", {
|
|
12140
|
+
get: function () {
|
|
12141
|
+
return this.verification_status === exports.ECustomDomainVerificationStatus.verified;
|
|
12142
|
+
},
|
|
12143
|
+
enumerable: false,
|
|
12144
|
+
configurable: true
|
|
12145
|
+
});
|
|
12146
|
+
CustomDomainModel.prototype.toJson = function () {
|
|
12147
|
+
return modelToJson(this);
|
|
12148
|
+
};
|
|
12149
|
+
CustomDomainModel.prototype.set = function (property, value) {
|
|
12150
|
+
modelSet(this, property, value);
|
|
12151
|
+
};
|
|
12152
|
+
CustomDomainModel.prototype.verify = function () {
|
|
12153
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
12154
|
+
return __generator(this, function (_a) {
|
|
12155
|
+
return [2 /*return*/, verifyCustomDomain({ id: this.id }).then(function (res) { return ({
|
|
12156
|
+
domain: new CustomDomainModel(res.data),
|
|
12157
|
+
verification: res.data.verification,
|
|
12158
|
+
}); })];
|
|
12159
|
+
});
|
|
12160
|
+
});
|
|
12161
|
+
};
|
|
12162
|
+
CustomDomainModel.prototype.delete = function () {
|
|
12163
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
12164
|
+
return __generator(this, function (_a) {
|
|
12165
|
+
return [2 /*return*/, deleteCustomDomain({ id: this.id })];
|
|
12166
|
+
});
|
|
12167
|
+
});
|
|
12168
|
+
};
|
|
12169
|
+
return CustomDomainModel;
|
|
12170
|
+
}());
|
|
12171
|
+
|
|
12052
12172
|
exports.EEmailAttachementTypes = void 0;
|
|
12053
12173
|
(function (EEmailAttachementTypes) {
|
|
12054
12174
|
EEmailAttachementTypes["csv"] = "csv";
|
|
@@ -12479,6 +12599,7 @@ exports.EPageBranding = void 0;
|
|
|
12479
12599
|
|
|
12480
12600
|
var ListPageModel = /** @class */ (function () {
|
|
12481
12601
|
function ListPageModel(params) {
|
|
12602
|
+
var _a, _b;
|
|
12482
12603
|
this.id = params.id;
|
|
12483
12604
|
this.name = params.name;
|
|
12484
12605
|
this.list_id = params.list_id;
|
|
@@ -12498,6 +12619,8 @@ var ListPageModel = /** @class */ (function () {
|
|
|
12498
12619
|
this.form_id = params.form_id;
|
|
12499
12620
|
this.thumbnail_url = params.thumbnail_url;
|
|
12500
12621
|
this.published_url = params.published_url;
|
|
12622
|
+
this.custom_domain_id = (_a = params.custom_domain_id) !== null && _a !== void 0 ? _a : null;
|
|
12623
|
+
this.custom_domain = (_b = params.custom_domain) !== null && _b !== void 0 ? _b : null;
|
|
12501
12624
|
}
|
|
12502
12625
|
ListPageModel.prototype.toJson = function () {
|
|
12503
12626
|
return modelToJson(this);
|
|
@@ -12523,7 +12646,6 @@ var ListPageModel = /** @class */ (function () {
|
|
|
12523
12646
|
return __generator(this, function (_a) {
|
|
12524
12647
|
dataToUpdate = page || this.toJson();
|
|
12525
12648
|
return [2 /*return*/, updatePage({ id: this.id, page: dataToUpdate }).then(function (data) {
|
|
12526
|
-
debugger;
|
|
12527
12649
|
trackEvent(exports.EEvents.PAGE_UPDATED, {
|
|
12528
12650
|
id: _this.id,
|
|
12529
12651
|
name: dataToUpdate === null || dataToUpdate === void 0 ? void 0 : dataToUpdate.name,
|
|
@@ -19239,6 +19361,40 @@ var ContactsFactory = /** @class */ (function () {
|
|
|
19239
19361
|
return ContactsFactory;
|
|
19240
19362
|
}());
|
|
19241
19363
|
|
|
19364
|
+
var CustomDomainsFactory = /** @class */ (function () {
|
|
19365
|
+
function CustomDomainsFactory() {
|
|
19366
|
+
}
|
|
19367
|
+
CustomDomainsFactory.list = function (_a) {
|
|
19368
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
19369
|
+
var params = __rest(_a, []);
|
|
19370
|
+
return __generator(this, function (_b) {
|
|
19371
|
+
return [2 /*return*/, listCustomDomains(params).then(function (data) { return (__assign(__assign({}, data), { data: data.data.map(function (row) { return new CustomDomainModel(row); }) })); })];
|
|
19372
|
+
});
|
|
19373
|
+
});
|
|
19374
|
+
};
|
|
19375
|
+
CustomDomainsFactory.get = function (_a) {
|
|
19376
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
19377
|
+
var id = _b.id;
|
|
19378
|
+
return __generator(this, function (_c) {
|
|
19379
|
+
return [2 /*return*/, getCustomDomain({ id: id }).then(function (data) {
|
|
19380
|
+
return new CustomDomainModel(data.data);
|
|
19381
|
+
})];
|
|
19382
|
+
});
|
|
19383
|
+
});
|
|
19384
|
+
};
|
|
19385
|
+
CustomDomainsFactory.create = function (_a) {
|
|
19386
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
19387
|
+
var domain = _b.domain;
|
|
19388
|
+
return __generator(this, function (_c) {
|
|
19389
|
+
return [2 /*return*/, createCustomDomain({ domain: domain }).then(function (data) {
|
|
19390
|
+
return new CustomDomainModel(data.data);
|
|
19391
|
+
})];
|
|
19392
|
+
});
|
|
19393
|
+
});
|
|
19394
|
+
};
|
|
19395
|
+
return CustomDomainsFactory;
|
|
19396
|
+
}());
|
|
19397
|
+
|
|
19242
19398
|
exports.EEmailLogType = void 0;
|
|
19243
19399
|
(function (EEmailLogType) {
|
|
19244
19400
|
EEmailLogType["submitted"] = "submitted";
|
|
@@ -19911,6 +20067,8 @@ exports.ContactModel = ContactModel;
|
|
|
19911
20067
|
exports.ContactsFactory = ContactsFactory;
|
|
19912
20068
|
exports.ContentSectionContainer = ContentSectionContainer;
|
|
19913
20069
|
exports.CountryDropdown = CountryDropdown;
|
|
20070
|
+
exports.CustomDomainModel = CustomDomainModel;
|
|
20071
|
+
exports.CustomDomainsFactory = CustomDomainsFactory;
|
|
19914
20072
|
exports.CustomerModel = CustomerModel;
|
|
19915
20073
|
exports.DataTable = DataTable;
|
|
19916
20074
|
exports.DataTableHead = DataTableHead;
|
|
@@ -20020,6 +20178,7 @@ exports.createCampaign = createCampaign;
|
|
|
20020
20178
|
exports.createCampaignLogsExports = createCampaignLogsExports;
|
|
20021
20179
|
exports.createCampaignsReportsExport = createCampaignsReportsExport;
|
|
20022
20180
|
exports.createContactsExport = createContactsExport;
|
|
20181
|
+
exports.createCustomDomain = createCustomDomain;
|
|
20023
20182
|
exports.createForm = createForm;
|
|
20024
20183
|
exports.createPage = createPage;
|
|
20025
20184
|
exports.createPopup = createPopup;
|
|
@@ -20032,6 +20191,7 @@ exports.deleteAutomation = deleteAutomation;
|
|
|
20032
20191
|
exports.deleteCampaign = deleteCampaign;
|
|
20033
20192
|
exports.deleteCampaignsReportsExport = deleteCampaignsReportsExport;
|
|
20034
20193
|
exports.deleteContact = deleteContact;
|
|
20194
|
+
exports.deleteCustomDomain = deleteCustomDomain;
|
|
20035
20195
|
exports.deleteForm = deleteForm;
|
|
20036
20196
|
exports.deleteList = deleteList;
|
|
20037
20197
|
exports.deletePage = deletePage;
|
|
@@ -20093,6 +20253,7 @@ exports.getCampaignRevisions = getCampaignRevisions;
|
|
|
20093
20253
|
exports.getCampaignsReportsExport = getCampaignsReportsExport;
|
|
20094
20254
|
exports.getComparator = getComparator;
|
|
20095
20255
|
exports.getContactsExport = getContactsExport;
|
|
20256
|
+
exports.getCustomDomain = getCustomDomain;
|
|
20096
20257
|
exports.getCustomerProfile = getCustomerProfile;
|
|
20097
20258
|
exports.getDate = getDate;
|
|
20098
20259
|
exports.getDomainFromEmail = getDomainFromEmail;
|
|
@@ -20140,6 +20301,7 @@ exports.listAutomations = listAutomations;
|
|
|
20140
20301
|
exports.listCampaigns = listCampaigns;
|
|
20141
20302
|
exports.listCampaignsReportsExports = listCampaignsReportsExports;
|
|
20142
20303
|
exports.listContacts = listContacts;
|
|
20304
|
+
exports.listCustomDomains = listCustomDomains;
|
|
20143
20305
|
exports.listDkimService = listDkimService;
|
|
20144
20306
|
exports.listEmailLogs = listEmailLogs;
|
|
20145
20307
|
exports.listForms = listForms;
|
|
@@ -20224,6 +20386,7 @@ exports.validateColor = validateColor;
|
|
|
20224
20386
|
exports.validateEmail = validateEmail;
|
|
20225
20387
|
exports.validateGenericInput = validateGenericInput;
|
|
20226
20388
|
exports.validateUrl = validateUrl;
|
|
20389
|
+
exports.verifyCustomDomain = verifyCustomDomain;
|
|
20227
20390
|
exports.wait = wait;
|
|
20228
20391
|
exports.whiteLabelBrand = whiteLabelBrand;
|
|
20229
20392
|
exports.whoAmi = whoAmi;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { TDeleteApiResource } from "../../types";
|
|
2
|
+
import { ECustomDomainVerificationStatus, TCustomDomainModel, TCustomDomainVerificationPayload } from "./types";
|
|
3
|
+
export declare class CustomDomainModel {
|
|
4
|
+
id: string;
|
|
5
|
+
account_id: number;
|
|
6
|
+
domain: string;
|
|
7
|
+
verification_status: ECustomDomainVerificationStatus;
|
|
8
|
+
verified_on: number | null;
|
|
9
|
+
created_on: number;
|
|
10
|
+
updated_on: number;
|
|
11
|
+
dns_instructions: TCustomDomainModel["dns_instructions"];
|
|
12
|
+
constructor(params: TCustomDomainModel);
|
|
13
|
+
get isVerified(): boolean;
|
|
14
|
+
toJson(): TCustomDomainModel;
|
|
15
|
+
set<T extends keyof this>(property: T, value: this[T]): void;
|
|
16
|
+
verify(): Promise<{
|
|
17
|
+
domain: CustomDomainModel;
|
|
18
|
+
verification: TCustomDomainVerificationPayload;
|
|
19
|
+
}>;
|
|
20
|
+
delete(): Promise<TDeleteApiResource>;
|
|
21
|
+
}
|
|
22
|
+
export * from "./types";
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export declare enum ECustomDomainVerificationStatus {
|
|
2
|
+
pending = "pending",
|
|
3
|
+
verified = "verified",
|
|
4
|
+
failed = "failed"
|
|
5
|
+
}
|
|
6
|
+
export type TCustomDomainDnsCname = {
|
|
7
|
+
hostname: string;
|
|
8
|
+
point_to: string;
|
|
9
|
+
help: string;
|
|
10
|
+
};
|
|
11
|
+
export type TCustomDomainDnsInstructions = {
|
|
12
|
+
cname: TCustomDomainDnsCname;
|
|
13
|
+
extra_dns?: Array<{
|
|
14
|
+
hostname: string;
|
|
15
|
+
help: string;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
export type TCustomDomainModel = {
|
|
19
|
+
id: string;
|
|
20
|
+
account_id: number;
|
|
21
|
+
domain: string;
|
|
22
|
+
verification_status: ECustomDomainVerificationStatus;
|
|
23
|
+
verified_on: number | null;
|
|
24
|
+
created_on: number;
|
|
25
|
+
updated_on: number;
|
|
26
|
+
dns_instructions: TCustomDomainDnsInstructions;
|
|
27
|
+
};
|
|
28
|
+
export type TCustomDomainVerificationPayload = {
|
|
29
|
+
success: boolean;
|
|
30
|
+
message: string;
|
|
31
|
+
};
|
|
32
|
+
export type TCustomDomainVerifyResult = TCustomDomainModel & {
|
|
33
|
+
verification: TCustomDomainVerificationPayload;
|
|
34
|
+
};
|
|
@@ -20,6 +20,8 @@ export declare class ListPageModel {
|
|
|
20
20
|
form_id: string | null;
|
|
21
21
|
thumbnail_url: string;
|
|
22
22
|
published_url: string | null;
|
|
23
|
+
custom_domain_id: string | null;
|
|
24
|
+
custom_domain: string | null;
|
|
23
25
|
constructor(params: TPageModel);
|
|
24
26
|
toJson(): any;
|
|
25
27
|
set<T extends keyof this>(property: T, value: this[T]): void;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { TCustomDomainModel, TCustomDomainVerifyResult } from "../../models/customDomains/types";
|
|
2
|
+
import { TGenericListParams, TGenericListReturn, TGenericReturn } from "../../types";
|
|
3
|
+
import { TCreateApiResource, TDeleteApiResource, TUpdateApiResource } from "../../types/generic";
|
|
4
|
+
export declare function listCustomDomains({ ...options }: TGenericListParams & {
|
|
5
|
+
verificationStatus?: string;
|
|
6
|
+
}): Promise<TGenericListReturn<TCustomDomainModel>>;
|
|
7
|
+
export declare function createCustomDomain({ domain, }: {
|
|
8
|
+
domain: string;
|
|
9
|
+
}): Promise<TCreateApiResource<TCustomDomainModel>>;
|
|
10
|
+
export declare function getCustomDomain({ id }: {
|
|
11
|
+
id: string;
|
|
12
|
+
}): Promise<TGenericReturn<TCustomDomainModel>>;
|
|
13
|
+
export declare function deleteCustomDomain({ id }: {
|
|
14
|
+
id: string;
|
|
15
|
+
}): Promise<TDeleteApiResource>;
|
|
16
|
+
export declare function verifyCustomDomain({ id, }: {
|
|
17
|
+
id: string;
|
|
18
|
+
}): Promise<TUpdateApiResource<TCustomDomainVerifyResult>>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { CustomDomainModel } from "../../models/customDomains";
|
|
2
|
+
import { TGenericListParams, TGenericListReturn } from "../../types";
|
|
3
|
+
export declare class CustomDomainsFactory {
|
|
4
|
+
static list({ ...params }: TGenericListParams & {
|
|
5
|
+
verificationStatus?: string;
|
|
6
|
+
}): Promise<TGenericListReturn<CustomDomainModel>>;
|
|
7
|
+
static get({ id }: {
|
|
8
|
+
id: string;
|
|
9
|
+
}): Promise<CustomDomainModel>;
|
|
10
|
+
static create({ domain }: {
|
|
11
|
+
domain: string;
|
|
12
|
+
}): Promise<CustomDomainModel>;
|
|
13
|
+
}
|
package/dist/esm/index.js
CHANGED
|
@@ -11012,6 +11012,75 @@ function untagContact(_a) {
|
|
|
11012
11012
|
});
|
|
11013
11013
|
}
|
|
11014
11014
|
|
|
11015
|
+
var baseUrl = function () { return uiKitConfig.GATEWAY_PROXY + "/customDomains"; };
|
|
11016
|
+
function listCustomDomains(_a) {
|
|
11017
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
11018
|
+
var options = __rest(_a, []);
|
|
11019
|
+
return __generator(this, function (_b) {
|
|
11020
|
+
return [2 /*return*/, callApi({
|
|
11021
|
+
url: baseUrl(),
|
|
11022
|
+
query: camelCase(options),
|
|
11023
|
+
fetchOptions: {
|
|
11024
|
+
method: EMethods.get,
|
|
11025
|
+
},
|
|
11026
|
+
})];
|
|
11027
|
+
});
|
|
11028
|
+
});
|
|
11029
|
+
}
|
|
11030
|
+
function createCustomDomain(_a) {
|
|
11031
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11032
|
+
var domain = _b.domain;
|
|
11033
|
+
return __generator(this, function (_c) {
|
|
11034
|
+
return [2 /*return*/, callApi({
|
|
11035
|
+
url: baseUrl(),
|
|
11036
|
+
fetchOptions: {
|
|
11037
|
+
method: EMethods.post,
|
|
11038
|
+
body: { domain: domain },
|
|
11039
|
+
},
|
|
11040
|
+
})];
|
|
11041
|
+
});
|
|
11042
|
+
});
|
|
11043
|
+
}
|
|
11044
|
+
function getCustomDomain(_a) {
|
|
11045
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11046
|
+
var id = _b.id;
|
|
11047
|
+
return __generator(this, function (_c) {
|
|
11048
|
+
return [2 /*return*/, callApi({
|
|
11049
|
+
url: "".concat(baseUrl(), "/").concat(id),
|
|
11050
|
+
fetchOptions: {
|
|
11051
|
+
method: EMethods.get,
|
|
11052
|
+
},
|
|
11053
|
+
})];
|
|
11054
|
+
});
|
|
11055
|
+
});
|
|
11056
|
+
}
|
|
11057
|
+
function deleteCustomDomain(_a) {
|
|
11058
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11059
|
+
var id = _b.id;
|
|
11060
|
+
return __generator(this, function (_c) {
|
|
11061
|
+
return [2 /*return*/, callApi({
|
|
11062
|
+
url: "".concat(baseUrl(), "/").concat(id),
|
|
11063
|
+
fetchOptions: {
|
|
11064
|
+
method: EMethods.delete,
|
|
11065
|
+
},
|
|
11066
|
+
})];
|
|
11067
|
+
});
|
|
11068
|
+
});
|
|
11069
|
+
}
|
|
11070
|
+
function verifyCustomDomain(_a) {
|
|
11071
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
11072
|
+
var id = _b.id;
|
|
11073
|
+
return __generator(this, function (_c) {
|
|
11074
|
+
return [2 /*return*/, callApi({
|
|
11075
|
+
url: "".concat(baseUrl(), "/").concat(id, "/verify"),
|
|
11076
|
+
fetchOptions: {
|
|
11077
|
+
method: EMethods.post,
|
|
11078
|
+
},
|
|
11079
|
+
})];
|
|
11080
|
+
});
|
|
11081
|
+
});
|
|
11082
|
+
}
|
|
11083
|
+
|
|
11015
11084
|
var EEmailLogTypeParam;
|
|
11016
11085
|
(function (EEmailLogTypeParam) {
|
|
11017
11086
|
EEmailLogTypeParam["all"] = "all";
|
|
@@ -12029,6 +12098,57 @@ var ContactModel = /** @class */ (function () {
|
|
|
12029
12098
|
return ContactModel;
|
|
12030
12099
|
}());
|
|
12031
12100
|
|
|
12101
|
+
var ECustomDomainVerificationStatus;
|
|
12102
|
+
(function (ECustomDomainVerificationStatus) {
|
|
12103
|
+
ECustomDomainVerificationStatus["pending"] = "pending";
|
|
12104
|
+
ECustomDomainVerificationStatus["verified"] = "verified";
|
|
12105
|
+
ECustomDomainVerificationStatus["failed"] = "failed";
|
|
12106
|
+
})(ECustomDomainVerificationStatus || (ECustomDomainVerificationStatus = {}));
|
|
12107
|
+
|
|
12108
|
+
var CustomDomainModel = /** @class */ (function () {
|
|
12109
|
+
function CustomDomainModel(params) {
|
|
12110
|
+
this.id = params.id;
|
|
12111
|
+
this.account_id = params.account_id;
|
|
12112
|
+
this.domain = params.domain;
|
|
12113
|
+
this.verification_status = params.verification_status;
|
|
12114
|
+
this.verified_on = params.verified_on;
|
|
12115
|
+
this.created_on = params.created_on;
|
|
12116
|
+
this.updated_on = params.updated_on;
|
|
12117
|
+
this.dns_instructions = params.dns_instructions;
|
|
12118
|
+
}
|
|
12119
|
+
Object.defineProperty(CustomDomainModel.prototype, "isVerified", {
|
|
12120
|
+
get: function () {
|
|
12121
|
+
return this.verification_status === ECustomDomainVerificationStatus.verified;
|
|
12122
|
+
},
|
|
12123
|
+
enumerable: false,
|
|
12124
|
+
configurable: true
|
|
12125
|
+
});
|
|
12126
|
+
CustomDomainModel.prototype.toJson = function () {
|
|
12127
|
+
return modelToJson(this);
|
|
12128
|
+
};
|
|
12129
|
+
CustomDomainModel.prototype.set = function (property, value) {
|
|
12130
|
+
modelSet(this, property, value);
|
|
12131
|
+
};
|
|
12132
|
+
CustomDomainModel.prototype.verify = function () {
|
|
12133
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
12134
|
+
return __generator(this, function (_a) {
|
|
12135
|
+
return [2 /*return*/, verifyCustomDomain({ id: this.id }).then(function (res) { return ({
|
|
12136
|
+
domain: new CustomDomainModel(res.data),
|
|
12137
|
+
verification: res.data.verification,
|
|
12138
|
+
}); })];
|
|
12139
|
+
});
|
|
12140
|
+
});
|
|
12141
|
+
};
|
|
12142
|
+
CustomDomainModel.prototype.delete = function () {
|
|
12143
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
12144
|
+
return __generator(this, function (_a) {
|
|
12145
|
+
return [2 /*return*/, deleteCustomDomain({ id: this.id })];
|
|
12146
|
+
});
|
|
12147
|
+
});
|
|
12148
|
+
};
|
|
12149
|
+
return CustomDomainModel;
|
|
12150
|
+
}());
|
|
12151
|
+
|
|
12032
12152
|
var EEmailAttachementTypes;
|
|
12033
12153
|
(function (EEmailAttachementTypes) {
|
|
12034
12154
|
EEmailAttachementTypes["csv"] = "csv";
|
|
@@ -12459,6 +12579,7 @@ var EPageBranding;
|
|
|
12459
12579
|
|
|
12460
12580
|
var ListPageModel = /** @class */ (function () {
|
|
12461
12581
|
function ListPageModel(params) {
|
|
12582
|
+
var _a, _b;
|
|
12462
12583
|
this.id = params.id;
|
|
12463
12584
|
this.name = params.name;
|
|
12464
12585
|
this.list_id = params.list_id;
|
|
@@ -12478,6 +12599,8 @@ var ListPageModel = /** @class */ (function () {
|
|
|
12478
12599
|
this.form_id = params.form_id;
|
|
12479
12600
|
this.thumbnail_url = params.thumbnail_url;
|
|
12480
12601
|
this.published_url = params.published_url;
|
|
12602
|
+
this.custom_domain_id = (_a = params.custom_domain_id) !== null && _a !== void 0 ? _a : null;
|
|
12603
|
+
this.custom_domain = (_b = params.custom_domain) !== null && _b !== void 0 ? _b : null;
|
|
12481
12604
|
}
|
|
12482
12605
|
ListPageModel.prototype.toJson = function () {
|
|
12483
12606
|
return modelToJson(this);
|
|
@@ -12503,7 +12626,6 @@ var ListPageModel = /** @class */ (function () {
|
|
|
12503
12626
|
return __generator(this, function (_a) {
|
|
12504
12627
|
dataToUpdate = page || this.toJson();
|
|
12505
12628
|
return [2 /*return*/, updatePage({ id: this.id, page: dataToUpdate }).then(function (data) {
|
|
12506
|
-
debugger;
|
|
12507
12629
|
trackEvent(EEvents.PAGE_UPDATED, {
|
|
12508
12630
|
id: _this.id,
|
|
12509
12631
|
name: dataToUpdate === null || dataToUpdate === void 0 ? void 0 : dataToUpdate.name,
|
|
@@ -19219,6 +19341,40 @@ var ContactsFactory = /** @class */ (function () {
|
|
|
19219
19341
|
return ContactsFactory;
|
|
19220
19342
|
}());
|
|
19221
19343
|
|
|
19344
|
+
var CustomDomainsFactory = /** @class */ (function () {
|
|
19345
|
+
function CustomDomainsFactory() {
|
|
19346
|
+
}
|
|
19347
|
+
CustomDomainsFactory.list = function (_a) {
|
|
19348
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
19349
|
+
var params = __rest(_a, []);
|
|
19350
|
+
return __generator(this, function (_b) {
|
|
19351
|
+
return [2 /*return*/, listCustomDomains(params).then(function (data) { return (__assign(__assign({}, data), { data: data.data.map(function (row) { return new CustomDomainModel(row); }) })); })];
|
|
19352
|
+
});
|
|
19353
|
+
});
|
|
19354
|
+
};
|
|
19355
|
+
CustomDomainsFactory.get = function (_a) {
|
|
19356
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
19357
|
+
var id = _b.id;
|
|
19358
|
+
return __generator(this, function (_c) {
|
|
19359
|
+
return [2 /*return*/, getCustomDomain({ id: id }).then(function (data) {
|
|
19360
|
+
return new CustomDomainModel(data.data);
|
|
19361
|
+
})];
|
|
19362
|
+
});
|
|
19363
|
+
});
|
|
19364
|
+
};
|
|
19365
|
+
CustomDomainsFactory.create = function (_a) {
|
|
19366
|
+
return __awaiter(this, arguments, void 0, function (_b) {
|
|
19367
|
+
var domain = _b.domain;
|
|
19368
|
+
return __generator(this, function (_c) {
|
|
19369
|
+
return [2 /*return*/, createCustomDomain({ domain: domain }).then(function (data) {
|
|
19370
|
+
return new CustomDomainModel(data.data);
|
|
19371
|
+
})];
|
|
19372
|
+
});
|
|
19373
|
+
});
|
|
19374
|
+
};
|
|
19375
|
+
return CustomDomainsFactory;
|
|
19376
|
+
}());
|
|
19377
|
+
|
|
19222
19378
|
var EEmailLogType;
|
|
19223
19379
|
(function (EEmailLogType) {
|
|
19224
19380
|
EEmailLogType["submitted"] = "submitted";
|
|
@@ -19865,4 +20021,4 @@ var UsersFactory = /** @class */ (function () {
|
|
|
19865
20021
|
return UsersFactory;
|
|
19866
20022
|
}());
|
|
19867
20023
|
|
|
19868
|
-
export { AccountModel, AccountsFactory, ActionBarContainer, ActionBarContainerHandler, AssetManager, AutomationModel, AutomationsFactory, Avatar, BillingFactory, BrandWrapper, BrandsFactory, Button, ButtonMenu, CampaignModel, CampaignsFactory, Checkbox, Chip, CircularProgress, CodeInput, ColManager, ColorTextField, CommonFormModel, ContactModel, ContactsFactory, ContentSectionContainer, CountryDropdown, CustomerModel, DataTable, DataTableHead, DataTableRow, DateCalendar, DatePicker, DateTimeCalendar, DateTimePicker, Dialog, DialogActions, DialogHandler, DialogTitle, Divider, Drawer, DrawerHandler, DropMenu, Dropdown, EApiLanguages, EAssetManagerMatchType, ECampaignStatuses, EEMailSummaryStatuses, EEditorType, EEmailAttachementTypes, EEmailLogType, EEmailLogTypeParam, EEmailProviders, EEmailStatuses, EEmailSummaryEngagement, EEvents, EListAttributeType, EMethods, EOperatorTypes, EPageBranding, EPartialInfoPool, EPopupBranding, EPopupBrowserType, EPopupCloseButtonPosition, EPopupDeviceType, EPopupDisplayFrequency, EPopupPosition, EPopupTriggerType, EStorageType, ETaskType, ElementContains, Email, EmailAPIFactory, EmptyContent, EnhancedFormModel, FileUpload, FilterBar, FormModel, FormsFactory, FullBar, GenericWrapper, GenericWrapperContext, GroupedActions, Header, Icon, IconPill, InformationGroup, InlineTextEdit, LinearProgress, Link, ListCampaignModel, ListModel, ListPageModel, ListPopupModel, ListTemplateModel, ListsFactory, LoadingContainer, LocationTextField, Logo, MD5, MetricCard, Modal, ModalHandler, ModalHeading, Overlay, OverlayHandler, OverlayHeading, PageModel, PagesFactory, PhoneTextField, PopupModel, PopupsFactory, Radio, ResourceEdit, Search, SenderModel, SendersFactory, SideMenu, SideMenuContainer, SideMenuItem, SubNav, SummaryEnhancedFormModel, SuppressedEmailsFactory, SystemEmailsFactory, SystemEmailsModel, TagsFactory, TasksFactory, TemplateModel, TemplatesFactory, TextField, TimePicker, TimeSelector, Toggle, TopMenu, Typography, UserModel, UsersFactory, acceptListPolicy, addInterestsToContactsOfList, addPartialInformation, addSuppressedEmail, addToImpersonificationTree, amIImpersonating, amILoggedInService, archiveCampaign, areAllPropertiesEmpty, buildMUITheme, callApi, camelCase, camelToSnakeCase, cancelCampaign, capitalizeFirstLetter, cleanPostHogId, clearImpersonificationTree, clearStorage, copyToClipboard, createAccount, createBrand, createCampaign, createCampaignLogsExports, createCampaignsReportsExport, createContactsExport, createForm, createPage, createPopup, createSuppressedEmailExport, createTemplate, deepMergeObject, deleteAccount, deleteAnyAutomation, deleteAutomation, deleteCampaign, deleteCampaignsReportsExport, deleteContact, deleteForm, deleteList, deletePage, deletePartialInformation, deletePopup, deleteSender, deleteStorageItem, deleteSuppressedEmail, deleteTaskService, deleteTemplate, deleteUser, deleteWorkflow, descendingComparator, disableForm, disablePage, disablePopup, downloadCampaignLogExport, downloadCampaignsReportsExport, downloadContactsExport, downloadListLogExport, downloadSuppressedEmailExport, emptyAccountAddress, emptyAccountLimits, enableForm, enablePage, enablePopup, enrichBrand, enrichOrganization, enrichProfile, eventCondition, eventIdentify, eventLogout, fetchRetry, fetchRoute, findNestedProperty, formatNumber, getAccount, getAccountMetadata, getAccountReport, getAdjustedBillingCycle, getAllAutomationStats, getAutomation, getAutomationEmailContent, getAutomationExecutionsCount, getAutomationStats, getBeeTokenService, getBestLocalMatch, getBrand, getBrandService, getBrandUrl, getCalendarFormat, getCampaign, getCampaignLinks, getCampaignLinksReport, getCampaignLogs, getCampaignLogsExports, getCampaignReport, getCampaignRevisions, getCampaignsReportsExport, getComparator, getContactsExport, getCustomerProfile, getDate, getDomainFromEmail, getDomainsFromEmails, getDomainsService, getEmail, getEmailActivitySummary, getEmailReport, getEndOfDate, getForm, getHashQueryWithoutHistory, getIconSize, getList, getListLogs, getListReport, getNestedProperty, getPage, getPopup, getPropertyValue, getSender, getStartOfDate, getStorage, getSuppressedEmailExport, getTColor, getTaskService, getTemplate, getUnixTime, getUrlQueryParam, getUser, getUtmCookies, googlePlacesMapper, hasDecimal, impersonateService, initFieldValidation, initPostHog, isColorLight, isDomainValidService, isSimpleType, isValidEmail, isValidString, isValidUrl, lisTEmailTags, listAccounts, listAutomations, listCampaigns, listCampaignsReportsExports, listContacts, listDkimService, listEmailLogs, listForms, listList, listListAttributes, listListInterests, listPages, listPopups, listSenders, listSuppressedEmails, listSystemEmails, listTasksService, listTemplates, listUsers, listWorkflows, logOutService, loginService, miliToSecond, modelSet, modelToJson, originalBrand, patchForm, popImpersonificationTree, postMessage, publishForm, publishPage, publishPopup, reScheduleCampaign, removeEmptyProperties, removeInterestsFromContactsOfList, removeQueryParams, removeTrailingChar, renderCampaign, renderEmail, renderForm, renderPage, renderPopup, renderPublicHtmlForm, renderTemplate, requestSupportService, resendEmail, resendVerificationEmail, resumeCampaign, saveList, scheduleCampaign, searchCustomerProfiles, sendCampaignTest, setBrandHeadElements, setStorage, shareTemplate, splitArray, splitObject, stableSort, startPromisePool, suspendAccount, suspendCampaign, tagContact, tagsContactsOfList, trackEvent, truncateEmail, truncateText, uiKitConfig, unArchiveCampaign, unScheduleCampaign, unSuspendAccount, unshareTemplate, unsubscribeContact, untagContact, untagContactsOfList, updateAccount, updateAndClearUrlParams, updateAnyAutomation, updateAutomation, updateCampaign, updatePage, updatePopup, updateSystemEmails, updateTemplate, updateUser, updateWorkflow, validateColor, validateEmail, validateGenericInput, validateUrl, wait, whiteLabelBrand, whoAmi };
|
|
20024
|
+
export { AccountModel, AccountsFactory, ActionBarContainer, ActionBarContainerHandler, AssetManager, AutomationModel, AutomationsFactory, Avatar, BillingFactory, BrandWrapper, BrandsFactory, Button, ButtonMenu, CampaignModel, CampaignsFactory, Checkbox, Chip, CircularProgress, CodeInput, ColManager, ColorTextField, CommonFormModel, ContactModel, ContactsFactory, ContentSectionContainer, CountryDropdown, CustomDomainModel, CustomDomainsFactory, CustomerModel, DataTable, DataTableHead, DataTableRow, DateCalendar, DatePicker, DateTimeCalendar, DateTimePicker, Dialog, DialogActions, DialogHandler, DialogTitle, Divider, Drawer, DrawerHandler, DropMenu, Dropdown, EApiLanguages, EAssetManagerMatchType, ECampaignStatuses, ECustomDomainVerificationStatus, EEMailSummaryStatuses, EEditorType, EEmailAttachementTypes, EEmailLogType, EEmailLogTypeParam, EEmailProviders, EEmailStatuses, EEmailSummaryEngagement, EEvents, EListAttributeType, EMethods, EOperatorTypes, EPageBranding, EPartialInfoPool, EPopupBranding, EPopupBrowserType, EPopupCloseButtonPosition, EPopupDeviceType, EPopupDisplayFrequency, EPopupPosition, EPopupTriggerType, EStorageType, ETaskType, ElementContains, Email, EmailAPIFactory, EmptyContent, EnhancedFormModel, FileUpload, FilterBar, FormModel, FormsFactory, FullBar, GenericWrapper, GenericWrapperContext, GroupedActions, Header, Icon, IconPill, InformationGroup, InlineTextEdit, LinearProgress, Link, ListCampaignModel, ListModel, ListPageModel, ListPopupModel, ListTemplateModel, ListsFactory, LoadingContainer, LocationTextField, Logo, MD5, MetricCard, Modal, ModalHandler, ModalHeading, Overlay, OverlayHandler, OverlayHeading, PageModel, PagesFactory, PhoneTextField, PopupModel, PopupsFactory, Radio, ResourceEdit, Search, SenderModel, SendersFactory, SideMenu, SideMenuContainer, SideMenuItem, SubNav, SummaryEnhancedFormModel, SuppressedEmailsFactory, SystemEmailsFactory, SystemEmailsModel, TagsFactory, TasksFactory, TemplateModel, TemplatesFactory, TextField, TimePicker, TimeSelector, Toggle, TopMenu, Typography, UserModel, UsersFactory, acceptListPolicy, addInterestsToContactsOfList, addPartialInformation, addSuppressedEmail, addToImpersonificationTree, amIImpersonating, amILoggedInService, archiveCampaign, areAllPropertiesEmpty, buildMUITheme, callApi, camelCase, camelToSnakeCase, cancelCampaign, capitalizeFirstLetter, cleanPostHogId, clearImpersonificationTree, clearStorage, copyToClipboard, createAccount, createBrand, createCampaign, createCampaignLogsExports, createCampaignsReportsExport, createContactsExport, createCustomDomain, createForm, createPage, createPopup, createSuppressedEmailExport, createTemplate, deepMergeObject, deleteAccount, deleteAnyAutomation, deleteAutomation, deleteCampaign, deleteCampaignsReportsExport, deleteContact, deleteCustomDomain, deleteForm, deleteList, deletePage, deletePartialInformation, deletePopup, deleteSender, deleteStorageItem, deleteSuppressedEmail, deleteTaskService, deleteTemplate, deleteUser, deleteWorkflow, descendingComparator, disableForm, disablePage, disablePopup, downloadCampaignLogExport, downloadCampaignsReportsExport, downloadContactsExport, downloadListLogExport, downloadSuppressedEmailExport, emptyAccountAddress, emptyAccountLimits, enableForm, enablePage, enablePopup, enrichBrand, enrichOrganization, enrichProfile, eventCondition, eventIdentify, eventLogout, fetchRetry, fetchRoute, findNestedProperty, formatNumber, getAccount, getAccountMetadata, getAccountReport, getAdjustedBillingCycle, getAllAutomationStats, getAutomation, getAutomationEmailContent, getAutomationExecutionsCount, getAutomationStats, getBeeTokenService, getBestLocalMatch, getBrand, getBrandService, getBrandUrl, getCalendarFormat, getCampaign, getCampaignLinks, getCampaignLinksReport, getCampaignLogs, getCampaignLogsExports, getCampaignReport, getCampaignRevisions, getCampaignsReportsExport, getComparator, getContactsExport, getCustomDomain, getCustomerProfile, getDate, getDomainFromEmail, getDomainsFromEmails, getDomainsService, getEmail, getEmailActivitySummary, getEmailReport, getEndOfDate, getForm, getHashQueryWithoutHistory, getIconSize, getList, getListLogs, getListReport, getNestedProperty, getPage, getPopup, getPropertyValue, getSender, getStartOfDate, getStorage, getSuppressedEmailExport, getTColor, getTaskService, getTemplate, getUnixTime, getUrlQueryParam, getUser, getUtmCookies, googlePlacesMapper, hasDecimal, impersonateService, initFieldValidation, initPostHog, isColorLight, isDomainValidService, isSimpleType, isValidEmail, isValidString, isValidUrl, lisTEmailTags, listAccounts, listAutomations, listCampaigns, listCampaignsReportsExports, listContacts, listCustomDomains, listDkimService, listEmailLogs, listForms, listList, listListAttributes, listListInterests, listPages, listPopups, listSenders, listSuppressedEmails, listSystemEmails, listTasksService, listTemplates, listUsers, listWorkflows, logOutService, loginService, miliToSecond, modelSet, modelToJson, originalBrand, patchForm, popImpersonificationTree, postMessage, publishForm, publishPage, publishPopup, reScheduleCampaign, removeEmptyProperties, removeInterestsFromContactsOfList, removeQueryParams, removeTrailingChar, renderCampaign, renderEmail, renderForm, renderPage, renderPopup, renderPublicHtmlForm, renderTemplate, requestSupportService, resendEmail, resendVerificationEmail, resumeCampaign, saveList, scheduleCampaign, searchCustomerProfiles, sendCampaignTest, setBrandHeadElements, setStorage, shareTemplate, splitArray, splitObject, stableSort, startPromisePool, suspendAccount, suspendCampaign, tagContact, tagsContactsOfList, trackEvent, truncateEmail, truncateText, uiKitConfig, unArchiveCampaign, unScheduleCampaign, unSuspendAccount, unshareTemplate, unsubscribeContact, untagContact, untagContactsOfList, updateAccount, updateAndClearUrlParams, updateAnyAutomation, updateAutomation, updateCampaign, updatePage, updatePopup, updateSystemEmails, updateTemplate, updateUser, updateWorkflow, validateColor, validateEmail, validateGenericInput, validateUrl, verifyCustomDomain, wait, whiteLabelBrand, whoAmi };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { TDeleteApiResource } from "../../types";
|
|
2
|
+
import { ECustomDomainVerificationStatus, TCustomDomainModel, TCustomDomainVerificationPayload } from "./types";
|
|
3
|
+
export declare class CustomDomainModel {
|
|
4
|
+
id: string;
|
|
5
|
+
account_id: number;
|
|
6
|
+
domain: string;
|
|
7
|
+
verification_status: ECustomDomainVerificationStatus;
|
|
8
|
+
verified_on: number | null;
|
|
9
|
+
created_on: number;
|
|
10
|
+
updated_on: number;
|
|
11
|
+
dns_instructions: TCustomDomainModel["dns_instructions"];
|
|
12
|
+
constructor(params: TCustomDomainModel);
|
|
13
|
+
get isVerified(): boolean;
|
|
14
|
+
toJson(): TCustomDomainModel;
|
|
15
|
+
set<T extends keyof this>(property: T, value: this[T]): void;
|
|
16
|
+
verify(): Promise<{
|
|
17
|
+
domain: CustomDomainModel;
|
|
18
|
+
verification: TCustomDomainVerificationPayload;
|
|
19
|
+
}>;
|
|
20
|
+
delete(): Promise<TDeleteApiResource>;
|
|
21
|
+
}
|
|
22
|
+
export * from "./types";
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export declare enum ECustomDomainVerificationStatus {
|
|
2
|
+
pending = "pending",
|
|
3
|
+
verified = "verified",
|
|
4
|
+
failed = "failed"
|
|
5
|
+
}
|
|
6
|
+
export type TCustomDomainDnsCname = {
|
|
7
|
+
hostname: string;
|
|
8
|
+
point_to: string;
|
|
9
|
+
help: string;
|
|
10
|
+
};
|
|
11
|
+
export type TCustomDomainDnsInstructions = {
|
|
12
|
+
cname: TCustomDomainDnsCname;
|
|
13
|
+
extra_dns?: Array<{
|
|
14
|
+
hostname: string;
|
|
15
|
+
help: string;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
export type TCustomDomainModel = {
|
|
19
|
+
id: string;
|
|
20
|
+
account_id: number;
|
|
21
|
+
domain: string;
|
|
22
|
+
verification_status: ECustomDomainVerificationStatus;
|
|
23
|
+
verified_on: number | null;
|
|
24
|
+
created_on: number;
|
|
25
|
+
updated_on: number;
|
|
26
|
+
dns_instructions: TCustomDomainDnsInstructions;
|
|
27
|
+
};
|
|
28
|
+
export type TCustomDomainVerificationPayload = {
|
|
29
|
+
success: boolean;
|
|
30
|
+
message: string;
|
|
31
|
+
};
|
|
32
|
+
export type TCustomDomainVerifyResult = TCustomDomainModel & {
|
|
33
|
+
verification: TCustomDomainVerificationPayload;
|
|
34
|
+
};
|
|
@@ -20,6 +20,8 @@ export declare class ListPageModel {
|
|
|
20
20
|
form_id: string | null;
|
|
21
21
|
thumbnail_url: string;
|
|
22
22
|
published_url: string | null;
|
|
23
|
+
custom_domain_id: string | null;
|
|
24
|
+
custom_domain: string | null;
|
|
23
25
|
constructor(params: TPageModel);
|
|
24
26
|
toJson(): any;
|
|
25
27
|
set<T extends keyof this>(property: T, value: this[T]): void;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { TCustomDomainModel, TCustomDomainVerifyResult } from "../../models/customDomains/types";
|
|
2
|
+
import { TGenericListParams, TGenericListReturn, TGenericReturn } from "../../types";
|
|
3
|
+
import { TCreateApiResource, TDeleteApiResource, TUpdateApiResource } from "../../types/generic";
|
|
4
|
+
export declare function listCustomDomains({ ...options }: TGenericListParams & {
|
|
5
|
+
verificationStatus?: string;
|
|
6
|
+
}): Promise<TGenericListReturn<TCustomDomainModel>>;
|
|
7
|
+
export declare function createCustomDomain({ domain, }: {
|
|
8
|
+
domain: string;
|
|
9
|
+
}): Promise<TCreateApiResource<TCustomDomainModel>>;
|
|
10
|
+
export declare function getCustomDomain({ id }: {
|
|
11
|
+
id: string;
|
|
12
|
+
}): Promise<TGenericReturn<TCustomDomainModel>>;
|
|
13
|
+
export declare function deleteCustomDomain({ id }: {
|
|
14
|
+
id: string;
|
|
15
|
+
}): Promise<TDeleteApiResource>;
|
|
16
|
+
export declare function verifyCustomDomain({ id, }: {
|
|
17
|
+
id: string;
|
|
18
|
+
}): Promise<TUpdateApiResource<TCustomDomainVerifyResult>>;
|