starta.apiclient 1.37.970 → 1.37.981

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.
@@ -16,13 +16,13 @@ export default class Organizations {
16
16
  index({ searchTerm }: {
17
17
  searchTerm?: string;
18
18
  }): Promise<import("../../types").StartaResponse>;
19
- create(account: any, { login, name, currency, timeZone, orgType, country }: {
19
+ create(account: any, { login, name, currency, timeZone, orgType, countryIso2 }: {
20
20
  login: any;
21
21
  name: any;
22
22
  currency: any;
23
23
  timeZone: any;
24
24
  orgType: any;
25
- country: any;
25
+ countryIso2: any;
26
26
  }): Promise<import("../../types").StartaResponse>;
27
27
  update(account: any, { name, timeZone }: {
28
28
  name: any;
@@ -24,11 +24,11 @@ var Organizations = /** @class */ (function () {
24
24
  });
25
25
  };
26
26
  Organizations.prototype.create = function (account, _a) {
27
- var login = _a.login, name = _a.name, currency = _a.currency, timeZone = _a.timeZone, orgType = _a.orgType, country = _a.country;
27
+ var login = _a.login, name = _a.name, currency = _a.currency, timeZone = _a.timeZone, orgType = _a.orgType, countryIso2 = _a.countryIso2;
28
28
  return this._requestRunner.performRequest({
29
29
  url: "accounts/".concat(account, "/organizations"),
30
30
  method: 'POST',
31
- body: { login: login, name: name, currency: currency, timeZone: timeZone, orgType: orgType, country: country },
31
+ body: { login: login, name: name, currency: currency, timeZone: timeZone, orgType: orgType, countryIso2: countryIso2 },
32
32
  });
33
33
  };
34
34
  Organizations.prototype.update = function (account, _a) {
@@ -20,7 +20,7 @@ export default class Orders {
20
20
  scheduleId: any;
21
21
  }): Promise<import("../../types").StartaResponse>;
22
22
  get(organizationLogin: any, orderId: any): Promise<import("../../types").StartaResponse>;
23
- add(organizationLogin: any, { product: { type, id, executor }, starttime, endtime, customerId, scheduleId, status, repeatSettings }: {
23
+ add(organizationLogin: any, { product: { type, id, executor }, starttime, endtime, customerId, scheduleId, status }: {
24
24
  product: {
25
25
  type: any;
26
26
  id: any;
@@ -31,9 +31,8 @@ export default class Orders {
31
31
  customerId: any;
32
32
  scheduleId?: any;
33
33
  status?: OrderStatus;
34
- repeatSettings?: OrderRepeatSettings;
35
34
  }): Promise<import("../../types").StartaResponse>;
36
- update(organizationLogin: any, orderId: any, { product: { type, id, executor }, starttime, endtime, customerId, scheduleId, status, repeatSettings }: {
35
+ update(organizationLogin: any, orderId: any, { product: { type, id, executor }, starttime, endtime, customerId, scheduleId, status }: {
37
36
  product: {
38
37
  type: any;
39
38
  id: any;
@@ -44,7 +43,7 @@ export default class Orders {
44
43
  customerId: any;
45
44
  scheduleId?: any;
46
45
  status?: OrderStatus;
47
- repeatSettings?: OrderRepeatSettings;
48
46
  }): Promise<import("../../types").StartaResponse>;
47
+ setRepeatSettings(organizationLogin: any, orderId: any, repeatSettings: OrderRepeatSettings): Promise<import("../../types").StartaResponse>;
49
48
  delete(organizationLogin: any, orderId: any): Promise<import("../../types").StartaResponse>;
50
49
  }
@@ -37,7 +37,7 @@ var Orders = /** @class */ (function () {
37
37
  });
38
38
  };
39
39
  Orders.prototype.add = function (organizationLogin, _a) {
40
- var _b = _a.product, type = _b.type, id = _b.id, executor = _b.executor, starttime = _a.starttime, endtime = _a.endtime, customerId = _a.customerId, scheduleId = _a.scheduleId, _c = _a.status, status = _c === void 0 ? 'new' : _c, repeatSettings = _a.repeatSettings;
40
+ var _b = _a.product, type = _b.type, id = _b.id, executor = _b.executor, starttime = _a.starttime, endtime = _a.endtime, customerId = _a.customerId, scheduleId = _a.scheduleId, _c = _a.status, status = _c === void 0 ? 'new' : _c;
41
41
  return this._requestRunner.performRequest({
42
42
  url: "accounts/".concat(organizationLogin, "/orders"),
43
43
  method: 'POST',
@@ -48,12 +48,11 @@ var Orders = /** @class */ (function () {
48
48
  customerId: customerId,
49
49
  scheduleId: scheduleId,
50
50
  status: status,
51
- repeatSettings: repeatSettings,
52
51
  },
53
52
  });
54
53
  };
55
54
  Orders.prototype.update = function (organizationLogin, orderId, _a) {
56
- var _b = _a.product, type = _b.type, id = _b.id, executor = _b.executor, starttime = _a.starttime, endtime = _a.endtime, customerId = _a.customerId, scheduleId = _a.scheduleId, status = _a.status, repeatSettings = _a.repeatSettings;
55
+ var _b = _a.product, type = _b.type, id = _b.id, executor = _b.executor, starttime = _a.starttime, endtime = _a.endtime, customerId = _a.customerId, scheduleId = _a.scheduleId, status = _a.status;
57
56
  return this._requestRunner.performRequest({
58
57
  url: "accounts/".concat(organizationLogin, "/orders/").concat(orderId),
59
58
  method: 'PUT',
@@ -64,6 +63,14 @@ var Orders = /** @class */ (function () {
64
63
  customerId: customerId,
65
64
  scheduleId: scheduleId,
66
65
  status: status,
66
+ },
67
+ });
68
+ };
69
+ Orders.prototype.setRepeatSettings = function (organizationLogin, orderId, repeatSettings) {
70
+ return this._requestRunner.performRequest({
71
+ url: "accounts/".concat(organizationLogin, "/orders/").concat(orderId, "/repeatSettings"),
72
+ method: 'PUT',
73
+ body: {
67
74
  repeatSettings: repeatSettings,
68
75
  },
69
76
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "starta.apiclient",
3
- "version": "1.37.970",
3
+ "version": "1.37.981",
4
4
  "main": "./lib/index.js",
5
5
  "description": "Wrapper for starta.one api",
6
6
  "author": "Collaboracia OÜ",