Skip to main content
Preferred for edits to existing routes, including the built-in starter homepage at /. Match blocks are copied exactly from the current route code (see get_space_route).

Parameters

string
required
Route path of the existing route to edit, e.g. ‘/about’ or ‘/api/hello’.
object[]
required
Edit operations applied in order: replace_block, insert_after, insert_before, delete_block, append_line. Same schema as edit_file.
string
default:""
Optional visibility override for page routes. Omit to preserve current visibility. API routes are always public.