Class PartnerLinkServiceClient
PartnerLinkService client wrapper, for convenient use.
Namespace: Google.Ads.DataManager.V1
Assembly: Google.Ads.DataManager.V1.dll
Syntax
public abstract class PartnerLinkServiceClient
Remarks
Service for managing partner links.
Properties
DefaultEndpoint
The default endpoint for the PartnerLinkService service, which is a host of "datamanager.googleapis.com" and a port of 443.
Declaration
public static string DefaultEndpoint { get; }
Property Value
| Type | Description |
|---|---|
| string |
DefaultScopes
The default PartnerLinkService scopes.
Declaration
public static IReadOnlyList<string> DefaultScopes { get; }
Property Value
| Type | Description |
|---|---|
| IReadOnlyList<string> |
Remarks
The default PartnerLinkService scopes are:
- https://www.googleapis.com/auth/datamanager
GrpcClient
The underlying gRPC PartnerLinkService client
Declaration
public virtual PartnerLinkService.PartnerLinkServiceClient GrpcClient { get; }
Property Value
| Type | Description |
|---|---|
| PartnerLinkService.PartnerLinkServiceClient |
ServiceMetadata
The service metadata associated with this client type.
Declaration
public static ServiceMetadata ServiceMetadata { get; }
Property Value
| Type | Description |
|---|---|
| ServiceMetadata |
Methods
Create()
Synchronously creates a PartnerLinkServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use PartnerLinkServiceClientBuilder .
Declaration
public static PartnerLinkServiceClient Create()
Returns
| Type | Description |
|---|---|
| PartnerLinkServiceClient | The created PartnerLinkServiceClient. |
CreateAsync(CancellationToken)
Asynchronously creates a PartnerLinkServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use PartnerLinkServiceClientBuilder .
Declaration
public static Task<PartnerLinkServiceClient> CreateAsync(CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| CancellationToken | cancellationToken | The CancellationToken to use while creating the client. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLinkServiceClient> | The task representing the created PartnerLinkServiceClient. |
CreatePartnerLink(AccountName, PartnerLink, CallSettings)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PartnerLink CreatePartnerLink(AccountName parent, PartnerLink partnerLink, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| AccountName | parent | Required. The parent, which owns this collection of partner links. Format: accountTypes/{account_type}/accounts/{account} |
| PartnerLink | partnerLink | Required. The partner link to create. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PartnerLink | The RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
AccountName parent = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]");
PartnerLink partnerLink = new PartnerLink();
// Make the request
PartnerLink response = partnerLinkServiceClient.CreatePartnerLink(parent, partnerLink);
CreatePartnerLink(CreatePartnerLinkRequest, CallSettings)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PartnerLink CreatePartnerLink(CreatePartnerLinkRequest request, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| CreatePartnerLinkRequest | request | The request object containing all of the parameters for the API call. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PartnerLink | The RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
CreatePartnerLinkRequest request = new CreatePartnerLinkRequest
{
ParentAsAccountName = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]"),
PartnerLink = new PartnerLink(),
};
// Make the request
PartnerLink response = partnerLinkServiceClient.CreatePartnerLink(request);
CreatePartnerLink(string, PartnerLink, CallSettings)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PartnerLink CreatePartnerLink(string parent, PartnerLink partnerLink, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | parent | Required. The parent, which owns this collection of partner links. Format: accountTypes/{account_type}/accounts/{account} |
| PartnerLink | partnerLink | Required. The partner link to create. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PartnerLink | The RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
string parent = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]";
PartnerLink partnerLink = new PartnerLink();
// Make the request
PartnerLink response = partnerLinkServiceClient.CreatePartnerLink(parent, partnerLink);
CreatePartnerLinkAsync(AccountName, PartnerLink, CallSettings)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task<PartnerLink> CreatePartnerLinkAsync(AccountName parent, PartnerLink partnerLink, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| AccountName | parent | Required. The parent, which owns this collection of partner links. Format: accountTypes/{account_type}/accounts/{account} |
| PartnerLink | partnerLink | Required. The partner link to create. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLink> | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
AccountName parent = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]");
PartnerLink partnerLink = new PartnerLink();
// Make the request
PartnerLink response = await partnerLinkServiceClient.CreatePartnerLinkAsync(parent, partnerLink);
CreatePartnerLinkAsync(AccountName, PartnerLink, CancellationToken)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task<PartnerLink> CreatePartnerLinkAsync(AccountName parent, PartnerLink partnerLink, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| AccountName | parent | Required. The parent, which owns this collection of partner links. Format: accountTypes/{account_type}/accounts/{account} |
| PartnerLink | partnerLink | Required. The partner link to create. |
| CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLink> | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
AccountName parent = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]");
PartnerLink partnerLink = new PartnerLink();
// Make the request
PartnerLink response = await partnerLinkServiceClient.CreatePartnerLinkAsync(parent, partnerLink);
CreatePartnerLinkAsync(CreatePartnerLinkRequest, CallSettings)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task<PartnerLink> CreatePartnerLinkAsync(CreatePartnerLinkRequest request, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| CreatePartnerLinkRequest | request | The request object containing all of the parameters for the API call. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLink> | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
CreatePartnerLinkRequest request = new CreatePartnerLinkRequest
{
ParentAsAccountName = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]"),
PartnerLink = new PartnerLink(),
};
// Make the request
PartnerLink response = await partnerLinkServiceClient.CreatePartnerLinkAsync(request);
CreatePartnerLinkAsync(CreatePartnerLinkRequest, CancellationToken)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task<PartnerLink> CreatePartnerLinkAsync(CreatePartnerLinkRequest request, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| CreatePartnerLinkRequest | request | The request object containing all of the parameters for the API call. |
| CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLink> | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
CreatePartnerLinkRequest request = new CreatePartnerLinkRequest
{
ParentAsAccountName = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]"),
PartnerLink = new PartnerLink(),
};
// Make the request
PartnerLink response = await partnerLinkServiceClient.CreatePartnerLinkAsync(request);
CreatePartnerLinkAsync(string, PartnerLink, CallSettings)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task<PartnerLink> CreatePartnerLinkAsync(string parent, PartnerLink partnerLink, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | parent | Required. The parent, which owns this collection of partner links. Format: accountTypes/{account_type}/accounts/{account} |
| PartnerLink | partnerLink | Required. The partner link to create. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLink> | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]";
PartnerLink partnerLink = new PartnerLink();
// Make the request
PartnerLink response = await partnerLinkServiceClient.CreatePartnerLinkAsync(parent, partnerLink);
CreatePartnerLinkAsync(string, PartnerLink, CancellationToken)
Creates a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task<PartnerLink> CreatePartnerLinkAsync(string parent, PartnerLink partnerLink, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| string | parent | Required. The parent, which owns this collection of partner links. Format: accountTypes/{account_type}/accounts/{account} |
| PartnerLink | partnerLink | Required. The partner link to create. |
| CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
| Type | Description |
|---|---|
| Task<PartnerLink> | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]";
PartnerLink partnerLink = new PartnerLink();
// Make the request
PartnerLink response = await partnerLinkServiceClient.CreatePartnerLinkAsync(parent, partnerLink);
DeletePartnerLink(DeletePartnerLinkRequest, CallSettings)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual void DeletePartnerLink(DeletePartnerLinkRequest request, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| DeletePartnerLinkRequest | request | The request object containing all of the parameters for the API call. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
DeletePartnerLinkRequest request = new DeletePartnerLinkRequest
{
PartnerLinkName = PartnerLinkName.FromAccountTypeAccountPartnerLink("[ACCOUNT_TYPE]", "[ACCOUNT]", "[PARTNER_LINK]"),
};
// Make the request
partnerLinkServiceClient.DeletePartnerLink(request);
DeletePartnerLink(PartnerLinkName, CallSettings)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual void DeletePartnerLink(PartnerLinkName name, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| PartnerLinkName | name | Required. The resource name of the partner link to delete. Format: accountTypes/{account_type}/accounts/{account}/partnerLinks/{partner_link} |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
PartnerLinkName name = PartnerLinkName.FromAccountTypeAccountPartnerLink("[ACCOUNT_TYPE]", "[ACCOUNT]", "[PARTNER_LINK]");
// Make the request
partnerLinkServiceClient.DeletePartnerLink(name);
DeletePartnerLink(string, CallSettings)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual void DeletePartnerLink(string name, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | name | Required. The resource name of the partner link to delete. Format: accountTypes/{account_type}/accounts/{account}/partnerLinks/{partner_link} |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
string name = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]/partnerLinks/[PARTNER_LINK]";
// Make the request
partnerLinkServiceClient.DeletePartnerLink(name);
DeletePartnerLinkAsync(DeletePartnerLinkRequest, CallSettings)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task DeletePartnerLinkAsync(DeletePartnerLinkRequest request, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| DeletePartnerLinkRequest | request | The request object containing all of the parameters for the API call. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| Task | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
DeletePartnerLinkRequest request = new DeletePartnerLinkRequest
{
PartnerLinkName = PartnerLinkName.FromAccountTypeAccountPartnerLink("[ACCOUNT_TYPE]", "[ACCOUNT]", "[PARTNER_LINK]"),
};
// Make the request
await partnerLinkServiceClient.DeletePartnerLinkAsync(request);
DeletePartnerLinkAsync(DeletePartnerLinkRequest, CancellationToken)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task DeletePartnerLinkAsync(DeletePartnerLinkRequest request, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| DeletePartnerLinkRequest | request | The request object containing all of the parameters for the API call. |
| CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
| Type | Description |
|---|---|
| Task | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
DeletePartnerLinkRequest request = new DeletePartnerLinkRequest
{
PartnerLinkName = PartnerLinkName.FromAccountTypeAccountPartnerLink("[ACCOUNT_TYPE]", "[ACCOUNT]", "[PARTNER_LINK]"),
};
// Make the request
await partnerLinkServiceClient.DeletePartnerLinkAsync(request);
DeletePartnerLinkAsync(PartnerLinkName, CallSettings)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task DeletePartnerLinkAsync(PartnerLinkName name, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| PartnerLinkName | name | Required. The resource name of the partner link to delete. Format: accountTypes/{account_type}/accounts/{account}/partnerLinks/{partner_link} |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| Task | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
PartnerLinkName name = PartnerLinkName.FromAccountTypeAccountPartnerLink("[ACCOUNT_TYPE]", "[ACCOUNT]", "[PARTNER_LINK]");
// Make the request
await partnerLinkServiceClient.DeletePartnerLinkAsync(name);
DeletePartnerLinkAsync(PartnerLinkName, CancellationToken)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task DeletePartnerLinkAsync(PartnerLinkName name, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| PartnerLinkName | name | Required. The resource name of the partner link to delete. Format: accountTypes/{account_type}/accounts/{account}/partnerLinks/{partner_link} |
| CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
| Type | Description |
|---|---|
| Task | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
PartnerLinkName name = PartnerLinkName.FromAccountTypeAccountPartnerLink("[ACCOUNT_TYPE]", "[ACCOUNT]", "[PARTNER_LINK]");
// Make the request
await partnerLinkServiceClient.DeletePartnerLinkAsync(name);
DeletePartnerLinkAsync(string, CallSettings)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task DeletePartnerLinkAsync(string name, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | name | Required. The resource name of the partner link to delete. Format: accountTypes/{account_type}/accounts/{account}/partnerLinks/{partner_link} |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| Task | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]/partnerLinks/[PARTNER_LINK]";
// Make the request
await partnerLinkServiceClient.DeletePartnerLinkAsync(name);
DeletePartnerLinkAsync(string, CancellationToken)
Deletes a partner link for the given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual Task DeletePartnerLinkAsync(string name, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| string | name | Required. The resource name of the partner link to delete. Format: accountTypes/{account_type}/accounts/{account}/partnerLinks/{partner_link} |
| CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
| Type | Description |
|---|---|
| Task | A Task containing the RPC response. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]/partnerLinks/[PARTNER_LINK]";
// Make the request
await partnerLinkServiceClient.DeletePartnerLinkAsync(name);
SearchPartnerLinks(AccountName, string, int?, CallSettings)
Searches for all partner links to and from a given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> SearchPartnerLinks(AccountName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| AccountName | parent | Required. Account to search for partner links. If no Format: |
| string | pageToken | The token returned from the previous request. A value of |
| int? | pageSize | The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> | A pageable sequence of PartnerLink resources. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
AccountName parent = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]");
// Make the request
PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> response = partnerLinkServiceClient.SearchPartnerLinks(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (PartnerLink item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (SearchPartnerLinksResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (PartnerLink item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<PartnerLink> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (PartnerLink item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
SearchPartnerLinks(SearchPartnerLinksRequest, CallSettings)
Searches for all partner links to and from a given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> SearchPartnerLinks(SearchPartnerLinksRequest request, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| SearchPartnerLinksRequest | request | The request object containing all of the parameters for the API call. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> | A pageable sequence of PartnerLink resources. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
SearchPartnerLinksRequest request = new SearchPartnerLinksRequest
{
ParentAsAccountName = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]"),
Filter = "",
};
// Make the request
PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> response = partnerLinkServiceClient.SearchPartnerLinks(request);
// Iterate over all response items, lazily performing RPCs as required
foreach (PartnerLink item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (SearchPartnerLinksResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (PartnerLink item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<PartnerLink> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (PartnerLink item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
SearchPartnerLinks(string, string, int?, CallSettings)
Searches for all partner links to and from a given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> SearchPartnerLinks(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | parent | Required. Account to search for partner links. If no Format: |
| string | pageToken | The token returned from the previous request. A value of |
| int? | pageSize | The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> | A pageable sequence of PartnerLink resources. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = PartnerLinkServiceClient.Create();
// Initialize request argument(s)
string parent = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]";
// Make the request
PagedEnumerable<SearchPartnerLinksResponse, PartnerLink> response = partnerLinkServiceClient.SearchPartnerLinks(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (PartnerLink item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (SearchPartnerLinksResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (PartnerLink item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<PartnerLink> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (PartnerLink item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
SearchPartnerLinksAsync(AccountName, string, int?, CallSettings)
Searches for all partner links to and from a given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> SearchPartnerLinksAsync(AccountName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| AccountName | parent | Required. Account to search for partner links. If no Format: |
| string | pageToken | The token returned from the previous request. A value of |
| int? | pageSize | The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> | A pageable asynchronous sequence of PartnerLink resources. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
AccountName parent = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]");
// Make the request
PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> response = partnerLinkServiceClient.SearchPartnerLinksAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await foreach (PartnerLink item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (SearchPartnerLinksResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (PartnerLink item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<PartnerLink> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (PartnerLink item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
SearchPartnerLinksAsync(SearchPartnerLinksRequest, CallSettings)
Searches for all partner links to and from a given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> SearchPartnerLinksAsync(SearchPartnerLinksRequest request, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| SearchPartnerLinksRequest | request | The request object containing all of the parameters for the API call. |
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> | A pageable asynchronous sequence of PartnerLink resources. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
SearchPartnerLinksRequest request = new SearchPartnerLinksRequest
{
ParentAsAccountName = AccountName.FromAccountTypeAccount("[ACCOUNT_TYPE]", "[ACCOUNT]"),
Filter = "",
};
// Make the request
PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> response = partnerLinkServiceClient.SearchPartnerLinksAsync(request);
// Iterate over all response items, lazily performing RPCs as required
await foreach (PartnerLink item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (SearchPartnerLinksResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (PartnerLink item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<PartnerLink> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (PartnerLink item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
SearchPartnerLinksAsync(string, string, int?, CallSettings)
Searches for all partner links to and from a given account.
Authorization Headers:
This method supports the following optional headers to define how the API authorizes access for the request:
login-account: (Optional) The resource name of the account where the Google Account of the credentials is a user. If not set, defaults to the account of the request. Format:accountTypes/{loginAccountType}/accounts/{loginAccountId}linked-account: (Optional) The resource name of the account with an established product link to thelogin-account. Format:accountTypes/{linkedAccountType}/accounts/{linkedAccountId}
Declaration
public virtual PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> SearchPartnerLinksAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | parent | Required. Account to search for partner links. If no Format: |
| string | pageToken | The token returned from the previous request. A value of |
| int? | pageSize | The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
| CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
| Type | Description |
|---|---|
| PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> | A pageable asynchronous sequence of PartnerLink resources. |
Sample code
// Create client
PartnerLinkServiceClient partnerLinkServiceClient = await PartnerLinkServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "accountTypes/[ACCOUNT_TYPE]/accounts/[ACCOUNT]";
// Make the request
PagedAsyncEnumerable<SearchPartnerLinksResponse, PartnerLink> response = partnerLinkServiceClient.SearchPartnerLinksAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await foreach (PartnerLink item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (SearchPartnerLinksResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (PartnerLink item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<PartnerLink> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (PartnerLink item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
ShutdownDefaultChannelsAsync()
Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.
Declaration
public static Task ShutdownDefaultChannelsAsync()
Returns
| Type | Description |
|---|---|
| Task | A task representing the asynchronous shutdown operation. |
Remarks
After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.