AdSense Management API . accounts . policyIssues

Instance Methods

close()

Close httplib2 connections.

get(name, x__xgafv=None)

Gets information about the selected policy issue.

list(parent, pageSize=None, pageToken=None, x__xgafv=None)

Lists all the policy issues where the specified account is involved, both directly and through any AFP child accounts.

list_next()

Retrieves the next page of results.

Method Details

close()
Close httplib2 connections.
get(name, x__xgafv=None)
Gets information about the selected policy issue.

Args:
  name: string, Required. Name of the policy issue. Format: accounts/{account}/policyIssues/{policy_issue} (required)
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Representation of a policy issue for a single entity (site, site-section, or page). All issues for a single entity are represented by a single PolicyIssue resource, though that PolicyIssue can have multiple causes (or "topics") that can change over time. Policy issues are removed if there are no issues detected recently or if there's a recent successful appeal for the entity.
  "action": "A String", # Required. The most severe action taken on the entity over the past seven days.
  "adClients": [ # Optional. List of ad clients associated with the policy issue (either as the primary ad client or an associated host/secondary ad client). In the latter case, this will be an ad client that is not owned by the current account.
    "A String",
  ],
  "adRequestCount": "A String", # Required. Total number of ad requests affected by the policy violations over the past seven days.
  "entityType": "A String", # Required. Type of the entity indicating if the entity is a site, site-section, or page.
  "firstDetectedDate": { # Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp # Required. The date (in the America/Los_Angeles timezone) when policy violations were first detected on the entity.
    "day": 42, # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.
    "month": 42, # Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
    "year": 42, # Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
  },
  "lastDetectedDate": { # Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp # Required. The date (in the America/Los_Angeles timezone) when policy violations were last detected on the entity.
    "day": 42, # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.
    "month": 42, # Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
    "year": 42, # Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
  },
  "name": "A String", # Required. Resource name of the entity with policy issues. Format: accounts/{account}/policyIssues/{policy_issue}
  "policyTopics": [ # Required. Unordered list. The policy topics that this entity was found to violate over the past seven days.
    { # Information about a particular policy topic. A policy topic represents a single class of policy issue that can impact ad serving for your site. For example, sexual content or having ads that obscure your content. A single policy issue can have multiple policy topics for a single entity.
      "mustFix": True or False, # Required. Indicates if this is a policy violation or not. When the value is true, issues that are instances of this topic must be addressed to remain in compliance with the partner's agreements with Google. A false value indicates that it's not mandatory to fix the issues but advertising demand might be restricted.
      "topic": "A String", # Required. The policy topic. For example, "sexual-content" or "ads-obscuring-content"."
    },
  ],
  "site": "A String", # Required. Hostname/domain of the entity (for example "foo.com" or "www.foo.com"). This _should_ be a bare domain/host name without any protocol. This will be present for all policy issues.
  "siteSection": "A String", # Optional. Prefix of the site-section having policy issues (For example "foo.com/bar-section"). This will be present if the `entity_type` is `SITE_SECTION` and will be absent for other entity types.
  "uri": "A String", # Optional. URI of the page having policy violations (for example "foo.com/bar" or "www.foo.com/bar"). This will be present if the `entity_type` is `PAGE` and will be absent for other entity types.
  "warningEscalationDate": { # Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp # Optional. The date (in the America/Los_Angeles timezone) when the entity will have ad serving demand restricted or ad serving disabled. This is present only for issues with a `WARNED` enforcement action. See https://support.google.com/adsense/answer/11066888.
    "day": 42, # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.
    "month": 42, # Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
    "year": 42, # Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
  },
}
list(parent, pageSize=None, pageToken=None, x__xgafv=None)
Lists all the policy issues where the specified account is involved, both directly and through any AFP child accounts.

Args:
  parent: string, Required. The account for which policy issues are being retrieved. Format: accounts/{account} (required)
  pageSize: integer, The maximum number of policy issues to include in the response, used for paging. If unspecified, at most 10000 policy issues will be returned. The maximum value is 10000; values above 10000 will be coerced to 10000.
  pageToken: string, A page token, received from a previous `ListPolicyIssues` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListPolicyIssues` must match the call that provided the page token.
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Response definition for the policy issues list rpc. Policy issues are reported only if the publisher has at least one AFC ad client in READY or GETTING_READY state. If the publisher has no such AFC ad client, the response will be an empty list.
  "nextPageToken": "A String", # Continuation token used to page through policy issues. To retrieve the next page of the results, set the next request's "page_token" value to this.
  "policyIssues": [ # The policy issues returned in the list response.
    { # Representation of a policy issue for a single entity (site, site-section, or page). All issues for a single entity are represented by a single PolicyIssue resource, though that PolicyIssue can have multiple causes (or "topics") that can change over time. Policy issues are removed if there are no issues detected recently or if there's a recent successful appeal for the entity.
      "action": "A String", # Required. The most severe action taken on the entity over the past seven days.
      "adClients": [ # Optional. List of ad clients associated with the policy issue (either as the primary ad client or an associated host/secondary ad client). In the latter case, this will be an ad client that is not owned by the current account.
        "A String",
      ],
      "adRequestCount": "A String", # Required. Total number of ad requests affected by the policy violations over the past seven days.
      "entityType": "A String", # Required. Type of the entity indicating if the entity is a site, site-section, or page.
      "firstDetectedDate": { # Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp # Required. The date (in the America/Los_Angeles timezone) when policy violations were first detected on the entity.
        "day": 42, # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.
        "month": 42, # Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
        "year": 42, # Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
      },
      "lastDetectedDate": { # Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp # Required. The date (in the America/Los_Angeles timezone) when policy violations were last detected on the entity.
        "day": 42, # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.
        "month": 42, # Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
        "year": 42, # Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
      },
      "name": "A String", # Required. Resource name of the entity with policy issues. Format: accounts/{account}/policyIssues/{policy_issue}
      "policyTopics": [ # Required. Unordered list. The policy topics that this entity was found to violate over the past seven days.
        { # Information about a particular policy topic. A policy topic represents a single class of policy issue that can impact ad serving for your site. For example, sexual content or having ads that obscure your content. A single policy issue can have multiple policy topics for a single entity.
          "mustFix": True or False, # Required. Indicates if this is a policy violation or not. When the value is true, issues that are instances of this topic must be addressed to remain in compliance with the partner's agreements with Google. A false value indicates that it's not mandatory to fix the issues but advertising demand might be restricted.
          "topic": "A String", # Required. The policy topic. For example, "sexual-content" or "ads-obscuring-content"."
        },
      ],
      "site": "A String", # Required. Hostname/domain of the entity (for example "foo.com" or "www.foo.com"). This _should_ be a bare domain/host name without any protocol. This will be present for all policy issues.
      "siteSection": "A String", # Optional. Prefix of the site-section having policy issues (For example "foo.com/bar-section"). This will be present if the `entity_type` is `SITE_SECTION` and will be absent for other entity types.
      "uri": "A String", # Optional. URI of the page having policy violations (for example "foo.com/bar" or "www.foo.com/bar"). This will be present if the `entity_type` is `PAGE` and will be absent for other entity types.
      "warningEscalationDate": { # Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp # Optional. The date (in the America/Los_Angeles timezone) when the entity will have ad serving demand restricted or ad serving disabled. This is present only for issues with a `WARNED` enforcement action. See https://support.google.com/adsense/answer/11066888.
        "day": 42, # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.
        "month": 42, # Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
        "year": 42, # Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
      },
    },
  ],
}
list_next()
Retrieves the next page of results.

        Args:
          previous_request: The request for the previous page. (required)
          previous_response: The response from the request for the previous page. (required)

        Returns:
          A request object that you can call 'execute()' on to request the next
          page. Returns None if there are no more items in the collection.