UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

44 lines 1.72 kB
import * as Core from 'cloudflare/core'; import { APIResource } from 'cloudflare/resource'; import * as SettingsAPI from 'cloudflare/resources/workers/scripts/settings'; import * as ScriptsAPI from 'cloudflare/resources/workers/scripts/scripts'; import * as TailAPI from 'cloudflare/resources/workers/scripts/tail'; export declare class Settings extends APIResource { /** * Patch script-level settings when using * [Worker Versions](https://developers.cloudflare.com/api/operations/worker-versions-list-versions). * Includes Logpush and Tail Consumers. */ edit(scriptName: string, params: SettingEditParams, options?: Core.RequestOptions): Core.APIPromise<ScriptsAPI.ScriptSetting>; /** * Get script-level settings when using * [Worker Versions](https://developers.cloudflare.com/api/operations/worker-versions-list-versions). * Includes Logpush and Tail Consumers. */ get(scriptName: string, params: SettingGetParams, options?: Core.RequestOptions): Core.APIPromise<ScriptsAPI.ScriptSetting>; } export interface SettingEditParams { /** * Path param: Identifier */ account_id: string; /** * Body param: Whether Logpush is turned on for the Worker. */ logpush?: boolean; /** * Body param: List of Workers that will consume logs from the attached Worker. */ tail_consumers?: Array<TailAPI.ConsumerScript>; } export interface SettingGetParams { /** * Identifier */ account_id: string; } export declare namespace Settings { export import SettingEditParams = SettingsAPI.SettingEditParams; export import SettingGetParams = SettingsAPI.SettingGetParams; } //# sourceMappingURL=settings.d.ts.map