import type { IndexCreateParams, IndexMetadata, IndexMultiQueryParams, IndexMultiQueryResponse, IndexQuery, IndexQueryResult, IndexSummary, IndexWriteParams, IndexWriteResponse, AttributeSchema } from "./api-types"; import type { MedusaSearchProviderOptions } from "./options"; /** * Cloud proxy error envelope — same shape as Medusa payments. */ export declare class CloudServiceError extends Error { type: string; originalType: string; data: any; message: string; status?: number; constructor(type: string, originalType: string, data: any, message: string, status?: number); get isNotFound(): boolean; } type RequestInitWithBody = Omit & { body?: object; }; /** * Thin HTTP client for the Medusa Cloud search proxy. The provider passes * Medusa index names; Cloud maps them to upstream storage for the environment. */ export declare class MedusaSearchClient { protected readonly options_: MedusaSearchProviderOptions; constructor(options: MedusaSearchProviderOptions); index(name: string): MedusaSearchIndex; createIndex(body: IndexCreateParams): Promise; indexes(): AsyncGenerator; request(method: string, path: string, options?: RequestInitWithBody): Promise; } export declare class MedusaSearchIndex { protected readonly client_: MedusaSearchClient; protected readonly name_: string; constructor(client_: MedusaSearchClient, name_: string); protected path(suffix?: string): string; schema(): Promise>; metadata(): Promise; updateSchema(body: { schema: Record; }): Promise; write(body: IndexWriteParams): Promise; deleteAll(): Promise; query(body: IndexQuery): Promise; multiQuery(body: IndexMultiQueryParams): Promise; } export declare function validateMedusaSearchOptions(options: MedusaSearchProviderOptions): void; export {}; //# sourceMappingURL=client.d.ts.map