CommandFusion Wiki

Documentation Resources

User Tools

Site Tools


software:gui-designer:system-manager:http-request-commands

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

software:gui-designer:system-manager:http-request-commands [2012/08/21 02:37]
aaron Page moved from software:gui-designer:http-request-commands to software:gui-designer:system-manager:http-request-commands
software:gui-designer:system-manager:http-request-commands [2015/05/17 22:58] (current)
jarrod [HTTP/HTTPS Systems]
Line 1: Line 1:
-====== HTTP Request Commands ​======+====== HTTP Requests ​======
  
 ===== Overview ===== ===== Overview =====
  
-Some devices only have a HTTP control protocol. These devices can be controlled from a web browser by entering specific URLs into the browser.\\ +Some devices only have a HTTP control protocol. These devices can be controlled from a web browser by entering specific URLs into the browser. 
-To control these devices via iViewer, the command value to send needs to be crafted to follow the HTTP Request standard formatting.+ 
 +To control these devices via iViewer, the communications can be defined in a variety of ways, depending on your requirements:​ 
 +  - [[#​httphttps-systems|HTTP/​HTTPS systems]] 
 +    - Easiest method.  
 +    - GET requests only. 
 +  - [[http://​www.commandfusion.com/​docs/​scripting/​net.html#​cF.request|CF.request JavaScript function]] 
 +    - Most powerful, but complicated method. 
 +  - [[#​manually-crafted-commands|Manually crafted commands via TCP systems]] 
 +    - Moderate complexity and flexibility. 
 +    - Not commonly used method. 
 +===== HTTP/HTTPS Systems ===== 
 +When you create a system in the guiDesigner System Manager, amongst the available protocol options are HTTP and HTTPS. These two options allow you to easily create HTTP GET Requests, either unsecured (HTTP), or secured (HTTPS). 
 + 
 +To use HTTP or HTTPS systems, you enter the root hostname or IP Address of the HTTP end point as the system hostname property. Then define the port to use, most commonly port 80 for HTTP or port 443 for HTTPS.\\ 
 + 
 +Then for the command values, all you have to enter is the request suffix. This should be the URL content after the hostname. 
 + 
 +So for example, if you control a device via a web browser with a URL such as:\\ 
 +''​http://​myhouse.dyndns.org:​8080/​transport?​action=playpause''​\\ 
 + 
 +Then the System Hostname would be ''​myhouse.dyndns.org''​ and port number ''​8080''​.\\ 
 +The command value would be ''/​transport?​action=playpause''​. 
 + 
 +===== Manually Crafted Commands ===== 
 + 
 +Alternatively,​ a raw TCP system can be used. In this case, the command value to send needs to be crafted to follow the HTTP Request standard formatting.
  
 ==== Basic Format ==== ==== Basic Format ====
Line 36: Line 61:
   * http://​en.wikipedia.org/​wiki/​HTTP   * http://​en.wikipedia.org/​wiki/​HTTP
   * http://​en.wikipedia.org/​wiki/​HTTP_headers   * http://​en.wikipedia.org/​wiki/​HTTP_headers
 +
 +The Requestb.in website is great for debugging HTTP requests, more info on their website:\\
 +http://​requestb.in
software/gui-designer/system-manager/http-request-commands.1345516666.txt.gz · Last modified: 2012/08/21 02:37 by aaron