The Importance of Standard Formats
Financial data exchange requires precise, unambiguous formats that can represent complex transactions, account structures, and regulatory information. This chapter explores the major data formats used in modern financial services.
JSON (JavaScript Object Notation)
JSON has become the dominant format for web APIs due to its simplicity, human readability, and native JavaScript support. It's widely used in open banking, fintech APIs, and mobile applications.
Advantages of JSON
- Lightweight and easy to read
- Native support in all modern programming languages
- Flexible schema-less structure
- Excellent tooling and validation support (JSON Schema)
XML (Extensible Markup Language)
XML remains critical in financial services, particularly for regulatory reporting and legacy system integration. Its verbose structure supports complex validation and transformation rules.
When to Use XML
- Regulatory reporting (EMIR, MiFID II)
- Complex document structures with mixed content
- Legacy system integration
- When XSD validation is required
ISO 20022
ISO 20022 is the global standard for electronic data interchange between financial institutions. It provides a comprehensive dictionary of business concepts and a methodology for creating message standards.
Key Message Types
| Message Type | Description | Use Case |
|---|---|---|
| pain.001 | Customer Credit Transfer Initiation | Payment orders from corporate to bank |
| pacs.008 | FI to FI Customer Credit Transfer | Interbank payment messages |
| camt.053 | Bank to Customer Statement | Account statements and transaction reports |
| pacs.002 | Payment Status Report | Acceptance or rejection notifications |
FIX Protocol
The Financial Information eXchange (FIX) protocol is the global standard for electronic communication of securities transactions. It's used by virtually all major stock exchanges, brokers, and institutional investors.
FIX Message Structure
FIX messages use a tag=value format with pipe delimiters. Each field has a numeric tag that identifies its meaning.
Common FIX Message Types
- Type D: New Order Single - Submit new order
- Type 8: Execution Report - Order status update
- Type W: Market Data Request - Subscribe to market data
- Type X: Market Data - Snapshot/Full Refresh
- Type F: Order Cancel Request - Cancel existing order
ISO 8583
ISO 8583 is the international standard for card-originated financial transaction messages. It's used by virtually all ATM and point-of-sale networks worldwide.
Message Structure
ISO 8583 messages consist of three main parts:
- Message Type Indicator (MTI): 4-digit code indicating message purpose
- Bitmap: Indicates which data elements are present
- Data Elements: Up to 128 fields containing transaction details
| MTI | Description | Usage |
|---|---|---|
| 0100 | Authorization Request | Card present transaction authorization |
| 0110 | Authorization Response | Approval or decline from issuer |
| 0200 | Financial Request | Transaction that impacts account balance |
| 0220 | Financial Response | Response to financial request |
| 0420 | Reversal | Undo a previous transaction |
SWIFT Messages
SWIFT (Society for Worldwide Interbank Financial Telecommunication) operates two main message standards: MT (Message Type) messages and MX (XML-based ISO 20022) messages.
MT Messages
Migrating to MX Messages
The financial industry is gradually migrating from MT to MX (ISO 20022) messages. The benefits include:
- Richer data content and structure
- Better support for compliance and regulatory requirements
- Improved straight-through processing (STP)
- Enhanced data quality and validation
Format Selection Criteria
| Format | Best For | Avoid When |
|---|---|---|
| JSON | APIs, mobile apps, web services | Complex validation rules required |
| XML | Regulatory reporting, complex documents | Performance is critical |
| ISO 20022 | Interbank payments, cross-border | Simple internal processes |
| FIX | Securities trading, market data | Banking or payment use cases |
| ISO 8583 | Card transactions, ATM networks | Non-card payment methods |
Understanding these formats and when to use each is essential for building robust financial data exchange systems. In the next chapter, we'll explore how to secure these data exchanges.