slackapi / java-slack-sdk

Slack Developer Kit (including Bolt for Java) for any JVM language
https://tools.slack.dev/java-slack-sdk/
MIT License
576 stars 214 forks source link

Question about RTM.start vs rtm.connect #1066

Closed RajeevLochan82 closed 1 year ago

RajeevLochan82 commented 2 years ago

We have a java application which listen to slack channels and post appropriate response. After receiving the email about depreciation of rtm.start function, I modified our slack application to use rtm.connect function. By making this change our application was working fine and I did not have to make any additional code changes. But starting 9/27 evening our application stopped working. It looks like the response provided by connect is completely different than start function. As our application was working fine, so I did not looked further in our code for any additional changes.

It looks like our application was parsing following additional data from rtm.start() JSON response. Can you please provide me a sample of old rtm.start() function and also suggest what alternative APIs we will need to use together with rtm.connect() function to get the following data?

Users Members Bots Channels Groups Ims Self Team url

WilliamBergamin commented 2 years ago

Hi @RajeevLochan82 thanks for writing in!

Here is the rtm.start() function as mentioned in the api documentation other Web API methods may be required to fetch all the data rtm start could obtain, for example Users can be fetched using users.list, groups usergroups.list, here are all the API methods available.

In terms of suggestions, I would recommend exploring Socket Mode as an alternative to RTM since RTM isn’t available for modern scoped apps anymore as mentioned in the notes of the RTM guide

RajeevLochan82 commented 2 years ago

Hello,

Can I get sample JSON response of old rtm.start() function ?

WilliamBergamin commented 2 years ago

Here is a sample of what a payload for rtm.start() can look like, other samples can also be found in this folder

seratch commented 2 years ago

Checking this migration guide may be helpful too: https://api.slack.com/changelog/2021-10-rtm-start-to-stop#how__looking-for-conversations-users-preferences-and-plans

RajeevLochan82 commented 2 years ago

Any limitations if we choose to develop this slack application in .Net vs Java ? Most of the example code seem to be provided in Java, so wondering if there are any limitations if we try to develop this slack application in .Net. Please let me know if there are any recommendations.

WilliamBergamin commented 2 years ago

We unfortunately do not officially support .Net if you want to use it you would have to use a third party open sourced library. I am unable to comment on the developer experience since I've never used .Net.

We develop and support the Bolt family of frameworks along with the SDKs found in the slackapi org, we also create and maintain sample projects that use theses frameworks and SDK's

github-actions[bot] commented 1 year ago

👋 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.

github-actions[bot] commented 1 year ago

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.