How to create a Plesk XML API access token and how to use it for XML API passwordless authentication?

Follow

Comments

1 comment

  • Avatar
    Darko Bazulj

    when I run next command to give additional admin API access I get error.
    Additonal plesk admin <client-admin> exists and can normally login to plesk administration.

    # command

    curl -kLi -H "Content-Type: text/xml" -H "KEY: 7t67t87ym8y8yym9ym87y88yhd" -H "HTTP_PRETTY_PRINT: TRUE" -d @api.rpc https://x.x.x.x:8443/enterprise/control/agent.php

    # error

    HTTP/2 200
    cache-control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
    pragma: no-cache
    content-type: text/xml;charset=UTF-8
    expires: Mon, 26 Jul 1990 05:00:00 GMT
    last-modified: Fri, 16 Sep 2022 19:27:42 GMT
    p3p: CP="NON COR CURa ADMa OUR NOR UNI COM NAV STA"
    x-frame-options: SAMEORIGIN
    x-xss-protection: 1; mode=block
    date: Fri, 16 Sep 2022 19:27:43 GMT

    <?xml version="1.0" encoding="UTF-8"?>
    <packet version="1.6.9.1">
      <secret_key>
        <create>
          <result>
            <status>error</status>
            <errcode>1013</errcode>
            <errtext>Can not find client 'client-admin'</errtext>
          </result>
        </create>
      </secret_key>
    </packet>

    0
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request