Paper Lantern for cPanel accounts is being retired this year. Find out more »
cPanel & WHM Version 102 has been released, and brings a slew of great updates. Take a look at what is included, and then upgrade today!

Add API method to get an account transfer status

Monarobase shared this idea 24 days ago
Already Exists

As a web-hosting provider, I would like to have an API method to get the status of an account transfer. so that I can reliably know if an account transfer succeeded or not.

Currently when you launch an account transfer with the API you can check when the session has completed and access to logs of the transfer but there is no API method to tell if the account transfer succeeded.

cPanel uses a SQLLite database to storee this information ( /var/cpanel/transfer_sessions/whmxfer.sqlite) but this database is not accessible from the API.

The logs are not a reliable source as they do not specify explicityly when an account fails. When the transfer succeeds without warnings the logs currently contain :

Account “username”: Success

When if finishes with non fatal warnings it contains :

Account “username”: Warning

But when it fails it contains :

Account “username”: Message that changes depending on the error

I'm not sure what the point of being able to launch an account transfer with the API if there is no way to know if it succeeds.

Please provide an API method that contains a list of accounts in a transfer session with their status. In WHM we have :

TRANSFER: 0 completed, 0 had warnings, and 1 failed.
RESTORE: 0 completed, 0 had warnings, and 1 failed
So adding this information to an API method shouldn't be complicated.

Replies (1)


Does the get_transfer_session_state API help you?


No, get_transfer_session_state only says if a session has completed or not but does not say if there were any errors.

We ended up parsing the logs to get this information it's a shame there isn't an explicit method to find out if an account migration succeeded or failed that does not require parsing the logs.

Leave a Comment
Attach a file