Google Ads Connector for SSISRead / write Google Ads data inside your app (e.g. Campaigns, Ad Groups, Keywords, Spending, Performance); perform many Google Ads operations without coding, just using easy to use high performance API Connector for Google Ads In this article you will learn how to quickly and efficiently integrate Google Ads data in SSIS without coding. We will use high-performance Google Ads Connector to easily connect to Google Ads and then access the data inside SSIS. Let's follow the steps below to see how we can accomplish that! Google Ads Connector for SSIS is based on ZappySys API Connector Framework which is a part of SSIS PowerPack. It is a collection of high-performance SSIS connectors that enable you to integrate data with virtually any data provider supported by SSIS, including SQL Server. SSIS PowerPack supports various file formats, sources and destinations, including REST/SOAP API, SFTP/FTP, storage services, and plain files, to mention a few (if you are new to SSIS and SSIS PowerPack, find out more on how to use them). |
Connect to Google Ads in other apps
|
Video Tutorial - Integrate Google Ads data in SSIS
This video covers the following topics and more, so please watch carefully. After watching the video, follow the steps outlined in this article:
- How to download and install the required PowerPack for
Google Ads integration in SSIS - How to configure the connection for
Google Ads - Features of the
ZappySys API Source (Authentication / Query Language / Examples / Driver UI) - How to use the
Google Ads in SSIS
Prerequisites
Before we begin, make sure the following prerequisites are met:
- SSIS designer installed. Sometimes it is referred as BIDS or SSDT (download it from Microsoft).
- Basic knowledge of SSIS package development using Microsoft SQL Server Integration Services.
- SSIS PowerPack is installed (if you are new to SSIS PowerPack, then get started!).
Read data from Google Ads in SSIS (Export data)
In this section we will learn how to configure and use Google Ads Connector in API Source to extract data from Google Ads.
-
Begin with opening Visual Studio and Create a New Project.
Select Integration Service Project and in new project window set the appropriate name and location for project. And click OK.
-
In the new SSIS project screen you will find the following:
- SSIS ToolBox on left side bar
- Solution Explorer and Property Window on right bar
- Control flow, data flow, event Handlers, Package Explorer in tab windows
- Connection Manager Window in the bottom
Note: If you don't see ZappySys SSIS PowerPack Task or Components in SSIS Toolbox, please refer to this help link. -
Now, Drag and Drop SSIS Data Flow Task from SSIS Toolbox. Double click on the Data Flow Task to see Data Flow designer.
-
From the SSIS toolbox drag and API Source (Predefined Templates) on the data flow designer surface, and double click on it to edit it:
-
Select New Connection to create a new connection:
-
Use a preinstalled Google Ads Connector from Popular Connector List or press Search Online radio button to download Google Ads Connector. Once downloaded simply use it in the configuration:
Google Ads -
Proceed with selecting the desired Authentication Type. Then select API Base URL (in most cases default one is the right one). Finally, fill in all the required parameters and set optional parameters if needed. You may press a link Steps to Configure which will help set certain parameters. More info is available in Authentication section.
User accounts represent a developer, administrator, or any other person who interacts with Google APIs and services. User accounts are managed as Google Accounts, either with Google Workspace or Cloud Identity. They can also be user accounts that are managed by a third-party identity provider and federated with Workforce Identity Federation. [API reference]
Steps how to get and use Google Ads credentials
Follow these steps on how to create Client Credentials (User Account principle) to authenticate and access Google Ads API in SSIS package or ODBC data source:
WARNING: If you are planning to automate processes, we recommend that you use a Service Account authentication method. In case, you still need to use User Account, then make sure you use a system/generic account (e.g.automation@my-company.com
). When you use a personal account which is tied to a specific employee profile and that employee leaves the company, the token may become invalid and any automated processes using that token will start to fail.Manager Account Setup - Obtain Developer Token
To access Google Ads API (your data or someone else data) you must perform the following steps (high level). Detailed steps listed in the next sections.
- Create a Google Ads Manager account (formally known as MCC).
- Apply for Production data access (Upgrade Developer Token access Level to Basic).
- Link manager account with Google Ads Account.
- Create a new Project and obtain Client Id and Client Secret
Step-1: Create a Google Ads Manager account (formally known as MCC)
Very first step to access Google Ads API for your own account or someone else account, you will need something called Google Manager Account (formally known as MCC). It will look like a Normal Google Ads Account with some difference so dont get confused if you see similar interface as Ads account.
Click here to see detailed instructions on how to create a manager account. Once you created a manager account, you can login or switch between Ads account and Manager account like below. You can identify manager account using "Manager" word next to the account id when you click Profile dropdown.Step-2: Obtain Developer Token
Once you have created and logged in to your Google Ads Manager Account (formally known as MCC) we are ready for the next step which is obtain Developer Token. To access Google Ads API you need to pass developer token in each API call. By default Developer Token is only allowed to access Sandbox (Test) account. If you like to access Production data (Live Ads Account) then you must apply for Basic Access by clicking link under Access Level (See next section for information).
Here is how to can obtain your Developer Token.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Admin icon
- Click on API Center (This option will be missing if you are logged in to Regular Ads account as Client and not using Manager Account (MMC)
- Expand Access Level, Click Apply for Basic Access if it says "Test". By default Developer Token is created with Test Account access only. To access Production Ads account you must apply for higher access level. Must be Basic or Standard (not Test). After click the link you will see form with few questions, please fill out that and submit the form. Apploval process may take 3-5 days (or longer in some cases if you did not provide enough information).
- If your token is already approved for the basic access then copy the token and paste on the Google Ads Connector - Connection UI (For Developer Token property)
Link Manager Account to Google Ads Account
After you have manager account ready, next step is to link manager account with Google Ads Account. You have to send invitation from Manager account to access Google Ads account (it can be your own account or someone else). Here is how to send invite to link Google Ads account.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Accounts icon > Sub-account settings > Send Link Request
- Click on Add Sign (+) and select + Link existing account option
- When prompted enter Account Id(s) you like to link with this Manager Account.
- Click Send Request. You can find Ad Account Id usually at the Top-Right corner after you login to the Google Ads account.
- Now ask Google Ads Account owner to check email. Click Accept Invitation link in the email (If prompted login as Google Ads Account owner).
-OR-
Another way to see Invitation, Login to Google Ads account (Or Switch from the Top-Right corner by clicking Profile icon). Go to Admin icon > Access and security > Managers Tab. Find the pending invitation and click ACCEPT. - That's it. Now your Manager account is linked to the Google Ads account
Obtain ClientId and ClientSecret
Step-1: Create project
This step is optional, if you already have a project in Google Cloud and can use it. However, if you don't, proceed with these simple steps to create one:
-
First of all, go to Google API Console.
-
Then click Select a project button and then click NEW PROJECT button:
-
Name your project and click CREATE button:
-
Wait until the project is created:
- Done! Let's proceed to the next step.
Step-2: Enable Google Ads API
In this step we will enable Google Ads API:
-
Select your project on the top bar:
-
Then click the "hamburger" icon on the top left and access APIs & Services:
-
Now let's enable several APIs by clicking ENABLE APIS AND SERVICES button:
-
In the search bar search for
Ads
and then locate and select Google Ads API: -
Enable Google Ads API:
- Done! Let's proceed to the next step.
Step-3: Create OAuth application
-
First of all, click the "hamburger" icon on the top left and then hit VIEW ALL PRODUCTS:
-
Then access Google Auth Platform to start creating an OAuth application:
-
Start by pressing GET STARTED button:
-
Next, continue by filling in App name and User support email fields:
-
Choose Internal option, if it's enabled, otherwise select External:
-
Optional step if you used
Internal
option in the previous step. Nevertheless, if you had to useExternal
option, then click ADD USERS to add a user: -
Then add your contact Email address:
-
Finally, check the checkbox and click CREATE button:
- Done! Let's create Client Credentials in the next step.
Step-4: Create Client Credentials
-
In Google Auth Platform, select Clients menu item and click CREATE CLIENT button:
-
Choose
Desktop app
as Application type and name your credentials: -
Continue by opening the created credentials:
-
Finally, copy Client ID and Client secret for the later step:
- Done! We have all the data needed for authentication, let's proceed to the last step!
Step-5: Configure connection
-
Now go to SSIS package or ODBC data source and use previously copied values in User Account authentication configuration:
- In the ClientId field paste the Client ID value.
- In the ClientSecret field paste the Client secret value.
- In the DeveloperToken field paste the Developer Token value.
-
Press Generate Token button to generate Access and Refresh Tokens.
-
Finally, click Test Connection to confirm the connection is working.
- Done! Now you are ready to use Google Ads Connector!
Configuring authentication parameters
Google AdsUser Account [OAuth]https://googleads.googleapis.com/[$ApiVersion$]Required Parameters UseCustomApp Fill-in the parameter... CustomerId (without dash e.g. 2125557752) Fill-in the parameter... DeveloperToken Fill-in the parameter... Optional Parameters ClientId ClientSecret Scope https://www.googleapis.com/auth/adwords Login CustomerId (without dash e.g. 2125557752) Linked CustomerId (without dash e.g. 2125557752) API Version v20 RetryMode RetryWhenStatusCodeMatch RetryStatusCodeList 429 RetryCountMax 5 RetryMultiplyWaitTime True Redirect URL (Only for Web App) Service accounts are accounts that do not represent a human user. They provide a way to manage authentication and authorization when a human is not directly involved, such as when an application needs to access Google Cloud resources. Service accounts are managed by IAM. [API reference]
Steps how to get and use Google Ads credentials
To access Google Ads API (your data or someone else data) you must perform the following steps (high level). Detailed steps listed in the next sections.
- Create a Manager account.
- Apply for Production data access (Upgrade Developer Token access Level to Basic).
- Link manager account with Google Ads Account.
- Inside Manager account apply for Basic API Access level so you can use Developer Token to access Live data (Production Ads account). Without Basic access level Developer Token can be only used for Test / Sandbox Ads account.
- Create a new Project and obtain Client Id and Client Secret
Manager Account Setup - Obtain Developer Token
To access Google Ads API (your data or someone else data) you must perform the following steps (high level). Detailed steps listed in the next sections.
- Create a Google Ads Manager account (formally known as MCC).
- Apply for Production data access (Upgrade Developer Token access Level to Basic).
- Link manager account with Google Ads Account.
- Create a new Project and obtain Service Account details
Step-1: Create a Google Ads Manager account (formally known as MCC)
Very first step to access Google Ads API for your own account or someone else account, you will need something called Google Manager Account (formally known as MCC). It will look like a Normal Google Ads Account with some difference so dont get confused if you see similar interface as Ads account.
Click here to see detailed instructions on how to create a manager account. Once you created a manager account, you can login or switch between Ads account and Manager account like below. You can identify manager account using "Manager" word next to the account id when you click Profile dropdown.Step-2: Obtain Developer Token
Once you have created and logged in to your Google Ads Manager Account (formally known as MCC) we are ready for the next step which is obtain Developer Token. To access Google Ads API you need to pass developer token in each API call. By default Developer Token is only allowed to access Sandbox (Test) account. If you like to access Production data (Live Ads Account) then you must apply for Basic Access by clicking link under Access Level (See next section for information).
Here is how to can obtain your Developer Token.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Admin icon
- Click on API Center (This option will be missing if you are logged in to Regular Ads account as Client and not using Manager Account (MMC)
- Expand Access Level, Click Apply for Basic Access if it says "Test". By default Developer Token is created with Test Account access only. To access Production Ads account you must apply for higher access level. Must be Basic or Standard (not Test). After click the link you will see form with few questions, please fill out that and submit the form. Apploval process may take 3-5 days (or longer in some cases if you did not provide enough information).
- If your token is already approved for the basic access then copy the token and paste on the Google Ads Connector - Connection UI (For Developer Token property)
Link Manager Account to Google Ads Account
After you have manager account ready, next step is to link manager account with Google Ads Account. You have to send invitation from Manager account to access Google Ads account (it can be your own account or someone else). Here is how to send invite to link Google Ads account.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Accounts icon > Sub-account settings > Send Link Request
- Click on Add Sign (+) and select + Link existing account option
- When prompted enter Account Id(s) you like to link with this Manager Account.
- Click Send Request. You can find Ad Account Id usually at the Top-Right corner after you login to the Google Ads account.
- Now ask Google Ads Account owner to check email. Click Accept Invitation link in the email (If prompted login as Google Ads Account owner).
-OR-
Another way to see Invitation, Login to Google Ads account (Or Switch from the Top-Right corner by clicking Profile icon). Go to Admin icon > Access and security > Managers Tab. Find the pending invitation and click ACCEPT. - That's it. Now your Manager account is linked to the Google Ads account
Obtain ClientId and ClientSecret
Step-1: Create project
This step is optional, if you already have a project in Google Cloud and can use it. However, if you don't, proceed with these simple steps to create one:
-
First of all, go to Google API Console.
-
Then click Select a project button and then click NEW PROJECT button:
-
Name your project and click CREATE button:
-
Wait until the project is created:
- Done! Let's proceed to the next step.
Step-2: Enable Google Ads API
In this step we will enable Google Ads API:
-
Select your project on the top bar:
-
Then click the "hamburger" icon on the top left and access APIs & Services:
-
Now let's enable several APIs by clicking ENABLE APIS AND SERVICES button:
-
In the search bar search for
ads
and then locate and select Google Ads API: -
Enable Google Ads API:
- Done! Let's proceed to the next step.
Step-3: Create Service Account
Use the steps below to create a Service Account in Google Cloud:
-
First of all, go to IAM & Admin in Google Cloud console:
-
Once you do that, click Service Accounts on the left side and click CREATE SERVICE ACCOUNT button:
-
Then name your service account and click CREATE AND CONTINUE button:
-
Continue by clicking Select a role dropdown and start granting service account Project Viewer roles:
-
Find Project group and select Viewer role:
-
Finish adding roles by clicking CONTINUE button:
You can always add or modify permissions later in IAM & Admin. -
Finally, in the last step, just click button DONE:
-
Done! We are ready to add a Key to this service account in the next step.
Step-4: Add Key to Service Account
We are ready to add a Key (JSON or P12 key file) to the created Service Account:
-
In Service Accounts open newly created service account:
-
Next, copy email address of your service account for the later step:
-
Continue by selecting KEYS tab, then press ADD KEY dropdown, and click Create new key menu item:
-
Finally, select JSON (Engine v19+) or P12 option and hit CREATE button:
- Key file downloads into your machine. We have all the data needed for authentication, let's proceed to the last step!
Step-5: Give Permissions to Service Account
Now it's time to grant permission to Service Account we just created:
- Login to https://ads.google.com/aw/settings/account with Google Ads account credentials (If propmpted choose your Ads account).
-
Go to Admin section, Access and security, Click on Users tab.
- Click on Add Icon (+) and enter service account email address which you like to use for data access and choose permissions.
- That's it! Let's proceed to the configuration!
Step-6: Configure connection
-
Now go to SSIS package or ODBC data source and configure these fields in Service Account authentication configuration:
- In the Service Account Email field paste the service account Email address value you copied in the previous step.
- In the Service Account Private Key Path (i.e. *.json OR *.p12) field use downloaded key file path.
- Done! Now you are ready to use Google Ads Connector!
Each Google API Console project can be associated with the developer token from only one manager account. Once you make a Google Ads API request, the developer token is permanently paired to the Google API Console project. If you don't use a new Google API Console project, you'll get a DEVELOPER_TOKEN_PROHIBITED error when making a request. Unfortunatly there is no other way to Unlink old Developer Token from the API Project, so for now just create a new Project as a workaround to fix this error.
Configuring authentication parameters
Google AdsService Account (Using *.json OR *.p12 key file) [OAuth]https://googleads.googleapis.com/[$ApiVersion$]Required Parameters Service Account Email Fill-in the parameter... Service Account Private Key Path (i.e. *.json OR *.p12) Fill-in the parameter... CustomerId (without dash e.g. 2125557752) Fill-in the parameter... DeveloperToken Fill-in the parameter... Optional Parameters Scope https://www.googleapis.com/auth/adwords Login CustomerId (without dash e.g. 2125557752) Linked CustomerId (without dash e.g. 2125557752) API Version v20 RetryMode RetryWhenStatusCodeMatch RetryStatusCodeList 429 RetryCountMax 5 RetryMultiplyWaitTime True Impersonate As (Google account email address) -
Select the desired endpoint, change/pass the properties values, and click on Preview Data button to make the API call.
API Source - Google AdsRead / write Google Ads data inside your app (e.g. Campaigns, Ad Groups, Keywords, Spending, Performance); perform many Google Ads operations without coding, just using easy to use high performance API Connector for Google Ads -
That's it! We are done! Just in a few clicks we configured the call to Google Ads using Google Ads Connector.
You can load the source data into your desired destination using the Upsert Destination, which supports SQL Server, PostgreSQL, and Amazon Redshift. We also offer other destinations such as CSV, Excel, Azure Table, Salesforce, and more. You can check out our SSIS PowerPack Tasks and components for more options. (*loaded in Trash Destination)
Write data to Google Ads using SSIS (Import data)
In this section we will learn how to configure and use Google Ads Connector in the API Destination to write data to Google Ads.
Video tutorial
This video covers following and more so watch carefully. After watching this video follow the steps described in this article.
- How to download SSIS PowerPack for
Google Ads integration in SSIS - How to configure connection for
Google Ads - How to write or lookup data to
Google Ads - Features about SSIS API Destination
- Using
Google Ads Connector in SSIS
Step-by-step instructions
In upper section we learned how to read data, now in this section we will learn how to configure Google Ads in the API Source to POST data to the Google Ads.
-
Read the data from the source, being any desired source component. In example we will use ZappySys Dummy Data Source component.
-
From the SSIS Toolbox drag and drop API Destination (Predefined Templates) on the Data Flow Designer surface and connect source component with it, and double click to edit it.
-
Select New Connection to create a new connection:
API Destination - Google AdsRead / write Google Ads data inside your app (e.g. Campaigns, Ad Groups, Keywords, Spending, Performance); perform many Google Ads operations without coding, just using easy to use high performance API Connector for Google Ads -
Use a preinstalled Google Ads Connector from Popular Connector List or press Search Online radio button to download Google Ads Connector. Once downloaded simply use it in the configuration:
Google Ads -
Proceed with selecting the desired Authentication Type. Then select API Base URL (in most cases default one is the right one). Finally, fill in all the required parameters and set optional parameters if needed. You may press a link Steps to Configure which will help set certain parameters. More info is available in Authentication section.
User accounts represent a developer, administrator, or any other person who interacts with Google APIs and services. User accounts are managed as Google Accounts, either with Google Workspace or Cloud Identity. They can also be user accounts that are managed by a third-party identity provider and federated with Workforce Identity Federation. [API reference]
Steps how to get and use Google Ads credentials
Follow these steps on how to create Client Credentials (User Account principle) to authenticate and access Google Ads API in SSIS package or ODBC data source:
WARNING: If you are planning to automate processes, we recommend that you use a Service Account authentication method. In case, you still need to use User Account, then make sure you use a system/generic account (e.g.automation@my-company.com
). When you use a personal account which is tied to a specific employee profile and that employee leaves the company, the token may become invalid and any automated processes using that token will start to fail.Manager Account Setup - Obtain Developer Token
To access Google Ads API (your data or someone else data) you must perform the following steps (high level). Detailed steps listed in the next sections.
- Create a Google Ads Manager account (formally known as MCC).
- Apply for Production data access (Upgrade Developer Token access Level to Basic).
- Link manager account with Google Ads Account.
- Create a new Project and obtain Client Id and Client Secret
Step-1: Create a Google Ads Manager account (formally known as MCC)
Very first step to access Google Ads API for your own account or someone else account, you will need something called Google Manager Account (formally known as MCC). It will look like a Normal Google Ads Account with some difference so dont get confused if you see similar interface as Ads account.
Click here to see detailed instructions on how to create a manager account. Once you created a manager account, you can login or switch between Ads account and Manager account like below. You can identify manager account using "Manager" word next to the account id when you click Profile dropdown.Step-2: Obtain Developer Token
Once you have created and logged in to your Google Ads Manager Account (formally known as MCC) we are ready for the next step which is obtain Developer Token. To access Google Ads API you need to pass developer token in each API call. By default Developer Token is only allowed to access Sandbox (Test) account. If you like to access Production data (Live Ads Account) then you must apply for Basic Access by clicking link under Access Level (See next section for information).
Here is how to can obtain your Developer Token.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Admin icon
- Click on API Center (This option will be missing if you are logged in to Regular Ads account as Client and not using Manager Account (MMC)
- Expand Access Level, Click Apply for Basic Access if it says "Test". By default Developer Token is created with Test Account access only. To access Production Ads account you must apply for higher access level. Must be Basic or Standard (not Test). After click the link you will see form with few questions, please fill out that and submit the form. Apploval process may take 3-5 days (or longer in some cases if you did not provide enough information).
- If your token is already approved for the basic access then copy the token and paste on the Google Ads Connector - Connection UI (For Developer Token property)
Link Manager Account to Google Ads Account
After you have manager account ready, next step is to link manager account with Google Ads Account. You have to send invitation from Manager account to access Google Ads account (it can be your own account or someone else). Here is how to send invite to link Google Ads account.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Accounts icon > Sub-account settings > Send Link Request
- Click on Add Sign (+) and select + Link existing account option
- When prompted enter Account Id(s) you like to link with this Manager Account.
- Click Send Request. You can find Ad Account Id usually at the Top-Right corner after you login to the Google Ads account.
- Now ask Google Ads Account owner to check email. Click Accept Invitation link in the email (If prompted login as Google Ads Account owner).
-OR-
Another way to see Invitation, Login to Google Ads account (Or Switch from the Top-Right corner by clicking Profile icon). Go to Admin icon > Access and security > Managers Tab. Find the pending invitation and click ACCEPT. - That's it. Now your Manager account is linked to the Google Ads account
Obtain ClientId and ClientSecret
Step-1: Create project
This step is optional, if you already have a project in Google Cloud and can use it. However, if you don't, proceed with these simple steps to create one:
-
First of all, go to Google API Console.
-
Then click Select a project button and then click NEW PROJECT button:
-
Name your project and click CREATE button:
-
Wait until the project is created:
- Done! Let's proceed to the next step.
Step-2: Enable Google Ads API
In this step we will enable Google Ads API:
-
Select your project on the top bar:
-
Then click the "hamburger" icon on the top left and access APIs & Services:
-
Now let's enable several APIs by clicking ENABLE APIS AND SERVICES button:
-
In the search bar search for
Ads
and then locate and select Google Ads API: -
Enable Google Ads API:
- Done! Let's proceed to the next step.
Step-3: Create OAuth application
-
First of all, click the "hamburger" icon on the top left and then hit VIEW ALL PRODUCTS:
-
Then access Google Auth Platform to start creating an OAuth application:
-
Start by pressing GET STARTED button:
-
Next, continue by filling in App name and User support email fields:
-
Choose Internal option, if it's enabled, otherwise select External:
-
Optional step if you used
Internal
option in the previous step. Nevertheless, if you had to useExternal
option, then click ADD USERS to add a user: -
Then add your contact Email address:
-
Finally, check the checkbox and click CREATE button:
- Done! Let's create Client Credentials in the next step.
Step-4: Create Client Credentials
-
In Google Auth Platform, select Clients menu item and click CREATE CLIENT button:
-
Choose
Desktop app
as Application type and name your credentials: -
Continue by opening the created credentials:
-
Finally, copy Client ID and Client secret for the later step:
- Done! We have all the data needed for authentication, let's proceed to the last step!
Step-5: Configure connection
-
Now go to SSIS package or ODBC data source and use previously copied values in User Account authentication configuration:
- In the ClientId field paste the Client ID value.
- In the ClientSecret field paste the Client secret value.
- In the DeveloperToken field paste the Developer Token value.
-
Press Generate Token button to generate Access and Refresh Tokens.
-
Finally, click Test Connection to confirm the connection is working.
- Done! Now you are ready to use Google Ads Connector!
Configuring authentication parameters
Google AdsUser Account [OAuth]https://googleads.googleapis.com/[$ApiVersion$]Required Parameters UseCustomApp Fill-in the parameter... CustomerId (without dash e.g. 2125557752) Fill-in the parameter... DeveloperToken Fill-in the parameter... Optional Parameters ClientId ClientSecret Scope https://www.googleapis.com/auth/adwords Login CustomerId (without dash e.g. 2125557752) Linked CustomerId (without dash e.g. 2125557752) API Version v20 RetryMode RetryWhenStatusCodeMatch RetryStatusCodeList 429 RetryCountMax 5 RetryMultiplyWaitTime True Redirect URL (Only for Web App) Service accounts are accounts that do not represent a human user. They provide a way to manage authentication and authorization when a human is not directly involved, such as when an application needs to access Google Cloud resources. Service accounts are managed by IAM. [API reference]
Steps how to get and use Google Ads credentials
To access Google Ads API (your data or someone else data) you must perform the following steps (high level). Detailed steps listed in the next sections.
- Create a Manager account.
- Apply for Production data access (Upgrade Developer Token access Level to Basic).
- Link manager account with Google Ads Account.
- Inside Manager account apply for Basic API Access level so you can use Developer Token to access Live data (Production Ads account). Without Basic access level Developer Token can be only used for Test / Sandbox Ads account.
- Create a new Project and obtain Client Id and Client Secret
Manager Account Setup - Obtain Developer Token
To access Google Ads API (your data or someone else data) you must perform the following steps (high level). Detailed steps listed in the next sections.
- Create a Google Ads Manager account (formally known as MCC).
- Apply for Production data access (Upgrade Developer Token access Level to Basic).
- Link manager account with Google Ads Account.
- Create a new Project and obtain Service Account details
Step-1: Create a Google Ads Manager account (formally known as MCC)
Very first step to access Google Ads API for your own account or someone else account, you will need something called Google Manager Account (formally known as MCC). It will look like a Normal Google Ads Account with some difference so dont get confused if you see similar interface as Ads account.
Click here to see detailed instructions on how to create a manager account. Once you created a manager account, you can login or switch between Ads account and Manager account like below. You can identify manager account using "Manager" word next to the account id when you click Profile dropdown.Step-2: Obtain Developer Token
Once you have created and logged in to your Google Ads Manager Account (formally known as MCC) we are ready for the next step which is obtain Developer Token. To access Google Ads API you need to pass developer token in each API call. By default Developer Token is only allowed to access Sandbox (Test) account. If you like to access Production data (Live Ads Account) then you must apply for Basic Access by clicking link under Access Level (See next section for information).
Here is how to can obtain your Developer Token.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Admin icon
- Click on API Center (This option will be missing if you are logged in to Regular Ads account as Client and not using Manager Account (MMC)
- Expand Access Level, Click Apply for Basic Access if it says "Test". By default Developer Token is created with Test Account access only. To access Production Ads account you must apply for higher access level. Must be Basic or Standard (not Test). After click the link you will see form with few questions, please fill out that and submit the form. Apploval process may take 3-5 days (or longer in some cases if you did not provide enough information).
- If your token is already approved for the basic access then copy the token and paste on the Google Ads Connector - Connection UI (For Developer Token property)
Link Manager Account to Google Ads Account
After you have manager account ready, next step is to link manager account with Google Ads Account. You have to send invitation from Manager account to access Google Ads account (it can be your own account or someone else). Here is how to send invite to link Google Ads account.- Log in as Manager account (Or change Top-Right Profile > Choose Manager account ID
- Click on Accounts icon > Sub-account settings > Send Link Request
- Click on Add Sign (+) and select + Link existing account option
- When prompted enter Account Id(s) you like to link with this Manager Account.
- Click Send Request. You can find Ad Account Id usually at the Top-Right corner after you login to the Google Ads account.
- Now ask Google Ads Account owner to check email. Click Accept Invitation link in the email (If prompted login as Google Ads Account owner).
-OR-
Another way to see Invitation, Login to Google Ads account (Or Switch from the Top-Right corner by clicking Profile icon). Go to Admin icon > Access and security > Managers Tab. Find the pending invitation and click ACCEPT. - That's it. Now your Manager account is linked to the Google Ads account
Obtain ClientId and ClientSecret
Step-1: Create project
This step is optional, if you already have a project in Google Cloud and can use it. However, if you don't, proceed with these simple steps to create one:
-
First of all, go to Google API Console.
-
Then click Select a project button and then click NEW PROJECT button:
-
Name your project and click CREATE button:
-
Wait until the project is created:
- Done! Let's proceed to the next step.
Step-2: Enable Google Ads API
In this step we will enable Google Ads API:
-
Select your project on the top bar:
-
Then click the "hamburger" icon on the top left and access APIs & Services:
-
Now let's enable several APIs by clicking ENABLE APIS AND SERVICES button:
-
In the search bar search for
ads
and then locate and select Google Ads API: -
Enable Google Ads API:
- Done! Let's proceed to the next step.
Step-3: Create Service Account
Use the steps below to create a Service Account in Google Cloud:
-
First of all, go to IAM & Admin in Google Cloud console:
-
Once you do that, click Service Accounts on the left side and click CREATE SERVICE ACCOUNT button:
-
Then name your service account and click CREATE AND CONTINUE button:
-
Continue by clicking Select a role dropdown and start granting service account Project Viewer roles:
-
Find Project group and select Viewer role:
-
Finish adding roles by clicking CONTINUE button:
You can always add or modify permissions later in IAM & Admin. -
Finally, in the last step, just click button DONE:
-
Done! We are ready to add a Key to this service account in the next step.
Step-4: Add Key to Service Account
We are ready to add a Key (JSON or P12 key file) to the created Service Account:
-
In Service Accounts open newly created service account:
-
Next, copy email address of your service account for the later step:
-
Continue by selecting KEYS tab, then press ADD KEY dropdown, and click Create new key menu item:
-
Finally, select JSON (Engine v19+) or P12 option and hit CREATE button:
- Key file downloads into your machine. We have all the data needed for authentication, let's proceed to the last step!
Step-5: Give Permissions to Service Account
Now it's time to grant permission to Service Account we just created:
- Login to https://ads.google.com/aw/settings/account with Google Ads account credentials (If propmpted choose your Ads account).
-
Go to Admin section, Access and security, Click on Users tab.
- Click on Add Icon (+) and enter service account email address which you like to use for data access and choose permissions.
- That's it! Let's proceed to the configuration!
Step-6: Configure connection
-
Now go to SSIS package or ODBC data source and configure these fields in Service Account authentication configuration:
- In the Service Account Email field paste the service account Email address value you copied in the previous step.
- In the Service Account Private Key Path (i.e. *.json OR *.p12) field use downloaded key file path.
- Done! Now you are ready to use Google Ads Connector!
Each Google API Console project can be associated with the developer token from only one manager account. Once you make a Google Ads API request, the developer token is permanently paired to the Google API Console project. If you don't use a new Google API Console project, you'll get a DEVELOPER_TOKEN_PROHIBITED error when making a request. Unfortunatly there is no other way to Unlink old Developer Token from the API Project, so for now just create a new Project as a workaround to fix this error.
Configuring authentication parameters
Google AdsService Account (Using *.json OR *.p12 key file) [OAuth]https://googleads.googleapis.com/[$ApiVersion$]Required Parameters Service Account Email Fill-in the parameter... Service Account Private Key Path (i.e. *.json OR *.p12) Fill-in the parameter... CustomerId (without dash e.g. 2125557752) Fill-in the parameter... DeveloperToken Fill-in the parameter... Optional Parameters Scope https://www.googleapis.com/auth/adwords Login CustomerId (without dash e.g. 2125557752) Linked CustomerId (without dash e.g. 2125557752) API Version v20 RetryMode RetryWhenStatusCodeMatch RetryStatusCodeList 429 RetryCountMax 5 RetryMultiplyWaitTime True Impersonate As (Google account email address) -
Select the desired endpoint, change/pass the properties values, and go to the Mappings tab to map the columns.
API Destination - Google AdsRead / write Google Ads data inside your app (e.g. Campaigns, Ad Groups, Keywords, Spending, Performance); perform many Google Ads operations without coding, just using easy to use high performance API Connector for Google Ads -
Finally, map the desired columns:
API Destination - Google AdsRead / write Google Ads data inside your app (e.g. Campaigns, Ad Groups, Keywords, Spending, Performance); perform many Google Ads operations without coding, just using easy to use high performance API Connector for Google Ads -
That's it; we successfully configured the POST API Call. In a few clicks we configured the Google Ads API call using ZappySys Google Ads Connector
Load Google Ads data into SQL Server using Upsert Destination (Insert or Update)
Once you configured the data source, you can load Google Ads data into SQL Server using Upsert Destination.
Upsert Destination can merge or synchronize source data with the target table.
It supports Microsoft SQL Server, PostgreSQL, and Redshift databases as targets.
Upsert Destination also supports very fast bulk upsert
operation along with bulk delete
.
Upsert operation
- a database operation which performs INSERT
or UPDATE
SQL commands
based on record's existence condition in the target table.
It
Upsert Destination supports INSERT
, UPDATE
, and DELETE
operations,
so it is similar to SQL Server's MERGE
command, except it can be used directly in SSIS package.
-
From the SSIS Toolbox drag-and-drop Upsert Destination component onto the Data Flow designer background.
-
Connect your SSIS source component to Upsert Destination.
-
Double-click on Upsert Destination component to open configuration window.
-
Start by selecting the Action from the list.
-
Next, select the desired target connection or create one by clicking <New [provider] Connection> menu item from the Target Connection dropdown.
-
Then select a table from the Target Table list or click New button to create a new table based on the source columns.
-
Continue by checking Insert and Update options according to your scenario (e.g. if Update option is unchecked, no updates will be made).
-
Finally, click Map All button to map all columns and then select the Key columns to match the columns on:
-
Click OK to save the configuration.
-
Run the package and Google Ads data will be merged with the target table in SQL Server, PostgreSQL, or Redshift:
-
Done!
Deploy and schedule SSIS package
After you are done creating SSIS package, most likely, you want to deploy it to SQL Server Catalog and run it periodically. Just follow the instructions in this article:
Running SSIS package in Azure Data Factory (ADF)
To use SSIS PowerPack in ADF, you must first prepare Azure-SSIS Integration Runtime. Follow this link for detailed instructions:
Actions supported by Google Ads Connector
Google Ads Connector supports following actions for REST API integration:
Get Campaign Keywords
Description
Get Campaign Keywords (For all AdGroup).
Parameters
You can provide the following parameters to this action:
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
CampaignId
-
CampaignName
-
CampaignResourceName
-
CampaignStatus
-
AdGroupId
-
AdGroupName
-
AdGroupResourceName
-
AdGroupStatus
-
CriterionId
-
CriterionStatus
-
CriterionApprovalStatus
-
CriterionResourceName
-
CriterionFinalUrls
-
CriterionFinalMobileUrls
-
KeywordText
-
KeywordMatchType
-
KeywordCpcBid
-
KeywordCpcBidMicros
-
KeywordCpmBid
-
KeywordCpmBidMicros
-
KeywordResourceName
Visit documentation for more information.
Get Campaigns
Description
Get Google Ads campaign data.
Parameters
You can provide the following parameters to this action:
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Id
-
Name
-
Status
-
StartDate
-
EndDate
-
CampaignBudgetAmount
-
CampaignBudgetAmountMicros
-
TargetCpa
-
TargetCpaMicros
-
MaximizeConversionsTargetCpa
-
MaximizeConversionsTargetCpaMicros
-
KeywordMatchType
-
ResourceName
-
BiddingStrategyType
-
FinalUrlSuffix
-
AdServingOptimizationStatus
-
AdvertisingChannelType
-
NetworkSettingsTargetGoogleSearch
-
NetworkSettingsTargetSearchNetwork
-
NetworkSettingsTargetContentNetwork
-
NetworkSettingsTargetPartnerSearchNetwork
-
NetworkSettingsTargetYoutube
-
NetworkSettingsTargetGoogleTvNetwork
-
ExperimentType
-
ServingStatus
-
DynamicSearchAdsSettingDomainName
-
DynamicSearchAdsSettingLanguageCode
-
DynamicSearchAdsSettingUseSuppliedUrlsOnly
-
TargetingSettingTargetRestrictions
-
GeoTargetTypeSettingPositiveGeoTargetType
-
GeoTargetTypeSettingNegativeGeoTargetType
-
PaymentMode
-
BaseCampaign
-
Labels
-
BiddingStrategySystemStatus
-
PrimaryStatus
-
PrimaryStatusReasons
-
CampaignBudget
-
ManualCpcEnhancedCpcEnabled
-
CampaignGroup
-
AdvertisingChannelSubType
-
TargetSpend
-
TargetSpendMicros
-
FrequencyCaps
-
VideoBrandSafetySuitability
-
AssetAutomationSettings
-
TargetImpressionShareLocation
-
TargetImpressionShareLocationFraction
-
TargetImpressionShareLocationFractionMicros
-
TargetImpressionShareCpcBidCeiling
-
TargetImpressionShareCpcBidCeilingMicros
-
UrlExpansionOptOut
-
AudienceSettingUseAudienceGrouped
-
PerformanceMaxUpgradePerformanceMaxCampaign
-
PerformanceMaxUpgradeStatus
-
OptimizationScore
Visit documentation for more information.
Get Customers
Description
Get Google Ads customer data.
Parameters
You can provide the following parameters to this action:
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Id
-
DescriptiveName
-
Status
-
Manager
-
TestAccount
-
ResourceName
-
CallReportingSettingCallReportingEnabled
-
CallReportingSettingCallConversionReportingEnabled
-
CallReportingSettingCallConversionAction
-
ConversionTrackingSettingConversionTrackingId
-
ConversionTrackingSettingAcceptedCustomerDataTerms
-
ConversionTrackingSettingConversionTrackingStatus
-
ConversionTrackingSettingGoogleAdsConversionCustomer
-
RemarketingSettingGoogleGlobalSiteTag
-
PayPerConversionEligibilityFailureReasons
-
CurrencyCode
-
TimeZone
-
TrackingUrlTemplate
-
AutoTaggingEnabled
-
HasPartnersBadge
-
OptimizationScore
-
OptimizationScoreWeight
-
LocationAssetAutoMigrationDone
-
ImageAssetAutoMigrationDone
-
LocationAssetAutoMigrationDoneDateTime
-
ImageAssetAutoMigrationDoneDateTime
Visit documentation for more information.
Get Linked Customers (For Manager Account)
Description
Get Linked Customers (Must be using Manager Account).
Parameters
You can provide the following parameters to this action:
-
N/A
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Id
-
ResourceNames
Visit documentation for more information.
Get Report: Campaign Performance (By Date)
Description
Get campaign performance data by date. If you like to customize this report then use get_query_result endpoint.
Parameters
You can provide the following parameters to this action:
-
Report Start Date (yyyy-MM-dd)
-
Report End Date (yyyy-MM-dd)
-
Campaign Id (Default: All)
-
Campaign Status (Default: All)
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Date
-
Year
-
Month
-
Day
-
Week
-
Quarter
-
DayOfWeek
-
CampaignId
-
CampaignName
-
Clicks
-
Conversions
-
Cost
-
CostMicros
-
CostPerConversion
-
CostPerConversionMicros
-
Impressions
-
InteractionRate
-
Interactions
-
AveragePageViews
-
BounceRate
-
SearchAbsoluteTopImpressionShare
-
SearchBudgetLostAbsoluteTopImpressionShare
-
SearchBudgetLostImpressionShare
-
SearchBudgetLostTopImpressionShare
-
SearchClickShare
-
SearchExactMatchImpressionShare
-
SearchImpressionShare
-
SearchRankLostAbsoluteTopImpressionShare
-
SearchRankLostImpressionShare
-
SearchRankLostTopImpressionShare
-
SearchTopImpressionShare
-
TopImpressionPercentage
-
VideoViews
-
ViewThroughConversions
-
Ctr
-
Engagements
-
AbsoluteTopImpressionPercentage
-
ActiveViewImpressions
-
AllConversions
-
AverageCost
-
AverageCostMicro
-
AverageCpc
-
AverageCpcMicro
-
AverageCpm
-
AverageCpmMicro
-
AverageCpv
-
AverageCpvMicro
-
AverageCpe
-
AverageCpeMicro
-
InvalidClicks
-
CostPerAllConversions
-
CostPerAllConversionsMicro
-
ContentImpressionShare
-
ContentBudgetLostImpressionShare
-
EngagementRate
-
VideoviewRate
-
VideoQuartileP75Rate
-
VideoQuartileP50Rate
-
VideoQuartileP25Rate
-
VideoQuartileP100rate
-
ActiveViewCpm
-
ActiveViewCpmMicro
-
ActiveViewCtr
-
UniqueUsers
-
AverageImpressionFrequencyPerUser
Visit documentation for more information.
Get Report: Campaign Performance (By Year and Month)
Description
Get campaign performance data by year and month. If you like to customize this report then use get_query_result endpoint.
Parameters
You can provide the following parameters to this action:
-
Report Start Date (yyyy-MM-dd)
-
Report End Date (yyyy-MM-dd)
-
Campaign Id (Default: All)
-
Campaign Status (Default: All)
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Year
-
Month
-
Quarter
-
CampaignId
-
CampaignName
-
Clicks
-
Conversions
-
Cost
-
CostMicros
-
CostPerConversion
-
CostPerConversionMicros
-
Impressions
-
InteractionRate
-
Interactions
-
AveragePageViews
-
BounceRate
-
SearchAbsoluteTopImpressionShare
-
SearchBudgetLostAbsoluteTopImpressionShare
-
SearchBudgetLostImpressionShare
-
SearchBudgetLostTopImpressionShare
-
SearchClickShare
-
SearchExactMatchImpressionShare
-
SearchImpressionShare
-
SearchRankLostAbsoluteTopImpressionShare
-
SearchRankLostImpressionShare
-
SearchRankLostTopImpressionShare
-
SearchTopImpressionShare
-
TopImpressionPercentage
-
VideoViews
-
ViewThroughConversions
-
Ctr
-
Engagements
-
AbsoluteTopImpressionPercentage
-
ActiveViewImpressions
-
AllConversions
-
AverageCost
-
AverageCostMicro
-
AverageCpc
-
AverageCpcMicro
-
AverageCpm
-
AverageCpmMicro
-
AverageCpv
-
AverageCpvMicro
-
AverageCpe
-
AverageCpeMicro
-
InvalidClicks
-
CostPerAllConversions
-
CostPerAllConversionsMicro
-
ContentImpressionShare
-
ContentBudgetLostImpressionShare
-
EngagementRate
-
VideoviewRate
-
VideoQuartileP75Rate
-
VideoQuartileP50Rate
-
VideoQuartileP25Rate
-
VideoQuartileP100rate
-
ActiveViewCpm
-
ActiveViewCpmMicro
-
ActiveViewCtr
Visit documentation for more information.
Get Resource Attributes (For GAQL)
Description
Get attributes you can query (for all or selected resource) using GAQL.
Parameters
You can provide the following parameters to this action:
-
Resource
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Name
-
Category
-
DataType
-
ResourceName
-
NameForResponse
Visit documentation for more information.
Get Resource Data (Query Attributes, Segments, Metrics)
Description
Get Google Ads resource data without supplying GAQL, easy to use Query Builder to fetch data from any object by its Resource name.
Parameters
You can provide the following parameters to this action:
-
Filter
-
Resource
-
Attributes (Leave blank to select all)
-
Segments (Group By)
-
Metrics (Aggregate Fields)
-
Where Clause
-
OrderBy Clause
-
Limit Clause (i.e. Max Rows) - Blank means all rows
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
<<[Dynamic Column]|~|true|~|proper|~|.|~|_-.@|~|1,FUN_PROPERCASE>>
-
<<[Dynamic Column]|~|true|~|proper|~|.|~|_-.@|~|1|~|_micros$|~|,FUN_PROPERCASE>>
Visit documentation for more information.
Get Resource Metrics (For GAQL)
Description
Get metrics you can query (for all or selected resource) using GAQL, Numeric fields which can be aggregated (e.g. clicks, impressions).
Parameters
You can provide the following parameters to this action:
-
Resource
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Name
-
ResourceName
Visit documentation for more information.
Get Resource Segments (For GAQL)
Description
Get segments (Group By Fields) for all or selected resource using GAQL.
Parameters
You can provide the following parameters to this action:
-
Resource
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Name
-
ResourceName
Visit documentation for more information.
Get Resources (For GAQL)
Description
Get resources you can query for GAQL.
Parameters
You can provide the following parameters to this action:
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
Name
-
ResourceName
Visit documentation for more information.
Query Google Ads data (Using GAQL - Google Ads Query Language)
Description
Get Google Ads report data using GAQL (Google Ads Query Language) SQL query. Use Query builder from this link to select fields, segments, and metrics https://developers.google.com/google-ads/api/fields/v18/overview_query_builder (Click on Resource type you like to query) for SELECT, FROM and ORDER BY.
Parameters
You can provide the following parameters to this action:
-
Enter Query (i.e. GAQL sql)
-
Filter
-
CustomerId (without dash e.g. 2125557752)
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
N/A
Visit documentation for more information.
Make Generic API Request
Description
This is generic endpoint. Use this endpoint when some actions are not implemented by connector. Just enter partial URL (Required), Body, Method, Header etc. Most parameters are optional except URL.
Parameters
You can provide the following parameters to this action:
-
Url
-
Body
-
IsMultiPart
-
Filter
-
Headers
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
N/A
Visit documentation for more information.
Make Generic API Request (Bulk Write)
Description
This is a generic endpoint for bulk write purpose. Use this endpoint when some actions are not implemented by connector. Just enter partial URL (Required), Body, Method, Header etc. Most parameters are optional except URL.
Parameters
You can provide the following parameters to this action:
-
Url
-
IsMultiPart
-
Filter
-
Headers
Input Fields
You can provide the following fields to this action:
-
N/A
Output Fields
The following fields are returned after calling this action:
-
N/A
Visit documentation for more information.
Conclusion
In this article we showed you how to connect to Google Ads in SSIS and integrate data without any coding, saving you time and effort.
We encourage you to download Google Ads Connector for SSIS and see how easy it is to use it for yourself or your team.
If you have any questions, feel free to contact ZappySys support team. You can also open a live chat immediately by clicking on the chat icon below.
Download Google Ads Connector for SSIS Documentation