/// <reference types="vite/client" />

interface ImportMetaEnv {
  /**
   * Holds your backend base URL; use it to retrieve the URL at runtime and make calls to your backend.
   *
   * @example
   * ```js
   * import { httpClient } from '@wix/essentials';
   *
   * httpClient.fetchWithAuth(import.meta.env.BASE_API_URL + '/api-endpoint').then(res => console.log(res));
   * ```
   *
   * @see https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend-extensions/api/add-api-extensions-with-the-cli
   */
  readonly BASE_API_URL: string;
}

interface ImportMeta {
  readonly env: ImportMetaEnv;
}
