// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
import { APIResource } from 'cloudflaredev/resource';
import * as DevicesAPI from 'cloudflaredev/resources/zero-trust/devices/devices';
import * as DEXTestsAPI from 'cloudflaredev/resources/zero-trust/devices/dex-tests';
import * as NetworksAPI from 'cloudflaredev/resources/zero-trust/devices/networks';
import * as OverrideCodesAPI from 'cloudflaredev/resources/zero-trust/devices/override-codes';
import * as RevokeAPI from 'cloudflaredev/resources/zero-trust/devices/revoke';
import * as SettingsAPI from 'cloudflaredev/resources/zero-trust/devices/settings';
import * as UnrevokeAPI from 'cloudflaredev/resources/zero-trust/devices/unrevoke';
import * as PoliciesAPI from 'cloudflaredev/resources/zero-trust/devices/policies/policies';
import * as PostureAPI from 'cloudflaredev/resources/zero-trust/devices/posture/posture';
import { SinglePage } from 'cloudflaredev/pagination';
export class Devices extends APIResource {
    constructor() {
        super(...arguments);
        this.dexTests = new DEXTestsAPI.DEXTests(this._client);
        this.networks = new NetworksAPI.Networks(this._client);
        this.policies = new PoliciesAPI.Policies(this._client);
        this.posture = new PostureAPI.Posture(this._client);
        this.revoke = new RevokeAPI.Revoke(this._client);
        this.settings = new SettingsAPI.Settings(this._client);
        this.unrevoke = new UnrevokeAPI.Unrevoke(this._client);
        this.overrideCodes = new OverrideCodesAPI.OverrideCodes(this._client);
    }
    /**
     * Fetches a list of enrolled devices.
     */
    list(params, options) {
        const { account_id } = params;
        return this._client.getAPIList(`/accounts/${account_id}/devices`, DevicesSinglePage, options);
    }
    /**
     * Fetches details for a single device.
     */
    get(deviceId, params, options) {
        const { account_id } = params;
        return this._client.get(`/accounts/${account_id}/devices/${deviceId}`, options)._thenUnwrap((obj) => obj.result);
    }
}
export class DevicesSinglePage extends SinglePage {
}
(function (Devices) {
    Devices.DevicesSinglePage = DevicesAPI.DevicesSinglePage;
    Devices.DEXTests = DEXTestsAPI.DEXTests;
    Devices.SchemaHTTPSSinglePage = DEXTestsAPI.SchemaHTTPSSinglePage;
    Devices.Networks = NetworksAPI.Networks;
    Devices.DeviceNetworksSinglePage = NetworksAPI.DeviceNetworksSinglePage;
    Devices.Policies = PoliciesAPI.Policies;
    Devices.SettingsPoliciesSinglePage = PoliciesAPI.SettingsPoliciesSinglePage;
    Devices.Posture = PostureAPI.Posture;
    Devices.DevicePostureRulesSinglePage = PostureAPI.DevicePostureRulesSinglePage;
    Devices.Revoke = RevokeAPI.Revoke;
    Devices.Settings = SettingsAPI.Settings;
    Devices.Unrevoke = UnrevokeAPI.Unrevoke;
    Devices.OverrideCodes = OverrideCodesAPI.OverrideCodes;
})(Devices || (Devices = {}));
//# sourceMappingURL=devices.mjs.map