mileskasce.blogg.se

Cpanel api
Cpanel api




cpanel api cpanel api

API2, on the other hand, always returns a Perl hash structure. Since API1 was designed for use by a browsable interface, it is not out of the ordinary for an API1 function to generate a snippet of HTML**. However, this is the exception to the rule and wouldn’t occur within a cPanel end-user interface. In various parts of the product, that output is suppressed or redirected due to the context of its usage. Because of this, API1 calls print their output directly to STDOUT. It most cases, if a particular function exists in both API1 and API2, we recommend using API2.ĪPI1 was originally designed to be a front-end-only API for use in cPanel pages. It is not uncommon for a module of the same name, present in both API1 and API2, to have different functions. Both API1 and API2 have their particular modules (and their functions) due, in large part, to the organic growth of the cPanel & WHM product. Sometimes, I hear the opposite, that all API2 module and functions are available in API1. The second common misconception is is that all API1 modules (and their functions) are available in API2. Active development has stopped, but API1 is maintained for bugs, security, and (as necessary) forward compatibility. API1 is considered fully matured at this point in time. Both versions of the API were concurrently developed for several years. It is true that API1 was the first publicly available API in cPanel however, development on API2 did not occur after API1. API1 and API2 are not ancestrally related. The first common misconception is that API1 begat API2. There are two common, false assumptions about API1 and API2 that confuse many newcomers to cPanel development. API1 modules are listed here and API2 modules are listed here. For instance, API2’s ‘Email’ module contains a function called ‘listpopswithdisk’ that will list all the details for all of the pop email accounts associated with a cPanel username. Within each module, there is a set functions. In fact, every cPanel interface (i.e., all themes, branding, and pages served in a descendant direct of $server/base/frontend/ ) use these APIs alone to present and alter the end-user’s environment.ĪPI1 and API2 each have their own set of modules*. These APIs are used throughout the cPanel interface. There are two APIs that affect the cPanel user space: API1 and API2. In this post, we’ll review the various APIs associated with cPanel and WHM and how you can use them in your own development. Our APIs are used by the cPanel developers when designing new features and interfaces but are also available to 3rd-party developers. APIs allow developers to perform actions (functions) that source and manipulate data related to cPanel accounts and system utilities. Application Programming Interfaces (APIs) are fundamental to the cPanel & WHM product.






Cpanel api