# @tsacademy/aws-creds

> CLI tool to manage AWS Credentials

Latest version **1.0.4** (published 2024-10-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install @tsacademy/aws-creds
pnpm add @tsacademy/aws-creds
yarn add @tsacademy/aws-creds
bun add @tsacademy/aws-creds
```

Provides the commands `awsc`, `aws-creds`.

## Health

**Score 30/100 (F)** — status: maintenance-mode.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2024-10-27 |
| First published | 2023-03-19 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=12.x |
| Dependencies | 11 |
| Unpacked size | 19 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Troubleshooting Academy |
| Maintainers | tsacademy |
| Keywords | AWS, credentials, AWS credentials, aws-creds, aws creds, aws cli, aws-cli, environment variables, access keys, session token, temporary credentials, IAM credentials, AWS MFA credentials, AWS profile, AWS cli profile, tsacademy, Troubleshooting Academy |

## Links

- npm: https://www.npmjs.com/package/@tsacademy/aws-creds
- Repository: https://github.com/tsacademy0/aws-creds
- Homepage: https://github.com/tsacademy0/aws-creds#readme
- Issues: https://github.com/tsacademy0/aws-creds/issues
- npm.io page: https://npm.io/package/@tsacademy/aws-creds

## Dependencies (11)

- [ora](https://npm.io/package/ora.md) ^6.1.0
- [meow](https://npm.io/package/meow.md) ^10.1.2
- [chalk](https://npm.io/package/chalk.md) ^5.1.2
- [execa](https://npm.io/package/execa.md) ^6.1.0
- [enquirer](https://npm.io/package/enquirer.md) ^2.3.6
- [cli-alerts](https://npm.io/package/cli-alerts.md) ^1.2.2
- [clipboardy](https://npm.io/package/clipboardy.md) ^3.0.0
- [data-store](https://npm.io/package/data-store.md) ^3.1.0
- [await-to-js](https://npm.io/package/await-to-js.md) ^3.0.0
- [cli-meow-help](https://npm.io/package/cli-meow-help.md) ^3.1.0
- [cli-handle-error](https://npm.io/package/cli-handle-error.md) ^4.4.0

## Alternatives

- [replicas-cli](https://npm.io/package/replicas-cli.md) — 3.0K weekly downloads
- [env-contract](https://npm.io/package/env-contract.md) — 133 weekly downloads
- [@openveo/api](https://npm.io/package/@openveo/api.md) — 61 weekly downloads
- [@ryniaubenpm2/cumque-error-reiciendis](https://npm.io/package/@ryniaubenpm2/cumque-error-reiciendis.md) — 54 weekly downloads
- [ts-global-type-extra](https://npm.io/package/ts-global-type-extra.md) — 11 weekly downloads

## Recent versions

- 1.0.4 (latest) — 2024-10-27
- 1.0.3 — 2023-04-02
- 1.0.2 — 2023-03-23
- 1.0.1 — 2023-03-20
- 1.0.0 — 2023-03-19

## README

<h4 align="center">
    <a href="https://github.com/tsacademy0/aws-creds">
        <img src="./.github/logo.jpg" alt="aws-creds" />
    </a>
    <br>
    <br>

⚙️ Manage AWS Credentials ⚙️

<a target="_blank" href="https://www.npmjs.com/package/@tsacademy/aws-creds">![DOWNLOADS](https://img.shields.io/npm/dt/@tsacademy/aws-creds?label=DOWNLOADS%20%20%E2%9D%AF&colorA=FFCD00&colorB=FFCD00&style=flat)</a> <a target="_blank" href="https://tsacademy0.gumroad.com/l/aws-creds">![Try aws-creds Pro](https://img.shields.io/badge/aws--creds%20PRO-%E2%86%92-FFCD00?colorA=FFCD00&colorB=FFCD00&style=flat)</a> <a target="_blank" href="https://twitter.com/tsacademy0/">![Follow @tsacademy0 on Twitter](https://img.shields.io/badge/FOLLOW%20@tsacademy0%20%E2%86%92-gray.svg?colorA=FFCD00&colorB=FFCD00&style=flat)</a>

</h4>

<br>

# aws-creds

#### Basic Features 🎯

- Manage AWS Credentials to use with **AWS CLI** and **AWS SDKs**
- Handles both **Long-Term** or **Temporary Credentials** with a single command
- Create **AWS CLI profile** to store the AWS credentials
- Store AWS credentials into **Environment variables**
- Identify **details about the currently used AWS Credentials**

#### Premium Features 🚀

- Get **MFA authenticated credentials** and configure them into a CLI profile
- **List** AWS CLI profiles on the machine
- **Delete** an AWS CLI profile
- **Import IAM user's credentials** downloaded from the IAM console (in CSV format) into a CLI profile
- **Backup** the `.aws/credentials` file
- **Import** `.aws/credentials` file's **backup** into a new machine

#### For all the premium features do check out <a target="_blank" href="https://tsacademy0.gumroad.com/l/aws-creds">aws-creds PRO 🙌</a>

<!-- <br>

[![Demo of aws-creds](https://img.youtube.com/vi/YOUTUBE_VIDEO_ID_HERE/0.jpg)](https://www.youtube.com/watch?v=YOUTUBE_VIDEO_ID_HERE) -->

<br>

## Prerequisites ⚠️

```
 Node.js version >= 12
```

<br>

## Install 💾

```sh
# Install globally (recommended).
npm install -g @tsacademy/aws-creds
```

![📟](./.github/aws-creds-install.gif)
<br>

## Usage 🕹

### Basic Features 🎯

#### 1) set

###### Store AWS Credentials into an AWS CLI Profile or in Environment varibales

```sh

aws-creds set
```

![📟](./.github/aws-creds-set.gif)

#### 2) curr

###### Return the "Credentials source", "Account ID" and "IAM entity" of currently used credentials

```sh
# Return details either for credentials in env variables if present, else from the 'default' CLI profile
aws curr

# Return details for a specific CLI profile
aws curr --profile <profileName>
```

![📟](./.github/aws-creds-curr.gif)
![📟](./.github/aws-creds-curr-profile.gif)

#### 3) help

###### Display the help data.

```sh
aws-creds help

aws-creds --help
```

![📟](./.github/aws-creds-help.gif)

---

### Premium Features 🚀 ( Available with <a target="_blank" href="https://tsacademy0.gumroad.com/l/aws-creds">aws-creds PRO</a> )

#### 1) list-profiles

###### Get list of AWS CLI profiles configured in the .aws/credentials file

```sh
aws-creds list-profiles
```

![📟](./.github/aws-creds-list-profiles.gif)

#### 2) delete-profile

###### Delete an AWS CLI profile configured in the .aws/credentials file

```sh
aws-creds delete-profile
```

![📟](./.github/aws-creds-delete-profile.gif)

#### 3) mfa

###### Get MFA Authenticated credentials

**Note:** The process mentioned in the following [AWS article](https://repost.aws/knowledge-center/authenticate-mfa-cli) is automated by this feature to easily get MFA authenticated credentials.

```sh
# ⭐️ Called once ⭐️ for a specific credential to configure MFA related configuration
aws-creds mfa configure
```

![📟](./.github/aws-creds-mfa-configure.gif)

```sh
# Issue and store MFA authenticated AWS credentials into an AWS CLI profile
# AWS CLI profile created with following name: ${profileName}-mfa
aws-creds mfa
```

![📟](./.github/aws-creds-mfa.gif)

#### 4) import

###### Import IAM user's credentials downloaded from IAM console (in CSV format) into a CLI profile

```sh
aws-creds import
```

![📟](./.github/aws-creds-import.gif)

#### 5) backup

###### Backup `.aws/credentials` file

```sh
aws-creds backup
```

![📟](./.github/aws-creds-backup.gif)

#### 6) import-backup

###### Import `.aws/credentials` file's backup into a new machine

```sh
aws-creds import-backup
```

![📟](./.github/aws-creds-import-backup.gif)

## License & Conduct

- MIT © [Troubleshooting Academy](https://twitter.com/tsacademy0/)
- [Code of Conduct](https://github.com/tsacademy0/aws-creds/blob/master/CODE-OF-CONDUCT.md)

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