@hahnpro/hpc-api 3.4.3 → 3.4.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.
@@ -27,7 +27,7 @@ export declare class FlowDeploymentService extends BaseService {
27
27
  readWritePermissions?: string[];
28
28
  tags?: string[];
29
29
  }): Promise<FlowDeployment>;
30
- subscribeToStatus(id: string, listener: (event: MessageEvent<any>) => void, errorListener?: (event: MessageEvent) => void): Promise<string>;
31
- subscribeToLogs(id: string, listener: (event: MessageEvent<any>) => void, errorListener?: (event: MessageEvent) => void): Promise<string>;
30
+ subscribeToStatus(id: string, listener: (event: MessageEvent<any>) => void, errorListener?: (event: MessageEvent) => void): Promise<any>;
31
+ subscribeToLogs(id: string, listener: (event: MessageEvent<any>) => void, errorListener?: (event: MessageEvent) => void): Promise<any>;
32
32
  }
33
33
  export {};
@@ -27,7 +27,7 @@ export declare class HttpClient {
27
27
  post: <T>(url: string, data: any, config?: AxiosRequestConfig) => Promise<T>;
28
28
  put: <T>(url: string, data: any, config?: AxiosRequestConfig) => Promise<T>;
29
29
  private request;
30
- addEventSource(url: string, listener: (event: MessageEvent) => void, errorListener?: (event: MessageEvent) => void): Promise<string>;
30
+ addEventSource(url: string, listener: (event: MessageEvent) => void, errorListener?: (event: MessageEvent) => void): Promise<any>;
31
31
  destroyEventSource(id: string): void;
32
32
  destroyAllEventSources(): void;
33
33
  getAccessToken: () => Promise<string>;
@@ -4,7 +4,7 @@ exports.HttpClient = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const axios_1 = tslib_1.__importDefault(require("axios"));
6
6
  const eventsource_1 = tslib_1.__importDefault(require("eventsource"));
7
- const crypto_1 = require("crypto");
7
+ const uuid_1 = require("uuid");
8
8
  const jose_1 = require("jose");
9
9
  const Queue_1 = require("./Queue");
10
10
  const token_set_1 = require("./token-set");
@@ -45,7 +45,7 @@ class HttpClient {
45
45
  this.requestQueue = new Queue_1.Queue({ concurrency: 1, timeout: 70000, throwOnTimeout: true });
46
46
  }
47
47
  async addEventSource(url, listener, errorListener) {
48
- const id = (0, crypto_1.randomUUID)();
48
+ const id = (0, uuid_1.v4)();
49
49
  const errListener = errorListener
50
50
  ? errorListener
51
51
  : (event) => {
@@ -99,7 +99,7 @@ class HttpClient {
99
99
  const assertionPayload = {
100
100
  iat: timestamp,
101
101
  exp: timestamp + 60,
102
- jti: (0, crypto_1.randomUUID)(),
102
+ jti: (0, uuid_1.v4)(),
103
103
  iss: this.clientId,
104
104
  sub: this.clientId,
105
105
  aud: audience,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hahnpro/hpc-api",
3
- "version": "3.4.3",
3
+ "version": "3.4.4",
4
4
  "description": "Module for easy access to the HahnPRO API",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -27,10 +27,11 @@
27
27
  "axios": "~0.27.2",
28
28
  "eventsource": "^2.0.2",
29
29
  "form-data": "^4.0.0",
30
- "jose": "^4.8.3",
30
+ "jose": "^4.9.0",
31
31
  "jwt-decode": "^3.1.2",
32
32
  "p-queue": "^6.6.2",
33
- "ts-mixer": "^6.0.1"
33
+ "ts-mixer": "^6.0.1",
34
+ "uuid": "^8.3.2"
34
35
  },
35
36
  "devDependencies": {
36
37
  "@types/eventsource": "^1.1.9",