Skip to main content
Aria Knowledge Central

Data Feed JSON Representation

Overview

This document provides a sample of how data described in the Data Feed Logical Object Model is represented in JSON format.

Object Model to JSON Mapping

Element Types

 

Model Data Type JSON
Value Type
Example Format
Text string "Hello world"  
Date string "2018-09-04" ISO 8601 format
Java format: "yyyy-MM-dd"
DateTime string "2018-09-04T20:49:51+02:00" ISO 8601 format
Java format:"yyyy-MM-dd'T'HH:mm:ssXXX"
EmailAddress string "jdoe@example. com" "local-part@domain"
Ref object {"type": "Account", `
`"ids":{"account_no": 419952624, "client_account_id": "john.doe", "userid": "6123422"}}`
An object with fields "type" and "ids"
BigInt number 123456789123456  
Int number 123456789  
SmallInt number 12345  
Decimal number 123456.78  
Boolean boolean true  
null null null  

Note: DateTime values should have a time zone part whose value matches the Aria client's configured time zone.

Objects

Model objects, including entities, are represented as JSON objects. The elements of the JSON objects are represented according to their model types.

Element order is not defined or enforced in JSON objects.

Object elements may have the value "null" (not a string value, but the JSON null value). This indicates that that element of the object explicitly has no value.

Examples

Each of the following shows the value for the change event data part.

Note: The line breaks and alignments in these examples are given solely for better clarity. The "data" field will normally be returned in compact form, with unnecessary whitespace removed.

Objects in the following example: Transaction

{
    "transaction_no":        ####,
    "transaction_type":      {"type": "Transaction_Type", "ids":{"enum": 3}},
    "created_tstamp":        "2018-09-04T22:49:51+02:00",  // ISO 8601 datetime in client's time zone
    "source_no":             ####,
    "account":               {"type": "Account", "ids": {"account_no": ####, "client_account_id": "john.doe", "userid": "####"}},  // Ref to an account
    "currency":              {"type": "Currency_Code", "ids":{"code": "eur"}},
    "amount":                -149.95,
    "applied_amount":        -149.95,
    "fully_applied_tstamp":  "2018-09-05T0:17:03+02:00",
    "statement":             null,
    "master_plan_instance":  {"type": "Plan_Instance", "ids": {"plan_instance_no": ####}},
    "api_receipt_id":        null,
    "transaction_supp_fields": [],
    "voided_transaction":    null,
    "voiding_transaction":   null,
    "applications":  [ // array of refs to Transaction_Applications
                                {"type": "Transaction_Application", "ids": {"application_no":####, "payment_transaction_no": ####, "charge_transaction_no": ####}},
                                {"type": "Transaction_Application", "ids": {"application_no":####, "payment_transaction_no": ####, "charge_transaction_no": ####}}
                             ],
    "payment_tstamp":        "2018-09-05T0:17:03+02:00",
    "collection_status":     {"type": "Collection_Status", "ids"{"enum": 1}},
    "payment_method":        {"type": "Payment_Method": "ids": {"account_no": ####, "payment_method_no": 1}}
    "processor_payment_id":  "x59.1001G",
    "payment_processor":     {"type": "Payment_Processor", "ids": {"enum": 4},
    "payment_method_type":   {"type": "Payment_Method_Type", "ids": {"enum": 2},
    "processor_status_cd":   "1",
    "processor_status_label": "OK"
}
```

Example data for an [Order](logical_model.md#order)

```
{
    "order_no":       624537,
    "client_order_id": "992.1523.9",
    "purchase_order_number": ""
    "account":        {"type": "Account", "ids": {"account_no": ####, "client_account_id": "john.doe", "userid": "####"}},
    "plan_instance":  {"type": "Plan_Instance", "ids": {"plan_instance_no": ####, "client_plan_instance_id": "####"}},
    "invoice":        {"type": "Invoice", "ids": {"invoice_no": ####}},
    "status":         {"type": "Order_Status", "ids": {"enum": 1}},
    "currency":       {"type": "Currency_Code", "ids":{"code": "usd"}},
    "amount":         24.95,
    "lines":  [
                         {"type": "Order_Line", "ids": {"order_no": ####, "line_no": 1}},
                         {"type": "Order_Line", "ids": {"order_no": ####, "line_no": 2}}
                      ],
    "created_tstamp": "2018-09-02T15:51:31-07:00",
    "updated_tstamp": null,
}
```
  
  • Was this article helpful?