Class SurveysParentSurveysClient
public class SurveysParentSurveysClient
- Inheritance
-
SurveysParentSurveysClient
- Inherited Members
Constructors
SurveysParentSurveysClient(string, HttpClient)
public SurveysParentSurveysClient(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
GetParentSurveysAsync(CancellationToken)
Retrieve all parent surveys. This list can be filtered and sorted
using standard OData syntax.
Parent surveys is a logical organization for surveys
A Parent survey can't be used to perform interviews, it need children (Waves), each wave works as a survey and can be managed like a regular survey through the Surveys Endpoints
public virtual Task<ICollection<SurveyModel>> GetParentSurveysAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenA cancellation token that can be used by other objects or threads to receive notice of cancellation.
Returns
- Task<ICollection<SurveyModel>>
Successful
Exceptions
- NfieldSdkException
A server side error occurred.
PostAsync(ParentSurveyCreateRequestModel, CancellationToken)
Create new ONLINE parent survey.
Parent surveys is a logical organization for surveys that allow create waves
public virtual Task<SurveyModel> PostAsync(ParentSurveyCreateRequestModel newSurvey, CancellationToken cancellationToken = default)
Parameters
newSurveyParentSurveyCreateRequestModelAn object describing the details for the new parent survey
cancellationTokenCancellationTokenA cancellation token that can be used by other objects or threads to receive notice of cancellation.
Returns
- Task<SurveyModel>
Successful
Exceptions
- NfieldSdkException
A server side error occurred.
ReadObjectResponseAsync<T>(HttpResponseMessage, IReadOnlyDictionary<string, IEnumerable<string>>, CancellationToken)
protected virtual Task<SurveysParentSurveysClient.ObjectResponseResult<T>> ReadObjectResponseAsync<T>(HttpResponseMessage response, IReadOnlyDictionary<string, IEnumerable<string>> headers, CancellationToken cancellationToken)
Parameters
responseHttpResponseMessageheadersIReadOnlyDictionary<string, IEnumerable<string>>cancellationTokenCancellationToken
Returns
Type Parameters
T