@chaosinsight/postoffice-portalclient 1.16.1 → 1.16.3
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/extensions/organizations.d.ts +8 -2
- package/dist/extensions/organizations.js +12 -4
- package/dist/extensions/organizations.js.map +1 -1
- package/dist/extensions/scheduledTemplates.js.map +1 -1
- package/dist/extensions/users.d.ts +2 -0
- package/dist/extensions/users.js +3 -0
- package/dist/extensions/users.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/src/extensions/organizations.ts +14 -4
- package/src/extensions/scheduledTemplates.ts +3 -3
- package/src/extensions/users.ts +5 -0
- package/src/index.ts +1 -1
|
@@ -5,13 +5,14 @@ export default class Organizations extends Extension {
|
|
|
5
5
|
get(): IServiceCall<IOrganization[]>;
|
|
6
6
|
post(name: string, key: string): IServiceCall<IOrganization>;
|
|
7
7
|
put(organizationId: number, isReviewRequired: boolean, isVariantDealsEnabled: boolean, isDealMessagingPrioritized: boolean, isDealCustomerAnonymized: boolean, dealReplies: IDealReplies, dealFooter: string | null, dealVariantFooter: string | null, dealOutOfStockHeader: string | null, dealExpiredHeader: string | null, dealLiveFooter: string | null): IServiceCall<void>;
|
|
8
|
+
patch(organizationId: number, locationSignupToken: "refresh"): IServiceCall<void>;
|
|
8
9
|
contentGroupsGet(organizationId: number): IServiceCall<IPrivateContentGroup[]>;
|
|
9
10
|
contentGroupsPost(organizationId: number, name: string): IServiceCall<IPrivateContentGroup>;
|
|
10
11
|
filtersGet(organizationId: number): IServiceCall<IFilter[]>;
|
|
11
12
|
invitationsGet(ticketId: string): IServiceCall<IOrganizationInvitation>;
|
|
12
|
-
invitationsPost(organizationId: number, message: string, name: string, email: string): IServiceCall<void>;
|
|
13
|
+
invitationsPost(organizationId: number, message: string, name: string, email: string, type: InvitationType): IServiceCall<void>;
|
|
13
14
|
locationsGet(organizationId: number): IServiceCall<ILocationWithServices[]>;
|
|
14
|
-
locationsPost(organizationId: number, key: string, name: string, shareInsightsWithOrganization: boolean, timeZone: string, userDefinedId: string | null): IServiceCall<ILocationWithServices>;
|
|
15
|
+
locationsPost(organizationId: number, key: string, name: string, shareInsightsWithOrganization: boolean, timeZone: string, userDefinedId: string | null, ticket?: string): IServiceCall<ILocationWithServices>;
|
|
15
16
|
logosPost(organizationId: number, file: File): IServiceCall<IFile>;
|
|
16
17
|
permissionsGet(organizationId: number): IServiceCall<IOrganizationPermission>;
|
|
17
18
|
postsGet(organizationId: number): IServiceCall<IPost[]>;
|
|
@@ -32,6 +33,7 @@ export interface IOrganization {
|
|
|
32
33
|
Name: string;
|
|
33
34
|
Key: string;
|
|
34
35
|
LogoUrl: string;
|
|
36
|
+
LocationSignupToken: string;
|
|
35
37
|
IsReviewRequired: boolean;
|
|
36
38
|
IsNotificationsEnabled: boolean;
|
|
37
39
|
IsDealsEnabled: boolean;
|
|
@@ -74,6 +76,10 @@ export declare enum OrganizationRole {
|
|
|
74
76
|
observer = 2,
|
|
75
77
|
administrator = 4294967295
|
|
76
78
|
}
|
|
79
|
+
export declare enum InvitationType {
|
|
80
|
+
membership = 0,
|
|
81
|
+
membershipAndCreateLocation = 1
|
|
82
|
+
}
|
|
77
83
|
export interface IPostStatistics {
|
|
78
84
|
Impressions: number;
|
|
79
85
|
ImpressionsPaid: number;
|
|
@@ -10,6 +10,9 @@ export default class Organizations extends Extension {
|
|
|
10
10
|
put(organizationId, isReviewRequired, isVariantDealsEnabled, isDealMessagingPrioritized, isDealCustomerAnonymized, dealReplies, dealFooter, dealVariantFooter, dealOutOfStockHeader, dealExpiredHeader, dealLiveFooter) {
|
|
11
11
|
return this.call(organizationId.toString(10), { isReviewRequired, isVariantDealsEnabled, isDealMessagingPrioritized, isDealCustomerAnonymized, dealReplies, dealFooter, dealVariantFooter, dealOutOfStockHeader, dealExpiredHeader, dealLiveFooter }, HttpMethod.PutJson, SessionRequirement.authenticated);
|
|
12
12
|
}
|
|
13
|
+
patch(organizationId, locationSignupToken) {
|
|
14
|
+
return this.call(organizationId.toString(10), { locationSignupToken }, HttpMethod.PatchJson, SessionRequirement.authenticated);
|
|
15
|
+
}
|
|
13
16
|
contentGroupsGet(organizationId) {
|
|
14
17
|
return this.call(organizationId.toString(10) + "/ContentGroups", null, HttpMethod.Get, SessionRequirement.authenticated);
|
|
15
18
|
}
|
|
@@ -22,14 +25,14 @@ export default class Organizations extends Extension {
|
|
|
22
25
|
invitationsGet(ticketId) {
|
|
23
26
|
return this.call("Invitations", { ticketId }, HttpMethod.Get, SessionRequirement.none);
|
|
24
27
|
}
|
|
25
|
-
invitationsPost(organizationId, message, name, email) {
|
|
26
|
-
return this.call(organizationId.toString(10) + "/Invitations", { message, invitee: { name, email } }, HttpMethod.PostJson, SessionRequirement.authenticated);
|
|
28
|
+
invitationsPost(organizationId, message, name, email, type) {
|
|
29
|
+
return this.call(organizationId.toString(10) + "/Invitations", { message, invitee: { name, email }, type }, HttpMethod.PostJson, SessionRequirement.authenticated);
|
|
27
30
|
}
|
|
28
31
|
locationsGet(organizationId) {
|
|
29
32
|
return this.call(organizationId.toString(10) + "/Locations", null, HttpMethod.Get, SessionRequirement.authenticated);
|
|
30
33
|
}
|
|
31
|
-
locationsPost(organizationId, key, name, shareInsightsWithOrganization, timeZone, userDefinedId) {
|
|
32
|
-
return this.call(organizationId.toString(10) + "/Locations", { name, key, shareInsightsWithOrganization, timeZone, userDefinedId }, HttpMethod.PostJson, SessionRequirement.authenticated);
|
|
34
|
+
locationsPost(organizationId, key, name, shareInsightsWithOrganization, timeZone, userDefinedId, ticket) {
|
|
35
|
+
return this.call(organizationId.toString(10) + "/Locations", { name, key, shareInsightsWithOrganization, timeZone, userDefinedId, ticket }, HttpMethod.PostJson, SessionRequirement.authenticated);
|
|
33
36
|
}
|
|
34
37
|
logosPost(organizationId, file) {
|
|
35
38
|
return this.call(organizationId.toString(10) + "/Logos", { file }, HttpMethod.Post, SessionRequirement.authenticated);
|
|
@@ -80,6 +83,11 @@ export var OrganizationRole;
|
|
|
80
83
|
OrganizationRole[OrganizationRole["observer"] = 2] = "observer";
|
|
81
84
|
OrganizationRole[OrganizationRole["administrator"] = 4294967295] = "administrator";
|
|
82
85
|
})(OrganizationRole || (OrganizationRole = {}));
|
|
86
|
+
export var InvitationType;
|
|
87
|
+
(function (InvitationType) {
|
|
88
|
+
InvitationType[InvitationType["membership"] = 0] = "membership";
|
|
89
|
+
InvitationType[InvitationType["membershipAndCreateLocation"] = 1] = "membershipAndCreateLocation";
|
|
90
|
+
})(InvitationType || (InvitationType = {}));
|
|
83
91
|
export var ServiceType;
|
|
84
92
|
(function (ServiceType) {
|
|
85
93
|
ServiceType["any"] = "any";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"organizations.js","sourceRoot":"","sources":["../../src/extensions/organizations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,UAAU,EAAgB,kBAAkB,EAAC,MAAM,4BAA4B,CAAA;AAGlG,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,SAAS;IACzC,aAAa,GAAW,eAAe,CAAA;IAE1C,GAAG;QACT,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,UAAU,CAAC,GAAG,EAAE,kBAAkB,CAAC,aAAa,CAAC,CAAA;IAC/E,CAAC;IAEM,IAAI,CAAC,IAAY,EAAE,GAAW;QACpC,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,EAAC,IAAI,EAAE,GAAG,EAAC,EAAE,UAAU,CAAC,QAAQ,EAAE,kBAAkB,CAAC,aAAa,CAAC,CAAA;IAC3F,CAAC;IAEM,GAAG,CAAC,cAAsB,EAAE,gBAAyB,EAAE,qBAA8B,EAAE,0BAAmC,EAAE,wBAAiC,EAAE,WAAyB,EAAE,UAAyB,EAAE,iBAAgC,EAAE,oBAAmC,EAAE,iBAAgC,EAAE,cAA6B;QACjW,OAAO,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","sourceRoot":"","sources":["../../src/extensions/scheduledTemplates.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,UAAU,EAAgB,kBAAkB,EAAC,MAAM,4BAA4B,CAAA;AAGlG,MAAM,CAAC,OAAO,OAAO,kBAAmB,SAAQ,SAAS;IAC9C,aAAa,GAAW,oBAAoB,CAAA;IAE/C,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"scheduledTemplates.js","sourceRoot":"","sources":["../../src/extensions/scheduledTemplates.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,UAAU,EAAgB,kBAAkB,EAAC,MAAM,4BAA4B,CAAA;AAGlG,MAAM,CAAC,OAAO,OAAO,kBAAmB,SAAQ,SAAS;IAC9C,aAAa,GAAW,oBAAoB,CAAA;IAE/C,GAAG,CAAC,mBAA2B;QACrC,OAAO,IAAI,CAAC,IAAI,CAAC,mBAAmB,CAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,UAAU,CAAC,GAAG,EAAE,kBAAkB,CAAC,aAAa,CAAC,CAAA;IAC3G,CAAC;IAEM,IAAI,CAAC,EAAU;QACrB,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,EAAC,EAAE,EAAC,EAAE,UAAU,CAAC,QAAQ,EAAE,kBAAkB,CAAC,aAAa,CAAC,CAAA;IACpF,CAAC;IAEM,GAAG,CAAC,mBAA2B,EAAE,WAAmC,EAAE,OAAgB,EAAE,IAAoB,EAAE,WAAkB,EAAE,IAAiD,EAAE,OAAiB,EAAE,aAAuB,EAAE,eAAyB,EAAE,aAAuB,EAAE,yBAAsC,IAAI,EAAE,uBAAoC,IAAI;QAC/W,OAAO,IAAI,CAAC,IAAI,CAAC,mBAAmB,CAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAC,aAAa,EAAE,WAAW,EAAE,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,OAAO,EAAE,aAAa,EAAE,eAAe,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G,EAAE,kBAAkB,CAAC,aAAa,CAAC,CAAA;IACxH,CAAC;CACD;AAkBD,SAAS,CAAC,GAAG,CAAC,kBAAkB,EAAE,oBAAoB,CAAC,CAAA"}
|
|
@@ -6,6 +6,7 @@ export default class Users extends AuthenticationExtension {
|
|
|
6
6
|
put(name?: string, language?: string, consentToTermsOfUse?: boolean, consentToMarketing?: boolean, consentToNotifications?: boolean, uiVersion?: string): IServiceCall<void>;
|
|
7
7
|
delete(): IServiceCall<void>;
|
|
8
8
|
me(): IServiceCall<IPrivateUser>;
|
|
9
|
+
mePasswordsPut(username: string | null, newPassword: string | null, currentPassword: string | null): IServiceCall<void>;
|
|
9
10
|
}
|
|
10
11
|
export interface IPublicUser extends IUser {
|
|
11
12
|
CreatedOn: string;
|
|
@@ -21,6 +22,7 @@ export interface IPrivateUser extends IUser {
|
|
|
21
22
|
MarketingConsent: string | null;
|
|
22
23
|
NotificationConsent: string;
|
|
23
24
|
UiVersion: string | null;
|
|
25
|
+
HasPassword: boolean;
|
|
24
26
|
}
|
|
25
27
|
export interface IUser {
|
|
26
28
|
Id: string;
|
package/dist/extensions/users.js
CHANGED
|
@@ -17,6 +17,9 @@ export default class Users extends AuthenticationExtension {
|
|
|
17
17
|
me() {
|
|
18
18
|
return this.call("Me", null, HttpMethod.Get, SessionRequirement.authenticated);
|
|
19
19
|
}
|
|
20
|
+
mePasswordsPut(username, newPassword, currentPassword) {
|
|
21
|
+
return this.call("Me/Passwords", { username, newPassword, currentPassword }, HttpMethod.PutJson, SessionRequirement.authenticated);
|
|
22
|
+
}
|
|
20
23
|
}
|
|
21
24
|
AuthenticationExtension.add(Users, "users");
|
|
22
25
|
//# sourceMappingURL=users.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"users.js","sourceRoot":"","sources":["../../src/extensions/users.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,uBAAuB,EAAE,UAAU,EAA0B,kBAAkB,EAAC,MAAM,4BAA4B,CAAA;AA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AA;IAC/E,CAAC;IAEM,cAAc,CAAC,QAAuB,EAAE,WAA0B,EAAE,eAA8B;QACxG,OAAO,IAAI,CAAC,IAAI,CAAC,cAAc,EAAE,EAAC,QAAQ,EAAE,WAAW,EAAE,eAAe,EAAC,EAAE,UAAU,CAAC,OAAO,EAAE,kBAAkB,CAAC,aAAa,CAAC,CAAA;IACjI,CAAC;CACD;AA0BD,uBAAuB,CAAC,GAAG,CAAC,KAAK,EAAE,OAAO,CAAC,CAAA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ export { default as PostOfficeErrorCode } from "./postOfficeErrorCode";
|
|
|
19
19
|
export { DealState } from "./extensions/deals";
|
|
20
20
|
export { FilterType } from "./extensions/filters";
|
|
21
21
|
export { PostError, PostType } from "./extensions/posts";
|
|
22
|
-
export { OrganizationRole, ServiceType } from "./extensions/organizations";
|
|
22
|
+
export { InvitationType, OrganizationRole, ServiceType } from "./extensions/organizations";
|
|
23
23
|
export { ServiceConnectionType } from "./extensions/serviceConnections";
|
|
24
24
|
export { FileStatus } from "./iFile";
|
|
25
25
|
export type { IContentGroup, IPrivateContentGroup, } from "./extensions/contentGroups";
|
package/dist/index.js
CHANGED
|
@@ -19,7 +19,7 @@ export { default as PostOfficeErrorCode } from "./postOfficeErrorCode";
|
|
|
19
19
|
export { DealState } from "./extensions/deals";
|
|
20
20
|
export { FilterType } from "./extensions/filters";
|
|
21
21
|
export { PostError, PostType } from "./extensions/posts";
|
|
22
|
-
export { OrganizationRole, ServiceType } from "./extensions/organizations";
|
|
22
|
+
export { InvitationType, OrganizationRole, ServiceType } from "./extensions/organizations";
|
|
23
23
|
export { ServiceConnectionType } from "./extensions/serviceConnections";
|
|
24
24
|
export { FileStatus } from "./iFile";
|
|
25
25
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA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AAC/B,OAAO,kCAAkC,CAAA;AACzC,OAAO,oBAAoB,CAAA;AAE3B,OAAO,EAAC,OAAO,IAAI,mBAAmB,EAAC,MAAM,uBAAuB,CAAA;AAEpE,OAAO,EAAC,SAAS,EAAC,MAAM,oBAAoB,CAAA;AAC5C,OAAO,EAAC,UAAU,EAAC,MAAM,sBAAsB,CAAA;AAC/C,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAC,MAAM,oBAAoB,CAAA;AACtD,OAAO,EAAC,cAAc,EAAC,gBAAgB,EAAE,WAAW,EAAC,MAAM,4BAA4B,CAAA;AACvF,OAAO,EAAC,qBAAqB,EAAC,MAAM,iCAAiC,CAAA;AACrE,OAAO,EAAC,UAAU,EAAC,MAAM,SAAS,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chaosinsight/postoffice-portalclient",
|
|
3
|
-
"version": "1.16.
|
|
3
|
+
"version": "1.16.3",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "./src/index.ts",
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
"url": "https://twitter.com/JacobRichardt"
|
|
21
21
|
},
|
|
22
22
|
"peerDependencies": {
|
|
23
|
-
"@chaosinsight/portalclient": "^3.11.
|
|
23
|
+
"@chaosinsight/portalclient": "^3.11.5"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@chaosinsight/portalclient": "3.11.
|
|
26
|
+
"@chaosinsight/portalclient": "3.11.5",
|
|
27
27
|
"tslint": "6.1.3",
|
|
28
28
|
"typescript": "4.6.4"
|
|
29
29
|
}
|
|
@@ -16,6 +16,10 @@ export default class Organizations extends Extension {
|
|
|
16
16
|
return this.call(organizationId.toString(10), {isReviewRequired, isVariantDealsEnabled, isDealMessagingPrioritized, isDealCustomerAnonymized, dealReplies, dealFooter, dealVariantFooter, dealOutOfStockHeader, dealExpiredHeader, dealLiveFooter}, HttpMethod.PutJson, SessionRequirement.authenticated)
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
+
public patch(organizationId: number, locationSignupToken: "refresh"): IServiceCall<void> {
|
|
20
|
+
return this.call(organizationId.toString(10), {locationSignupToken}, HttpMethod.PatchJson, SessionRequirement.authenticated)
|
|
21
|
+
}
|
|
22
|
+
|
|
19
23
|
public contentGroupsGet(organizationId: number): IServiceCall<IPrivateContentGroup[]> {
|
|
20
24
|
return this.call(organizationId.toString(10) + "/ContentGroups", null, HttpMethod.Get, SessionRequirement.authenticated)
|
|
21
25
|
}
|
|
@@ -32,16 +36,16 @@ export default class Organizations extends Extension {
|
|
|
32
36
|
return this.call("Invitations", {ticketId}, HttpMethod.Get, SessionRequirement.none)
|
|
33
37
|
}
|
|
34
38
|
|
|
35
|
-
public invitationsPost(organizationId: number, message: string, name: string, email: string): IServiceCall<void> {
|
|
36
|
-
return this.call(organizationId.toString(10) + "/Invitations", {message, invitee: {name, email}}, HttpMethod.PostJson, SessionRequirement.authenticated)
|
|
39
|
+
public invitationsPost(organizationId: number, message: string, name: string, email: string, type: InvitationType): IServiceCall<void> {
|
|
40
|
+
return this.call(organizationId.toString(10) + "/Invitations", {message, invitee: {name, email}, type}, HttpMethod.PostJson, SessionRequirement.authenticated)
|
|
37
41
|
}
|
|
38
42
|
|
|
39
43
|
public locationsGet(organizationId: number): IServiceCall<ILocationWithServices[]> {
|
|
40
44
|
return this.call(organizationId.toString(10) + "/Locations", null, HttpMethod.Get, SessionRequirement.authenticated)
|
|
41
45
|
}
|
|
42
46
|
|
|
43
|
-
public locationsPost(organizationId: number, key: string, name: string, shareInsightsWithOrganization: boolean, timeZone: string, userDefinedId: string | null): IServiceCall<ILocationWithServices> {
|
|
44
|
-
return this.call(organizationId.toString(10) + "/Locations", {name, key, shareInsightsWithOrganization, timeZone, userDefinedId}, HttpMethod.PostJson, SessionRequirement.authenticated)
|
|
47
|
+
public locationsPost(organizationId: number, key: string, name: string, shareInsightsWithOrganization: boolean, timeZone: string, userDefinedId: string | null, ticket?: string): IServiceCall<ILocationWithServices> {
|
|
48
|
+
return this.call(organizationId.toString(10) + "/Locations", {name, key, shareInsightsWithOrganization, timeZone, userDefinedId, ticket}, HttpMethod.PostJson, SessionRequirement.authenticated)
|
|
45
49
|
}
|
|
46
50
|
|
|
47
51
|
public logosPost(organizationId: number, file: File): IServiceCall<IFile> {
|
|
@@ -106,6 +110,7 @@ export interface IOrganization {
|
|
|
106
110
|
Name: string
|
|
107
111
|
Key: string
|
|
108
112
|
LogoUrl: string
|
|
113
|
+
LocationSignupToken: string
|
|
109
114
|
|
|
110
115
|
IsReviewRequired: boolean
|
|
111
116
|
IsNotificationsEnabled: boolean
|
|
@@ -155,6 +160,11 @@ export enum OrganizationRole {
|
|
|
155
160
|
administrator = 4294967295
|
|
156
161
|
}
|
|
157
162
|
|
|
163
|
+
export enum InvitationType {
|
|
164
|
+
membership,
|
|
165
|
+
membershipAndCreateLocation
|
|
166
|
+
}
|
|
167
|
+
|
|
158
168
|
export interface IPostStatistics {
|
|
159
169
|
Impressions: number
|
|
160
170
|
ImpressionsPaid: number
|
|
@@ -4,11 +4,11 @@ import type {IDatedDeal, IDatedPostData, IFile, IPost, IPostStatistics, IProduct
|
|
|
4
4
|
export default class ScheduledTemplates extends Extension {
|
|
5
5
|
protected extensionName: string = "ScheduledTemplates"
|
|
6
6
|
|
|
7
|
-
public get(scheduledTemplateId
|
|
7
|
+
public get(scheduledTemplateId: number): IServiceCall<IScheduledTemplate> {
|
|
8
8
|
return this.call(scheduledTemplateId.toString(10), null, HttpMethod.Get, SessionRequirement.authenticated)
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
public post(id
|
|
11
|
+
public post(id: number): IServiceCall<IScheduledTemplate> {
|
|
12
12
|
return this.call(null, {id}, HttpMethod.PostJson, SessionRequirement.authenticated)
|
|
13
13
|
}
|
|
14
14
|
|
|
@@ -28,7 +28,7 @@ export default class ScheduledTemplates extends Extension {
|
|
|
28
28
|
return this.call(templateId.toString(10) + "/Files/" + fileId.toString(10), {isDummy}, HttpMethod.PutJson, SessionRequirement.authenticated)
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
-
public filesDelete(scheduledTemplatesId
|
|
31
|
+
public filesDelete(scheduledTemplatesId: number, fileId: number): IServiceCall<void> {
|
|
32
32
|
return this.call(scheduledTemplatesId.toString(10) + "/Files/" + fileId.toString(10), null, HttpMethod.Delete, SessionRequirement.authenticated)
|
|
33
33
|
}
|
|
34
34
|
|
package/src/extensions/users.ts
CHANGED
|
@@ -23,6 +23,10 @@ export default class Users extends AuthenticationExtension {
|
|
|
23
23
|
public me(): IServiceCall<IPrivateUser> {
|
|
24
24
|
return this.call("Me", null, HttpMethod.Get, SessionRequirement.authenticated)
|
|
25
25
|
}
|
|
26
|
+
|
|
27
|
+
public mePasswordsPut(username: string | null, newPassword: string | null, currentPassword: string | null): IServiceCall<void> {
|
|
28
|
+
return this.call("Me/Passwords", {username, newPassword, currentPassword}, HttpMethod.PutJson, SessionRequirement.authenticated)
|
|
29
|
+
}
|
|
26
30
|
}
|
|
27
31
|
|
|
28
32
|
export interface IPublicUser extends IUser {
|
|
@@ -40,6 +44,7 @@ export interface IPrivateUser extends IUser {
|
|
|
40
44
|
MarketingConsent: string | null
|
|
41
45
|
NotificationConsent: string
|
|
42
46
|
UiVersion: string | null
|
|
47
|
+
HasPassword: boolean
|
|
43
48
|
}
|
|
44
49
|
|
|
45
50
|
export interface IUser {
|
package/src/index.ts
CHANGED
|
@@ -21,7 +21,7 @@ export {default as PostOfficeErrorCode} from "./postOfficeErrorCode"
|
|
|
21
21
|
export {DealState} from "./extensions/deals"
|
|
22
22
|
export {FilterType} from "./extensions/filters"
|
|
23
23
|
export {PostError, PostType} from "./extensions/posts"
|
|
24
|
-
export {OrganizationRole, ServiceType} from "./extensions/organizations"
|
|
24
|
+
export {InvitationType,OrganizationRole, ServiceType} from "./extensions/organizations"
|
|
25
25
|
export {ServiceConnectionType} from "./extensions/serviceConnections"
|
|
26
26
|
export {FileStatus} from "./iFile"
|
|
27
27
|
|