pastercourt.blogg.se

Custom slack client
Custom slack client








custom slack client

If you want to conceal the metadata used in the installation URL options you will need to store state on your server (in a database) by providing a custom state store. Later during the OAuth callback, it verifies the signature. Instead, it signs the options (using the stateSecret) and encodes them along with a signature into state. The default state store, ClearStateStore, does not use any storage.

#CUSTOM SLACK CLIENT HOW TO#

Please go to the storing installations in a database section to learn how to plug in your own database.Ĭonst ) Ī state store handles generating the OAuth state parameter in the installation URL for a given set of options, and verifying the state in the OAuth callback and returning those same options. Note: This example is not ready for production because it only stores installations (tokens) in memory. InstallProvider also requires a stateSecret, which is used to encode the generated state, and later used to decode that same state to verify it wasn’t tampered with during the OAuth flow. At a minimum, InstallProvider takes a clientId and clientSecret (both which can be obtained under the Basic Information of your app configuration). This package exposes an InstallProvider class, which sets up the required configuration and exposes methods such as generateInstallUrl, handleCallback, authorize for use within your apps. It may be helpful to read the tutorials on getting started and getting a public URL that can be used for development.

custom slack client

You’ll also need to copy the Client ID and Client Secret given to you by Slack under the Basic Information of your app configuration. $ npm install building an app, you’ll need to create a Slack app and install it to your development workspace.










Custom slack client