@mergeapi/merge-node-client 2.0.0 → 2.0.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/.mock/definition/accounting/employees.yml +24 -0
- package/.mock/definition/accounting/projects.yml +24 -0
- package/Client.d.ts +6 -6
- package/Client.js +17 -17
- package/api/resources/accounting/resources/employees/client/Client.js +19 -1
- package/api/resources/accounting/resources/employees/client/requests/EmployeesListRequest.d.ts +24 -0
- package/api/resources/accounting/resources/projects/client/Client.js +19 -1
- package/api/resources/accounting/resources/projects/client/requests/ProjectsListRequest.d.ts +24 -0
- package/api/resources/index.d.ts +2 -2
- package/api/resources/index.js +3 -3
- package/dist/Client.d.ts +6 -6
- package/dist/Client.js +17 -17
- package/dist/api/resources/accounting/resources/employees/client/Client.js +19 -1
- package/dist/api/resources/accounting/resources/employees/client/requests/EmployeesListRequest.d.ts +24 -0
- package/dist/api/resources/accounting/resources/projects/client/Client.js +19 -1
- package/dist/api/resources/accounting/resources/projects/client/requests/ProjectsListRequest.d.ts +24 -0
- package/dist/api/resources/index.d.ts +2 -2
- package/dist/api/resources/index.js +3 -3
- package/dist/serialization/resources/index.d.ts +2 -2
- package/dist/serialization/resources/index.js +3 -3
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/reference.md +3146 -3146
- package/serialization/resources/index.d.ts +2 -2
- package/serialization/resources/index.js +3 -3
- package/version.d.ts +1 -1
- package/version.js +1 -1
|
@@ -14,6 +14,17 @@ service:
|
|
|
14
14
|
request:
|
|
15
15
|
name: EmployeesListRequest
|
|
16
16
|
query-parameters:
|
|
17
|
+
company_id:
|
|
18
|
+
type: optional<string>
|
|
19
|
+
docs: If provided, will only return employees for this company.
|
|
20
|
+
created_after:
|
|
21
|
+
type: optional<datetime>
|
|
22
|
+
docs: If provided, will only return objects created after this datetime.
|
|
23
|
+
created_before:
|
|
24
|
+
type: optional<datetime>
|
|
25
|
+
docs: >-
|
|
26
|
+
If provided, will only return objects created before this
|
|
27
|
+
datetime.
|
|
17
28
|
cursor:
|
|
18
29
|
type: optional<string>
|
|
19
30
|
docs: The pagination cursor value.
|
|
@@ -40,9 +51,22 @@ service:
|
|
|
40
51
|
docs: >-
|
|
41
52
|
Whether to include shell records. Shell records are empty records
|
|
42
53
|
(they may contain some metadata but all other fields are null).
|
|
54
|
+
modified_after:
|
|
55
|
+
type: optional<datetime>
|
|
56
|
+
docs: >-
|
|
57
|
+
If provided, only objects synced by Merge after this date time
|
|
58
|
+
will be returned.
|
|
59
|
+
modified_before:
|
|
60
|
+
type: optional<datetime>
|
|
61
|
+
docs: >-
|
|
62
|
+
If provided, only objects synced by Merge before this date time
|
|
63
|
+
will be returned.
|
|
43
64
|
page_size:
|
|
44
65
|
type: optional<integer>
|
|
45
66
|
docs: Number of results to return per page.
|
|
67
|
+
remote_id:
|
|
68
|
+
type: optional<string>
|
|
69
|
+
docs: The API provider's ID for the given object.
|
|
46
70
|
response:
|
|
47
71
|
docs: ''
|
|
48
72
|
type: root.PaginatedEmployeeList
|
|
@@ -31,6 +31,17 @@ service:
|
|
|
31
31
|
request:
|
|
32
32
|
name: ProjectsListRequest
|
|
33
33
|
query-parameters:
|
|
34
|
+
company_id:
|
|
35
|
+
type: optional<string>
|
|
36
|
+
docs: If provided, will only return projects for this company.
|
|
37
|
+
created_after:
|
|
38
|
+
type: optional<datetime>
|
|
39
|
+
docs: If provided, will only return objects created after this datetime.
|
|
40
|
+
created_before:
|
|
41
|
+
type: optional<datetime>
|
|
42
|
+
docs: >-
|
|
43
|
+
If provided, will only return objects created before this
|
|
44
|
+
datetime.
|
|
34
45
|
cursor:
|
|
35
46
|
type: optional<string>
|
|
36
47
|
docs: The pagination cursor value.
|
|
@@ -57,9 +68,22 @@ service:
|
|
|
57
68
|
docs: >-
|
|
58
69
|
Whether to include shell records. Shell records are empty records
|
|
59
70
|
(they may contain some metadata but all other fields are null).
|
|
71
|
+
modified_after:
|
|
72
|
+
type: optional<datetime>
|
|
73
|
+
docs: >-
|
|
74
|
+
If provided, only objects synced by Merge after this date time
|
|
75
|
+
will be returned.
|
|
76
|
+
modified_before:
|
|
77
|
+
type: optional<datetime>
|
|
78
|
+
docs: >-
|
|
79
|
+
If provided, only objects synced by Merge before this date time
|
|
80
|
+
will be returned.
|
|
60
81
|
page_size:
|
|
61
82
|
type: optional<integer>
|
|
62
83
|
docs: Number of results to return per page.
|
|
84
|
+
remote_id:
|
|
85
|
+
type: optional<string>
|
|
86
|
+
docs: The API provider's ID for the given object.
|
|
63
87
|
response:
|
|
64
88
|
docs: ''
|
|
65
89
|
type: root.PaginatedProjectList
|
package/Client.d.ts
CHANGED
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as environments from "./environments";
|
|
5
5
|
import * as core from "./core";
|
|
6
|
-
import { Ats } from "./api/resources/ats/client/Client";
|
|
7
|
-
import { Crm } from "./api/resources/crm/client/Client";
|
|
8
6
|
import { Filestorage } from "./api/resources/filestorage/client/Client";
|
|
9
7
|
import { Hris } from "./api/resources/hris/client/Client";
|
|
10
8
|
import { Ticketing } from "./api/resources/ticketing/client/Client";
|
|
9
|
+
import { Crm } from "./api/resources/crm/client/Client";
|
|
10
|
+
import { Ats } from "./api/resources/ats/client/Client";
|
|
11
11
|
import { Accounting } from "./api/resources/accounting/client/Client";
|
|
12
12
|
export declare namespace MergeClient {
|
|
13
13
|
interface Options {
|
|
@@ -36,17 +36,17 @@ export declare namespace MergeClient {
|
|
|
36
36
|
}
|
|
37
37
|
export declare class MergeClient {
|
|
38
38
|
protected readonly _options: MergeClient.Options;
|
|
39
|
-
protected _ats: Ats | undefined;
|
|
40
|
-
protected _crm: Crm | undefined;
|
|
41
39
|
protected _filestorage: Filestorage | undefined;
|
|
42
40
|
protected _hris: Hris | undefined;
|
|
43
41
|
protected _ticketing: Ticketing | undefined;
|
|
42
|
+
protected _crm: Crm | undefined;
|
|
43
|
+
protected _ats: Ats | undefined;
|
|
44
44
|
protected _accounting: Accounting | undefined;
|
|
45
45
|
constructor(_options: MergeClient.Options);
|
|
46
|
-
get ats(): Ats;
|
|
47
|
-
get crm(): Crm;
|
|
48
46
|
get filestorage(): Filestorage;
|
|
49
47
|
get hris(): Hris;
|
|
50
48
|
get ticketing(): Ticketing;
|
|
49
|
+
get crm(): Crm;
|
|
50
|
+
get ats(): Ats;
|
|
51
51
|
get accounting(): Accounting;
|
|
52
52
|
}
|
package/Client.js
CHANGED
|
@@ -39,11 +39,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
39
39
|
exports.MergeClient = void 0;
|
|
40
40
|
const core = __importStar(require("./core"));
|
|
41
41
|
const headers_js_1 = require("./core/headers.js");
|
|
42
|
-
const Client_1 = require("./api/resources/
|
|
43
|
-
const Client_2 = require("./api/resources/
|
|
44
|
-
const Client_3 = require("./api/resources/
|
|
45
|
-
const Client_4 = require("./api/resources/
|
|
46
|
-
const Client_5 = require("./api/resources/
|
|
42
|
+
const Client_1 = require("./api/resources/filestorage/client/Client");
|
|
43
|
+
const Client_2 = require("./api/resources/hris/client/Client");
|
|
44
|
+
const Client_3 = require("./api/resources/ticketing/client/Client");
|
|
45
|
+
const Client_4 = require("./api/resources/crm/client/Client");
|
|
46
|
+
const Client_5 = require("./api/resources/ats/client/Client");
|
|
47
47
|
const Client_6 = require("./api/resources/accounting/client/Client");
|
|
48
48
|
class MergeClient {
|
|
49
49
|
constructor(_options) {
|
|
@@ -51,31 +51,31 @@ class MergeClient {
|
|
|
51
51
|
"X-Account-Token": _options === null || _options === void 0 ? void 0 : _options.accountToken,
|
|
52
52
|
"X-Fern-Language": "JavaScript",
|
|
53
53
|
"X-Fern-SDK-Name": "@mergeapi/merge-node-client",
|
|
54
|
-
"X-Fern-SDK-Version": "2.0.
|
|
55
|
-
"User-Agent": "@mergeapi/merge-node-client/2.0.
|
|
54
|
+
"X-Fern-SDK-Version": "2.0.1",
|
|
55
|
+
"User-Agent": "@mergeapi/merge-node-client/2.0.1",
|
|
56
56
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
57
57
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
58
58
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
59
59
|
}
|
|
60
|
-
get
|
|
60
|
+
get filestorage() {
|
|
61
61
|
var _a;
|
|
62
|
-
return ((_a = this.
|
|
62
|
+
return ((_a = this._filestorage) !== null && _a !== void 0 ? _a : (this._filestorage = new Client_1.Filestorage(this._options)));
|
|
63
63
|
}
|
|
64
|
-
get
|
|
64
|
+
get hris() {
|
|
65
65
|
var _a;
|
|
66
|
-
return ((_a = this.
|
|
66
|
+
return ((_a = this._hris) !== null && _a !== void 0 ? _a : (this._hris = new Client_2.Hris(this._options)));
|
|
67
67
|
}
|
|
68
|
-
get
|
|
68
|
+
get ticketing() {
|
|
69
69
|
var _a;
|
|
70
|
-
return ((_a = this.
|
|
70
|
+
return ((_a = this._ticketing) !== null && _a !== void 0 ? _a : (this._ticketing = new Client_3.Ticketing(this._options)));
|
|
71
71
|
}
|
|
72
|
-
get
|
|
72
|
+
get crm() {
|
|
73
73
|
var _a;
|
|
74
|
-
return ((_a = this.
|
|
74
|
+
return ((_a = this._crm) !== null && _a !== void 0 ? _a : (this._crm = new Client_4.Crm(this._options)));
|
|
75
75
|
}
|
|
76
|
-
get
|
|
76
|
+
get ats() {
|
|
77
77
|
var _a;
|
|
78
|
-
return ((_a = this.
|
|
78
|
+
return ((_a = this._ats) !== null && _a !== void 0 ? _a : (this._ats = new Client_5.Ats(this._options)));
|
|
79
79
|
}
|
|
80
80
|
get accounting() {
|
|
81
81
|
var _a;
|
|
@@ -74,8 +74,17 @@ class Employees {
|
|
|
74
74
|
__list() {
|
|
75
75
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
76
76
|
var _a, _b, _c, _d;
|
|
77
|
-
const { cursor, expand, includeDeletedData, includeRemoteData, includeShellData, pageSize } = request;
|
|
77
|
+
const { companyId, createdAfter, createdBefore, cursor, expand, includeDeletedData, includeRemoteData, includeShellData, modifiedAfter, modifiedBefore, pageSize, remoteId, } = request;
|
|
78
78
|
const _queryParams = {};
|
|
79
|
+
if (companyId != null) {
|
|
80
|
+
_queryParams["company_id"] = companyId;
|
|
81
|
+
}
|
|
82
|
+
if (createdAfter != null) {
|
|
83
|
+
_queryParams["created_after"] = createdAfter.toISOString();
|
|
84
|
+
}
|
|
85
|
+
if (createdBefore != null) {
|
|
86
|
+
_queryParams["created_before"] = createdBefore.toISOString();
|
|
87
|
+
}
|
|
79
88
|
if (cursor != null) {
|
|
80
89
|
_queryParams["cursor"] = cursor;
|
|
81
90
|
}
|
|
@@ -91,9 +100,18 @@ class Employees {
|
|
|
91
100
|
if (includeShellData != null) {
|
|
92
101
|
_queryParams["include_shell_data"] = includeShellData.toString();
|
|
93
102
|
}
|
|
103
|
+
if (modifiedAfter != null) {
|
|
104
|
+
_queryParams["modified_after"] = modifiedAfter.toISOString();
|
|
105
|
+
}
|
|
106
|
+
if (modifiedBefore != null) {
|
|
107
|
+
_queryParams["modified_before"] = modifiedBefore.toISOString();
|
|
108
|
+
}
|
|
94
109
|
if (pageSize != null) {
|
|
95
110
|
_queryParams["page_size"] = pageSize.toString();
|
|
96
111
|
}
|
|
112
|
+
if (remoteId != null) {
|
|
113
|
+
_queryParams["remote_id"] = remoteId;
|
|
114
|
+
}
|
|
97
115
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
98
116
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.MergeEnvironment.Production, "accounting/v1/employees"),
|
|
99
117
|
method: "GET",
|
package/api/resources/accounting/resources/employees/client/requests/EmployeesListRequest.d.ts
CHANGED
|
@@ -6,6 +6,18 @@
|
|
|
6
6
|
* {}
|
|
7
7
|
*/
|
|
8
8
|
export interface EmployeesListRequest {
|
|
9
|
+
/**
|
|
10
|
+
* If provided, will only return employees for this company.
|
|
11
|
+
*/
|
|
12
|
+
companyId?: string;
|
|
13
|
+
/**
|
|
14
|
+
* If provided, will only return objects created after this datetime.
|
|
15
|
+
*/
|
|
16
|
+
createdAfter?: Date;
|
|
17
|
+
/**
|
|
18
|
+
* If provided, will only return objects created before this datetime.
|
|
19
|
+
*/
|
|
20
|
+
createdBefore?: Date;
|
|
9
21
|
/**
|
|
10
22
|
* The pagination cursor value.
|
|
11
23
|
*/
|
|
@@ -26,8 +38,20 @@ export interface EmployeesListRequest {
|
|
|
26
38
|
* Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null).
|
|
27
39
|
*/
|
|
28
40
|
includeShellData?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* If provided, only objects synced by Merge after this date time will be returned.
|
|
43
|
+
*/
|
|
44
|
+
modifiedAfter?: Date;
|
|
45
|
+
/**
|
|
46
|
+
* If provided, only objects synced by Merge before this date time will be returned.
|
|
47
|
+
*/
|
|
48
|
+
modifiedBefore?: Date;
|
|
29
49
|
/**
|
|
30
50
|
* Number of results to return per page.
|
|
31
51
|
*/
|
|
32
52
|
pageSize?: number;
|
|
53
|
+
/**
|
|
54
|
+
* The API provider's ID for the given object.
|
|
55
|
+
*/
|
|
56
|
+
remoteId?: string;
|
|
33
57
|
}
|
|
@@ -74,8 +74,17 @@ class Projects {
|
|
|
74
74
|
__list() {
|
|
75
75
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
76
76
|
var _a, _b, _c, _d;
|
|
77
|
-
const { cursor, expand, includeDeletedData, includeRemoteData, includeShellData, pageSize } = request;
|
|
77
|
+
const { companyId, createdAfter, createdBefore, cursor, expand, includeDeletedData, includeRemoteData, includeShellData, modifiedAfter, modifiedBefore, pageSize, remoteId, } = request;
|
|
78
78
|
const _queryParams = {};
|
|
79
|
+
if (companyId != null) {
|
|
80
|
+
_queryParams["company_id"] = companyId;
|
|
81
|
+
}
|
|
82
|
+
if (createdAfter != null) {
|
|
83
|
+
_queryParams["created_after"] = createdAfter.toISOString();
|
|
84
|
+
}
|
|
85
|
+
if (createdBefore != null) {
|
|
86
|
+
_queryParams["created_before"] = createdBefore.toISOString();
|
|
87
|
+
}
|
|
79
88
|
if (cursor != null) {
|
|
80
89
|
_queryParams["cursor"] = cursor;
|
|
81
90
|
}
|
|
@@ -93,9 +102,18 @@ class Projects {
|
|
|
93
102
|
if (includeShellData != null) {
|
|
94
103
|
_queryParams["include_shell_data"] = includeShellData.toString();
|
|
95
104
|
}
|
|
105
|
+
if (modifiedAfter != null) {
|
|
106
|
+
_queryParams["modified_after"] = modifiedAfter.toISOString();
|
|
107
|
+
}
|
|
108
|
+
if (modifiedBefore != null) {
|
|
109
|
+
_queryParams["modified_before"] = modifiedBefore.toISOString();
|
|
110
|
+
}
|
|
96
111
|
if (pageSize != null) {
|
|
97
112
|
_queryParams["page_size"] = pageSize.toString();
|
|
98
113
|
}
|
|
114
|
+
if (remoteId != null) {
|
|
115
|
+
_queryParams["remote_id"] = remoteId;
|
|
116
|
+
}
|
|
99
117
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
100
118
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.MergeEnvironment.Production, "accounting/v1/projects"),
|
|
101
119
|
method: "GET",
|
package/api/resources/accounting/resources/projects/client/requests/ProjectsListRequest.d.ts
CHANGED
|
@@ -7,6 +7,18 @@ import * as Merge from "../../../../../../index";
|
|
|
7
7
|
* {}
|
|
8
8
|
*/
|
|
9
9
|
export interface ProjectsListRequest {
|
|
10
|
+
/**
|
|
11
|
+
* If provided, will only return projects for this company.
|
|
12
|
+
*/
|
|
13
|
+
companyId?: string;
|
|
14
|
+
/**
|
|
15
|
+
* If provided, will only return objects created after this datetime.
|
|
16
|
+
*/
|
|
17
|
+
createdAfter?: Date;
|
|
18
|
+
/**
|
|
19
|
+
* If provided, will only return objects created before this datetime.
|
|
20
|
+
*/
|
|
21
|
+
createdBefore?: Date;
|
|
10
22
|
/**
|
|
11
23
|
* The pagination cursor value.
|
|
12
24
|
*/
|
|
@@ -27,8 +39,20 @@ export interface ProjectsListRequest {
|
|
|
27
39
|
* Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null).
|
|
28
40
|
*/
|
|
29
41
|
includeShellData?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* If provided, only objects synced by Merge after this date time will be returned.
|
|
44
|
+
*/
|
|
45
|
+
modifiedAfter?: Date;
|
|
46
|
+
/**
|
|
47
|
+
* If provided, only objects synced by Merge before this date time will be returned.
|
|
48
|
+
*/
|
|
49
|
+
modifiedBefore?: Date;
|
|
30
50
|
/**
|
|
31
51
|
* Number of results to return per page.
|
|
32
52
|
*/
|
|
33
53
|
pageSize?: number;
|
|
54
|
+
/**
|
|
55
|
+
* The API provider's ID for the given object.
|
|
56
|
+
*/
|
|
57
|
+
remoteId?: string;
|
|
34
58
|
}
|
package/api/resources/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * as ats from "./ats";
|
|
2
|
-
export * as crm from "./crm";
|
|
3
1
|
export * as filestorage from "./filestorage";
|
|
4
2
|
export * as hris from "./hris";
|
|
5
3
|
export * as ticketing from "./ticketing";
|
|
4
|
+
export * as crm from "./crm";
|
|
5
|
+
export * as ats from "./ats";
|
|
6
6
|
export * as accounting from "./accounting";
|
package/api/resources/index.js
CHANGED
|
@@ -33,10 +33,10 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
33
33
|
};
|
|
34
34
|
})();
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.accounting = exports.
|
|
37
|
-
exports.ats = __importStar(require("./ats"));
|
|
38
|
-
exports.crm = __importStar(require("./crm"));
|
|
36
|
+
exports.accounting = exports.ats = exports.crm = exports.ticketing = exports.hris = exports.filestorage = void 0;
|
|
39
37
|
exports.filestorage = __importStar(require("./filestorage"));
|
|
40
38
|
exports.hris = __importStar(require("./hris"));
|
|
41
39
|
exports.ticketing = __importStar(require("./ticketing"));
|
|
40
|
+
exports.crm = __importStar(require("./crm"));
|
|
41
|
+
exports.ats = __importStar(require("./ats"));
|
|
42
42
|
exports.accounting = __importStar(require("./accounting"));
|
package/dist/Client.d.ts
CHANGED
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as environments from "./environments";
|
|
5
5
|
import * as core from "./core";
|
|
6
|
-
import { Ats } from "./api/resources/ats/client/Client";
|
|
7
|
-
import { Crm } from "./api/resources/crm/client/Client";
|
|
8
6
|
import { Filestorage } from "./api/resources/filestorage/client/Client";
|
|
9
7
|
import { Hris } from "./api/resources/hris/client/Client";
|
|
10
8
|
import { Ticketing } from "./api/resources/ticketing/client/Client";
|
|
9
|
+
import { Crm } from "./api/resources/crm/client/Client";
|
|
10
|
+
import { Ats } from "./api/resources/ats/client/Client";
|
|
11
11
|
import { Accounting } from "./api/resources/accounting/client/Client";
|
|
12
12
|
export declare namespace MergeClient {
|
|
13
13
|
interface Options {
|
|
@@ -36,17 +36,17 @@ export declare namespace MergeClient {
|
|
|
36
36
|
}
|
|
37
37
|
export declare class MergeClient {
|
|
38
38
|
protected readonly _options: MergeClient.Options;
|
|
39
|
-
protected _ats: Ats | undefined;
|
|
40
|
-
protected _crm: Crm | undefined;
|
|
41
39
|
protected _filestorage: Filestorage | undefined;
|
|
42
40
|
protected _hris: Hris | undefined;
|
|
43
41
|
protected _ticketing: Ticketing | undefined;
|
|
42
|
+
protected _crm: Crm | undefined;
|
|
43
|
+
protected _ats: Ats | undefined;
|
|
44
44
|
protected _accounting: Accounting | undefined;
|
|
45
45
|
constructor(_options: MergeClient.Options);
|
|
46
|
-
get ats(): Ats;
|
|
47
|
-
get crm(): Crm;
|
|
48
46
|
get filestorage(): Filestorage;
|
|
49
47
|
get hris(): Hris;
|
|
50
48
|
get ticketing(): Ticketing;
|
|
49
|
+
get crm(): Crm;
|
|
50
|
+
get ats(): Ats;
|
|
51
51
|
get accounting(): Accounting;
|
|
52
52
|
}
|
package/dist/Client.js
CHANGED
|
@@ -39,11 +39,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
39
39
|
exports.MergeClient = void 0;
|
|
40
40
|
const core = __importStar(require("./core"));
|
|
41
41
|
const headers_js_1 = require("./core/headers.js");
|
|
42
|
-
const Client_1 = require("./api/resources/
|
|
43
|
-
const Client_2 = require("./api/resources/
|
|
44
|
-
const Client_3 = require("./api/resources/
|
|
45
|
-
const Client_4 = require("./api/resources/
|
|
46
|
-
const Client_5 = require("./api/resources/
|
|
42
|
+
const Client_1 = require("./api/resources/filestorage/client/Client");
|
|
43
|
+
const Client_2 = require("./api/resources/hris/client/Client");
|
|
44
|
+
const Client_3 = require("./api/resources/ticketing/client/Client");
|
|
45
|
+
const Client_4 = require("./api/resources/crm/client/Client");
|
|
46
|
+
const Client_5 = require("./api/resources/ats/client/Client");
|
|
47
47
|
const Client_6 = require("./api/resources/accounting/client/Client");
|
|
48
48
|
class MergeClient {
|
|
49
49
|
constructor(_options) {
|
|
@@ -51,31 +51,31 @@ class MergeClient {
|
|
|
51
51
|
"X-Account-Token": _options === null || _options === void 0 ? void 0 : _options.accountToken,
|
|
52
52
|
"X-Fern-Language": "JavaScript",
|
|
53
53
|
"X-Fern-SDK-Name": "@mergeapi/merge-node-client",
|
|
54
|
-
"X-Fern-SDK-Version": "2.0.
|
|
55
|
-
"User-Agent": "@mergeapi/merge-node-client/2.0.
|
|
54
|
+
"X-Fern-SDK-Version": "2.0.1",
|
|
55
|
+
"User-Agent": "@mergeapi/merge-node-client/2.0.1",
|
|
56
56
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
57
57
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
58
58
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
59
59
|
}
|
|
60
|
-
get
|
|
60
|
+
get filestorage() {
|
|
61
61
|
var _a;
|
|
62
|
-
return ((_a = this.
|
|
62
|
+
return ((_a = this._filestorage) !== null && _a !== void 0 ? _a : (this._filestorage = new Client_1.Filestorage(this._options)));
|
|
63
63
|
}
|
|
64
|
-
get
|
|
64
|
+
get hris() {
|
|
65
65
|
var _a;
|
|
66
|
-
return ((_a = this.
|
|
66
|
+
return ((_a = this._hris) !== null && _a !== void 0 ? _a : (this._hris = new Client_2.Hris(this._options)));
|
|
67
67
|
}
|
|
68
|
-
get
|
|
68
|
+
get ticketing() {
|
|
69
69
|
var _a;
|
|
70
|
-
return ((_a = this.
|
|
70
|
+
return ((_a = this._ticketing) !== null && _a !== void 0 ? _a : (this._ticketing = new Client_3.Ticketing(this._options)));
|
|
71
71
|
}
|
|
72
|
-
get
|
|
72
|
+
get crm() {
|
|
73
73
|
var _a;
|
|
74
|
-
return ((_a = this.
|
|
74
|
+
return ((_a = this._crm) !== null && _a !== void 0 ? _a : (this._crm = new Client_4.Crm(this._options)));
|
|
75
75
|
}
|
|
76
|
-
get
|
|
76
|
+
get ats() {
|
|
77
77
|
var _a;
|
|
78
|
-
return ((_a = this.
|
|
78
|
+
return ((_a = this._ats) !== null && _a !== void 0 ? _a : (this._ats = new Client_5.Ats(this._options)));
|
|
79
79
|
}
|
|
80
80
|
get accounting() {
|
|
81
81
|
var _a;
|
|
@@ -74,8 +74,17 @@ class Employees {
|
|
|
74
74
|
__list() {
|
|
75
75
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
76
76
|
var _a, _b, _c, _d;
|
|
77
|
-
const { cursor, expand, includeDeletedData, includeRemoteData, includeShellData, pageSize } = request;
|
|
77
|
+
const { companyId, createdAfter, createdBefore, cursor, expand, includeDeletedData, includeRemoteData, includeShellData, modifiedAfter, modifiedBefore, pageSize, remoteId, } = request;
|
|
78
78
|
const _queryParams = {};
|
|
79
|
+
if (companyId != null) {
|
|
80
|
+
_queryParams["company_id"] = companyId;
|
|
81
|
+
}
|
|
82
|
+
if (createdAfter != null) {
|
|
83
|
+
_queryParams["created_after"] = createdAfter.toISOString();
|
|
84
|
+
}
|
|
85
|
+
if (createdBefore != null) {
|
|
86
|
+
_queryParams["created_before"] = createdBefore.toISOString();
|
|
87
|
+
}
|
|
79
88
|
if (cursor != null) {
|
|
80
89
|
_queryParams["cursor"] = cursor;
|
|
81
90
|
}
|
|
@@ -91,9 +100,18 @@ class Employees {
|
|
|
91
100
|
if (includeShellData != null) {
|
|
92
101
|
_queryParams["include_shell_data"] = includeShellData.toString();
|
|
93
102
|
}
|
|
103
|
+
if (modifiedAfter != null) {
|
|
104
|
+
_queryParams["modified_after"] = modifiedAfter.toISOString();
|
|
105
|
+
}
|
|
106
|
+
if (modifiedBefore != null) {
|
|
107
|
+
_queryParams["modified_before"] = modifiedBefore.toISOString();
|
|
108
|
+
}
|
|
94
109
|
if (pageSize != null) {
|
|
95
110
|
_queryParams["page_size"] = pageSize.toString();
|
|
96
111
|
}
|
|
112
|
+
if (remoteId != null) {
|
|
113
|
+
_queryParams["remote_id"] = remoteId;
|
|
114
|
+
}
|
|
97
115
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
98
116
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.MergeEnvironment.Production, "accounting/v1/employees"),
|
|
99
117
|
method: "GET",
|
package/dist/api/resources/accounting/resources/employees/client/requests/EmployeesListRequest.d.ts
CHANGED
|
@@ -6,6 +6,18 @@
|
|
|
6
6
|
* {}
|
|
7
7
|
*/
|
|
8
8
|
export interface EmployeesListRequest {
|
|
9
|
+
/**
|
|
10
|
+
* If provided, will only return employees for this company.
|
|
11
|
+
*/
|
|
12
|
+
companyId?: string;
|
|
13
|
+
/**
|
|
14
|
+
* If provided, will only return objects created after this datetime.
|
|
15
|
+
*/
|
|
16
|
+
createdAfter?: Date;
|
|
17
|
+
/**
|
|
18
|
+
* If provided, will only return objects created before this datetime.
|
|
19
|
+
*/
|
|
20
|
+
createdBefore?: Date;
|
|
9
21
|
/**
|
|
10
22
|
* The pagination cursor value.
|
|
11
23
|
*/
|
|
@@ -26,8 +38,20 @@ export interface EmployeesListRequest {
|
|
|
26
38
|
* Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null).
|
|
27
39
|
*/
|
|
28
40
|
includeShellData?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* If provided, only objects synced by Merge after this date time will be returned.
|
|
43
|
+
*/
|
|
44
|
+
modifiedAfter?: Date;
|
|
45
|
+
/**
|
|
46
|
+
* If provided, only objects synced by Merge before this date time will be returned.
|
|
47
|
+
*/
|
|
48
|
+
modifiedBefore?: Date;
|
|
29
49
|
/**
|
|
30
50
|
* Number of results to return per page.
|
|
31
51
|
*/
|
|
32
52
|
pageSize?: number;
|
|
53
|
+
/**
|
|
54
|
+
* The API provider's ID for the given object.
|
|
55
|
+
*/
|
|
56
|
+
remoteId?: string;
|
|
33
57
|
}
|
|
@@ -74,8 +74,17 @@ class Projects {
|
|
|
74
74
|
__list() {
|
|
75
75
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
76
76
|
var _a, _b, _c, _d;
|
|
77
|
-
const { cursor, expand, includeDeletedData, includeRemoteData, includeShellData, pageSize } = request;
|
|
77
|
+
const { companyId, createdAfter, createdBefore, cursor, expand, includeDeletedData, includeRemoteData, includeShellData, modifiedAfter, modifiedBefore, pageSize, remoteId, } = request;
|
|
78
78
|
const _queryParams = {};
|
|
79
|
+
if (companyId != null) {
|
|
80
|
+
_queryParams["company_id"] = companyId;
|
|
81
|
+
}
|
|
82
|
+
if (createdAfter != null) {
|
|
83
|
+
_queryParams["created_after"] = createdAfter.toISOString();
|
|
84
|
+
}
|
|
85
|
+
if (createdBefore != null) {
|
|
86
|
+
_queryParams["created_before"] = createdBefore.toISOString();
|
|
87
|
+
}
|
|
79
88
|
if (cursor != null) {
|
|
80
89
|
_queryParams["cursor"] = cursor;
|
|
81
90
|
}
|
|
@@ -93,9 +102,18 @@ class Projects {
|
|
|
93
102
|
if (includeShellData != null) {
|
|
94
103
|
_queryParams["include_shell_data"] = includeShellData.toString();
|
|
95
104
|
}
|
|
105
|
+
if (modifiedAfter != null) {
|
|
106
|
+
_queryParams["modified_after"] = modifiedAfter.toISOString();
|
|
107
|
+
}
|
|
108
|
+
if (modifiedBefore != null) {
|
|
109
|
+
_queryParams["modified_before"] = modifiedBefore.toISOString();
|
|
110
|
+
}
|
|
96
111
|
if (pageSize != null) {
|
|
97
112
|
_queryParams["page_size"] = pageSize.toString();
|
|
98
113
|
}
|
|
114
|
+
if (remoteId != null) {
|
|
115
|
+
_queryParams["remote_id"] = remoteId;
|
|
116
|
+
}
|
|
99
117
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
100
118
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.MergeEnvironment.Production, "accounting/v1/projects"),
|
|
101
119
|
method: "GET",
|
package/dist/api/resources/accounting/resources/projects/client/requests/ProjectsListRequest.d.ts
CHANGED
|
@@ -7,6 +7,18 @@ import * as Merge from "../../../../../../index";
|
|
|
7
7
|
* {}
|
|
8
8
|
*/
|
|
9
9
|
export interface ProjectsListRequest {
|
|
10
|
+
/**
|
|
11
|
+
* If provided, will only return projects for this company.
|
|
12
|
+
*/
|
|
13
|
+
companyId?: string;
|
|
14
|
+
/**
|
|
15
|
+
* If provided, will only return objects created after this datetime.
|
|
16
|
+
*/
|
|
17
|
+
createdAfter?: Date;
|
|
18
|
+
/**
|
|
19
|
+
* If provided, will only return objects created before this datetime.
|
|
20
|
+
*/
|
|
21
|
+
createdBefore?: Date;
|
|
10
22
|
/**
|
|
11
23
|
* The pagination cursor value.
|
|
12
24
|
*/
|
|
@@ -27,8 +39,20 @@ export interface ProjectsListRequest {
|
|
|
27
39
|
* Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null).
|
|
28
40
|
*/
|
|
29
41
|
includeShellData?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* If provided, only objects synced by Merge after this date time will be returned.
|
|
44
|
+
*/
|
|
45
|
+
modifiedAfter?: Date;
|
|
46
|
+
/**
|
|
47
|
+
* If provided, only objects synced by Merge before this date time will be returned.
|
|
48
|
+
*/
|
|
49
|
+
modifiedBefore?: Date;
|
|
30
50
|
/**
|
|
31
51
|
* Number of results to return per page.
|
|
32
52
|
*/
|
|
33
53
|
pageSize?: number;
|
|
54
|
+
/**
|
|
55
|
+
* The API provider's ID for the given object.
|
|
56
|
+
*/
|
|
57
|
+
remoteId?: string;
|
|
34
58
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * as ats from "./ats";
|
|
2
|
-
export * as crm from "./crm";
|
|
3
1
|
export * as filestorage from "./filestorage";
|
|
4
2
|
export * as hris from "./hris";
|
|
5
3
|
export * as ticketing from "./ticketing";
|
|
4
|
+
export * as crm from "./crm";
|
|
5
|
+
export * as ats from "./ats";
|
|
6
6
|
export * as accounting from "./accounting";
|
|
@@ -33,10 +33,10 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
33
33
|
};
|
|
34
34
|
})();
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.accounting = exports.
|
|
37
|
-
exports.ats = __importStar(require("./ats"));
|
|
38
|
-
exports.crm = __importStar(require("./crm"));
|
|
36
|
+
exports.accounting = exports.ats = exports.crm = exports.ticketing = exports.hris = exports.filestorage = void 0;
|
|
39
37
|
exports.filestorage = __importStar(require("./filestorage"));
|
|
40
38
|
exports.hris = __importStar(require("./hris"));
|
|
41
39
|
exports.ticketing = __importStar(require("./ticketing"));
|
|
40
|
+
exports.crm = __importStar(require("./crm"));
|
|
41
|
+
exports.ats = __importStar(require("./ats"));
|
|
42
42
|
exports.accounting = __importStar(require("./accounting"));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * as ats from "./ats";
|
|
2
|
-
export * as crm from "./crm";
|
|
3
1
|
export * as filestorage from "./filestorage";
|
|
4
2
|
export * as hris from "./hris";
|
|
5
3
|
export * as ticketing from "./ticketing";
|
|
4
|
+
export * as crm from "./crm";
|
|
5
|
+
export * as ats from "./ats";
|
|
6
6
|
export * as accounting from "./accounting";
|