@ptkl/sdk 0.4.0 → 0.8.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/dist/index.cjs.js CHANGED
@@ -17855,6 +17855,8 @@ class PlatformBaseClient extends BaseClient {
17855
17855
  // this potentially means that it is running as dev server in local
17856
17856
  headers['X-Project-Env'] = "dev";
17857
17857
  }
17858
+ }
17859
+ if (window) {
17858
17860
  // @ts-ignore
17859
17861
  const __global_env__ = window === null || window === undefined ? undefined : window.__ENV_VARIABLES__;
17860
17862
  host = (_b = __global_env__ === null || __global_env__ === undefined ? undefined : __global_env__.API_HOST) !== null && _b !== undefined ? _b : host;
@@ -17977,6 +17979,9 @@ class Users extends PlatformBaseClient {
17977
17979
  async delete(uuid) {
17978
17980
  return await this.client.delete(`/v1/project/user/${uuid}`);
17979
17981
  }
17982
+ async permissions() {
17983
+ return await this.client.delete(`/v1/user/role/permissions`);
17984
+ }
17980
17985
  }
17981
17986
 
17982
17987
  class Apps extends PlatformBaseClient {
package/dist/index.esm.js CHANGED
@@ -45,6 +45,8 @@ class PlatformBaseClient extends BaseClient {
45
45
  // this potentially means that it is running as dev server in local
46
46
  headers['X-Project-Env'] = "dev";
47
47
  }
48
+ }
49
+ if (window) {
48
50
  // @ts-ignore
49
51
  const __global_env__ = window === null || window === undefined ? undefined : window.__ENV_VARIABLES__;
50
52
  host = (_b = __global_env__ === null || __global_env__ === undefined ? undefined : __global_env__.API_HOST) !== null && _b !== undefined ? _b : host;
@@ -167,6 +169,9 @@ class Users extends PlatformBaseClient {
167
169
  async delete(uuid) {
168
170
  return await this.client.delete(`/v1/project/user/${uuid}`);
169
171
  }
172
+ async permissions() {
173
+ return await this.client.delete(`/v1/user/role/permissions`);
174
+ }
170
175
  }
171
176
 
172
177
  class Apps extends PlatformBaseClient {
@@ -1,8 +1,5 @@
1
- (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('axios')) :
3
- typeof define === 'function' && define.amd ? define(['exports', 'axios'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.ProtokolSDK = {}, global.axios));
5
- })(this, (function (exports, axios) { 'use strict';
1
+ var ProtokolSDK = (function (exports, axios) {
2
+ 'use strict';
6
3
 
7
4
  class BaseClient {
8
5
  constructor(client) {
@@ -49,6 +46,8 @@
49
46
  // this potentially means that it is running as dev server in local
50
47
  headers['X-Project-Env'] = "dev";
51
48
  }
49
+ }
50
+ if (window) {
52
51
  // @ts-ignore
53
52
  const __global_env__ = window === null || window === undefined ? undefined : window.__ENV_VARIABLES__;
54
53
  host = (_b = __global_env__ === null || __global_env__ === undefined ? undefined : __global_env__.API_HOST) !== null && _b !== undefined ? _b : host;
@@ -171,6 +170,9 @@
171
170
  async delete(uuid) {
172
171
  return await this.client.delete(`/v1/project/user/${uuid}`);
173
172
  }
173
+ async permissions() {
174
+ return await this.client.delete(`/v1/user/role/permissions`);
175
+ }
174
176
  }
175
177
 
176
178
  class Apps extends PlatformBaseClient {
@@ -831,4 +833,6 @@
831
833
 
832
834
  Object.defineProperty(exports, '__esModule', { value: true });
833
835
 
834
- }));
836
+ return exports;
837
+
838
+ })({}, http);
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ptkl/sdk",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "scripts": {
5
5
  "build": "rollup -c",
6
6
  "docs": "typedoc"
@@ -2,4 +2,5 @@ import PlatformBaseClient from "./platformBaseClient";
2
2
  export default class Users extends PlatformBaseClient {
3
3
  invite(email: string, roles: string[]): Promise<import("axios").AxiosResponse<any, any>>;
4
4
  delete(uuid: string): Promise<import("axios").AxiosResponse<any, any>>;
5
+ permissions(): Promise<import("axios").AxiosResponse<any, any>>;
5
6
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ptkl/sdk",
3
- "version": "0.4.0",
3
+ "version": "0.8.0",
4
4
  "scripts": {
5
5
  "build": "rollup -c",
6
6
  "docs": "typedoc"