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.

Problem creating accounts - API

Discussion in 'cPanel Developers' started by danielati, Sep 24, 2015.

  1. danielati

    danielati Active Member

    Joined:
    Nov 7, 2011
    Messages:
    31
    Likes Received:
    1
    Trophy Points:
    6
    cPanel Access Level:
    Website Owner
    Hi,

    I use API to create accounts with PHP. This week I noticed that the account creation status is different.
    It is appearing before the following account status:

    Code:
    Password is 'useracct' has been changed.
    Id: TQ: TaskQueue: 0000
    ----- BEGIN RSA PRIVATE KEY -----
    SDFJLJljflJLJlhjHhLHljhlJHLgJHGjughjjlkJLKjlkJKLjLKJKLjllkjlJlkjLKJLLjlkJKLjlJLJHGJgJGjgJGjgJgjGJgjGJgJGJHGJFDFDSDFJLJljflJLJlhjHhLHljhlJHLgJHGjughjjlkJLKjlkJKLjLKJKLjllkjlJlkjLKJLLjlkJKLjlJLJHGJgJGjgJGjgJgjGJgjGJgJGJHGJFDFDSDFJLJljflJLJlhjHhLHljhlJHLgJHGjughjjlkJLKjlkJKLjLKJKLjllkjlJlkjLKJLLjlkJKLjlJLJHGJgJGjgJGjgJgjGJgjGJgJGJHGJFDFDSDFJLJljflJLJlhjHhLHljhlJHLgJHGjughjjlkJLKjlkJKLjLKJKLjllkjlJlkjLKJLLjlkJKLjlJLJHGJgJGjgJGjgJgjGJgjGJgJGJHGJFDFDSDFJLJljflJLJlhjHhLHljhlJHLgJHGjughjjlkJLKjlkJKLjLKJKLjllkjlJlkjLKJLLjlkJKLjlJLJHGJgJGjgJGjgJgjGJgjGJgJGJHGJFDFD
    ----- END RSA PRIVATE KEY -----
    
    What is this? Before I created the account and did not appear this ...

    I use the port '2087'.

    I read the status of the account creation through the command "new SimpleXMLElement ()". But I have the following log:

    Code:
    PHP Warning: SimpleXMLElement :: __ construct (): Entity: line 1: parser error: Start tag expected, < not found in /home/useracctlocal/public_html/createacct.php on line 338
    PHP Warning: SimpleXMLElement :: __ construct (): Password is "useracct" has been changed. in /home/useracctlocal/public_html/createacct.php on line 338
    PHP Warning: SimpleXMLElement :: __ construct (): ^ in /home/useracctlocal/public_html/createacct.php on line 338
    PHP Fatal error: Uncaught exception 'Exception' with message 'String could not be parsed XML' in /home/useracctlocal/public_html/createacct.php:338
    Stack trace:
    __construct('Password for \xE2\x80...') ">
    # 0 /home/useracctlocal/public_html/createacct.php(338): SimpleXMLElement -> __ construct ('Password for \ XE2 \ x80 ...')
    # 1 /home/useracctlocal/public_html/createacct.php(170): include ('/ home / useracctlocal ...')
    # 2 {main}
    
    
    thrown in /home/useracctlocal/public_html/createacct.php on line 338

    Code:
    PHP Code:
    $acct = array( 'username' => $cp_user, 'password' => $cp_passw, 'domain' => $domain, 'contactemail' => $email, 'plan' => $plan, 'mxcheck'=>"local");
    
    $account = $xmlapi->createacct($acct);
    
    $xml2 = new SimpleXMLElement($account); // line 338
    
    
    Please can anyone help me?

    Thank you
     
    #1 danielati, Sep 24, 2015
    Last edited: Sep 24, 2015
  2. cPDavidN

    cPDavidN cPanel Developer
    Staff Member

    Joined:
    Mar 19, 2013
    Messages:
    42
    Likes Received:
    3
    Trophy Points:
    8
    cPanel Access Level:
    DataCenter Provider
    Hello,

    Thanks for contacting us. This could indicate any number of different conditions, and could be affected by a large number of variables. Could you open a ticket by emailing integrationATcpanel.net, or using https://tickets.cpanel.net/ and provide access to an affected server so we can investigate? (Please include a link to this forum thread so we can update the thread once we find the answer.)

    Thank you,

    David Nielson
    Integration Developer, cPanel
     
    #2 cPDavidN, Sep 24, 2015
    Last edited by a moderator: Sep 24, 2015
    danielati likes this.
  3. danielati

    danielati Active Member

    Joined:
    Nov 7, 2011
    Messages:
    31
    Likes Received:
    1
    Trophy Points:
    6
    cPanel Access Level:
    Website Owner
    Hello David, thank you for answering me.

    Before opening the ticket identified a change in my WHM.
    In Home »Server Configuration» Basic cPanel & WHM Setup is showing the following:

    - Removed - (please attach images to your posts)

    I think maybe that might be the cause of the log and I'm having as never before.

    Can you help me with that? I could not understand well how to proceed with the API TOKEN.

    API_TOKEN.jpg
     
    #3 danielati, Sep 24, 2015
    Last edited by a moderator: Sep 24, 2015
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    653
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    That issue is discussed at:

    https://forums.cpanel.net/threads/pushbullet-default-settings.500771/

    However, I don't believe it's related to your issue so you may want to proceed with opening a ticket. Post the ticket number here so we can update this thread with the outcome.

    Thank you.
     
Loading...

Share This Page