Table of Contents

Class SurveysSamplingPointsInterviewerAssignmentsClient

Namespace
Nfield.SDK
Assembly
Nfield.Public.SDK.dll
public class SurveysSamplingPointsInterviewerAssignmentsClient
Inheritance
SurveysSamplingPointsInterviewerAssignmentsClient
Inherited Members

Constructors

SurveysSamplingPointsInterviewerAssignmentsClient(string, HttpClient)

public SurveysSamplingPointsInterviewerAssignmentsClient(string baseUrl, HttpClient httpClient)

Parameters

baseUrl string
httpClient HttpClient

Properties

BaseUrl

public string BaseUrl { get; set; }

Property Value

string

JsonSerializerSettings

protected JsonSerializerSettings JsonSerializerSettings { get; }

Property Value

JsonSerializerSettings

ReadResponseAsString

public bool ReadResponseAsString { get; set; }

Property Value

bool

Methods

DeleteAsync(string, string, string, CancellationToken)

Unassign an interviewer from a sampling point.

public virtual Task DeleteAsync(string surveyId, string samplingPointId, string interviewerId, CancellationToken cancellationToken = default)

Parameters

surveyId string

The survey id that the sampling point belongs to

samplingPointId string

The id of the sampling point to unassign

interviewerId string

The id of the interviewer to unassign

cancellationToken CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

Task

No content

Exceptions

NfieldSdkException

A server side error occurred.

DeleteBatchV2Async(string, SamplingPointInterviewerAssignmentsModel, CancellationToken)

Unassign many interviewers from many sampling points.

public virtual Task DeleteBatchV2Async(string surveyId, SamplingPointInterviewerAssignmentsModel model, CancellationToken cancellationToken = default)

Parameters

surveyId string

The survey id that the sampling point belongs to

model SamplingPointInterviewerAssignmentsModel

The id's of the sampling points and the interviewers to unassign

cancellationToken CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

Task

No content

Exceptions

NfieldSdkException

A server side error occurred.

GetAsync(string, string, CancellationToken)

Get the interviewers assigned to a sampling point.

public virtual Task<ICollection<InterviewerSamplingPointAssignmentModel>> GetAsync(string surveyId, string samplingPointId, CancellationToken cancellationToken = default)

Parameters

surveyId string

The survey id that the sampling point belongs to

samplingPointId string

The sampling point to get assignments for

cancellationToken CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

Task<ICollection<InterviewerSamplingPointAssignmentModel>>

Successful

Exceptions

NfieldSdkException

A server side error occurred.

PostAsync(string, string, string, CancellationToken)

Assign an interviewer to a sampling point.

public virtual Task<SamplingPointInterviewerAssignmentsModel> PostAsync(string surveyId, string samplingPointId, string interviewerId, CancellationToken cancellationToken = default)

Parameters

surveyId string

The survey id that the sampling point belongs to

samplingPointId string

The id of the sampling point to assign

interviewerId string

The id of the interviewer to assign

cancellationToken CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

Task<SamplingPointInterviewerAssignmentsModel>

Successful

Exceptions

NfieldSdkException

A server side error occurred.

PostBatchV2Async(string, SamplingPointInterviewerAssignmentsModel, CancellationToken)

Assign many interviewers to many sampling points.

public virtual Task<SamplingPointInterviewerAssignmentsModel> PostBatchV2Async(string surveyId, SamplingPointInterviewerAssignmentsModel model, CancellationToken cancellationToken = default)

Parameters

surveyId string

The survey id that the sampling point belongs to

model SamplingPointInterviewerAssignmentsModel

The id's of the sampling points and the interviewers to assign

cancellationToken CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

Task<SamplingPointInterviewerAssignmentsModel>

Successful

Exceptions

NfieldSdkException

A server side error occurred.

ReadObjectResponseAsync<T>(HttpResponseMessage, IReadOnlyDictionary<string, IEnumerable<string>>, CancellationToken)

protected virtual Task<SurveysSamplingPointsInterviewerAssignmentsClient.ObjectResponseResult<T>> ReadObjectResponseAsync<T>(HttpResponseMessage response, IReadOnlyDictionary<string, IEnumerable<string>> headers, CancellationToken cancellationToken)

Parameters

response HttpResponseMessage
headers IReadOnlyDictionary<string, IEnumerable<string>>
cancellationToken CancellationToken

Returns

Task<SurveysSamplingPointsInterviewerAssignmentsClient.ObjectResponseResult<T>>

Type Parameters

T