I re-programmed the xml-api class and added a consistent method to use API1 and API2 functions along with some new functions.
The reason for this was because I really need the park and unpark domain functions. I searched this forum and found some solutions by using:
andPHP Code:api2_query($username, 'Park', 'park', $args)
However, the problem is that the “park a domain”-feature must be enabled for cPanel users to be able to use this, because API1 and API2 are collection of cPanel functions which require an account username. Documentation about API1 and API2 functions: "required string - user —> The user as whom you wish to call the function."PHP Code:api2_query($username, 'Park', 'unpark', $args)
I've this cPanel park-feature disabled to prevent users from messing up there parked domains thru there cPanel GUI. Instead a external order/billing GUI should manage parking and unparking domains (f.e. order a domain and park it directly afterwards, cancel a domain subscription and unpark it or to rearrange domains over multiple accounts; unpark and park), therefore I really need the park and unpark domain functions on a reseller/root level.
Is it possible to implement this in the XML-API collection?
WHM contains functions to manage this as well, which still works while the park-feature for cPanel users is disabled, so it’s probably possible.
Edit: Additional documentation research
* API version 1 (also known as API1), which is designed to generate output compatible with browsers. This API is used mainly to add, modify, or delete data on the server.
* API version 2 (also known as API2), which is also designed to generate output compatible with browsers. This API is used mainly to return data.
This means park and unpark should be API1 functions. The documentation for park and unpark mention that these functions belong to API2 (see documentation). Threads about park and unpark in this forum mention it should be API1. I tested both without succes.



LinkBack URL
About LinkBacks
Reply With Quote





