Class HouseholdMembershipClient
- Namespace
- Crews.PlanningCenter.Api.People.V2025_07_17
- Assembly
- Crews.PlanningCenter.Api.dll
Client for interacting with the HouseholdMembership resource.
public class HouseholdMembershipClient : SingletonResourceClient<HouseholdMembership, HouseholdMembershipResource, HouseholdMembershipResponse>
- Inheritance
-
SingletonResourceClient<HouseholdMembership, HouseholdMembershipResource, HouseholdMembershipResponse>HouseholdMembershipClient
- Inherited Members
Constructors
HouseholdMembershipClient(HttpClient, Uri)
Client for interacting with the HouseholdMembership resource.
public HouseholdMembershipClient(HttpClient httpClient, Uri uri)
Parameters
httpClientHttpClienturiUri
Properties
Household
Associated Household.
public HouseholdClient Household { get; }
Property Value
Person
Associated Person.
public PersonClient Person { get; }
Property Value
Methods
DeleteAsync(CancellationToken)
Deletes the HouseholdMembership resource asynchronously.
public Task DeleteAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenA 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
cancellationTokenCancellationTokenA 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
IncludePerson()
Include related Person resources in the response.
public HouseholdMembershipClient IncludePerson()
Returns
PatchAsync(HouseholdMembership, CancellationToken)
Updates an existing HouseholdMembership resource asynchronously.
public Task<HouseholdMembershipResponse> PatchAsync(HouseholdMembership resource, CancellationToken cancellationToken = default)
Parameters
resourceHouseholdMembershipThe resource data to be sent in the patch request.
cancellationTokenCancellationTokenA 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
documentJsonApiDocument<HouseholdMembershipResource>The JSON:API document to be sent in the patch request.
cancellationTokenCancellationTokenA 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.