@keycloak/keycloak-admin-client 16.0.0-dev.9 → 16.0.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/README.md +32 -1
- package/lib/client.d.ts +8 -6
- package/lib/client.js +14 -6
- package/lib/client.js.map +1 -1
- package/lib/defs/clientPoliciesRepresentation.d.ts +4 -0
- package/lib/defs/clientPoliciesRepresentation.js +3 -0
- package/lib/defs/clientPoliciesRepresentation.js.map +1 -0
- package/lib/defs/clientPolicyConditionRepresentation.d.ts +4 -0
- package/lib/defs/clientPolicyConditionRepresentation.js +3 -0
- package/lib/defs/clientPolicyConditionRepresentation.js.map +1 -0
- package/lib/defs/clientPolicyExecutorRepresentation.d.ts +4 -0
- package/lib/defs/clientPolicyExecutorRepresentation.js +3 -0
- package/lib/defs/clientPolicyExecutorRepresentation.js.map +1 -0
- package/lib/defs/clientPolicyRepresentation.d.ts +8 -0
- package/lib/defs/clientPolicyRepresentation.js +3 -0
- package/lib/defs/clientPolicyRepresentation.js.map +1 -0
- package/lib/defs/clientProfileRepresentation.d.ts +6 -0
- package/lib/defs/clientProfileRepresentation.js +3 -0
- package/lib/defs/clientProfileRepresentation.js.map +1 -0
- package/lib/defs/clientProfilesRepresentation.d.ts +5 -0
- package/lib/defs/clientProfilesRepresentation.js +3 -0
- package/lib/defs/clientProfilesRepresentation.js.map +1 -0
- package/lib/defs/credentialRepresentation.d.ts +5 -9
- package/lib/defs/identityProviderMapperTypeRepresentation.d.ts +8 -0
- package/lib/defs/identityProviderMapperTypeRepresentation.js +3 -0
- package/lib/defs/identityProviderMapperTypeRepresentation.js.map +1 -0
- package/lib/defs/realmRepresentation.d.ts +21 -0
- package/lib/defs/requiredActionProviderRepresentation.d.ts +1 -1
- package/lib/defs/requiredActionProviderSimpleRepresentation.d.ts +5 -0
- package/lib/defs/requiredActionProviderSimpleRepresentation.js +3 -0
- package/lib/defs/requiredActionProviderSimpleRepresentation.js.map +1 -0
- package/lib/defs/resourceRepresentation.d.ts +10 -6
- package/lib/defs/resourceServerRepresentation.d.ts +25 -8
- package/lib/defs/resourceServerRepresentation.js +0 -7
- package/lib/defs/resourceServerRepresentation.js.map +1 -1
- package/lib/defs/userProfileConfig.d.ts +31 -0
- package/lib/defs/userProfileConfig.js +3 -0
- package/lib/defs/userProfileConfig.js.map +1 -0
- package/lib/resources/agent.d.ts +4 -3
- package/lib/resources/agent.js +33 -28
- package/lib/resources/agent.js.map +1 -1
- package/lib/resources/attackDetection.d.ts +8 -8
- package/lib/resources/attackDetection.js.map +1 -1
- package/lib/resources/authenticationManagement.d.ts +28 -27
- package/lib/resources/authenticationManagement.js.map +1 -1
- package/lib/resources/cache.d.ts +2 -2
- package/lib/resources/clientPolicies.d.ts +23 -0
- package/lib/resources/clientPolicies.js +58 -0
- package/lib/resources/clientPolicies.js.map +1 -0
- package/lib/resources/clientScopes.d.ts +72 -72
- package/lib/resources/clientScopes.js +4 -6
- package/lib/resources/clientScopes.js.map +1 -1
- package/lib/resources/clients.d.ts +250 -195
- package/lib/resources/clients.js +42 -3
- package/lib/resources/clients.js.map +1 -1
- package/lib/resources/components.d.ts +20 -13
- package/lib/resources/components.js +6 -0
- package/lib/resources/components.js.map +1 -1
- package/lib/resources/groups.d.ts +64 -53
- package/lib/resources/groups.js +10 -0
- package/lib/resources/groups.js.map +1 -1
- package/lib/resources/identityProviders.d.ts +36 -35
- package/lib/resources/identityProviders.js.map +1 -1
- package/lib/resources/realms.d.ts +55 -47
- package/lib/resources/realms.js +8 -1
- package/lib/resources/realms.js.map +1 -1
- package/lib/resources/resource.d.ts +1 -1
- package/lib/resources/roles.d.ts +44 -36
- package/lib/resources/roles.js.map +1 -1
- package/lib/resources/serverInfo.d.ts +1 -1
- package/lib/resources/sessions.d.ts +2 -2
- package/lib/resources/userStorageProvider.d.ts +17 -17
- package/lib/resources/users.d.ts +146 -107
- package/lib/resources/users.js +34 -0
- package/lib/resources/users.js.map +1 -1
- package/lib/resources/whoAmI.d.ts +2 -2
- package/lib/utils/auth.d.ts +10 -0
- package/lib/utils/auth.js +3 -3
- package/lib/utils/auth.js.map +1 -1
- package/package.json +6 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import Resource from './resource';
|
|
2
2
|
import AdminEventRepresentation from '../defs/adminEventRepresentation';
|
|
3
|
-
import RealmRepresentation from '../defs/realmRepresentation';
|
|
3
|
+
import RealmRepresentation, { PartialImportRealmRepresentation, PartialImportResponse } from '../defs/realmRepresentation';
|
|
4
4
|
import EventRepresentation from '../defs/eventRepresentation';
|
|
5
5
|
import EventType from '../defs/eventTypes';
|
|
6
6
|
import KeysMetadataRepresentation from '../defs/keyMetadataRepresentation';
|
|
@@ -10,98 +10,104 @@ import { KeycloakAdminClient } from '../client';
|
|
|
10
10
|
import { RealmEventsConfigRepresentation } from '../defs/realmEventsConfigRepresentation';
|
|
11
11
|
import GlobalRequestResult from '../defs/globalRequestResult';
|
|
12
12
|
export declare class Realms extends Resource {
|
|
13
|
-
find: (payload?: {
|
|
14
|
-
|
|
13
|
+
find: (payload?: {
|
|
14
|
+
briefRepresentation?: boolean | undefined;
|
|
15
|
+
} | undefined) => Promise<RealmRepresentation[]>;
|
|
16
|
+
create: (payload?: RealmRepresentation | undefined) => Promise<{
|
|
15
17
|
realmName: string;
|
|
16
18
|
}>;
|
|
17
19
|
findOne: (payload?: {
|
|
18
20
|
realm: string;
|
|
19
|
-
}) => Promise<RealmRepresentation>;
|
|
21
|
+
} | undefined) => Promise<RealmRepresentation | undefined>;
|
|
20
22
|
update: (query: {
|
|
21
23
|
realm: string;
|
|
22
24
|
}, payload: RealmRepresentation) => Promise<void>;
|
|
23
25
|
del: (payload?: {
|
|
24
26
|
realm: string;
|
|
25
|
-
}) => Promise<void>;
|
|
27
|
+
} | undefined) => Promise<void>;
|
|
28
|
+
partialImport: (payload?: {
|
|
29
|
+
realm: string;
|
|
30
|
+
rep: PartialImportRealmRepresentation;
|
|
31
|
+
} | undefined) => Promise<PartialImportResponse>;
|
|
26
32
|
export: (payload?: {
|
|
27
33
|
realm: string;
|
|
28
|
-
exportClients?: boolean;
|
|
29
|
-
exportGroupsAndRoles?: boolean;
|
|
30
|
-
}) => Promise<RealmRepresentation>;
|
|
34
|
+
exportClients?: boolean | undefined;
|
|
35
|
+
exportGroupsAndRoles?: boolean | undefined;
|
|
36
|
+
} | undefined) => Promise<RealmRepresentation>;
|
|
31
37
|
findEvents: (payload?: {
|
|
32
38
|
realm: string;
|
|
33
|
-
client?: string;
|
|
34
|
-
dateFrom?: Date;
|
|
35
|
-
dateTo?: Date;
|
|
36
|
-
first?: number;
|
|
37
|
-
ipAddress?: string;
|
|
38
|
-
max?: number;
|
|
39
|
-
type?: EventType | EventType[];
|
|
40
|
-
user?: string;
|
|
41
|
-
}) => Promise<EventRepresentation[]>;
|
|
39
|
+
client?: string | undefined;
|
|
40
|
+
dateFrom?: Date | undefined;
|
|
41
|
+
dateTo?: Date | undefined;
|
|
42
|
+
first?: number | undefined;
|
|
43
|
+
ipAddress?: string | undefined;
|
|
44
|
+
max?: number | undefined;
|
|
45
|
+
type?: EventType | EventType[] | undefined;
|
|
46
|
+
user?: string | undefined;
|
|
47
|
+
} | undefined) => Promise<EventRepresentation[]>;
|
|
42
48
|
getConfigEvents: (payload?: {
|
|
43
49
|
realm: string;
|
|
44
|
-
}) => Promise<RealmEventsConfigRepresentation>;
|
|
50
|
+
} | undefined) => Promise<RealmEventsConfigRepresentation>;
|
|
45
51
|
updateConfigEvents: (query: {
|
|
46
52
|
realm: string;
|
|
47
53
|
}, payload: RealmEventsConfigRepresentation) => Promise<void>;
|
|
48
54
|
clearEvents: (payload?: {
|
|
49
55
|
realm: string;
|
|
50
|
-
}) => Promise<void>;
|
|
56
|
+
} | undefined) => Promise<void>;
|
|
51
57
|
clearAdminEvents: (payload?: {
|
|
52
58
|
realm: string;
|
|
53
|
-
}) => Promise<void>;
|
|
59
|
+
} | undefined) => Promise<void>;
|
|
54
60
|
getClientsInitialAccess: (payload?: {
|
|
55
61
|
realm: string;
|
|
56
|
-
}) => Promise<ClientInitialAccessPresentation[]>;
|
|
62
|
+
} | undefined) => Promise<ClientInitialAccessPresentation[]>;
|
|
57
63
|
createClientsInitialAccess: (query: {
|
|
58
64
|
realm: string;
|
|
59
65
|
}, payload: {
|
|
60
|
-
count?: number;
|
|
61
|
-
expiration?: number;
|
|
66
|
+
count?: number | undefined;
|
|
67
|
+
expiration?: number | undefined;
|
|
62
68
|
}) => Promise<ClientInitialAccessPresentation>;
|
|
63
69
|
delClientsInitialAccess: (payload?: {
|
|
64
70
|
realm: string;
|
|
65
71
|
id: string;
|
|
66
|
-
}) => Promise<void>;
|
|
72
|
+
} | undefined) => Promise<void>;
|
|
67
73
|
removeSession: (payload?: {
|
|
68
74
|
realm: string;
|
|
69
75
|
sessionId: string;
|
|
70
|
-
}) => Promise<void>;
|
|
76
|
+
} | undefined) => Promise<void>;
|
|
71
77
|
findAdminEvents: (payload?: {
|
|
72
78
|
realm: string;
|
|
73
|
-
authClient?: string;
|
|
74
|
-
authIpAddress?: string;
|
|
75
|
-
authRealm?: string;
|
|
76
|
-
authUser?: string;
|
|
77
|
-
dateFrom?: Date;
|
|
78
|
-
dateTo?: Date;
|
|
79
|
-
first?: number;
|
|
80
|
-
max?: number;
|
|
81
|
-
operationTypes?: string;
|
|
82
|
-
resourcePath?: string;
|
|
83
|
-
resourceTypes?: string;
|
|
84
|
-
}) => Promise<AdminEventRepresentation[]>;
|
|
79
|
+
authClient?: string | undefined;
|
|
80
|
+
authIpAddress?: string | undefined;
|
|
81
|
+
authRealm?: string | undefined;
|
|
82
|
+
authUser?: string | undefined;
|
|
83
|
+
dateFrom?: Date | undefined;
|
|
84
|
+
dateTo?: Date | undefined;
|
|
85
|
+
first?: number | undefined;
|
|
86
|
+
max?: number | undefined;
|
|
87
|
+
operationTypes?: string | undefined;
|
|
88
|
+
resourcePath?: string | undefined;
|
|
89
|
+
resourceTypes?: string | undefined;
|
|
90
|
+
} | undefined) => Promise<AdminEventRepresentation[]>;
|
|
85
91
|
getUsersManagementPermissions: (payload?: {
|
|
86
92
|
realm: string;
|
|
87
|
-
}) => Promise<void>;
|
|
93
|
+
} | undefined) => Promise<void>;
|
|
88
94
|
updateUsersManagementPermissions: (payload?: {
|
|
89
95
|
realm: string;
|
|
90
96
|
enabled: boolean;
|
|
91
|
-
}) => Promise<void>;
|
|
97
|
+
} | undefined) => Promise<void>;
|
|
92
98
|
logoutAll: (payload?: {
|
|
93
99
|
realm: string;
|
|
94
|
-
}) => Promise<void>;
|
|
100
|
+
} | undefined) => Promise<void>;
|
|
95
101
|
deleteSession: (payload?: {
|
|
96
102
|
realm: string;
|
|
97
103
|
session: string;
|
|
98
|
-
}) => Promise<void>;
|
|
104
|
+
} | undefined) => Promise<void>;
|
|
99
105
|
pushRevocation: (payload?: {
|
|
100
106
|
realm: string;
|
|
101
|
-
}) => Promise<GlobalRequestResult>;
|
|
107
|
+
} | undefined) => Promise<GlobalRequestResult>;
|
|
102
108
|
getKeys: (payload?: {
|
|
103
109
|
realm: string;
|
|
104
|
-
}) => Promise<KeysMetadataRepresentation>;
|
|
110
|
+
} | undefined) => Promise<KeysMetadataRepresentation>;
|
|
105
111
|
testLDAPConnection: (query: {
|
|
106
112
|
realm: string;
|
|
107
113
|
}, payload: TestLdapConnectionRepresentation) => Promise<any>;
|
|
@@ -110,11 +116,13 @@ export declare class Realms extends Resource {
|
|
|
110
116
|
}, payload: Record<string, string | number>) => Promise<any>;
|
|
111
117
|
getRealmSpecificLocales: (payload?: {
|
|
112
118
|
realm: string;
|
|
113
|
-
}) => Promise<string[]>;
|
|
119
|
+
} | undefined) => Promise<string[]>;
|
|
114
120
|
getRealmLocalizationTexts: (payload?: {
|
|
115
121
|
realm: string;
|
|
116
122
|
selectedLocale: string;
|
|
117
|
-
|
|
123
|
+
first?: number | undefined;
|
|
124
|
+
max?: number | undefined;
|
|
125
|
+
} | undefined) => Promise<Record<string, string>>;
|
|
118
126
|
addLocalization: (query: {
|
|
119
127
|
realm: string;
|
|
120
128
|
selectedLocale: string;
|
|
@@ -123,7 +131,7 @@ export declare class Realms extends Resource {
|
|
|
123
131
|
deleteRealmLocalizationTexts: (payload?: {
|
|
124
132
|
realm: string;
|
|
125
133
|
selectedLocale: string;
|
|
126
|
-
key?: string;
|
|
127
|
-
}) => Promise<void>;
|
|
134
|
+
key?: string | undefined;
|
|
135
|
+
} | undefined) => Promise<void>;
|
|
128
136
|
constructor(client: KeycloakAdminClient);
|
|
129
137
|
}
|
package/lib/resources/realms.js
CHANGED
|
@@ -50,6 +50,12 @@ var Realms = (function (_super) {
|
|
|
50
50
|
path: '/{realm}',
|
|
51
51
|
urlParamKeys: ['realm']
|
|
52
52
|
});
|
|
53
|
+
_this.partialImport = _this.makeRequest({
|
|
54
|
+
method: 'POST',
|
|
55
|
+
path: '/{realm}/partialImport',
|
|
56
|
+
urlParamKeys: ['realm'],
|
|
57
|
+
payloadKey: 'rep'
|
|
58
|
+
});
|
|
53
59
|
_this["export"] = _this.makeRequest({
|
|
54
60
|
method: 'POST',
|
|
55
61
|
path: '/{realm}/partial-export',
|
|
@@ -184,7 +190,8 @@ var Realms = (function (_super) {
|
|
|
184
190
|
_this.addLocalization = _this.makeUpdateRequest({
|
|
185
191
|
method: 'PUT',
|
|
186
192
|
path: '/{realm}/localization/{selectedLocale}/{key}',
|
|
187
|
-
urlParamKeys: ['realm', 'selectedLocale', 'key']
|
|
193
|
+
urlParamKeys: ['realm', 'selectedLocale', 'key'],
|
|
194
|
+
headers: { 'content-type': 'text/plain' }
|
|
188
195
|
});
|
|
189
196
|
_this.deleteRealmLocalizationTexts = _this.makeRequest({
|
|
190
197
|
method: 'DELETE',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"realms.js","sourceRoot":"","sources":["../../src/resources/realms.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,wDAAkC;
|
|
1
|
+
{"version":3,"file":"realms.js","sourceRoot":"","sources":["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AAG,KAAI,CAAC,WAAW,CAGpD;YACA,MAAM,EAAE,QAAQ;YAChB,IAAI,EAAE,8CAA8C;YACpD,YAAY,EAAE,CAAC,OAAO,EAAE,gBAAgB,EAAE,KAAK,CAAC;SACjD,CAAC,CAAC;;IAOH,CAAC;IACH,aAAC;AAAD,CAAC,AA1UD,CAA4B,qBAAQ,GA0UnC;AA1UY,wBAAM"}
|
|
@@ -7,6 +7,6 @@ export default class Resource<ParamType = {}> {
|
|
|
7
7
|
getUrlParams?: () => Record<string, any>;
|
|
8
8
|
getBaseUrl?: () => string;
|
|
9
9
|
});
|
|
10
|
-
makeRequest: <PayloadType = any, ResponseType_1 = any>(args: RequestArgs) => (payload?: PayloadType & ParamType) => Promise<ResponseType_1>;
|
|
10
|
+
makeRequest: <PayloadType = any, ResponseType_1 = any>(args: RequestArgs) => (payload?: (PayloadType & ParamType) | undefined) => Promise<ResponseType_1>;
|
|
11
11
|
makeUpdateRequest: <QueryType = any, PayloadType = any, ResponseType_1 = any>(args: RequestArgs) => (query: QueryType & ParamType, payload: PayloadType) => Promise<ResponseType_1>;
|
|
12
12
|
}
|
package/lib/resources/roles.d.ts
CHANGED
|
@@ -2,79 +2,87 @@ import Resource from './resource';
|
|
|
2
2
|
import RoleRepresentation from '../defs/roleRepresentation';
|
|
3
3
|
import UserRepresentation from '../defs/userRepresentation';
|
|
4
4
|
import { KeycloakAdminClient } from '../client';
|
|
5
|
+
export interface RoleQuery {
|
|
6
|
+
first?: number;
|
|
7
|
+
max?: number;
|
|
8
|
+
search?: string;
|
|
9
|
+
}
|
|
5
10
|
export declare class Roles extends Resource<{
|
|
6
11
|
realm?: string;
|
|
7
12
|
}> {
|
|
8
|
-
find: (payload?: {
|
|
9
|
-
realm?: string;
|
|
10
|
-
}) => Promise<RoleRepresentation[]>;
|
|
11
|
-
create: (payload?: RoleRepresentation & {
|
|
12
|
-
realm?: string;
|
|
13
|
-
}) => Promise<{
|
|
13
|
+
find: (payload?: (RoleQuery & {
|
|
14
|
+
realm?: string | undefined;
|
|
15
|
+
}) | undefined) => Promise<RoleRepresentation[]>;
|
|
16
|
+
create: (payload?: (RoleRepresentation & {
|
|
17
|
+
realm?: string | undefined;
|
|
18
|
+
}) | undefined) => Promise<{
|
|
14
19
|
roleName: string;
|
|
15
20
|
}>;
|
|
16
|
-
findOneByName: (payload?: {
|
|
21
|
+
findOneByName: (payload?: ({
|
|
17
22
|
name: string;
|
|
18
23
|
} & {
|
|
19
|
-
realm?: string;
|
|
20
|
-
}) => Promise<RoleRepresentation>;
|
|
24
|
+
realm?: string | undefined;
|
|
25
|
+
}) | undefined) => Promise<RoleRepresentation | undefined>;
|
|
21
26
|
updateByName: (query: {
|
|
22
27
|
name: string;
|
|
23
28
|
} & {
|
|
24
|
-
realm?: string;
|
|
29
|
+
realm?: string | undefined;
|
|
25
30
|
}, payload: RoleRepresentation) => Promise<void>;
|
|
26
|
-
delByName: (payload?: {
|
|
31
|
+
delByName: (payload?: ({
|
|
27
32
|
name: string;
|
|
28
33
|
} & {
|
|
29
|
-
realm?: string;
|
|
30
|
-
}) => Promise<void>;
|
|
31
|
-
findUsersWithRole: (payload?: {
|
|
34
|
+
realm?: string | undefined;
|
|
35
|
+
}) | undefined) => Promise<void>;
|
|
36
|
+
findUsersWithRole: (payload?: ({
|
|
32
37
|
name: string;
|
|
33
|
-
first?: number;
|
|
34
|
-
max?: number;
|
|
38
|
+
first?: number | undefined;
|
|
39
|
+
max?: number | undefined;
|
|
35
40
|
} & {
|
|
36
|
-
realm?: string;
|
|
37
|
-
}) => Promise<UserRepresentation[]>;
|
|
38
|
-
findOneById: (payload?: {
|
|
41
|
+
realm?: string | undefined;
|
|
42
|
+
}) | undefined) => Promise<UserRepresentation[]>;
|
|
43
|
+
findOneById: (payload?: ({
|
|
39
44
|
id: string;
|
|
40
45
|
} & {
|
|
41
|
-
realm?: string;
|
|
42
|
-
}) => Promise<RoleRepresentation>;
|
|
46
|
+
realm?: string | undefined;
|
|
47
|
+
}) | undefined) => Promise<RoleRepresentation | undefined>;
|
|
43
48
|
createComposite: (query: {
|
|
44
49
|
roleId: string;
|
|
45
50
|
} & {
|
|
46
|
-
realm?: string;
|
|
51
|
+
realm?: string | undefined;
|
|
47
52
|
}, payload: RoleRepresentation[]) => Promise<void>;
|
|
48
|
-
getCompositeRoles: (payload?: {
|
|
53
|
+
getCompositeRoles: (payload?: ({
|
|
49
54
|
id: string;
|
|
55
|
+
search?: string | undefined;
|
|
56
|
+
first?: number | undefined;
|
|
57
|
+
max?: number | undefined;
|
|
50
58
|
} & {
|
|
51
|
-
realm?: string;
|
|
52
|
-
}) => Promise<RoleRepresentation[]>;
|
|
53
|
-
getCompositeRolesForRealm: (payload?: {
|
|
59
|
+
realm?: string | undefined;
|
|
60
|
+
}) | undefined) => Promise<RoleRepresentation[]>;
|
|
61
|
+
getCompositeRolesForRealm: (payload?: ({
|
|
54
62
|
id: string;
|
|
55
63
|
} & {
|
|
56
|
-
realm?: string;
|
|
57
|
-
}) => Promise<RoleRepresentation[]>;
|
|
58
|
-
getCompositeRolesForClient: (payload?: {
|
|
64
|
+
realm?: string | undefined;
|
|
65
|
+
}) | undefined) => Promise<RoleRepresentation[]>;
|
|
66
|
+
getCompositeRolesForClient: (payload?: ({
|
|
59
67
|
id: string;
|
|
60
68
|
clientId: string;
|
|
61
69
|
} & {
|
|
62
|
-
realm?: string;
|
|
63
|
-
}) => Promise<RoleRepresentation[]>;
|
|
70
|
+
realm?: string | undefined;
|
|
71
|
+
}) | undefined) => Promise<RoleRepresentation[]>;
|
|
64
72
|
delCompositeRoles: (query: {
|
|
65
73
|
id: string;
|
|
66
74
|
} & {
|
|
67
|
-
realm?: string;
|
|
75
|
+
realm?: string | undefined;
|
|
68
76
|
}, payload: RoleRepresentation[]) => Promise<void>;
|
|
69
77
|
updateById: (query: {
|
|
70
78
|
id: string;
|
|
71
79
|
} & {
|
|
72
|
-
realm?: string;
|
|
80
|
+
realm?: string | undefined;
|
|
73
81
|
}, payload: RoleRepresentation) => Promise<void>;
|
|
74
|
-
delById: (payload?: {
|
|
82
|
+
delById: (payload?: ({
|
|
75
83
|
id: string;
|
|
76
84
|
} & {
|
|
77
|
-
realm?: string;
|
|
78
|
-
}) => Promise<void>;
|
|
85
|
+
realm?: string | undefined;
|
|
86
|
+
}) | undefined) => Promise<void>;
|
|
79
87
|
constructor(client: KeycloakAdminClient);
|
|
80
88
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"roles.js","sourceRoot":"","sources":["../../src/resources/roles.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,wDAAkC;
|
|
1
|
+
{"version":3,"file":"roles.js","sourceRoot":"","sources":["../../src/resources/roles.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,wDAAkC;AAWlC;IAA2B,yBAA0B;IAqInD,eAAY,MAA2B;QAAvC,YACE,kBAAM,MAAM,EAAE;YACZ,IAAI,EAAE,uBAAuB;YAC7B,YAAY,EAAE,cAAM,OAAA,CAAC;gBACnB,KAAK,EAAE,MAAM,CAAC,SAAS;aACxB,CAAC,EAFkB,CAElB;YACF,UAAU,EAAE,cAAM,OAAA,MAAM,CAAC,OAAO,EAAd,CAAc;SACjC,CAAC,SACH;QAxIM,UAAI,GAAG,KAAI,CAAC,WAAW,CAAkC;YAC9D,MAAM,EAAE,KAAK;YACb,IAAI,EAAE,QAAQ;SACf,CAAC,CAAC;QAEI,YAAM,GAAG,KAAI,CAAC,WAAW,CAAyC;YACvE,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,QAAQ;YACd,gCAAgC,EAAE,EAAC,KAAK,EAAE,UAAU,EAAC;SACtD,CAAC,CAAC;QAMI,mBAAa,GAAG,KAAI,CAAC,WAAW,CAGrC;YACA,MAAM,EAAE,KAAK;YACb,IAAI,EAAE,eAAe;YACrB,YAAY,EAAE,CAAC,MAAM,CAAC;YACtB,aAAa,EAAE,IAAI;SACpB,CAAC,CAAC;QAEI,kBAAY,GAA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I,uBAAiB,GAAG,KAAI,CAAC,iBAAiB,CAI/C;YACA,MAAM,EAAE,QAAQ;YAChB,IAAI,EAAE,8BAA8B;YACpC,YAAY,EAAE,CAAC,IAAI,CAAC;SACrB,CAAC,CAAC;QAEI,gBAAU,GAAG,KAAI,CAAC,iBAAiB,CAIxC;YACA,MAAM,EAAE,KAAK;YACb,IAAI,EAAE,mBAAmB;YACzB,YAAY,EAAE,CAAC,IAAI,CAAC;SACrB,CAAC,CAAC;QAEI,aAAO,GAAG,KAAI,CAAC,WAAW,CAAqB;YACpD,MAAM,EAAE,QAAQ;YAChB,IAAI,EAAE,mBAAmB;YACzB,YAAY,EAAE,CAAC,IAAI,CAAC;SACrB,CAAC,CAAC;;IAUH,CAAC;IACH,YAAC;AAAD,CAAC,AA9ID,CAA2B,qBAAQ,GA8IlC;AA9IY,sBAAK"}
|
|
@@ -3,5 +3,5 @@ import { ServerInfoRepresentation } from '../defs/serverInfoRepesentation';
|
|
|
3
3
|
import KeycloakAdminClient from '..';
|
|
4
4
|
export declare class ServerInfo extends Resource {
|
|
5
5
|
constructor(client: KeycloakAdminClient);
|
|
6
|
-
find: (payload?: {}) => Promise<ServerInfoRepresentation>;
|
|
6
|
+
find: (payload?: {} | undefined) => Promise<ServerInfoRepresentation>;
|
|
7
7
|
}
|
|
@@ -4,7 +4,7 @@ export declare class Sessions extends Resource<{
|
|
|
4
4
|
realm?: string;
|
|
5
5
|
}> {
|
|
6
6
|
find: (payload?: {
|
|
7
|
-
realm?: string;
|
|
8
|
-
}) => Promise<Record<string, any>[]>;
|
|
7
|
+
realm?: string | undefined;
|
|
8
|
+
} | undefined) => Promise<Record<string, any>[]>;
|
|
9
9
|
constructor(client: KeycloakAdminClient);
|
|
10
10
|
}
|
|
@@ -10,34 +10,34 @@ declare type NameResponse = {
|
|
|
10
10
|
export declare class UserStorageProvider extends Resource<{
|
|
11
11
|
realm?: string;
|
|
12
12
|
}> {
|
|
13
|
-
name: (payload?: {
|
|
13
|
+
name: (payload?: ({
|
|
14
14
|
id: string;
|
|
15
15
|
} & {
|
|
16
|
-
realm?: string;
|
|
17
|
-
}) => Promise<NameResponse>;
|
|
18
|
-
removeImportedUsers: (payload?: {
|
|
16
|
+
realm?: string | undefined;
|
|
17
|
+
}) | undefined) => Promise<NameResponse>;
|
|
18
|
+
removeImportedUsers: (payload?: ({
|
|
19
19
|
id: string;
|
|
20
20
|
} & {
|
|
21
|
-
realm?: string;
|
|
22
|
-
}) => Promise<void>;
|
|
23
|
-
sync: (payload?: {
|
|
21
|
+
realm?: string | undefined;
|
|
22
|
+
}) | undefined) => Promise<void>;
|
|
23
|
+
sync: (payload?: ({
|
|
24
24
|
id: string;
|
|
25
|
-
action?: ActionType;
|
|
25
|
+
action?: ActionType | undefined;
|
|
26
26
|
} & {
|
|
27
|
-
realm?: string;
|
|
28
|
-
}) => Promise<SynchronizationResultRepresentation>;
|
|
29
|
-
unlinkUsers: (payload?: {
|
|
27
|
+
realm?: string | undefined;
|
|
28
|
+
}) | undefined) => Promise<SynchronizationResultRepresentation>;
|
|
29
|
+
unlinkUsers: (payload?: ({
|
|
30
30
|
id: string;
|
|
31
31
|
} & {
|
|
32
|
-
realm?: string;
|
|
33
|
-
}) => Promise<void>;
|
|
34
|
-
mappersSync: (payload?: {
|
|
32
|
+
realm?: string | undefined;
|
|
33
|
+
}) | undefined) => Promise<void>;
|
|
34
|
+
mappersSync: (payload?: ({
|
|
35
35
|
id: string;
|
|
36
36
|
parentId: string;
|
|
37
|
-
direction?: DirectionType;
|
|
37
|
+
direction?: DirectionType | undefined;
|
|
38
38
|
} & {
|
|
39
|
-
realm?: string;
|
|
40
|
-
}) => Promise<SynchronizationResultRepresentation>;
|
|
39
|
+
realm?: string | undefined;
|
|
40
|
+
}) | undefined) => Promise<SynchronizationResultRepresentation>;
|
|
41
41
|
constructor(client: KeycloakAdminClient);
|
|
42
42
|
}
|
|
43
43
|
export {};
|