Consume SAP Netweaver Gateway Web service in Windows Mobile 6.5

Hi All,
I am using Netweaver Gateway Webservice in Windows Mobile 6.5 platform. I know if need to make POST request, first i need to make GET for fetching CSRF token and then passing the CSRF token again with POST request to do the create operation. So i have used the below syntax. But it is always saying as 403 forbidden status while making POST request. I had successfully fetched CSRF token in my get request. Is there any help available for the below syntax?
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(new Uri("http://hostname:8040/sap/opu/odata/APLX/ST_GRRF_TS_01/Headers"));
            request.Credentials = new NetworkCredential("ddsdsdsd", "sdsdsdsdsds");
            request.Method = "GET";
            request.ContentType = "application/atom+xml";
            request.Accept = "application/xml,application/atom+xml";
            request.AllowWriteStreamBuffering = true;
            request.Headers.Add("X-CSRF-Token", "Fetch");
            request.KeepAlive = true;
            WebResponse response = request.GetResponse();
            string strcsrf = response.Headers["X-CSRF-Token"];
            string strcookie = response.Headers["Set-Cookie"];
            string pXml = @"<?xml version=""1.0"" encoding=""UTF-8"" ?> <atom:entry xmlns:atom=""http://www.w3.org/2005/Atom"" xmlns:d=""http://schemas.microsoft.com/ado/2007/08/dataservices"" xmlns:m=""http://schemas.microsoft.com/ado/2007/08/dataservices/metadata""> <atom:content type=""application/xml"">" +
                 "<m:properties>" +
                   "<d:I_MBLNR>004</d:I_MBLNR>" +
                   "<d:I_MJAHR>2011</d:I_MJAHR>" +
                   "<d:I_SELECT>1</d:I_SELECT>" +
                   "<d:I_REFDOC>4500000001</d:I_REFDOC>" +
                   "<d:I_MATNR />" +
                   "<d:I_SLOC>0001</d:I_SLOC>" +
                   "<d:I_DELNOTE />" +
                   "<d:I_GR_GI />" +
                   "<d:I_PLANT>R303</d:I_PLANT>" +
                   "<d:I_VENDOR>R3000</d:I_VENDOR>" +
                   "<d:I_DATE>2013-09-08T00:00:00</d:I_DATE>" +
                   "</m:properties>" +
                   "</atom:content>" +
                 @"<atom:link rel=""http://schemas.microsoft.com/ado/2007/08/dataservices/related/Items"" type=""application/atom+xml;type=feed"" title=""APLX/ST_GRRF_TS_01.Header_Items"">" +
                 "<m:inline>" +
                 "<atom:feed>" +
                 "<atom:entry>" +
                 @"<atom:content type=""application/xml"">" +
                 "<m:properties>" +
                   "<d:I_MBLNR>003</d:I_MBLNR>" +
                   "<d:I_MJAHR>0000</d:I_MJAHR>" +
                   "<d:ITEMNO>000001</d:ITEMNO>" +
                   "<d:MATNR>R100000</d:MATNR>" +
                   "<d:QUANTITY>1</d:QUANTITY>" +
                   "</m:properties>" +
                   "</atom:content>" +
                   "</atom:entry>" +
                   "</atom:feed>" +
                   "</m:inline>" +
                   "</atom:link>" +
                   "</atom:entry>";
            request =(HttpWebRequest)HttpWebRequest.Create(new Uri("http://hostname:8040/sap/opu/odata/APLX/ST_GRRF_TS_01/Headers"));
            request.Credentials = new NetworkCredential("ddsdsdsd", "sdsdsdsdsds");
            request.Method = "POST";
            request.ContentType = "application/atom+xml";
            request.Accept = "application/xml,application/atom+xml";
            request.AllowWriteStreamBuffering = true;
            request.Headers.Add("x-csrf-token", strcsrf);
            request.Headers.Add("set-cookie", strcookie);
            request.KeepAlive = true;
            request.AllowAutoRedirect = false;
            request.ClientCertificates = cn;
            //request.Headers.Add("content-type", @"application/atom+xml");
            //request.Headers.Add("content-length", pXml.Length+"");
            byte[] bytes = Encoding.UTF8.GetBytes(pXml);
            request.ContentLength = bytes.Length;
            using (Stream putStream = request.GetRequestStream())            {
                putStream.Write(bytes, 0, bytes.Length);
                putStream.Close();
            response = request.GetResponse();
Here the response in the last line always shows 403 forbidden status.

Hi Mohanasundaram,
This is the wrong forum for Gateway questions - sorry. Please try the following forum:
http://scn.sap.com/community/netweaver-gateway
Best regards,
Jon

Similar Messages

  • How to consume sap xi pi web services or sap RFC with oracle 11g forms.

    Dear All
    how to consume sap xi pi web services or sap RFC with oracle 11g forms.
    or
    how to config 11g forms with sap xi....
    or how to call sap xi web services in 11g forms....
    or can send sample code....
    Regards
    smfatmi
    Edited by: smfatmi on Oct 17, 2011 2:16 AM
    Edited by: smfatmi on Oct 17, 2011 2:17 AM

    Dear All
    how to consume sap xi pi web services or sap RFC with oracle 11g forms.
    or
    how to config 11g forms with sap xi....
    or how to call sap xi web services in 11g forms....
    or can send sample code....
    Regards
    smfatmi
    Edited by: smfatmi on Oct 17, 2011 2:16 AM
    Edited by: smfatmi on Oct 17, 2011 2:17 AM

  • Failed to test a SAP PI Published web service on SOAPUI

    Hi All,
    I have developed the RFC to Web service through SAP PI 7.1 . Web service published on 'Services Registry' and test on it. It accepts the my request and respond from SAP R3. All the message was successfully recorded on SXMB_MONI.
    In Integration Directory, i could view the web service URL . I navigated to the Sender Agreement -> Display WSDL and i could see the "WSDL URL' and wsdl content on large text box.
    I access the WSDL URL from SOAPUI tool and set the preference -> proxy setting also. it populated the request message successfully but respond gives the '400 Bad HTTP request' and Detail: -> illegal path specified  . No SOAPUI request recorded on SXMB_moni.
    i try the same following way also . i saved the WSDL on xml file and access it through the SOAPUI -> import project. that also failed on SOAPUI.
    Can you please help to solve the issue ?
    Thanks,
    Rehan

    Hi Rehan
    Please check the below blog, it might help
    Publish services from PI 7.1 to the Service Registry
    Consuming SAP PI published Web Service
    regards,
    Harish

  • SAP Netweaver Gateway 2.0 vs. Web Services

    Hello,
    I want to ask about SAP Netweaver Gateway 2.0. I understand its usage but why do we need it when we can create (globally compatible) web services and use SOa Manager? I want to implement Gateway add-on but I need to know differences between web services and Gateway before making last decision.
    Thank you.

    Hi,
    I have just answered your question in the the Gateway Forum...
    Martin

  • Problem when consuming web service on WIndows authentication applcation

    Hi,
    I am having a tough time in consuming web services on a
    Windows authentication IIS server.
    In one of my application I have created web services and
    consuming those web services from my another application.
    If I turned off the Windows authentication everything works
    fine, but If I turned on the Windows authentication web services
    stop working.
    Has anyone encountered such error while working with web
    services on Windows authentication server.
    Attach Code
    Could not perform web service invocation "funGetCustomer".
    Here is the fault returned when invoking the web service
    operation:
    AxisFault
    faultCode: {
    http://xml.apache.org/axis/}HTTP
    faultSubcode:
    faultString: (401)Unauthorized
    faultActor:
    faultNode:
    faultDetail:
    {}:return code: 401
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "
    http://www.w3.org/TR/html4/strict.dtd">
    <HTML><HEAD><TITLE>You are not authorized
    to view this page</TITLE>
    <META HTTP-EQUIV="Content-Type" Content="text/html;
    charset=Windows-1252">
    <STYLE type="text/css">
    BODY { font: 8pt/12pt verdana }
    H1 { font: 13pt/15pt verdana }
    H2 { font: 8pt/12pt verdana }
    A:link { color: red }
    A:visited { color: maroon }
    </STYLE>
    </HEAD><BODY><TABLE width=500 border=0
    cellspacing=10><TR><TD>
    <h1>You are not authorized to view this page</h1>
    You do not have permission to view this directory or page
    using the credentials that you supplied because your Web browser is
    sending a WWW-Authenticate header fi...

    You could try switching the HTTP transport provided in the
    Apache Axis embedded in ColdFusion to "CommonsHTTPSender".
    See this blog post:
    http://tjordahl.blogspot.com/2007/03/apache-axis-and-commons-httpclient.html

  • SAP NetWeaver Gateway 2.0 Pre-Packaged Trial Version for Windows available

    The Windows version of SAP NetWeaver Gateway 2.0 Pre-Packaged Trial Version is available for release. For more information and to find the download links [here|http://www.sdn.sap.com/irj/scn/downloads?rid=/library/uuid/f091b083-c2d0-2e10-dfaf-d39b95b312d1].

    Hi Johny,
    In my view the very first thing to observe is if there is any
    licence implication by doing so as I believe it was designed to run on top of
    HyperV. Technically it is possible to do it. But the licence check should come
    first. I don’t know the answer for the licence implication.
    Best Regards,
    Felipe

  • Difference between SAP NetWeaver Gateway 2.0 and SAP NetWeaver Gateway productivity accelerator for Microsoft

    Hi Experts ,
    Can anyone tell me the difference between SAP NetWeaver Gateway 2.0 and SAP NetWeaver Gateway productivity accelerator for Microsoft ?
    Best Regards,
    SK

    SAP  Netweaver Gateway 2.0 is a product for Exposing ERP data as OData for external consumption which is independent of any Microsoft product. Using this you can model OData services and Expose them for light weight consumption. You can use this in use cases where  you just want to consume the OData in some client or so, and you do not want any kind of accelerators to help you in development or in your integration.
    GWPAM is an interoperability framework from SAP that leverages SAP NetWeaver Gateway and Microsoft technologies enabling customers and partners to easily and quickly compose solutions that consume and extend SAP throughout Microsoft technologies for on premise and on demand deployment. With GWPAM you get components like
    GWPAM Visual Studio Add-On,GWPAM Template,GWPAM Project,GWPAM Outlook Add-In which are very much Microsoft specific.

  • Flash Builder 4.6 and SAP Netweaver Gateway plugin works just fine

    Hi, i have just installed the new Flash Builder 4.6 and add the SAP NetWeaver Gateway plugin on it.
    I you follow the documentation available (http://download.macromedia.com/pub/labs/flashbuilder_sap/flashbuilder_sap_gettingstarted.p df) and then select the "DEMO_BANK" service instead of the "DEMO_FLIGHT" as writtent in the documentation and then bound the "selectZ_demo_bankCollection" to your datagrid, the demo works just fine.
    My platform specification is:
    - Windows 7 Integral running on VMware Fusion installed on my MacBook Air (just installed yesterday and full updated from Windows Update)
    - Flash Builder 4.6 (fresh download from this morning)
    - Internet Explorer 9 (last update at this time)
    - Flash Player 11.1.102.55 (last update at this time)
    - flashbuilder_sap_p1_plugin_110111 (the SAP Netweaver Gateway Plugin) available at http://labs.adobe.com/technologies/flashbuilder_sap/
    FXL

    note sure if I'm much help other than to CONFIRM it is working for me by using the sdk WITHOUT the compiler. Check out adobe's little note: "Note : Flex users will need to download the original AIR SDK without the new compiler."
    I am using FB 4.7 with AIR 3.6 and seems to compile correctly for iOS.
    Maybe try reinstalling flash builder?
    I honestly don't know if the JRE has anything to do with it... I'm using 1.7 ....to see what JRE you're using, open the Java Control Panel (I right click my java orange icon and hit properties), select the Java tab, then hit "View..."

  • SAP Business Workflow and SAP Netweaver Gateway - Missing extensible elements

    Hello,
    For a mobile project we use SAP Netweaver Gateway in order to retrieve information from workflows stored into SAP Business Workflow.
    We are able to retrieve standard informations for a workflow but custom fields added into "Extensible Elements" section are lost when exit SAP NG.
    We have checked the configuration of SAP NG (by 4 differents person) and it seems to be OK.
    Do you have an idea why the custom fields are lost during SAP NG processing ?
    Thanks in advance
    Best regards,
    Dominique

    Hi Dominique,
    FYI. SAP Fiori Approve Requests uses task processing service. This may help.
    How to display application data in SAP Fiori Approve Requests app
    Regards, Masa
    SAP Customer Experience Group - CEG

  • Installation of SAP NetWeaver Gateway 2.0

    Dear SAP Experts,
    I wanted to install standalone SAP NW Gateway 2.0 for SAP Mobile Platform 3.0.
    Can you please help me with required documentation for installation of SAP NW Gateway 2.0 on Windows Server 2008 R2 along with the exact SWPM release which needs to be used for the installation.
    I did installed with SWPM by using option as per attached screen shot. Please let me know whether this was a right procedure for NW Gateway Installation or I need to follow something else. After installation I have checked at SAP MMC and found all the processes running. But I am not aware how to access the NW Gateway. Please guide me as I am little new to this area.
    Best Regards,
    Vishal Jain

    Hi Vishal,
    Can you please elaborate your requirements for this implementation from your DSD? For me the question is little confusing. Are you talking about integration GW that is part of SMP 3.0?
    If you want to install SAP NW GW 2.0 then till NW 731 this is an add-on component. You need to refer to the GW 2.0 master and installation guide from Service Market Place for this. Another option, if you have the opportunity, is to install SAP NW 740 standalone system which actually comprises GW 2.0 within it.
    From the screen shot what you have installed is a gateway services engine used to connect to SAP databses in a distributed environment I think this is not the requirement in your case. So you should be going with SAP GW 2.0 product installation http://help.sap.com/nwgateway
    Hope it helps.
    Regards,
    S Sumanth GV

  • SAP NetWeaver Gateway 2.0 Pre-Packaged Trial Version for Linux available

    The Linux version of SAP NetWeaver Gateway 2.0 Pre-Packaged Trial Version is available for release. For more information and to find the download links [ here|http://www.sdn.sap.com/irj/sdn/gateway?rid=/webcontent/uuid/90b292cc-a2d7-2e10-709d-9fba966a6937]. The Hyper-V Windows 2008 version will be available shortly.

    Hi Thomas,
    We currently have three pre-packaged demo version available with slightly different favours. We are evaluating which ones we want to maintain currently and currently all 3 are at SP4 levels. So a questions back to you would be, if the Hyper-V image was dropped, would the Windows 64 bit version still work for you?
    You can find that here.
    Regards,
    Wayne

  • Diff b/w Web service and window service

    What is the difference between web service and window service, whether the both are same or not, Give some explain about that each one and give some examples also.

    An XML Web service is a component that implements program
    logic and provides functionality for diseparate
    applications. These applications use standard protocols,
    such as HTTP, XML, and SOAP, to access the functionality.
    XML Web services use XML-based messaging to send and
    receive data, which enables heterogeneous applications to
    interoperate with each other. You can use XML Web services
    to integrate applications that are written in different
    programming languages and deployed on different platforms.
    In addition, you can deploy XML Web services within an
    intranet as well as on the Internet. While the Internet
    brings users closer to organizations, XML Web services
    allow organizations to integrate their applications.
    A Windows service starts much before any user logs in to
    the system (if it has been setup to start at boot up
    process). A Windows service can also be setup in such a way
    that it requires a user to start it manually ? the ultimate
    customization!
    Windows services run as background processes. These
    applications do not have a user interface, which makes them
    ideal for tasks that do not require any user interaction.
    You can install a Windows service on any server or computer
    that is running Windows 2000, Windows XP, or Windows NT.
    You can also specify a Windows service to run in the
    security context of a specific user account that is
    different from the logged on user account or the default
    computer account. For example, you can create a Windows
    service to monitor performance counter data and react to
    threshold values in a database.

  • While consuming Fusion CRM web service in ADF mobile throwing an error

    Hi,
    I am developing ADF Mobile using JDeveloper
    11.1.2.3 and consuming Fusion CRM ADF Web Services.
    While executing CRUD operations with these web services
    in ADF mobile app, I am getting SOAP response as *Error in getting response
    and got result nothing *.
    And also noticed as using JDeveloper ADF mobile App, unable to create URL service
    Data Control - REST based for FUsion CRM web services. Where as I am able to
    create SOAP based web services data control. It' strange or surprise.
    Did anyone face the above problems. Kindly let me know any suggestions or
    samples to the below contacts
    Regards
    Bhaskara Reddy S
    00919008466722
    bhaskara.sannapureddy at Crmit.com

    Dear Frank,
    Based on below links, Fusion CRM also supports REST also apart from regular SOAP Web Services.
    http://niallcblogs.blogspot.in/2012/10/204-calling-rest-service-from-fusion-crm.html AND
    http://docs.oracle.com/cd/E15586_01/fusionapps.1111/e20388/F412758AN17B21.htm
    (For e.g one of linked in profile :http://www.linkedin.com/in/minalkhodani , many teams are developing using SOAP & REST)
    Designed and developed integration services using SOAP and REST web services for Oracle Fusion CRM Marketing Modules.)
    When creating URL based data control, getting an Error as "Forbidden" , (Does it mean NOT SUPPORTED??) . Kindly advice.
    I am calling WEB SERVICE thru SOAP in AMX PAGE code as below after creating Web Services Data Control from ADF Mobile UI thru JDeveloper IDE.
    == CODE SNIPPET OF AMX PAGE CALLING SOAP FUSION CRM WEB SERVICE =======
    <?xml version="1.0" encoding="UTF-8" ?>
    <amx:view xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:amx="http://xmlns.oracle.com/adf/mf/amx"
    xmlns:dvtm="http://xmlns.oracle.com/adf/mf/amx/dvt">
    <amx:panelPage id="pp1">
    <amx:panelFormLayout id="pfl2">
    <amx:inputText value="#{bindings.name.inputValue}" label="Person First Name" id="it1"/>
    <amx:inputText value="300000001210220" label="Person Object Id" id="it2"/>
    </amx:panelFormLayout>
    <amx:facet name="header">
    <amx:outputText value="Create Person in Fusion CRM" id="ot1"/>
    </amx:facet>
    <amx:facet name="primary">
    <amx:commandButton id="cb1" text="Back" action="__back"/>
    </amx:facet>
    <amx:facet name="secondary">
    <amx:commandButton id="cb2"/>
    </amx:facet>
    <amx:panelFormLayout id="pfl1">
    </amx:panelFormLayout>
    <amx:outputText value="#{bindings.message.inputValue}" id="ot2"/>
    <amx:outputText value="#{bindings.code.inputValue}" id="ot3"/>
    *<amx:commandButton actionListener="#{bindings.createPerson.execute}" text="createPerson"*
    *disabled="#{!bindings.createPerson.enabled}" id="cb3"/>*
    <amx:iterator var="row" value="#{bindings.personParty1.collectionModel}" id="i1">
    <amx:panelLabelAndMessage label=" 300000001210220" id="plam2">
    <amx:outputText value="#{row.PartyId}" id="ot5">
    <amx:convertNumber groupingUsed="false"/>
    </amx:outputText>
    </amx:panelLabelAndMessage>
    <amx:panelLabelAndMessage label="#{bindings.name.inputValue}" id="plam1">
    <amx:outputText value="#{row.PersonFirstName}" id="ot4"/>
    </amx:panelLabelAndMessage>
    </amx:iterator>
    </amx:panelPage>
    </amx:view>
    Regards
    Bhaskara Reddy

  • Sending document to oracle xml gateway web service and body is url encoded

    Hello,
    a question from a complete newbie to web services. I have some code that is sending a soap message to an oracle xml gateway web service. In the soap message the values in the soap body look like &lt ;CNTROLAREA&gt ;
    when I would be expecting <CNTROLAREA>. What I have been told is that the content of the ReceiveDocument element has been url encoded which causes the &lt and to correct it I need to change the paramater type from object to xmlnode and to build the request as an xmldocument. The xmlnode and xmldocument comes from a .net guy so I've been trying to find the equivalent in java but am not having any luck. I have a lot of reading to do but was wondering if someone might be able to point me in the right direction on how to correct the problem. I captured the soap message being sent using tcpmon. Why does the body have the &lt instead of the < as I was expecting and is there an xmldocument type? The header part of the soap message looks as I expect. "><soapenv:Header><ns1:XMLGateway_Header xmlns:ns1="http://xmlns.oracle.com/apps/fnd/XMLGateway"><ns1:MESSAGE_TYPE>XML</ns1:MESSAGE_TYPE>. It is being sent as a com.oracle.xmlns.apps.fnd.XMLGateway.XMLGateway_Header type.
    thanks
    Thanks
    Edited by: twf123 on May 5, 2010 11:59 AM
    Edited by: twf123 on May 5, 2010 12:00 PM

    twf123 wrote:
    What I have been told is that the content of the ReceiveDocument element has been url encoded which causes the &lt and to correct it I need to change the paramater type from object to xmlnode and to build the request as an xmldocument. Where do you change the parameter type?
    The xmlnode and xmldocument comes from a .net guy so I've been trying to find the equivalent in java but am not having any luck. How do you get the data from .net guy? Which interface do you use? What processing do you do after receiving the data?

  • SAP Netweaver gateway in solution manager

    Hi ,
    We have a solution manager 7.1(netweaver 7.02) and ECC IDES EHP 6 system for which we need to configure Netweaver gateway. We have installed netweaver gateway 2.0 components in solution manager system. Now is it possible to configure gateway on solution manager system instead of building a separate netweaver system for configuring gateway.
    Wondering if we can make solman as gateway system for accessing ECC IDES. Please give your suggestion and steps to perform.
    Regards,
    Prakaash

    Hi Prakaash,
    For overall installation prerequisites for SAP NetWeaver Gateway 2.0
    components, please have a look in the installation guide -> Installation
    Prerequisites:
    http://help.sap.com/saphelp_gateway20sp06/helpdata/en/52/fc994f456a4573957461be15520fe8/frameset.htm
    Quick Starter Configuration Guide - SAP NetWeaver Gateway:
    Quick Starter Configuration Guide - SAP NetWeaver Gateway
    The meaning for 'embedded deployment', below:
    http://help.sap.com/saphelp_gateway20sp04/helpdata/en/62/91ad98b19b4a91bca737fbe442273f/content.htm
    please refer to the below link for different deployment scenarios,
    http://help.sap.com/saphelp_gateway20sp04/helpdata/en/88/889a8cbf6046378e274d6d9cd04e4d/content.htm
    also,
    http://help.sap.com/saphelp_nw04/helpdata/en/90/cbde3f7bc1eb06e10000000a1550b0/content.htm
    how to configure SAP NetWeaver Gateway in the SAP ONline Help
    http://help.sap.com/saphelp_gateway20sp06/helpdata/en/4c/a670b0e36c4c01ae2b9a042056f9dc/frameset.htm
    Note 1569624 - Installation/Delta Upgrade of SAP NW Gateway 2.0
    1560585 - SAP Netweaver Gateway 2.0 Release Note
    1417757 - System logon, determining client and language
    Thanks
    vikram

Maybe you are looking for

  • How to get required fields in the selection screen while filling a set tabl

    hai, i was filling the set up table for 2lis_13_vditm.but while filling the set up table in the selection conditions in the tcode OLI9BW. I would like to have the a field added in the selection condition which is not existing in the OLI9BW. kindly he

  • HT4910 how do i save photo on my iphone to my pc

    CAN U TEACH ME HOW TO BACK UP MY PICTURES ON MY IPHONE TO MY PC?

  • How do I get my ipod to download the movies I bought off of itunes?

    I redeemed "Les Miserables" with the code that was given for a digital copy. It said that it was itunes compatible and my ipod has had videos on it before but now it doesn't seem work anymore and none of my movies or music videos show up. It plays on

  • Opening window with display_items

    Hi, I need to show some messages (validation errors) on the press of a button. For this, i have created a document window and a content canvas containing only 1 display item. Before opening the window, i populate the display item with the message i w

  • Flashing Text

    I wanted to know if there is somewhere in Dreamweaver that allows you to make text flash. I am in the process of doing a webpage and don't know how to do that. Also are there special codes that I would have to use?