Delete host

This function removes a host from the cPanel account's /home/user/.ssh/known_hosts file.

Authorizations:
query Parameters
required
string or string

The hostname or IP address of the host to delete.

Example: host_name=host.example.com
port
integer >= 1
Default: 22

The SSH port to use.

Example: port=1234

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 --user=username KnownHosts delete host_name='host.example.com'

Response samples

Content type
application/json
{
  • "apiversion": 3,
  • "func": "delete",
  • "module": "KnownHosts",
  • "result": {
    • "data": null,
    • "errors": null,
    • "messages": null,
    • "metadata": { },
    • "status": 1,
    • "warnings": null
    }
}