Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Unified Diff: generated/googleapis/lib/adexperiencereport/v1.dart

Issue 2973303002: Api-Roll 51: 2017-07-10 (Closed)
Patch Set: Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « generated/googleapis/README.md ('k') | generated/googleapis/lib/admin/directory_v1.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: generated/googleapis/lib/adexperiencereport/v1.dart
diff --git a/generated/googleapis/lib/adexperiencereport/v1.dart b/generated/googleapis/lib/adexperiencereport/v1.dart
new file mode 100644
index 0000000000000000000000000000000000000000..e3a07037b16546c0dbe58b8764196830da743e21
--- /dev/null
+++ b/generated/googleapis/lib/adexperiencereport/v1.dart
@@ -0,0 +1,289 @@
+// This is a generated file (see the discoveryapis_generator project).
+
+library googleapis.adexperiencereport.v1;
+
+import 'dart:core' as core;
+import 'dart:async' as async;
+import 'dart:convert' as convert;
+
+import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons;
+import 'package:http/http.dart' as http;
+
+export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show
+ ApiRequestError, DetailedApiRequestError;
+
+const core.String USER_AGENT = 'dart-api-client adexperiencereport/v1';
+
+/**
+ * View Ad Experience Report data, and get a list of sites that have a
+ * significant number of annoying ads.
+ */
+class AdexperiencereportApi {
+ /** Test scope for access to the Zoo service */
+ static const XapiZooScope = "https://www.googleapis.com/auth/xapi.zoo";
+
+
+ final commons.ApiRequester _requester;
+
+ SitesResourceApi get sites => new SitesResourceApi(_requester);
+ ViolatingSitesResourceApi get violatingSites => new ViolatingSitesResourceApi(_requester);
+
+ AdexperiencereportApi(http.Client client, {core.String rootUrl: "https://adexperiencereport.googleapis.com/", core.String servicePath: ""}) :
+ _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_AGENT);
+}
+
+
+class SitesResourceApi {
+ final commons.ApiRequester _requester;
+
+ SitesResourceApi(commons.ApiRequester client) :
+ _requester = client;
+
+ /**
+ * Gets a summary of the ads rating of a site.
+ *
+ * Request parameters:
+ *
+ * [name] - The required site name. It should be a site property registered in
+ * Search
+ * Console. The server will return an error of BAD_REQUEST if this field is
+ * not filled in.
+ * Value must have pattern "^sites/[^/]+$".
+ *
+ * Completes with a [SiteSummaryResponse].
+ *
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an
+ * error.
+ *
+ * If the used [http.Client] completes with an error when making a REST call,
+ * this method will complete with the same error.
+ */
+ async.Future<SiteSummaryResponse> get(core.String name) {
+ var _url = null;
+ var _queryParams = new core.Map();
+ var _uploadMedia = null;
+ var _uploadOptions = null;
+ var _downloadOptions = commons.DownloadOptions.Metadata;
+ var _body = null;
+
+ if (name == null) {
+ throw new core.ArgumentError("Parameter name is required.");
+ }
+
+ _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name');
+
+ var _response = _requester.request(_url,
+ "GET",
+ body: _body,
+ queryParams: _queryParams,
+ uploadOptions: _uploadOptions,
+ uploadMedia: _uploadMedia,
+ downloadOptions: _downloadOptions);
+ return _response.then((data) => new SiteSummaryResponse.fromJson(data));
+ }
+
+}
+
+
+class ViolatingSitesResourceApi {
+ final commons.ApiRequester _requester;
+
+ ViolatingSitesResourceApi(commons.ApiRequester client) :
+ _requester = client;
+
+ /**
+ * Lists sites with Ad Experience Report statuses of "Failing" or "Warning".
+ *
+ * Request parameters:
+ *
+ * Completes with a [ViolatingSitesResponse].
+ *
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an
+ * error.
+ *
+ * If the used [http.Client] completes with an error when making a REST call,
+ * this method will complete with the same error.
+ */
+ async.Future<ViolatingSitesResponse> list() {
+ var _url = null;
+ var _queryParams = new core.Map();
+ var _uploadMedia = null;
+ var _uploadOptions = null;
+ var _downloadOptions = commons.DownloadOptions.Metadata;
+ var _body = null;
+
+
+ _url = 'v1/violatingSites';
+
+ var _response = _requester.request(_url,
+ "GET",
+ body: _body,
+ queryParams: _queryParams,
+ uploadOptions: _uploadOptions,
+ uploadMedia: _uploadMedia,
+ downloadOptions: _downloadOptions);
+ return _response.then((data) => new ViolatingSitesResponse.fromJson(data));
+ }
+
+}
+
+
+
+/** Summary of the ads rating of a site for a specific platform. */
+class PlatformSummary {
+ /**
+ * The status of the site reviewed for the Better Ads Standards.
+ * Possible string values are:
+ * - "UNKNOWN" : Not reviewed.
+ * - "PASSING" : Passing.
+ * - "WARNING" : Warning.
+ * - "FAILING" : Failing.
+ */
+ core.String betterAdsStatus;
+ /**
+ * The status of the site reviewed for egregious ads.
+ * Possible string values are:
+ * - "UNKNOWN" : Not reviewed.
+ * - "PASSING" : Passing.
+ * - "FAILING" : Failing.
+ */
+ core.String egregiousStatus;
+ /** The date on which ad filtering begins. */
+ core.String enforcementTime;
+ /**
+ * The ad filtering status of the site.
+ * Possible string values are:
+ * - "UNKNOWN" : N/A.
+ * - "ON" : Ad filtering is on.
+ * - "OFF" : Ad filtering is off.
+ * - "PAUSED" : Ad filtering is paused.
+ * - "PENDING" : Ad filtering is pending.
+ */
+ core.String filterStatus;
+ /** The last time that the site changed status. */
+ core.String lastChangeTime;
+ /** The assigned regions for the site and platform. */
+ core.List<core.String> region;
+ /** A link that leads to a full ad experience report. */
+ core.String reportUrl;
+ /** Whether the site is currently under review. */
+ core.bool underReview;
+
+ PlatformSummary();
+
+ PlatformSummary.fromJson(core.Map _json) {
+ if (_json.containsKey("betterAdsStatus")) {
+ betterAdsStatus = _json["betterAdsStatus"];
+ }
+ if (_json.containsKey("egregiousStatus")) {
+ egregiousStatus = _json["egregiousStatus"];
+ }
+ if (_json.containsKey("enforcementTime")) {
+ enforcementTime = _json["enforcementTime"];
+ }
+ if (_json.containsKey("filterStatus")) {
+ filterStatus = _json["filterStatus"];
+ }
+ if (_json.containsKey("lastChangeTime")) {
+ lastChangeTime = _json["lastChangeTime"];
+ }
+ if (_json.containsKey("region")) {
+ region = _json["region"];
+ }
+ if (_json.containsKey("reportUrl")) {
+ reportUrl = _json["reportUrl"];
+ }
+ if (_json.containsKey("underReview")) {
+ underReview = _json["underReview"];
+ }
+ }
+
+ core.Map<core.String, core.Object> toJson() {
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>();
+ if (betterAdsStatus != null) {
+ _json["betterAdsStatus"] = betterAdsStatus;
+ }
+ if (egregiousStatus != null) {
+ _json["egregiousStatus"] = egregiousStatus;
+ }
+ if (enforcementTime != null) {
+ _json["enforcementTime"] = enforcementTime;
+ }
+ if (filterStatus != null) {
+ _json["filterStatus"] = filterStatus;
+ }
+ if (lastChangeTime != null) {
+ _json["lastChangeTime"] = lastChangeTime;
+ }
+ if (region != null) {
+ _json["region"] = region;
+ }
+ if (reportUrl != null) {
+ _json["reportUrl"] = reportUrl;
+ }
+ if (underReview != null) {
+ _json["underReview"] = underReview;
+ }
+ return _json;
+ }
+}
+
+/** Response message for GetSiteSummary. */
+class SiteSummaryResponse {
+ /** Summary for the desktop review of the site. */
+ PlatformSummary desktopSummary;
+ /** Summary for the mobile review of the site. */
+ PlatformSummary mobileSummary;
+ /** The name of the site reviewed. */
+ core.String reviewedSite;
+
+ SiteSummaryResponse();
+
+ SiteSummaryResponse.fromJson(core.Map _json) {
+ if (_json.containsKey("desktopSummary")) {
+ desktopSummary = new PlatformSummary.fromJson(_json["desktopSummary"]);
+ }
+ if (_json.containsKey("mobileSummary")) {
+ mobileSummary = new PlatformSummary.fromJson(_json["mobileSummary"]);
+ }
+ if (_json.containsKey("reviewedSite")) {
+ reviewedSite = _json["reviewedSite"];
+ }
+ }
+
+ core.Map<core.String, core.Object> toJson() {
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>();
+ if (desktopSummary != null) {
+ _json["desktopSummary"] = (desktopSummary).toJson();
+ }
+ if (mobileSummary != null) {
+ _json["mobileSummary"] = (mobileSummary).toJson();
+ }
+ if (reviewedSite != null) {
+ _json["reviewedSite"] = reviewedSite;
+ }
+ return _json;
+ }
+}
+
+/** Response message for ListViolatingSites. */
+class ViolatingSitesResponse {
+ /** A list of summaries of violating sites. */
+ core.List<SiteSummaryResponse> violatingSites;
+
+ ViolatingSitesResponse();
+
+ ViolatingSitesResponse.fromJson(core.Map _json) {
+ if (_json.containsKey("violatingSites")) {
+ violatingSites = _json["violatingSites"].map((value) => new SiteSummaryResponse.fromJson(value)).toList();
+ }
+ }
+
+ core.Map<core.String, core.Object> toJson() {
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>();
+ if (violatingSites != null) {
+ _json["violatingSites"] = violatingSites.map((value) => (value).toJson()).toList();
+ }
+ return _json;
+ }
+}
« no previous file with comments | « generated/googleapis/README.md ('k') | generated/googleapis/lib/admin/directory_v1.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698