kolfild26 opened a new issue, #33391: URL: https://github.com/apache/airflow/issues/33391
### Description I would like to suggest changes in `SlackAPIPostOperator`. SlackAPIPostOperator is supposed to send message to Slack. Now, there is no responce left after the execution finished. Would be good to save its `ts` and `channel` to XCOM once it's finished successfully. It looks to be quite easy because [here](https://github.com/apache/airflow/blob/main/airflow/providers/slack/operators/slack.py#L84) we actually have [chat.postMessage](https://api.slack.com/methods/chat.postMessage) responce from Slack which includes all needed info. Then we could push it to XCOM. ``` responce = self.hook.call(self.method, json=self.api_params) ti = kwargs['context']['task_instance'] ti.xcom_push(key="ts", value=responce['ts']) ti.xcom_push(key="channel", value=responce['channel']) ``` It will look like:  or  ### Use case/motivation Motivation is to have access to the timestamps of the sent messages in order to track them futher - change/delete. In Slack the only way to do it is to know its timestamp (& channel of course). The case is quite specific and may not be usefull for others, so before open a PR, would like to know if this suggestion have chances to be accepted. ### Related issues _No response_ ### Are you willing to submit a PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
