Amazon Web Services Continued

Ok, I am LAME…. Here is the CORRECT destination configuration ( in the proxy-config.xml ) to make the webservice work from within Flex using the WebService tag plus LiveCyle Data Services ES…


<destination id="amazon" adapter="soap-proxy">
<properties>
<url> http://webservices.amazon.com/AWSECommerceService/
AWSECommerceService.wsdl
</url>
<soap>http://soap.amazon.com/onca/soap?Service=AWSECommerceService
</soap>
</properties>
</destination>

I was calling the <url></url> above, <wsdl></wsdl>... and I had not inlcuded the <soap></soap> at all since I thought Flex Framework did that all by iteself….once I changed it to <url></url> and added the <soap> tag, everything worked fine.

I hope this helps other flex developers, as I found almost zilch online.

If you enjoyed this post, make sure you subscribe to the SDFlex RSS feed!

6 Responses to “Amazon Web Services Continued”

  1. Nell Says:

    Hi there,

    Could you tell me where i have to put that code to take care of the security issue?

    Thanks in advance

  2. admin Says:

    Hi Nell,

    It goes in the proxy-config.xml file in your LCDS server. If you use the standard set up, you’ll find it at:

    [your drive]\[your LCDS folder]\jrun4\servers\default[or your project folder]\flex\WEB-INF\flex

    Hope that helped.

    Kev

  3. Brendon J. Wilson Says:

    This helps if you’re using the proxy, but what if you’re simply using the WebService MXML tag directly, as opposed to using the Import Web Service option? For example:

    {amazonDeveloperId}

    {itemId}
    {idType}
    {searchIndex}
    ItemAttributes,Images,Tracks,EditorialReview

    Amazon has a crossdomain.xml file, so this should simply work. In fact, it DID work until Flash 9,0,124,0. Any ideas?

  4. “Security error accessing url” in Flash 9,0,124,0 at www.brendonwilson.com Says:

    […] wall. Unless I’m totally mistaken, and there’s a workaround that doesn’t involve using a proxy? « US Border Laptop Search Policies Are […]

  5. admin Says:

    Brendon,

    What url are you using to access the AWS?

    Kev

  6. admin Says:

    I just wrote a quick HTTP Service that works fine without the Proxy:


    <mx:HTTPService id="AmazonSearch"
    showBusyCursor="true"
    url="http://ecs.amazonaws.com/onca/xml" method="POST"
    resultFormat="e4x"
    result="itemSearchResult(event)">

    <mx:request >

    <Version>2008-06-26</Version>
    <Service>AWSECommerceService</Service>
    <Operation>ItemSearch</Operation>
    <AWSAccessKeyId>[ your aws access key id here ]</AWSAccessKeyId>
    <Keywords>hunting</Keywords>
    <SearchIndex>Books</SearchIndex>
    <Count>20</Count>
    <ResponseGroup>Medium</ResponseGroup>
    <ItemPage>5</ItemPage>

    </mx:request>

    </mx:HTTPService>

Leave a Reply