-
Notifications
You must be signed in to change notification settings - Fork 853
Closed
Labels
Version: 3xenhancementM-T: A feature request for new functionalityM-T: A feature request for new functionalityweb-client
Milestone
Description
The use case reported at #1259 (comment) has been supported for a long time but it was not by design.
client = WebClient(token="....")
client.chat_postMessage(text="fallback", blocks="{ JSON string here }")The blocks and attachments arguments for chat.postMessage API etc. are supposed to be Sequence[Block | Attachment | dict] as of today. However, passing the whole blocks/attachments as a single str should be a relatively common use case. In future versions, the use case should be clearly covered in both type hints and its implementation.
Category (place an x in each of the [ ])
- slack_sdk.web.WebClient (sync/async) (Web API client)
- slack_sdk.webhook.WebhookClient (sync/async) (Incoming Webhook, response_url sender)
- slack_sdk.models (UI component builders)
- slack_sdk.oauth (OAuth Flow Utilities)
- slack_sdk.socket_mode (Socket Mode client)
- slack_sdk.audit_logs (Audit Logs API client)
- slack_sdk.scim (SCIM API client)
- slack_sdk.rtm (RTM client)
- slack_sdk.signature (Request Signature Verifier)
Requirements
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Version: 3xenhancementM-T: A feature request for new functionalityM-T: A feature request for new functionalityweb-client