Set Website Aliases (WSM 4.5.7.0+ only)
Sets aliases for a given website, replacing any existing aliases in the process.
URL
/api/v1/website/[website_id]/aliases
HTTP Method
PUT
URL Parameters
Parameter |
Required |
Type |
Description |
---|---|---|---|
website_id |
true |
integer |
Specifies the website ID to set aliases for. |
PUT Parameters
PUT takes a JSON array of strings containing aliases. An empty array will remove all aliases.
Response Parameters
Returns a string indicating success/error.
Example: Set Website Aliases
Request
/api/v1/website/[website_id]/aliases
curl -kv \
-u api_ninja:ninja_password \
-X PUT \
-H 'Content-Type: application/json' \
-d '[ "www.example.com", "another.example.com" ]' \
https://172.31.1.172:4849/api/v1/website/1/aliases
Response
{"result":"success"}