POST api/Zone/{zone_handle}/Redirection?user={user}
Create a new redirection on a zone
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| zone_handle |
Handle of zone |
string |
Required |
| user |
Optional user handle - if empty logged in user will be used |
string |
None. |
Body Parameters
New redirection details
RedirectionBase| Name | Description | Type | Additional information |
|---|---|---|---|
| UrlOrigin |
Url origin |
string |
None. |
| UrlDestination |
Url destination |
string |
None. |
| Type |
Redirection type: |
integer |
Matching regular expression pattern: 0|1|2|3|4|5|6 |
| Active | boolean |
None. |
|
| Title | string |
None. |
|
| MetaKeyword |
Comma seperated list of meta key words |
string |
None. |
| MetaDescription |
Meta description |
string |
None. |
| Relative |
Is relative |
boolean |
None. |
Request Formats
application/json, text/json
{
"UrlOrigin": "sample string 1",
"UrlDestination": "sample string 2",
"Type": 3,
"Active": true,
"Title": "sample string 5",
"MetaKeyword": "sample string 6",
"MetaDescription": "sample string 7",
"Relative": true
}
application/xml, text/xml
<RedirectionBase xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Zone"> <Active>true</Active> <MetaDescription>sample string 7</MetaDescription> <MetaKeyword>sample string 6</MetaKeyword> <Relative>true</Relative> <Title>sample string 5</Title> <Type>3</Type> <UrlDestination>sample string 2</UrlDestination> <UrlOrigin>sample string 1</UrlOrigin> </RedirectionBase>
application/x-www-form-urlencoded
Response Information
Resource Description
New redirection on success
Collection of errors on failure
Return codes
200 - ok
400 - bad request
401 - unauthorized
404 - not found
500 - internal server error
511 - object has expired
513 - quota exceeded
525 - object already exists
530 - invalid attribute value
712 - permission denied on domain
714 - The primary NS is not Namebay's
735 - must be a sub-domain
| Name | Description | Type | Additional information |
|---|---|---|---|
| Handle |
Redirection handle |
string |
None. |
| CreatedOn |
Created on |
date |
None. |
| HitsYesterday |
Number of hits yesterday |
integer |
None. |
| UrlOrigin |
Url origin |
string |
None. |
| UrlDestination |
Url destination |
string |
None. |
| Type |
Redirection type: |
integer |
Matching regular expression pattern: 0|1|2|3|4|5|6 |
| Active | boolean |
None. |
|
| Title | string |
None. |
|
| MetaKeyword |
Comma seperated list of meta key words |
string |
None. |
| MetaDescription |
Meta description |
string |
None. |
| Relative |
Is relative |
boolean |
None. |
Response Formats
application/json, text/json
{
"Handle": "sample string 1",
"CreatedOn": "2025-12-12T19:14:13.2885711+01:00",
"HitsYesterday": 3,
"UrlOrigin": "sample string 4",
"UrlDestination": "sample string 5",
"Type": 6,
"Active": true,
"Title": "sample string 8",
"MetaKeyword": "sample string 9",
"MetaDescription": "sample string 10",
"Relative": true
}
application/xml, text/xml
<Redirection xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Zone"> <Active>true</Active> <MetaDescription>sample string 10</MetaDescription> <MetaKeyword>sample string 9</MetaKeyword> <Relative>true</Relative> <Title>sample string 8</Title> <Type>6</Type> <UrlDestination>sample string 5</UrlDestination> <UrlOrigin>sample string 4</UrlOrigin> <CreatedOn>2025-12-12T19:14:13.2885711+01:00</CreatedOn> <Handle>sample string 1</Handle> <HitsYesterday>3</HitsYesterday> </Redirection>