Readonly actions work just like action return values, but in my opinion they are even cooler.
You don't need any session or private key to sign them.
The transaction does not actually get submitted on-chain, consuming 0 CPU from your wallet. All it does is simulate the transaction, and return the data.
This will return a list of pending rewards for a user, so they can be displayed on a front end etc. All without any special front end math, and without submitting a transaction on chain!