listAsyncErrors method

Future<GoogleAdsSearchads360V23ServicesListCampaignDraftAsyncErrorsResponse> listAsyncErrors(
  1. String resourceName, {
  2. int? pageSize,
  3. String? pageToken,
  4. String? $fields,
})

Returns all errors that occurred during CampaignDraft promote.

Throws an error if called before campaign draft is promoted. Supports standard list paging. List of thrown errors: [AuthenticationError]() [AuthorizationError]() [HeaderError]() [InternalError]() [QuotaError]() [RequestError]()

Request parameters:

resourceName - Required. The name of the campaign draft from which to retrieve the async errors. Value must have pattern ^customers/\[^/\]+/campaignDrafts/\[^/\]+$.

pageSize - Number of elements to retrieve in a single page. When a page request is too large, the server may decide to further limit the number of returned resources.

pageToken - Token of the page to retrieve. If not specified, the first page of results will be returned. Use the value obtained from next_page_token in the previous response in order to request the next page of results.

$fields - Selector specifying which fields to include in a partial response.

Completes with a GoogleAdsSearchads360V23ServicesListCampaignDraftAsyncErrorsResponse.

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.

Implementation

async.Future<
  GoogleAdsSearchads360V23ServicesListCampaignDraftAsyncErrorsResponse
>
listAsyncErrors(
  core.String resourceName, {
  core.int? pageSize,
  core.String? pageToken,
  core.String? $fields,
}) async {
  final queryParams_ = <core.String, core.List<core.String>>{
    'pageSize': ?pageSize == null ? null : ['${pageSize}'],
    'pageToken': ?pageToken == null ? null : [pageToken],
    'fields': ?$fields == null ? null : [$fields],
  };

  final url_ =
      'v23/' + core.Uri.encodeFull('$resourceName') + ':listAsyncErrors';

  final response_ = await _requester.request(
    url_,
    'GET',
    queryParams: queryParams_,
  );
  return GoogleAdsSearchads360V23ServicesListCampaignDraftAsyncErrorsResponse.fromJson(
    response_ as core.Map<core.String, core.dynamic>,
  );
}