Create a URL redirect

POST

Add a new URL redirection rule to a site.

This endpoint allows you to define a source path (fromUrl) and its corresponding destination path (toUrl), which will dictate how traffic is rerouted on your site. This is useful for managing site changes, restructuring URLs, or handling outdated links.

Required scope: sites:write

Path parameters

site_idstringRequired

Unique identifier for a Site

Request

This endpoint expects an object.
fromUrlstringOptional

The source URL path that will be redirected.

toUrlstringOptional

The target URL path where the user or client will be redirected.

Response

Request was successful

idstringOptional

The ID of the specific redirect rule

fromUrlstringOptional

The source URL path that will be redirected.

toUrlstringOptional

The target URL path where the user or client will be redirected.