How do I setup a Slack alert?

I haven’t been able to find documentation for setting up a Slack alert.

When I tried:

$ fly checks handlers create --type slack

and then tried to list the checks:

$ fly checks handlers list
Error: accepts 1 arg(s), received 0
  flyctl checks handlers list [flags]

  -h, --help   help for list

Global Flags:
  -t, --access-token string   Fly API Access Token
  -j, --json                  json output
      --verbose               verbose output

Error accepts 1 arg(s), received 0

What should I do?

1 Like

The only info I’m aware of is this (perhaps you’ve already found this). Scroll down the post to the Slack bit:

Seems like Fly soft launched this feature. Are you running that CLI command from the folder the app’s fly.toml is in? If not I’d guess you’d need to provide the app name as a flag. If you are, does it need the type to list? :thinking: Like fly checks handlers list --type slack? Total guess while waiting for someone from Fly to jump in.


I have found that, but don’t understand why it doesn’t do anything, or why the list command fails.

@eric1 I just ran into this same issue today, and might have discovered what the 1 required argument is through a bit of trial and error! My first attempts were to use <app-name> or --app <app-name>, since so many of the other commands require that, but it didn’t work.

Then I remembered that when I created a check using flyctl checks handlers create --type slack, the CLI prompted me to select an organization, and not an app.

Supplying the name of my org worked, and I can now see the one check that I created!

flyctl checks handlers list <org-name>
1 Like