Table of Contents

Class PaymentSourceClient

Namespace
Crews.PlanningCenter.Api.Giving.V2019_10_18
Assembly
Crews.PlanningCenter.Api.dll

Client for interacting with the PaymentSource resource.

public class PaymentSourceClient : SingletonResourceClient<PaymentSource, PaymentSourceResource, PaymentSourceResponse>
Inheritance
PaymentSourceClient
Inherited Members

Constructors

PaymentSourceClient(HttpClient, Uri)

Client for interacting with the PaymentSource resource.

public PaymentSourceClient(HttpClient httpClient, Uri uri)

Parameters

httpClient HttpClient
uri Uri

Properties

Donations

Associated Donations.

public PaginatedDonationClient Donations { get; }

Property Value

PaginatedDonationClient

Methods

DeleteAsync(CancellationToken)

Deletes the PaymentSource 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 PaymentSource resource asynchronously.

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

Parameters

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<PaymentSourceResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(PaymentSource, CancellationToken)

Updates an existing PaymentSource resource asynchronously.

public Task<PaymentSourceResponse> PatchAsync(PaymentSource resource, CancellationToken cancellationToken = default)

Parameters

resource PaymentSource

The resource data to be sent in the patch request.

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<PaymentSourceResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(JsonApiDocument<PaymentSourceResource>, CancellationToken)

Updates an existing PaymentSource resource asynchronously.

public Task<PaymentSourceResponse> PatchAsync(JsonApiDocument<PaymentSourceResource> document, CancellationToken cancellationToken = default)

Parameters

document JsonApiDocument<PaymentSourceResource>

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

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<PaymentSourceResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.