API properties
Properties are used by the gateway to control behavior of certain policies. Typically, you provide properties, but the policy can also provide properties settings.
In IBM® API Connect, you can create API properties that consist of Catalog-specific values to eliminate the need for source code modifications. You can then reference the properties elsewhere in your API definition.
Pre-supplied API properties
Pre-supplied API properties for various policies are shown in the tables.
Property | Required | Description | Data type |
---|---|---|---|
x-ibm-gateway-decode-request-params | No | If set to a value of true , any request parameters that are referenced by a
variable definition on an invoke target-url are URL-decoded. The default behavior is to not decode
any parameters, thereby sending them to the target URL without alteration. |
Boolean |
x-ibm-gateway-invoke-suppress-clientid | No | When set with a value of true , or not specified, the X-IBM-Client-Id HTTP
header (if specified on the API request) is suppressed from being sent to the invoke target URL.
When set with a value of false , the X-IBM-Client-Id HTTP header is no longer
suppressed from being sent to the invoke target URL. This property is supported only by the DataPower® Gateway (v5 compatible). If you are using
the DataPower API Gateway then to
achieve the same functionality add a Suppress the
X-Client-ID header as
follows: Suppress the userId query parameter as
follows:
|
Boolean |
x-ibm-gateway-optimize-invoke | No | If set to false, prevents the replacement of the last invoke in a policy with proxy. Any value other than false (case insensitive) will result in the last invoke in a policy possibly being replaced by proxy when the API is executed in the gateway. | Boolean |
x-ibm-gateway-queryparam-encode-plus-char | No | If set to a value of true , all +characters in the query parameter values of the target-url of the Invoke and Proxy policies are encoded to %2F. The default
value is |
Boolean |
x-ibm-gateway-api-enforce-response-limits | No | If set to a value of true , allows the JSON parser to be enforced on the
response rule. If the response body size is higher than the JSON parser limit set in the DataPower domain, a status code of
500 is returned.Note: The x-ibm-gateway-api-enforce-response-limits property is
supported by the DataPower Gateway (v5 compatible) but not by the DataPower API Gateway. However, if you
are using the DataPower API Gateway,
consider using a Parse policy in your API
assembly to enforce these limits.
For information on the different types of gateway, see API Connect gateway types. |
Boolean |
x-ibm-gateway-invoke-emulate-v4-soap-error | No | IBM API Management
Version 4.0
initiates a DataPower error when
a SOAP fault is returned from a web service. IBM
API Connect provides a mechanism
to catch SOAP errors and does not initiate a DataPower error. For compatibility
with APIs developed in IBM API Management
Version 4.0, set this property
to true only in the case where a gateway extension is expecting to handle a SOAP
error in a post error rule.The default value is Note: This property is
deprecated in favor of
x-ibm-gateway-invoke-emulate-v4-invoke-error.
|
Boolean |
x-ibm-gateway-invoke-keep-payload | No | If set to a value of true , the invoke policy sends a payload on an HTTP
DELETE method. This property is available for use with IBM
DataPower Gateway version
7.7.1.1 and later.The default value is |
Boolean |
x-ibm-gateway-invoke-emulate-v4-invoke-error | No | IBM API Management
Version 4.0
initiates a DataPower error when
a backend server error is returned, either a SOAP fault returned from a web service or a JSON or XML
(non-SOAP) error from a restful service. IBM
API Connect provides a mechanism
to catch SOAP errors and operation errors and does not initiate a DataPower error when they occur. If
no catch policy is configured, a generic error message is generated. For compatibility with APIs
developed in IBM API Management
Version 4.0,
set this property to true only in the case where a gateway extension is expecting
to handle a backend server error in a gateway extension post error rule or if the client of the API
is expecting the backend server error to be returned.The default value is
|
Boolean |
Property | Required | Description | Data type |
---|---|---|---|
x-ibm-gateway-map-array-first-element-value | No | In IBM API Management
Version 4.0, if
a mapping source value is from an array then only the first value is output. In API Connect, the default
behavior is to return an array of all array element values. To maintain compatibility with IBM API Management
Version 4.0, set this API
property to true to only return the first array element value. |
Boolean |
x-ibm-gateway-map-resolve-apic-variables | No | By default, any API Connect variable that is
found in the map configuration is resolved. For example,
$(request.headers.content-type) resolves to the request's content type header.
Because searching for variables in every map property can be CPU intensive, you can choose not to
resolve variables by setting this API property to false. If this property is
not configured or is set to any other value, the existing behavior to search for these variables
continues. Note that variable usage within a map value JavaScript snippet is not changed provided
that the variables that are referenced come from a configured map input. |
Boolean |
x-ibm-gateway-map-create-empty-array | No | This property controls how the map policy handles the output of an empty array; it can have
the following values:
|
String |
x-ibm-gateway-optimize-schema-definition | No | Set the value of this property to true to provide a performance improvement
to the map policy when a very complex schema definition is referenced by a policy output definition;
for example, some very complex schemas that are generated by importing a very complex WSDL
schema. The map policy builds a schema from an API definition when a referenced definition is
provided as the value of the schema. If the schema does not have references that generate a circular
reference, setting this property to The default value of this
property, is |
Boolean |
x-ibm-gateway-map-null-value | No | Set the value of this API property to true to allow a property from a map
policy's input data with a value of null to be mapped to the output document. By
default, a property from a map policy's input data with a value of null is not
mapped to the output document. |
Boolean |
x-ibm-gateway-map-resolve-xmlinput-datatypes | No | XML input elements with numeric or boolean data have no metadata to indicate whether this
data should be mapped as a string value or as the specific data type. If you set the value of this
property to false , XML input elements are always mapped as a string. If you set the
value to true , numeric or boolean XML input elements are mapped as the
corresponding data type from the input schema.The default value is
|
Boolean |
x-ibm-gateway-map-xml-empty-element | No | This property controls how the map policy handles XML input empty elements and impacts JSON
output when the input document is XML; it can have the following values:
|
Boolean |
x-ibm-gateway-schema-definition-reference-limit | No | Set the value of this property to an integer value that specifies the maximum allowed number
of iterations of a circular schema definition. The default value is 1, which means that circular schema definitions are not followed. The maximum possible value is 5. If you specify a value greater than 5, a value of 5 is assumed. If you specify a non-numeric value, a value of 1 is assumed. |
String |
x-ibm-gateway-map-emulate-v4-default-required-properties | No | Set this property to true to have default values generated in the output for required
properties that are either not mapped, or for which there is no input data present, in the following
specific cases:
By default, these required properties are not present in the output. If you set the
If the |
Boolean |
x-ibm-gateway-map-post-process-json-output | No | Set the value of this property to true to enable post processing of mapped
JSON output. The post processing of JSON output will use the output schema to ensure that property
values are of the same data type as that defined in the schema. It will also normalize output
property values that have a Badgerfish JSON syntax due to object mapping of an XML input. Set the
value to false for no post processing of mapped JSON output.The default value is
|
Boolean |
x-ibm-gateway-map-emulate-v4-empty-json-object | No | If a mapping fails because its input is not present and there is no default mapping
configured, the default behavior is to not to make any change to the output mapping. Set the value
of this property to true to create an empty object for the parent of the target
mapping, emulating the behavior of IBM API Management
Version 4.0.
|
Boolean |
Property | Required | Description | Data type |
---|---|---|---|
x-ibm-gateway-proxy-suppress-clientid | No | A setting of false activates the injection of the X-IBM-Client-Id HTTP
header (if it is specified on the API request), or the client_id query parameter in
the request URL, to the proxy target-url. If not specified, or set with a value of
true, suppresses the sending of this parameter to the proxy
target-url.This property is supported only by the DataPower Gateway (v5 compatible). If you are using
the DataPower API Gateway then to
achieve the same functionality add a Suppress the
X-Client-ID header as
follows: Suppress the userId query parameter as
follows:
|
Boolean |
x-ibm-gateway-optimize-invoke | No | If set to false, prevents the replacement of the last invoke in a policy with proxy. Any value other than false (case insensitive) will result in the last invoke in a policy possibly being replaced by proxy when the API is executed in the gateway. | Boolean |
x-ibm-gateway-queryparam-encode-plus-char | No | If set to a value of true , all +characters in the query parameter values of the target-url of Invoke and Proxy policies are encoded to %2F. The default value
is |
Boolean |
x-ibm-gateway-api-enforce-response-limits | No | If set to a value of true , allows the JSON parser to be enforced on the
response rule. If the response body size is higher than the JSON parser limit set in the DataPower domain, a status code of
500 is returned. |
Boolean |
Property | Required | Description | Data type |
---|---|---|---|
x-ibm-gateway-emulate-v4-plan-rate-limit | No | By default in IBM API Connect Version
10, if you configure
a rate limit only for a Plan and not for the API operations within the Plan then a single rate limit
threshold is set for the API as a whole, regardless of which operation in the API is requested. This
behavior differs from IBM API Management
Version 4.0 where the rate
limit is set individually for each operation in the API. To change the Version 10
behavior to emulate the Version 4.0 behavior, set this API property to a value of
true . |
Boolean |
Property | Required | Description | Data type |
---|---|---|---|
x-ibm-gateway-sourcecode-resolve-apic-variables | No | If set to true , API Connect variable
references are resolved. Set to false if you want the policy to ignore API Connect variable
references.The default value is This property applies to the
following policies:
Note: This property setting is overridden by the
x-ibm-gateway-map-resolve-apic-variables API property setting for the Map
policy.
|
Boolean |
x-ibm-gateway-api-json-parse-error-handling | No | If an API request or response payload includes valid JSON content that contains characters
that cannot be represented in the JSONX XML internal syntax that is used by the DataPower Gateway, set this property to
escape-unicode to allow the payload to be accepted without parsing errors. If this
property is not configured or is set to any other value, the payload is rejected as invalid
JSON.This property applies to the API request payload, and to the API response payload when
|
String |
x-ibm-gateway-framework-preserve-escaped-reverse-solidus | No | By default, the string \\ in a policy property is converted to a single
\ character. Set this property to true to preserve the string
\\ . |
Boolean |
x-ibm-gateway-inspect-request-headers | No | Causes an inspection of the HTTP headers in the API request to check for characters in the
header values that are illegal XML characters; it can have the following values:
The default value is |
Boolean |