Search Ads 360 Reporting API . customers . assetGroupAssets

Instance Methods

close()

Close httplib2 connections.

mutate(customerId, body=None, x__xgafv=None)

Creates, updates or removes asset group assets. Operation statuses are returned.

Method Details

close()
Close httplib2 connections.
mutate(customerId, body=None, x__xgafv=None)
Creates, updates or removes asset group assets. Operation statuses are returned.

Args:
  customerId: string, Required. The ID of the customer whose asset group assets are being modified. (required)
  body: object, The request body.
    The object takes the form of:

{ # Request message for AssetGroupAssetService.MutateAssetGroupAssets.
  "operations": [ # Required. The list of operations to perform on individual asset group assets.
    { # A single operation (create, remove) on an asset group asset.
      "create": { # AssetGroupAsset is the link between an asset and an asset group. Adding an AssetGroupAsset links an asset with an asset group. # Create operation: No resource name is expected for the new asset group asset.
        "asset": "A String", # Immutable. The asset which this asset group asset is linking.
        "assetGroup": "A String", # Immutable. The asset group which this asset group asset is linking.
        "fieldType": "A String", # The description of the placement of the asset within the asset group. For example: HEADLINE, YOUTUBE_VIDEO etc
        "policySummary": { # Contains policy summary information. # Output only. The policy information for this asset group asset.
          "approvalStatus": "A String", # The overall approval status, which is calculated based on the status of its individual policy topic entries.
          "policyTopicEntries": [ # The list of policy findings.
            { # Policy finding attached to a resource (for example, alcohol policy associated with a site that sells alcohol). Each PolicyTopicEntry has a topic that indicates the specific ads policy the entry is about and a type to indicate the effect that the entry will have on serving. It may optionally have one or more evidences that indicate the reason for the finding. It may also optionally have one or more constraints that provide details about how serving may be restricted.
              "constraints": [ # Indicates how serving of this resource may be affected (for example, not serving in a country).
                { # Describes the effect on serving that a policy topic entry will have.
                  "certificateDomainMismatchInCountryList": { # A list of countries where a resource's serving is constrained. # Countries where the resource's domain is not covered by the certificates associated with it.
                    "countries": [ # Countries in which serving is restricted.
                      { # Indicates that a resource's ability to serve in a particular country is constrained.
                        "countryCriterion": "A String", # Geo target constant resource name of the country in which serving is constrained.
                      },
                    ],
                    "totalTargetedCountries": 42, # Total number of countries targeted by the resource.
                  },
                  "certificateMissingInCountryList": { # A list of countries where a resource's serving is constrained. # Countries where a certificate is required for serving.
                    "countries": [ # Countries in which serving is restricted.
                      { # Indicates that a resource's ability to serve in a particular country is constrained.
                        "countryCriterion": "A String", # Geo target constant resource name of the country in which serving is constrained.
                      },
                    ],
                    "totalTargetedCountries": 42, # Total number of countries targeted by the resource.
                  },
                  "countryConstraintList": { # A list of countries where a resource's serving is constrained. # Countries where the resource cannot serve.
                    "countries": [ # Countries in which serving is restricted.
                      { # Indicates that a resource's ability to serve in a particular country is constrained.
                        "countryCriterion": "A String", # Geo target constant resource name of the country in which serving is constrained.
                      },
                    ],
                    "totalTargetedCountries": 42, # Total number of countries targeted by the resource.
                  },
                  "resellerConstraint": { # Indicates that a policy topic was constrained due to disapproval of the website for reseller purposes. # Reseller constraint.
                  },
                },
              ],
              "evidences": [ # Additional information that explains policy finding (for example, the brand name for a trademark finding).
                { # Additional information that explains a policy finding.
                  "destinationMismatch": { # Evidence of mismatches between the URLs of a resource. # Mismatch between the destinations of a resource's URLs.
                    "urlTypes": [ # The set of URLs that did not match each other.
                      "A String",
                    ],
                  },
                  "destinationNotWorking": { # Evidence details when the destination is returning an HTTP error code or isn't functional in all locations for commonly used devices. # Details when the destination is returning an HTTP error code or isn't functional in all locations for commonly used devices.
                    "device": "A String", # The type of device that failed to load the URL.
                    "dnsErrorType": "A String", # The type of DNS error.
                    "expandedUrl": "A String", # The full URL that didn't work.
                    "httpErrorCode": "A String", # The HTTP error code.
                    "lastCheckedDateTime": "A String", # The time the URL was last checked. The format is "YYYY-MM-DD HH:MM:SS". Examples: "2018-03-05 09:15:00" or "2018-02-01 14:34:30"
                  },
                  "destinationTextList": { # A list of strings found in a destination page that caused a policy finding. # The text in the destination of the resource that is causing a policy finding.
                    "destinationTexts": [ # List of text found in the resource's destination page.
                      "A String",
                    ],
                  },
                  "languageCode": "A String", # The language the resource was detected to be written in. This is an IETF language tag such as "en-US".
                  "textList": { # A list of fragments of text that violated a policy. # List of evidence found in the text of a resource.
                    "texts": [ # The fragments of text from the resource that caused the policy finding.
                      "A String",
                    ],
                  },
                  "websiteList": { # A list of websites that caused a policy finding. Used for ONE_WEBSITE_PER_AD_GROUP policy topic, for example. In case there are more than five websites, only the top five (those that appear in resources the most) will be listed here. # List of websites linked with this resource.
                    "websites": [ # Websites that caused the policy finding.
                      "A String",
                    ],
                  },
                },
              ],
              "topic": "A String", # Policy topic this finding refers to. For example, "ALCOHOL", "TRADEMARKS_IN_AD_TEXT", or "DESTINATION_NOT_WORKING". The set of possible policy topics is not fixed for a particular API version and may change at any time.
              "type": "A String", # Describes the negative or positive effect this policy will have on serving.
            },
          ],
          "reviewStatus": "A String", # Where in the review process the resource is.
        },
        "primaryStatus": "A String", # Output only. Provides the PrimaryStatus of this asset link. Primary status is meant essentially to differentiate between the plain "status" field, which has advertiser set values of enabled, paused, or removed. The primary status takes into account other signals (for assets its mainly policy and quality approvals) to come up with a more comprehensive status to indicate its serving state.
        "primaryStatusDetails": [ # Output only. Provides the details of the primary status and its associated reasons.
          { # Provides the detail of a PrimaryStatus. Each asset link has a PrimaryStatus value (e.g. NOT_ELIGIBLE, meaning not serving), and list of corroborating PrimaryStatusReasons (e.g. [ASSET_DISAPPROVED]). Each reason may have some additional details annotated with it. For instance, when the reason is ASSET_DISAPPROVED, the details field will contain additional information about the offline evaluation errors which led to the asset being disapproved.
            "assetDisapproved": { # Details related to AssetLinkPrimaryStatusReasonPB.ASSET_DISAPPROVED # Provides the details for AssetLinkPrimaryStatusReason.ASSET_DISAPPROVED
              "offlineEvaluationErrorReasons": [ # Provides the quality evaluation disapproval reason of an asset.
                "A String",
              ],
            },
            "reason": "A String", # Provides the reason of this PrimaryStatus.
            "status": "A String", # Provides the PrimaryStatus of this status detail.
          },
        ],
        "primaryStatusReasons": [ # Output only. Provides a list of reasons for why an asset is not serving or not serving at full capacity.
          "A String",
        ],
        "resourceName": "A String", # Immutable. The resource name of the asset group asset. Asset group asset resource name have the form: `customers/{customer_id}/assetGroupAssets/{asset_group_id}~{asset_id}~{field_type}`
        "source": "A String", # Output only. Source of the asset group asset.
        "status": "A String", # The status of the link between an asset and asset group.
      },
      "remove": "A String", # Remove operation: A resource name for the removed asset group asset is expected, in this format: `customers/{customer_id}/assetGroupAssets/{asset_group_id}~{asset_id}~{field_type}`
      "update": { # AssetGroupAsset is the link between an asset and an asset group. Adding an AssetGroupAsset links an asset with an asset group. # Update operation: The asset group asset is expected to have a valid resource name.
        "asset": "A String", # Immutable. The asset which this asset group asset is linking.
        "assetGroup": "A String", # Immutable. The asset group which this asset group asset is linking.
        "fieldType": "A String", # The description of the placement of the asset within the asset group. For example: HEADLINE, YOUTUBE_VIDEO etc
        "policySummary": { # Contains policy summary information. # Output only. The policy information for this asset group asset.
          "approvalStatus": "A String", # The overall approval status, which is calculated based on the status of its individual policy topic entries.
          "policyTopicEntries": [ # The list of policy findings.
            { # Policy finding attached to a resource (for example, alcohol policy associated with a site that sells alcohol). Each PolicyTopicEntry has a topic that indicates the specific ads policy the entry is about and a type to indicate the effect that the entry will have on serving. It may optionally have one or more evidences that indicate the reason for the finding. It may also optionally have one or more constraints that provide details about how serving may be restricted.
              "constraints": [ # Indicates how serving of this resource may be affected (for example, not serving in a country).
                { # Describes the effect on serving that a policy topic entry will have.
                  "certificateDomainMismatchInCountryList": { # A list of countries where a resource's serving is constrained. # Countries where the resource's domain is not covered by the certificates associated with it.
                    "countries": [ # Countries in which serving is restricted.
                      { # Indicates that a resource's ability to serve in a particular country is constrained.
                        "countryCriterion": "A String", # Geo target constant resource name of the country in which serving is constrained.
                      },
                    ],
                    "totalTargetedCountries": 42, # Total number of countries targeted by the resource.
                  },
                  "certificateMissingInCountryList": { # A list of countries where a resource's serving is constrained. # Countries where a certificate is required for serving.
                    "countries": [ # Countries in which serving is restricted.
                      { # Indicates that a resource's ability to serve in a particular country is constrained.
                        "countryCriterion": "A String", # Geo target constant resource name of the country in which serving is constrained.
                      },
                    ],
                    "totalTargetedCountries": 42, # Total number of countries targeted by the resource.
                  },
                  "countryConstraintList": { # A list of countries where a resource's serving is constrained. # Countries where the resource cannot serve.
                    "countries": [ # Countries in which serving is restricted.
                      { # Indicates that a resource's ability to serve in a particular country is constrained.
                        "countryCriterion": "A String", # Geo target constant resource name of the country in which serving is constrained.
                      },
                    ],
                    "totalTargetedCountries": 42, # Total number of countries targeted by the resource.
                  },
                  "resellerConstraint": { # Indicates that a policy topic was constrained due to disapproval of the website for reseller purposes. # Reseller constraint.
                  },
                },
              ],
              "evidences": [ # Additional information that explains policy finding (for example, the brand name for a trademark finding).
                { # Additional information that explains a policy finding.
                  "destinationMismatch": { # Evidence of mismatches between the URLs of a resource. # Mismatch between the destinations of a resource's URLs.
                    "urlTypes": [ # The set of URLs that did not match each other.
                      "A String",
                    ],
                  },
                  "destinationNotWorking": { # Evidence details when the destination is returning an HTTP error code or isn't functional in all locations for commonly used devices. # Details when the destination is returning an HTTP error code or isn't functional in all locations for commonly used devices.
                    "device": "A String", # The type of device that failed to load the URL.
                    "dnsErrorType": "A String", # The type of DNS error.
                    "expandedUrl": "A String", # The full URL that didn't work.
                    "httpErrorCode": "A String", # The HTTP error code.
                    "lastCheckedDateTime": "A String", # The time the URL was last checked. The format is "YYYY-MM-DD HH:MM:SS". Examples: "2018-03-05 09:15:00" or "2018-02-01 14:34:30"
                  },
                  "destinationTextList": { # A list of strings found in a destination page that caused a policy finding. # The text in the destination of the resource that is causing a policy finding.
                    "destinationTexts": [ # List of text found in the resource's destination page.
                      "A String",
                    ],
                  },
                  "languageCode": "A String", # The language the resource was detected to be written in. This is an IETF language tag such as "en-US".
                  "textList": { # A list of fragments of text that violated a policy. # List of evidence found in the text of a resource.
                    "texts": [ # The fragments of text from the resource that caused the policy finding.
                      "A String",
                    ],
                  },
                  "websiteList": { # A list of websites that caused a policy finding. Used for ONE_WEBSITE_PER_AD_GROUP policy topic, for example. In case there are more than five websites, only the top five (those that appear in resources the most) will be listed here. # List of websites linked with this resource.
                    "websites": [ # Websites that caused the policy finding.
                      "A String",
                    ],
                  },
                },
              ],
              "topic": "A String", # Policy topic this finding refers to. For example, "ALCOHOL", "TRADEMARKS_IN_AD_TEXT", or "DESTINATION_NOT_WORKING". The set of possible policy topics is not fixed for a particular API version and may change at any time.
              "type": "A String", # Describes the negative or positive effect this policy will have on serving.
            },
          ],
          "reviewStatus": "A String", # Where in the review process the resource is.
        },
        "primaryStatus": "A String", # Output only. Provides the PrimaryStatus of this asset link. Primary status is meant essentially to differentiate between the plain "status" field, which has advertiser set values of enabled, paused, or removed. The primary status takes into account other signals (for assets its mainly policy and quality approvals) to come up with a more comprehensive status to indicate its serving state.
        "primaryStatusDetails": [ # Output only. Provides the details of the primary status and its associated reasons.
          { # Provides the detail of a PrimaryStatus. Each asset link has a PrimaryStatus value (e.g. NOT_ELIGIBLE, meaning not serving), and list of corroborating PrimaryStatusReasons (e.g. [ASSET_DISAPPROVED]). Each reason may have some additional details annotated with it. For instance, when the reason is ASSET_DISAPPROVED, the details field will contain additional information about the offline evaluation errors which led to the asset being disapproved.
            "assetDisapproved": { # Details related to AssetLinkPrimaryStatusReasonPB.ASSET_DISAPPROVED # Provides the details for AssetLinkPrimaryStatusReason.ASSET_DISAPPROVED
              "offlineEvaluationErrorReasons": [ # Provides the quality evaluation disapproval reason of an asset.
                "A String",
              ],
            },
            "reason": "A String", # Provides the reason of this PrimaryStatus.
            "status": "A String", # Provides the PrimaryStatus of this status detail.
          },
        ],
        "primaryStatusReasons": [ # Output only. Provides a list of reasons for why an asset is not serving or not serving at full capacity.
          "A String",
        ],
        "resourceName": "A String", # Immutable. The resource name of the asset group asset. Asset group asset resource name have the form: `customers/{customer_id}/assetGroupAssets/{asset_group_id}~{asset_id}~{field_type}`
        "source": "A String", # Output only. Source of the asset group asset.
        "status": "A String", # The status of the link between an asset and asset group.
      },
      "updateMask": "A String", # FieldMask that determines which resource fields are modified in an update.
    },
  ],
  "partialFailure": True or False, # If true, successful operations will be carried out and invalid operations will return errors. If false, all operations will be carried out in one transaction if and only if they are all valid. Default is false.
  "validateOnly": True or False, # If true, the request is validated but not executed. Only errors are returned, not results.
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Response message for an asset group asset mutate.
  "partialFailureError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # Errors that pertain to operation failures in the partial failure mode. Returned only when partial_failure = true and all errors occur inside the operations. If any errors occur outside the operations (for example, auth errors), we return an RPC level error.
    "code": 42, # The status code, which should be an enum value of google.rpc.Code.
    "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
      {
        "a_key": "", # Properties of the object. Contains field @type with type URL.
      },
    ],
    "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
  },
  "results": [ # All results for the mutate.
    { # The result for the asset group asset mutate.
      "resourceName": "A String", # Returned for successful operations.
    },
  ],
}