OWASP / Nest

Explore OWASP and be a part of it
https://nest.owasp.dev
MIT License
10 stars 11 forks source link

Bump slack-bolt from 1.20.1 to 1.21.0 in /backend #34

Closed dependabot[bot] closed 1 month ago

dependabot[bot] commented 1 month ago

Bumps slack-bolt from 1.20.1 to 1.21.0.

Release notes

Sourced from slack-bolt's releases.

version 1.21.0

New Features

Agents & Assistants

A better Agents & Assistants support in Bolt is now available!

While you already can implement your agents using app.event(...) listeners for assistant_thread_started, assistant_thread_context_changed, and message events, Bolt offers a simpler approach. You just need to create an Assistant instance, attach the needed event handlers to it, and then add the assistant to your App instance.

assistant = Assistant()

This listener is invoked when a human user opened an assistant thread

@​assistant.thread_started def start_assistant_thread(say: Say, set_suggested_prompts: SetSuggestedPrompts): # Send the first reply to the human who started chat with your app's assistant bot say(":wave: Hi, how can I help you today?")

# Setting suggested prompts is optional
set_suggested_prompts(
    prompts=[
        # If the suggested prompt is long, you can use {"title": "short one to display", "message": "full prompt"} instead
        "What does SLACK stand for?",
        "When Slack was released?",
    ],
)

This listener is invoked when the human user sends a reply in the assistant thread

@​assistant.user_message def respond_in_assistant_thread( payload: dict, logger: logging.Logger, context: BoltContext, set_status: SetStatus, say: Say, client: WebClient, ): try: # Tell the human user the assistant bot acknowledges the request and is working on it set_status("is typing...")

    # Collect the conversation history with this user
    replies_in_thread = client.conversations_replies(
        channel=context.channel_id,
        ts=context.thread_ts,
        oldest=context.thread_ts,
        limit=10,
    )
    messages_in_thread: List[Dict[str, str]] = []
    for message in replies_in_thread["messages"]:

</tr></table>

... (truncated)

Commits


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)