
Product
Introducing Socket Fix for Safe, Automated Dependency Upgrades
Automatically fix and test dependency updates with socket fix—a new CLI tool that turns CVE alerts into safe, automated upgrades.
google-api-javascript-client
Advanced tools
A NPM package for Google API JavaScript Client: https://github.com/google/google-api-javascript-client
This is a simple NPM wrapper around the Google API Javascript Client, which is not published to NPM. This package also includes the TypeScript definitions for the client.
npm install google-api-javascript-client
import { gapi, load } from "google-api-javascript-client";
// Or
const { gapi, load } = require("google-api-javascript-client");
async function fn() {
// 1. Load the JavaScript client library.
await load('client')
// 2. Initialize the JavaScript client library.
await gapi.client.init({
'apiKey': 'YOUR_API_KEY',
// clientId and scope are optional if auth is not required.
'clientId': 'YOUR_WEB_CLIENT_ID.apps.googleusercontent.com',
'scope': 'profile',
})
// 3. Initialize and make the API request.
const response = await gapi.client.request({
'path': 'https://people.googleapis.com/v1/people/me?requestMask.includeField=person.names',
})
console.log(response.result);
}
MIT
FAQs
A NPM package for Google API JavaScript Client: https://github.com/google/google-api-javascript-client
The npm package google-api-javascript-client receives a total of 145 weekly downloads. As such, google-api-javascript-client popularity was classified as not popular.
We found that google-api-javascript-client demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
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.
Product
Automatically fix and test dependency updates with socket fix—a new CLI tool that turns CVE alerts into safe, automated upgrades.
Security News
CISA denies CVE funding issues amid backlash over a new CVE foundation formed by board members, raising concerns about transparency and program governance.
Product
We’re excited to announce a powerful new capability in Socket: historical data and enhanced analytics.