Class WorkflowClient
- Namespace
- Crews.PlanningCenter.Api.People.V2019_01_14
- Assembly
- Crews.PlanningCenter.Api.dll
Client for interacting with the Workflow resource.
public class WorkflowClient : SingletonResourceClient<Workflow, WorkflowResource, WorkflowResponse>
- Inheritance
-
WorkflowClient
- Inherited Members
Constructors
WorkflowClient(HttpClient, Uri)
Client for interacting with the Workflow resource.
public WorkflowClient(HttpClient httpClient, Uri uri)
Parameters
httpClientHttpClienturiUri
Properties
Cards
Associated Cards.
public PaginatedWorkflowCardClient Cards { get; }
Property Value
Category
Associated Category.
public WorkflowCategoryClient Category { get; }
Property Value
SharedPeople
Associated SharedPeople.
public PaginatedPersonClient SharedPeople { get; }
Property Value
Shares
Associated Shares.
public PaginatedWorkflowShareClient Shares { get; }
Property Value
Steps
Associated Steps.
public PaginatedWorkflowStepClient Steps { get; }
Property Value
Methods
DeleteAsync(CancellationToken)
Deletes the Workflow 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 Workflow resource asynchronously.
public Task<WorkflowResponse> GetAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<WorkflowResponse>
A task representing the asynchronous operation, containing the Workflow resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.
IncludeCategory()
Include related Category resources in the response.
public WorkflowClient IncludeCategory()
Returns
IncludeShares()
Include related Shares resources in the response.
public WorkflowClient IncludeShares()
Returns
IncludeSteps()
Include related Steps resources in the response.
public WorkflowClient IncludeSteps()
Returns
PatchAsync(Workflow, CancellationToken)
Updates an existing Workflow resource asynchronously.
public Task<WorkflowResponse> PatchAsync(Workflow resource, CancellationToken cancellationToken = default)
Parameters
resourceWorkflowThe resource data to be sent in the patch request.
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<WorkflowResponse>
A task representing the asynchronous operation, containing the updated Workflow resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.
PatchAsync(JsonApiDocument<WorkflowResource>, CancellationToken)
Updates an existing Workflow resource asynchronously.
public Task<WorkflowResponse> PatchAsync(JsonApiDocument<WorkflowResource> document, CancellationToken cancellationToken = default)
Parameters
documentJsonApiDocument<WorkflowResource>The JSON:API document to be sent in the patch request.
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<WorkflowResponse>
A task representing the asynchronous operation, containing the updated Workflow resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.