// Before running the sample:
// - Enable the API at:
// https://console.developers.google.com/apis/api/content.googleapis.com
// - Login into gcloud by running:
// `$ gcloud auth application-default login`
// - Install the npm module by running:
// `$ npm install googleapis`
const {google} = require('googleapis');
const content = google.content('v2.1');
async function main() {
const auth = new google.auth.GoogleAuth({
// Scopes can be specified either as an array or as a single, space-delimited string.
scopes: ['https://www.googleapis.com/auth/content'],
});
// Acquire an auth client, and bind it to all future calls
const authClient = await auth.getClient();
google.options({auth: authClient});
// Do the magic
const res = await content.csses.updatelabels({
// Required. The ID of the updated CSS domain.
cssDomainId: 'placeholder-value',
// Required. The CSS group ID of the updated CSS domain.
cssGroupId: 'placeholder-value',
// Request body metadata
requestBody: {
// request body parameters
// {
// "labelIds": []
// }
},
});
console.log(res.data);
// Example response
// {
// "cssDomainId": "my_cssDomainId",
// "cssGroupId": "my_cssGroupId",
// "displayName": "my_displayName",
// "fullName": "my_fullName",
// "homepageUri": "my_homepageUri",
// "labelIds": []
// }
}
main().catch(e => {
console.error(e);
throw e;
});
// Before running the sample:
// - Enable the API at:
// https://console.developers.google.com/apis/api/content.googleapis.com
// - Login into gcloud by running:
// `$ gcloud auth application-default login`
// - Install the npm module by running:
// `$ npm install googleapis`
const {google} = require('googleapis');
const content = google.content('v2.1');
async function main() {
const auth = new google.auth.GoogleAuth({
// Scopes can be specified either as an array or as a single, space-delimited string.
scopes: ['https://www.googleapis.com/auth/content'],
});
// Acquire an auth client, and bind it to all future calls
const authClient = await auth.getClient();
google.options({auth: authClient});
// Do the magic
const res = await content.csses.get({
// Required. The ID of the CSS domain to return.
cssDomainId: 'placeholder-value',
// Required. The ID of the managing account. If this parameter is not the same as [cssDomainId](#cssDomainId), then this ID must be a CSS group ID and `cssDomainId` must be the ID of a CSS domain affiliated with this group.
cssGroupId: 'placeholder-value',
});
console.log(res.data);
// Example response
// {
// "cssDomainId": "my_cssDomainId",
// "cssGroupId": "my_cssGroupId",
// "displayName": "my_displayName",
// "fullName": "my_fullName",
// "homepageUri": "my_homepageUri",
// "labelIds": []
// }
}
main().catch(e => {
console.error(e);
throw e;
});
const {google} = require('googleapis');
const content = google.content('v2.1');
const {google} = require('googleapis');
const content = google.content('v2');
// Before running the sample:
// - Enable the API at:
// https://console.developers.google.com/apis/api/content.googleapis.com
// - Login into gcloud by running:
// `$ gcloud auth application-default login`
// - Install the npm module by running:
// `$ npm install googleapis`
const {google} = require('googleapis');
const content = google.content('v2.1');
async function main() {
const auth = new google.auth.GoogleAuth({
// Scopes can be specified either as an array or as a single, space-delimited string.
scopes: ['https://www.googleapis.com/auth/content'],
});
// Acquire an auth client, and bind it to all future calls
const authClient = await auth.getClient();
google.options({auth: authClient});
// Do the magic
const res = await content.regionalinventory.custombatch({
// Request body metadata
requestBody: {
// request body parameters
// {
// "entries": []
// }
},
});
console.log(res.data);
// Example response
// {
// "entries": [],
// "kind": "my_kind"
// }
}
main().catch(e => {
console.error(e);
throw e;
});