BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
CTurley
Fluorite | Level 6

Has anyone tried connecting to the Google Doubleclick (DFP Adserver) API. I have read different documentation on connecting to Google Analytics and other API's through SAS, bit when I apply these to my situation, it does not seem to ad up. It seems these APIs are different and more complicated. IT uses some JST Headers? I am looking for sample code if anyone has created any for this API.

1 ACCEPTED SOLUTION

Accepted Solutions
CTurley
Fluorite | Level 6
The api setup in the google dasboard was incorrect. It was under the web development type and should have been other. All is well now.

View solution in original post

5 REPLIES 5
ChrisHemedinger
Community Manager

I think it depends on what you want to do.  Are you downloading reports?  Or uploading conversions data?

 

Glancing over the doc about the API, it looks like a very similar setup to Google Analytics in that there is a REST API that can be driven from HTTP, which means that you ought to be able to accomplish this with PROC HTTP.

 

See my complete paper about Google Analytics with SAS - it might help.

SAS Hackathon registration is open! Build your skills. Make connections. Enjoy creative freedom. Maybe change the world.
CTurley
Fluorite | Level 6

What do I use as a redirect url?

ChrisHemedinger
Community Manager

To get your auth token?  In my paper, I covered this -- the URL for the call looks something like this:

 

https://accounts.google.com/o/oauth2/v2/auth? 
  scope=https://www.googleapis.com/auth/analytics.readonly
 &redirect_uri=urn:ietf:wg:oauth:2.0:oob&response_type=code
 &client_id=yourappid.apps.googleusercontent.com

(But all on one line)

SAS Hackathon registration is open! Build your skills. Make connections. Enjoy creative freedom. Maybe change the world.
CTurley
Fluorite | Level 6

What is the Client secret? Is that the API Key? I have in the google API dashboard a APIKey, ClientID and a Service Account Key (ID).

CTurley
Fluorite | Level 6
The api setup in the google dasboard was incorrect. It was under the web development type and should have been other. All is well now.

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 5 replies
  • 727 views
  • 1 like
  • 2 in conversation