@delopay/sdk 0.383.0 → 0.385.0

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.
@@ -9991,7 +9991,8 @@ var Settlement = class {
9991
9991
  );
9992
9992
  }
9993
9993
  /**
9994
- * Generate (or regenerate) the statement for one shop and calendar month.
9994
+ * Generate (or regenerate) the statement for one shop and period: a
9995
+ * calendar month by `year` and `month`, or any period by its `period_start`.
9995
9996
  *
9996
9997
  * `POST /settlement/statements/generate`
9997
9998
  */
@@ -10040,7 +10041,7 @@ var Settlement = class {
10040
10041
  options
10041
10042
  );
10042
10043
  }
10043
- /** Record a transfer against a shop's month before its statement exists. */
10044
+ /** Record a transfer against a shop's period before its statement exists. */
10044
10045
  async recordAdvance(params, options) {
10045
10046
  return this.request("POST", "/settlement/advances", {
10046
10047
  body: params,
@@ -10054,11 +10055,25 @@ var Settlement = class {
10054
10055
  profile_id: params.profile_id,
10055
10056
  year: params.year,
10056
10057
  month: params.month,
10058
+ period_start: params.period_start,
10057
10059
  test_mode: params.test_mode
10058
10060
  },
10059
10061
  ...options
10060
10062
  });
10061
10063
  }
10064
+ /**
10065
+ * A shop's statement periods, newest first: the running one and those that
10066
+ * closed in the last twelve months. Each `period_start` names its period to
10067
+ * {@link generateStatement}, {@link recordAdvance} and {@link listAdvances}.
10068
+ *
10069
+ * `GET /settlement/periods`
10070
+ */
10071
+ async listPeriods(params, options) {
10072
+ return this.request("GET", "/settlement/periods", {
10073
+ query: { profile_id: params.profile_id },
10074
+ ...options
10075
+ });
10076
+ }
10062
10077
  /**
10063
10078
  * Export a statement as PDF, or with `format` as CSV, JSON
10064
10079
  * (`StatementDocument`) or XLSX. Returns the raw bytes as a `Blob`, with
@@ -10098,6 +10113,7 @@ var Settlement = class {
10098
10113
  profile_id: params.profile_id,
10099
10114
  year: params.year,
10100
10115
  month: params.month,
10116
+ period_start: params.period_start,
10101
10117
  test_mode: params.test_mode,
10102
10118
  limit: params.limit,
10103
10119
  offset: params.offset
@@ -17321,4 +17337,4 @@ export {
17321
17337
  decodeNativePanes,
17322
17338
  encodeNativePanes
17323
17339
  };
17324
- //# sourceMappingURL=chunk-JZBJHC2M.js.map
17340
+ //# sourceMappingURL=chunk-UGIHA7A6.js.map