@ignos/api-client 20250225.0.11254 → 20250225.0.11258-alpha

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.
@@ -395,6 +395,7 @@ export interface IUtilizationClient {
395
395
  getUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined, assetId: number | null | undefined, assetExternalId: string | null | undefined): Promise<MachineUtilizationDatapointListDto>;
396
396
  getCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CompanyUtilizationDatapointListDto>;
397
397
  getCrossCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CrossCompanyUtilizationDatapointListDto>;
398
+ getLowessCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CompanyUtilizationDatapointListDto>;
398
399
  }
399
400
  export declare class UtilizationClient extends AuthorizedApiBase implements IUtilizationClient {
400
401
  private http;
@@ -413,6 +414,8 @@ export declare class UtilizationClient extends AuthorizedApiBase implements IUti
413
414
  protected processGetCompanyUtilizationDatapoints(response: Response): Promise<CompanyUtilizationDatapointListDto>;
414
415
  getCrossCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CrossCompanyUtilizationDatapointListDto>;
415
416
  protected processGetCrossCompanyUtilizationDatapoints(response: Response): Promise<CrossCompanyUtilizationDatapointListDto>;
417
+ getLowessCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CompanyUtilizationDatapointListDto>;
418
+ protected processGetLowessCompanyUtilizationDatapoints(response: Response): Promise<CompanyUtilizationDatapointListDto>;
416
419
  }
417
420
  export interface IMrbClient {
418
421
  listMrbInstances(customerOrder: string | undefined, customerOrderLine: number | null | undefined): Promise<MrbInstanceDto[]>;
@@ -2398,6 +2398,51 @@ export class UtilizationClient extends AuthorizedApiBase {
2398
2398
  }
2399
2399
  return Promise.resolve(null);
2400
2400
  }
2401
+ getLowessCompanyUtilizationDatapoints(utilizationType, startTime, endTime) {
2402
+ let url_ = this.baseUrl + "/utilization/datapoints/company/lowess?";
2403
+ if (utilizationType === null)
2404
+ throw new Error("The parameter 'utilizationType' cannot be null.");
2405
+ else if (utilizationType !== undefined)
2406
+ url_ += "utilizationType=" + encodeURIComponent("" + utilizationType) + "&";
2407
+ if (startTime !== undefined && startTime !== null)
2408
+ url_ += "startTime=" + encodeURIComponent(startTime ? "" + startTime.toISOString() : "") + "&";
2409
+ if (endTime !== undefined && endTime !== null)
2410
+ url_ += "endTime=" + encodeURIComponent(endTime ? "" + endTime.toISOString() : "") + "&";
2411
+ url_ = url_.replace(/[?&]$/, "");
2412
+ let options_ = {
2413
+ method: "GET",
2414
+ headers: {
2415
+ "Accept": "application/json"
2416
+ }
2417
+ };
2418
+ return this.transformOptions(options_).then(transformedOptions_ => {
2419
+ return this.http.fetch(url_, transformedOptions_);
2420
+ }).then((_response) => {
2421
+ return this.processGetLowessCompanyUtilizationDatapoints(_response);
2422
+ });
2423
+ }
2424
+ processGetLowessCompanyUtilizationDatapoints(response) {
2425
+ const status = response.status;
2426
+ let _headers = {};
2427
+ if (response.headers && response.headers.forEach) {
2428
+ response.headers.forEach((v, k) => _headers[k] = v);
2429
+ }
2430
+ ;
2431
+ if (status === 200) {
2432
+ return response.text().then((_responseText) => {
2433
+ let result200 = null;
2434
+ let resultData200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
2435
+ result200 = CompanyUtilizationDatapointListDto.fromJS(resultData200);
2436
+ return result200;
2437
+ });
2438
+ }
2439
+ else if (status !== 200 && status !== 204) {
2440
+ return response.text().then((_responseText) => {
2441
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
2442
+ });
2443
+ }
2444
+ return Promise.resolve(null);
2445
+ }
2401
2446
  }
2402
2447
  export class MrbClient extends AuthorizedApiBase {
2403
2448
  constructor(configuration, baseUrl, http) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ignos/api-client",
3
- "version": "20250225.0.11254",
3
+ "version": "20250225.0.11258-alpha",
4
4
  "description": "IGNOS API Client",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
@@ -2396,6 +2396,8 @@ export interface IUtilizationClient {
2396
2396
  getCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CompanyUtilizationDatapointListDto>;
2397
2397
 
2398
2398
  getCrossCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CrossCompanyUtilizationDatapointListDto>;
2399
+
2400
+ getLowessCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CompanyUtilizationDatapointListDto>;
2399
2401
  }
2400
2402
 
2401
2403
  export class UtilizationClient extends AuthorizedApiBase implements IUtilizationClient {
@@ -2632,6 +2634,50 @@ export class UtilizationClient extends AuthorizedApiBase implements IUtilization
2632
2634
  }
2633
2635
  return Promise.resolve<CrossCompanyUtilizationDatapointListDto>(null as any);
2634
2636
  }
2637
+
2638
+ getLowessCompanyUtilizationDatapoints(utilizationType: UtilizationTypeDto | undefined, startTime: Date | null | undefined, endTime: Date | null | undefined): Promise<CompanyUtilizationDatapointListDto> {
2639
+ let url_ = this.baseUrl + "/utilization/datapoints/company/lowess?";
2640
+ if (utilizationType === null)
2641
+ throw new Error("The parameter 'utilizationType' cannot be null.");
2642
+ else if (utilizationType !== undefined)
2643
+ url_ += "utilizationType=" + encodeURIComponent("" + utilizationType) + "&";
2644
+ if (startTime !== undefined && startTime !== null)
2645
+ url_ += "startTime=" + encodeURIComponent(startTime ? "" + startTime.toISOString() : "") + "&";
2646
+ if (endTime !== undefined && endTime !== null)
2647
+ url_ += "endTime=" + encodeURIComponent(endTime ? "" + endTime.toISOString() : "") + "&";
2648
+ url_ = url_.replace(/[?&]$/, "");
2649
+
2650
+ let options_: RequestInit = {
2651
+ method: "GET",
2652
+ headers: {
2653
+ "Accept": "application/json"
2654
+ }
2655
+ };
2656
+
2657
+ return this.transformOptions(options_).then(transformedOptions_ => {
2658
+ return this.http.fetch(url_, transformedOptions_);
2659
+ }).then((_response: Response) => {
2660
+ return this.processGetLowessCompanyUtilizationDatapoints(_response);
2661
+ });
2662
+ }
2663
+
2664
+ protected processGetLowessCompanyUtilizationDatapoints(response: Response): Promise<CompanyUtilizationDatapointListDto> {
2665
+ const status = response.status;
2666
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
2667
+ if (status === 200) {
2668
+ return response.text().then((_responseText) => {
2669
+ let result200: any = null;
2670
+ let resultData200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
2671
+ result200 = CompanyUtilizationDatapointListDto.fromJS(resultData200);
2672
+ return result200;
2673
+ });
2674
+ } else if (status !== 200 && status !== 204) {
2675
+ return response.text().then((_responseText) => {
2676
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
2677
+ });
2678
+ }
2679
+ return Promise.resolve<CompanyUtilizationDatapointListDto>(null as any);
2680
+ }
2635
2681
  }
2636
2682
 
2637
2683
  export interface IMrbClient {