/** * @since 0.1.0 */ import type { CommandImpl, SmithyResolvedConfiguration } from "@smithy/smithy-client"; import { ServiceException as ServiceError } from "@smithy/smithy-client"; import type { Client, HandlerOptions, Logger, PaginationConfiguration, Paginator, RequestHandler } from "@smithy/types"; import type { NonEmptyReadonlyArray } from "effect/Array"; import * as Cause from "effect/Cause"; import * as Effect from "effect/Effect"; import * as Stream from "effect/Stream"; import type { TaggedException } from "./Errors.js"; import { SdkError } from "./Errors.js"; import type { HttpHandlerOptions } from "./Types.js"; /** * @since 0.3.0 * @category models */ export interface LoggerResolvedConfig { logger?: Logger; } /** * @since 0.3.0 * @category models */ export interface BaseResolvedConfig extends Required, SmithyResolvedConfiguration { requestHandler: RequestHandler; } /** * @since 0.3.0 * @category models */ export type CommandCtor = new (input: I, ...args: Array) => CommandImpl; /** * @since 0.4.0 * @category models */ export type PaginatorCtor = (config: PaginationConfiguration, input: I, ...args: Array) => Paginator; type ServiceFnOptions = { errorTags?: NonEmptyReadonlyArray; resolveClientConfig: Effect.Effect; }; /** * @since 0.1.0 * @category errors */ export declare const catchServiceExceptions: (errorTags?: NonEmptyReadonlyArray) => (e: unknown) => TaggedException | Cause.TimeoutError | SdkError; /** * @since 0.1.0 * @category constructors */ export declare const makeServiceFn: (client: Client, CommandCtor: CommandCtor, fnOptions: ServiceFnOptions) => (args: any, options?: HttpHandlerOptions) => Effect.Effect, never>; /** * @since 0.4.0 * @category constructors */ export declare const makeServiceStreamFn: (client: Client, paginateFn: PaginatorCtor, fnOptions: ServiceFnOptions) => (args: any, options?: HttpHandlerOptions) => Stream.Stream, never>; /** * @since 0.1.0 * @category constructors */ export declare const fromCommandsAndServiceFn: (commands: Record>, serviceFnMaker: (CommandCtor: CommandCtor) => ReturnType, paginators?: Record>, streamFnMaker?: (paginateFn: PaginatorCtor) => ReturnType) => Effect.Effect; /** * @since 0.1.0 * @category constructors */ export declare const fromClientAndCommands: (client: Client, commands: Record>, options: ServiceFnOptions, paginators?: Record>) => Effect.Effect; export {}; //# sourceMappingURL=Service.d.ts.map