-
-
Notifications
You must be signed in to change notification settings - Fork 349
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
Upload file to slack #166
Comments
Maybe you can try this piece of code
Here you need to install the okhttp3 and Meteoroid, You can add more check or operations to send different files. |
yeah, the above code is quite helpful! |
|
so helpful Mr @Lionelsy , thank you so much |
My pleasure : ) |
I saw the issue about uploading file to slack
public void postFileToSlack(Event event, File file) throws IOException {
okhttp3.Response response = new Meteoroid.Builder()
.token("YOUR-TOKEN")
.channels(event.getChannelId())
.uploadFile(file)
.build()
.post();
response.close();
}
but i can't get it, where can i add the function in JBot code, help me please
The text was updated successfully, but these errors were encountered: