Loading ...
Sorry, an error occurred while loading the content.

1114Re: [yws-searchmarketing] Re: Version 6.0 BasicReportingService example?

Expand Messages
  • Bill Harrelson
    Mar 5, 2010
    • 0 Attachment
      Thanks Reed,

      Very helpful.  I notice that you are using "OnBehalfOf" in your template, and I can't find any documentation on which sets of un/pw/master account id's/api key work.

      I think I must be very confused.

      Say I have two accounts:

      acct1 username=un1 password=pw1 masterAccountId=ma1 - this is the account that has the API token (token1)
      acct2 username=un2 password=pw2 masterAccountId=ma2- this account is a sub-account of acct1

      Now, I want to retrieve a report for acct2.

      If I set un=un1, pw=pw1, maId=ma1, oboUn=un2, oboPw=pw2, token1 -  I get the report back for the first account, not the second that I wanted.
      If I set un=un1, pw=pw1, maId=ma2, oboUn=un2, oboPw=pw2 token1 -  I get 'can't log in for un1'
      If I set un=un2, pw=pw2, maId=ma2, oboUn=un1, oboPw=pw1, token 1 - I get "Account cannot be accessed at this location." so clearly I've got the location wrong.

      So I call location service with un=un2, pw=pw2, maId=ma2, oboUn=un1, oboPw=pw1, token 1 and I get 'token1' is not a valid license key.

      There's something I'm clearly not understanding about this api and am looking for help anywhere I can get it.  It all worked fine in V5.

      TIA

      Bill


      reedpowell wrote:
       

      I agree that a collection of just XML SOAP request/EWS response document for each of the methods would be great. I don't use any of the client libraries because they all see to compile in the username/password info, and I work with way too many clients for that to work out. So I create my SOAP documents via server side programming using SOAP templates for each method that I use.

      Here is the V6 report request template that I just made this week as part of my V6 upgrade process. Hope it helps you. Just fill in the access information and the start/end dates. Hopefully the formatting stays intact!
      -reed

      <cfxml variable="mstring" >
      <?xml version="1.0" encoding="UTF- 8"?>
      <soap:Envelope
      xmlns:namesp1= "http://marketing. ews.yahooapis. com/V6"
      xmlns:xsi="http://www.w3. org/2001/ XMLSchema- instance"
      xmlns:soapenc= "http://schemas. xmlsoap.org/ soap/encoding/"
      xmlns:xsd="http://www.w3. org/2001/ XMLSchema"
      soap:encodingStyle= "http://schemas. xmlsoap.org/ soap/encoding/"
      xmlns:soap="http://schemas. xmlsoap.org/ soap/envelope/"
      xmlns:wsse="http://schemas. xmlsoap.org/ ws/2002/07/ secext"
      >
      <soap:Header>
      <wsse:Security>
      <wsse:UsernameToken soapenc:arrayType= "xsd:string[ 2]" xsi:type="soapenc: Array">
      <wsse:Username xsi:type="xsd: string">Username </wsse:Username>
      <wsse:Password xsi:type="xsd: string">Password </wsse:Password>
      </wsse:UsernameToke n>
      </wsse:Security>
      <license xmlns="http://marketing. ews.yahooapis. com/V6" xsi:type="xsd: string">
      License</license>
      <masterAccountID xmlns="http://marketing. ews.yahooapis. com/V6" xsi:type="xsd: string">
      MasterAccountID< /masterAccountID >
      <accountID xsi:type="xsd: string">Acct_ ID</accountID>
      <wsse:onBehalfOfUse rname xsi:type="xsd: string">APIlogin </wsse:onBehalfO fUsername>
      <wsse:onBehalfOfPas sword xsi:type="xsd: string"># APIpas</wsse: onBehalfOfPasswo rd>
      </soap:Header>

      <soap:Body>
      <addReportRequest xmlns="http://marketing. ews.yahooapis. com/V6">
      <accountID>Acct_ ID</accountID>
      <reportRequest>
      <startDate xsi:type="tns: Date">#variables .DateToPull# T12:00:00< /startDate>
      <endDate xsi:type="tns: Date">#variables .DateToPull# T12:00:00< /endDate>
      <reportName xsi:type="xsd: string">Keyword report</reportName>
      <reportType xsi:type="tns: BasicReportType" >KeywordSummary< /reportType>
      </reportRequest>
      <fileOutputFormat>
      <fileOutputType xsi:type="tns: FileOutputType" >XML</fileOutput Type>
      <zipped>true< /zipped>
      </fileOutputFormat>
      </addReportRequest>
      </soap:Body>
      </soap:Envelope>

      --- In yws-searchmarketing @yahoogroups. com, "billharrelson" <bill.harrelson@ ...> wrote:
      >
      > Could someone post an example message for requesting a report? I'm having some difficulty generating one that is acceptable.
      >
      > Thanks.
      >

    • Show all 5 messages in this topic