{"$schema":"http://json-schema.org/draft-07/schema#","type":"object","title":"TransactionPostedEvent","description":"Event emitted when a financial transaction is posted to a merchant account","properties":{"accountId":{"type":"object","description":"Account identifier","properties":{"value":{"type":"string","format":"uuid","description":"The unique account UUID"}},"required":["value"]},"transactionId":{"type":"object","description":"Transaction identifier","properties":{"value":{"type":"string","format":"uuid","description":"The unique transaction UUID"}},"required":["value"]},"transactionType":{"type":"string","enum":["CHARGE","REFUND","FEE_ADDED","CHARGEBACK","TOPUP","REMITTANCE","ADJUSTMENT_CREDIT","ADJUSTMENT_DEBIT"],"description":"Type of transaction posted","example":"CHARGE"},"amount":{"type":"integer","description":"Transaction amount (in smallest currency unit, e.g., 10050 = 100.50)","example":10050},"currency":{"type":"string","pattern":"^[A-Z]{3}$","description":"Currency of the transaction (ISO 4217)","example":"EUR"},"reference":{"type":"string","description":"External reference for the transaction","example":"order-12345"},"description":{"type":"string","description":"Description of the transaction","example":"Payment for order #12345"},"postings":{"type":"array","description":"List of account postings made","items":{"type":"object","properties":{"accountDefinitionId":{"type":"integer","description":"Account definition identifier"},"accountDefinitionName":{"type":"string","description":"Account definition name"},"amount":{"type":"integer","description":"Posted amount (in smallest currency unit, e.g., 10050 = 100.50)"},"sign":{"type":"string","enum":["POSITIVE","NEGATIVE"],"description":"Posting sign"}},"required":["accountDefinitionId","accountDefinitionName","amount","sign"]}},"timestamp":{"type":"string","format":"date-time","description":"Timestamp when the transaction was posted"}},"required":["accountId","transactionId","transactionType","amount","currency","postings","timestamp"],"additionalProperties":false}