Skip to main content

Posts

Showing posts from September, 2019

#120-How to Run a Curl Command on Postman

While testing APIs, curl and postman both are powerful weapons in a developer's arsenal. Released for the first time in 1997, curl has come a long way and has helped thousands of developers in testing APIs. It is used for transferring data to or from a server. It supports a wide range of protocols, DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET, and TFTP. According to the  curl man page , it "is designed to work without user interaction." It uses the syntax , curl [options] [URL...]. The command, curl  https://mgtheboss.blogspot.com/  will fetch the contents of the home page of this site on command prompt (or terminal, if you are on a linux machine). The URL syntax is protocol dependent. Multiple URLs can be specified as,  http://site.{one, two, three}.com . Sequences of alphanumeric series can be provided using [], for instance, ftp://ftp.example.com/file[1-100].txt ...