Contact update
Changes a contact's details and statuses.
Request
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<epp xmlns="urn:ietf:params:xml:ns:epp-1.0">
<command>
<update>
<contact:update xmlns:contact="urn:ietf:params:xml:ns:contact-1.0">
<contact:id>EXAMPLE-1-C1</contact:id>
<contact:add>
<contact:status s="clientUpdateProhibited"/>
</contact:add>
<contact:chg>
<contact:email>new@example.com.ua</contact:email>
</contact:chg>
</contact:update>
</update>
<clTRID>EXAMPLE-1-cupd-0001</clTRID>
</command>
</epp>
add and rem carry statuses; chg carries the data.
How a postal block is applied here
This server merges a <contact:postalInfo> in <chg> field by field into the block of that type it already holds. A field you leave out keeps its stored value; a field you send replaces it. The int and loc blocks are independent — changing one does not touch the other.
Send the complete block anyway. Not every registry merges: in some zones a partial block replaces the stored one, so a change that is safe here can drop a registrant's street address in the zone — behind a 1000. Read the contact with info, change what you need in the block it returns, and send the whole thing back.
That advice is worth the extra bytes. The failure it prevents is silent, and what it destroys is somebody's registration data.
Clearing a field
org,streetandspare optional in the schema, so an empty element is valid and clears them.name,cityandccare not optional: an empty one is schema-invalid and comes back as a bare2001that names no element — a confusing answer whose cause is simply that these three must always have a value.- Clearing a phone number is not done with an empty element. Ask before you rely on a particular form: it differs by zone, and in some an empty
<contact:voice/>is accepted with1000while changing nothing at all.
Here is how that looks together: the organisation is cleared with an empty element, and the rest of the postal block is sent whole, as the section above advises.
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<epp xmlns="urn:ietf:params:xml:ns:epp-1.0">
<command>
<update>
<contact:update xmlns:contact="urn:ietf:params:xml:ns:contact-1.0">
<contact:id>EXAMPLE-1-C1</contact:id>
<contact:chg>
<contact:postalInfo type="int">
<contact:name>Ivan Petrenko</contact:name>
<contact:org/>
<contact:addr>
<contact:street>12 Khreshchatyk</contact:street>
<contact:city>Kyiv</contact:city>
<contact:pc>01001</contact:pc>
<contact:cc>UA</contact:cc>
</contact:addr>
</contact:postalInfo>
</contact:chg>
</contact:update>
</update>
<clTRID>EXAMPLE-1-cupd-0002</clTRID>
</command>
</epp>
Statuses
You may add and remove your own: clientUpdateProhibited, clientDeleteProhibited, clientTransferProhibited. The server* ones are the registry's — a command carrying one is refused whole, so a single server* status in a batch takes the legitimate half of the change with it.
As with domains, clientUpdateProhibited blocks updates, and the only command that can lift it is one whose sole content is its removal.
Who it affects
A contact referenced by several domains is one object. An update made for one customer rewrites the registration data of every domain that references it — which is the reason not to share contacts between unrelated customers.
What the server refuses, in its own words
Each refusal arrives as a result code and a sentence in <result><msg>, in the shape Commands and responses shows. The sentence is translated into the language you chose at login where a translation exists, and the lang attribute says which language you are being given. Branch on the code, never on the sentence — the code is the contract, the wording is not.
| Code | What the message says |
|---|---|
2003 | A postal address (contact:postalInfo) is required |
2005 | Country code must be 2 letters |
2005 | Invalid email address |
2304 | A domain that references this contact is under an operator freeze |
2304 | Contact status prohibits update |
2306 | An operator may show contact data only together with the evidence of consent to its publication |
2306 | At most 3 street lines |
2400 | Internal error |
2400 | The consent to publication could not be recorded, so nothing was changed; retry the command |
Result codes
| Code | When |
|---|---|
1000 | applied |
2001 | schema-invalid — most often an empty name, city or cc |
2005 | Cyrillic in an int block, a malformed e-mail or phone |
2303 | no such contact |
2304 | a status prohibits it |
2306 | policy — a weak transfer code, or a server* status you may not set |
On this page