Git Product home page Git Product logo

Comments (6)

joeltoby avatar joeltoby commented on August 11, 2024

Button clicks are not slack events - they are not provided by the RTM API.

Button clicks require a callback handler /URL which is out of scope for this library.

Please see the 'Responding to message actions' section of the doc: https://api.slack.com/docs/message-buttons

from java-slack-sdk.

itayktest avatar itayktest commented on August 11, 2024

Thanks for fast response
Will this option be someday in this library?

from java-slack-sdk.

joeltoby avatar joeltoby commented on August 11, 2024

I can't see that ever happening personally. It's out of scope because it isn't really something that can be included in a library. It would require a web server to receive the callbacks and each application has a different requirement for handling the button clicks.

Having said that, I don't run the project :) @seratch ?

from java-slack-sdk.

seratch avatar seratch commented on August 11, 2024

Right, I don't have any plans to do something.

from java-slack-sdk.

seratch avatar seratch commented on August 11, 2024

After 1.5 years, I've implemented some features to easily build a Slack App backend to handle the scenario discussed here. Actually, it's not possible to receive the event as an RTM events, but we can receive interactive messages on our side side.

Check the classes under this package. I've already started using these classes for my personal Slack apps.

For example, let's say a user clicks a button in a message made of BlockKit components. At the time, your Slack App backend receives a HTTP request from Slack Platform. The request body contains a payload which has the type block_actions as below. You can use this class to bind the request body. Here is a simple example code.

from java-slack-sdk.

seratch avatar seratch commented on August 11, 2024

Please allow me close this issue. Feel free to reopen this when you have something to discuss further here at any time.

from java-slack-sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.