This resource will be reviewed shortly.
If you think this resource contain inappropriate content, please report to webmaster.
In this step by step tutorial, I will discuss how to use Google AdSense APIs to retrieve Adsense account information.
Step 1: Enable AdSense API Service in your Google Account
If you already have an approved AdSense account, you can that Google account to join the AdSense API program. Visit the Google API Console to apply for AdSense API program.
You may use any Google account to implement AdSense API application and it does not need to be an AdSense account. However, you will need an AdSense account to test the application you developed.
It will show you a welcome screen which you have to click on the button to proceed to the API console screen. After you reach the Console, you will be shown the list of available API services. You can click on the AdSense Management API button to enable it.
You will be taken to a screen and will be asked to agree to "AdSense Management API Terms and Conditions".
After you accept the Terms and Conditions, you will see that the AdSense APIs service is enabled for you.
Step 2: Generate an App Key
In the API Console, go to the API Access console. You will see that an App Key is automatically generated for you. This is unique key is required for you to make the API calls and Google will depend on this key to identify who is making the call.
You may optionally use OAuth 2.0 token for your project, but for this tutorials, we will use the simple App Key. You can create an App Key for your AdSense API project by clicking on the "Generate Key" link.
The above steps conclude the basic configuration required on your Google account to enable your application to start using the AdSense APIs.
In the next steps, I will discuss how to start using the APIs from your code and how to use the retrieved data.
Step 3: Start coding and call the APIs
Once you have the APIs enabled using the previous steps, you can start coding your application and call the AdSense Management APIs.
Before you call any APIs, you must authenticate the call. There are detailed documentation available on the Google website describing how to authenticate a user, get a client Auth token and how to use this token to make further API calls.
There are several client libraries available to make the authentication process easier. Client libraries are available in languages like .NET, Java, Python etc.