Skip to main content
POST
Create Survey
A survey (Survey) is a location-specific questionnaire sent to selected customers on a recurring schedule. It defines delivery timing, customer eligibility, and the questions customers can answer.

Authentication

This endpoint requires OAuth2 authentication. Include a valid bearer token in the Authorization header. The authenticated user must be a full unrestricted administrator or have the Survey-Create role.

Enums

Request Body

Required Fields

integer
required
ID of the location that owns this survey; the Admin Tool normally supplies it from the current location context.
string
required
Required name used by administrators to identify this survey.
string
required
Required free-text description explaining the purpose of this survey.
string
required
UTC date and time when the next scheduled delivery is due; the system advances it by the delivery rate after a delivery.
integer
required
Positive number of delivery-frequency units between scheduled deliveries; a value of zero prevents scheduled delivery.
integer
required
Unit used by DeliveryRate and the delivery cap: Weeks, Months, or Years; defaults to Weeks.
integer
required
Maximum number of DeliveryFrequency units after StartDate for scheduled deliveries; zero means no end date.
integer
required
Legacy delivery-cap frequency setting; the delivery-cap calculation uses DeliveryFrequency, so manage the cap with DeliveryRateMaximum and DeliveryFrequency instead.

Optional Fields

boolean
Whether this survey is eligible for scheduled delivery when its next delivery date is due.
string
Optional UTC date and time from which the delivery cap is measured; without it, the delivery cap does not apply.
boolean
Whether delivery is restricted to contacts without an active contract; when enabled with OnlyForMembers, both restrictions apply and no customer can qualify.
boolean
Whether delivery is restricted to members with an active contract; when Tariffs is non-empty, the contract must be on one of those plans.
integer[]
List of plans eligible for member-only delivery; when OnlyForMembers is enabled, an empty list allows every member, otherwise the customer needs an active contract on one of these plans.

Code Examples

Response

200

integer
HTTP status code. 200 on success.
string
A human-readable message confirming the creation.
object
Contains the Id of the newly created record.
boolean
true if the survey was created successfully.
array
null on success.
Example Response

400

string
A summary of the validation error(s), in the format PropertyName: error message.
any
null on validation failure.
object[]
Array of validation errors.
boolean
false when the request fails validation.
Example Response