Socket
Socket
Sign inDemoInstall

@honkandgo/googleads

Package Overview
Dependencies
7
Maintainers
5
Versions
20
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @honkandgo/googleads

Access Google Ads REST API (json based) from Node.js.


Version published
Weekly downloads
12
decreased by-7.69%
Maintainers
5
Install size
529 kB
Created
Weekly downloads
 

Readme

Source

googleads

Access Google Ads REST API (json based) from Node.js.

Install

npm -i @honkandgo/googleads

Use

import GoogleAdsClient from '@honkandgo/googleads'

const googleads = new GoogleAdsClient({
	clientId: <GOOGLE_CLIENT_ID>
	clientSecret: <GOOGLE_CLIENT_SECRET>
	developerToken: <GOOGLE_ADS_DEVELOPER_TOKEN>
	refreshToken: <REFRESH_TOKEN> (optional)
})

const { resourceNames } = await googleads.listAccessibleCustomers()

Passing refreshToken in constructor is optional. You can also pass refreshToken as a parameter to any method

const refreshToken = ...
const customerId = ...
const query = "SELECT campaign.id, campaign.name FROM campaign WHERE campaign.status IN ('ENABLED', 'PAUSED')"
const campaigns = await googleads.search(customerId, { query }, refreshToken)

FAQs

Last updated on 01 Nov 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc