Chapter 11 Advanced Policies: Sending HTTP Service Callouts to Applications 191
2. In the details pane, click Add.
3. In the Create HTTP Callout dialog box, in the Name field, enter a name
for the callout.
4. In the Server to receive callout request section, select the name of a
virtual server to which you want to send the callout, or specify an IP
address and port for the server. If this server uses IPv6 format, select the
IPv6 check box to enable the IP Address field to accept the appropriate
address format.
5. In the Request to send to the server section, do one of the following:
To configure individual parameters for the request, click
Attribute-based and specify the attribute-based parameters
described in the table, “Elements in an HTTP Callout Policy,” on
page 188. For an example of the content of an HTTP request, see
“Note on the Format of an HTTP Request,” on page 187.
To configure the entire HTTP request, click Expression-based and
enter the expression in the text box, as described in “Configuring
Advanced Expressions in a Policy,” on page 57, with one exception.
Unlike other expression entry fields, the request must start with the
string GET or POST. For an example of an expression that formats a
legal request, see “To configure a callout policy using the NetScaler
command line,” on page 191.
6. In the Server Response section, click the Return Type drop-down menu
and select BOOL, NUM, or TEXT , depending on the format of the data
that you expect the server to return. In the Expression to extract data
from the response field, enter an expression to extract the data that you
want from the HTTP response to this callout.
For more information on configuring an advanced expression, see
“Configuring Advanced Expressions in a Policy,” on page 57. Note that this
expression must start with the string http.res. For an example of an
HTTP response, see “Note on the Format of an HTTP Response,” on page
187. For an example of an expression that parses the response, see “To
configure a callout policy using the NetScaler command line,” on page 191.
7. Click Create.
To configure a callout policy using the NetScaler command line
1. At a NetScaler command prompt, type:
add policy httpCallout calloutName
2. Enter the following command to configure the policy.