import { BridgeContext } from "../runtime/global"; export interface IRequest { url?: string; method?: "get" | "post" | "put" | "delete"; headers?: { [index: string]: string; }; params?: { [index: string]: string; }; data?: object | string; timeout?: number; } export interface IResponse { data: any; status: number; headers?: { [index: string]: string; }; } export declare function network(context: BridgeContext): { request: (config: IRequest) => Promise; get: (url: string, config?: IRequest | undefined) => Promise; post: (url: string, data?: string | object | undefined, config?: IRequest | undefined) => Promise; put: (url: string, data?: string | object | undefined, config?: IRequest | undefined) => Promise; delete: (url: string, data?: string | object | undefined, config?: IRequest | undefined) => Promise; };