Class PlanPersonClient
- Namespace
- Crews.PlanningCenter.Api.Services.V2018_11_01
- Assembly
- Crews.PlanningCenter.Api.dll
Client for interacting with the PlanPerson resource.
public class PlanPersonClient : SingletonResourceClient<PlanPerson, PlanPersonResource, PlanPersonResponse>
- Inheritance
-
PlanPersonClient
- Inherited Members
Constructors
PlanPersonClient(HttpClient, Uri)
Client for interacting with the PlanPerson resource.
public PlanPersonClient(HttpClient httpClient, Uri uri)
Parameters
httpClientHttpClienturiUri
Properties
DeclinedPlanTimes
Associated DeclinedPlanTimes.
public PaginatedPlanTimeClient DeclinedPlanTimes { get; }
Property Value
Person
Associated Person.
public PersonClient Person { get; }
Property Value
Plan
Associated Plan.
public PlanClient Plan { get; }
Property Value
PlanPersonTimes
Associated PlanPersonTimes.
public PaginatedPlanPersonTimeClient PlanPersonTimes { get; }
Property Value
PlanTimes
Associated PlanTimes.
public PaginatedPlanTimeClient PlanTimes { get; }
Property Value
Team
Associated Team.
public TeamClient Team { get; }
Property Value
Methods
DeleteAsync(CancellationToken)
Deletes the PlanPerson 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 PlanPerson resource asynchronously.
public Task<PlanPersonResponse> GetAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<PlanPersonResponse>
A task representing the asynchronous operation, containing the PlanPerson resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.
IncludeDeclinedPlanTimes()
Include related DeclinedPlanTimes resources in the response.
public PlanPersonClient IncludeDeclinedPlanTimes()
Returns
IncludePerson()
Include related Person resources in the response.
public PlanPersonClient IncludePerson()
Returns
IncludePlan()
Include related Plan resources in the response.
public PlanPersonClient IncludePlan()
Returns
IncludeTeam()
Include related Team resources in the response.
public PlanPersonClient IncludeTeam()
Returns
PatchAsync(PlanPerson, CancellationToken)
Updates an existing PlanPerson resource asynchronously.
public Task<PlanPersonResponse> PatchAsync(PlanPerson resource, CancellationToken cancellationToken = default)
Parameters
resourcePlanPersonThe resource data to be sent in the patch request.
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<PlanPersonResponse>
A task representing the asynchronous operation, containing the updated PlanPerson resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.
PatchAsync(JsonApiDocument<PlanPersonResource>, CancellationToken)
Updates an existing PlanPerson resource asynchronously.
public Task<PlanPersonResponse> PatchAsync(JsonApiDocument<PlanPersonResource> document, CancellationToken cancellationToken = default)
Parameters
documentJsonApiDocument<PlanPersonResource>The JSON:API document to be sent in the patch request.
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<PlanPersonResponse>
A task representing the asynchronous operation, containing the updated PlanPerson resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.