cPanel PHP API

PHP recommendations

GitHub OpenAPI
Business capability
Information Technology Management BC-600

Operations 15

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /EA4/get_php_recommendations Get recommended PHP versions · Get custom PHP recommendations #
Ask an LLM
“Which PHP versions does EasyApache 4 recommend for my server?”
“What PHP version should I choose for a new site?”
Tell an agent
Show the PHP version recommendations.
List the PHP versions EasyApache 4 suggests.
GET /php_get_handlers List PHP handlers on the system · Return PHP handlers #
Ask an LLM
“Which PHP handlers are available on my server?”
“Can I see the handler for a specific PHP version?”
Tell an agent
List the PHP handlers on the system.
Show the handler for PHP version {version}.
GET /php_get_impacted_domains List domains using a PHP configuration · Return PHP preconfigured domains #
Ask an LLM
“Which domains use the system default PHP version?”
“What domains inherit a particular PHP configuration?”
Tell an agent
List domains that use the system default PHP version.
Show domains inheriting PHP configuration {domain}.
GET /php_get_installed_versions List installed PHP versions · Return installed PHP versions #
Ask an LLM
“What PHP versions are installed on my server?”
“Which PHP versions can I choose for a domain?”
Tell an agent
List the installed PHP versions.
Show every PHP version installed on the server.
GET /php_get_system_default_version Get the system default PHP version · Return system default PHP version #
Ask an LLM
“What PHP version is set as the system default?”
“Which PHP version do new domains get by default?”
Tell an agent
Show the system default PHP version.
Tell me which PHP version is the default.
GET /php_get_vhost_versions Get PHP version of every virtual host · Return PHP version of all virtual hosts #
Ask an LLM
“What PHP version is each of my virtual hosts running?”
“Can I see the PHP version for all domains I control?”
Tell an agent
Show the PHP version of every virtual host.
List the PHP version for each of my domains.
GET /php_get_vhosts_by_version List virtual hosts using a PHP version · Return virtual hosts per PHP version #
Ask an LLM
“Which domains run PHP 7.4?”
“Can I find every virtual host on a given PHP version?”
Tell an agent
List the virtual hosts using PHP version {version}.
Show every domain running PHP {version}.
GET /php_ini_get_content Get a PHP version's php.ini contents · Return PHP version's php.ini file #
Ask an LLM
“What does the php.ini file look like for a PHP version?”
“Can I read the full php.ini for a PHP version?”
Tell an agent
Show the php.ini contents for PHP version {version}.
Get the full php.ini file for {version}.
GET /php_ini_get_directives List a PHP version's php.ini directives · Return PHP version's directives #
Ask an LLM
“Which php.ini directives are set for a PHP version?”
“What settings does a PHP version's php.ini contain?”
Tell an agent
List the php.ini directives for PHP version {version}.
Show the php.ini settings of {version}.
POST /php_ini_set_content Replace a PHP version's php.ini file · Update PHP version's php.ini file #
Ask an LLM
“Can I overwrite a PHP version's entire php.ini file?”
“How do I replace the full php.ini for a PHP version?”
Tell an agent
Replace the php.ini file for PHP version {version} with {content}.
Overwrite the full php.ini of {version} with {content}.
GET /php_ini_set_directives Set a PHP version's php.ini directives · Update PHP version's directives #
Ask an LLM
“Can I change one or more php.ini settings for a PHP version?”
“How do I set a php.ini directive value for a PHP version?”
Tell an agent
Set the php.ini directive {directive} for PHP version {version}.
Update the {directive} setting in {version}'s php.ini.
GET /php_set_handler Change a PHP version's handler · Update PHP version's handler #
Ask an LLM
“Can I switch a PHP version to CGI or suphp?”
“How do I change the handler a PHP version uses?”
Tell an agent
Set PHP version {version} to use handler {handler}.
Change {version}'s PHP handler to {handler}.
GET /php_set_session_save_path Set PHP's default session save path · Update PHP default save path #
Ask an LLM
“Can I change where PHP saves session files?”
“How do I set a custom session save path for PHP?”
Tell an agent
Set PHP's default session save path to {path}.
Change the PHP session save path to {path} and overwrite the existing one ({overwrite}).
GET /php_set_system_default_version Set the system default PHP version · Update default PHP version #
Ask an LLM
“How do I make a PHP version the default for new domains?”
“Can I change which PHP version new sites get automatically?”
Tell an agent
Set the system default PHP version to {version}.
Make {version} the default PHP version for new domains.
GET /php_set_vhost_versions Update a domain's PHP version · Update domain's PHP values #
Ask an LLM
“How do I set the PHP version for a domain in WHM?”
“Can I turn PHP-FPM on or off for specific virtual hosts?”
Tell an agent
Set the PHP version of {vhost} to {version}.
Change virtual host {vhost} to PHP {version} with PHP-FPM {php_fpm}.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/cpanel:cpanel-php-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

cpanel-php-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Cpanel PHP API
  version: 11.137.9999.106
  contact:
    email: cs@cpanel.net
    name: WebPros International, LLC
    url: https://cpanel.net/support/
  license:
    name: cPanel License
    url: https://cpanel.net/legal-notices/
  termsOfService: https://cpanel.net/legal-notices/
  x-api-evangelist-provenance: 'Harvested verbatim from cPanel''s developer portal on 2026-09-05 via the MCP tool get-full-api-description at https://api.docs.cpanel.net/mcp. ONE mechanical change was made before storage: example values containing PEM private-key or certificate blocks, and AWS-access-key-shaped example strings, were replaced with REDACTED_* placeholders so the file can be stored in a public git repository without tripping secret scanning. No path, operation, parameter, schema or description was altered, added or removed.'
  description: 'Operations tagged PHP across 2 of this provider''s published API definitions: cpanel-uapi-openapi.yml, cpanel-whm-api-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- description: A server running cPanel.
  url: https://{host}:{port}/execute
  variables:
    host:
      default: cpanel-server.tld
      description: The hostname of a server running cPanel.
    port:
      default: '2083'
      description: The cPanel port.
- description: A server running WHM.
  url: https://{host}:{port}/json-api
  variables:
    host:
      default: whm-server.tld
      description: The hostname of a server running WHM.
    port:
      default: '2087'
      description: The WHM port.
security:
- BasicAuth: []
tags:


# --- truncated at 32 KB (68 KB total) ---
# Full source: https://artifacts.apis.io/cpanel/openapi/cpanel-php-api-openapi.yml