Move CURL function from apps/ to funcs/