metaregistrar / php-epp-client

Object-oriented PHP EPP Client
https://www.metaregistrar.com/docs/
MIT License
210 stars 153 forks source link

[2001 Command Syntax Error] Trying to register a contactperson #247

Closed Jeroenhulshof closed 4 years ago

Jeroenhulshof commented 4 years ago

Hi Metaregistrar,

I'm trying to register a contactperson, but the whatever i do results in a command syntax error. What is wrong? Also, where can i find documentation for PHP? Finding documentation for EPP/SIDN is terrible in my honest opinion.

I also want to note that i am connected and logged in to the sidn service.

Here's the code:

$contactInfo = new eppContact(
                new eppContactPostalInfo(
                    'Test name',
                    'Amsterdam',
                    'NL',
                    null,
                    'Teststreet',
                    'Amsterdam',
                    '1800AB',
                    'LOC'
                ),
                'testemail@gmail.com',
                '+31.12345678'
            );
            $contactInfo->setPassword('');

            $request = new sidnEppCreateContactRequest($contactInfo);

Result in a die dump:

<?xml version="1.0" encoding="UTF-8"?>
    <epp xmlns="urn:ietf:params:xml:ns:epp-1.0">
      <response>
        <result code="2001">
          <msg>Command syntax error</msg>
        </result>
        <trID>
          <clTRID>XXX</clTRID>
          <svTRID>SIDN</svTRID>
        </trID>
      </response>
    </epp>
metaregistrar commented 4 years ago

Hello,

I can tell you immediately what is wrong, because we ourselves have had this same problem last week. Somehow, SIDN requires the password for a new contact to be set. So you have to specify a password. It is not used anywhere, but it is just required.

Jeroenhulshof commented 4 years ago

It is fixed. Thanks for the quick response. This issue can be closed.