Table of Contents

Class WebhookSubscriptionClient

Namespace
Crews.PlanningCenter.Api.Webhooks.V2022_10_20
Assembly
Crews.PlanningCenter.Api.dll

Client for interacting with the WebhookSubscription resource.

public class WebhookSubscriptionClient : SingletonResourceClient<WebhookSubscription, WebhookSubscriptionResource, WebhookSubscriptionResponse>
Inheritance
WebhookSubscriptionClient
Inherited Members

Constructors

WebhookSubscriptionClient(HttpClient, Uri)

Client for interacting with the WebhookSubscription resource.

public WebhookSubscriptionClient(HttpClient httpClient, Uri uri)

Parameters

httpClient HttpClient
uri Uri

Properties

Events

Associated Events.

public PaginatedEventClient Events { get; }

Property Value

PaginatedEventClient

Methods

DeleteAsync(CancellationToken)

Deletes the WebhookSubscription resource asynchronously.

public Task DeleteAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task

A task representing the asynchronous delete operation.

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

GetAsync(CancellationToken)

Fetches the WebhookSubscription resource asynchronously.

public Task<WebhookSubscriptionResponse> GetAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<WebhookSubscriptionResponse>

A task representing the asynchronous operation, containing the WebhookSubscription resource.

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(WebhookSubscription, CancellationToken)

Updates an existing WebhookSubscription resource asynchronously.

public Task<WebhookSubscriptionResponse> PatchAsync(WebhookSubscription resource, CancellationToken cancellationToken = default)

Parameters

resource WebhookSubscription

The resource data to be sent in the patch request.

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<WebhookSubscriptionResponse>

A task representing the asynchronous operation, containing the updated WebhookSubscription resource.

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(JsonApiDocument<WebhookSubscriptionResource>, CancellationToken)

Updates an existing WebhookSubscription resource asynchronously.

public Task<WebhookSubscriptionResponse> PatchAsync(JsonApiDocument<WebhookSubscriptionResource> document, CancellationToken cancellationToken = default)

Parameters

document JsonApiDocument<WebhookSubscriptionResource>

The JSON:API document to be sent in the patch request.

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<WebhookSubscriptionResponse>

A task representing the asynchronous operation, containing the updated WebhookSubscription resource.

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

RotateSecretAsync(CancellationToken)

Planning Center does not provide a description for this action.

public Task RotateSecretAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

Returns

Task