Table of Contents

Class HouseholdMembershipClient

Namespace
Crews.PlanningCenter.Api.People.V2021_08_17
Assembly
Crews.PlanningCenter.Api.dll

Client for interacting with the HouseholdMembership resource.

public class HouseholdMembershipClient : SingletonResourceClient<HouseholdMembership, HouseholdMembershipResource, HouseholdMembershipResponse>
Inheritance
HouseholdMembershipClient
Inherited Members

Constructors

HouseholdMembershipClient(HttpClient, Uri)

Client for interacting with the HouseholdMembership resource.

public HouseholdMembershipClient(HttpClient httpClient, Uri uri)

Parameters

httpClient HttpClient
uri Uri

Properties

Household

Associated Household.

public HouseholdClient Household { get; }

Property Value

HouseholdClient

Person

Associated Person.

public PersonClient Person { get; }

Property Value

PersonClient

Methods

DeleteAsync(CancellationToken)

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

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

Parameters

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<HouseholdMembershipResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

IncludeHousehold()

Include related Household resources in the response.

public HouseholdMembershipClient IncludeHousehold()

Returns

HouseholdMembershipClient

IncludePerson()

Include related Person resources in the response.

public HouseholdMembershipClient IncludePerson()

Returns

HouseholdMembershipClient

PatchAsync(HouseholdMembership, CancellationToken)

Updates an existing HouseholdMembership resource asynchronously.

public Task<HouseholdMembershipResponse> PatchAsync(HouseholdMembership resource, CancellationToken cancellationToken = default)

Parameters

resource HouseholdMembership

The resource data to be sent in the patch request.

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<HouseholdMembershipResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(JsonApiDocument<HouseholdMembershipResource>, CancellationToken)

Updates an existing HouseholdMembership resource asynchronously.

public Task<HouseholdMembershipResponse> PatchAsync(JsonApiDocument<HouseholdMembershipResource> document, CancellationToken cancellationToken = default)

Parameters

document JsonApiDocument<HouseholdMembershipResource>

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

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<HouseholdMembershipResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.