@vendasta/iam 2.2.2 → 2.3.1

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.
Files changed (124) hide show
  1. package/esm2020/lib/_generated/host.service.mjs +25 -0
  2. package/esm2020/lib/_generated/index.mjs +2 -0
  3. package/esm2020/lib/_internal/enums/api.enum.mjs +22 -0
  4. package/esm2020/lib/_internal/enums/index.mjs +12 -0
  5. package/esm2020/lib/_internal/enums/policies.enum.mjs +18 -0
  6. package/esm2020/lib/_internal/enums/resources.enum.mjs +14 -0
  7. package/esm2020/lib/_internal/enums/subjects.enum.mjs +17 -0
  8. package/esm2020/lib/_internal/enums/users.enum.mjs +13 -0
  9. package/esm2020/lib/_internal/iam.api.service.mjs +189 -0
  10. package/esm2020/lib/_internal/index.mjs +12 -0
  11. package/esm2020/lib/_internal/interfaces/annotations.interface.mjs +8 -0
  12. package/esm2020/lib/_internal/interfaces/api.interface.mjs +2 -0
  13. package/esm2020/lib/_internal/interfaces/attributes.interface.mjs +8 -0
  14. package/esm2020/lib/_internal/interfaces/field-mask.interface.mjs +8 -0
  15. package/esm2020/lib/_internal/interfaces/index.mjs +2 -0
  16. package/esm2020/lib/_internal/interfaces/policies.interface.mjs +3 -0
  17. package/esm2020/lib/_internal/interfaces/resources.interface.mjs +2 -0
  18. package/esm2020/lib/_internal/interfaces/security-logs.interface.mjs +8 -0
  19. package/esm2020/lib/_internal/interfaces/subjects.interface.mjs +2 -0
  20. package/esm2020/lib/_internal/interfaces/users.interface.mjs +2 -0
  21. package/esm2020/lib/_internal/objects/annotations.mjs +30 -0
  22. package/esm2020/lib/_internal/objects/api.mjs +1846 -0
  23. package/esm2020/lib/_internal/objects/attributes.mjs +158 -0
  24. package/esm2020/lib/_internal/objects/field-mask.mjs +27 -0
  25. package/esm2020/lib/_internal/objects/index.mjs +16 -0
  26. package/esm2020/lib/_internal/objects/policies.mjs +264 -0
  27. package/esm2020/lib/_internal/objects/resources.mjs +168 -0
  28. package/esm2020/lib/_internal/objects/security-logs.mjs +42 -0
  29. package/esm2020/lib/_internal/objects/subjects.mjs +352 -0
  30. package/esm2020/lib/_internal/objects/users.mjs +168 -0
  31. package/esm2020/lib/_internal/user-iam.api.service.mjs +65 -0
  32. package/esm2020/lib/http/http.interface.mjs +2 -0
  33. package/esm2020/lib/http/http.mjs +104 -0
  34. package/esm2020/lib/http/iam.http.api.service.mjs +67 -0
  35. package/esm2020/lib/iam.service.mjs +155 -0
  36. package/esm2020/lib/index.mjs +7 -0
  37. package/esm2020/lib/personas/account-group.mjs +9 -0
  38. package/esm2020/lib/personas/base-personas.mjs +93 -0
  39. package/esm2020/lib/personas/crm-role.mjs +9 -0
  40. package/esm2020/lib/personas/developer.mjs +9 -0
  41. package/esm2020/lib/personas/digital-agent.mjs +9 -0
  42. package/esm2020/lib/personas/index.mjs +13 -0
  43. package/esm2020/lib/personas/partner-app.mjs +9 -0
  44. package/esm2020/lib/personas/partner.mjs +25 -0
  45. package/esm2020/lib/personas/persona-type.enum.mjs +14 -0
  46. package/esm2020/lib/personas/personas.mjs +61 -0
  47. package/esm2020/lib/personas/salesperson.mjs +15 -0
  48. package/esm2020/lib/personas/smb.mjs +10 -0
  49. package/esm2020/lib/personas/success.mjs +9 -0
  50. package/esm2020/lib/personas/vendor.mjs +9 -0
  51. package/esm2020/public_api.mjs +2 -0
  52. package/esm2020/vendasta-iam.mjs +5 -0
  53. package/fesm2015/{vendasta-iam.js → vendasta-iam.mjs} +375 -388
  54. package/fesm2015/vendasta-iam.mjs.map +1 -0
  55. package/fesm2020/vendasta-iam.mjs +3948 -0
  56. package/fesm2020/vendasta-iam.mjs.map +1 -0
  57. package/lib/_generated/host.service.d.ts +4 -11
  58. package/lib/_internal/iam.api.service.d.ts +3 -2
  59. package/lib/_internal/user-iam.api.service.d.ts +3 -2
  60. package/lib/http/iam.http.api.service.d.ts +3 -2
  61. package/lib/iam.service.d.ts +2 -2
  62. package/lib/index.d.ts +1 -1
  63. package/lib/personas/crm-role.d.ts +5 -0
  64. package/lib/personas/index.d.ts +1 -0
  65. package/lib/personas/persona-type.enum.d.ts +2 -1
  66. package/package.json +27 -16
  67. package/{README.md → src/README.md} +0 -0
  68. package/CHANGELOG.md +0 -101
  69. package/bundles/vendasta-iam.umd.js +0 -4531
  70. package/bundles/vendasta-iam.umd.js.map +0 -1
  71. package/bundles/vendasta-iam.umd.min.js +0 -16
  72. package/bundles/vendasta-iam.umd.min.js.map +0 -1
  73. package/esm2015/lib/_generated/host.service.js +0 -64
  74. package/esm2015/lib/_generated/index.js +0 -2
  75. package/esm2015/lib/_internal/enums/api.enum.js +0 -22
  76. package/esm2015/lib/_internal/enums/index.js +0 -12
  77. package/esm2015/lib/_internal/enums/policies.enum.js +0 -18
  78. package/esm2015/lib/_internal/enums/resources.enum.js +0 -14
  79. package/esm2015/lib/_internal/enums/subjects.enum.js +0 -17
  80. package/esm2015/lib/_internal/enums/users.enum.js +0 -13
  81. package/esm2015/lib/_internal/iam.api.service.js +0 -188
  82. package/esm2015/lib/_internal/index.js +0 -12
  83. package/esm2015/lib/_internal/interfaces/annotations.interface.js +0 -8
  84. package/esm2015/lib/_internal/interfaces/api.interface.js +0 -2
  85. package/esm2015/lib/_internal/interfaces/attributes.interface.js +0 -8
  86. package/esm2015/lib/_internal/interfaces/field-mask.interface.js +0 -8
  87. package/esm2015/lib/_internal/interfaces/index.js +0 -2
  88. package/esm2015/lib/_internal/interfaces/policies.interface.js +0 -3
  89. package/esm2015/lib/_internal/interfaces/resources.interface.js +0 -2
  90. package/esm2015/lib/_internal/interfaces/security-logs.interface.js +0 -8
  91. package/esm2015/lib/_internal/interfaces/subjects.interface.js +0 -2
  92. package/esm2015/lib/_internal/interfaces/users.interface.js +0 -2
  93. package/esm2015/lib/_internal/objects/annotations.js +0 -30
  94. package/esm2015/lib/_internal/objects/api.js +0 -1846
  95. package/esm2015/lib/_internal/objects/attributes.js +0 -158
  96. package/esm2015/lib/_internal/objects/field-mask.js +0 -27
  97. package/esm2015/lib/_internal/objects/index.js +0 -16
  98. package/esm2015/lib/_internal/objects/policies.js +0 -264
  99. package/esm2015/lib/_internal/objects/resources.js +0 -168
  100. package/esm2015/lib/_internal/objects/security-logs.js +0 -42
  101. package/esm2015/lib/_internal/objects/subjects.js +0 -352
  102. package/esm2015/lib/_internal/objects/users.js +0 -168
  103. package/esm2015/lib/_internal/user-iam.api.service.js +0 -64
  104. package/esm2015/lib/http/http.interface.js +0 -2
  105. package/esm2015/lib/http/http.js +0 -102
  106. package/esm2015/lib/http/iam.http.api.service.js +0 -65
  107. package/esm2015/lib/iam.service.js +0 -152
  108. package/esm2015/lib/index.js +0 -7
  109. package/esm2015/lib/personas/account-group.js +0 -9
  110. package/esm2015/lib/personas/base-personas.js +0 -89
  111. package/esm2015/lib/personas/developer.js +0 -9
  112. package/esm2015/lib/personas/digital-agent.js +0 -9
  113. package/esm2015/lib/personas/index.js +0 -12
  114. package/esm2015/lib/personas/partner-app.js +0 -9
  115. package/esm2015/lib/personas/partner.js +0 -25
  116. package/esm2015/lib/personas/persona-type.enum.js +0 -13
  117. package/esm2015/lib/personas/personas.js +0 -57
  118. package/esm2015/lib/personas/salesperson.js +0 -15
  119. package/esm2015/lib/personas/smb.js +0 -10
  120. package/esm2015/lib/personas/success.js +0 -9
  121. package/esm2015/lib/personas/vendor.js +0 -9
  122. package/esm2015/public_api.js +0 -2
  123. package/esm2015/vendasta-iam.js +0 -5
  124. package/fesm2015/vendasta-iam.js.map +0 -1
@@ -1,14 +1,7 @@
1
- import { EnvironmentService } from '@vendasta/core';
2
1
  import * as i0 from "@angular/core";
3
2
  export declare class HostService {
4
- private environmentService;
5
- private _host;
6
- private _httpsHost;
7
- constructor(environmentService: EnvironmentService);
8
- host(): string;
9
- httpsHost(): string;
10
- hostWithScheme(): string;
11
- httpsHostWithScheme(): string;
12
- static ɵfac: i0.ɵɵFactoryDef<HostService, never>;
13
- static ɵprov: i0.ɵɵInjectableDef<HostService>;
3
+ get host(): string;
4
+ get hostWithScheme(): string;
5
+ static ɵfac: i0.ɵɵFactoryDeclaration<HostService, never>;
6
+ static ɵprov: i0.ɵɵInjectableDeclaration<HostService>;
14
7
  }
@@ -7,6 +7,7 @@ import * as i0 from "@angular/core";
7
7
  export declare class IAMApiService {
8
8
  private http;
9
9
  private hostService;
10
+ private _host;
10
11
  constructor(http: HttpClient, hostService: HostService);
11
12
  private apiOptions;
12
13
  registerSubject(r: RegisterSubjectRequest | RegisterSubjectRequestInterface): Observable<RegisterSubjectResponse>;
@@ -43,6 +44,6 @@ export declare class IAMApiService {
43
44
  createExternalId(r: CreateExternalIDRequest | CreateExternalIDRequestInterface): Observable<HttpResponse<null>>;
44
45
  addMultiUserRestriction(r: AddMultiUserRestrictionRequest | AddMultiUserRestrictionRequestInterface): Observable<HttpResponse<null>>;
45
46
  removeMultiUserRestriction(r: RemoveMultiUserRestrictionRequest | RemoveMultiUserRestrictionRequestInterface): Observable<HttpResponse<null>>;
46
- static ɵfac: i0.ɵɵFactoryDef<IAMApiService, never>;
47
- static ɵprov: i0.ɵɵInjectableDef<IAMApiService>;
47
+ static ɵfac: i0.ɵɵFactoryDeclaration<IAMApiService, never>;
48
+ static ɵprov: i0.ɵɵInjectableDeclaration<IAMApiService>;
48
49
  }
@@ -7,6 +7,7 @@ import * as i0 from "@angular/core";
7
7
  export declare class UserIAMApiService {
8
8
  private http;
9
9
  private hostService;
10
+ private _host;
10
11
  constructor(http: HttpClient, hostService: HostService);
11
12
  private apiOptions;
12
13
  getSubjectBySession(r: GetSubjectBySessionRequest | GetSubjectBySessionRequestInterface): Observable<GetSubjectResponse>;
@@ -15,6 +16,6 @@ export declare class UserIAMApiService {
15
16
  getSessionToken(r: GetSessionTokenRequest | GetSessionTokenRequestInterface): Observable<GetTokenResponse>;
16
17
  resetPasswordWithToken(r: ResetPasswordWithTokenRequest | ResetPasswordWithTokenRequestInterface): Observable<HttpResponse<null>>;
17
18
  getImpersonationToken(r: GetImpersonationTokenRequest | GetImpersonationTokenRequestInterface): Observable<GetImpersonationTokenResponse>;
18
- static ɵfac: i0.ɵɵFactoryDef<UserIAMApiService, never>;
19
- static ɵprov: i0.ɵɵInjectableDef<UserIAMApiService>;
19
+ static ɵfac: i0.ɵɵFactoryDeclaration<UserIAMApiService, never>;
20
+ static ɵprov: i0.ɵɵInjectableDeclaration<UserIAMApiService>;
20
21
  }
@@ -7,11 +7,12 @@ import * as i0 from "@angular/core";
7
7
  export declare class IamHttpApiService {
8
8
  private http;
9
9
  private hostService;
10
+ private _host;
10
11
  constructor(http: HttpClient, hostService: HostService);
11
12
  private apiOptions;
12
13
  login(r: LoginRequest | LoginRequestInterface): Observable<LoginResponse>;
13
14
  logout(): Observable<LogoutResponse>;
14
15
  ssoLogin(r: SSOLoginRequest | SSOLoginRequestInterface): void;
15
- static ɵfac: i0.ɵɵFactoryDef<IamHttpApiService, never>;
16
- static ɵprov: i0.ɵɵInjectableDef<IamHttpApiService>;
16
+ static ɵfac: i0.ɵɵFactoryDeclaration<IamHttpApiService, never>;
17
+ static ɵprov: i0.ɵɵInjectableDeclaration<IamHttpApiService>;
17
18
  }
@@ -26,6 +26,6 @@ export declare class IAMService {
26
26
  getMultiUsers(userIdentifiers: UserIdentifierInterface[]): Observable<User[]>;
27
27
  listSecurityLogs(userId: string, cursor?: string, pageSize?: number, actionId?: string): Observable<ListSecurityLogsResponse>;
28
28
  listUsers(namespace: string, email?: string, cursor?: string, pageSize?: number, subjectTypes?: string[], searchTerms?: string[], sortOptions?: UserSortOptionsInterface[]): Observable<ListUsersResponse>;
29
- static ɵfac: i0.ɵɵFactoryDef<IAMService, never>;
30
- static ɵprov: i0.ɵɵInjectableDef<IAMService>;
29
+ static ɵfac: i0.ɵɵFactoryDeclaration<IAMService, never>;
30
+ static ɵprov: i0.ɵɵInjectableDeclaration<IAMService>;
31
31
  }
package/lib/index.d.ts CHANGED
@@ -3,4 +3,4 @@ export { HostService } from './_generated';
3
3
  export * from './_internal';
4
4
  export { UserSortOptionsInterface, UserFilterInterface } from './_internal/interfaces/api.interface';
5
5
  export { SortDirection, UserSortField } from './_internal/enums/api.enum';
6
- export { PersonaType, BasePersona, PartnerPersona, PartnerAppPersona, SalespersonPersona, SMBPersona, VendorPersona, DeveloperPersona, DigitalAgentPersona, NamespacedPersona, TypedPersona, fromPersona } from './personas';
6
+ export { PersonaType, BasePersona, CRMRolePersona, PartnerPersona, PartnerAppPersona, SalespersonPersona, SMBPersona, VendorPersona, DeveloperPersona, DigitalAgentPersona, NamespacedPersona, TypedPersona, fromPersona } from './personas';
@@ -0,0 +1,5 @@
1
+ import { NamespacedPersona } from './base-personas';
2
+ import { PersonaType } from './persona-type.enum';
3
+ export declare class CRMRolePersona extends NamespacedPersona {
4
+ type: PersonaType;
5
+ }
@@ -1,6 +1,7 @@
1
1
  export { PersonaType } from './persona-type.enum';
2
2
  export { DigitalAgentPersona } from './digital-agent';
3
3
  export { PartnerPersona } from './partner';
4
+ export { CRMRolePersona } from './crm-role';
4
5
  export { PartnerAppPersona } from './partner-app';
5
6
  export { SalespersonPersona, TitleChoice } from './salesperson';
6
7
  export { SMBPersona, AccountAccessPermission } from './smb';
@@ -7,5 +7,6 @@ export declare enum PersonaType {
7
7
  digital_agent = "digital_agent",
8
8
  developer = "developer",
9
9
  success = "success",
10
- account_group = "account_group"
10
+ account_group = "account_group",
11
+ crm_role = "crm_role"
11
12
  }
package/package.json CHANGED
@@ -1,26 +1,37 @@
1
1
  {
2
2
  "name": "@vendasta/iam",
3
- "version": "2.2.2",
3
+ "version": "2.3.1",
4
4
  "peerDependencies": {
5
- "@angular/core": "^10.0.0",
6
- "@angular/common": "^10.0.0",
7
- "@vendasta/core": "^46.0.1",
8
- "rxjs": "^6.0.0"
5
+ "@angular/common": "^13.0.0",
6
+ "@angular/core": "^13.0.0",
7
+ "@vendasta/core": "^55.0.2",
8
+ "rxjs": "^6.6.6"
9
9
  },
10
10
  "author": "Vendasta R&D",
11
11
  "description": "SDK to interact with the iam service",
12
12
  "typings": "vendasta-iam.d.ts",
13
- "dependencies": {
14
- "tslib": "^2.0.0"
15
- },
16
13
  "license": "ISC",
17
- "main": "bundles/vendasta-iam.umd.js",
18
- "module": "fesm2015/vendasta-iam.js",
19
- "es2015": "fesm2015/vendasta-iam.js",
20
- "esm2015": "esm2015/vendasta-iam.js",
21
- "fesm2015": "fesm2015/vendasta-iam.js",
14
+ "main": "index.js",
15
+ "module": "fesm2015/vendasta-iam.mjs",
16
+ "es2020": "fesm2020/vendasta-iam.mjs",
17
+ "esm2020": "esm2020/vendasta-iam.mjs",
18
+ "fesm2020": "fesm2020/vendasta-iam.mjs",
19
+ "fesm2015": "fesm2015/vendasta-iam.mjs",
20
+ "exports": {
21
+ "./package.json": {
22
+ "default": "./package.json"
23
+ },
24
+ ".": {
25
+ "types": "./vendasta-iam.d.ts",
26
+ "esm2020": "./esm2020/vendasta-iam.mjs",
27
+ "es2020": "./fesm2020/vendasta-iam.mjs",
28
+ "es2015": "./fesm2015/vendasta-iam.mjs",
29
+ "node": "./fesm2015/vendasta-iam.mjs",
30
+ "default": "./fesm2020/vendasta-iam.mjs"
31
+ }
32
+ },
22
33
  "sideEffects": false,
23
- "scripts": {
24
- "prepublishOnly": "node --eval \"console.error('ERROR: Trying to publish a package that has been compiled by Ivy. This is not allowed.\\nPlease delete and rebuild the package, without compiling with Ivy, before attempting to publish.\\n')\" && exit 1"
34
+ "dependencies": {
35
+ "tslib": "^2.3.0"
25
36
  }
26
- }
37
+ }
File without changes
package/CHANGELOG.md DELETED
@@ -1,101 +0,0 @@
1
- # Changelog
2
-
3
- ## 2.2.2
4
- - Change ng-package location in IAM_SDK
5
-
6
- ## 2.2.1
7
- - Version Bump (Doesn't change anything)
8
-
9
- ## 2.2.0
10
- - Regenerated TS SDK
11
-
12
- ## 2.1.0
13
- - Add canAccessRetailBilling to PartnerPersona
14
-
15
- ## 2.0.2
16
- - Fix ssoLogin() query param encoding
17
-
18
- ## 2.0.1
19
- - Set defaults for partner 'canAccess*' attributes to false, as they should be filled in by the actual persona's attributes. This will affect the values of these fields for partner users who don't have values for these attributes, but the new behaviour matches the actual values stored in IAM.
20
-
21
- ## 2.0.0
22
- - Tree Shakeable
23
-
24
- ## 1.17.2
25
- - Rebuild SDK integrity check error with the last version.
26
-
27
- ## 1.17.1
28
- - Fix TS SDK.
29
-
30
- ## 1.17.0
31
- - Add ListUser sorting by LastLoginColumn
32
-
33
- ## 1.16.0
34
- - Add canAccessAutomations to PartnerPersona
35
-
36
- ## 1.15.2
37
- - Add account_group PersonaType
38
-
39
- ## 1.14.0
40
- - Add `profilePicture` to DigitalAgent
41
-
42
- ## 1.13.0
43
- - Expose HostService so that external users can override environment if needed
44
-
45
- ## 1.12.0
46
- - Add `DeleteUser`
47
-
48
- ## 1.11.0
49
- - Add `AddMultiUserRestriction`
50
- - Add `RemoveMultiUserRestriction`
51
- - Add `CreateExternalID`
52
- - Add `GetMultiExternalID`
53
- - Add user Identifier to `AddKey` and `RemoveKey`
54
- - Return public_keys on User
55
-
56
- ## 1.10.1
57
- - Fix sessionID not being returned during `login`
58
- - Microservice returns object with key `session_id` not `sessionId`
59
-
60
- ## 1.10.0
61
- - Updated ListUsers endpoint with search and sort.
62
-
63
- ## 1.9.0
64
- - Add additional fields to the Partner Persona that are already in the attributes.
65
-
66
- ## 1.8.0
67
- - Expose the fromPersona method in the SDK
68
-
69
- ## 1.7.0
70
- - Add new Token UserIdentifier
71
-
72
- ## 1.6.0
73
- - Updated the SDK with addition of roles to the Users returned in ListUsers
74
-
75
- ## 1.5.0
76
- - Add algorithm type to AddKey, add client_key option on GetSessionForUser
77
-
78
- ## 1.4.1
79
- - Fix serializing namespace on ListUsers
80
-
81
- ## 1.4.0
82
- - Add UserFilter to the ListUsers function
83
-
84
- ## 1.3.1
85
- - Add userId to BasePersona
86
-
87
- ## 1.3.0
88
- - Add listUsers function to IAMService
89
-
90
- ## 1.2.1
91
- - Fix null injector error by providing IamHttpApiService
92
-
93
- ## 1.2.0
94
- - Add listSecurityLogs function to IAMService
95
-
96
- ## 1.1.0
97
- - Add getMultiUser function to IAMService
98
-
99
- ## 1.0.0
100
- - Transferred package from [vendasta/core](https://github.com/vendasta/frontend/blob/master/angular/projects/core/iam/CHANGELOG.md)
101
- - See that changelog for any prior changes