Google Search Console is the most important tool when it comes to keyword data crunching on your site. That said, data for queries and pages must be exported separately. There is no automatic export for the search queries per page and all the exports are limited to 1000 search keys.
In this article I will cover the process of creating API keys that are required to communicate with the Google Search Console API. This makes it possible to query Google Search Console using a simple scripting language like Python and unlocking the possibility to automate time-consuming & repetitive tasks.
Create Google Search Console API Key
The process of creating an API in Google Search Console is very complex and you will need to navigate multiple pages to gain access to the Keys. The keys are created from the Google Developers console. This is a separate Console that developers use to manage the different entry points to their services.
STEP 1 – Create a Project and Enable the Google Search Console API
In this step we will be creating a project in the Google Developers Console and enable the API.
1. Create New Project
Access the Google Developers Console and create a new project. Login with credentials that you use to access your projects on Google Search Console.
Provide a meaningful project name that will describe your project. A project is the main container that can be used to access multiple Google Services through API.
2. Go to the main dashboard and search for Google Search Console and click on Google Search Console API
3. Click Enable. Once enabled functionality to access Google Search Console will be added to the UI.
Step 2: Setup the OAuth Consent Screen
The consent screen is required so that the user will see a warning that they need to provide permission to your app.
1. Go to the menu on the right and Select OAuth Consent Screen
2. If you want to integrate through code select Internal and press CREATE.
3. Provide the product name and the support mail. Use the email that is associated with your Google Search Console Account and Press Save.
Step 3 Create Credentials
Now that you have setup the OAuth consent screen you can move to create the actual keys that you will need to access the API.
1. Go the left menu and select Credentials.
2. Click on Create Credentials
3. Select OAuth client ID
4. Setup the application type to the Desktop app and Provide a name for the client application.
5. 5. Once you press CREATE you will be presented with the ClientID and the Client Secret. These are the credentials you will need to access the Google Search Console through its API. You can now use code to simply proceed with the data extraction from Google Search Console
Simon Bonello is Co-founder of Gain Changer. His main area of focus is Business Process Automation, Software Technical Architecture and Technical SEO