UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

38 lines • 1.35 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.DNS = exports.BaseDNS = void 0; // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. const resource_1 = require("../../core/resource.js"); const pagination_1 = require("../../core/pagination.js"); const path_1 = require("../../internal/utils/path.js"); var BaseDNS = /* @__PURE__ */ (() => { class BaseDNS extends resource_1.APIResource { /** * Gets a list of all the domains that have resolved to a specific IP address. * * @example * ```ts * // Automatically fetches more pages as needed. * for await (const dns of client.intel.dns.list({ * account_id: '023e105f4ecef8ad9ca31a8372d0c353', * })) { * // ... * } * ``` */ list(params, options) { const { account_id, ...query } = params; return this._client.getAPIList((0, path_1.path) `/accounts/${account_id}/intel/dns`, (pagination_1.V4PagePagination), { query, ...options, }); } } BaseDNS._key = Object.freeze(['intel', 'dns']); return BaseDNS; })(); exports.BaseDNS = BaseDNS; class DNS extends BaseDNS { } exports.DNS = DNS; //# sourceMappingURL=dns.js.map