Update fields of a route
Changes only the fields you send; an omitted field is left alone, and null clears a nullable field back to its default. To make a redirect, send purpose: "redirect" and a root-relative redirectTo in the same call. A redirect cannot also carry contentKey, layout, experiment, nav or navLabel, and redirectTo / redirectStatus need purpose: "redirect". The check looks only at what you send, so a PATCH that sets redirectTo must repeat purpose: "redirect", even on a route that is already a redirect. The home page is …/routes/ (trailing slash). Other paths are sent without the leading slash, for example …/routes/blog/launch for /blog/launch. The change is staged to the draft — publish to make it live.
Request
- Base URL: https://api.dotsy.ai
- URL: https://api.dotsy.ai/api/v1/sites/{slug}/routes/{path}
- Auth: one of:
- HTTP bearer
- HTTP bearer
Path parameters
Site slug or site id (UUID). An old slug answers 301/308 and a site id 307 to the canonical slug path.
Percent-encode each segment; '/' may be sent raw or as %2F. Keys may contain '/'.
Request body
Example request
{
"title": "About us",
"layout": "layouts/main.html"
}Response
The updated route (staged).
Example response
{
"path": "/about",
"contentKey": "about.html",
"layout": "layouts/main.html",
"title": "About us",
"hint": "Changes staged to draft — call publish_site to go live."
}Changes
No recorded changes to this operation across all 1 revision of this API.