# aws-secret

> A simple API for getting a secret from AWS's secrets manager

Latest version **1.0.3** (published 2019-03-15) · ISC license · 0 weekly downloads

## Install

```sh
npm install aws-secret
pnpm add aws-secret
yarn add aws-secret
bun add aws-secret
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2019-03-15 |
| First published | 2019-03-15 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 2.4 KB |
| Known vulnerabilities | 0 (+2 in 1 direct dependencies) |
| Install scripts | no |
| Author | ptmclean |
| Maintainers | ptmclean |

## Links

- npm: https://www.npmjs.com/package/aws-secret
- Repository: https://github.com/ptmclean/aws-secret
- Homepage: https://github.com/ptmclean/aws-secret#readme
- Issues: https://github.com/ptmclean/aws-secret/issues
- npm.io page: https://npm.io/package/aws-secret

## Dependencies (1)

- [aws-sdk](https://npm.io/package/aws-sdk.md) 2.420.0

## Recent versions

- 1.0.3 (latest) — 2019-03-15
- 1.0.2 — 2019-03-15
- 1.0.1 — 2019-03-15

## README

# aws-secret
A javascript function that makes getting of a secret from secret manager a one liner.

## Installation
To install simply...
```
npm i aws-secret
```

## Assumptions
The function takes the key and optionally a region. The AWS key and secret are assumed to be gathered from the role executing, the environment variables or the shared credentials file(~/.aws/credentials).

## API

The following is an example of the use of the function...
```
const { getSecret } = require('aws-secret');
const secretValue = getSecret('secretKey', 'ap-southeast-2'); // Note region defaults to 'ap-southeast-2'
```

The function will throw an exception if it fails to get or decrypt the key provided.

---
_Source: https://npm.io/package/aws-secret · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
