Update a survey
Edit a survey. Send any subset of the survey contract. Once a survey is active or has any responses, changing type, questions or settings.anonymous is refused with 400, because it would change what past answers mean. Duplicate the survey in the app to change those. Name, cooldown and the other settings stay editable. The merged result is validated as a whole, so a patch can fail on a rule that involves a key you did not send. Rules that compare several fields (a required first question, the NPS 0-10 and CSAT/CES scale ranges, promotional copy, showWhen rules) are checked after the merge, and a failure returns 400 bad_request with a generic message and no field detail. A value that fails its own field schema returns 422. Requires a secret server key (gt_live_). Publishable keys (gt_pub_) return 403.
Scope: write:surveys
Authorizations
Bearer API key. Secret server keys start with gt_live_; client-safe browser keys start with gt_pub_ (write-only, origin-pinned). Create and scope keys in Settings → API Keys.
Path Parameters
The survey's UUID.
Body
Any subset of the survey contract. settings keys you send replace the matching top-level settings keys, and the rest are kept. A nested object such as reminders is replaced as a whole.
1 - 255nps is a 0-10 scale. csat and ces use a 1-5 or 1-7 scale. custom has no band and its responses are unscored. For nps, csat and ces, the first question must be a required rating or scale question: it carries the score.
nps, csat, ces, custom 1 - 20 elementsOptional survey settings. Unknown keys are rejected.
Minimum days since this person last got a survey of the same measure (an email sent, an invited answer or an in-app view) before this survey can invite them or show to them in-app. It doesn't block responses you record through the API.
0 <= x <= 730Response
The updated survey.