예제 #1
0
        /// <summary>Snippet for DeleteUnsubscriberAsync</summary>
        public async Task DeleteUnsubscriberResourceNamesAsync()
        {
            // Snippet: DeleteUnsubscriberAsync(UnsubscriberName, CallSettings)
            // Additional: DeleteUnsubscriberAsync(UnsubscriberName, CancellationToken)
            // Create client
            UnsubscribersClient unsubscribersClient = await UnsubscribersClient.CreateAsync();

            // Initialize request argument(s)
            UnsubscriberName name = UnsubscriberName.FromProjectUnsubscriber("[PROJECT]", "[UNSUBSCRIBER]");
            // Make the request
            Unsubscriber response = await unsubscribersClient.DeleteUnsubscriberAsync(name);

            // End snippet
        }
예제 #2
0
        /// <summary>Snippet for DeleteUnsubscriberAsync</summary>
        public async Task DeleteUnsubscriberAsync()
        {
            // Snippet: DeleteUnsubscriberAsync(string, CallSettings)
            // Additional: DeleteUnsubscriberAsync(string, CancellationToken)
            // Create client
            UnsubscribersClient unsubscribersClient = await UnsubscribersClient.CreateAsync();

            // Initialize request argument(s)
            string name = "projects/[PROJECT]/unsubscribers/[UNSUBSCRIBER]";
            // Make the request
            Unsubscriber response = await unsubscribersClient.DeleteUnsubscriberAsync(name);

            // End snippet
        }