Troubleshooting
Problem
Built-in service pub.client:http adds a HTTP header "Content-Type: application/x-www-form-urlencoded" on a GET method - even though the body payload is empty.
Consider 2 examples:
1. When using pub.client:http and the URL contains all the parameters (e.g. http://localhost:5555/invoke/pub.flow:debugLog?message=example1 ) then prior to 9.7 Core fix 9 this always adds the Content-Type header. With any Core Fix higher than 9 the Content-Type header is not added.
2. When using pub.client:http and the parameters are added to variable data/table (e.g. url: http://localhost:5597/invoke/pub.flow:debugLog data.table=message/example2) then prior to 9.7 Core fix 9 this always adds the Content-Type header, "Content-Type: application/x-www-form-urlencoded" . With any Core Fix higher than 9 the Content-Type header is still added.
i.e .
[ISC.0038.0002D] --> GET /invoke/pub.flow:debugLog?message=example1 HTTP/1.1
[ISC.0038.0002D] --> User-Agent: Mozilla/4.0 [en] (WinNT; I)
[ISC.0038.0002D] --> Accept: image/gif, */*
[ISC.0038.0002D] --> Host: localhost:5555
[ISC.0038.0002D] --> Authorization:Administrator: ****
[ISC.0038.0002D] --> GET /invoke/pub.flow:debugLog?message=example2 HTTP/1.1
[ISC.0038.0002D] --> User-Agent: Mozilla/4.0 [en] (WinNT; I)
[ISC.0038.0002D] --> Accept: image/gif, */*
[ISC.0038.0002D] --> Host: localhost:5555
[ISC.0038.0002D] --> Authorization:Administrator: ****
[ISC.0038.0002D] --> Content-Type: application/x-www-form-urlencoded <- not needed
Document Location
Worldwide
Log InLog in to view more of this document
Was this topic helpful?
Document Information
Modified date:
20 March 2025
UID
ibm17225047