@effect-aws/client-elasticache
v1.4.0
Published
[![npm version](https://img.shields.io/npm/v/%40effect-aws%2Fclient-elasticache?color=brightgreen&label=npm%20package)](https://www.npmjs.com/package/@effect-aws/client-elasticache) [![npm downloads](https://img.shields.io/npm/dm/%40effect-aws%2Fclient-el
Downloads
269
Readme
@effect-aws/client-elasticache
Installation
npm install --save @effect-aws/client-elasticache
Usage
With default ElastiCacheClient instance:
import { ElastiCache } from "@effect-aws/client-elasticache";
const program = ElastiCache.listTagsForResource(args);
const result = pipe(
program,
Effect.provide(ElastiCache.defaultLayer),
Effect.runPromise,
);
With custom ElastiCacheClient instance:
import { ElastiCache } from "@effect-aws/client-elasticache";
const program = ElastiCache.listTagsForResource(args);
const result = await pipe(
program,
Effect.provide(
ElastiCache.baseLayer(() => new ElastiCacheClient({ region: "eu-central-1" })),
),
Effect.runPromise,
);
With custom ElastiCacheClient configuration:
import { ElastiCache } from "@effect-aws/client-elasticache";
const program = ElastiCache.listTagsForResource(args);
const result = await pipe(
program,
Effect.provide(ElastiCache.layer({ region: "eu-central-1" })),
Effect.runPromiseExit,
);
or use ElastiCache.baseLayer((default) => new ElastiCacheClient({ ...default, region: "eu-central-1" }))