"use strict";
/**
 * This file was auto-generated by Fern from our API Definition.
 */
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
    var ownKeys = function(o) {
        ownKeys = Object.getOwnPropertyNames || function (o) {
            var ar = [];
            for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
            return ar;
        };
        return ownKeys(o);
    };
    return function (mod) {
        if (mod && mod.__esModule) return mod;
        var result = {};
        if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
        __setModuleDefault(result, mod);
        return result;
    };
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.MergeClient = void 0;
const core = __importStar(require("./core"));
const headers_1 = require("./core/headers");
const Client_1 = require("./api/resources/ats/client/Client");
const Client_2 = require("./api/resources/filestorage/client/Client");
const Client_3 = require("./api/resources/crm/client/Client");
const Client_4 = require("./api/resources/hris/client/Client");
const Client_5 = require("./api/resources/ticketing/client/Client");
const Client_6 = require("./api/resources/accounting/client/Client");
class MergeClient {
    constructor(_options) {
        this._options = Object.assign(Object.assign({}, _options), { headers: (0, headers_1.mergeHeaders)({
                "X-Account-Token": _options === null || _options === void 0 ? void 0 : _options.accountToken,
                "X-Fern-Language": "JavaScript",
                "X-Fern-SDK-Name": "@mergeapi/merge-node-client",
                "X-Fern-SDK-Version": "2.2.0",
                "User-Agent": "@mergeapi/merge-node-client/2.2.0",
                "X-Fern-Runtime": core.RUNTIME.type,
                "X-Fern-Runtime-Version": core.RUNTIME.version,
            }, _options === null || _options === void 0 ? void 0 : _options.headers) });
    }
    get ats() {
        var _a;
        return ((_a = this._ats) !== null && _a !== void 0 ? _a : (this._ats = new Client_1.Ats(this._options)));
    }
    get filestorage() {
        var _a;
        return ((_a = this._filestorage) !== null && _a !== void 0 ? _a : (this._filestorage = new Client_2.Filestorage(this._options)));
    }
    get crm() {
        var _a;
        return ((_a = this._crm) !== null && _a !== void 0 ? _a : (this._crm = new Client_3.Crm(this._options)));
    }
    get hris() {
        var _a;
        return ((_a = this._hris) !== null && _a !== void 0 ? _a : (this._hris = new Client_4.Hris(this._options)));
    }
    get ticketing() {
        var _a;
        return ((_a = this._ticketing) !== null && _a !== void 0 ? _a : (this._ticketing = new Client_5.Ticketing(this._options)));
    }
    get accounting() {
        var _a;
        return ((_a = this._accounting) !== null && _a !== void 0 ? _a : (this._accounting = new Client_6.Accounting(this._options)));
    }
}
exports.MergeClient = MergeClient;
