From 4006d8a40b219e0c3a90c6dbb20d58d737d9d08f Mon Sep 17 00:00:00 2001 From: Lorenzo Aiello Date: Thu, 14 Nov 2024 11:49:13 -0800 Subject: [PATCH] chore: Adding A Deprecation Notice for rtm.start (no-op) --- rtm.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/rtm.go b/rtm.go index ef6ba3434..9b30eb315 100644 --- a/rtm.go +++ b/rtm.go @@ -25,6 +25,9 @@ const ( // StartRTM calls the "rtm.start" endpoint and returns the provided URL and the full Info block. // // To have a fully managed Websocket connection, use `NewRTM`, and call `ManageConnection()` on it. +// +// Deprecated: Use [ConnectRTM] instead. +// For more details, see: https://api.slack.com/changelog/2021-10-rtm-start-to-stop func (api *Client) StartRTM() (info *Info, websocketURL string, err error) { ctx, cancel := context.WithTimeout(context.Background(), websocketDefaultTimeout) defer cancel() @@ -35,6 +38,9 @@ func (api *Client) StartRTM() (info *Info, websocketURL string, err error) { // StartRTMContext calls the "rtm.start" endpoint and returns the provided URL and the full Info block with a custom context. // // To have a fully managed Websocket connection, use `NewRTM`, and call `ManageConnection()` on it. +// +// Deprecated: Use [ConnectRTMContext] instead. +// For more details, see: https://api.slack.com/changelog/2021-10-rtm-start-to-stop func (api *Client) StartRTMContext(ctx context.Context) (info *Info, websocketURL string, err error) { response := &infoResponseFull{} err = api.postMethod(ctx, "rtm.start", url.Values{"token": {api.token}}, response)