HTTP 1.1 services

HTTP 1.1 handlers are declared in GXML with tag <end/>.

Syntax

End tags are placed at the root of your <endpoints/> tag.

GXML attributes :

GXML content :

Defines Go code to be ran on handler execution.

Comments

To comment an HTTP handler use XML style comments. The comments must be in your tag’s GXML content. For example :

 <end>
 <!-- Comment -->
 </end>
Scope of code

You may use other Go packages without explicitly importing them. This is due to the fact that gos uses a command to add missing imports to generated source code.

These variables are available to your code :

Variables
Debug variables

These variables are only available on debug :

Functions

These functions are available to your code :

Sample tag for root of web server :

<endpoints>
	<end path="/" id="foo" type="GET" >
		<!-- Handler comment -->
  		response = "Hi"
  	</end>
 </endpoints>

Exported to package:
Exports to files :
Writes tests to :