0

The command below successfully sends GET requests to a secure server with the Wget Command which saves the output in the “response_from_API_server.json” file in the same directory.

Is there any way to show the command output on the screen instead of saving it into a file?

Sample code:

wget -S --ca-cert=/etc/ssl/AAA.crt 
--certificate=/etc/ssl/[email protected] 
--private-key=/etc/ssl/[email protected] 
--header="Accept-Encoding: gzip, deflate"
--header='Accept-Charset: UTF-8'
--header='Content-Type: application/json' -O response_from_API_server.json
--post-data '{"email": "[email protected]", "accountID": "myaccount1234"}' https: //examplewebsite.com//ourUsers/findAccount

1 Answer 1

3

Instead of -O response_from_API_server.json try -O-. Instead of saving the response to a file it prints to stdout.

Sign up to request clarification or add additional context in comments.

2 Comments

Awesome, I think that worked pretty well! Saving to: ‘STDOUT’ [<=> ] 0 --.-KB/s {"ourUsers":{""accountStatus":"ACTIVE","email":"[email protected]"} [ <=> ] 252 --.-KB/s in 0s Thank you so much, @dwosk !
Glad it worked - would you mind marking this as the answer then? Thanks so much

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.