Skip to content

Commit b7cc608

Browse files
authored
update docs links (#1464)
1 parent d190d93 commit b7cc608

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+240
-240
lines changed

docs/content/guides/ai-apps.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -9,29 +9,29 @@ If you don't have a paid workspace for development, you can join the [Developer
99

1010
:::
1111

12-
AI apps comprise a new messaging experience for Slack. If you're unfamiliar with using AI apps within Slack, you'll want to read the [API documentation on the subject](https://api.slack.com/docs/apps/ai). Then come back here to implement them with Bolt!
12+
AI apps comprise a new messaging experience for Slack. If you're unfamiliar with using AI apps within Slack, you'll want to read the [API documentation on the subject](https://docs.slack.dev/ai/). Then come back here to implement them with Bolt!
1313

1414
## Configuring your app to support AI apps features {#configuring-your-app}
1515

1616
1. Within [App Settings](https://api.slack.com/apps), enable the **Agents & AI Apps** feature.
1717

1818
2. Within the App Settings **OAuth & Permissions** page, add the following scopes:
19-
* [`assistant:write`](https://api.slack.com/scopes/assistant:write)
20-
* [`chat:write`](https://api.slack.com/scopes/chat:write)
21-
* [`im:history`](https://api.slack.com/scopes/im:history)
19+
* [`assistant:write`](https://docs.slack.dev/reference/scopes/assistant.write)
20+
* [`chat:write`](https://docs.slack.dev/reference/scopes/chat.write)
21+
* [`im:history`](https://docs.slack.dev/reference/scopes/im.history)
2222

2323
3. Within the App Settings **Event Subscriptions** page, subscribe to the following events:
24-
* [`assistant_thread_started`](https://api.slack.com/events/assistant_thread_started)
25-
* [`assistant_thread_context_changed`](https://api.slack.com/events/assistant_thread_context_changed)
26-
* [`message.im`](https://api.slack.com/events/message.im)
24+
* [`assistant_thread_started`](https://docs.slack.dev/reference/events/assistant_thread_started)
25+
* [`assistant_thread_context_changed`](https://docs.slack.dev/reference/events/assistant_thread_context_changed)
26+
* [`message.im`](https://docs.slack.dev/reference/events/message.im)
2727

2828
## The `Assistant` class instance {#assistant-class}
2929

3030
The [`Assistant`](/reference#the-assistantconfig-configuration-object) class can be used to handle the incoming events expected from a user interacting with an AI app in Slack. A typical flow would look like:
3131

32-
1. [The user starts a thread](#handling-a-new-thread). The `Assistant` class handles the incoming [`assistant_thread_started`](https://api.slack.com/events/assistant_thread_started) event.
33-
2. [The thread context may change at any point](#handling-thread-context-changes). The `Assistant` class can handle any incoming [`assistant_thread_context_changed`](https://api.slack.com/events/assistant_thread_context_changed) events. The class also provides a default `context` store to keep track of thread context changes as the user moves through Slack.
34-
3. [The user responds](#handling-user-response). The `Assistant` class handles the incoming [`message.im`](https://api.slack.com/events/message.im) event.
32+
1. [The user starts a thread](#handling-a-new-thread). The `Assistant` class handles the incoming [`assistant_thread_started`](https://docs.slack.dev/reference/events/assistant_thread_started) event.
33+
2. [The thread context may change at any point](#handling-thread-context-changes). The `Assistant` class can handle any incoming [`assistant_thread_context_changed`](https://docs.slack.dev/reference/events/assistant_thread_context_changed) events. The class also provides a default `context` store to keep track of thread context changes as the user moves through Slack.
34+
3. [The user responds](#handling-user-response). The `Assistant` class handles the incoming [`message.im`](https://docs.slack.dev/reference/events/message.im) event.
3535

3636
```java
3737
App app = new App();
@@ -71,7 +71,7 @@ assistant.userMessage((req, ctx) -> {
7171
app.assistant(assistant);
7272
```
7373

74-
While the `assistant_thread_started` and `assistant_thread_context_changed` events do provide Slack-client thread context information, the `message.im` event does not. Any subsequent user message events won't contain thread context data. For that reason, Bolt not only provides a way to store thread context — the `threadContextService` property — but it also provides a `DefaultAssistantThreadContextService` instance that is utilized by default. This implementation relies on storing and retrieving [message metadata](https://api.slack.com/metadata/using) as the user interacts with the app.
74+
While the `assistant_thread_started` and `assistant_thread_context_changed` events do provide Slack-client thread context information, the `message.im` event does not. Any subsequent user message events won't contain thread context data. For that reason, Bolt not only provides a way to store thread context — the `threadContextService` property — but it also provides a `DefaultAssistantThreadContextService` instance that is utilized by default. This implementation relies on storing and retrieving [message metadata](https://docs.slack.dev/messaging/message-metadata/) as the user interacts with the app.
7575

7676
If you do provide your own `threadContextService` property, it must feature `get` and `save` methods.
7777

@@ -81,15 +81,15 @@ Be sure to give the [AI apps reference docs](/reference#agents--assistants) a lo
8181

8282
## Handling a new thread {#handling-a-new-thread}
8383

84-
When the user opens a new thread with your AI app, the [`assistant_thread_started`](https://api.slack.com/events/assistant_thread_started) event will be sent to your app.
84+
When the user opens a new thread with your AI app, the [`assistant_thread_started`](https://docs.slack.dev/reference/events/assistant_thread_started) event will be sent to your app.
8585

8686
:::tip
8787
When a user opens a thread with your app while in a channel, the channel info is stored as the thread's `AssistantThreadContext` data. You can grab that info by using the `context.getThreadContext()` utility, as subsequent user message event payloads won't include the channel info.
8888
:::
8989

9090
### Block Kit interactions in the AI app thread {#block-kit-interactions}
9191

92-
For advanced use cases, Block Kit buttons may be used instead of suggested prompts, as well as the sending of messages with structured [metadata](https://api.slack.com/metadata) to trigger subsequent interactions with the user.
92+
For advanced use cases, Block Kit buttons may be used instead of suggested prompts, as well as the sending of messages with structured [metadata](https://docs.slack.dev/messaging/message-metadata/) to trigger subsequent interactions with the user.
9393

9494
For example, an app can display a button like "Summarize the referring channel" in the initial reply. When the user clicks the button and submits detailed information (such as the number of messages, days to check, the purpose of the summary, etc.), the app can handle that information and post a message that describes the request with structured metadata.
9595

@@ -175,9 +175,9 @@ app.assistant(assistant);
175175

176176
## Handling thread context changes {#handling-thread-context-changes}
177177

178-
When the user switches channels, the [`assistant_thread_context_changed`](https://api.slack.com/events/assistant_thread_context_changed) event will be sent to your app.
178+
When the user switches channels, the [`assistant_thread_context_changed`](https://docs.slack.dev/reference/events/assistant_thread_context_changed) event will be sent to your app.
179179

180-
If you use the built-in `Assistant` middleware without any custom configuration, the updated context data is automatically saved as [message metadata](https://api.slack.com/metadata/using) of the first reply from the assistant bot.
180+
If you use the built-in `Assistant` middleware without any custom configuration, the updated context data is automatically saved as [message metadata](https://docs.slack.dev/messaging/message-metadata/) of the first reply from the assistant bot.
181181

182182
As long as you use the built-in approach, you don't need to store the context data within a datastore. The downside of this default behavior is the overhead of additional calls to the Slack API. These calls include those to `conversations.history`, which are used to look up the stored message metadata that contains the thread context (via `context.getThreadContextService().findCurrentContext(channelId, threadTs)`).
183183

@@ -189,9 +189,9 @@ Assistant assistant = new Assistant(new YourOwnAssistantThreadContextService());
189189

190190
## Handling the user response {#handling-user-response}
191191

192-
When the user messages your app, the [`message.im`](https://api.slack.com/events/message.im) event will be sent to your app.
192+
When the user messages your app, the [`message.im`](https://docs.slack.dev/reference/events/message.im) event will be sent to your app.
193193

194-
Messages sent to the app do not contain a [subtype](https://api.slack.com/events/message#subtypes) and must be deduced based on their shape and any provided [message metadata](https://api.slack.com/metadata/using).
194+
Messages sent to the app do not contain a [subtype](https://docs.slack.dev/reference/events/message) and must be deduced based on their shape and any provided [message metadata](https://docs.slack.dev/messaging/message-metadata/).
195195

196196
There are three utilities that are particularly useful in curating the user experience:
197197
* [`say`](https://tools.slack.dev/bolt-python/api-docs/slack_bolt/#slack_bolt.Say)

docs/content/guides/app-distribution.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,18 @@ lang: en
44

55
# App Distribution (OAuth)
66

7-
A newly created Slack app can only be installed in its development workspace in the beginning. By setting an OAuth Redirect URL and enabling [App Distribution](https://api.slack.com/start/distributing), the app becomes to be ready for installation in any other workspaces.
7+
A newly created Slack app can only be installed in its development workspace in the beginning. By setting an OAuth Redirect URL and enabling [App Distribution](https://docs.slack.dev/distribution/), the app becomes to be ready for installation in any other workspaces.
88

9-
* [Installing with OAuth](https://api.slack.com/authentication/oauth-v2)
10-
* [Distributing Slack Apps](https://api.slack.com/start/distributing)
9+
* [Installing with OAuth](https://docs.slack.dev/authentication/installing-with-oauth)
10+
* [Distributing Slack Apps](https://docs.slack.dev/distribution/)
1111

1212
### Slack App Configuration
1313

1414
To enable App Distribution, visit the [Slack App configuration page](http://api.slack.com/apps), choose the app you're working on, go to **Settings** > **Manage Distribution** on the left pane, and follow the instructions there.
1515

1616
For **Redirect URL**, Bolt apps respond to `https://{your app's public URL domain}/slack/oauth/callback` if you go with recommended settings. To know how to configure such settings, consult the list of the available env variables below in this page.
1717

18-
Bolt for Java automatically includes support for [org wide installations](https://api.slack.com/enterprise/apps) since version `1.4.0`. Org wide installations can be enabled in your app configuration settings under **Org Level Apps**.
18+
Bolt for Java automatically includes support for [org wide installations](https://docs.slack.dev/enterprise-grid/) since version `1.4.0`. Org wide installations can be enabled in your app configuration settings under **Org Level Apps**.
1919

2020
### What Your Bolt App Does
2121

@@ -26,7 +26,7 @@ All your app needs to do to properly handle OAuth Flow are:
2626
* Append `client_id`, `scope`, `user_scope` (only for v2), and `state` to the URL
2727
* Provide an endpoint to handle user redirection from Slack
2828
* Make sure if the `state` parameter is valid
29-
* Complete the installation by calling [oauth.v2.access](https://api.slack.com/methods/oauth.v2.access) (or [oauth.access](https://api.slack.com/methods/oauth.access) if you maintain legacy OAuth apps) method and store the acquired tokens
29+
* Complete the installation by calling [oauth.v2.access](https://docs.slack.dev/reference/methods/oauth.v2.access) (or [oauth.access](https://docs.slack.dev/reference/methods/oauth.access) if you maintain legacy OAuth apps) method and store the acquired tokens
3030
* Provide the endpoints to navigate installers for the completion/cancellation of the installation flow
3131
* The URLs are usually somewhere else but Bolt has simple functionality to serve them
3232

@@ -147,23 +147,23 @@ SlackAppServer server = new SlackAppServer(new HashMap<>(Map.ofEntries(
147147
server.start(); // http://localhost:3000
148148
```
149149

150-
If you want to turn [the token rotation feature](https://api.slack.com/authentication/rotation) on, your `InstallationService` should be compatible with it. Refer to the [v1.9.0 release notes](https://github.com/slackapi/java-slack-sdk/releases/tag/v1.9.0) for more details.
150+
If you want to turn [the token rotation feature](https://docs.slack.dev/authentication/using-token-rotation) on, your `InstallationService` should be compatible with it. Refer to the [v1.9.0 release notes](https://github.com/slackapi/java-slack-sdk/releases/tag/v1.9.0) for more details.
151151

152152
### Granular Permission Apps or Classic Apps
153153

154154
Slack has two types of OAuth flows for Slack app installations. The V2 (this is a bit confusing but it's not the version of OAuth spec, but the version of the Slack OAuth flow) OAuth flow enables Slack apps to request more granular permissions than the classic ones, especially for bot users. The differences between the two types are having `v2` in the endpoint to issue access tokens and the OAuth Authorization URL, plus some changes to the response data structure returned by the `oauth(.v2).access` endpoint.
155155

156-
#### [V2 OAuth 2.0 Flow](https://api.slack.com/authentication/oauth-v2) (default)
156+
#### [V2 OAuth 2.0 Flow](https://docs.slack.dev/authentication/installing-with-oauth) (default)
157157

158158
|-|-|
159159
|Authorization URL|`https://slack.com/oauth/v2/authorize`|
160-
|Web API to issue access tokens|[`oauth.v2.access`](https://api.slack.com/methods/oauth.v2.access) ([Response](https://github.com/slackapi/java-slack-sdk/blob/main/slack-api-client/src/main/java/com/slack/api/methods/response/oauth/OAuthV2AccessResponse.java))|
160+
|Web API to issue access tokens|[`oauth.v2.access`](https://docs.slack.dev/reference/methods/oauth.v2.access) ([Response](https://github.com/slackapi/java-slack-sdk/blob/main/slack-api-client/src/main/java/com/slack/api/methods/response/oauth/OAuthV2AccessResponse.java))|
161161

162-
#### [Classic OAuth Flow](https://api.slack.com/docs/oauth)
162+
#### [Classic OAuth Flow](https://docs.slack.dev/authentication/installing-with-oauth)
163163

164164
|-|-|
165165
|Authorization URL|`https://slack.com/oauth/authorize`|
166-
|Web API to issue access tokens|[`oauth.access`](https://api.slack.com/methods/oauth.access) ([Response](https://github.com/slackapi/java-slack-sdk/blob/main/slack-api-client/src/main/java/com/slack/api/methods/response/oauth/OAuthAccessResponse.java))|
166+
|Web API to issue access tokens|[`oauth.access`](https://docs.slack.dev/reference/methods/oauth.access) ([Response](https://github.com/slackapi/java-slack-sdk/blob/main/slack-api-client/src/main/java/com/slack/api/methods/response/oauth/OAuthAccessResponse.java))|
167167

168168
By default, Bolt enables the V2 OAuth Flow over the classic one. It's configurable by **AppConfig**'s the setter method for `classicAppPermissionsEnabled`. The value is set to `false` by default. Change the flag to `true` to authorize your classic OAuth apps.
169169

@@ -258,7 +258,7 @@ public class SlackApp {
258258

259259
#### Use the Built-in tokens_revoked / app_uninstalled Event Handlers
260260

261-
For secure data management for your customers and end-users, properly handling [tokens_revoked](https://api.slack.com/events/tokens_revoked) and [app_uninstalled](https://api.slack.com/events/app_uninstalled) events is crucial. Bolt for Java provides the built-in event handlers for these events, which seamlessly integrated with your `InstallationService`'s deletion methods.
261+
For secure data management for your customers and end-users, properly handling [tokens_revoked](https://docs.slack.dev/reference/events/tokens_revoked) and [app_uninstalled](https://docs.slack.dev/reference/events/app_uninstalled) events is crucial. Bolt for Java provides the built-in event handlers for these events, which seamlessly integrated with your `InstallationService`'s deletion methods.
262262

263263
```java
264264
App app = new App();

docs/content/guides/app-home.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ lang: en
44

55
# App Home
66

7-
An [App Home](https://api.slack.com/surfaces/tabs/events) is a private, one-to-one space in Slack shared by a user and an app. Each App Home contains a number of tabbed surfaces, including a Messages tab for app-user conversation, and a Home tab that can be fully customized by the app.
7+
An [App Home](https://docs.slack.dev/surfaces/app-home) is a private, one-to-one space in Slack shared by a user and an app. Each App Home contains a number of tabbed surfaces, including a Messages tab for app-user conversation, and a Home tab that can be fully customized by the app.
88

99
### Slack App Configuration
1010

@@ -24,10 +24,10 @@ To enable Events API, go to **Features** > **Event Subscriptions** on the left p
2424

2525
All your app needs to do to provide Home tabs to your app users are:
2626

27-
1. Call the [**views.publish**](https://api.slack.com/methods/views.publish) method to update the Home tab on a per-user basis
27+
1. Call the [**views.publish**](https://docs.slack.dev/reference/methods/views.publish) method to update the Home tab on a per-user basis
2828
2. Handle any user interactions in Home tab (`"block_actions"`, `"block_suggestion"`)
2929

30-
Most commonly, [`"app_home_opened"`](https://api.slack.com/events/app_home_opened) events would be used as the trigger to call the [**views.publish**](https://api.slack.com/methods/views.publish) method. Subscribing this event type is useful particularly for the initial Home tab creation. But it's also fine to publish Home tabs by any other means.
30+
Most commonly, [`"app_home_opened"`](https://docs.slack.dev/reference/events/app_home_opened) events would be used as the trigger to call the [**views.publish**](https://docs.slack.dev/reference/methods/views.publish) method. Subscribing this event type is useful particularly for the initial Home tab creation. But it's also fine to publish Home tabs by any other means.
3131

3232
---
3333
## Examples
@@ -38,7 +38,7 @@ If you're a beginner to using Bolt for Slack App development, consult [Getting S
3838

3939
:::
4040

41-
The following code calls [**views.publish**](https://api.slack.com/methods/views.publish) method when receiving an [`"app_home_opened"` events](https://api.slack.com/events/app_home_opened) for the user that triggered the event. The user will see the updated Home tab immediately after the [**views.publish**](https://api.slack.com/methods/views.publish) call has been successfully completed.
41+
The following code calls [**views.publish**](https://docs.slack.dev/reference/methods/views.publish) method when receiving an [`"app_home_opened"` events](https://docs.slack.dev/reference/events/app_home_opened) for the user that triggered the event. The user will see the updated Home tab immediately after the [**views.publish**](https://docs.slack.dev/reference/methods/views.publish) call has been successfully completed.
4242

4343
```java
4444
import com.slack.api.methods.response.views.ViewsPublishResponse;
@@ -50,7 +50,7 @@ import static com.slack.api.model.block.Blocks.*;
5050
import static com.slack.api.model.block.composition.BlockCompositions.*;
5151
import static com.slack.api.model.view.Views.*;
5252

53-
// https://api.slack.com/events/app_home_opened
53+
// https://docs.slack.dev/reference/events/app_home_opened
5454
app.event(AppHomeOpenedEvent.class, (payload, ctx) -> {
5555
// Build a Home tab view
5656
ZonedDateTime now = ZonedDateTime.now();
@@ -89,7 +89,7 @@ import com.slack.api.model.view.Views.*
8989
import com.slack.api.model.event.AppHomeOpenedEvent
9090
import java.time.ZonedDateTime
9191

92-
// https://api.slack.com/events/app_home_opened
92+
// https://docs.slack.dev/reference/events/app_home_opened
9393
app.event(AppHomeOpenedEvent::class.java) { event, ctx ->
9494
// Build a Home tab view
9595
val now = ZonedDateTime.now()

0 commit comments

Comments
 (0)