A client to the forwardemail.net API

Timothy Rice d7603b6774 Check number of args after processing options 2 yıl önce
LICENSE.md 52426c5854 Initial commit 2 yıl önce
README.md 52426c5854 Initial commit 2 yıl önce
fembot.sh d7603b6774 Check number of args after processing options 2 yıl önce

README.md

Fembot

Prototype client for the forwardemail.net API. The client admits various subcommands with the following structure:

fembot
├── account
│   └── show
├── alias
│   ├── create
│   ├── delete
│   ├── disable
│   ├── enable
│   ├── list
│   ├── set
│   └── show
├── domain
│   ├── list
│   ├── show
│   └── verify
└── help
    ├── account
    ├── alias
    └── domain
  • A brief usage for each subcommand can be seen using the help subcommand.
  • The client assumes you have FEMBOT_API_TOKEN and FEMBOT_PASSWORD environment variables defined in the obvious ways.

An example session might look like:

$ export FEMBOT_API_TOKEN=$(pass show forwardemail.net/api)

$ export FEMBOT_PASSWORD=$(pass show forwardemail.net/password)

$ fembot domain list
id                       | name            | plan                | child_protect | phish_protect | exec_protect | virus_protect | max_recipients | smtp_port | created_at               | updated_at
----                     | ----            | ----                | ----          | ----          | ----         | ----          | ----           | ----      | ----                     | ----
5e3c05509e97d1609b7ba021 | hash.fyi        | team                | true          | true          | true         | true          | 10             | 25        | 2020-02-06T12:23:45.257Z | 2021-01-21T16:37:19.534Z
5e3c05509e97d1609b7ba025 | hideaddress.net | team                | true          | true          | true         | true          | 10             | 25        | 2020-02-06T12:23:44.820Z | 2021-01-21T16:38:03.975Z
5e3c05509e97d1609b7ba023 | mailsire.com    | team                | true          | true          | true         | true          | 10             | 25        | 2020-02-06T12:23:44.798Z | 2021-01-21T16:38:46.694Z
5e3c05509e97d1609b7ba027 | secret.fyi      | team                | true          | true          | true         | true          | 10             | 25        | 2020-02-06T12:23:44.973Z | 2021-01-21T16:37:39.851Z

$ fembot alias list hash.fyi
id   | name | domain | description | recipients | is_enabled | created_at | updated_at
---- | ---- | ----   | ----        | ----       | ----       | ----       | ----

$ fembot alias create -d "Just a test" hash.fyi my-cool-test foo@example.com

$ fembot alias list hash.fyi
id                       | name         | domain   | description | recipients      | is_enabled | created_at               | updated_at
----                     | ----         | ----     | ----        | ----            | ----       | ----                     | ----
<redacted>               | my-cool-test | hash.fyi | Just a test | foo@example.com | false      | 2022-02-14T09:55:02.494Z | 2022-02-14T09:55:02.494Z

$ fembot alias enable hash.fyi my-cool-test

$ fembot alias set -d "A new description" -r "bar@example.com" hash.fyi my-cool-test

$ fembot alias show hash.fyi my-cool-test
id           <redacted>
name         my-cool-test
domain       hash.fyi
description  A new description
recipients   bar@example.com
is_enabled   true
created_at   2022-02-14T09:55:02.494Z
updated_at   2022-02-14T09:58:51.784Z

$ fembot alias delete hash.fyi my-cool-test

$ fembot alias list hash.fyi
id   | name | domain | description | recipients | is_enabled | created_at | updated_at
---- | ---- | ----   | ----        | ----       | ----       | ----       | ----