UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

34 lines • 1.39 kB
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from "../../core/resource.mjs"; import { V4PagePaginationArray } from "../../core/pagination.mjs"; import { path } from "../../internal/utils/path.mjs"; export var BaseEvaluationTypes = /* @__PURE__ */ (() => { class BaseEvaluationTypes extends APIResource { /** * Lists the evaluator types that evaluations can use to score AI Gateway * responses. Evaluations are deprecated and unavailable to new accounts. * * @example * ```ts * // Automatically fetches more pages as needed. * for await (const evaluationTypeListResponse of client.aiGateway.evaluationTypes.list( * { account_id: '0d37909e38d3e99c29fa2cd343ac421a' }, * )) { * // ... * } * ``` */ list(params, options) { const { account_id, ...query } = params; return this._client.getAPIList(path `/accounts/${account_id}/ai-gateway/evaluation-types`, (V4PagePaginationArray), { query, ...options }); } } BaseEvaluationTypes._key = Object.freeze([ 'aiGateway', 'evaluationTypes', ]); return BaseEvaluationTypes; })(); export class EvaluationTypes extends BaseEvaluationTypes { } //# sourceMappingURL=evaluation-types.mjs.map