import { R as RequesterConfig, D as Dict, I as Index$1 } from './vector-wT6XsV3D.js';
export { F as FetchResult, d as InfoResult, Q as QueryResult, c as RangeResult, a as Requester, U as UpstashRequest, b as UpstashResponse, V as Vector } from './vector-wT6XsV3D.js';

/**
 * Connection credentials for upstash vector.
 * Get them from https://console.upstash.com/vector/<uuid>
 */
type IndexConfig = {
    /**
     * UPSTASH_VECTOR_REST_URL
     */
    url?: string;
    /**
     * UPSTASH_VECTOR_REST_TOKEN
     */
    token?: string;
    /**
     * The signal will allow aborting requests on the fly.
     * For more check: https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal
     */
    signal?: AbortSignal;
} & RequesterConfig;
/**
 * Serverless vector client for upstash.
 */
declare class Index<TIndexMetadata extends Dict = Dict> extends Index$1<TIndexMetadata> {
    /**
     * Create a new vector client by providing the url and token
     *
     * @example
     * ```typescript
     * const index = new Index({
     *  url: "<UPSTASH_VECTOR_REST_URL>",
     *  token: "<UPSTASH_VECTOR_REST_TOKEN>",
     * });
     * ```
     * OR
     * This will automatically get environment variables from .env file
     * ```typescript
     * const index = new Index();
     * ```
     */
    constructor(config?: IndexConfig);
    /**
     * Create a new Upstash Vector instance from environment variables.
     *
     * Use this to automatically load connection secrets from your environment
     * variables. For instance when using the Vercel integration.
     *
     * When used on the Cloudflare Workers, you can just pass the "env" context provided by Cloudflare.
     * Else, this tries to load `UPSTASH_VECTOR_REST_URL` and `UPSTASH_VECTOR_REST_TOKEN` from
     * your environment using `process.env`.
     */
    static fromEnv(env?: {
        UPSTASH_VECTOR_REST_URL: string;
        UPSTASH_VECTOR_REST_TOKEN: string;
    }, config?: Omit<IndexConfig, "url" | "token">): Index;
}

export { Index, type IndexConfig };
