Description

This function returns whether a specific role is currently enabled.


Examples




https://hostname.example.com:2087/cpsess##########/json-api/is_role_enabled?api.version=1&role=FTP




whmapi1 is_role_enabled role=FTP



{  
   "data":{  
      "enabled":"1"
   },
   "metadata":{  
      "version":1,
      "command":"is_role_enabled",
      "result":1,
      "reason":"OK"
   }
}



Parameters

ParameterTypeDescriptionPossible valuesExample
rolestring

Required.

The role to check the enabled status of.

This parameter is case-sensitive.


  • CalendarContact
  • DNS
  • FileStorage
  • FTP
  • MailLocal
  • MailReceive
  • MailSend
  • MySQL
  • Postgres
  • SpamFilter
  • WebDisk
  • Webmail
  • WebServer
FTP

Returns

ReturnTypeDescriptionPossible valuesExample
enabledBooleanWhether a role is enabled or disabled.
  • 0 — Disabled.
  • 1 — Enabled.
1