Our features site is undergoing a refresh! Be sure to explore the revamped site and discover our latest product roadmap launching here on Monday, March 18th.

Add API method to get an account transfer status

Monarobase shared this idea 2 years 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)

photo
1

Does the get_transfer_session_state API help you?

photo
1

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.

photo
Leave a Comment
 
Attach a file