@a-cube-io/ereceipts-js-sdk 2.1.1 → 2.2.1

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
@@ -4778,7 +4778,7 @@ class PointOfSaleMapper {
4778
4778
  serialNumber: output.serial_number,
4779
4779
  status: output.status,
4780
4780
  address: AddressMapper.fromApi(output.address),
4781
- operationalStatus: output.operational_status,
4781
+ journalStatus: output.journal_status,
4782
4782
  };
4783
4783
  }
4784
4784
  static fromDetailedApiOutput(output) {
@@ -4798,6 +4798,7 @@ class PointOfSaleMapper {
4798
4798
  }
4799
4799
  }
4800
4800
 
4801
+ // this repository is used for MF1 endpoints
4801
4802
  class PointOfSaleRepositoryImpl {
4802
4803
  constructor(http) {
4803
4804
  this.http = http;
@@ -4830,6 +4831,12 @@ class PointOfSaleRepositoryImpl {
4830
4831
  const apiInput = PointOfSaleMapper.toOfflineApiInput(input);
4831
4832
  await this.http.post(`/mf1/pems/${serialNumber}/communicate-offline`, apiInput);
4832
4833
  }
4834
+ async downloadData(serialNumber) {
4835
+ const response = await this.http.get(`/mf1/pems/${serialNumber}/download-data`, {
4836
+ responseType: 'arraybuffer',
4837
+ });
4838
+ return response.data;
4839
+ }
4833
4840
  }
4834
4841
 
4835
4842
  class SupplierMapper {
@@ -4941,6 +4948,7 @@ class PemMapper {
4941
4948
  }
4942
4949
  }
4943
4950
 
4951
+ // this repository is used for MF2 endpoints
4944
4952
  class PemRepositoryImpl {
4945
4953
  constructor(http) {
4946
4954
  this.http = http;