If you need the appropriate access token associated with your Slack App, the only way to get it is to install your Slack application using the OAuth process, as described here in the Slack documentation. To complete the installation, you will need a mini-site with a script (for example, PHP).
The so-called test token will also allow you to use the Slack API (for example, to create a channel), provided that the user created the test token has this right on your Slack. This is easiest to obtain, but it will always be associated with the user account, not with the Slack application. And you cannot request specific areas for it. Therefore, for most applications, it is better to use the Slack App and get the appropriate access token by installing it.
If you are looking for an example for a script installer, here is a complete script in PHP. It will work on any web server that supports PHP. It is very simple, but everything will be fine.
source share