todo: finish correct implementation of hcurl-style things