UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

40 lines 1.69 kB
"use strict"; // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. Object.defineProperty(exports, "__esModule", { value: true }); exports.TimeseriesGroups = void 0; const resource_1 = require("../../../resource.js"); const core_1 = require("../../../core.js"); class TimeseriesGroups extends resource_1.APIResource { summary(dimension, query = {}, options) { if ((0, core_1.isRequestOptions)(query)) { return this.summary(dimension, {}, query); } return this._client.get(`/radar/ai/bots/summary/${dimension}`, { query, ...options })._thenUnwrap((obj) => obj.result); } timeseries(query = {}, options) { if ((0, core_1.isRequestOptions)(query)) { return this.timeseries({}, query); } return this._client.get('/radar/ai/bots/timeseries', { query, ...options })._thenUnwrap((obj) => obj.result); } timeseriesGroups(dimension, query = {}, options) { if ((0, core_1.isRequestOptions)(query)) { return this.timeseriesGroups(dimension, {}, query); } return this._client.get(`/radar/ai/bots/timeseries_groups/${dimension}`, { query, ...options, })._thenUnwrap((obj) => obj.result); } userAgent(query = {}, options) { if ((0, core_1.isRequestOptions)(query)) { return this.userAgent({}, query); } return this._client.get('/radar/ai/bots/timeseries_groups/user_agent', { query, ...options, })._thenUnwrap((obj) => obj.result); } } exports.TimeseriesGroups = TimeseriesGroups; //# sourceMappingURL=timeseries-groups.js.map