move to curl, and add cache