delete method

Future<void> delete(
  1. String linkingToken,
  2. String type, {
  3. String? externalChannelId,
  4. List<String>? part,
  5. String? $fields,

Deletes a resource.

Request parameters:

linkingToken - Delete the partner links with the given linking token.

type - Type of the link to be deleted. Possible string values are:

  • "linkUnspecified"
  • "channelToStoreLink" : A link that is connecting (or about to connect) a channel with a store on a merchandising platform in order to enable retail commerce capabilities for that channel on YouTube.

externalChannelId - Channel ID to which changes should be applied, for delegation.

part - Do not use. Required for compatibility.

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

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<void> delete(
  core.String linkingToken,
  core.String type, {
  core.String? externalChannelId,
  core.List<core.String>? part,
  core.String? $fields,
}) async {
  final queryParams_ = <core.String, core.List<core.String>>{
    'linkingToken': [linkingToken],
    'type': [type],
    if (externalChannelId != null) 'externalChannelId': [externalChannelId],
    if (part != null) 'part': part,
    if ($fields != null) 'fields': [$fields],

  const url_ = 'youtube/v3/thirdPartyLinks';

  await _requester.request(
    queryParams: queryParams_,
    downloadOptions: null,