'How to validate domain EPP codes?

I'm trying to find a way to automate our company's domain transfer process, and one of the first steps requires validating the domain's EPP code before we initiate the actual transfer.

Currently, we're having to login to our domain registrar and manually use their domain EPP validation tool. They don't provide any API access for this and setting up what would essentially be a macro to automatically log in and run the tool is too fragile for our requirements. The code for their tool is closed source so I'm unable to see how they're validating the EPP codes.

Is there any other method for validating domain EPP codes? I've searched StackOverflow and Google but have been unable to find any information on how to do this.



Solution 1:[1]

By "EPP code," do you mean the temporary transfer auth codes that registrars usually send via email (or show in their web UIs)?

For reference: https://en.wikipedia.org/wiki/Auth-Code

(EPP codes can also be these status codes, fwiw: https://www.icann.org/resources/pages/epp-status-codes-2014-06-16-en)

I'm also not quite following what you mean by "validating" the codes?

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Case