ConnectHttp

From Opale Wiki
Jump to navigation Jump to search

This command connects to a given HTTP server on the specified GSM port.

FTP server connection details are provided in parameters

Prerequisites : Data link should be UP on the given port (See ConnectData)

If any of required parameters is not needed it can be specified as empty string ("").

Optional HTTP header name and value can be specified always in pair. Up to 12 HTTP headers can be specified.

Command returns once connection is established or optional timeout (entered in seconds) expired.

COMMAND

Command Line Arguments Returns
ConnectFtp PortIndex, HTTPIPAddress,UserName,Password,HTTPVersion, MaximalNumberofRedirect,ListofHTTPHeaderName, HTTPHeaderValue Error Code in case of error.

OUTPUT

Success or Error Message (See Data Commands Messages)

EXAMPLE

~# ConnectHttp 0 http://www.opalesystems.com "user" "pass" 0 5 "User-Agent" "WIP-HTTP-Client/0" "Accept-Encoding" "gzip" "Accept-Language" "en-US"
OK

~# ConnectHttp 1 
BAD PARAMETERS