Return WordPress site settings

This function retrieves a WordPress® instance's configuration.

Note:

  • You must install the WordPress Manager cPanel plugin to access this API function.
  • This function retrieves some data that the system stored during the WordPress installation. That data may not reflect the most recent user changes.
Authorizations:
query Parameters
id
required
string

The WordPress instance's unique ID.

Note:

You can retrieve an instance ID with the get_instances function.

Example: id=cPanel__Blogs__WordPressX.0.1528208546

Responses

Response Schema: application/json
apiversion
integer

The version of the API.

func
string

The name of the method called.

module
string

The name of the module called.

object

Request samples

uapi --output=jsonpretty \
  --user=username \
  WordPressInstanceManager \
  get_instance_by_id \
  id='cPanel__Blogs__WordPressX.0.1528208546'

Response samples

Content type
application/json
{
  • "apiversion": 3,
  • "func": "get_instance_by_id",
  • "module": "WordPressInstanceManager",
  • "result": {
    • "data": {
      • "addon_config": "/home/example/.cpaddons/cPanel::Blogs::WordPressX.0.yaml",
      • "addon_name": "cPanel::Blogs::WordPressX",
      • "addon_type": "modern",
      • "admin_url": "example.com/wp-login.php",
      • "admin_username": "admin",
      • "admins": [
        • {
          • "ID": 1,
          • "display_name": "admin",
          • "user_email": "admin@example.com",
          • "user_login": "admin",
          • "user_nicename": "admin",
          • "user_status": 0
          }
        ],
      • "autoupdate": true,
      • "autoupdate.core.has_filter": false,
      • "autoupdate.core.major": false,
      • "autoupdate.core.minor": true,
      • "available_version": "4.9.6",
      • "created_on": 1528208546,
      • "current_version": "4.9.5",
      • "db_name": "example_wp2",
      • "db_prefix": "wp",
      • "db_server": "localhost",
      • "db_type": "mysql",
      • "db_username": "example_wp",
      • "domain": "example.com",
      • "full_path": "/home/example/public_html",
      • "homedir": "/home/example",
      • "id": "cPanel__Blogs__WordPressX.0.1528208546",
      • "initial_install_version": "4.7.2",
      • "recent": 1,
      • "rel_path": " ",
      • "site_url": "example.com/wordpress"
      },
    • "errors": null,
    • "messages": null,
    • "metadata": { },
    • "status": 1,
    • "warnings": null
    }
}