cidaas-javascript-sdk 3.1.2 → 3.1.4
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/CHANGELOG.md +2 -2
- package/README.md +0 -1
- package/dist/authentication/index.d.ts +55 -0
- package/{src/main/authentication/index.ts → dist/authentication/index.js} +127 -88
- package/dist/index.d.ts +3 -0
- package/dist/index.js +7 -0
- package/dist/web-auth/ConsentService.d.ts +59 -0
- package/dist/web-auth/ConsentService.js +73 -0
- package/dist/web-auth/Entities.d.ts +533 -0
- package/dist/web-auth/Entities.js +78 -0
- package/dist/web-auth/Helper.d.ts +24 -0
- package/dist/web-auth/Helper.js +89 -0
- package/dist/web-auth/LoginService.d.ts +103 -0
- package/dist/web-auth/LoginService.js +248 -0
- package/dist/web-auth/TokenService.d.ts +48 -0
- package/dist/web-auth/TokenService.js +160 -0
- package/dist/web-auth/UserService.d.ts +143 -0
- package/dist/web-auth/UserService.js +311 -0
- package/dist/web-auth/VerificationService.d.ts +125 -0
- package/dist/web-auth/VerificationService.js +251 -0
- package/dist/web-auth/WebAuth.d.ts +882 -0
- package/dist/web-auth/WebAuth.js +1570 -0
- package/package.json +7 -8
- package/src/main/global.d.ts +0 -10
- package/src/main/index.ts +0 -6
- package/src/main/web-auth/ConsentService.ts +0 -76
- package/src/main/web-auth/Entities.ts +0 -610
- package/src/main/web-auth/Helper.ts +0 -75
- package/src/main/web-auth/LoginService.ts +0 -249
- package/src/main/web-auth/TokenService.ts +0 -106
- package/src/main/web-auth/UserService.ts +0 -297
- package/src/main/web-auth/VerificationService.ts +0 -247
- package/src/main/web-auth/WebAuth.ts +0 -1516
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
## [3.1.
|
|
1
|
+
## [3.1.4](https://gitlab.widas.de/cidaas-public-devkits/cidaas-public-sdks/cidaas-javascript-sdk/compare/v3.1.3...v3.1.4) (2023-09-06)
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
### Bug Fixes
|
|
5
5
|
|
|
6
|
-
*
|
|
6
|
+
* update ci ([6bb80e0](https://gitlab.widas.de/cidaas-public-devkits/cidaas-public-sdks/cidaas-javascript-sdk/commit/6bb80e01aed3cd92a18303d0bf4ea74d29e8d9f6))
|
package/README.md
CHANGED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { UserManager, UserManagerSettings } from "oidc-client-ts";
|
|
2
|
+
export declare class Authentication {
|
|
3
|
+
webAuthSettings: UserManagerSettings;
|
|
4
|
+
userManager: UserManager;
|
|
5
|
+
constructor(webAuthSettings: UserManagerSettings, userManager: UserManager);
|
|
6
|
+
/**
|
|
7
|
+
* redirect sign in
|
|
8
|
+
* @param view_type
|
|
9
|
+
*/
|
|
10
|
+
redirectSignIn(view_type: string): void;
|
|
11
|
+
/**
|
|
12
|
+
* redirect sign in callback
|
|
13
|
+
* @returns
|
|
14
|
+
*/
|
|
15
|
+
redirectSignInCallback(): Promise<unknown>;
|
|
16
|
+
/**
|
|
17
|
+
* redirect sign out
|
|
18
|
+
* @returns
|
|
19
|
+
*/
|
|
20
|
+
redirectSignOut(): Promise<unknown>;
|
|
21
|
+
/**
|
|
22
|
+
* redirect sign out callback
|
|
23
|
+
* @returns
|
|
24
|
+
*/
|
|
25
|
+
redirectSignOutCallback(): Promise<unknown>;
|
|
26
|
+
/**
|
|
27
|
+
* pop up sign in
|
|
28
|
+
*/
|
|
29
|
+
popupSignIn(): void;
|
|
30
|
+
/**
|
|
31
|
+
* pop up sign in callback
|
|
32
|
+
*/
|
|
33
|
+
popupSignInCallback(): void;
|
|
34
|
+
/**
|
|
35
|
+
* pop up sign out
|
|
36
|
+
*/
|
|
37
|
+
popupSignOut(): void;
|
|
38
|
+
/**
|
|
39
|
+
* silent sign in
|
|
40
|
+
*/
|
|
41
|
+
silentSignIn(): void;
|
|
42
|
+
/**
|
|
43
|
+
* silent sign in callback
|
|
44
|
+
*/
|
|
45
|
+
silentSignInCallback(): void;
|
|
46
|
+
/**
|
|
47
|
+
* silent sign in callback v2
|
|
48
|
+
* @returns
|
|
49
|
+
*/
|
|
50
|
+
silentSignInCallbackV2(): Promise<unknown>;
|
|
51
|
+
/**
|
|
52
|
+
* silent sign out callback
|
|
53
|
+
*/
|
|
54
|
+
popupSignOutCallback(): void;
|
|
55
|
+
}
|
|
@@ -1,14 +1,16 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
exports.__esModule = true;
|
|
3
|
+
exports.Authentication = void 0;
|
|
4
|
+
var Authentication = /** @class */ (function () {
|
|
5
|
+
function Authentication(webAuthSettings, userManager) {
|
|
6
|
+
this.webAuthSettings = webAuthSettings;
|
|
7
|
+
this.userManager = userManager;
|
|
8
|
+
}
|
|
7
9
|
/**
|
|
8
10
|
* redirect sign in
|
|
9
|
-
* @param view_type
|
|
11
|
+
* @param view_type
|
|
10
12
|
*/
|
|
11
|
-
redirectSignIn(view_type
|
|
13
|
+
Authentication.prototype.redirectSignIn = function (view_type) {
|
|
12
14
|
try {
|
|
13
15
|
if (this.userManager) {
|
|
14
16
|
if (this.webAuthSettings) {
|
|
@@ -28,196 +30,233 @@ export class Authentication {
|
|
|
28
30
|
}).then(function () {
|
|
29
31
|
console.log("Redirect logged in using cidaas sdk");
|
|
30
32
|
});
|
|
31
|
-
}
|
|
33
|
+
}
|
|
34
|
+
else {
|
|
32
35
|
throw "user manager is null";
|
|
33
36
|
}
|
|
34
|
-
}
|
|
37
|
+
}
|
|
38
|
+
catch (ex) {
|
|
35
39
|
console.log("user manager instance is empty : " + ex);
|
|
36
40
|
}
|
|
37
41
|
};
|
|
38
|
-
|
|
42
|
+
;
|
|
39
43
|
/**
|
|
40
44
|
* redirect sign in callback
|
|
41
|
-
* @returns
|
|
45
|
+
* @returns
|
|
42
46
|
*/
|
|
43
|
-
redirectSignInCallback() {
|
|
44
|
-
|
|
47
|
+
Authentication.prototype.redirectSignInCallback = function () {
|
|
48
|
+
var _this = this;
|
|
49
|
+
return new Promise(function (resolve, reject) {
|
|
45
50
|
try {
|
|
46
|
-
if (
|
|
47
|
-
|
|
48
|
-
.then(function (user
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
}
|
|
51
|
+
if (_this.userManager) {
|
|
52
|
+
_this.userManager.signinRedirectCallback()
|
|
53
|
+
.then(function (user) {
|
|
54
|
+
if (user) {
|
|
55
|
+
resolve(user);
|
|
56
|
+
return;
|
|
57
|
+
}
|
|
58
|
+
resolve(undefined);
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
else {
|
|
56
62
|
throw "user manager is null";
|
|
57
63
|
}
|
|
58
|
-
}
|
|
64
|
+
}
|
|
65
|
+
catch (ex) {
|
|
59
66
|
reject(ex);
|
|
60
67
|
}
|
|
61
68
|
});
|
|
62
|
-
}
|
|
63
|
-
|
|
69
|
+
};
|
|
64
70
|
/**
|
|
65
71
|
* redirect sign out
|
|
66
|
-
* @returns
|
|
72
|
+
* @returns
|
|
67
73
|
*/
|
|
68
|
-
redirectSignOut() {
|
|
69
|
-
|
|
74
|
+
Authentication.prototype.redirectSignOut = function () {
|
|
75
|
+
var _this = this;
|
|
76
|
+
return new Promise(function (resolve, reject) {
|
|
70
77
|
try {
|
|
71
|
-
if (
|
|
72
|
-
|
|
73
|
-
state:
|
|
74
|
-
}).then(function (resp
|
|
78
|
+
if (_this.userManager && _this.webAuthSettings) {
|
|
79
|
+
_this.userManager.signoutRedirect({
|
|
80
|
+
state: _this.webAuthSettings
|
|
81
|
+
}).then(function (resp) {
|
|
75
82
|
console.log('signed out', resp);
|
|
76
|
-
window.authentication.redirectSignOutCallback().then(function (resp
|
|
83
|
+
window.authentication.redirectSignOutCallback().then(function (resp) {
|
|
77
84
|
resolve(resp);
|
|
78
85
|
});
|
|
79
86
|
});
|
|
80
|
-
}
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
81
89
|
throw "user manager or settings is null";
|
|
82
90
|
}
|
|
83
|
-
}
|
|
91
|
+
}
|
|
92
|
+
catch (ex) {
|
|
84
93
|
reject(ex);
|
|
85
94
|
}
|
|
86
95
|
});
|
|
87
96
|
};
|
|
88
|
-
|
|
97
|
+
;
|
|
89
98
|
/**
|
|
90
99
|
* redirect sign out callback
|
|
91
|
-
* @returns
|
|
100
|
+
* @returns
|
|
92
101
|
*/
|
|
93
|
-
redirectSignOutCallback() {
|
|
94
|
-
|
|
102
|
+
Authentication.prototype.redirectSignOutCallback = function () {
|
|
103
|
+
var _this = this;
|
|
104
|
+
return new Promise(function (resolve, reject) {
|
|
95
105
|
try {
|
|
96
|
-
if (
|
|
97
|
-
|
|
106
|
+
if (_this.userManager) {
|
|
107
|
+
_this.userManager.signoutRedirectCallback().then(function (resp) {
|
|
98
108
|
console.log("Signed out");
|
|
99
109
|
resolve(resp);
|
|
100
110
|
});
|
|
101
|
-
}
|
|
111
|
+
}
|
|
112
|
+
else {
|
|
102
113
|
resolve(undefined);
|
|
103
114
|
throw "user manager is null";
|
|
104
115
|
}
|
|
105
|
-
}
|
|
116
|
+
}
|
|
117
|
+
catch (ex) {
|
|
106
118
|
reject(ex);
|
|
107
119
|
}
|
|
108
120
|
});
|
|
109
121
|
};
|
|
110
|
-
|
|
122
|
+
;
|
|
111
123
|
/**
|
|
112
124
|
* pop up sign in
|
|
113
125
|
*/
|
|
114
|
-
popupSignIn() {
|
|
126
|
+
Authentication.prototype.popupSignIn = function () {
|
|
115
127
|
try {
|
|
116
128
|
if (this.userManager && this.webAuthSettings) {
|
|
117
129
|
this.userManager.signinPopup().then(function () {
|
|
118
130
|
console.log("signed in");
|
|
119
131
|
});
|
|
120
|
-
}
|
|
132
|
+
}
|
|
133
|
+
else {
|
|
121
134
|
throw "user manager or settings is null";
|
|
122
135
|
}
|
|
123
|
-
}
|
|
136
|
+
}
|
|
137
|
+
catch (ex) {
|
|
138
|
+
console.error(ex);
|
|
139
|
+
}
|
|
124
140
|
};
|
|
125
|
-
|
|
141
|
+
;
|
|
126
142
|
/**
|
|
127
143
|
* pop up sign in callback
|
|
128
144
|
*/
|
|
129
|
-
popupSignInCallback() {
|
|
145
|
+
Authentication.prototype.popupSignInCallback = function () {
|
|
130
146
|
try {
|
|
131
147
|
if (this.userManager) {
|
|
132
148
|
this.userManager.signinPopupCallback();
|
|
133
149
|
}
|
|
134
|
-
}
|
|
150
|
+
}
|
|
151
|
+
catch (ex) {
|
|
152
|
+
console.error(ex);
|
|
153
|
+
}
|
|
135
154
|
};
|
|
136
|
-
|
|
155
|
+
;
|
|
137
156
|
/**
|
|
138
157
|
* pop up sign out
|
|
139
158
|
*/
|
|
140
|
-
popupSignOut() {
|
|
159
|
+
Authentication.prototype.popupSignOut = function () {
|
|
141
160
|
try {
|
|
142
161
|
if (this.userManager && this.webAuthSettings) {
|
|
143
162
|
this.userManager.signoutPopup({
|
|
144
163
|
state: this.webAuthSettings
|
|
145
|
-
}).then(function (resp
|
|
164
|
+
}).then(function (resp) {
|
|
146
165
|
console.log('signed out', resp);
|
|
147
166
|
});
|
|
148
|
-
}
|
|
167
|
+
}
|
|
168
|
+
else {
|
|
149
169
|
throw "user manager or settings is null";
|
|
150
170
|
}
|
|
151
|
-
}
|
|
152
|
-
|
|
171
|
+
}
|
|
172
|
+
catch (ex) {
|
|
173
|
+
console.error(ex);
|
|
174
|
+
}
|
|
153
175
|
};
|
|
154
|
-
|
|
176
|
+
;
|
|
155
177
|
/**
|
|
156
178
|
* silent sign in
|
|
157
179
|
*/
|
|
158
|
-
silentSignIn() {
|
|
180
|
+
Authentication.prototype.silentSignIn = function () {
|
|
159
181
|
try {
|
|
160
182
|
if (this.userManager && this.webAuthSettings) {
|
|
161
183
|
this.userManager.signinSilent({
|
|
162
184
|
state: this.webAuthSettings
|
|
163
|
-
}).then(function (user
|
|
185
|
+
}).then(function (user) {
|
|
164
186
|
console.log("signed in : " + user.access_token);
|
|
165
187
|
});
|
|
166
|
-
}
|
|
188
|
+
}
|
|
189
|
+
else {
|
|
167
190
|
throw "user manager is null";
|
|
168
191
|
}
|
|
169
|
-
}
|
|
192
|
+
}
|
|
193
|
+
catch (ex) {
|
|
194
|
+
console.error(ex);
|
|
195
|
+
}
|
|
170
196
|
};
|
|
171
|
-
|
|
197
|
+
;
|
|
172
198
|
/**
|
|
173
199
|
* silent sign in callback
|
|
174
200
|
*/
|
|
175
|
-
silentSignInCallback() {
|
|
201
|
+
Authentication.prototype.silentSignInCallback = function () {
|
|
176
202
|
try {
|
|
177
203
|
if (this.userManager) {
|
|
178
204
|
this.userManager.signinSilentCallback();
|
|
179
|
-
}
|
|
205
|
+
}
|
|
206
|
+
else {
|
|
180
207
|
throw "user manager is null";
|
|
181
208
|
}
|
|
182
|
-
}
|
|
209
|
+
}
|
|
210
|
+
catch (ex) {
|
|
211
|
+
console.error(ex);
|
|
212
|
+
}
|
|
183
213
|
};
|
|
184
|
-
|
|
214
|
+
;
|
|
185
215
|
/**
|
|
186
216
|
* silent sign in callback v2
|
|
187
|
-
* @returns
|
|
217
|
+
* @returns
|
|
188
218
|
*/
|
|
189
|
-
silentSignInCallbackV2() {
|
|
190
|
-
|
|
219
|
+
Authentication.prototype.silentSignInCallbackV2 = function () {
|
|
220
|
+
var _this = this;
|
|
221
|
+
return new Promise(function (resolve, reject) {
|
|
191
222
|
try {
|
|
192
|
-
if (
|
|
193
|
-
|
|
194
|
-
.then(function (user
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
}
|
|
223
|
+
if (_this.userManager) {
|
|
224
|
+
_this.userManager.signinSilentCallback(_this.webAuthSettings.silent_redirect_uri)
|
|
225
|
+
.then(function (user) {
|
|
226
|
+
if (user) {
|
|
227
|
+
resolve(user);
|
|
228
|
+
return;
|
|
229
|
+
}
|
|
230
|
+
resolve(undefined);
|
|
231
|
+
});
|
|
232
|
+
}
|
|
233
|
+
else {
|
|
202
234
|
throw "user manager is null";
|
|
203
235
|
}
|
|
204
|
-
}
|
|
236
|
+
}
|
|
237
|
+
catch (ex) {
|
|
205
238
|
reject(ex);
|
|
206
239
|
}
|
|
207
240
|
});
|
|
208
|
-
|
|
209
241
|
};
|
|
210
|
-
|
|
242
|
+
;
|
|
211
243
|
/**
|
|
212
244
|
* silent sign out callback
|
|
213
245
|
*/
|
|
214
|
-
popupSignOutCallback() {
|
|
246
|
+
Authentication.prototype.popupSignOutCallback = function () {
|
|
215
247
|
try {
|
|
216
248
|
if (this.userManager) {
|
|
217
249
|
this.userManager.signoutPopupCallback(this.webAuthSettings.post_logout_redirect_uri, true);
|
|
218
|
-
}
|
|
250
|
+
}
|
|
251
|
+
else {
|
|
219
252
|
throw "user manager is null";
|
|
220
253
|
}
|
|
221
|
-
}
|
|
254
|
+
}
|
|
255
|
+
catch (ex) {
|
|
256
|
+
console.error(ex);
|
|
257
|
+
}
|
|
222
258
|
};
|
|
223
|
-
|
|
259
|
+
;
|
|
260
|
+
return Authentication;
|
|
261
|
+
}());
|
|
262
|
+
exports.Authentication = Authentication;
|
package/dist/index.d.ts
ADDED
package/dist/index.js
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
exports.__esModule = true;
|
|
3
|
+
exports.Authentication = exports.WebAuth = void 0;
|
|
4
|
+
var authentication_1 = require("./authentication");
|
|
5
|
+
exports.Authentication = authentication_1.Authentication;
|
|
6
|
+
var WebAuth_1 = require("./web-auth/WebAuth");
|
|
7
|
+
exports.WebAuth = WebAuth_1.WebAuth;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { IConsentAcceptEntity } from "./Entities";
|
|
2
|
+
export declare namespace ConsentService {
|
|
3
|
+
/**
|
|
4
|
+
* get user consent details
|
|
5
|
+
* @param options
|
|
6
|
+
* @returns
|
|
7
|
+
*/
|
|
8
|
+
function getConsentDetailsV2(options: {
|
|
9
|
+
consent_id: string;
|
|
10
|
+
consent_version_id: string;
|
|
11
|
+
sub: string;
|
|
12
|
+
}): Promise<unknown>;
|
|
13
|
+
/**
|
|
14
|
+
* accept constn v2
|
|
15
|
+
* @param options
|
|
16
|
+
* @returns
|
|
17
|
+
*/
|
|
18
|
+
function acceptConsentV2(options: IConsentAcceptEntity): Promise<unknown>;
|
|
19
|
+
/**
|
|
20
|
+
* get scope consent version details
|
|
21
|
+
* @param options
|
|
22
|
+
* @returns
|
|
23
|
+
*/
|
|
24
|
+
function getScopeConsentVersionDetailsV2(options: {
|
|
25
|
+
scopeid: string;
|
|
26
|
+
locale: string;
|
|
27
|
+
access_token: string;
|
|
28
|
+
}): Promise<unknown>;
|
|
29
|
+
/**
|
|
30
|
+
* accept scope Consent
|
|
31
|
+
* @param options
|
|
32
|
+
* @returns
|
|
33
|
+
*/
|
|
34
|
+
function acceptScopeConsent(options: {
|
|
35
|
+
client_id: string;
|
|
36
|
+
sub: string;
|
|
37
|
+
scopes: string[];
|
|
38
|
+
}): Promise<unknown>;
|
|
39
|
+
/**
|
|
40
|
+
* accept claim Consent
|
|
41
|
+
* @param options
|
|
42
|
+
* @returns
|
|
43
|
+
*/
|
|
44
|
+
function acceptClaimConsent(options: {
|
|
45
|
+
client_id: string;
|
|
46
|
+
sub: string;
|
|
47
|
+
accepted_claims: string[];
|
|
48
|
+
}): Promise<unknown>;
|
|
49
|
+
/**
|
|
50
|
+
* revoke claim Consent
|
|
51
|
+
* @param options
|
|
52
|
+
* @returns
|
|
53
|
+
*/
|
|
54
|
+
function revokeClaimConsent(options: {
|
|
55
|
+
client_id: string;
|
|
56
|
+
sub: string;
|
|
57
|
+
revoked_claims: string[];
|
|
58
|
+
}): Promise<unknown>;
|
|
59
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
exports.__esModule = true;
|
|
3
|
+
exports.ConsentService = void 0;
|
|
4
|
+
var Helper_1 = require("./Helper");
|
|
5
|
+
var ConsentService;
|
|
6
|
+
(function (ConsentService) {
|
|
7
|
+
/**
|
|
8
|
+
* get user consent details
|
|
9
|
+
* @param options
|
|
10
|
+
* @returns
|
|
11
|
+
*/
|
|
12
|
+
function getConsentDetailsV2(options) {
|
|
13
|
+
var _serviceURL = window.webAuthSettings.authority + "/consent-management-srv/v2/consent/usage/public/info";
|
|
14
|
+
return Helper_1.Helper.createPostPromise(options, _serviceURL, false, "POST");
|
|
15
|
+
}
|
|
16
|
+
ConsentService.getConsentDetailsV2 = getConsentDetailsV2;
|
|
17
|
+
;
|
|
18
|
+
/**
|
|
19
|
+
* accept constn v2
|
|
20
|
+
* @param options
|
|
21
|
+
* @returns
|
|
22
|
+
*/
|
|
23
|
+
function acceptConsentV2(options) {
|
|
24
|
+
var _serviceURL = window.webAuthSettings.authority + "/consent-management-srv/v2/consent/usage/accept";
|
|
25
|
+
return Helper_1.Helper.createPostPromise(options, _serviceURL, false, "POST");
|
|
26
|
+
}
|
|
27
|
+
ConsentService.acceptConsentV2 = acceptConsentV2;
|
|
28
|
+
;
|
|
29
|
+
/**
|
|
30
|
+
* get scope consent version details
|
|
31
|
+
* @param options
|
|
32
|
+
* @returns
|
|
33
|
+
*/
|
|
34
|
+
function getScopeConsentVersionDetailsV2(options) {
|
|
35
|
+
var _serviceURL = window.webAuthSettings.authority + "/consent-management-srv/v2/consent/versions/details/" + options.scopeid + "?locale=" + options.locale;
|
|
36
|
+
return Helper_1.Helper.createPostPromise(undefined, _serviceURL, false, "GET", options.access_token);
|
|
37
|
+
}
|
|
38
|
+
ConsentService.getScopeConsentVersionDetailsV2 = getScopeConsentVersionDetailsV2;
|
|
39
|
+
;
|
|
40
|
+
/**
|
|
41
|
+
* accept scope Consent
|
|
42
|
+
* @param options
|
|
43
|
+
* @returns
|
|
44
|
+
*/
|
|
45
|
+
function acceptScopeConsent(options) {
|
|
46
|
+
var _serviceURL = window.webAuthSettings.authority + "/consent-management-srv/consent/scope/accept";
|
|
47
|
+
return Helper_1.Helper.createPostPromise(options, _serviceURL, false, "POST");
|
|
48
|
+
}
|
|
49
|
+
ConsentService.acceptScopeConsent = acceptScopeConsent;
|
|
50
|
+
;
|
|
51
|
+
/**
|
|
52
|
+
* accept claim Consent
|
|
53
|
+
* @param options
|
|
54
|
+
* @returns
|
|
55
|
+
*/
|
|
56
|
+
function acceptClaimConsent(options) {
|
|
57
|
+
var _serviceURL = window.webAuthSettings.authority + "/consent-management-srv/consent/claim/accept";
|
|
58
|
+
return Helper_1.Helper.createPostPromise(options, _serviceURL, false, "POST");
|
|
59
|
+
}
|
|
60
|
+
ConsentService.acceptClaimConsent = acceptClaimConsent;
|
|
61
|
+
;
|
|
62
|
+
/**
|
|
63
|
+
* revoke claim Consent
|
|
64
|
+
* @param options
|
|
65
|
+
* @returns
|
|
66
|
+
*/
|
|
67
|
+
function revokeClaimConsent(options) {
|
|
68
|
+
var _serviceURL = window.webAuthSettings.authority + "/consent-management-srv/consent/claim/revoke";
|
|
69
|
+
return Helper_1.Helper.createPostPromise(options, _serviceURL, false, "POST");
|
|
70
|
+
}
|
|
71
|
+
ConsentService.revokeClaimConsent = revokeClaimConsent;
|
|
72
|
+
;
|
|
73
|
+
})(ConsentService = exports.ConsentService || (exports.ConsentService = {}));
|