Skip to content

Commit c5349cc

Browse files
authored
Add anchors and add contribute link to sidebar (#686)
1 parent ff9c796 commit c5349cc

File tree

6 files changed

+36
-36
lines changed

6 files changed

+36
-36
lines changed

docs/_config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ t:
4040
steps: ワークフローステップ
4141
advanced: 応用コンセプト
4242
start: Bolt 入門ガイド
43-
# contribute: 貢献
43+
contribute: 貢献
4444

4545
# Metadata
4646
repo_name: bolt-python

docs/_includes/sidebar.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
<li class="title">{{tutorial.title}}</li>
7575
</a>
7676
{% endfor %}
77-
<a href="https://github.com/SlackAPI/bolt-python/blob/master/.github/contributing.md">
77+
<a href="https://github.com/SlackAPI/bolt-python/blob/main/.github/contributing.md">
7878
<li class="title">{{ site.t[page.lang].contribute }}</li>
7979
</a>
8080
</ul>

docs/_tutorials/getting_started.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ When you're finished, you'll have this ⚡️[Getting Started with Slack app](ht
2020
2121
---
2222

23-
### Create an app
23+
### Create an app {#create-an-app}
2424
First thing's first: before you start developing with Bolt, you'll want to [create a Slack app](https://api.slack.com/apps/new).
2525

2626
> 💡 We recommend using a workspace where you won't disrupt real work getting done — [you can create a new one for free](https://slack.com/get-started#create).
@@ -35,7 +35,7 @@ Look around, add an app icon and description, and then let's start configuring y
3535

3636
---
3737

38-
### Tokens and installing apps
38+
### Tokens and installing apps {#tokens-and-installing-apps}
3939
Slack apps use [OAuth to manage access to Slack's APIs](https://api.slack.com/docs/oauth). When an app is installed, you'll receive a token that the app can use to call API methods.
4040

4141
There are three main token types available to a Slack app: user (`xoxp`), bot (`xoxb`), and app-level (`xapp`) tokens.
@@ -64,7 +64,7 @@ We're going to use bot and app-level tokens for this guide.
6464
6565
---
6666

67-
### Setting up your project
67+
### Setting up your project {#setting-up-your-project}
6868
With the initial configuration handled, it's time to set up a new Bolt project. This is where you'll write the code that handles the logic for your app.
6969

7070
If you don’t already have a project, let’s create a new one. Create an empty directory:
@@ -133,7 +133,7 @@ Your app should let you know that it's up and running. 🎉
133133

134134
---
135135

136-
### Setting up events
136+
### Setting up events {#setting-up-events}
137137
Your app behaves similarly to people on your team — it can post messages, add emoji reactions, and listen and respond to events.
138138

139139
To listen for events happening in a Slack workspace (like when a message is posted or when a reaction is posted to a message) you'll use the [Events API to subscribe to event types](https://api.slack.com/events-api).
@@ -154,7 +154,7 @@ If you want your bot to listen to messages from everywhere it is added to, choos
154154

155155
---
156156

157-
### Listening and responding to a message
157+
### Listening and responding to a message {#listening-and-responding-to-a-message}
158158
Your app is now ready for some logic. Let's start by using the `message()` method to attach a listener for messages.
159159

160160
The following example listens and responds to all messages in channels/DMs where your app has been added that contain the word "hello":
@@ -186,7 +186,7 @@ This is a basic example, but it gives you a place to start customizing your app
186186

187187
---
188188

189-
### Sending and responding to actions
189+
### Sending and responding to actions {#sending-and-responding-to-actions}
190190

191191
To use features like buttons, select menus, datepickers, modals, and shortcuts, you’ll need to enable interactivity. Head over to **Interactivity & Shortcuts** in your app configuration.
192192

@@ -288,7 +288,7 @@ You can see that we used `app.action()` to listen for the `action_id` that we na
288288

289289
---
290290

291-
### Next steps
291+
### Next steps {#next-steps}
292292
You just built your first [Bolt for Python app](https://github.com/slackapi/bolt-python/tree/main/examples/getting_started) with Socket Mode! 🎉
293293

294294
Now that you have a basic app up and running, you can start exploring how to make your Bolt app stand out. Here are some ideas about what to explore next:

docs/_tutorials/getting_started_http.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ When you're finished, you'll have this ⚡️[Getting Started with Slack app](ht
1818

1919
---
2020

21-
### Create an app
21+
### Create an app {#create-an-app}
2222
First thing's first: before you start developing with Bolt, you'll want to [create a Slack app](https://api.slack.com/apps/new).
2323

2424
> 💡 We recommend using a workspace where you won't disrupt real work getting done — [you can create a new one for free](https://slack.com/get-started#create).
@@ -33,7 +33,7 @@ Look around, add an app icon and description, and then let's start configuring y
3333

3434
---
3535

36-
### Tokens and installing apps
36+
### Tokens and installing apps {#tokens-and-installing-apps}
3737
Slack apps use [OAuth to manage access to Slack's APIs](https://api.slack.com/docs/oauth). When an app is installed, you'll receive a token that the app can use to call API methods.
3838

3939
There are three main token types available to a Slack app: user (`xoxp`), bot (`xoxb`), and app-level (`xapp`) tokens.
@@ -57,7 +57,7 @@ For brevity, we're going to use bot tokens for this guide.
5757
5858
---
5959

60-
### Setting up your project
60+
### Setting up your project {#setting-up-your-project}
6161
With the initial configuration handled, it's time to set up a new Bolt project. This is where you'll write the code that handles the logic for your app.
6262

6363
If you don’t already have a project, let’s create a new one. Create an empty directory:
@@ -127,7 +127,7 @@ Your app should let you know that it's up and running. 🎉
127127

128128
---
129129

130-
### Setting up events over http
130+
### Setting up events over HTTP {#setting-up-events}
131131
Your app behaves similarly to people on your team — it can post messages, add emoji reactions, and listen and respond to events.
132132

133133
To listen for events happening in a Slack workspace (like when a message is posted or when a reaction is posted to a message) you'll use the [Events API to subscribe to event types](https://api.slack.com/events-api).
@@ -153,7 +153,7 @@ If you want your bot to listen to messages from everywhere it is added to, choos
153153

154154
---
155155

156-
### Listening and responding to a message
156+
### Listening and responding to a message {#listening-and-responding-to-a-message}
157157
Your app is now ready for some logic. Let's start by using the `message()` method to attach a listener for messages.
158158

159159
The following example listens and responds to all messages in channels/DMs where your app has been added that contain the word "hello":
@@ -187,7 +187,7 @@ This is a basic example, but it gives you a place to start customizing your app
187187

188188
---
189189

190-
### Sending and responding to actions
190+
### Sending and responding to actions {#sending-and-responding-to-actions}
191191

192192
To use features like buttons, select menus, datepickers, modals, and shortcuts, you’ll need to enable interactivity. Similar to events, you'll need to specify a URL for Slack to send the action (such as *user clicked a button*).
193193

@@ -293,7 +293,7 @@ You can see that we used `app.action()` to listen for the `action_id` that we na
293293

294294
---
295295

296-
### Next steps
296+
### Next steps {#next-steps}
297297
You just built your first [Bolt for Python app](https://github.com/slackapi/bolt-python/tree/main/examples/getting_started)! 🎉
298298

299299
Now that you have a basic app up and running, you can start exploring how to make your Bolt app stand out. Here are some ideas about what to explore next:

docs/_tutorials/ja_getting_started.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ redirect_from:
2121
2222
---
2323

24-
### アプリを作成する
24+
### アプリを作成する {#create-an-app}
2525
最初にやるべきこと : Bolt での開発を始める前に、[Slack アプリを作成](https://api.slack.com/apps/new)します。
2626

2727
> 💡 いつもの仕事のさまたげにならないように、別の開発用のワークスペースを使用することをおすすめします。[新しいワークスペースは無料で作成できます](https://slack.com/get-started#create)
@@ -36,7 +36,7 @@ redirect_from:
3636

3737
---
3838

39-
### トークンとアプリのインストール
39+
### トークンとアプリのインストール {#tokens-and-installing-apps}
4040
Slack アプリでは、[Slack API へのアクセスの管理に OAuth を使用します](https://api.slack.com/docs/oauth)。アプリがインストールされると、トークンが発行されます。アプリはそのトークンを使って API メソッドを呼び出すことができます。
4141

4242
Slack アプリで使用できるトークンには、ユーザートークン(`xoxp`)とボットトークン(`xoxb`)、アプリレベルトークン(`xapp`)の 3 種類があります。
@@ -64,7 +64,7 @@ Slack アプリで使用できるトークンには、ユーザートークン
6464
6565
---
6666

67-
### プロジェクトをセットアップする
67+
### プロジェクトをセットアップする {#setting-up-your-project}
6868
初期設定が終わったら、新しい Bolt プロジェクトのセットアップを行いましょう。このプロジェクトが、あなたのアプリのロジックを処理するコードを配置する場所となります。
6969

7070
プロジェクトをまだ作成していない場合は、新しく作成しましょう。空のディレクトリを作成します。
@@ -134,7 +134,7 @@ python3 app.py
134134

135135
---
136136

137-
### イベントを設定する
137+
### イベントを設定する {#setting-up-events}
138138
アプリはワークスペース内の他のメンバーと同じように振る舞い、メッセージを投稿したり、絵文字リアクションを追加したり、イベントをリッスンして返答したりできます。
139139

140140
Slack ワークスペースで発生するイベント(メッセージが投稿されたときや、メッセージに対するリアクションがつけられたときなど)をリッスンするには、[Events API を使って特定の種類のイベントをサブスクライブします](https://api.slack.com/events-api)
@@ -155,7 +155,7 @@ Slack ワークスペースで発生するイベント(メッセージが投
155155

156156
---
157157

158-
### メッセージをリッスンして応答する
158+
### メッセージをリッスンして応答する {#listening-and-responding-to-a-message}
159159
アプリにロジックを組み込む準備が整いました。まずは `message()` メソッドを使用して、メッセージのリスナーをアタッチしましょう。
160160

161161
次の例では、アプリが参加するチャンネルとダイレクトメッセージに投稿されるすべてのメッセージをリッスンし、「hello」というメッセージに応答を返します。
@@ -187,7 +187,7 @@ if __name__ == "__main__":
187187

188188
---
189189

190-
### アクションを送信して応答する
190+
### アクションを送信して応答する {#sending-and-responding-to-actions}
191191

192192
インタラクティブ機能を有効にすると、ボタン、選択メニュー、日付ピッカー、モーダル、ショートカットなどの機能が利用できるようになります。アプリ設定ページの「**Interactivity & Shortcuts**」にアクセスしてください。
193193

@@ -286,12 +286,12 @@ if __name__ == "__main__":
286286

287287
---
288288

289-
### 次のステップ
289+
### 次のステップ {#next-steps}
290290
はじめての [Bolt for Python アプリ](https://github.com/slackapi/bolt-python/tree/main/examples/getting_started)をソケットモードを使って構築することができました。🎉
291291

292292
ここまでで基本的なアプリをセットアップして実行することはできたので、次は自分だけの Bolt アプリを作る方法を調べてみましょう。参考になりそうな記事をいくつかご紹介します。
293293

294-
* [基本的な概念](/bolt-python/concepts#basic)について読んでみてください。Bolt アプリがアクセスできるさまざまメソッドや機能について知ることができます。
295-
* [`events()` メソッド](/bolt-python/concepts#event-listening)でボットがリッスンできるイベントをほかにも試してみましょう。すべてのイベントの一覧は [API サイト](https://api.slack.com/events)で確認できます。
296-
* Bolt では、アプリにアタッチされたクライアントから [Web API メソッドを呼び出す](/bolt-python/concepts#web-api)ことができます。API サイトに [220 以上のメソッド](https://api.slack.com/methods)を一覧しています。
294+
* [基本的な概念](/bolt-python/ja-jp/concepts#basic)について読んでみてください。Bolt アプリがアクセスできるさまざまメソッドや機能について知ることができます。
295+
* [`events()` メソッド](/bolt-python/ja-jp/concepts#event-listening)でボットがリッスンできるイベントをほかにも試してみましょう。すべてのイベントの一覧は [API サイト](https://api.slack.com/events)で確認できます。
296+
* Bolt では、アプリにアタッチされたクライアントから [Web API メソッドを呼び出す](/bolt-python/ja-jp/concepts#web-api)ことができます。API サイトに [220 以上のメソッド](https://api.slack.com/methods)を一覧しています。
297297
* [API サイト](https://api.slack.com/docs/token-types)でほかのタイプのトークンを確認してみてください。アプリで実行したいアクションによって、異なるトークンが必要になる場合があります。ソケットモードを使わないアプリでは、通常はボットトークン (`xoxb`) と署名シークレットが必要です。ソケットモードを使わない場合の例については、 HTTP 方式のやり方としてこのチュートリアルと対になっている [Bolt 入門ガイド(HTTP)](/bolt-python/ja-jp/tutorial/getting-started-http)を参照してください。

docs/_tutorials/ja_getting_started_http.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ redirect_from:
1919

2020
---
2121

22-
### アプリを作成する
22+
### アプリを作成する {#create-an-app}
2323
最初にやるべきこと : Bolt での開発を始める前に、[Slack アプリを作成](https://api.slack.com/apps/new)します。
2424

2525
> 💡 いつもの仕事のさまたげにならないように、別の開発用のワークスペースを使用することをおすすめします。[新しいワークスペースは無料で作成できます](https://slack.com/get-started#create)
@@ -35,7 +35,7 @@ redirect_from:
3535

3636
---
3737

38-
### トークンとアプリのインストール
38+
### トークンとアプリのインストール {#tokens-and-installing-apps}
3939
Slack アプリでは、[Slack API へのアクセスの管理に OAuth を使用します](https://api.slack.com/docs/oauth)。アプリがインストールされると、トークンが発行されます。アプリはそのトークンを使って API メソッドを呼び出すことができます。
4040

4141
Slack アプリで使用できるトークンには、ユーザートークン(`xoxp`)とボットトークン(`xoxb`)、アプリレベルトークン(`xapp`)の 3 種類があります。
@@ -59,7 +59,7 @@ Slack アプリで使用できるトークンには、ユーザートークン
5959
6060
---
6161

62-
### プロジェクトをセットアップする
62+
### プロジェクトをセットアップする {#setting-up-your-project}
6363
初期設定が終わったら、新しい Bolt プロジェクトのセットアップを行いましょう。このプロジェクトが、あなたのアプリのロジックを処理するコードを配置する場所となります。
6464

6565
プロジェクトをまだ作成していない場合は、新しく作成しましょう。空のディレクトリを作成します。
@@ -132,7 +132,7 @@ python3 app.py
132132

133133
---
134134

135-
### HTTPを利用したイベントを設定する
135+
### HTTP を利用したイベントを設定する {#setting-up-events}
136136
アプリはワークスペース内の他のメンバーと同じように振る舞い、メッセージを投稿したり、絵文字リアクションを追加したり、イベントをリッスンして返答したりできます。
137137

138138
Slack ワークスペースで発生するイベント(メッセージが投稿されたときや、メッセージに対するリアクションがつけられたときなど)をリッスンするには、[Events API を使って特定の種類のイベントをサブスクライブします](https://api.slack.com/events-api)
@@ -158,7 +158,7 @@ Slack ワークスペースで発生するイベント(メッセージが投
158158

159159
---
160160

161-
### メッセージをリッスンして応答する
161+
### メッセージをリッスンして応答する {#listening-and-responding-to-a-message}
162162
アプリにロジックを組み込む準備が整いました。まずは `message()` メソッドを使用して、メッセージのリスナーをアタッチしましょう。
163163

164164
次の例では、アプリが参加するチャンネルとダイレクトメッセージに投稿されるすべてのメッセージをリッスンし、「hello」というメッセージに応答を返します。
@@ -192,7 +192,7 @@ if __name__ == "__main__":
192192

193193
---
194194

195-
### アクションを送信して応答する
195+
### アクションを送信して応答する {#sending-and-responding-to-actions}
196196

197197
インタラクティブ機能を有効にすると、ボタン、選択メニュー、日付ピッカー、モーダル、ショートカットなどの機能が利用できるようになります。イベントと同様に、Slack からのアクション(*ユーザーがボタンをクリックした*など)の送信先となる URL を設定する必要があります。
198198

@@ -299,12 +299,12 @@ if __name__ == "__main__":
299299

300300
---
301301

302-
### 次のステップ
302+
### 次のステップ {#next-steps}
303303
はじめての [Bolt for Python アプリ](https://github.com/slackapi/bolt-python/tree/main/examples/getting_started)を構築することができました。🎉
304304

305305
ここまでで基本的なアプリをセットアップして実行することはできたので、次は自分だけの Bolt アプリを作る方法を調べてみましょう。参考になりそうな記事をいくつかご紹介します。
306306

307-
* [基本的な概念](/bolt-python/concepts#basic)について読む。Bolt アプリがアクセスできるさまざまメソッドや機能について知ることができます。
308-
* [`events()` メソッド](/bolt-python/concepts#event-listening)でボットがリッスンできるイベントをほかにも試してみる。すべてのイベントの一覧は [API サイト](https://api.slack.com/events)で確認できます。
309-
* Bolt では、アプリにアタッチされたクライアントから [Web API メソッドを呼び出す](/bolt-python/concepts#web-api)ことができます。API サイトに [220 以上のメソッド](https://api.slack.com/methods)を一覧しています。
307+
* [基本的な概念](/bolt-python/ja-jp/concepts#basic)について読む。Bolt アプリがアクセスできるさまざまメソッドや機能について知ることができます。
308+
* [`events()` メソッド](/bolt-python/ja-jp/concepts#event-listening)でボットがリッスンできるイベントをほかにも試してみる。すべてのイベントの一覧は [API サイト](https://api.slack.com/events)で確認できます。
309+
* Bolt では、アプリにアタッチされたクライアントから [Web API メソッドを呼び出す](/bolt-python/ja-jp/concepts#web-api)ことができます。API サイトに [220 以上のメソッド](https://api.slack.com/methods)を一覧しています。
310310
* [API サイト](https://api.slack.com/docs/token-types)でほかのタイプのトークンを確認する。アプリで実行したいアクションによって、異なるトークンが必要になる場合があります。HTTPの代わりにソケットモードを利用したい場合には、`connections:write` のスコープを追加した、追加のトークン (`xapp`) が必要です。

0 commit comments

Comments
 (0)