refactor: Extract transaction IDs/offsets conversion to a standalone method.
Support querying the last transaction ID in the history.