locked
sample v5 xml report request RRS feed

  • Question

  • I,ve been using v4 adcenter api quite happily and now i'm switching over to v5 because of the extra features which i require but i'm having problems with requesting a report. can anyone please post a sample v5 xml report request e.g keywordperformancereportrequest.
    Thursday, April 24, 2008 1:51 PM

All replies

  • Here is the soap request that I send to MSN for my keyword performance report:


    <!DOCTYPE root>
    <root>
        <soapenv:Envelope xmlnsTongue Tiedoapenv="http://schemas.xmlsoap.org/soap/envelope/"
            xmlns:xsd="http://www.w3.org/2001/XMLSchema"
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <soapenv:Header>
                <ns1:ApplicationToken
                    soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                    soapenv:mustUnderstand="0"
                    xmlns:ns1="https://adcenter.microsoft.com/api/advertiser/v5"/>
                <ns2Big SmileeveloperToken
                    soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                    soapenv:mustUnderstand="0"
                    xmlns:ns2="https://adcenter.microsoft.com/api/advertiser/v5">
                    <ns2:Value>XXXXXXXXX</ns2:Value>
                </ns2Big SmileeveloperToken>
                <ns3:UserCredentials
                    soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                    soapenv:mustUnderstand="0"
                    xmlns:ns3="https://adcenter.microsoft.com/api/advertiser/v5">
                    <ns3Stick out tongueassword>XXXXXXXX</ns3Stick out tongueassword>
                    <ns3:Username>XXXXXXXXg</ns3:Username>
                </ns3:UserCredentials>
                <ns4:AccountId
                    soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                    soapenv:mustUnderstand="0"
                    xmlns:ns4="https://adcenter.microsoft.com/api/advertiser/v5"/>
            </soapenv:Header>
            <soapenv:Body>
                <QueueReportRequest
                    xmlns="https://adcenter.microsoft.com/api/advertiser/v5">
                    <ReportRequest xsi:type="ns5:KeywordPerformanceReportRequest"
                        xmlns:ns5="https://adcenter.microsoft.com/api/advertiser/v5">
                        <Format>Xml</Format>
                        <Language>English</Language>
                        <ReportName>Mykeyword report</ReportName>
                        <ReturnOnlyCompleteData>false</ReturnOnlyCompleteData>
                        <Aggregation>Daily</Aggregation>
                        <Columns>
                            <KeywordPerformanceReportColumn>
                                AccountName</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                CampaignName</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                Keyword</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                TimePeriod</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                CampaignId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                AdGroupId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                KeywordId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                AdId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                AdDistribution</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                MatchType</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                LanguageAndRegion</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                DestinationUrl</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                CurrencyCode</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                Impressions</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                Clicks</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                Ctr</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                AverageCpc</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                Spend</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                AveragePosition</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                Conversions</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                ConversionRate</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                CostPerConversion</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>
                                CurrentMaxCpc</KeywordPerformanceReportColumn>
                        </Columns>
                        <Scope>
                            <AccountIds>
                                <ns6:int
                                    xmlns:ns6="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
                                    XXXXXX</ns6:int>
                            </AccountIds>
                        </Scope>
                        <Time>
                            <CustomDates>
                                <Date>
                                    <Day>23</Day>
                                    <Month>4</Month>
                                    <Year>2008</Year>
                                </Date>
                            </CustomDates>
                        </Time>
                    </ReportRequest>
                </QueueReportRequest>
            </soapenv:Body>
        </soapenv:Envelope>
    </root>


    You can view the soap response in another posting: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=3093002&SiteID=1
    Thursday, April 24, 2008 3:14 PM
  • hi, thanks for your reply. i'm still having problems with v5. I'm sending the above request with curl using my credentials and accountid etc. but i get an empty result back, no error or anything.  in fact i can send any file other than xml i just get an empty response. I'm using curl for the v4 reports aswell and its working fine.

    any help appreciated.

    im sending the request to the following url, is it correct?

    https://adcenterapi.microsoft.com/Api/Advertiser/V5/Reporting/ReportingService.svc

    Thursday, April 24, 2008 6:08 PM
  • I believe you want:

     

    https://adcenterapi.microsoft.com/Api/Advertiser/V5/Reporting/ReportingService.svc?wsdl

    If you continue to have problems, post your SOAP here, or feel free to open a support ticket

     

    Jeff Dillon, API Support

     

    Thursday, April 24, 2008 11:49 PM
  • <?xml version="1.0" encoding="utf-8"?>

    <soapenv:Envelope xmlnsoapenv="http://schemas.xmlsoap.org/soap/envelope/"
        xmlns:xsd="http://www.w3.org/2001/XMLSchema"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
       
        <soapenv:Header>
            <ns1:ApplicationToken
                soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                soapenv:mustUnderstand="0"
                xmlns:ns1="https://adcenter.microsoft.com/api/advertiser/v5"/>
            <ns2Big SmileeveloperToken
                soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                soapenv:mustUnderstand="0"
                xmlns:ns2="https://adcenter.microsoft.com/api/advertiser/v5">
                    <ns2:Value>xxxxxxx</ns2:Value>
                </ns2Big SmileeveloperToken>
                <ns3:UserCredentials
                    soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                    soapenv:mustUnderstand="0"
                    xmlns:ns3="https://adcenter.microsoft.com/api/advertiser/v5">
                    <ns3Stick out tongueassword>xxxxxxxxx</ns3Stick out tongueassword>
                    <ns3:Username>xxxxxxxxxx</ns3:Username>
                </ns3:UserCredentials>
                <ns4:AccountId
                    soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next"
                    soapenv:mustUnderstand="0"
                    xmlns:ns4="https://adcenter.microsoft.com/api/advertiser/v5"/>
            </soapenv:Header>

            <soapenv:Body>
                <QueueReportRequest xmlns="https://adcenter.microsoft.com/api/advertiser/v5">
                    <ReportRequest xsi:type="ns5:KeywordPerformanceReportRequest" xmlns:ns5="https://adcenter.microsoft.com/api/advertiser/v5">
                        <Format>Xml</Format>
                        <Language>English</Language>
                        <ReportName>Mykeyword report</ReportName>
                        <ReturnOnlyCompleteData>false</ReturnOnlyCompleteData>
                        <Aggregation>Daily</Aggregation>
                        <Columns>
                            <KeywordPerformanceReportColumn>AccountName</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>CampaignName</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>Keyword</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>TimePeriod</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>CampaignId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>AdGroupId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>KeywordId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>AdId</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>AdDistribution</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>MatchType</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>LanguageAndRegion</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>DestinationUrl</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>CurrencyCode</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>Impressions</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>Clicks</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>Ctr</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>AverageCpc</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>Spend</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>AveragePosition</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>Conversions</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>ConversionRate</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>CostPerConversion</KeywordPerformanceReportColumn>
                            <KeywordPerformanceReportColumn>CurrentMaxCpc</KeywordPerformanceReportColumn>
                        </Columns>
                        <Scope>
                            <AccountIds>
                                <ns6:int xmlns:ns6="http://schemas.microsoft.com/2003/10/Serialization/Arrays">xxxxx</ns6:int>
                            </AccountIds>
                        </Scope>
                        <Time>
                            <CustomDates>
                                <Date>
                                    <Day>23</Day>
                                    <Month>4</Month>
                                    <Year>2008</Year>
                                </Date>
                            </CustomDates>
                        </Time>
                    </ReportRequest>
                </QueueReportRequest>
            </soapenv:Body>
    </soapenv:Envelope>


    Friday, April 25, 2008 10:18 AM
  • Did you try the URL that I suggested? I would suggest first getting a simpler method call working first, such as

    V5 GetCampaignsByAccountId. If you continue to have problems, please open a support ticket

     

    Sincerely,

     

    Jeff Dillon, API Support

     

     

    Friday, April 25, 2008 5:11 PM