Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Update form template

Save content as the latest design of a form and return the stored version.

Update form template

patch

Save content as the latest design of a form and return the stored version.

The HTML is sanitized and, unless the plan allows removing it, the Reach signature is added. Visitors submit the form with an email field (required) and optional name, surname and phone. After sanitizing, the design must contain a form container (data-reach-form), an email input (data-reach-field="email") and a submit button (data-reach-submit); otherwise the request fails with 422 and errors.content lists missing_form_container, missing_email_field and/or missing_submit_button.

A draft or paused form stays unreachable until its status is set to active, which publishes this design. On a form that is already active the saved design is not public until the form is paused and set to active again. Saving a design does not consume AI credits.

Authorizations
AuthorizationstringRequired

API Token authentication

Path parameters
profileUuidstringRequired

Profile uuid parameter

Example: 550e8400-e09b-41d4-a716-400055000000
formUuidstringRequired

Form uuid parameter

Example: 550e8400-e09b-41d4-a716-400055000000
Body

Save the design of a form

contentstringRequired

HTML of the form design. After sanitizing it must still contain a form container (data-reach-form), an email input (data-reach-field="email") and a submit button (data-reach-submit).

Example: <form data-reach-form><input type="email" name="email" data-reach-field="email" /><button type="submit" data-reach-submit>Subscribe</button></form>
Responses
200

Success response

application/json

The stored version of a saved form design.

uuidstringOptionalExample: 2080cc86-e026-4f7b-9598-d4132f8c7c2f
pathstringOptional

Storage path of the template HTML, relative to the storage directory of this profile.

Example: forms/8f2c1b9e-1f4a-4a1e-9a2b-2f3c4d5e6f70/9a1b2c3d.html
edit_typestring · enum · nullableOptional

Whether the design was saved by hand or by the AI builder.

Example: manualPossible values:
created_atstring · date-timeOptionalExample: 2025-02-27T11:54:22Z
updated_atstring · date-timeOptionalExample: 2025-03-04T09:12:07Z
patch/api/reach/v1/profiles/{profileUuid}/forms/{formUuid}/template
PATCH /api/reach/v1/profiles/{profileUuid}/forms/{formUuid}/template HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 169

{
  "content": "<form data-reach-form><input type=\"email\" name=\"email\" data-reach-field=\"email\" /><button type=\"submit\" data-reach-submit>Subscribe</button></form>"
}
{
  "uuid": "2080cc86-e026-4f7b-9598-d4132f8c7c2f",
  "path": "forms/8f2c1b9e-1f4a-4a1e-9a2b-2f3c4d5e6f70/9a1b2c3d.html",
  "edit_type": "manual",
  "created_at": "2025-02-27T11:54:22Z",
  "updated_at": "2025-03-04T09:12:07Z"
}

Last updated

Was this helpful?