a service convert between tokens and credentials