github slack-go/slack v0.32.0

one hour ago

This release expands Slack Code support with channel views, context bars, and canvas collaboration, and fixes permission diagnostics, slash-command decoding, and workflow-button validation.

Important

Please read all the notes below, not just the breaking changes. Some changes deserve paying close attention to, like new fields in SlackResponse, and all the new *AgentConversation* methods.

Breaking changes

  • Update interfaces, mocks, and function values that use the old canvas creation
    signatures.
    CreateCanvas and CreateCanvasContext now accept
    options ...CreateCanvasOption. Existing direct calls still compile, but these
    methods no longer satisfy interfaces with the old fixed signatures. Add the
    variadic parameter to interface and mock declarations; adapt stored function
    values or wrap the call in a function with the old signature.
  • Use field names when initializing Properties, SlackResponse,
    KickUserFromConversationSlackResponse, or SlackErrorResponse.
    New fields
    make positional literals fail to compile. Existing keyed literals still work.

Added

  • Show code diffs, HTML reports, Block Kit interfaces, and canvases in Slack Code
    channels.
    Use SetAgentConversationView to publish or update a view,
    ListAgentConversationViews to discover attached views, and
    RemoveAgentConversationView to remove them. All have Context variants.
    Slack documents pull-request views too, but live requests have returned
    invalid_view_type; publish a unified diff with AgentViewTypeDiff if that
    happens.
  • Give a code channel useful context. Set context-bar links, action items,
    a summary message, and external resource details with
    SetAgentConversationProperties or its Context variant. Read session status,
    title, assigned agents, origin message, context-bar ownership, summary, and
    managed views through Properties.AgentSession and Properties.CodeChannel
    in conversation responses.
  • Read and revise canvases attached to code channels.
    GetAgentConversationCanvas retrieves markdown and comment threads, including
    replies and optional resolved threads. SetAgentConversationCanvasContent
    replaces the markdown while preserving section IDs and comment anchors on
    unchanged sections. Both have Context variants.
  • Create a canvas directly in a channel, including in free workspaces that
    require a channel. Pass CreateCanvasOptionChannelID(channelID) to
    CreateCanvas or CreateCanvasContext (#1623).
  • Try the new examples/slack_code CLI for channel
    setup, context bars, views, canvases, commands, metadata inspection, and archival.
    It includes sample HTML, Block Kit, markdown, and unified-diff files.

Fixed

  • See which scopes are missing when an API call fails. Slack's needed and
    provided values are now preserved in responses and SlackErrorResponse, even
    for methods that return only an error. Use errors.As to inspect Needed and
    Provided; the error text is unchanged.
  • Discover code-channel views even when Slack returns an empty legacy views
    array.
    ListAgentConversationViews also preserves session_views, including
    view types, names, and owner IDs.
  • Receive slash commands when Slack omits is_enterprise_install. JSON
    decoding now accepts absent or null values, including observed Slack Code
    context-bar action deliveries over Socket Mode.
  • Send workflow buttons without an action ID. An empty
    WorkflowButtonBlockElement.ActionID is omitted from JSON so the button passes
    Slack's block validation. Populated IDs are preserved.

Documentation and testing

  • Clarify that Slack documents raw_number table cells for publishing. If a
    workspace rejects them with invalid_blocks, send the number as a
    TableRawTextCell. Null cells remain a received-only representation.
  • Add regression coverage for code-channel lifecycle events, Block Kit view
    interactions, and agent slash commands through the existing HTTP and Socket
    Mode parsers and handlers.

Full Changelog: v0.31.0...v0.32.0

Don't miss a new slack release

NewReleases is sending notifications on new releases.