InvokeHTTP lets you send any custom HTTP header, either hard-coded or built from attributes using Expression Language. If the header isn’t showing up in your outbound request, it’s almost always because of one of these configuration issues.
Static header
Open the processor
Add a new property
Set the property name to the exact header name
Set the value to the literal value you want sent
Example:
Property Name: X-Client
Value: clockspring-ui
This sends X-Client: clockspring-ui.
Dynamic header with Expression Language
Same process, but use EL to build the value from FlowFile attributes.
Example:
Property Name: X-Customer-ID
Value: ${customerId}
If customerId exists, the header is populated.
If not, the header ends up empty.
More examples:
X-Env: ${env}X-Region: ${region}X-Trace: ${uuid()}X-Date: ${now():format("yyyy-MM-dd")}
Things to know
Header names must match exactly. Case differences can matter depending on the target API.
Headers are not automatically created from attributes. Every header must be explicitly added.
Missing or invalid EL resolves to an empty header value.
The built-in Authorization configuration is separate and should be used instead of manually creating Authorization headers.
Example config
You want to send three headers:
| Property Name | Value |
|---|---|
| X-Client | clockspring-ui |
| X-Customer | ${customerId} |
| X-Trace | ${uuid()} |
InvokeHTTP will include all three in the outbound request.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article