IBM Support

webMethods Knowlegebase : Custom HTTP Header policy: unable to set Host http header.

Troubleshooting


Problem

Trying to create Rest API on API Gateway that will route requests to the native service provider which expects incoming requests to have the HTTP header "Host" with a particular value.



Tried to set this outgoing HTTP header by setting the HTTP header "Host":"myvalue" in the client request headers to API Gateway, but API Gateway is not forwarding this header to the endpoint.

Tried to set Routing / Custom HTTP header policy with parameters: HTTP Header Key = Host, Header Value = "myvalue", but it neither works.

Similar behavior is present in policy Request Processing / Request Transformation with Transformation Configuration / Header Transformation.

Even tried building an IS service to be invoked in the request transformation policy to modify the Host header using pub.apigateway.ctxvar:setContextVariable, but this also has no effect on the outgoing call.

Document Location

Worldwide


[{"Line of Business":{"code":"LOB77","label":"Automation Platform"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SSL6KH","label":"IBM webMethods API Management SaaS"},"ARM Category":[{"code":"a8mKe00000000AQIAY","label":"webMethods API Gateway (YAI)"}],"ARM Case Number":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"10.x"}]

Log InLog in to view more of this document

This document has the abstract of a technical article that is available to authorized users once you have logged on. Please use Log in button above to access the full document. After log in, if you do not have the right authorization for this document, there will be instructions on what to do next.

Document Information

More support for:
IBM webMethods API Management SaaS

Component:
webMethods API Gateway (YAI)

Software version:
10.x

Document number:
7207209

Modified date:
20 March 2025

UID

ibm17207209

Manage My Notification Subscriptions