@frontegg/rest-api 3.0.117 → 3.0.118

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/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v3.0.117
1
+ /** @license Frontegg v3.0.118
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
package/node/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v3.0.117
1
+ /** @license Frontegg v3.0.118
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
@@ -7,6 +7,7 @@ Object.defineProperty(exports, "__esModule", {
7
7
  });
8
8
  exports.getHierarchyMetadata = getHierarchyMetadata;
9
9
  exports.getParentTenants = getParentTenants;
10
+ exports.getParentTenantsById = getParentTenantsById;
10
11
  exports.getSubTenants = getSubTenants;
11
12
  exports.getSubTenantsAsTree = getSubTenantsAsTree;
12
13
  exports.getTenants = getTenants;
@@ -46,6 +47,12 @@ async function getParentTenants(options) {
46
47
  });
47
48
  }
48
49
 
50
+ async function getParentTenantsById(tenantId, options) {
51
+ return (0, _fetch.Get)(`${_constants.urls.tenants.hierarchy.parents.v1}/${tenantId}`, undefined, {
52
+ headers: (0, _fetch.extractHeadersFromOptions)(options)
53
+ });
54
+ }
55
+
49
56
  async function getTenantsUsersCount(body, options) {
50
57
  return (0, _fetch.Post)(`${_constants.urls.identity.tenants.users.v1}/count`, body, {
51
58
  headers: (0, _fetch.extractHeadersFromOptions)(options)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@frontegg/rest-api",
3
- "version": "3.0.117",
3
+ "version": "3.0.118",
4
4
  "main": "./node/index.js",
5
5
  "license": "MIT",
6
6
  "dependencies": {
@@ -31,6 +31,7 @@ export declare function getSubTenantsAsTree(options?: UserJwtOptions): Promise<I
31
31
  * ``authorized user``
32
32
  */
33
33
  export declare function getParentTenants(options?: UserJwtOptions): Promise<IParentTenant[]>;
34
+ export declare function getParentTenantsById(tenantId: string, options?: UserJwtOptions): Promise<IParentTenant[]>;
34
35
  export declare function getTenantsUsersCount(body: IGetTenantsUserCountRequest, options?: UserJwtOptions): Promise<IGetTenantsUserCountResponse[]>;
35
36
  export declare function searchSubTenants(params: SearchSubTenantsParams, options?: UserJwtOptions): Promise<FronteggPaginationWrapper<SearchSubTenantsResponse>>;
36
37
  export declare function getHierarchyMetadata(params: GetHierarchyMetadataParams, options?: UserJwtOptions): Promise<GetHierarchyMetadataResponse[]>;
package/tenants/index.js CHANGED
@@ -22,6 +22,11 @@ export async function getParentTenants(options) {
22
22
  headers: extractHeadersFromOptions(options)
23
23
  });
24
24
  }
25
+ export async function getParentTenantsById(tenantId, options) {
26
+ return Get(`${urls.tenants.hierarchy.parents.v1}/${tenantId}`, undefined, {
27
+ headers: extractHeadersFromOptions(options)
28
+ });
29
+ }
25
30
  export async function getTenantsUsersCount(body, options) {
26
31
  return Post(`${urls.identity.tenants.users.v1}/count`, body, {
27
32
  headers: extractHeadersFromOptions(options)