Skip to content

Update the generator to es6 imports, run generator #736

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 23 additions & 25 deletions apis/acceleratedmobilepageurl/v1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,8 @@

/* jshint maxlen: false */

'use strict';

var createAPIRequest = require('../../lib/apirequest');
var utils = require('../../lib/utils');
const createAPIRequest = require('../../lib/apirequest');
const utils = require('../../lib/utils');

/**
* Accelerated Mobile Pages (AMP) URL API
Expand All @@ -28,8 +26,8 @@ var utils = require('../../lib/utils');

*
* @example
* var google = require('googleapis');
* var acceleratedmobilepageurl = google.acceleratedmobilepageurl('v1');
* const google = require('googleapis');
* const acceleratedmobilepageurl = google.acceleratedmobilepageurl('v1');
*
* @namespace acceleratedmobilepageurl
* @type {Function}
Expand All @@ -38,7 +36,7 @@ var utils = require('../../lib/utils');
* @param {object=} options Options for Acceleratedmobilepageurl
*/
function Acceleratedmobilepageurl(options) { // eslint-disable-line
var self = this;
const self = this;
self._options = options || {};

self.ampUrls = {
Expand All @@ -64,7 +62,7 @@ function Acceleratedmobilepageurl(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://acceleratedmobilepageurl.googleapis.com/v1/ampUrls:batchGet',
method: 'POST'
Expand All @@ -81,6 +79,23 @@ function Acceleratedmobilepageurl(options) { // eslint-disable-line
};
}

/**
* @typedef AmpUrl
* @memberOf! acceleratedmobilepageurl(v1)
* @type object
* @property {string} cdnAmpUrl The [AMP Cache URL](/amp/cache/overview#amp-cache-url-format) pointing to
the cached document in the Google AMP Cache.
* @property {string} originalUrl The original non-AMP URL.
* @property {string} ampUrl The AMP URL pointing to the publisher's web server.
*/
/**
* @typedef AmpUrlError
* @memberOf! acceleratedmobilepageurl(v1)
* @type object
* @property {string} errorCode The error code of an API call.
* @property {string} originalUrl The original non-AMP URL.
* @property {string} errorMessage An optional descriptive error message.
*/
/**
* @typedef BatchGetAmpUrlsRequest
* @memberOf! acceleratedmobilepageurl(v1)
Expand All @@ -100,21 +115,4 @@ If BatchAmpUrlsRequest contains duplicate URLs, AmpUrl is generated
only once.
* @property {acceleratedmobilepageurl(v1).AmpUrlError[]} urlErrors The errors for requested URLs that have no AMP URL.
*/
/**
* @typedef AmpUrl
* @memberOf! acceleratedmobilepageurl(v1)
* @type object
* @property {string} originalUrl The original non-AMP URL.
* @property {string} ampUrl The AMP URL pointing to the publisher's web server.
* @property {string} cdnAmpUrl The [AMP Cache URL](/amp/cache/overview#amp-cache-url-format) pointing to
the cached document in the Google AMP Cache.
*/
/**
* @typedef AmpUrlError
* @memberOf! acceleratedmobilepageurl(v1)
* @type object
* @property {string} errorMessage An optional descriptive error message.
* @property {string} errorCode The error code of an API call.
* @property {string} originalUrl The original non-AMP URL.
*/
export = Acceleratedmobilepageurl;
26 changes: 12 additions & 14 deletions apis/adexchangebuyer/v1.2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,17 @@

/* jshint maxlen: false */

'use strict';

var createAPIRequest = require('../../lib/apirequest');
var utils = require('../../lib/utils');
const createAPIRequest = require('../../lib/apirequest');
const utils = require('../../lib/utils');

/**
* Ad Exchange Buyer API
*
* Accesses your bidding-account information, submits creatives for validation, finds available direct deals, and retrieves performance reports.
*
* @example
* var google = require('googleapis');
* var adexchangebuyer = google.adexchangebuyer('v1.2');
* const google = require('googleapis');
* const adexchangebuyer = google.adexchangebuyer('v1.2');
*
* @namespace adexchangebuyer
* @type {Function}
Expand All @@ -37,7 +35,7 @@ var utils = require('../../lib/utils');
* @param {object=} options Options for Adexchangebuyer
*/
function Adexchangebuyer(options) { // eslint-disable-line
var self = this;
const self = this;
self._options = options || {};

self.accounts = {
Expand All @@ -63,7 +61,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/accounts/{id}',
method: 'GET'
Expand Down Expand Up @@ -97,7 +95,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/accounts',
method: 'GET'
Expand Down Expand Up @@ -133,7 +131,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/accounts/{id}',
method: 'PATCH'
Expand Down Expand Up @@ -169,7 +167,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/accounts/{id}',
method: 'PUT'
Expand Down Expand Up @@ -209,7 +207,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/creatives/{accountId}/{buyerCreativeId}',
method: 'GET'
Expand Down Expand Up @@ -244,7 +242,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/creatives',
method: 'POST'
Expand Down Expand Up @@ -281,7 +279,7 @@ function Adexchangebuyer(options) { // eslint-disable-line
}
options || (options = {});

var parameters = {
const parameters = {
options: utils.extend({
url: 'https://www.googleapis.com/adexchangebuyer/v1.2/creatives',
method: 'GET'
Expand Down
Loading