Class FolderClient
- Namespace
- Crews.PlanningCenter.Api.Services.V2018_11_01
- Assembly
- Crews.PlanningCenter.Api.dll
Client for interacting with the Folder resource.
public class FolderClient : SingletonResourceClient<Folder, FolderResource, FolderResponse>
- Inheritance
-
FolderClient
- Inherited Members
Constructors
FolderClient(HttpClient, Uri)
Client for interacting with the Folder resource.
public FolderClient(HttpClient httpClient, Uri uri)
Parameters
httpClientHttpClienturiUri
Properties
Folders
Associated Folders.
public PaginatedFolderClient Folders { get; }
Property Value
ServiceTypes
Associated ServiceTypes.
public PaginatedServiceTypeClient ServiceTypes { get; }
Property Value
Methods
DeleteAsync(CancellationToken)
Deletes the Folder 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 Folder resource asynchronously.
public Task<FolderResponse> GetAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<FolderResponse>
A task representing the asynchronous operation, containing the Folder resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.
IncludeServiceTypes()
Include related ServiceTypes resources in the response.
public FolderClient IncludeServiceTypes()
Returns
PatchAsync(Folder, CancellationToken)
Updates an existing Folder resource asynchronously.
public Task<FolderResponse> PatchAsync(Folder resource, CancellationToken cancellationToken = default)
Parameters
resourceFolderThe resource data to be sent in the patch request.
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<FolderResponse>
A task representing the asynchronous operation, containing the updated Folder resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.
PatchAsync(JsonApiDocument<FolderResource>, CancellationToken)
Updates an existing Folder resource asynchronously.
public Task<FolderResponse> PatchAsync(JsonApiDocument<FolderResource> document, CancellationToken cancellationToken = default)
Parameters
documentJsonApiDocument<FolderResource>The JSON:API document to be sent in the patch request.
cancellationTokenCancellationTokenA token to monitor for cancellation requests.
Returns
- Task<FolderResponse>
A task representing the asynchronous operation, containing the updated Folder resource.
Exceptions
- JsonApiException
Thrown when the HTTP response indicates a failure status code.