@thera-hr/api-sdk 0.0.1547 → 0.0.1556

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.
Files changed (55) hide show
  1. package/api/resources/api/resources/services/resources/file/client/Client.js +4 -4
  2. package/api/resources/api/resources/test/resources/invoices/client/Client.js +1 -1
  3. package/api/resources/api/resources/thera/resources/bank/resources/bankApi/client/Client.js +4 -4
  4. package/api/resources/api/resources/thera/resources/company/resources/companyApi/client/Client.js +1 -1
  5. package/api/resources/api/resources/thera/resources/company/resources/companyW2PayrollApi/client/Client.js +1 -1
  6. package/api/resources/api/resources/thera/resources/disbursement/client/Client.d.ts +3 -0
  7. package/api/resources/api/resources/thera/resources/disbursement/client/Client.js +7 -2
  8. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/Client.d.ts +19 -0
  9. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/Client.js +100 -0
  10. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/index.d.ts +1 -0
  11. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/index.js +2 -0
  12. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/index.d.ts +1 -0
  13. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/index.js +17 -0
  14. package/api/resources/api/resources/thera/resources/disbursement/resources/disbursementWebhookApi/client/Client.js +1 -1
  15. package/api/resources/api/resources/thera/resources/disbursement/resources/index.d.ts +1 -0
  16. package/api/resources/api/resources/thera/resources/disbursement/resources/index.js +2 -1
  17. package/api/resources/api/resources/thera/resources/employment/resources/employmentApi/client/Client.d.ts +5 -1
  18. package/api/resources/api/resources/thera/resources/employment/resources/employmentApi/client/Client.js +48 -2
  19. package/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.d.ts +7 -0
  20. package/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.js +5 -0
  21. package/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.d.ts +1 -0
  22. package/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.js +1 -0
  23. package/api/resources/api/resources/thera/resources/payroll/resources/oncycleApi/client/Client.js +1 -1
  24. package/dist/api/resources/api/resources/services/resources/file/client/Client.js +4 -4
  25. package/dist/api/resources/api/resources/test/resources/invoices/client/Client.js +1 -1
  26. package/dist/api/resources/api/resources/thera/resources/bank/resources/bankApi/client/Client.js +4 -4
  27. package/dist/api/resources/api/resources/thera/resources/company/resources/companyApi/client/Client.js +1 -1
  28. package/dist/api/resources/api/resources/thera/resources/company/resources/companyW2PayrollApi/client/Client.js +1 -1
  29. package/dist/api/resources/api/resources/thera/resources/disbursement/client/Client.d.ts +3 -0
  30. package/dist/api/resources/api/resources/thera/resources/disbursement/client/Client.js +7 -2
  31. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/Client.d.ts +19 -0
  32. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/Client.js +100 -0
  33. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/index.d.ts +1 -0
  34. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/client/index.js +2 -0
  35. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/index.d.ts +1 -0
  36. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementApi/index.js +17 -0
  37. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/disbursementWebhookApi/client/Client.js +1 -1
  38. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/index.d.ts +1 -0
  39. package/dist/api/resources/api/resources/thera/resources/disbursement/resources/index.js +2 -1
  40. package/dist/api/resources/api/resources/thera/resources/employment/resources/employmentApi/client/Client.d.ts +5 -1
  41. package/dist/api/resources/api/resources/thera/resources/employment/resources/employmentApi/client/Client.js +48 -2
  42. package/dist/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.d.ts +7 -0
  43. package/dist/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.js +5 -0
  44. package/dist/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.d.ts +1 -0
  45. package/dist/api/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.js +1 -0
  46. package/dist/api/resources/api/resources/thera/resources/payroll/resources/oncycleApi/client/Client.js +1 -1
  47. package/dist/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.d.ts +12 -0
  48. package/dist/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.js +42 -0
  49. package/dist/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.d.ts +1 -0
  50. package/dist/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.js +1 -0
  51. package/package.json +1 -1
  52. package/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.d.ts +12 -0
  53. package/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/GetCurrentPayCycleResponse.js +42 -0
  54. package/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.d.ts +1 -0
  55. package/serialization/resources/api/resources/thera/resources/employment/resources/employmentApi/types/index.js +1 -0
@@ -56,7 +56,7 @@ class File_ {
56
56
  Authorization: yield this._getAuthorizationHeader(),
57
57
  "X-Fern-Language": "JavaScript",
58
58
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
59
- "X-Fern-SDK-Version": "0.0.1547",
59
+ "X-Fern-SDK-Version": "0.0.1556",
60
60
  },
61
61
  contentType: "application/json",
62
62
  body: yield serializers.api.services.AttachDocumentToEmploymentRequest.jsonOrThrow(request, {
@@ -97,7 +97,7 @@ class File_ {
97
97
  Authorization: yield this._getAuthorizationHeader(),
98
98
  "X-Fern-Language": "JavaScript",
99
99
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
100
- "X-Fern-SDK-Version": "0.0.1547",
100
+ "X-Fern-SDK-Version": "0.0.1556",
101
101
  },
102
102
  contentType: "application/json",
103
103
  body: yield serializers.api.services.DeleteDocumentFromEmploymentRequest.jsonOrThrow(request, {
@@ -138,7 +138,7 @@ class File_ {
138
138
  Authorization: yield this._getAuthorizationHeader(),
139
139
  "X-Fern-Language": "JavaScript",
140
140
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
141
- "X-Fern-SDK-Version": "0.0.1547",
141
+ "X-Fern-SDK-Version": "0.0.1556",
142
142
  },
143
143
  contentType: "application/json",
144
144
  timeoutMs: 60000,
@@ -181,7 +181,7 @@ class File_ {
181
181
  Authorization: yield this._getAuthorizationHeader(),
182
182
  "X-Fern-Language": "JavaScript",
183
183
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
184
- "X-Fern-SDK-Version": "0.0.1547",
184
+ "X-Fern-SDK-Version": "0.0.1556",
185
185
  },
186
186
  contentType: "application/json",
187
187
  timeoutMs: 60000,
@@ -56,7 +56,7 @@ class Invoices {
56
56
  Authorization: yield this._getAuthorizationHeader(),
57
57
  "X-Fern-Language": "JavaScript",
58
58
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
59
- "X-Fern-SDK-Version": "0.0.1547",
59
+ "X-Fern-SDK-Version": "0.0.1556",
60
60
  },
61
61
  contentType: "application/json",
62
62
  body: yield serializers.api.test.VoidInvoiceRequest.jsonOrThrow(request, {
@@ -65,7 +65,7 @@ class BankApi {
65
65
  Authorization: yield this._getAuthorizationHeader(),
66
66
  "X-Fern-Language": "JavaScript",
67
67
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
68
- "X-Fern-SDK-Version": "0.0.1547",
68
+ "X-Fern-SDK-Version": "0.0.1556",
69
69
  },
70
70
  contentType: "application/json",
71
71
  queryParameters: _queryParams,
@@ -112,7 +112,7 @@ class BankApi {
112
112
  Authorization: yield this._getAuthorizationHeader(),
113
113
  "X-Fern-Language": "JavaScript",
114
114
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
115
- "X-Fern-SDK-Version": "0.0.1547",
115
+ "X-Fern-SDK-Version": "0.0.1556",
116
116
  },
117
117
  contentType: "application/json",
118
118
  body: yield serializers.api.thera.bank.VerifyAccountSignupRequest.jsonOrThrow(request, {
@@ -156,7 +156,7 @@ class BankApi {
156
156
  Authorization: yield this._getAuthorizationHeader(),
157
157
  "X-Fern-Language": "JavaScript",
158
158
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
159
- "X-Fern-SDK-Version": "0.0.1547",
159
+ "X-Fern-SDK-Version": "0.0.1556",
160
160
  },
161
161
  contentType: "application/json",
162
162
  timeoutMs: 60000,
@@ -197,7 +197,7 @@ class BankApi {
197
197
  Authorization: yield this._getAuthorizationHeader(),
198
198
  "X-Fern-Language": "JavaScript",
199
199
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
200
- "X-Fern-SDK-Version": "0.0.1547",
200
+ "X-Fern-SDK-Version": "0.0.1556",
201
201
  },
202
202
  contentType: "application/json",
203
203
  body: yield serializers.api.thera.bank.VerifyMicrodepositRequest.jsonOrThrow(request, {
@@ -65,7 +65,7 @@ class CompanyApi {
65
65
  Authorization: yield this._getAuthorizationHeader(),
66
66
  "X-Fern-Language": "JavaScript",
67
67
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
68
- "X-Fern-SDK-Version": "0.0.1547",
68
+ "X-Fern-SDK-Version": "0.0.1556",
69
69
  },
70
70
  contentType: "application/json",
71
71
  queryParameters: _queryParams,
@@ -59,7 +59,7 @@ class CompanyW2PayrollApi {
59
59
  Authorization: yield this._getAuthorizationHeader(),
60
60
  "X-Fern-Language": "JavaScript",
61
61
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
62
- "X-Fern-SDK-Version": "0.0.1547",
62
+ "X-Fern-SDK-Version": "0.0.1556",
63
63
  },
64
64
  contentType: "application/json",
65
65
  body: yield serializers.api.thera.company.OnboardW2PayrollRequest.jsonOrThrow(request, {
@@ -2,6 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as core from "../../../../../../../../core";
5
+ import { DisbursementApi } from "../resources/disbursementApi/client/Client";
5
6
  import { DisbursementWebhookApi } from "../resources/disbursementWebhookApi/client/Client";
6
7
  export declare namespace Disbursement {
7
8
  interface Options {
@@ -12,6 +13,8 @@ export declare namespace Disbursement {
12
13
  export declare class Disbursement {
13
14
  protected readonly _options: Disbursement.Options;
14
15
  constructor(_options: Disbursement.Options);
16
+ protected _disbursementApi: DisbursementApi | undefined;
17
+ get disbursementApi(): DisbursementApi;
15
18
  protected _disbursementWebhookApi: DisbursementWebhookApi | undefined;
16
19
  get disbursementWebhookApi(): DisbursementWebhookApi;
17
20
  }
@@ -4,14 +4,19 @@
4
4
  */
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.Disbursement = void 0;
7
- const Client_1 = require("../resources/disbursementWebhookApi/client/Client");
7
+ const Client_1 = require("../resources/disbursementApi/client/Client");
8
+ const Client_2 = require("../resources/disbursementWebhookApi/client/Client");
8
9
  class Disbursement {
9
10
  constructor(_options) {
10
11
  this._options = _options;
11
12
  }
13
+ get disbursementApi() {
14
+ var _a;
15
+ return ((_a = this._disbursementApi) !== null && _a !== void 0 ? _a : (this._disbursementApi = new Client_1.DisbursementApi(this._options)));
16
+ }
12
17
  get disbursementWebhookApi() {
13
18
  var _a;
14
- return ((_a = this._disbursementWebhookApi) !== null && _a !== void 0 ? _a : (this._disbursementWebhookApi = new Client_1.DisbursementWebhookApi(this._options)));
19
+ return ((_a = this._disbursementWebhookApi) !== null && _a !== void 0 ? _a : (this._disbursementWebhookApi = new Client_2.DisbursementWebhookApi(this._options)));
15
20
  }
16
21
  }
17
22
  exports.Disbursement = Disbursement;
@@ -0,0 +1,19 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as core from "../../../../../../../../../../core";
5
+ export declare namespace DisbursementApi {
6
+ interface Options {
7
+ environment: core.Supplier<string>;
8
+ token?: core.Supplier<core.BearerToken | undefined>;
9
+ }
10
+ }
11
+ export declare class DisbursementApi {
12
+ protected readonly _options: DisbursementApi.Options;
13
+ constructor(_options: DisbursementApi.Options);
14
+ /**
15
+ * [Staging] Approve Invoice API
16
+ */
17
+ approveInvoice(invoiceId: string): Promise<void>;
18
+ protected _getAuthorizationHeader(): Promise<string | undefined>;
19
+ }
@@ -0,0 +1,100 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
29
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
30
+ return new (P || (P = Promise))(function (resolve, reject) {
31
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
32
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
33
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
34
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
35
+ });
36
+ };
37
+ var __importDefault = (this && this.__importDefault) || function (mod) {
38
+ return (mod && mod.__esModule) ? mod : { "default": mod };
39
+ };
40
+ Object.defineProperty(exports, "__esModule", { value: true });
41
+ exports.DisbursementApi = void 0;
42
+ const core = __importStar(require("../../../../../../../../../../core"));
43
+ const url_join_1 = __importDefault(require("url-join"));
44
+ const errors = __importStar(require("../../../../../../../../../../errors"));
45
+ class DisbursementApi {
46
+ constructor(_options) {
47
+ this._options = _options;
48
+ }
49
+ /**
50
+ * [Staging] Approve Invoice API
51
+ */
52
+ approveInvoice(invoiceId) {
53
+ return __awaiter(this, void 0, void 0, function* () {
54
+ const _response = yield core.fetcher({
55
+ url: (0, url_join_1.default)(yield core.Supplier.get(this._options.environment), `disbursement/invoices/${invoiceId}/approve`),
56
+ method: "POST",
57
+ headers: {
58
+ Authorization: yield this._getAuthorizationHeader(),
59
+ "X-Fern-Language": "JavaScript",
60
+ "X-Fern-SDK-Name": "@thera-hr/api-sdk",
61
+ "X-Fern-SDK-Version": "0.0.1556",
62
+ },
63
+ contentType: "application/json",
64
+ timeoutMs: 60000,
65
+ });
66
+ if (_response.ok) {
67
+ return;
68
+ }
69
+ if (_response.error.reason === "status-code") {
70
+ throw new errors.TheraApiError({
71
+ statusCode: _response.error.statusCode,
72
+ body: _response.error.body,
73
+ });
74
+ }
75
+ switch (_response.error.reason) {
76
+ case "non-json":
77
+ throw new errors.TheraApiError({
78
+ statusCode: _response.error.statusCode,
79
+ body: _response.error.rawBody,
80
+ });
81
+ case "timeout":
82
+ throw new errors.TheraApiTimeoutError();
83
+ case "unknown":
84
+ throw new errors.TheraApiError({
85
+ message: _response.error.errorMessage,
86
+ });
87
+ }
88
+ });
89
+ }
90
+ _getAuthorizationHeader() {
91
+ return __awaiter(this, void 0, void 0, function* () {
92
+ const bearer = yield core.Supplier.get(this._options.token);
93
+ if (bearer != null) {
94
+ return `Bearer ${bearer}`;
95
+ }
96
+ return undefined;
97
+ });
98
+ }
99
+ }
100
+ exports.DisbursementApi = DisbursementApi;
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./client"), exports);
@@ -60,7 +60,7 @@ class DisbursementWebhookApi {
60
60
  Authorization: yield this._getAuthorizationHeader(),
61
61
  "X-Fern-Language": "JavaScript",
62
62
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
63
- "X-Fern-SDK-Version": "0.0.1547",
63
+ "X-Fern-SDK-Version": "0.0.1556",
64
64
  "Thera-Webhook-Signature-Header": theraWebhookSignatureHeader,
65
65
  },
66
66
  contentType: "application/json",
@@ -1,3 +1,4 @@
1
1
  export * as disbursementWebhookApi from "./disbursementWebhookApi";
2
2
  export * from "./disbursementWebhookApi/types";
3
+ export * as disbursementApi from "./disbursementApi";
3
4
  export * from "./disbursementWebhookApi/client/requests";
@@ -26,7 +26,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
26
26
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.disbursementWebhookApi = void 0;
29
+ exports.disbursementApi = exports.disbursementWebhookApi = void 0;
30
30
  exports.disbursementWebhookApi = __importStar(require("./disbursementWebhookApi"));
31
31
  __exportStar(require("./disbursementWebhookApi/types"), exports);
32
+ exports.disbursementApi = __importStar(require("./disbursementApi"));
32
33
  __exportStar(require("./disbursementWebhookApi/client/requests"), exports);
@@ -13,8 +13,12 @@ export declare class EmploymentApi {
13
13
  protected readonly _options: EmploymentApi.Options;
14
14
  constructor(_options: EmploymentApi.Options);
15
15
  /**
16
- * In Staging. Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
16
+ * [Staging] Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
17
17
  */
18
18
  estimateContract(request: TheraApi.api.thera.employment.CreateContractEstimateRequest): Promise<TheraApi.api.thera.employment.CreateContractEstimateResponse>;
19
+ /**
20
+ * [Staging]. Get Current Cycle for this contract
21
+ */
22
+ getCurrentPayCycle(contractId: string): Promise<TheraApi.api.thera.employment.GetCurrentPayCycleResponse>;
19
23
  protected _getAuthorizationHeader(): Promise<string | undefined>;
20
24
  }
@@ -48,7 +48,7 @@ class EmploymentApi {
48
48
  this._options = _options;
49
49
  }
50
50
  /**
51
- * In Staging. Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
51
+ * [Staging] Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
52
52
  */
53
53
  estimateContract(request) {
54
54
  return __awaiter(this, void 0, void 0, function* () {
@@ -59,7 +59,7 @@ class EmploymentApi {
59
59
  Authorization: yield this._getAuthorizationHeader(),
60
60
  "X-Fern-Language": "JavaScript",
61
61
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
62
- "X-Fern-SDK-Version": "0.0.1547",
62
+ "X-Fern-SDK-Version": "0.0.1556",
63
63
  },
64
64
  contentType: "application/json",
65
65
  body: yield serializers.api.thera.employment.CreateContractEstimateRequest.jsonOrThrow(request, {
@@ -96,6 +96,52 @@ class EmploymentApi {
96
96
  }
97
97
  });
98
98
  }
99
+ /**
100
+ * [Staging]. Get Current Cycle for this contract
101
+ */
102
+ getCurrentPayCycle(contractId) {
103
+ return __awaiter(this, void 0, void 0, function* () {
104
+ const _response = yield core.fetcher({
105
+ url: (0, url_join_1.default)(yield core.Supplier.get(this._options.environment), `contracts/${contractId}/payCycle`),
106
+ method: "GET",
107
+ headers: {
108
+ Authorization: yield this._getAuthorizationHeader(),
109
+ "X-Fern-Language": "JavaScript",
110
+ "X-Fern-SDK-Name": "@thera-hr/api-sdk",
111
+ "X-Fern-SDK-Version": "0.0.1556",
112
+ },
113
+ contentType: "application/json",
114
+ timeoutMs: 60000,
115
+ });
116
+ if (_response.ok) {
117
+ return yield serializers.api.thera.employment.GetCurrentPayCycleResponse.parseOrThrow(_response.body, {
118
+ unrecognizedObjectKeys: "passthrough",
119
+ allowUnrecognizedUnionMembers: true,
120
+ allowUnrecognizedEnumValues: true,
121
+ breadcrumbsPrefix: ["response"],
122
+ });
123
+ }
124
+ if (_response.error.reason === "status-code") {
125
+ throw new errors.TheraApiError({
126
+ statusCode: _response.error.statusCode,
127
+ body: _response.error.body,
128
+ });
129
+ }
130
+ switch (_response.error.reason) {
131
+ case "non-json":
132
+ throw new errors.TheraApiError({
133
+ statusCode: _response.error.statusCode,
134
+ body: _response.error.rawBody,
135
+ });
136
+ case "timeout":
137
+ throw new errors.TheraApiTimeoutError();
138
+ case "unknown":
139
+ throw new errors.TheraApiError({
140
+ message: _response.error.errorMessage,
141
+ });
142
+ }
143
+ });
144
+ }
99
145
  _getAuthorizationHeader() {
100
146
  return __awaiter(this, void 0, void 0, function* () {
101
147
  const bearer = yield core.Supplier.get(this._options.token);
@@ -0,0 +1,7 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as TheraApi from "../../../../../../../../..";
5
+ export interface GetCurrentPayCycleResponse {
6
+ payCycle: TheraApi.api.thera.employment.PayCycleEstimate;
7
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +1,4 @@
1
+ export * from "./GetCurrentPayCycleResponse";
1
2
  export * from "./CreateContractEstimateRequest";
2
3
  export * from "./ContractEstimateRequest";
3
4
  export * from "./PayCycleEstimateRequest";
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./GetCurrentPayCycleResponse"), exports);
17
18
  __exportStar(require("./CreateContractEstimateRequest"), exports);
18
19
  __exportStar(require("./ContractEstimateRequest"), exports);
19
20
  __exportStar(require("./PayCycleEstimateRequest"), exports);
@@ -59,7 +59,7 @@ class OncycleApi {
59
59
  Authorization: yield this._getAuthorizationHeader(),
60
60
  "X-Fern-Language": "JavaScript",
61
61
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
62
- "X-Fern-SDK-Version": "0.0.1547",
62
+ "X-Fern-SDK-Version": "0.0.1556",
63
63
  },
64
64
  contentType: "application/json",
65
65
  timeoutMs: 60000,
@@ -56,7 +56,7 @@ class File_ {
56
56
  Authorization: yield this._getAuthorizationHeader(),
57
57
  "X-Fern-Language": "JavaScript",
58
58
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
59
- "X-Fern-SDK-Version": "0.0.1547",
59
+ "X-Fern-SDK-Version": "0.0.1556",
60
60
  },
61
61
  contentType: "application/json",
62
62
  body: yield serializers.api.services.AttachDocumentToEmploymentRequest.jsonOrThrow(request, {
@@ -97,7 +97,7 @@ class File_ {
97
97
  Authorization: yield this._getAuthorizationHeader(),
98
98
  "X-Fern-Language": "JavaScript",
99
99
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
100
- "X-Fern-SDK-Version": "0.0.1547",
100
+ "X-Fern-SDK-Version": "0.0.1556",
101
101
  },
102
102
  contentType: "application/json",
103
103
  body: yield serializers.api.services.DeleteDocumentFromEmploymentRequest.jsonOrThrow(request, {
@@ -138,7 +138,7 @@ class File_ {
138
138
  Authorization: yield this._getAuthorizationHeader(),
139
139
  "X-Fern-Language": "JavaScript",
140
140
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
141
- "X-Fern-SDK-Version": "0.0.1547",
141
+ "X-Fern-SDK-Version": "0.0.1556",
142
142
  },
143
143
  contentType: "application/json",
144
144
  timeoutMs: 60000,
@@ -181,7 +181,7 @@ class File_ {
181
181
  Authorization: yield this._getAuthorizationHeader(),
182
182
  "X-Fern-Language": "JavaScript",
183
183
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
184
- "X-Fern-SDK-Version": "0.0.1547",
184
+ "X-Fern-SDK-Version": "0.0.1556",
185
185
  },
186
186
  contentType: "application/json",
187
187
  timeoutMs: 60000,
@@ -56,7 +56,7 @@ class Invoices {
56
56
  Authorization: yield this._getAuthorizationHeader(),
57
57
  "X-Fern-Language": "JavaScript",
58
58
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
59
- "X-Fern-SDK-Version": "0.0.1547",
59
+ "X-Fern-SDK-Version": "0.0.1556",
60
60
  },
61
61
  contentType: "application/json",
62
62
  body: yield serializers.api.test.VoidInvoiceRequest.jsonOrThrow(request, {
@@ -65,7 +65,7 @@ class BankApi {
65
65
  Authorization: yield this._getAuthorizationHeader(),
66
66
  "X-Fern-Language": "JavaScript",
67
67
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
68
- "X-Fern-SDK-Version": "0.0.1547",
68
+ "X-Fern-SDK-Version": "0.0.1556",
69
69
  },
70
70
  contentType: "application/json",
71
71
  queryParameters: _queryParams,
@@ -112,7 +112,7 @@ class BankApi {
112
112
  Authorization: yield this._getAuthorizationHeader(),
113
113
  "X-Fern-Language": "JavaScript",
114
114
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
115
- "X-Fern-SDK-Version": "0.0.1547",
115
+ "X-Fern-SDK-Version": "0.0.1556",
116
116
  },
117
117
  contentType: "application/json",
118
118
  body: yield serializers.api.thera.bank.VerifyAccountSignupRequest.jsonOrThrow(request, {
@@ -156,7 +156,7 @@ class BankApi {
156
156
  Authorization: yield this._getAuthorizationHeader(),
157
157
  "X-Fern-Language": "JavaScript",
158
158
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
159
- "X-Fern-SDK-Version": "0.0.1547",
159
+ "X-Fern-SDK-Version": "0.0.1556",
160
160
  },
161
161
  contentType: "application/json",
162
162
  timeoutMs: 60000,
@@ -197,7 +197,7 @@ class BankApi {
197
197
  Authorization: yield this._getAuthorizationHeader(),
198
198
  "X-Fern-Language": "JavaScript",
199
199
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
200
- "X-Fern-SDK-Version": "0.0.1547",
200
+ "X-Fern-SDK-Version": "0.0.1556",
201
201
  },
202
202
  contentType: "application/json",
203
203
  body: yield serializers.api.thera.bank.VerifyMicrodepositRequest.jsonOrThrow(request, {
@@ -65,7 +65,7 @@ class CompanyApi {
65
65
  Authorization: yield this._getAuthorizationHeader(),
66
66
  "X-Fern-Language": "JavaScript",
67
67
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
68
- "X-Fern-SDK-Version": "0.0.1547",
68
+ "X-Fern-SDK-Version": "0.0.1556",
69
69
  },
70
70
  contentType: "application/json",
71
71
  queryParameters: _queryParams,
@@ -59,7 +59,7 @@ class CompanyW2PayrollApi {
59
59
  Authorization: yield this._getAuthorizationHeader(),
60
60
  "X-Fern-Language": "JavaScript",
61
61
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
62
- "X-Fern-SDK-Version": "0.0.1547",
62
+ "X-Fern-SDK-Version": "0.0.1556",
63
63
  },
64
64
  contentType: "application/json",
65
65
  body: yield serializers.api.thera.company.OnboardW2PayrollRequest.jsonOrThrow(request, {
@@ -2,6 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as core from "../../../../../../../../core";
5
+ import { DisbursementApi } from "../resources/disbursementApi/client/Client";
5
6
  import { DisbursementWebhookApi } from "../resources/disbursementWebhookApi/client/Client";
6
7
  export declare namespace Disbursement {
7
8
  interface Options {
@@ -12,6 +13,8 @@ export declare namespace Disbursement {
12
13
  export declare class Disbursement {
13
14
  protected readonly _options: Disbursement.Options;
14
15
  constructor(_options: Disbursement.Options);
16
+ protected _disbursementApi: DisbursementApi | undefined;
17
+ get disbursementApi(): DisbursementApi;
15
18
  protected _disbursementWebhookApi: DisbursementWebhookApi | undefined;
16
19
  get disbursementWebhookApi(): DisbursementWebhookApi;
17
20
  }
@@ -4,14 +4,19 @@
4
4
  */
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.Disbursement = void 0;
7
- const Client_1 = require("../resources/disbursementWebhookApi/client/Client");
7
+ const Client_1 = require("../resources/disbursementApi/client/Client");
8
+ const Client_2 = require("../resources/disbursementWebhookApi/client/Client");
8
9
  class Disbursement {
9
10
  constructor(_options) {
10
11
  this._options = _options;
11
12
  }
13
+ get disbursementApi() {
14
+ var _a;
15
+ return ((_a = this._disbursementApi) !== null && _a !== void 0 ? _a : (this._disbursementApi = new Client_1.DisbursementApi(this._options)));
16
+ }
12
17
  get disbursementWebhookApi() {
13
18
  var _a;
14
- return ((_a = this._disbursementWebhookApi) !== null && _a !== void 0 ? _a : (this._disbursementWebhookApi = new Client_1.DisbursementWebhookApi(this._options)));
19
+ return ((_a = this._disbursementWebhookApi) !== null && _a !== void 0 ? _a : (this._disbursementWebhookApi = new Client_2.DisbursementWebhookApi(this._options)));
15
20
  }
16
21
  }
17
22
  exports.Disbursement = Disbursement;
@@ -0,0 +1,19 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as core from "../../../../../../../../../../core";
5
+ export declare namespace DisbursementApi {
6
+ interface Options {
7
+ environment: core.Supplier<string>;
8
+ token?: core.Supplier<core.BearerToken | undefined>;
9
+ }
10
+ }
11
+ export declare class DisbursementApi {
12
+ protected readonly _options: DisbursementApi.Options;
13
+ constructor(_options: DisbursementApi.Options);
14
+ /**
15
+ * [Staging] Approve Invoice API
16
+ */
17
+ approveInvoice(invoiceId: string): Promise<void>;
18
+ protected _getAuthorizationHeader(): Promise<string | undefined>;
19
+ }
@@ -0,0 +1,100 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
29
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
30
+ return new (P || (P = Promise))(function (resolve, reject) {
31
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
32
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
33
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
34
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
35
+ });
36
+ };
37
+ var __importDefault = (this && this.__importDefault) || function (mod) {
38
+ return (mod && mod.__esModule) ? mod : { "default": mod };
39
+ };
40
+ Object.defineProperty(exports, "__esModule", { value: true });
41
+ exports.DisbursementApi = void 0;
42
+ const core = __importStar(require("../../../../../../../../../../core"));
43
+ const url_join_1 = __importDefault(require("url-join"));
44
+ const errors = __importStar(require("../../../../../../../../../../errors"));
45
+ class DisbursementApi {
46
+ constructor(_options) {
47
+ this._options = _options;
48
+ }
49
+ /**
50
+ * [Staging] Approve Invoice API
51
+ */
52
+ approveInvoice(invoiceId) {
53
+ return __awaiter(this, void 0, void 0, function* () {
54
+ const _response = yield core.fetcher({
55
+ url: (0, url_join_1.default)(yield core.Supplier.get(this._options.environment), `disbursement/invoices/${invoiceId}/approve`),
56
+ method: "POST",
57
+ headers: {
58
+ Authorization: yield this._getAuthorizationHeader(),
59
+ "X-Fern-Language": "JavaScript",
60
+ "X-Fern-SDK-Name": "@thera-hr/api-sdk",
61
+ "X-Fern-SDK-Version": "0.0.1556",
62
+ },
63
+ contentType: "application/json",
64
+ timeoutMs: 60000,
65
+ });
66
+ if (_response.ok) {
67
+ return;
68
+ }
69
+ if (_response.error.reason === "status-code") {
70
+ throw new errors.TheraApiError({
71
+ statusCode: _response.error.statusCode,
72
+ body: _response.error.body,
73
+ });
74
+ }
75
+ switch (_response.error.reason) {
76
+ case "non-json":
77
+ throw new errors.TheraApiError({
78
+ statusCode: _response.error.statusCode,
79
+ body: _response.error.rawBody,
80
+ });
81
+ case "timeout":
82
+ throw new errors.TheraApiTimeoutError();
83
+ case "unknown":
84
+ throw new errors.TheraApiError({
85
+ message: _response.error.errorMessage,
86
+ });
87
+ }
88
+ });
89
+ }
90
+ _getAuthorizationHeader() {
91
+ return __awaiter(this, void 0, void 0, function* () {
92
+ const bearer = yield core.Supplier.get(this._options.token);
93
+ if (bearer != null) {
94
+ return `Bearer ${bearer}`;
95
+ }
96
+ return undefined;
97
+ });
98
+ }
99
+ }
100
+ exports.DisbursementApi = DisbursementApi;
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./client"), exports);
@@ -60,7 +60,7 @@ class DisbursementWebhookApi {
60
60
  Authorization: yield this._getAuthorizationHeader(),
61
61
  "X-Fern-Language": "JavaScript",
62
62
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
63
- "X-Fern-SDK-Version": "0.0.1547",
63
+ "X-Fern-SDK-Version": "0.0.1556",
64
64
  "Thera-Webhook-Signature-Header": theraWebhookSignatureHeader,
65
65
  },
66
66
  contentType: "application/json",
@@ -1,3 +1,4 @@
1
1
  export * as disbursementWebhookApi from "./disbursementWebhookApi";
2
2
  export * from "./disbursementWebhookApi/types";
3
+ export * as disbursementApi from "./disbursementApi";
3
4
  export * from "./disbursementWebhookApi/client/requests";
@@ -26,7 +26,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
26
26
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.disbursementWebhookApi = void 0;
29
+ exports.disbursementApi = exports.disbursementWebhookApi = void 0;
30
30
  exports.disbursementWebhookApi = __importStar(require("./disbursementWebhookApi"));
31
31
  __exportStar(require("./disbursementWebhookApi/types"), exports);
32
+ exports.disbursementApi = __importStar(require("./disbursementApi"));
32
33
  __exportStar(require("./disbursementWebhookApi/client/requests"), exports);
@@ -13,8 +13,12 @@ export declare class EmploymentApi {
13
13
  protected readonly _options: EmploymentApi.Options;
14
14
  constructor(_options: EmploymentApi.Options);
15
15
  /**
16
- * In Staging. Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
16
+ * [Staging] Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
17
17
  */
18
18
  estimateContract(request: TheraApi.api.thera.employment.CreateContractEstimateRequest): Promise<TheraApi.api.thera.employment.CreateContractEstimateResponse>;
19
+ /**
20
+ * [Staging]. Get Current Cycle for this contract
21
+ */
22
+ getCurrentPayCycle(contractId: string): Promise<TheraApi.api.thera.employment.GetCurrentPayCycleResponse>;
19
23
  protected _getAuthorizationHeader(): Promise<string | undefined>;
20
24
  }
@@ -48,7 +48,7 @@ class EmploymentApi {
48
48
  this._options = _options;
49
49
  }
50
50
  /**
51
- * In Staging. Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
51
+ * [Staging] Get estimate for this contract (cycle date, list of cycles, etc) based on provided paycycle
52
52
  */
53
53
  estimateContract(request) {
54
54
  return __awaiter(this, void 0, void 0, function* () {
@@ -59,7 +59,7 @@ class EmploymentApi {
59
59
  Authorization: yield this._getAuthorizationHeader(),
60
60
  "X-Fern-Language": "JavaScript",
61
61
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
62
- "X-Fern-SDK-Version": "0.0.1547",
62
+ "X-Fern-SDK-Version": "0.0.1556",
63
63
  },
64
64
  contentType: "application/json",
65
65
  body: yield serializers.api.thera.employment.CreateContractEstimateRequest.jsonOrThrow(request, {
@@ -96,6 +96,52 @@ class EmploymentApi {
96
96
  }
97
97
  });
98
98
  }
99
+ /**
100
+ * [Staging]. Get Current Cycle for this contract
101
+ */
102
+ getCurrentPayCycle(contractId) {
103
+ return __awaiter(this, void 0, void 0, function* () {
104
+ const _response = yield core.fetcher({
105
+ url: (0, url_join_1.default)(yield core.Supplier.get(this._options.environment), `contracts/${contractId}/payCycle`),
106
+ method: "GET",
107
+ headers: {
108
+ Authorization: yield this._getAuthorizationHeader(),
109
+ "X-Fern-Language": "JavaScript",
110
+ "X-Fern-SDK-Name": "@thera-hr/api-sdk",
111
+ "X-Fern-SDK-Version": "0.0.1556",
112
+ },
113
+ contentType: "application/json",
114
+ timeoutMs: 60000,
115
+ });
116
+ if (_response.ok) {
117
+ return yield serializers.api.thera.employment.GetCurrentPayCycleResponse.parseOrThrow(_response.body, {
118
+ unrecognizedObjectKeys: "passthrough",
119
+ allowUnrecognizedUnionMembers: true,
120
+ allowUnrecognizedEnumValues: true,
121
+ breadcrumbsPrefix: ["response"],
122
+ });
123
+ }
124
+ if (_response.error.reason === "status-code") {
125
+ throw new errors.TheraApiError({
126
+ statusCode: _response.error.statusCode,
127
+ body: _response.error.body,
128
+ });
129
+ }
130
+ switch (_response.error.reason) {
131
+ case "non-json":
132
+ throw new errors.TheraApiError({
133
+ statusCode: _response.error.statusCode,
134
+ body: _response.error.rawBody,
135
+ });
136
+ case "timeout":
137
+ throw new errors.TheraApiTimeoutError();
138
+ case "unknown":
139
+ throw new errors.TheraApiError({
140
+ message: _response.error.errorMessage,
141
+ });
142
+ }
143
+ });
144
+ }
99
145
  _getAuthorizationHeader() {
100
146
  return __awaiter(this, void 0, void 0, function* () {
101
147
  const bearer = yield core.Supplier.get(this._options.token);
@@ -0,0 +1,7 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as TheraApi from "../../../../../../../../..";
5
+ export interface GetCurrentPayCycleResponse {
6
+ payCycle: TheraApi.api.thera.employment.PayCycleEstimate;
7
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +1,4 @@
1
+ export * from "./GetCurrentPayCycleResponse";
1
2
  export * from "./CreateContractEstimateRequest";
2
3
  export * from "./ContractEstimateRequest";
3
4
  export * from "./PayCycleEstimateRequest";
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./GetCurrentPayCycleResponse"), exports);
17
18
  __exportStar(require("./CreateContractEstimateRequest"), exports);
18
19
  __exportStar(require("./ContractEstimateRequest"), exports);
19
20
  __exportStar(require("./PayCycleEstimateRequest"), exports);
@@ -59,7 +59,7 @@ class OncycleApi {
59
59
  Authorization: yield this._getAuthorizationHeader(),
60
60
  "X-Fern-Language": "JavaScript",
61
61
  "X-Fern-SDK-Name": "@thera-hr/api-sdk",
62
- "X-Fern-SDK-Version": "0.0.1547",
62
+ "X-Fern-SDK-Version": "0.0.1556",
63
63
  },
64
64
  contentType: "application/json",
65
65
  timeoutMs: 60000,
@@ -0,0 +1,12 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../../../../../../../../..";
5
+ import * as TheraApi from "../../../../../../../../../../api";
6
+ import * as core from "../../../../../../../../../../core";
7
+ export declare const GetCurrentPayCycleResponse: core.serialization.ObjectSchema<serializers.api.thera.employment.GetCurrentPayCycleResponse.Raw, TheraApi.api.thera.employment.GetCurrentPayCycleResponse>;
8
+ export declare namespace GetCurrentPayCycleResponse {
9
+ interface Raw {
10
+ payCycle: serializers.api.thera.employment.PayCycleEstimate.Raw;
11
+ }
12
+ }
@@ -0,0 +1,42 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
29
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
30
+ return new (P || (P = Promise))(function (resolve, reject) {
31
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
32
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
33
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
34
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
35
+ });
36
+ };
37
+ Object.defineProperty(exports, "__esModule", { value: true });
38
+ exports.GetCurrentPayCycleResponse = void 0;
39
+ const core = __importStar(require("../../../../../../../../../../core"));
40
+ exports.GetCurrentPayCycleResponse = core.serialization.object({
41
+ payCycle: core.serialization.lazyObject(() => __awaiter(void 0, void 0, void 0, function* () { return (yield Promise.resolve().then(() => __importStar(require("../../../../../../../../..")))).api.thera.employment.PayCycleEstimate; })),
42
+ });
@@ -1,3 +1,4 @@
1
+ export * from "./GetCurrentPayCycleResponse";
1
2
  export * from "./CreateContractEstimateRequest";
2
3
  export * from "./ContractEstimateRequest";
3
4
  export * from "./PayCycleEstimateRequest";
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./GetCurrentPayCycleResponse"), exports);
17
18
  __exportStar(require("./CreateContractEstimateRequest"), exports);
18
19
  __exportStar(require("./ContractEstimateRequest"), exports);
19
20
  __exportStar(require("./PayCycleEstimateRequest"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thera-hr/api-sdk",
3
- "version": "0.0.1547",
3
+ "version": "0.0.1556",
4
4
  "private": false,
5
5
  "repository": "https://github.com/CarbonNYC/thera-typescript-sdk",
6
6
  "main": "./index.js",
@@ -0,0 +1,12 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../../../../../../../../..";
5
+ import * as TheraApi from "../../../../../../../../../../api";
6
+ import * as core from "../../../../../../../../../../core";
7
+ export declare const GetCurrentPayCycleResponse: core.serialization.ObjectSchema<serializers.api.thera.employment.GetCurrentPayCycleResponse.Raw, TheraApi.api.thera.employment.GetCurrentPayCycleResponse>;
8
+ export declare namespace GetCurrentPayCycleResponse {
9
+ interface Raw {
10
+ payCycle: serializers.api.thera.employment.PayCycleEstimate.Raw;
11
+ }
12
+ }
@@ -0,0 +1,42 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
29
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
30
+ return new (P || (P = Promise))(function (resolve, reject) {
31
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
32
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
33
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
34
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
35
+ });
36
+ };
37
+ Object.defineProperty(exports, "__esModule", { value: true });
38
+ exports.GetCurrentPayCycleResponse = void 0;
39
+ const core = __importStar(require("../../../../../../../../../../core"));
40
+ exports.GetCurrentPayCycleResponse = core.serialization.object({
41
+ payCycle: core.serialization.lazyObject(() => __awaiter(void 0, void 0, void 0, function* () { return (yield Promise.resolve().then(() => __importStar(require("../../../../../../../../..")))).api.thera.employment.PayCycleEstimate; })),
42
+ });
@@ -1,3 +1,4 @@
1
+ export * from "./GetCurrentPayCycleResponse";
1
2
  export * from "./CreateContractEstimateRequest";
2
3
  export * from "./ContractEstimateRequest";
3
4
  export * from "./PayCycleEstimateRequest";
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./GetCurrentPayCycleResponse"), exports);
17
18
  __exportStar(require("./CreateContractEstimateRequest"), exports);
18
19
  __exportStar(require("./ContractEstimateRequest"), exports);
19
20
  __exportStar(require("./PayCycleEstimateRequest"), exports);