move logic into core again
shorten uri token a bit