POST api/Hosting/{hosting_handle}/Wordpress?updateHtaccess={updateHtaccess}
Create wordpress on the given hosting
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
hosting_handle |
Hosting object handle |
string |
Required |
updateHtaccess | boolean |
Default value is False |
Body Parameters
Body - the details of the wordpress to create
WordpressNewName | Description | Type | Additional information |
---|---|---|---|
Site |
Optional site to install the wordpress in |
string |
None. |
Alias |
Optional alias to install the wordpress with |
string |
None. |
HostingHandle |
Hosting handle - auto populated |
string |
None. |
DbName |
Name of wordpress database. A new database is created if this is left empty. |
string |
None. |
Dir |
Directory to deploy the wordpress |
string |
None. |
RootInstallDir |
Directory to install the root wordpress - default wp_root_install |
string |
None. |
Title |
Title of wordpress site |
string |
Required |
AdminUser |
Admin user name - default wp_admin |
string |
None. |
AdminEmail |
Admin email - default to user email |
string |
None. |
AdminPassword |
Password if supplied must have at least one alpha character, one numeric character, special character and a length between 6 and 20 |
string |
Matching regular expression pattern: ^(?=.*[0-9])(?=.*[a-zA-Z])(?=.*[é'(\-è_çà)=#{\[|\\@\]}$ù*,;:!£%µ?./§¤])[0-9a-zA-Zé'(\-è_çà)=#{\[|\\@\]}$ù*,;:!£%µ?./§¤]{6,20}$ Max length: 20 Min length: 6 |
Request Formats
application/json, text/json
{ "Site": "sample string 1", "Alias": "sample string 2", "HostingHandle": "sample string 3", "DbName": "sample string 4", "Dir": "sample string 5", "RootInstallDir": "sample string 6", "Title": "sample string 7", "AdminUser": "sample string 8", "AdminEmail": "sample string 9", "AdminPassword": "sample string 10" }
application/xml, text/xml
<WordpressNew xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Hosting"> <AdminEmail>sample string 9</AdminEmail> <AdminPassword>sample string 10</AdminPassword> <AdminUser>sample string 8</AdminUser> <Alias>sample string 2</Alias> <DbName>sample string 4</DbName> <Dir>sample string 5</Dir> <HostingHandle>sample string 3</HostingHandle> <RootInstallDir>sample string 6</RootInstallDir> <Site>sample string 1</Site> <Title>sample string 7</Title> </WordpressNew>
application/x-www-form-urlencoded
Sample not available.
Response Information
Resource Description
The wordpress object on success
Collection of errors on failure
Return codes
200 - ok
300 - ambiguous
401 - unauthorized
404 - not found
500 - internal server error
510 - object does not exist
513 - quota exceeded
525 - object already registered
803 - Invalid os for this operation
Name | Description | Type | Additional information |
---|---|---|---|
Id |
Wordpress id |
integer |
None. |
Site |
Optional site to install the wordpress in |
string |
None. |
Alias |
Optional alias to install the wordpress with |
string |
None. |
HostingHandle |
Hosting handle |
string |
None. |
Db |
Database used by wordpress |
Db |
None. |
Dir |
Directory where wordpress is installed |
string |
None. |
Title |
Title of wordpress site |
string |
None. |
AdminUser |
Admin user name |
string |
None. |
AdminEmail |
Admin email address |
string |
None. |
AdminPassword |
Admin password. Returned on creation only. |
string |
None. |
Response Formats
application/json, text/json
{ "Id": 1, "Site": "sample string 2", "Alias": "sample string 3", "HostingHandle": "sample string 4", "Db": { "Name": "sample string 1", "HostingHandle": "sample string 2", "User": "sample string 3", "Pwd": "sample string 4", "Type": "sample string 5", "Size": 6, "MaxSize": 7, "ServerId": 8, "DateCre": "2025-04-04T00:32:26.2215176+02:00", "DateReq": "2025-04-04T00:32:26.2215176+02:00", "Etat": "sample string 11", "UserLang": "sample string 12" }, "Dir": "sample string 5", "Title": "sample string 6", "AdminUser": "sample string 7", "AdminEmail": "sample string 8", "AdminPassword": "sample string 9" }
application/xml, text/xml
<Wordpress xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Hosting"> <AdminEmail>sample string 8</AdminEmail> <AdminPassword>sample string 9</AdminPassword> <AdminUser>sample string 7</AdminUser> <Alias>sample string 3</Alias> <Db> <DateCre>2025-04-04T00:32:26.2215176+02:00</DateCre> <DateReq>2025-04-04T00:32:26.2215176+02:00</DateReq> <Etat>sample string 11</Etat> <HostingHandle>sample string 2</HostingHandle> <MaxSize>7</MaxSize> <Name>sample string 1</Name> <Pwd>sample string 4</Pwd> <ServerId>8</ServerId> <Size>6</Size> <Type>sample string 5</Type> <User>sample string 3</User> <UserLang>sample string 12</UserLang> </Db> <Dir>sample string 5</Dir> <HostingHandle>sample string 4</HostingHandle> <Id>1</Id> <Site>sample string 2</Site> <Title>sample string 6</Title> </Wordpress>