I see this piece of code is used many times. Why not extract it into private method?

    def generate_url(path)
       Targetprocess.configuration.api_url+path
    end