import { DatasourceConfiguration } from '../datasource/index.js'; import { Timing } from './timing.js'; export declare class ResponseWrapper { responseMeta: ResponseMeta; data?: T; api?: T; intergrations?: Record; constructor({ data }: { data: T; }); } export declare class ApiV2WithIntegrationsResponseWrapper { api: T; integrations: Record; metadata: Record; stores: { secrets: Array; }; constructor(api: T, integrations: Record, metadata: Record, stores: { secrets: Array; }); } export declare class ResponseMeta { status: number; message: string; success?: boolean; error?: ErrorDto; timing?: Timing; constructor({ status, message, success }: { status: number; message: string; success: boolean; }); } export declare class ErrorDto { code: number | string; message: string; superblocksError?: SuperblocksError; constructor({ code, message, type }: { code: number | string; message: string; type?: SuperblocksError; }); } /** * To let UI know if http error is caused by superblocks or external * This enum is intended to provide additional information on top of general * error code and message */ export declare enum SuperblocksError { RbacUnauthorized = "RbacUnauthorized", APIKeyInvalid = "APIKeyInvalid", AuthenticatedUserNotFound = "AuthenticatedUserNotFound", UserTokenInvalid = "UserTokenInvalid", JWTExpired = "JWTExpired" } /** * Type guard to check if an object is a ResponseMeta * Works with both class instances and serialized objects (from API responses) */ export declare function isResponseMetadata(responseMetadata: unknown): responseMetadata is ResponseMeta; //# sourceMappingURL=response.d.ts.map