Table of Contents

Class ResourceQuestionClient

Namespace
Crews.PlanningCenter.Api.Calendar.V2021_07_20
Assembly
Crews.PlanningCenter.Api.dll

Client for interacting with the ResourceQuestion resource.

public class ResourceQuestionClient : SingletonResourceClient<ResourceQuestion, ResourceQuestionResource, ResourceQuestionResponse>
Inheritance
ResourceQuestionClient
Inherited Members

Constructors

ResourceQuestionClient(HttpClient, Uri)

Client for interacting with the ResourceQuestion resource.

public ResourceQuestionClient(HttpClient httpClient, Uri uri)

Parameters

httpClient HttpClient
uri Uri

Methods

AddCustomParameter(string, string)

Adds a custom query parameter to the request URI.

public ResourceQuestionClient AddCustomParameter(string parameter, string value)

Parameters

parameter string

The name of the query parameter.

value string

The value of the query parameter.

Returns

ResourceQuestionClient

The current ResourceQuestionClient instance.

ClearParameters()

Removes the entire query string from the request URI.

public ResourceQuestionClient ClearParameters()

Returns

ResourceQuestionClient

The current ResourceQuestionClient instance.

DeleteAsync(CancellationToken)

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

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

Parameters

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<ResourceQuestionResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(ResourceQuestion, CancellationToken)

Updates an existing ResourceQuestion resource asynchronously.

public Task<ResourceQuestionResponse> PatchAsync(ResourceQuestion resource, CancellationToken cancellationToken = default)

Parameters

resource ResourceQuestion

The resource data to be sent in the patch request.

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<ResourceQuestionResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.

PatchAsync(JsonApiDocument<ResourceQuestionResource>, CancellationToken)

Updates an existing ResourceQuestion resource asynchronously.

public Task<ResourceQuestionResponse> PatchAsync(JsonApiDocument<ResourceQuestionResource> document, CancellationToken cancellationToken = default)

Parameters

document JsonApiDocument<ResourceQuestionResource>

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

cancellationToken CancellationToken

A token to monitor for cancellation requests.

Returns

Task<ResourceQuestionResponse>

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

Exceptions

JsonApiException

Thrown when the HTTP response indicates a failure status code.