<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: SAP HCI - HTTP Adapter with Header Parameter in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375023#M30482</link>
    <description>&lt;P&gt;Hi Sriprasad Shivaram Bhat/ Bruno,&lt;/P&gt;
  &lt;P&gt;I tried with content modifier for passing http header , type header and constant, as Sriprasad said, while selecting data type constant it gives me error, but while giving its type header it gives me Your browser does not support JavaScript or it is turned off, in header payload it will pass http headers names but not value it shows it's value null. so i write Groovy script for it and it works perfectly also in header payload it shos me value that i passed in groovy. &lt;/P&gt;
  &lt;P&gt;please find groovy script below , &lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;import com.sap.gateway.ip.core.customdev.util.Message;
import java.util.HashMap;
def Message processData(Message message) {
  // Get the OAuth token value from the properties
  def map = message.getProperties();
  // Set the OAuth authorization credentials
  message.setHeader("Authorization", "bearer ******);
message.setHeader("Content-Type", "application/json");
message.setHeader("tns_id", "***");
message.setHeader("src_sys_id", "***");
message.setHeader("src_ip_address", "***");
  return message;
}
&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/67812-header.png" /&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 11 Sep 2017 14:47:05 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2017-09-11T14:47:05Z</dc:date>
    <item>
      <title>SAP HCI - HTTP Adapter with Header Parameter</title>
      <link>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaq-p/375019</link>
      <description>&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;We're trying to consume a Rest API via HTTP Receiver Adapter but, the services has the  below two parameters: &lt;/P&gt;&lt;P&gt;- ACCEPT = application/xml &lt;/P&gt;&lt;P&gt;- X-CUSTOM-PARAM = Static GUID provided by the customer&lt;/P&gt;&lt;P&gt;How can we set these parameters in the HTTP Receiver  HCI Adapter?&lt;/P&gt;&lt;P&gt;Thank You&lt;/P&gt;</description>
      <pubDate>Fri, 24 Feb 2017 13:14:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaq-p/375019</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-24T13:14:47Z</dc:date>
    </item>
    <item>
      <title>Re: SAP HCI - HTTP Adapter with Header Parameter</title>
      <link>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375020#M30479</link>
      <description>&lt;P&gt;Hi Bruno&lt;/P&gt;&lt;P&gt;The Content Modifier step, found in the Message Transformers category of the palette, lets you set headers directly. If the receiver adapter supports headers (which the HTTP adapter does, of course), the headers will be delivered to the recipent along with your request.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Morten&lt;/P&gt;</description>
      <pubDate>Fri, 24 Feb 2017 13:31:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375020#M30479</guid>
      <dc:creator>MortenWittrock</dc:creator>
      <dc:date>2017-02-24T13:31:58Z</dc:date>
    </item>
    <item>
      <title>Re: SAP HCI - HTTP Adapter with Header Parameter</title>
      <link>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375021#M30480</link>
      <description>&lt;P&gt;Hello Bruno.&lt;/P&gt;&lt;P&gt;Have Content Modifier before request reply[ Where you are calling HTTP adapter ] and set these two parameter as header.&lt;/P&gt;&lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/22289-sap-sdn-http-param.png" /&gt;&lt;/P&gt;&lt;P&gt;Below will give more details&lt;/P&gt;&lt;P&gt;&lt;A target="_blank" href="http://SAP HCI Help"&gt;&lt;/A&gt;&lt;A href="https://uacp.hana.ondemand.com/http.svc/rc/PRODUCTION/93810d568bee49c6b3d7b5065a30b0ff/1/en-US/frameset.html?5e77b59f09e04088b0a01abb1fe4d191.html" target="test_blank"&gt;https://uacp.hana.ondemand.com/http.svc/rc/PRODUCTION/93810d568bee49c6b3d7b5065a30b0ff/1/en-US/frameset.html?5e77b59f09e04088b0a01abb1fe4d191.html&lt;/A&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Regards,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Sriprasad Shivaram Bhat&lt;BR /&gt;&lt;A target="_blank" href="http://SAP HCI Help"&gt;&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Feb 2017 13:45:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375021#M30480</guid>
      <dc:creator>Sriprasadsbhat</dc:creator>
      <dc:date>2017-02-24T13:45:03Z</dc:date>
    </item>
    <item>
      <title>Re: SAP HCI - HTTP Adapter with Header Parameter</title>
      <link>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375022#M30481</link>
      <description>&lt;P&gt;Many thanks Sriprasad Shivaram Bhat, it helped me a lot, as I Already marked the Morten's answer as a correctly, I unfortunately cannot mark both as a correct. But you helped a Lot!&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 12:51:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375022#M30481</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-03-07T12:51:08Z</dc:date>
    </item>
    <item>
      <title>Re: SAP HCI - HTTP Adapter with Header Parameter</title>
      <link>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375023#M30482</link>
      <description>&lt;P&gt;Hi Sriprasad Shivaram Bhat/ Bruno,&lt;/P&gt;
  &lt;P&gt;I tried with content modifier for passing http header , type header and constant, as Sriprasad said, while selecting data type constant it gives me error, but while giving its type header it gives me Your browser does not support JavaScript or it is turned off, in header payload it will pass http headers names but not value it shows it's value null. so i write Groovy script for it and it works perfectly also in header payload it shos me value that i passed in groovy. &lt;/P&gt;
  &lt;P&gt;please find groovy script below , &lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;import com.sap.gateway.ip.core.customdev.util.Message;
import java.util.HashMap;
def Message processData(Message message) {
  // Get the OAuth token value from the properties
  def map = message.getProperties();
  // Set the OAuth authorization credentials
  message.setHeader("Authorization", "bearer ******);
message.setHeader("Content-Type", "application/json");
message.setHeader("tns_id", "***");
message.setHeader("src_sys_id", "***");
message.setHeader("src_ip_address", "***");
  return message;
}
&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/67812-header.png" /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 11 Sep 2017 14:47:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/sap-hci-http-adapter-with-header-parameter/qaa-p/375023#M30482</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-09-11T14:47:05Z</dc:date>
    </item>
  </channel>
</rss>

