Perhaps all you need is to include the curl package in your package's native-inputs field.
Also as a side note, I'm not entirely sure if using open-input-pipe would be considered good practice for packages as far as reproducibility is concerned. Perhaps someone else can comment on that. But another option you might want to consider is using the built in web modules. For example: #:use-module (web client) #:use-module (web uri) ... (let* ((out (call-with-values (lambda () (http-get (string->uri %api-url))) (lambda (response body) body))) ... I'm not sure if that's the most elegant way to do it, but it seems to work. There's also a curl module for guile, although I'm not sure if guix will let you import it or not.