Zm_Account is a class which allows to manage Zimbra accounts via SOAP
You may create, modify, rename, delete and get the attributes of a Zimbra account using this class
For the usage examples of all class methods check the source code of test.php
| package |
ZimbraSoapPhp |
|---|
accountExists(string $idOrNameAccount, string $type = "auto") : boolean
stringaccount id or account name
stringvalue of the account (auto, name, id)
booleanexists
addAccountAlias(string $idOrNameAccount, string $alias, string $type = "auto") : array
stringaccount id or account name
stringaccount alias
stringvalue of the account (auto, name, id)
arrayinformations
createAccount(string $name, string $password, array $attrs = array()) : string
stringaccount name
stringpassword
arrayan optional array containing the account attributes to be set
stringthe new account's id
deleteAccount(string $idOrNameAccount, string $type = "auto") : array
stringaccount id or account name
stringvalue of the account (auto, name, id)
arrayinformations
expireAccountSessions(string $idOrNameAccount, string $type = "auto") : array
stringaccount id or account name
stringvalue of the account (auto, name, id)
arrayinformations
fetchAccounts(string $ldapQuery, array $attrList, string $nameDomain = null) : array
| author |
Marc Lamouche marc.lamouche@ined.fr |
|---|
stringLDAP-style filter string (RFC 2254)
arraynames of requested attributes
stringdomain name to restrict search request
arrayinformations for accounts as specified in $ldapQuery
getAccountAliases(string $idOrNameAccount, string $type = "auto") : array
stringaccount id or account name
stringvalue of the account (auto, name, id)
arrayaliases
getAccountCos(string $idOrNameAccount, string $returnType = "NAME", string $type = "auto") : string
stringaccount id or account name
stringget the COS ID or NAME
stringvalue of the account (auto, name, id)
stringCOS id or name
getAccountId(string $name) : string
stringaccount name
stringaccount id
getAccountInfo(string $idOrNameAccount, string $type = "auto") : array
stringaccount id or account name
stringvalue of the account (auto, name, id)
arrayinformations
getAccountOption(string $idOrNameAccount, string $optName, integer $multisingle = ATTR_SINGLEVALUE, string $type = "auto") : string
stringaccount id or account name
stringname of the option to get
integer(ATTR_SINGLEVALUE, ATTR_MULTIVALUE)
stringvalue of the account (auto, name, id)
stringoption
getAccountOptions(string $idOrNameAccount, string $type = "auto") : array
stringaccount id or account name
stringvalue of the account (auto, name, id)
arrayoptions
getAccountStatus(string $idOrNameAccount, string $type = "auto") : string
stringaccount id or account name
stringvalue of the account (auto, name, id)
stringstatus
getAllAccounts(string $idOrNameDomain, string $type = "auto") : array
| deprecated |
it may take a long time to complete and fail on servers with lots of accounts use fetchAccounts instead |
|---|
stringdomain id or domain name
stringvalue of the domain (auto, name, id)
arrayinformations for all accounts
getCosId(string $name) : string
stringthe COS name
stringCOS id
modifyAccount(string $idOrNameAccount, array $attrs = array(), string $type = "auto") : array
stringaccount id or account name
arrayan array containing the account attributes to be set
stringvalue of the account (auto, name, id)
arrayinformations
removeAccountAlias(string $idOrNameAccount, string $alias, string $type = "auto") : array
stringaccount id or account name
stringaccount alias
stringvalue of the account (auto, name, id)
arrayinformations
renameAccount(string $idOrNameAccount, string $newName, string $type = "auto") : array
stringaccount id or account name
stringnew account name
stringvalue of the account (auto, name, id)
arrayinformations
setAccountCos(string $idOrNameAccount, string $cosName, string $type = "auto") : array
stringaccount id or account name
stringthe COS name
stringvalue of the account (auto, name, id)
arrayinformations
setAccountPassword(string $idOrNameAccount, string $password, string $type = "auto") : array
stringaccount id or account name
stringpassword
stringvalue of the account (auto, name, id)
arrayinformations
setAccountStatus(string $idOrNameAccount, string $status, string $type = "auto") : array
stringaccount id or account name
stringthe status (active, maintenance, pending, locked, closed)
stringvalue of the account (auto, name, id)
arrayinformations