Learn how to understand user and account management to design your application properly.
Users within Account
Voximplant application users are the end users of the application, and Voximplant developers can control each user account balance by setting the parent_accounting parameter to false (via the AddUser and SetUserInfo methods) or specifying this setting in the control panel (the Separate account balance checkbox) while creating/editing the app user.
It's possible to transfer funds from the developer account to an app user account and back using the TransferMoneyToUser method.
Independent Child Accounts
But let's imagine that a developer is building a Cloud PBX service where every company has its own account balance and controls users account balance (if required), while the developer has his or her developer account balance where they put funds to divide them up among the companies. For this type of service, Voximplant offers child accounts that can be created by the developer with the help of their parent account credentials. To create a child account, use the AddAccount method.
This functionality is disabled by default, and developers need to ask Voximplant team to enable it.
Child Accounts operates as standalone entities, they do not share applications, scenarios, and balance with each other. They, however, have access to the parent's applications and scenarios. Creating a child account is handy when you need to separate your customers, so each child account can represent each customer, but there will be only one parent account "to rule them all".
In terms of balance, you can use the TransferMoneyToChildAccount method to transfer funds from the developer account to child accounts. A child account, in its turn, can transfer funds to its user via the aforementioned TransferMoneyToUser method. See the picture below:
If a developer needs to withdraw funds from a user or child account balance and add it to his or her account balance, then the amount should be negative, otherwise – positive.
Thus, the chain of events for adding the funds will look like this: Developer's card / wire -> Developer account balance -> Child account balance (optional) -> App user account balance (optional).