Method GetHeaderValue

Returns response header value

Usage

Function GetHeaderValue(
  String HeaderName,
  Boolean Report [Optional]
)

Method

ZAP API Method step

GetHeaderValue

Server

True

headerValue

String HeaderName

Boolean Report [Optional]

Output Parameter

Parameters

HeaderName

Type: String

Header Name

Report (optional)

Type: Boolean

Default Value: False

Generate report for this step

Returns

Header Value

Example

VBScript

Server("API Server").Method("Method").Execute
' Execute method should be called before get header value
headerValue = Server("API Server").Method("Method").GetHeaderValue("Server", True)

JavaScript

Server("API Server").Method("Method").Execute();
// Execute method should be called before get header value
var headerValue = Server("API Server").Method("Method").GetHeaderValue("Server", true);

Method

ZAP API Method step

Execute

Script-Less next step

Comment

Execute method should be called before get header value

Script-Less next step

Method

ZAP API Method step

GetHeaderValue

Server

True

headerValue