UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

39 lines • 1.31 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.BotClass = exports.BaseBotClass = void 0; // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. const resource_1 = require("../../../../core/resource.js"); const path_1 = require("../../../../internal/utils/path.js"); var BaseBotClass = /* @__PURE__ */ (() => { class BaseBotClass extends resource_1.APIResource { /** * Retrieves the top locations, by HTTP requests, of the requested bot class. * * @example * ```ts * const botClass = * await client.radar.http.locations.botClass.get( * 'LIKELY_AUTOMATED', * ); * ``` */ get(botClass, query = {}, options) { return this._client.get((0, path_1.path) `/radar/http/top/locations/bot_class/${botClass}`, { query, ...options, })._thenUnwrap((obj) => obj.result); } } BaseBotClass._key = Object.freeze([ 'radar', 'http', 'locations', 'botClass', ]); return BaseBotClass; })(); exports.BaseBotClass = BaseBotClass; class BotClass extends BaseBotClass { } exports.BotClass = BotClass; //# sourceMappingURL=bot-class.js.map