Skip to content
Alex ALAVO.

Case study 05 · Payments · Backend · Energy

ÉnergiePay

Turns Mobile Money payment SMS into electricity top-ups, automatically and with full traceability.

Role
Design and full-stack development
Category
Payments · Backend · Energy
Stack
Laravel · React · TypeScript
Dashboard of payments, corrected codes and pending SMS
Filterable payment history

01 — Context

For a prepaid electricity operator, turning a Mobile Money payment into credit meant matching the amount, the customer reference and the meter account, despite mistyped references and duplicate messages.

02 — Problem

Mistyped references, duplicate SMS, flaky APIs: every payment needed a manual check.

03 — Solution

The platform receives payment SMS through an API, extracts the information and normalises references. Depending on the amount, it records an installation instalment or requests a SparkMeter top-up, stores the transaction and sends a confirmation. Managers follow operations, customers and anomalies from a dedicated interface.

04 — Features

  • Automatic payments

    Amount, payer, reference and transaction extracted from the SMS, top-up sent.

  • Normalised references

    Cleaning, reordering and matching against known sites.

  • Failure recovery

    Balance check after an API error and scheduled retries.

  • Installation fees

    Threshold-based classification, instalment tracking and individual exemptions.

  • Balance lookup

    From the web, by SMS or through a protected API.

  • Alerts and exports

    Low-balance alerts and filtered Excel exports.

06 — Architecture

  1. SMS gatewayMobile Money
  2. Laravel APIintake · parsing
  3. Domain servicespayments · references
  4. SparkMeter APImeter top-up
  5. Jobs · SMSconfirmations · alerts

A shared Laravel backend serves the React management interface (through Inertia) and the intake APIs.

Confirmations, syncs and retries are jobs or listeners; the database keeps every operation and its state so retries are possible.

07 — Technical challenges

  • Challenge

    Interpret irregularly typed references.

    Solution

    A parsing service with cleaning and matching rules; corrections logged with their reason.

  • Challenge

    Handle a payment whose API response is uncertain.

    Solution

    Same external ID reused, balance change checked and scheduled retry.

  • Challenge

    Import an existing SQL history.

    Solution

    Dedicated command with a dry-run mode, normalisation and duplicate checks.

08 — My contribution

  • Architecture and payment processing rules
  • Laravel backend and React / TypeScript interfaces
  • Data model, migrations and indexes
  • SparkMeter and SMS API integration
  • Dashboards, histories and exports
  • Permissions, tests and deployment pipeline

09 — Stack

Backend
PHP 8, Laravel 10, jobs, événements, planificateur
Frontend
React 19, TypeScript, Inertia.js, Tailwind CSS, TanStack Table
Data
MySQL, Laravel Excel
Integrations
API SparkMeter, API SMS
Delivery
PHPUnit, GitHub Actions, déploiement SSH

10 — Results

  • 3

    balance lookup channels: web, SMS and API

  • 0

    double credits after an API outage, thanks to the reused ID

Next case study1:1 DigitalPrepares manager–employee one-on-ones with AI and turns notes into a report signed off by both.