# How to get the last user input in Rasa

**URL:** <https://forum.rasa.com/t/how-to-get-the-last-user-input-in-rasa/29549>\
**Category:** Rasa Open Source\
**Created:** [May 31, 2020, 4:52am UTC](https://forum.rasa.com/t/how-to-get-the-last-user-input-in-rasa/29549 "2020-05-31T04:52:28Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![MuraliChandran14](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/muralichandran14/32/9120_2.png) [@MuraliChandran14](https://forum.rasa.com/u/MuraliChandran14)\
**Post date:** [May 31, 2020, 10:08am UTC](https://forum.rasa.com/t/how-to-get-the-last-user-input-in-rasa/29549/6 "2020-05-31T10:08:25Z")

</div>

hi @shaiful019,

To my knowledge you have to use slots to fill in the button input, you cannot get text using `tracker.latest_message[‘text’]`

for more reference you can refer below:

> [@How to get values from payload in button after choosing an option?](http://forum.rasa.com/t/how-to-get-values-from-payload-in-button-after-choosing-an-option/11979):
>
> Hi there, I want to get access to the payload values from my custom buttons. The main idea is to choose one option from the buttons, and then collect the payload values in a variable, in order to pass these to the next action. The custom buttons are in a loop where from each items I collect the needed values for the “titles” and for the “payloads”. I want to achieve this in a dynamic way, since I have a lot of different variables with different length. Here is my code until now: def run(s…

Hope this helps

---

_[View the full topic](https://forum.rasa.com/t/how-to-get-the-last-user-input-in-rasa/29549)._
