getAccountInfo()
Allows to retrieve all attributes of a given account. To be found the account is to belong to the customer that authenticated the request, unless trusted mode is used.Parameters:
- i_account (integer) or account's username (string). Required this or username.
- username - username to login to Account's selfcare interface. String. Required this or i_account.
Returns:
All the attributes of the account in a form of structure. The account's attributes are identical to input parameters of the createAccount() function.
Sensitive fields with password-related information e.g. web_password, voip_password, vm_password are not returned.
Parameters:
- i_account (integer) or account's username (string). Required this or username.
- username - username to login to Account's selfcare interface. String. Required this or i_account.
Returns:
All the attributes of the account in a form of structure. The account's attributes are identical to input parameters of the createAccount() function.
Sensitive fields with password-related information e.g. web_password, voip_password, vm_password are not returned.
Trusted mode
This function supports trusted mode in which case any account of any customer can be queried.
----
Notes
For historical reasons the function returns negative number for positive balance and positive number for the negative balance. Client-side code needs to handle this condition.
Example of how to get account info via CURL tool:
curl -k --digest -u CustomerA-Web-Login:CustomerA-API-password -d '<?xml version="1.0"?> <methodCall> <methodName>getAccountInfo</methodName> <params><param><value><struct> <member><name>i_account</name> <value><int>3</int></value> </member> </struct></value></param></params> </methodCall>' https://your.environment.address.com/xmlapi/xmlapi
Folder with examples for different languages:
https://support.sippysoft.com/support/solutions/categories/107132/folders/176917