How to call a python function on cell click in streamlit ag-grid

I want to know that how we can add a button in streamlit ag-grid row that will call a python function with data of that specific row.

Anyone got it?