reworked tools for getting tokens and keys