@ignos/api-client 20250805.0.12275-alpha → 20250805.0.12279-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.
@@ -2624,7 +2624,7 @@ export interface IWorkordersClient {
2624
2624
  */
2625
2625
  deleteWorkOrderMappings(): Promise<void>;
2626
2626
  getDiscussionMessages(id: string): Promise<WorkorderDiscussionMessageDto[]>;
2627
- addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<void>;
2627
+ addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<WorkorderDiscussionMessageDto>;
2628
2628
  updateMessage(id: string, messageId: string, content: string): Promise<FileResponse>;
2629
2629
  deleteMessage(id: string, messageId: string): Promise<FileResponse>;
2630
2630
  getLastRead(id: string, operationId: string | null | undefined, resourceId: string | null | undefined, userUpn: string | null | undefined): Promise<WorkorderDiscussionReadStatusDto>;
@@ -2760,8 +2760,8 @@ export declare class WorkordersClient extends AuthorizedApiBase implements IWork
2760
2760
  protected processDeleteWorkOrderMappings(response: Response): Promise<void>;
2761
2761
  getDiscussionMessages(id: string): Promise<WorkorderDiscussionMessageDto[]>;
2762
2762
  protected processGetDiscussionMessages(response: Response): Promise<WorkorderDiscussionMessageDto[]>;
2763
- addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<void>;
2764
- protected processAddDiscussionMessage(response: Response): Promise<void>;
2763
+ addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<WorkorderDiscussionMessageDto>;
2764
+ protected processAddDiscussionMessage(response: Response): Promise<WorkorderDiscussionMessageDto>;
2765
2765
  updateMessage(id: string, messageId: string, content: string): Promise<FileResponse>;
2766
2766
  protected processUpdateMessage(response: Response): Promise<FileResponse>;
2767
2767
  deleteMessage(id: string, messageId: string): Promise<FileResponse>;
@@ -22778,6 +22778,7 @@ export class WorkordersClient extends AuthorizedApiBase {
22778
22778
  method: "POST",
22779
22779
  headers: {
22780
22780
  "Content-Type": "application/json",
22781
+ "Accept": "application/json"
22781
22782
  }
22782
22783
  };
22783
22784
  return this.transformOptions(options_).then(transformedOptions_ => {
@@ -22793,9 +22794,12 @@ export class WorkordersClient extends AuthorizedApiBase {
22793
22794
  response.headers.forEach((v, k) => _headers[k] = v);
22794
22795
  }
22795
22796
  ;
22796
- if (status === 204) {
22797
+ if (status === 201) {
22797
22798
  return response.text().then((_responseText) => {
22798
- return;
22799
+ let result201 = null;
22800
+ let resultData201 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
22801
+ result201 = WorkorderDiscussionMessageDto.fromJS(resultData201);
22802
+ return result201;
22799
22803
  });
22800
22804
  }
22801
22805
  else if (status !== 200 && status !== 204) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ignos/api-client",
3
- "version": "20250805.0.12275-alpha",
3
+ "version": "20250805.0.12279-alpha",
4
4
  "description": "IGNOS API Client",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
@@ -23186,7 +23186,7 @@ export interface IWorkordersClient {
23186
23186
 
23187
23187
  getDiscussionMessages(id: string): Promise<WorkorderDiscussionMessageDto[]>;
23188
23188
 
23189
- addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<void>;
23189
+ addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<WorkorderDiscussionMessageDto>;
23190
23190
 
23191
23191
  updateMessage(id: string, messageId: string, content: string): Promise<FileResponse>;
23192
23192
 
@@ -24318,7 +24318,7 @@ export class WorkordersClient extends AuthorizedApiBase implements IWorkordersCl
24318
24318
  return Promise.resolve<WorkorderDiscussionMessageDto[]>(null as any);
24319
24319
  }
24320
24320
 
24321
- addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<void> {
24321
+ addDiscussionMessage(id: string, request: AddDiscussionMessageRequest): Promise<WorkorderDiscussionMessageDto> {
24322
24322
  let url_ = this.baseUrl + "/erp/workorders/{id}/discussion";
24323
24323
  if (id === undefined || id === null)
24324
24324
  throw new Error("The parameter 'id' must be defined.");
@@ -24332,6 +24332,7 @@ export class WorkordersClient extends AuthorizedApiBase implements IWorkordersCl
24332
24332
  method: "POST",
24333
24333
  headers: {
24334
24334
  "Content-Type": "application/json",
24335
+ "Accept": "application/json"
24335
24336
  }
24336
24337
  };
24337
24338
 
@@ -24342,19 +24343,22 @@ export class WorkordersClient extends AuthorizedApiBase implements IWorkordersCl
24342
24343
  });
24343
24344
  }
24344
24345
 
24345
- protected processAddDiscussionMessage(response: Response): Promise<void> {
24346
+ protected processAddDiscussionMessage(response: Response): Promise<WorkorderDiscussionMessageDto> {
24346
24347
  const status = response.status;
24347
24348
  let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
24348
- if (status === 204) {
24349
+ if (status === 201) {
24349
24350
  return response.text().then((_responseText) => {
24350
- return;
24351
+ let result201: any = null;
24352
+ let resultData201 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
24353
+ result201 = WorkorderDiscussionMessageDto.fromJS(resultData201);
24354
+ return result201;
24351
24355
  });
24352
24356
  } else if (status !== 200 && status !== 204) {
24353
24357
  return response.text().then((_responseText) => {
24354
24358
  return throwException("An unexpected server error occurred.", status, _responseText, _headers);
24355
24359
  });
24356
24360
  }
24357
- return Promise.resolve<void>(null as any);
24361
+ return Promise.resolve<WorkorderDiscussionMessageDto>(null as any);
24358
24362
  }
24359
24363
 
24360
24364
  updateMessage(id: string, messageId: string, content: string): Promise<FileResponse> {