WHM API 1 - createacct
- Created by Sync User, last modified on Sep 29, 2014
Overview
This page contains the input variables, output variables, and examples in JSON and XML output formats for the createacct function.
The createacct function creates a hosting account and sets up its associated domain information.
Note
Icon
Parameters
| Input | Type | Description | |
|---|---|---|---|
| username | string |
The username for the account that you wish to create (for example, Note Icon Usernames must be eight characters or less, or, as of cPanel & WHM version 11.40, 16 characters or less if database prefixes are disabled. Also, usernames cannot start with a number, or the string
test. |
|
| domain | string | The domain name to assign to the account (for example, example.com). |
|
| plan | string | The package that you wish to apply to the new account (for example, reseller_gold). |
|
| pkgname | string | The name of a new package to be created based on the settings used (for example, reseller_new). |
|
| savepkg | boolean | This value determines whether to save the settings as a new package. A value of 1 will save the settings as a new package. |
|
| featurelist | string | The name of the feature list to be used when you create a new package (for example, no_ftp_100mb_gold). |
|
| quota | integer | The disk space quota, in megabytes. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited. |
|
| password | string | The password that you wish to assign to the new account (for example, p@ss!w0rd$123). |
|
| ip | string | This value determines whether the domain has a dedicated IP address. A value of y will flag the domain for a dedicated IP address. |
|
| cgi | boolean | This value determines whether the domain has CGI access. A value of 1 grants the domain CGI access. |
|
| frontpage | boolean |
This value determines whether the domain can install FrontPage extensions. A value of Note: Icon cPanel & WHM will ignore all Microsoft® FrontPage® settings and parameters if either of the following statements are true:
|
|
| dkim (optional) | boolean |
This value determines whether the domain has DKIM enabled. A value of Note: Icon This parameter does not follow the Enable DKIM on domains for newly created accounts setting in WHM'sTweak Settings interface (Home >> System Configuration >> Tweak Settings). If you wish to enable DKIM on this newly-created domain, set this parameter to a value of |
|
| spf (optional) | boolean |
This value determines whether the domain has SPF enabled. A value of Note: Icon This parameter does not follow the Enable SPF on domains for newly created accounts setting in WHM's Tweak Settings interface (Home >> System Configuration >> Tweak Settings). If you wish to enable SPF on this newly-created domain, set this parameter to a value of |
|
| hasshell | boolean | This value determines whether the domain has shell (SSH) access. A value of 1 grants shell access to the domain. |
|
| contactemail | string | Contact email address for the account (for example, user@example.com). |
|
| cpmod | string |
The name of the cPanel theme that is assigned to the domain (for example: Note Icon If no value is provided, the function will use the cPanel default theme (set in WHM in the Basic cPanel & WHM Setup interface). This behavior only applies to version 11.36+.
|
|
| maxftp | string | The maximum number of FTP accounts that the user can create. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited, unlimited, and null. |
|
| maxsql | string | The maximum number of SQL databases that the user can create. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited, unlimited, and null. |
|
| maxpop | string | The maximum number of email accounts that the user can create. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited, unlimited, and null. |
|
| maxlst | string | The maximum number of mailing lists that the user can create. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited, unlimited, and null. |
|
| maxsub | string | The maximum number of subdomains that the user can create. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited, unlimited, and null. |
|
| maxpark | string | The maximum number of parked domains that the user can create. Allowed values are: a number from 0 to 999999where a value of 0 is unlimited, unlimited, and null. |
|
| maxaddon | string | The maximum number of addon domains that the user can create. Allowed values are: a number from 0 to 999999 where a value of 0 is unlimited, unlimited, and null. |
|
| bwlimit | string | The bandwidth limit, in megabytes. This value must be a number from 0 to 999999, where a value of 0 is unlimited. |
|
| customip | string | This value specifies an IP address for the site. | |
| language | string | The language that you wish for the new account to use in the cPanel interface (for example, spanish-utf8). |
|
| useregns | boolean | This value determines whether the domain will use the registered nameservers for the domain instead of the ones configured on the server. A value of 1 will use the registered nameservers for the domain. |
|
| hasuseregns | boolean | If you set useregns to 1, you must set this value to 1. |
|
| reseller | boolean | This value determines whether you wish to grant reseller privileges to the account. A value of 1 will grant reseller privileges to the account. |
|
| forcedns | boolean | This value will overwrite an existing DNS Zone with this new account's information if one already exists. A value of 1 will overwrite an existing DNS zone with this new account's information. |
|
| mxcheck | string |
Determines how the server will handle incoming mail for this domain. This variable can be set to one of the following: Note Icon You will still need to use the WHM Edit MX Entry interface to configure the primary MX entry to point to the appropriate exchanger.
remote — The domain will not accept mail, instead sending it to the primary mail exchanger. Note: You will still need to use the WHM Edit MX Entry interface to configure the primary MX entry to point to the appropriate exchanger. |
|
| MAX_EMAIL_PER_HOUR | integer |
The maximum number of emails the account can send in an hour. This parameter's default value is unlimited. A value of Note Icon This variable is only accepted in cPanel & WHM Version 11.32 and later.
|
|
| MAX_DEFER_FAIL_PERCENTAGE | integer |
The percentage of failed or deferred email messages the account can send per hour before outgoing mail is rate-limited. This parameter's default value is unlimited. Note Icon This variable is only accepted in cPanel & WHM Version 11.32 and later.
|
|
| uid | string |
The user ID for a new account. This must be a numeral, not already associated with disk usage, and does not pre-exist on the machine. You must be logged in as the Note Icon This variable is only accepted in cPanel & WHM Version 11.32 and later.
|
|
| gid | string |
The group ID for a new account. This must be a numeral, not already associated with disk usage, and does not pre-exist on the machine. You must be logged in as the Note Icon This variable is only accepted in cPanel & WHM Version 11.34 and later.
|
|
| homedir | string |
The home directory (HOMEDIR) to be used for a new account. You must be logged in as the Note Icon This variable is only accepted in cPanel & WHM Version 11.34 and later.
|
|
| Output | Type | Description | |
| createacct | The container for the results from the createacct function. |
||
| result | The container for the results of the function. | ||
| options | The container for the domain options. | ||
| ip | string | IP address with which the the domain is associated (for example, 123.456.789.10). |
|
| nameserverX | string | The nameserver for the domain. The property of nameserver may be appended by an integer (x) between 1 and 5 (for example: nameserver1). |
|
| nameserveraX | string | IP address of the nameserver. The property of nameservera may be appended by an integer (x) between 1 and 5 (for example: nameservera1). |
|
| nameserverentryX | string | DNS name of the nameservers the namerservers are registered. The property of nameserverentry may appear appended by an integer (x) between 1 and 5 (for example: nameserverentry1). |
|
| rawout | string | Raw output of the account creation operation in HTML format. | |
Examples
| JSON | ||||
|---|---|---|---|---|
| Input URL |
https://hostname:2087/cpsess########/json-api/createacct |
|||
| Output |
|
|||
| XML | ||||
| Input URL |
https://hostname:2087/cpsess########/xml-api/createacct |
|||
| Output |
|
|||
WHM API 1 - createacct的更多相关文章
- easypanel api 文档
easypanel api 文档 Easypanel的api通信安全码在easypanel的服务器设置处设置. 接口名称有: add_vh 创建空间和修改空间 update_vh 暂停空间和恢复空间 ...
- 干货来袭-整套完整安全的API接口解决方案
在各种手机APP泛滥的现在,背后都有同样泛滥的API接口在支撑,其中鱼龙混杂,直接裸奔的WEB API大量存在,安全性令人堪优 在以前WEB API概念没有很普及的时候,都采用自已定义的接口和结构,对 ...
- 12306官方火车票Api接口
2017,现在已进入春运期间,真的是一票难求,深有体会.各种购票抢票软件应运而生,也有购买加速包提高抢票几率,可以理解为变相的黄牛.对于技术人员,虽然写一个抢票软件还是比较难的,但是还是简单看看123 ...
- 几个有趣的WEB设备API(二)
浏览器和设备之间还有很多有趣的接口, 1.屏幕朝向接口 浏览器有两种方法来监听屏幕朝向,看是横屏还是竖屏. (1)使用css媒体查询的方法 /* 竖屏 */ @media screen and (or ...
- html5 canvas常用api总结(三)--图像变换API
canvas的图像变换api,可以帮助我们更加方便的绘画出一些酷炫的效果,也可以用来制作动画.接下来将总结一下canvas的变换方法,文末有一个例子来更加深刻的了解和利用这几个api. 1.画布旋转a ...
- JavaScript 对数据处理的5个API
JavaScript对数据处理包括向上取整.向下取整.四舍五入.固定精度和固定长度5种方式,分别对应ceil,floor,round,toFixed,toPrecision等5个API,本文将对这5个 ...
- ES5对Array增强的9个API
为了更方便的对Array进行操作,ES5规范在Array的原型上新增了9个方法,分别是forEach.filter.map.reduce.reduceRight.some.every.indexOf ...
- javascript的api设计原则
前言 本篇博文来自一次公司内部的前端分享,从多个方面讨论了在设计接口时遵循的原则,总共包含了七个大块.系卤煮自己总结的一些经验和教训.本篇博文同时也参考了其他一些文章,相关地址会在后面贴出来.很难做到 ...
- 一百元的智能家居——Asp.Net Mvc Api+讯飞语音+Android+Arduino
大半夜的,先说些废话提提神 如今智能家居已经不再停留在概念阶段,高大上的科技公司都已经推出了自己的部分或全套的智能家居解决方案,不过就目前的现状而言,大多还停留在展厅阶段,还没有广泛的推广起来,有人说 ...
随机推荐
- apache 修改连接数(转)
1.先要修改最大连接数,必须了解Apache的MPM(Multi -Processing Modules,多道处理模块)Apache2.0中MPM分为3种(perfork.worker.event). ...
- (repost)在ARM Linux内核中增加一个新的系统调用
实验平台内核版本为4.0-rc1,增加一仅仅打印Hello World的syscall,最后我们在用户空间swi验证 实验平台内核版本为4.0-rc1,增加的系统调用仅仅是简单打印一个Hello Wo ...
- TCP/IP 协议(摘抄)
TCP/IP 协议 TCP/IP 是不同的通信协议的大集合. 协议族 TCP/IP 是基于 TCP 和 IP 这两个最初的协议之上的不同的通信协议的大集合. TCP - 传输控制协议 TCP 用于从应 ...
- google浏览器图标显示不正常怎么办
taskkill /f /im explorer.exe rem 清理系统图标缓存数据库 attrib -h -s -r "%userprofile%\AppData\Local\IconC ...
- 微信小程序支付步骤
http://blog.csdn.net/wangsf789/article/details/53419781 最近开发微信小程序进入到支付阶段,一直以来从事App开发,所以支付流程还是熟记于心的.但 ...
- [bash] 查找替换文件
写这个脚本也加深了对 bash 数组的理解. #!/bin/bash #2015-11-23 echo -e "说明:\n将文件放在/app/tmp_class目录下,保证该目录下没有其他文 ...
- linux安装gcc-c++
首先查看系统是否安装: gcc -v g++ -v c++ -v 没有安装则执行一键安装命令:#yum install gcc-c++ 如果直接执行:#yum install c++是安装 ...
- bootstrip 折叠菜单
body { font-family: "宋体"; font-size: 12px } .menu { height: 30px; background: #e6e6e6; mar ...
- express学习点滴- methodOverride
app.use(express.methodOverride());在app.js中可以看到这个中间件,去翻文档,几乎没有提到.一番寻找,整理如下. 作用是使用REST风格的http请求时,进行改写后 ...
- 浅谈MAIC 2016第二届移动应用(APP)创新大会
MAIC 2016第二届移动应用(APP)创新大会将于2016年12月在上海举办!MAIC一届比一届办的有质量,规模越大.今年也如约而至,预计今年MAIC规模逾2000人.大会以专业会议,创新应用展览 ...