Making Hosted Chef API Requests with Curl?

No matter what I do I always get an error:

{“error”:“Failed to authenticate as MY-USERNAME. Ensure that your
node_name and client key are correct.”}

(should the error be “Ensure that your api-client-name and
api-client-key are correct”? I’m referring to
X-Ops-UserId: The name of the API client whose private key will be
used to create the authorization header)

I’m following this documentation:

I’m using the same credentials as in my knife config. (knife works fine)

(from the knife config)
client_key “#{keys_dir}/#{ENV[‘OPSCODE_USER_NAME’]}.pem”

Anyone have a working exemple of how to make an api request with curl?

Thank you!