Skip to content

Commit b904e41

Browse files
committed
Apply v3.10.1 changes to API docs
1 parent 4fec036 commit b904e41

File tree

4 files changed

+124
-115
lines changed

4 files changed

+124
-115
lines changed

docs/api-docs/slack_sdk/version.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ <h1 class="title">Module <code>slack_sdk.version</code></h1>
2828
<span>Expand source code</span>
2929
</summary>
3030
<pre><code class="python">&#34;&#34;&#34;Check the latest version at https://pypi.org/project/slack-sdk/&#34;&#34;&#34;
31-
__version__ = &#34;3.10.0&#34;</code></pre>
31+
__version__ = &#34;3.10.1&#34;</code></pre>
3232
</details>
3333
</section>
3434
<section>

docs/api-docs/slack_sdk/web/async_client.html

Lines changed: 45 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -2877,29 +2877,30 @@ <h1 class="title">Module <code>slack_sdk.web.async_client</code></h1>
28772877
&#34;You cannot specify both the file and the content argument.&#34;
28782878
)
28792879

2880-
if file:
2881-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
2882-
# use the local filename if filename is missing
2883-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
2884-
return await self.api_call(
2885-
&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs
2886-
)
2887-
data = kwargs.copy()
2888-
data.update(
2880+
if isinstance(channels, (list, Tuple)):
2881+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
2882+
else:
2883+
kwargs.update({&#34;channels&#34;: channels})
2884+
kwargs.update(
28892885
{
2890-
&#34;content&#34;: content,
28912886
&#34;filename&#34;: filename,
28922887
&#34;filetype&#34;: filetype,
28932888
&#34;initial_comment&#34;: initial_comment,
28942889
&#34;thread_ts&#34;: thread_ts,
28952890
&#34;title&#34;: title,
28962891
}
28972892
)
2898-
if isinstance(channels, (list, Tuple)):
2899-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
2893+
if file:
2894+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
2895+
# use the local filename if filename is missing
2896+
if kwargs.get(&#34;filename&#34;) is None:
2897+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
2898+
return await self.api_call(
2899+
&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs
2900+
)
29002901
else:
2901-
kwargs.update({&#34;channels&#34;: channels})
2902-
return await self.api_call(&#34;files.upload&#34;, data=data)
2902+
kwargs[&#34;content&#34;] = content
2903+
return await self.api_call(&#34;files.upload&#34;, data=kwargs)
29032904

29042905
# --------------------------
29052906
# Deprecated: groups.*
@@ -7217,29 +7218,30 @@ <h2 id="note">Note</h2>
72177218
&#34;You cannot specify both the file and the content argument.&#34;
72187219
)
72197220

7220-
if file:
7221-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
7222-
# use the local filename if filename is missing
7223-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
7224-
return await self.api_call(
7225-
&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs
7226-
)
7227-
data = kwargs.copy()
7228-
data.update(
7221+
if isinstance(channels, (list, Tuple)):
7222+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
7223+
else:
7224+
kwargs.update({&#34;channels&#34;: channels})
7225+
kwargs.update(
72297226
{
7230-
&#34;content&#34;: content,
72317227
&#34;filename&#34;: filename,
72327228
&#34;filetype&#34;: filetype,
72337229
&#34;initial_comment&#34;: initial_comment,
72347230
&#34;thread_ts&#34;: thread_ts,
72357231
&#34;title&#34;: title,
72367232
}
72377233
)
7238-
if isinstance(channels, (list, Tuple)):
7239-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
7234+
if file:
7235+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
7236+
# use the local filename if filename is missing
7237+
if kwargs.get(&#34;filename&#34;) is None:
7238+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
7239+
return await self.api_call(
7240+
&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs
7241+
)
72407242
else:
7241-
kwargs.update({&#34;channels&#34;: channels})
7242-
return await self.api_call(&#34;files.upload&#34;, data=data)
7243+
kwargs[&#34;content&#34;] = content
7244+
return await self.api_call(&#34;files.upload&#34;, data=kwargs)
72437245

72447246
# --------------------------
72457247
# Deprecated: groups.*
@@ -13093,29 +13095,30 @@ <h3>Methods</h3>
1309313095
&#34;You cannot specify both the file and the content argument.&#34;
1309413096
)
1309513097

13096-
if file:
13097-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
13098-
# use the local filename if filename is missing
13099-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
13100-
return await self.api_call(
13101-
&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs
13102-
)
13103-
data = kwargs.copy()
13104-
data.update(
13098+
if isinstance(channels, (list, Tuple)):
13099+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
13100+
else:
13101+
kwargs.update({&#34;channels&#34;: channels})
13102+
kwargs.update(
1310513103
{
13106-
&#34;content&#34;: content,
1310713104
&#34;filename&#34;: filename,
1310813105
&#34;filetype&#34;: filetype,
1310913106
&#34;initial_comment&#34;: initial_comment,
1311013107
&#34;thread_ts&#34;: thread_ts,
1311113108
&#34;title&#34;: title,
1311213109
}
1311313110
)
13114-
if isinstance(channels, (list, Tuple)):
13115-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
13111+
if file:
13112+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
13113+
# use the local filename if filename is missing
13114+
if kwargs.get(&#34;filename&#34;) is None:
13115+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
13116+
return await self.api_call(
13117+
&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs
13118+
)
1311613119
else:
13117-
kwargs.update({&#34;channels&#34;: channels})
13118-
return await self.api_call(&#34;files.upload&#34;, data=data)</code></pre>
13120+
kwargs[&#34;content&#34;] = content
13121+
return await self.api_call(&#34;files.upload&#34;, data=kwargs)</code></pre>
1311913122
</details>
1312013123
</dd>
1312113124
<dt id="slack_sdk.web.async_client.AsyncWebClient.groups_archive"><code class="name flex">

docs/api-docs/slack_sdk/web/client.html

Lines changed: 39 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -2826,27 +2826,28 @@ <h1 class="title">Module <code>slack_sdk.web.client</code></h1>
28262826
&#34;You cannot specify both the file and the content argument.&#34;
28272827
)
28282828

2829-
if file:
2830-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
2831-
# use the local filename if filename is missing
2832-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
2833-
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
2834-
data = kwargs.copy()
2835-
data.update(
2829+
if isinstance(channels, (list, Tuple)):
2830+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
2831+
else:
2832+
kwargs.update({&#34;channels&#34;: channels})
2833+
kwargs.update(
28362834
{
2837-
&#34;content&#34;: content,
28382835
&#34;filename&#34;: filename,
28392836
&#34;filetype&#34;: filetype,
28402837
&#34;initial_comment&#34;: initial_comment,
28412838
&#34;thread_ts&#34;: thread_ts,
28422839
&#34;title&#34;: title,
28432840
}
28442841
)
2845-
if isinstance(channels, (list, Tuple)):
2846-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
2842+
if file:
2843+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
2844+
# use the local filename if filename is missing
2845+
if kwargs.get(&#34;filename&#34;) is None:
2846+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
2847+
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
28472848
else:
2848-
kwargs.update({&#34;channels&#34;: channels})
2849-
return self.api_call(&#34;files.upload&#34;, data=data)
2849+
kwargs[&#34;content&#34;] = content
2850+
return self.api_call(&#34;files.upload&#34;, data=kwargs)
28502851

28512852
# --------------------------
28522853
# Deprecated: groups.*
@@ -7112,27 +7113,28 @@ <h2 id="note">Note</h2>
71127113
&#34;You cannot specify both the file and the content argument.&#34;
71137114
)
71147115

7115-
if file:
7116-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
7117-
# use the local filename if filename is missing
7118-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
7119-
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
7120-
data = kwargs.copy()
7121-
data.update(
7116+
if isinstance(channels, (list, Tuple)):
7117+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
7118+
else:
7119+
kwargs.update({&#34;channels&#34;: channels})
7120+
kwargs.update(
71227121
{
7123-
&#34;content&#34;: content,
71247122
&#34;filename&#34;: filename,
71257123
&#34;filetype&#34;: filetype,
71267124
&#34;initial_comment&#34;: initial_comment,
71277125
&#34;thread_ts&#34;: thread_ts,
71287126
&#34;title&#34;: title,
71297127
}
71307128
)
7131-
if isinstance(channels, (list, Tuple)):
7132-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
7129+
if file:
7130+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
7131+
# use the local filename if filename is missing
7132+
if kwargs.get(&#34;filename&#34;) is None:
7133+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
7134+
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
71337135
else:
7134-
kwargs.update({&#34;channels&#34;: channels})
7135-
return self.api_call(&#34;files.upload&#34;, data=data)
7136+
kwargs[&#34;content&#34;] = content
7137+
return self.api_call(&#34;files.upload&#34;, data=kwargs)
71367138

71377139
# --------------------------
71387140
# Deprecated: groups.*
@@ -12934,27 +12936,28 @@ <h3>Methods</h3>
1293412936
&#34;You cannot specify both the file and the content argument.&#34;
1293512937
)
1293612938

12937-
if file:
12938-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
12939-
# use the local filename if filename is missing
12940-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
12941-
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
12942-
data = kwargs.copy()
12943-
data.update(
12939+
if isinstance(channels, (list, Tuple)):
12940+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
12941+
else:
12942+
kwargs.update({&#34;channels&#34;: channels})
12943+
kwargs.update(
1294412944
{
12945-
&#34;content&#34;: content,
1294612945
&#34;filename&#34;: filename,
1294712946
&#34;filetype&#34;: filetype,
1294812947
&#34;initial_comment&#34;: initial_comment,
1294912948
&#34;thread_ts&#34;: thread_ts,
1295012949
&#34;title&#34;: title,
1295112950
}
1295212951
)
12953-
if isinstance(channels, (list, Tuple)):
12954-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
12952+
if file:
12953+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
12954+
# use the local filename if filename is missing
12955+
if kwargs.get(&#34;filename&#34;) is None:
12956+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
12957+
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
1295512958
else:
12956-
kwargs.update({&#34;channels&#34;: channels})
12957-
return self.api_call(&#34;files.upload&#34;, data=data)</code></pre>
12959+
kwargs[&#34;content&#34;] = content
12960+
return self.api_call(&#34;files.upload&#34;, data=kwargs)</code></pre>
1295812961
</details>
1295912962
</dd>
1296012963
<dt id="slack_sdk.web.client.WebClient.groups_archive"><code class="name flex">

docs/api-docs/slack_sdk/web/legacy_client.html

Lines changed: 39 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -2836,27 +2836,28 @@ <h1 class="title">Module <code>slack_sdk.web.legacy_client</code></h1>
28362836
&#34;You cannot specify both the file and the content argument.&#34;
28372837
)
28382838

2839-
if file:
2840-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
2841-
# use the local filename if filename is missing
2842-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
2843-
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
2844-
data = kwargs.copy()
2845-
data.update(
2839+
if isinstance(channels, (list, Tuple)):
2840+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
2841+
else:
2842+
kwargs.update({&#34;channels&#34;: channels})
2843+
kwargs.update(
28462844
{
2847-
&#34;content&#34;: content,
28482845
&#34;filename&#34;: filename,
28492846
&#34;filetype&#34;: filetype,
28502847
&#34;initial_comment&#34;: initial_comment,
28512848
&#34;thread_ts&#34;: thread_ts,
28522849
&#34;title&#34;: title,
28532850
}
28542851
)
2855-
if isinstance(channels, (list, Tuple)):
2856-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
2852+
if file:
2853+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
2854+
# use the local filename if filename is missing
2855+
if kwargs.get(&#34;filename&#34;) is None:
2856+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
2857+
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
28572858
else:
2858-
kwargs.update({&#34;channels&#34;: channels})
2859-
return self.api_call(&#34;files.upload&#34;, data=data)
2859+
kwargs[&#34;content&#34;] = content
2860+
return self.api_call(&#34;files.upload&#34;, data=kwargs)
28602861

28612862
# --------------------------
28622863
# Deprecated: groups.*
@@ -7122,27 +7123,28 @@ <h2 id="note">Note</h2>
71227123
&#34;You cannot specify both the file and the content argument.&#34;
71237124
)
71247125

7125-
if file:
7126-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
7127-
# use the local filename if filename is missing
7128-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
7129-
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
7130-
data = kwargs.copy()
7131-
data.update(
7126+
if isinstance(channels, (list, Tuple)):
7127+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
7128+
else:
7129+
kwargs.update({&#34;channels&#34;: channels})
7130+
kwargs.update(
71327131
{
7133-
&#34;content&#34;: content,
71347132
&#34;filename&#34;: filename,
71357133
&#34;filetype&#34;: filetype,
71367134
&#34;initial_comment&#34;: initial_comment,
71377135
&#34;thread_ts&#34;: thread_ts,
71387136
&#34;title&#34;: title,
71397137
}
71407138
)
7141-
if isinstance(channels, (list, Tuple)):
7142-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
7139+
if file:
7140+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
7141+
# use the local filename if filename is missing
7142+
if kwargs.get(&#34;filename&#34;) is None:
7143+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
7144+
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
71437145
else:
7144-
kwargs.update({&#34;channels&#34;: channels})
7145-
return self.api_call(&#34;files.upload&#34;, data=data)
7146+
kwargs[&#34;content&#34;] = content
7147+
return self.api_call(&#34;files.upload&#34;, data=kwargs)
71467148

71477149
# --------------------------
71487150
# Deprecated: groups.*
@@ -12944,27 +12946,28 @@ <h3>Methods</h3>
1294412946
&#34;You cannot specify both the file and the content argument.&#34;
1294512947
)
1294612948

12947-
if file:
12948-
if &#34;filename&#34; not in kwargs and isinstance(file, str):
12949-
# use the local filename if filename is missing
12950-
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
12951-
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
12952-
data = kwargs.copy()
12953-
data.update(
12949+
if isinstance(channels, (list, Tuple)):
12950+
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
12951+
else:
12952+
kwargs.update({&#34;channels&#34;: channels})
12953+
kwargs.update(
1295412954
{
12955-
&#34;content&#34;: content,
1295612955
&#34;filename&#34;: filename,
1295712956
&#34;filetype&#34;: filetype,
1295812957
&#34;initial_comment&#34;: initial_comment,
1295912958
&#34;thread_ts&#34;: thread_ts,
1296012959
&#34;title&#34;: title,
1296112960
}
1296212961
)
12963-
if isinstance(channels, (list, Tuple)):
12964-
kwargs.update({&#34;channels&#34;: &#34;,&#34;.join(channels)})
12962+
if file:
12963+
if &#34;filename&#34; not in kwargs and isinstance(file, str):
12964+
# use the local filename if filename is missing
12965+
if kwargs.get(&#34;filename&#34;) is None:
12966+
kwargs[&#34;filename&#34;] = file.split(os.path.sep)[-1]
12967+
return self.api_call(&#34;files.upload&#34;, files={&#34;file&#34;: file}, data=kwargs)
1296512968
else:
12966-
kwargs.update({&#34;channels&#34;: channels})
12967-
return self.api_call(&#34;files.upload&#34;, data=data)</code></pre>
12969+
kwargs[&#34;content&#34;] = content
12970+
return self.api_call(&#34;files.upload&#34;, data=kwargs)</code></pre>
1296812971
</details>
1296912972
</dd>
1297012973
<dt id="slack_sdk.web.legacy_client.LegacyWebClient.groups_archive"><code class="name flex">

0 commit comments

Comments
 (0)