Map Data Fields Between App and External System
Different accounting systems use different field names, data types, and code structures (e.g., chart of accounts codes, cost center IDs). The field mapping editor allows admins to visually match app data fields (activity type, amount, date, peer mentor name) to their corresponding fields in the external system. The editor should show sample data values to help admins verify mappings are correct, and support transformation rules such as date format conversion and numeric rounding.
User Story
Acceptance Criteria
- Given an active integration exists, When I open the Field Mapping Editor, Then I see two columns: app fields on the left and external system fields on the right, with drag-and-drop or dropdown matching
- Given I am mapping a date field, When I select the external system's date field, Then I can choose the output format (ISO 8601, DD.MM.YYYY, epoch) required by the target system
- Given I have created a mapping, When I click 'Preview Mapping' with sample data, Then the system shows 3-5 example records transformed according to my mapping so I can visually verify correctness
- Given a required field in the external system has no matching app field, When I save the mapping, Then the system warns me about unmapped required fields and prevents saving until resolved or explicitly marked as excluded
- Given the external system uses chart-of-accounts codes, When I map the activity type field, Then I can configure a lookup table that translates app activity types to accounting codes
- Given I save a valid mapping, When the next export runs, Then the exported file uses the mapped field names and transformed values exactly as configured
Business Value
Incorrect field mapping is the primary cause of accounting import failures, requiring manual correction that can take 2-4 hours per export cycle. A visual mapping editor with preview reduces setup errors to near zero, accelerates onboarding for new accounting staff, and ensures the app can accommodate the diverse field naming conventions used by Xledger (Blindeforbundet) and Dynamics (HLF) without requiring developer intervention for each organization.
Components
- Field Mapping Editor ui
- Field Mapping Resolver service
- Integration Configuration Service service
- Organization Integration Repository data
- Integration Config Validator infrastructure
- Chart of Accounts Mapper data