Skip to content

Commit 3b05b5f

Browse files
committed
Add comments on WorkflowStep initialization
1 parent 25459cc commit 3b05b5f

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

slack_bolt/workflows/step/async_step.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,18 @@ def __init__(
308308
app_name: Optional[str] = None,
309309
base_logger: Optional[Logger] = None,
310310
):
311+
"""
312+
Args:
313+
callback_id: The callback_id for this workflow step
314+
edit: Either a single function or a list of functions for opening a modal in the builder UI
315+
When it's a list, the first one is responsible for ack() while the rest are lazy listeners.
316+
save: Either a single function or a list of functions for handling modal interactions in the builder UI
317+
When it's a list, the first one is responsible for ack() while the rest are lazy listeners.
318+
execute: Either a single function or a list of functions for handling workflow step executions
319+
When it's a list, the first one is responsible for ack() while the rest are lazy listeners.
320+
app_name: The app name that can be mainly used for logging
321+
base_logger: The logger instance that can be used as a template when creating this step's logger
322+
"""
311323
self.callback_id = callback_id
312324
app_name = app_name or __name__
313325
self.edit = self.build_listener(

slack_bolt/workflows/step/step.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -319,6 +319,18 @@ def __init__(
319319
app_name: Optional[str] = None,
320320
base_logger: Optional[Logger] = None,
321321
):
322+
"""
323+
Args:
324+
callback_id: The callback_id for this workflow step
325+
edit: Either a single function or a list of functions for opening a modal in the builder UI
326+
When it's a list, the first one is responsible for ack() while the rest are lazy listeners.
327+
save: Either a single function or a list of functions for handling modal interactions in the builder UI
328+
When it's a list, the first one is responsible for ack() while the rest are lazy listeners.
329+
execute: Either a single function or a list of functions for handling workflow step executions
330+
When it's a list, the first one is responsible for ack() while the rest are lazy listeners.
331+
app_name: The app name that can be mainly used for logging
332+
base_logger: The logger instance that can be used as a template when creating this step's logger
333+
"""
322334
self.callback_id = callback_id
323335
app_name = app_name or __name__
324336
self.edit = self.build_listener(

0 commit comments

Comments
 (0)