refactor ... basic auth otken creation