Class SurveysBlueprintsClient
public class SurveysBlueprintsClient
- Inheritance
-
SurveysBlueprintsClient
- Inherited Members
Constructors
SurveysBlueprintsClient(string, HttpClient)
public SurveysBlueprintsClient(string baseUrl, HttpClient httpClient)
Parameters
baseUrlstringhttpClientHttpClient
Properties
BaseUrl
public string BaseUrl { get; set; }
Property Value
JsonSerializerSettings
protected JsonSerializerSettings JsonSerializerSettings { get; }
Property Value
- JsonSerializerSettings
ReadResponseAsString
public bool ReadResponseAsString { get; set; }
Property Value
Methods
PostAsync(SurveyFromBlueprintModel, CancellationToken)
This method creates a new survey from a blueprint survey.
All survey configurations will be copied from the blueprint to the new survey.
public virtual Task<SurveyModel> PostAsync(SurveyFromBlueprintModel input, CancellationToken cancellationToken = default)
Parameters
inputSurveyFromBlueprintModelAn object describing the details for the new survey
cancellationTokenCancellationTokenA cancellation token that can be used by other objects or threads to receive notice of cancellation.
Returns
- Task<SurveyModel>
Survey created from blueprint survey
Exceptions
- NfieldSdkException
A server side error occurred.
PutAsync(string, UpdateBlueprintModel, CancellationToken)
This method updates an existing blueprint by copying configuration from a survey.
public virtual Task PutAsync(string blueprintId, UpdateBlueprintModel input, CancellationToken cancellationToken = default)
Parameters
blueprintIdstringinputUpdateBlueprintModelcancellationTokenCancellationTokenA cancellation token that can be used by other objects or threads to receive notice of cancellation.
Returns
- Task
Successful
Exceptions
- NfieldSdkException
A server side error occurred.
ReadObjectResponseAsync<T>(HttpResponseMessage, IReadOnlyDictionary<string, IEnumerable<string>>, CancellationToken)
protected virtual Task<SurveysBlueprintsClient.ObjectResponseResult<T>> ReadObjectResponseAsync<T>(HttpResponseMessage response, IReadOnlyDictionary<string, IEnumerable<string>> headers, CancellationToken cancellationToken)
Parameters
responseHttpResponseMessageheadersIReadOnlyDictionary<string, IEnumerable<string>>cancellationTokenCancellationToken
Returns
Type Parameters
T