Using curl for Linode API commands
curl -u u:my-linode-key '
However this command doesn't work as I would expect (the key is in the linode_key.txt file):
curl -u u:@linodekey.txt '
I've read the curl docs but I don't see what I'm doing wrong. Has anyone else managed to do this correctly? Thanks!
3 Replies
May want to search that for "password".
- Les
curl -u u:$(cat linode_key.txt) 'https://api.linode.com/?api_action=linode.list&LinodeID=12345' | jsonpp
Or you may find using the -n option and creating a .netrc file to be more convenient.