When we were hired to help develop mobile applications for Alizee, it quickly turned out that the portals system the company used will not met all the requirements. This is when we get a request to build first module of the vPortals stack: online payment website for Agents and Resellers. It quickly turned out that this recharge module needs extending and in time from these two e-commerce modules a fully featured portals stack emerged.
Problems to solve
Portals needed to support online payments with multiple of methods, like PayPal, PaySafeCard, Credit Cards and more, some of them were local payment providers with no much of an API documentation
Three types of users had to be supported: retail clients, agents and resellers, where every type should see a basically different portal
Resellers are working on huge sets of data, called tariffs, which can have more than 40 thousand rows. They should be able to easily upload such data and manipulate them from within the portal.
Portals should recognize client's location and provide appropriate VoIP account, apply appropriate charges and display appropriate data.
There had to be a very thick security layer, as the VoIP business is full of frauds, hackers and unfair clients.
With our e-commerce stack written in Laravel PHP, we deployed that framework to extend it. We wrote our modules to be type-safe, test-covered PHP7 and delegated heaviest tasks to third party services, like Redis database and ElasticSearch. We have also built a backend for manipulating large datasets, deployed a complex queue jobs engine in Redis and rewritten our connectors to take data (and cache them) directly from SoftSwitch, instead of using slow vendor API.
We secured servers with custom designed iptables rules, fail2ban, interconnected them with VPN, added additional sms registration confirmations and more.
We used geolocation database to provide localized content and recognize what services we should enable for given user and developed portals for each type of user separately, so they could be scaled and deployed appropriately.
Currently our portals are successfuly used in several production environments, requiring very little support and experiencing no performance issues. We are still developing new features for them and write additional connectors, which in near future will allow them to stand as a fully independent, open source based platform for VoIP providers.