Package com.slack.api.bolt
Class AppConfig
java.lang.Object
com.slack.api.bolt.AppConfig
Configuration for a Slack App.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
static final class
-
Constructor Summary
ConstructorsConstructorDescriptionAppConfig
(Slack slack, ExecutorServiceProvider executorServiceProvider, String singleTeamBotToken, String signingSecret, String verificationToken, boolean oAuthInstallPathEnabled, boolean oAuthStartEnabled, boolean openIDConnectEnabled, boolean oAuthRedirectUriPathEnabled, boolean oAuthCallbackEnabled, boolean oAuthInstallPageRenderingEnabled, OAuthInstallPageRenderer oAuthInstallPageRenderer, OAuthRedirectUriPageRenderer oAuthRedirectUriPageRenderer, UnmatchedRequestHandler unmatchedRequestHandler, boolean authTestCacheEnabled, long authTestCacheExpirationMillis, boolean classicAppPermissionsEnabled, int threadPoolSize, String clientId, String clientSecret, String redirectUri, String scope, String userScope, long tokenRotationExpirationMillis, String appPath, String oauthStartPath, String oauthInstallPath, String oauthCallbackPath, String oauthRedirectUriPath, boolean stateValidationEnabled, String oauthCancellationUrl, String oauthCompletionUrl, boolean alwaysRequestUserTokenNeeded, boolean appInitializersEnabled, boolean subtypedMessageEventsAutoAckEnabled, boolean allEventsApiAutoAckEnabled, boolean sslCheckEnabled, boolean requestVerificationEnabled, boolean ignoringSelfEventsEnabled) -
Method Summary
Modifier and TypeMethodDescriptionstatic AppConfig.AppConfigBuilder
builder()
protected boolean
boolean
long
Returns the millisecond value to keep cached auth.test response in cache.Deprecated.Deprecated.Renders the web page content to display to installers.Renders the web page content to display to installers.Deprecated.Deprecated.getScope()
getSlack()
int
The thread pool size for the built-in handy executor service.long
Handles unmatched requests (default behavior is simply returning 404 Not Found).Deprecated.int
hashCode()
boolean
Automatically acknowledge all Event API events if true.boolean
boolean
boolean
Returns true if auth.test call result cache in MultiTeamsAuthorization middleware is enabled.boolean
boolean
boolean
boolean
Deprecated.boolean
If you prefer the behavior in v1.0 - 1.3, set this flag as falseboolean
boolean
boolean
Deprecated.boolean
boolean
boolean
boolean
Enables validation of the state parameter in the OAuth flow.boolean
Automatically acknowledge message events that have subtype if true.void
setAllEventsApiAutoAckEnabled
(boolean allEventsApiAutoAckEnabled) Automatically acknowledge all Event API events if true.void
setAlwaysRequestUserTokenNeeded
(boolean alwaysRequestUserTokenNeeded) void
setAppInitializersEnabled
(boolean appInitializersEnabled) void
setAppPath
(String appPath) void
setAuthTestCacheEnabled
(boolean authTestCacheEnabled) Returns true if auth.test call result cache in MultiTeamsAuthorization middleware is enabled.void
setAuthTestCacheExpirationMillis
(long authTestCacheExpirationMillis) Returns the millisecond value to keep cached auth.test response in cache.void
setClassicAppPermissionsEnabled
(boolean classicAppPermissionsEnabled) void
setClientId
(String clientId) void
setClientSecret
(String clientSecret) void
setExecutorServiceProvider
(ExecutorServiceProvider executorServiceProvider) void
setIgnoringSelfEventsEnabled
(boolean ignoringSelfEventsEnabled) void
setOAuthCallbackEnabled
(boolean enabled) Deprecated.void
setOauthCallbackPath
(String oauthCallbackPath) Deprecated.void
setOauthCancellationUrl
(String oauthCancellationUrl) void
setOauthCompletionUrl
(String oauthCompletionUrl) void
setOAuthInstallPageRenderer
(OAuthInstallPageRenderer oAuthInstallPageRenderer) Renders the web page content to display to installers.void
setOAuthInstallPageRenderingEnabled
(boolean oAuthInstallPageRenderingEnabled) If you prefer the behavior in v1.0 - 1.3, set this flag as falsevoid
setOauthInstallPath
(String oauthInstallPath) void
setOAuthInstallPathEnabled
(boolean oAuthInstallPathEnabled) void
setOAuthRedirectUriPageRenderer
(OAuthRedirectUriPageRenderer oAuthRedirectUriPageRenderer) Renders the web page content to display to installers.void
setOauthRedirectUriPath
(String oauthRedirectUriPath) void
setOAuthRedirectUriPathEnabled
(boolean oAuthRedirectUriPathEnabled) void
setOAuthStartEnabled
(boolean enabled) Deprecated.void
setOauthStartPath
(String oauthStartPath) Deprecated.void
setOpenIDConnectEnabled
(boolean openIDConnectEnabled) void
setRedirectUri
(String redirectUri) void
setRequestVerificationEnabled
(boolean requestVerificationEnabled) void
void
setSigningSecret
(String signingSecret) void
setSingleTeamBotToken
(String singleTeamBotToken) void
void
setSslCheckEnabled
(boolean sslCheckEnabled) void
setStateValidationEnabled
(boolean stateValidationEnabled) Enables validation of the state parameter in the OAuth flow.void
setSubtypedMessageEventsAutoAckEnabled
(boolean subtypedMessageEventsAutoAckEnabled) Automatically acknowledge message events that have subtype if true.void
setThreadPoolSize
(int threadPoolSize) The thread pool size for the built-in handy executor service.void
setTokenRotationExpirationMillis
(long tokenRotationExpirationMillis) void
setUnmatchedRequestHandler
(UnmatchedRequestHandler unmatchedRequestHandler) Handles unmatched requests (default behavior is simply returning 404 Not Found).void
setUserScope
(String userScope) void
setVerificationToken
(String verificationToken) Deprecated.toString()
-
Constructor Details
-
AppConfig
public AppConfig() -
AppConfig
public AppConfig(Slack slack, ExecutorServiceProvider executorServiceProvider, String singleTeamBotToken, String signingSecret, String verificationToken, boolean oAuthInstallPathEnabled, boolean oAuthStartEnabled, boolean openIDConnectEnabled, boolean oAuthRedirectUriPathEnabled, boolean oAuthCallbackEnabled, boolean oAuthInstallPageRenderingEnabled, OAuthInstallPageRenderer oAuthInstallPageRenderer, OAuthRedirectUriPageRenderer oAuthRedirectUriPageRenderer, UnmatchedRequestHandler unmatchedRequestHandler, boolean authTestCacheEnabled, long authTestCacheExpirationMillis, boolean classicAppPermissionsEnabled, int threadPoolSize, String clientId, String clientSecret, String redirectUri, String scope, String userScope, long tokenRotationExpirationMillis, String appPath, String oauthStartPath, String oauthInstallPath, String oauthCallbackPath, String oauthRedirectUriPath, boolean stateValidationEnabled, String oauthCancellationUrl, String oauthCompletionUrl, boolean alwaysRequestUserTokenNeeded, boolean appInitializersEnabled, boolean subtypedMessageEventsAutoAckEnabled, boolean allEventsApiAutoAckEnabled, boolean sslCheckEnabled, boolean requestVerificationEnabled, boolean ignoringSelfEventsEnabled)
-
-
Method Details
-
isDistributedApp
public boolean isDistributedApp() -
isOAuthInstallPathEnabled
public boolean isOAuthInstallPathEnabled() -
isOAuthStartEnabled
Deprecated. -
setOAuthStartEnabled
Deprecated. -
isOAuthRedirectUriPathEnabled
public boolean isOAuthRedirectUriPathEnabled() -
isOAuthCallbackEnabled
Deprecated. -
setOAuthCallbackEnabled
Deprecated. -
getOauthStartRequestURI
Deprecated. -
getOauthInstallRequestURI
-
getOauthCallbackRequestURI
Deprecated. -
getOauthRedirectUriRequestURI
-
getOauthStartPath
Deprecated. -
setOauthStartPath
Deprecated. -
getOauthInstallPath
-
setOauthInstallPath
-
getOauthCallbackPath
Deprecated. -
setOauthCallbackPath
Deprecated. -
getOauthRedirectUriPath
-
setOauthRedirectUriPath
-
builder
-
toBuilder
-
getSlack
-
getExecutorServiceProvider
-
getSingleTeamBotToken
-
getSigningSecret
-
getVerificationToken
Deprecated. -
isOpenIDConnectEnabled
public boolean isOpenIDConnectEnabled() -
isOAuthInstallPageRenderingEnabled
public boolean isOAuthInstallPageRenderingEnabled()If you prefer the behavior in v1.0 - 1.3, set this flag as false -
getOAuthInstallPageRenderer
Renders the web page content to display to installers. -
getOAuthRedirectUriPageRenderer
Renders the web page content to display to installers. -
getUnmatchedRequestHandler
Handles unmatched requests (default behavior is simply returning 404 Not Found). -
isAuthTestCacheEnabled
public boolean isAuthTestCacheEnabled()Returns true if auth.test call result cache in MultiTeamsAuthorization middleware is enabled. The default is false. -
getAuthTestCacheExpirationMillis
public long getAuthTestCacheExpirationMillis()Returns the millisecond value to keep cached auth.test response in cache. Negative value indicates the cache is permanent. The default is 10 minutes. -
isClassicAppPermissionsEnabled
public boolean isClassicAppPermissionsEnabled() -
getThreadPoolSize
public int getThreadPoolSize()The thread pool size for the built-in handy executor service. -
getClientId
-
getClientSecret
-
getRedirectUri
-
getScope
-
getUserScope
-
getTokenRotationExpirationMillis
public long getTokenRotationExpirationMillis() -
getAppPath
-
isStateValidationEnabled
public boolean isStateValidationEnabled()Enables validation of the state parameter in the OAuth flow. It is highly recommended to enable this validation for better security. A valid exception is when Enterprise Grid Org admins install apps from the app management page. -
getOauthCancellationUrl
-
getOauthCompletionUrl
-
isAlwaysRequestUserTokenNeeded
public boolean isAlwaysRequestUserTokenNeeded() -
isAppInitializersEnabled
public boolean isAppInitializersEnabled() -
isSubtypedMessageEventsAutoAckEnabled
public boolean isSubtypedMessageEventsAutoAckEnabled()Automatically acknowledge message events that have subtype if true. Find the list of available subtypes at https://api.slack.com/events/message#subtypes -
isAllEventsApiAutoAckEnabled
public boolean isAllEventsApiAutoAckEnabled()Automatically acknowledge all Event API events if true. This behavior is compatible with bolt-js. -
isSslCheckEnabled
public boolean isSslCheckEnabled() -
isRequestVerificationEnabled
public boolean isRequestVerificationEnabled() -
isIgnoringSelfEventsEnabled
public boolean isIgnoringSelfEventsEnabled() -
setSlack
-
setExecutorServiceProvider
-
setSingleTeamBotToken
-
setSigningSecret
-
setVerificationToken
Deprecated. -
setOAuthInstallPathEnabled
public void setOAuthInstallPathEnabled(boolean oAuthInstallPathEnabled) -
setOpenIDConnectEnabled
public void setOpenIDConnectEnabled(boolean openIDConnectEnabled) -
setOAuthRedirectUriPathEnabled
public void setOAuthRedirectUriPathEnabled(boolean oAuthRedirectUriPathEnabled) -
setOAuthInstallPageRenderingEnabled
public void setOAuthInstallPageRenderingEnabled(boolean oAuthInstallPageRenderingEnabled) If you prefer the behavior in v1.0 - 1.3, set this flag as false -
setOAuthInstallPageRenderer
Renders the web page content to display to installers. -
setOAuthRedirectUriPageRenderer
public void setOAuthRedirectUriPageRenderer(OAuthRedirectUriPageRenderer oAuthRedirectUriPageRenderer) Renders the web page content to display to installers. -
setUnmatchedRequestHandler
Handles unmatched requests (default behavior is simply returning 404 Not Found). -
setAuthTestCacheEnabled
public void setAuthTestCacheEnabled(boolean authTestCacheEnabled) Returns true if auth.test call result cache in MultiTeamsAuthorization middleware is enabled. The default is false. -
setAuthTestCacheExpirationMillis
public void setAuthTestCacheExpirationMillis(long authTestCacheExpirationMillis) Returns the millisecond value to keep cached auth.test response in cache. Negative value indicates the cache is permanent. The default is 10 minutes. -
setClassicAppPermissionsEnabled
public void setClassicAppPermissionsEnabled(boolean classicAppPermissionsEnabled) -
setThreadPoolSize
public void setThreadPoolSize(int threadPoolSize) The thread pool size for the built-in handy executor service. -
setClientId
-
setClientSecret
-
setRedirectUri
-
setScope
-
setUserScope
-
setTokenRotationExpirationMillis
public void setTokenRotationExpirationMillis(long tokenRotationExpirationMillis) -
setAppPath
-
setStateValidationEnabled
public void setStateValidationEnabled(boolean stateValidationEnabled) Enables validation of the state parameter in the OAuth flow. It is highly recommended to enable this validation for better security. A valid exception is when Enterprise Grid Org admins install apps from the app management page. -
setOauthCancellationUrl
-
setOauthCompletionUrl
-
setAlwaysRequestUserTokenNeeded
public void setAlwaysRequestUserTokenNeeded(boolean alwaysRequestUserTokenNeeded) -
setAppInitializersEnabled
public void setAppInitializersEnabled(boolean appInitializersEnabled) -
setSubtypedMessageEventsAutoAckEnabled
public void setSubtypedMessageEventsAutoAckEnabled(boolean subtypedMessageEventsAutoAckEnabled) Automatically acknowledge message events that have subtype if true. Find the list of available subtypes at https://api.slack.com/events/message#subtypes -
setAllEventsApiAutoAckEnabled
public void setAllEventsApiAutoAckEnabled(boolean allEventsApiAutoAckEnabled) Automatically acknowledge all Event API events if true. This behavior is compatible with bolt-js. -
setSslCheckEnabled
public void setSslCheckEnabled(boolean sslCheckEnabled) -
setRequestVerificationEnabled
public void setRequestVerificationEnabled(boolean requestVerificationEnabled) -
setIgnoringSelfEventsEnabled
public void setIgnoringSelfEventsEnabled(boolean ignoringSelfEventsEnabled) -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-