It depends.

The canonical form of a DPID is without a hyphen. Hence DPIDs should be used, in DDEX messages, without hyphens:

<PartyId>PADPIDA3897722461G</PartyID>
<PartyId>PA-DPIDA-3897722461-G</PartyID>

However, for human consumption hyphens may be added. Therefore, the HTML/PDF export of the DPID registry contains hyphens whereas the XML export does not.