The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Automatically Creating cPanle User Using API

Discussion in 'cPanel Developers' started by c0mgu1, Nov 9, 2010.

  1. c0mgu1

    c0mgu1 Registered

    Joined:
    Nov 9, 2010
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Hello,

    I am using XML APIs for creating cPanel User in WHM (createacct)

    (1) I want to create a new user account with out passing username and WHM is able to generate a username based on the passed domain name
    (2) And based on Domain Name I want to get the username which is automatically created by WHM

    Can any one help me on how to do that I am using 11.26 WHM

    Regards
    c0mgu1
     
  2. cPanelDavidN

    cPanelDavidN Integration Developer
    Staff Member

    Joined:
    Dec 17, 2009
    Messages:
    571
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    Hi c0mgu1,

    The XML-API function createacct will not perform the action you desire. You must pass a username when making your request. The parsing that you describe on WHM's Create Account page is provide by Javascript served from WHM.

    Your script will need to parse a valid username from the domain before making the XML-API call.

    Regards,
    -DavidN
     
Loading...

Share This Page