How to Determine Device Type with the Php Client Library

2012-08-15 Thread Ashley Bennett
I am wondering what the best way is to determine what the device type a 
campaign is targeting is.

Within the web interface this is set at the campaign level, and so I assume 
I would use CampaignService or CampaignCriterionService for this api call, 
but I can't determine which field I am supposed to request in order to get 
this information within my php-based reporting file which returns data in a 
set and inserts it into our own C.R.M.

I am looking for enumerations like 'Tablet' or 'Mobile' or 'Desktop', or 
some version of the like.

Any assistance would be appreciated.

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
http://adwordsapi.blogspot.com
http://groups.google.com/group/adwords-api
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en


Re: How to Determine Device Type with the Php Client Library

2012-08-15 Thread Ewan Heming
Hi,

I think that the device type is called a Platform 
targetin
 the CampaignCriterionService, so you need to issue a 
getrequest
 with a 
predicateto
 filter the 
Criterion.Type
 so 
the results only include targets of the *PLATFORM* type; you should get a 
response with a list of 
CampaignCriterion
 objects from 
which you can extract the campaignId to obtain a list of campaigns that are 
using device targeting. If you need the specific device that is being used, 
then you can look at the id of each criterion to find out which 
platform has 
been selected.

If you're using v201206, then you could also check out the 
query
 operation 
of the CampaignCriterionService to do the same thing using 
AWQL instead 
of a predicate; AWQL is a recent addition to the AdWords API that lets you 
select objects using an SQL-like syntax.
  
Regards,

Ewan

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
http://adwordsapi.blogspot.com
http://groups.google.com/group/adwords-api
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en