byron
4 years agoNew Contributor
Where to put API key in RESTful request?
I am trying to use the easypost.com API (for reference, here: https://www.easypost.com/docs/api). One of the required request elements is an API key. I have the API key and it is working when I make a cURL request (see below), but I can't figure out how to enter it when making the corresponding request in SoapUI.
Does it go in a header and, if so, how would I know what the Name should be?
Or is this something I set in the Authorization tab? Or somewhere else?
Basically this question amounts to, "How do I convert the cURL request below into a request I can make from SoapUI?"
curl -X POST https://api.easypost.com/v2/addresses \ -u <YOUR_TEST/PRODUCTION_API_KEY>: \ -d "verify[]=delivery" \ -d "address[street1]=417 Montgomery Street" \ -d "address[street2]=5" \ -d "address[city]=SF" \ -d "address[state]=CA" \ -d "address[zip]=94104" \ -d "address[country]=US" \ -d "address[company]=EasyPost" \ -d "address[phone]=415-123-4567"