attlaz-client 1.37.2 → 1.37.6

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.
@@ -3,7 +3,7 @@ export class EntityId {
3
3
  constructor(id) {
4
4
  this.id = id;
5
5
  if (id === null || id === undefined || (id + '').length < 1) {
6
- throw new Error('Invalid id');
6
+ throw new Error('Invalid entity id (' + this.constructor.name + ')');
7
7
  }
8
8
  if ((id + '').length !== 27) {
9
9
  // console.error('Id `' + id + '` does not seem a valid KSUID (type `' + this.getIdType() + '`)');
@@ -11,7 +11,7 @@ export declare class FlowRun extends MetaDataAware {
11
11
  triggerId: string;
12
12
  priority: FlowRunPriority;
13
13
  deployId: string;
14
- logStreamId: LogStreamId;
14
+ logStreamId: LogStreamId | null;
15
15
  logLevelCount: Map<LogLevel, number>;
16
16
  logsPurged: boolean;
17
17
  static parse(rawFlowRun: ApiRecord): FlowRun;
@@ -24,7 +24,7 @@ export class FlowRun extends MetaDataAware {
24
24
  flowRun.priority = FlowRunPriority.fromString(rawFlowRun.priority);
25
25
  flowRun.triggerId = rawFlowRun.trigger;
26
26
  flowRun.deployId = rawFlowRun.deploy;
27
- flowRun.logStreamId = new LogStreamId(rawFlowRun.log_stream);
27
+ flowRun.logStreamId = rawFlowRun.log_stream === null ? null : new LogStreamId(rawFlowRun.log_stream);
28
28
  flowRun.logLevelCount = rawFlowRun.log_level_count;
29
29
  flowRun.logsPurged = Utils.isTrue(rawFlowRun.logs_purged);
30
30
  return flowRun;
@@ -1,8 +1,8 @@
1
+ import { Parameters } from '../Http/Data/Parameters.js';
2
+ import { QueryString } from '../Http/Data/QueryString.js';
1
3
  import { OAuthClient } from '../Http/OAuthClient.js';
2
4
  import { CollectionResult } from '../Model/Result/CollectionResult.js';
3
5
  import { ObjectResult } from '../Model/Result/ObjectResult.js';
4
- import { Parameters } from '../Http/Data/Parameters.js';
5
- import { QueryString } from '../Http/Data/QueryString.js';
6
6
  export declare abstract class Endpoint {
7
7
  protected httpClient: OAuthClient;
8
8
  constructor(httpClient: OAuthClient);
@@ -1,14 +1,14 @@
1
- import { CollectionResult } from '../Model/Result/CollectionResult.js';
2
- import { ObjectResult } from '../Model/Result/ObjectResult.js';
3
- import { Utils } from '../Utils.js';
4
- import { ObjectWrapper } from '../Model/Result/ObjectWrapper.js';
5
- import { DataValueCollection } from '../Model/DataValueCollection.js';
6
- import { JsonSerializable } from '../Model/JsonSerializable.js';
7
- import { LogStreamId } from '../Model/Log/LogStreamId.js';
1
+ import { ClientError } from '../Http/ClientError.js';
8
2
  import { QueryString } from '../Http/Data/QueryString.js';
9
3
  import { HttpStatus } from '../Http/HttpStatus.js';
4
+ import { DataValueCollection } from '../Model/DataValueCollection.js';
10
5
  import { ApiError } from '../Model/Error/ApiError.js';
11
- import { ClientError } from '../Http/ClientError.js';
6
+ import { JsonSerializable } from '../Model/JsonSerializable.js';
7
+ import { LogStreamId } from '../Model/Log/LogStreamId.js';
8
+ import { CollectionResult } from '../Model/Result/CollectionResult.js';
9
+ import { ObjectResult } from '../Model/Result/ObjectResult.js';
10
+ import { ObjectWrapper } from '../Model/Result/ObjectWrapper.js';
11
+ import { Utils } from '../Utils.js';
12
12
  export class Endpoint {
13
13
  httpClient;
14
14
  constructor(httpClient) {
@@ -188,7 +188,7 @@ export class Endpoint {
188
188
  return parser(wrappedData);
189
189
  }
190
190
  catch (error) {
191
- console.error('Unable to parse: ' + error.message);
191
+ console.error('Unable to parse object', { object: rawObject, error });
192
192
  }
193
193
  return null;
194
194
  }
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const VERSION = "1.37.1";
1
+ export declare const VERSION = "1.37.5";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const VERSION = "1.37.1";
1
+ export const VERSION = "1.37.5";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "attlaz-client",
3
- "version": "1.37.2",
3
+ "version": "1.37.6",
4
4
  "description": "Javascript Client to access Attlaz API",
5
5
  "types": "./dist/index.d.ts",
6
6
  "main": "./dist/index.js",