Skip to content

Commit 56995a1

Browse files
committed
docs: replace links from api.slack.com to docs.slack.dev redirects
1 parent c3e26d9 commit 56995a1

File tree

38 files changed

+118
-118
lines changed

38 files changed

+118
-118
lines changed

.github/ISSUE_TEMPLATE/03_document.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ assignees: ''
1010

1111
### The page URLs
1212

13-
* https://slack.dev/bolt-python/
13+
* https://docs.slack.dev/tools/bolt-python/
1414

1515
## Requirements
1616

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ ngrok http 3000
6060

6161
## Running a Socket Mode app
6262

63-
If you use [Socket Mode](https://api.slack.com/socket-mode) for running your app, `SocketModeHandler` is available for it.
63+
If you use [Socket Mode](https://docs.slack.dev/apis/events-api/using-socket-mode/) for running your app, `SocketModeHandler` is available for it.
6464

6565
```python
6666
import os
@@ -91,7 +91,7 @@ python app.py
9191

9292
## Listening for events
9393

94-
Apps typically react to a collection of incoming events, which can correspond to [Events API events](https://api.slack.com/events-api), [actions](https://api.slack.com/interactivity/components), [shortcuts](https://api.slack.com/interactivity/shortcuts), [slash commands](https://api.slack.com/interactivity/slash-commands) or [options requests](https://api.slack.com/reference/block-kit/block-elements#external_select). For each type of
94+
Apps typically react to a collection of incoming events, which can correspond to [Events API events](https://docs.slack.dev/apis/events-api/), [actions](https://docs.slack.dev/block-kit/#making-things-interactive), [shortcuts](https://docs.slack.dev/interactivity/implementing-shortcuts/), [slash commands](https://docs.slack.dev/interactivity/implementing-slash-commands/) or [options requests](https://docs.slack.dev/reference/block-kit/block-elements/select-menu-element#external_select). For each type of
9595
request, there's a method to build a listener function.
9696

9797
```python
@@ -138,12 +138,12 @@ Most of the app's functionality will be inside listener functions (the `fn` para
138138
| Argument | Description |
139139
| :---: | :--- |
140140
| `body` | Dictionary that contains the entire body of the request (superset of `payload`). Some accessory data is only available outside of the payload (such as `trigger_id` and `authorizations`).
141-
| `payload` | Contents of the incoming event. The payload structure depends on the listener. For example, for an Events API event, `payload` will be the [event type structure](https://api.slack.com/events-api#event_type_structure). For a block action, it will be the action from within the `actions` list. The `payload` dictionary is also accessible via the alias corresponding to the listener (`message`, `event`, `action`, `shortcut`, `view`, `command`, or `options`). For example, if you were building a `message()` listener, you could use the `payload` and `message` arguments interchangably. **An easy way to understand what's in a payload is to log it**. |
141+
| `payload` | Contents of the incoming event. The payload structure depends on the listener. For example, for an Events API event, `payload` will be the [event type structure](https://docs.slack.dev/apis/events-api/#event-type-structure). For a block action, it will be the action from within the `actions` list. The `payload` dictionary is also accessible via the alias corresponding to the listener (`message`, `event`, `action`, `shortcut`, `view`, `command`, or `options`). For example, if you were building a `message()` listener, you could use the `payload` and `message` arguments interchangably. **An easy way to understand what's in a payload is to log it**. |
142142
| `context` | Event context. This dictionary contains data about the event and app, such as the `botId`. Middleware can add additional context before the event is passed to listeners.
143-
| `ack` | Function that **must** be called to acknowledge that your app received the incoming event. `ack` exists for all actions, shortcuts, view submissions, slash command and options requests. `ack` returns a promise that resolves when complete. Read more in [Acknowledging events](https://tools.slack.dev/bolt-python/concepts/acknowledge).
143+
| `ack` | Function that **must** be called to acknowledge that your app received the incoming event. `ack` exists for all actions, shortcuts, view submissions, slash command and options requests. `ack` returns a promise that resolves when complete. Read more in [Acknowledging events](https://docs.slack.dev/tools/bolt-python/concepts/acknowledge/).
144144
| `respond` | Utility function that responds to incoming events **if** it contains a `response_url` (shortcuts, actions, and slash commands).
145145
| `say` | Utility function to send a message to the channel associated with the incoming event. This argument is only available when the listener is triggered for events that contain a `channel_id` (the most common being `message` events). `say` accepts simple strings (for plain-text messages) and dictionaries (for messages containing blocks).
146-
| `client` | Web API client that uses the token associated with the event. For single-workspace installations, the token is provided to the constructor. For multi-workspace installations, the token is returned by using [the OAuth library](https://tools.slack.dev/bolt-python/concepts/authenticating-oauth), or manually using the `authorize` function.
146+
| `client` | Web API client that uses the token associated with the event. For single-workspace installations, the token is provided to the constructor. For multi-workspace installations, the token is returned by using [the OAuth library](https://docs.slack.dev/tools/bolt-python/concepts/authenticating-oauth/), or manually using the `authorize` function.
147147
| `logger` | The built-in [`logging.Logger`](https://docs.python.org/3/library/logging.html) instance you can use in middleware/listeners.
148148
| `complete` | Utility function used to signal the successful completion of a custom step execution. This tells Slack to proceed with the next steps in the workflow. This argument is only available with the `.function` and `.action` listener when handling custom workflow step executions.
149149
| `fail` | Utility function used to signal that a custom step failed to complete. This tells Slack to stop the workflow execution. This argument is only available with the `.function` and `.action` listener when handling custom workflow step executions.
@@ -192,7 +192,7 @@ Apps can be run the same way as the syncronous example above. If you'd prefer an
192192

193193
## Getting Help
194194

195-
[The documentation](https://tools.slack.dev/bolt-python) has more information on basic and advanced concepts for Bolt for Python. Also, all the Python module documents of this library are available [here](https://tools.slack.dev/bolt-python/reference/).
195+
[The documentation](https://docs.slack.dev/tools/bolt-python/) has more information on basic and advanced concepts for Bolt for Python. Also, all the Python module documents of this library are available [here](https://docs.slack.dev/tools/bolt-python/reference/).
196196

197197
If you otherwise get stuck, we're here to help. The following are the best ways to get assistance working through your issue:
198198

docs/english/tutorial/custom-steps-workflow-builder-existing/custom-steps-workflow-builder-existing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ If you followed along with our [create a custom step for Workflow Builder: new a
99
In this tutorial we will:
1010
- Start with an existing Bolt app
1111
- Add a custom **workflow step** in the [app settings](https://api.slack.com/apps)
12-
- Wire up the new step to a **function listener** in our project, using the [Bolt for Python](https://slack.dev/bolt-python/) framework
12+
- Wire up the new step to a **function listener** in our project, using the [Bolt for Python](https://docs.slack.dev/tools/bolt-python/) framework
1313
- See the step as a custom workflow step in Workflow Builder
1414

1515
## Prerequisites {#prereqs}

examples/aws_lambda/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,16 +32,16 @@ Instructions on how to set up and deploy each example are provided below.
3232
`lazy_aws_lambda_config.yaml`
3333
- Optionally enter a description for the role, such as "Bolt Python basic
3434
role"
35-
3. Ensure you have created an app on api.slack.com/apps as per the [Getting
36-
Started Guide](https://slack.dev/bolt-python/tutorial/getting-started).
35+
3. Ensure you have created an app on api.slack.com/apps as per the
36+
[Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide.
3737
Ensure you have installed it to a workspace.
3838
4. Ensure you have exported your Slack Bot Token and Slack Signing Secret for your
3939
apps as the environment variables `SLACK_BOT_TOKEN` and
40-
`SLACK_SIGNING_SECRET`, respectively, as per the [Getting
41-
Started Guide](https://slack.dev/bolt-python/tutorial/getting-started).
40+
`SLACK_SIGNING_SECRET`, respectively, as per the
41+
[Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide.
4242
5. You may want to create a dedicated virtual environment for this example app, as
43-
per the "Setting up your project" section of the [Getting
44-
Started Guide](https://slack.dev/bolt-python/tutorial/getting-started).
43+
per the "Setting up your project" section of the
44+
[Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide.
4545
6. Let's deploy the Lambda! Run `./deploy_lazy.sh`. By default it deploys to the
4646
us-east-1 region in AWS - you can change this at the top of `lazy_aws_lambda_config.yaml` if you wish.
4747
7. Load up AWS Lambda inside the AWS Console - make sure you are in the correct
@@ -150,7 +150,7 @@ Let’s create a user role that will use the custom policy we created as well as
150150
3. "Create Role"
151151

152152
### Create Slack App and Load your Lambda to AWS
153-
Ensure you have created an app on [api.slack.com/apps](https://api.slack.com/apps) as per the [Getting Started Guide](https://slack.dev/bolt-python/tutorial/getting-started). You do not need to ensure you have installed it to a workspace, as the OAuth flow will provide your app the ability to be installed by anyone.
153+
Ensure you have created an app on [api.slack.com/apps](https://api.slack.com/apps) as per the [Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide. You do not need to ensure you have installed it to a workspace, as the OAuth flow will provide your app the ability to be installed by anyone.
154154

155155
1. Remember those S3 buckets we made? You will need the names of these buckets again in the next step.
156156
2. You need many environment variables exported! Specifically the following from api.slack.com/apps

examples/django/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ This example demonstrates how you can use Bolt for Python in your Django applica
44

55
### `simple_app` - Single-workspace App Example
66

7-
If you want to run a simple app like the one you've tried in the [Getting Started Guide](https://slack.dev/bolt-python/tutorial/getting-started), this is the right one for you. By default, this Django project runs this application. If you want to switch to OAuth flow supported one, modify `myslackapp/urls.py`.
7+
If you want to run a simple app like the one you've tried in the [Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide, this is the right one for you. By default, this Django project runs this application. If you want to switch to OAuth flow supported one, modify `myslackapp/urls.py`.
88

99
To run this app, all you need to do are:
1010

@@ -31,7 +31,7 @@ python manage.py migrate
3131
python manage.py runserver 0.0.0.0:3000
3232
```
3333

34-
As you did at [Getting Started Guide](https://slack.dev/bolt-python/tutorial/getting-started), configure ngrok or something similar to serve a public endpoint. Lastly,
34+
As you did at [Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide, configure ngrok or something similar to serve a public endpoint. Lastly,
3535

3636
* Go back to the Slack app configuration page
3737
* Go to "Event Subscriptions"
@@ -54,7 +54,7 @@ To run this app, all you need to do are:
5454
* Create a new Slack app configuration at https://api.slack.com/apps?new_app=1
5555
* Go to "OAuth & Permissions"
5656
* Add `app_mentions:read`, `chat:write` in Scopes > Bot Token Scopes
57-
* Follow the instructions [here](https://slack.dev/bolt-python/concepts#authenticating-oauth) for configuring OAuth flow supported Slack apps
57+
* Follow the instructions [here](https://docs.slack.dev/tools/bolt-python/concepts/authenticating-oauth) for configuring OAuth flow supported Slack apps
5858

5959
You can start your Django application this way:
6060

@@ -73,7 +73,7 @@ python manage.py migrate
7373
python manage.py runserver 0.0.0.0:3000
7474
```
7575

76-
As you did at [Getting Started Guide](https://slack.dev/bolt-python/tutorial/getting-started), configure ngrok or something similar to serve a public endpoint. Lastly,
76+
As you did at [Building an App](https://docs.slack.dev/tools/bolt-python/building-an-app) guide, configure ngrok or something similar to serve a public endpoint. Lastly,
7777

7878
* Go back to the Slack app configuration page
7979
* Go to "Event Subscriptions"

examples/getting_started/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Getting Started with ⚡️ Bolt for Python
2-
> Slack app example from 📚 [Getting started with Bolt for Python][1]
2+
> Slack app example from 📚 [Building an App with Bolt for Python][1]
33
44
## Overview
55

@@ -42,6 +42,6 @@ ngrok http 3000
4242
python3 app.py
4343
```
4444

45-
[1]: https://slack.dev/bolt-python/tutorial/getting-started
46-
[2]: https://slack.dev/bolt-python/
47-
[3]: https://slack.dev/bolt-python/tutorial/getting-started#setting-up-events
45+
[1]: https://docs.slack.dev/tools/bolt-python/building-an-app
46+
[2]: https://docs.slack.dev/tools/bolt-python/
47+
[3]: https://docs.slack.dev/tools/bolt-python/building-an-app#setting-up-events

examples/message_events.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def extract_subtype(body: dict, context: BoltContext, next: Callable):
3232
next()
3333

3434

35-
# https://api.slack.com/events/message
35+
# https://docs.slack.dev/reference/events/message/
3636
# Newly posted messages only
3737
# or @app.event("message")
3838
@app.event({"type": "message", "subtype": None})
@@ -55,8 +55,8 @@ def detect_deletion(say: Say, body: dict):
5555
say(f"You've deleted a message: {text}")
5656

5757

58-
# https://api.slack.com/events/message/file_share
59-
# https://api.slack.com/events/message/bot_message
58+
# https://docs.slack.dev/reference/events/message/file_share
59+
# https://docs.slack.dev/reference/events/message/bot_message
6060
@app.event(
6161
event={"type": "message", "subtype": re.compile("(me_message)|(file_share)")},
6262
middleware=[extract_subtype],

examples/readme_app.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ def log_request(logger, body, next):
1616
return next()
1717

1818

19-
# Events API: https://api.slack.com/events-api
19+
# Events API: https://docs.slack.dev/apis/events-api/
2020
@app.event("app_mention")
2121
def event_test(say):
2222
say("What's up?")
2323

2424

25-
# Interactivity: https://api.slack.com/interactivity
25+
# Interactivity: https://docs.slack.dev/interactivity/
2626
@app.shortcut("callback-id-here")
2727
# @app.command("/hello-bolt-python")
2828
def open_modal(ack, client, logger, body):

examples/readme_async_app.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ async def log_request(logger, body, next):
2828
return await next()
2929

3030

31-
# Events API: https://api.slack.com/events-api
31+
# Events API: https://docs.slack.dev/apis/events-api/
3232
@app.event("app_mention")
3333
async def event_test(say):
3434
await say("What's up?")
3535

3636

37-
# Interactivity: https://api.slack.com/interactivity
37+
# Interactivity: https://docs.slack.dev/interactivity/
3838
@app.shortcut("callback-id-here")
3939
# @app.command("/hello-bolt-python")
4040
async def open_modal(ack, client, logger, body):

examples/workflow_steps/async_steps_from_apps.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
################################################################################
1313
# Steps from apps for legacy workflows are now deprecated. #
14-
# Use new custom steps: https://api.slack.com/automation/functions/custom-bolt #
14+
# Use new custom steps: https://docs.slack.dev/workflows/workflow-steps/ #
1515
################################################################################
1616

1717
logging.basicConfig(level=logging.DEBUG)

0 commit comments

Comments
 (0)