Skip to content

Create a theme

Creates a theme of the token’s team. The body is the theme definition described in Themes. Needs the themes:write scope.

POST https://api.responsly.com/v1/themes
Terminal window
curl -X POST https://api.responsly.com/v1/themes \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"name": "Our brand", "font": "Open Sans", "colors": {"background": "#ffffff", "question": "#111111", "answer": "#333333", "button": "#0055ff"}, "background": false}'

The response is 201 Created with the theme, in the same shape as Get a theme. Use its id with Set a form’s theme.

  • Only the keys of a theme definition are kept, each with a valid value. A missing or invalid value takes its default.
  • A theme the form renderer cannot build, for example with a color it cannot read, is refused with 422, so it never breaks the forms that use it.
  • Custom CSS is set in the editor, not through the API.
StatusMeaning
403The token lacks themes:write.
422The theme cannot be used. The answer says why.