I have the idea to use a regex pattern as a template and wonder if there is a convenient way to do so in Python (3 or newer).
import re
pattern = re.compile("/something/(?P<id>.*)")
pattern.populate(id=1) # that is what I'm looking for
should result in
/something/1