Account Profile & Company Entity Module Documentation
π― User Roles & Key Capabilities
Section titled βπ― User Roles & Key Capabilitiesβ| Role | Primary Use Case | Key Capabilities |
|---|---|---|
| Customer Account Administrator | Corporate telecom self-service management. | View account balance, purchase additional DIDs, manage subscribed plans, and configure company profile. |
| Finance / Accounts Payable | Wallet replenishment & invoice payments. | Add funds via credit card / bank transfer, download official PDF invoices, and monitor transaction ledgers. |
| End Subscriber | Personal usage tracking. | Review outbound call history, check message logs, and inspect plan quota consumption. |
Module Code:
billing/client/account-profile
Route:/portal/settings
Backend Service:clientService.ts(ring2all-billing-api)
Database Table:customers
Brand Purity: 100% White-Label Compliant (Ring2All BSS)
Table of Contents
Section titled βTable of Contentsβ- Executive Summary & Corporate Identity
- Technical Architecture & Profile Sync
- Visual Interface & Screen Breakdown
- Company Details, Tax ID & Invoicing Address
- FormGrid Standardization & Action Bar Controls
- Diagnostic CLI & Operational Playbooks
- Domain Glossary
1. Executive Summary & Corporate Identity
Section titled β1. Executive Summary & Corporate IdentityβThe Account Profile & Company Entity module allows subscribers to manage their official corporate identity, authorized point-of-contact details, national tax registration numbers, and legal billing address used across all generated statements and PDF tax invoices.
+-------------------------------------------------------------------------------+| COMMERCIAL & OPERATIONAL IMPACT |+-------------------------------------------------------------------------------+| β’ Automated Tax Accuracy: Changes to company address and tax identification || are dynamically reflected on subsequent PDF invoices and tax receipts. || β’ Emergency Notice Dispatch: Direct maintenance, dunning warnings, and low- || balance alerts to the verified primary administrative email and phone. || β’ Self-Service Governance: Eliminates support tickets for routine corporate || contact and office relocation updates. || β’ Strict Form Standards: Complies with Ring2All Level 2 Form UI guidelines || with FormGrid alignment and lower FixedActionBar controls. |+-------------------------------------------------------------------------------+2. Technical Architecture & Profile Sync
Section titled β2. Technical Architecture & Profile SyncβWhen an administrator saves modifications in SettingsPage.tsx, the API validates the payload, updates PostgreSQL, and refreshes the clientβs session context:
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β Client Web Browser (Portal UI) β β Route: /portal/settings β βββββββββββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββ β PUT /api/client/profile βΌ ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β Ring2All BSS API Engine (Fastify 5 / Zod Schema) β β β’ Validates International Phone E.164 & Postal Code Formats β β β’ Sanitizes Tax ID & Legal Company Name β βββββββββββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββ β βΌ SQL UPDATE ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β PostgreSQL 17 (customer accounts store) β β UPDATE customers SET company_name = ..., β β tax_id = ..., billing_address = ..., city = ... β β WHERE id = $authCustomerId β βββββββββββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββ β 200 OK + Refreshed Profile βΌ ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β Client Session Context Hydration β β Updates React Context & Header Profile Display β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ3. Visual Interface & Screen Breakdown
Section titled β3. Visual Interface & Screen Breakdownβ4.1 Account & Company Profile Settings
Section titled β4.1 Account & Company Profile SettingsβThe profile form utilizes standardized FormBoxes and responsive FormGrids:

- ModuleFormHeader: Fixed 56px header displaying the building icon, module title (
Account Profile), and navigation back button. - Company Information Card: Fields for Primary Contact Name, Registered Company Name, Contact Phone, and National Tax ID.
- Billing Address Card: Fields for Street Address, City, State/Province, Postal Code, and Country dropdown selector.
- FixedActionBar: Bottom-anchored action bar featuring
Cancel(resets form to original state without navigating) andSave Changes(submits payload).
4. Company Details, Tax ID & Invoicing Address
Section titled β4. Company Details, Tax ID & Invoicing AddressβThe profile configuration controls corporate tax calculations:
- Tax Exemption Status: If a valid European VAT ID or US Resale Certificate number is filed and verified, the billing engine automatically applies zero-rated tax rules on invoice generation.
- E911 Consistency: By default, new DID acquisitions can inherit the registered company billing address for emergency dispatch routing.
5. FormGrid Standardization & Action Bar Controls
Section titled β5. FormGrid Standardization & Action Bar ControlsβIn accordance with Ring2All UI Rule 8:
- Standard Grid Structure: All form elements utilize
grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-x-6 gap-y-3 items-start. - Label Baseline: Every
<Label>enforcesmin-h-[40px] flex items-centerto guarantee vertical baseline alignment across adjacent columns. - Cancel Button Semantics: As per Rule 6, clicking Cancel restores the form to initial values without leaving the page.
6. Diagnostic CLI & Operational Playbooks
Section titled β6. Diagnostic CLI & Operational PlaybooksβVerify Customer Profile Record via Database
Section titled βVerify Customer Profile Record via Databaseβsu - postgres -c "psql -d ss_billing -x -c \"SELECT name, company_name, phone, tax_id, billing_address, city, state, postal_code, countryFROM customersWHERE id = 5;\""7. Domain Glossary
Section titled β7. Domain Glossaryβ- FixedActionBar: Bottom-docked UI toolbar housing primary persistence and form cancellation controls.
- Tax ID / EIN: Employer Identification Number or Value Added Tax (VAT) registry code.
- FormGrid: Standardized 4-column responsive grid layout ensuring field alignment.

