-
Notifications
You must be signed in to change notification settings - Fork 838
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to send image with files_upload_v2()
to single user
#1426
Comments
Hi @natalevichmv! 👋 Thanks for writing in. This error is expected, as the One way you can do this is supply the channel_id of the DM between your with the user. Or you can share the file in a general channel where both your app user and the target user are members. |
👋 It looks like this issue has been open for 30 days with no activity. We'll mark this as stale for now, and wait 10 days for an update or for further comment before closing this issue out. If you think this issue needs to be prioritized, please comment to get the thread going again! Maintainers also review issues marked as stale on a regular basis and comment or adjust status if the issue needs to be reprioritized. |
As this issue has been inactive for more than one month, we will be closing it. Thank you to all the participants! If you would like to raise a related issue, please create a new issue which includes your specific details and references this issue number. |
Reopening because the 'v1' version of the upload files would allow files to be shared in a private 'chat'. The v2 API breaks this behavior. |
FileUploadV2 is breaking V1 in two ways:
|
I agree^^ this is an issue. |
Can't figure out the way to send image to user using
files_upload_v2()
.Error:
slack_sdk.errors.SlackApiError: The request to the Slack API failed. (url: https://www.slack.com/api/files.completeUploadExternal) The server responded with: {'ok': False, 'error': 'invalid_arguments', 'response_metadata': {'messages': ['[ERROR] input must match regex patt ern: ^[CGDZ][A-Z0-9]{8,}$ [json-pointer:/channel_id]']}}
It seems from the error message that ChannelID must start with C, G, D or Z, whereas my UserID starts with U.
The Slack SDK version
slack-sdk==3.23.0
Python runtime version
Python 3.10.4
OS info
Ubuntu 20.04
The text was updated successfully, but these errors were encountered: