def insert_values(path, instance):
    """
    Insert values from object into the path string
    Example: "/{test}/" (self.test = "pyon") -> "/pyon/"
    :param path: Path string where the values should be inserted
    :param instance: Instance (mostly 'self') which includes the values
    :return:
    """

    return path.format(**vars(instance))