import cfPuppeteer, { type WorkersLaunchOptions } from "@cloudflare/puppeteer"; /** * Upload, store and serve images, videos, music, documents and other * unstructured data in your Edge-first application. */ export declare function fs(): import("../fs/fs.js").FS; /** * The `cache` function gives you access to a cache object powered by * Cloudflare Worker KV. * * Every cached key will be prefixed by `cache:` to avoid conflicts with other * keys. * * This function is memoized so the next time you call it, it will return the * same instance of the cache object. */ export declare function cache(): import("../cache/cache.js").Cache; /** * Get a Drizzle ORM instance for your Edge-first application already connected * to your D1 database. */ export declare function orm(): import("drizzle-orm/d1").DrizzleD1Database; /** * The `env` function gives you access to the environment variables in a * type-safe way. */ export declare function env(): import("../env/env.js").Env; /** * Add a global, low-latency key-value data storage to your Edge-first * application. */ export declare function kv(): import("../kv/kv.js").KV; /** * Access the request object in your Edge-first application. */ export declare function request(): import("@cloudflare/workers-types").Request>; /** * Access the AbortSignal associated with the request in your Edge-first * application. */ export declare function signal(): AbortSignal; /** * Access the headers of the request in your Edge-first application. */ export declare function headers(): import("@mjackson/headers").default; /** * Run machine learning models, such as LLMs in your Edge-first application. */ export declare function ai(): import("../ai/ai.js").AI; /** * Access the geolocation information of the request in your Edge-first * application. */ export declare function geo(): import("../geo/geo.js").Geo; /** * Enqueue for processing later any kind of payload of data. */ export declare function queue(): import("../queue/queue.js").Queue; /** * Get access to a rate limiter for your Edge-first application. * * The RateLimit object gives you an `limit` method you can call with any key * to identify the thing you want to rate limit. * * The default limit is set to 10, the default period is set to 60s, this means * by default any call to `limit` will allow 10 calls in a limit of 60s * * There's also a `reset` method that will delete the rate limit for a given * key. * * The `writeHttpMetadata` method will fill a Headers object with the necessary * headers to inform the client about the rate limit. If a Headers object is not * provided, a new one will be created and returned. * * @example * import { rateLimit } from "@edgefirst-dev/core"; * * @example * let rateLimit = rateLimit(); * * @example * let rateLimit = rateLimit({ limit: 10, period: 60 }); * * @example * let result = await rateLimit.limit({ key }); * if (result.success) return json(data); * return json(error, { status: 429 }); * * @example * let headers = await rateLimit.writeHttpMetadata(key); * if (!result.success) return json(error, { status: 429, headers }); * return json(data, { headers }); * * @example * await rateLimit.reset(key); */ export declare function rateLimit(): import("@edgefirst-dev/worker-kv-rate-limit").WorkerKVRateLimit; export declare function waitUntil(promise: Promise): void; export declare function bindings(): import("../types.js").Bindings; export declare function puppeteer(options?: WorkersLaunchOptions): Promise<{ page: cfPuppeteer.Page; browser: cfPuppeteer.Browser; }>;