• Register

Account Hierarchy

Account hierarchy API is used to get all accounts for commercial or multi-currency hierarchy under specific client id or account number, with the option to get how many levels is needed under the searched level (applicable for corporate hierarchy ), and to filter also by client type for example to get all accounts linked to commercial clients.

Request Parameters:

Node Child Node Data Type Length Description Remarks
header msg_id A/N 12 Unique Source Message ID Mandatory
msg_type String 12 Request Type Default: "ENQUIRY" Mandatory
msg_function String 50 Function name to be used Default: "REQ_GET_CARD_TRANSACTIONS " Mandatory
src_application String 10 Source requesting channel Ex: IVR Mandatory
target_application String 10 Target application name Ex. : "PCMS" Mandatory
timestamp String 30 Timestamp of the request Format  “DD/MM/YYYY HH:MM:SS” Mandatory
tracking_id String 15 Transaction Tracking Id Optional
bank_id String 4 Source Bank Id Ex: bankID Mandatory
body customer_id String 10 Either customer id or account identifier is required. Mandatory 
account_identifier_id String 16 Either customer id or account identifier is required. Mandatory 
account_identifier_type String 10

CONTRACT_NUMBER or EXID

Mandatory
level_down String 1 value from 1 to 5 Optional
client_type String 10

Commercial → C

Private → P

Optional
balance_list String 512 AVAILABLE,BLOCKED,TOTAL_BALANCE Optional
Request Json
{
   "NISrvRequest":{
      "request_get_card_transactions":{
         "header":{
            "msg_id":"224001",
            "msg_type":"ENQUIRY",
            "msg_function":"REQ_ACCOUNT_HIERARCHY",
            "src_application":"IVR",
            "target_application":"app",
            "timestamp":"2020-07-19T13:04:30.356+04:00",
            "tracking_id":"224001",
            "bank_id":"bankID"
         },
         "body":{
            "customer_id":"121224",
            "level_down":"5",
            "client_type":"Commercial",
            "balance_list":"AVAILABLE"
         }
      }
   }
}

Response Parameters:

Node Child Node Type Length Description Remarks
header msg_id A/N 12 Unique Source Message ID Mandatory
msg_type String 12 Request Type Default: "ENQUIRY" Mandatory
msg_function String 50 Function name to be used Default: "REP_ACCOUNT_HIERARCHY" Mandatory
src_application String 10 Source requesting channel Ex: IVR. Mandatory
target_application String 10 Target application name Ex. : "PCMS" Mandatory
timestamp String 30 Timestamp of the request Format  “DD/MM/YYYY HH:MM:SS” Mandatory
tracking_id String 15 Transaction Tracking Id Optional
bank_id String 4 Source Bank Id Ex: bankID Mandatory
body account_number String 16 CIF ID Mandatory
customer_id String 10 Bank code Mandatory
rbs_number   String 512 RBS Number which is the number used to link NI System with Core System Optional
product_code String 10 Product Code Mandatory
masked_card_number String 16

Masked PAN

Mandatory
card_identifier_id String 32 454545XXXXXX1234 Mandatory
card_identifier_type String 20

CONTRACT_NUMBER

or

EXID

Mandatory
card_expiry_date String 4 2310 Mandatory
cardholder_name String 21 JOHN DOE Mandatory
product_code String 50 Product Code Mandatory
product_name String 100 Product Name Optional
brand String 10 Card Brand example: MC , Visa Optional
card_virtual_indicator String 1

Y: Virtual

N: Physical

F: Physical in progress

Optional
balances type String 32 For example: AVAILABLE Optional
currency String 3 Ex: AED Optional
amount String  20
Optional
statuses type String 10 card_status Optional
value String 10 Refer statuses Optional
changed_date String 10 Changed Date Optional
description String 100 Description Optional

Json Response

{
   "NISrvRequest":{
      "request_get_card_transactions":{
         "header":{
            "msg_id":"224001",
            "msg_type":"ENQUIRY",
            "msg_function":"REP_ACCOUNT_HIERARCHY",
            "src_application":"IVR",
            "target_application":"app",
            "timestamp":"2020-07-19T13:04:30.356+04:00",
            "tracking_id":"224001",
            "bank_id":"bankID"
         },
         "body":{
            "accounts":[
               {
                  "account_number":"0009822010000000020",
                  "customer_id":"121224",
                  "rbs_number":"1",
                  "product_code":"982_AED_045_C_1",
                  "balances":[
                     {
                        "type":"AVAILABLE",
                        "currency":"AED",
                        "amount":"100.25"
                     }
                  ],
                  "sub_accounts":[
                     {
                        "account_number":"0009822020000000006",
                        "customer_id":"121226",
                        "rbs_number":"3",
                        "product_code":"982_AED_045_C_2",
                        "balances":[
                           {
                              "type":"AVAILABLE",
                              "currency":"AED",
                              "amount":"100.25"
                           }
                        ],
                        "sub_accounts":[
                           {
                              "account_number":"0009822030000000007",
                              "customer_id":"121227",
                              "rbs_number":"4",
                              "product_code":"982_AED_045_C_3",
                              "balances":[
                                 {
                                    "type":"AVAILABLE",
                                    "currency":"AED",
                                    "amount":"100.25"
                                 }
                              ],
                              "sub_accounts":[
                                 {
                                    "account_number":"0009822040000000002",
                                    "customer_id":"121227",
                                    "rbs_number":"5",
                                    "product_code":"982_AED_045_C_4",
                                    "balances":[
                                       {
                                          "type":"AVAILABLE",
                                          "currency":"AED",
                                          "amount":"100.25"
                                       }
                                    ],
                                    "sub_accounts":[
                                       {
                                          "account_number":"0009822220000000260",
                                          "customer_id":"121228",
                                          "rbs_number":"6",
                                          "product_code":"982_AED_045_A_5",
                                          "balances":[
                                             {
                                                "type":"AVAILABLE",
                                                "currency":"AED",
                                                "amount":"100.25"
                                             }
                                          ],
                                          "cards":[
                                             {
                                                "masked_card_number":"999851XXXXXX5439",
                                                "customer_id":"121228",
                                                "card_identifier_id":"99985104165423946128",
                                                "card_identifier_type":"EXID",
                                                "card_expiry_date":"2712",
                                                "cardholder_name":"TEST",
                                                "product_code":"982_AED_045_P_5",
                                                "product_name":"Corporate",
                                                "brand":"MC",
                                                "card_virtual_indicator":"Y",
                                                "statuses":[
                                                   {
                                                      "type":"BCC-CARD-982",
                                                      "value":"_",
                                                      "changed_date":"",
                                                      "description":"SPACE"
                                                   }
                                                ],
                                                "balances":[
                                                   {
                                                      "type":"AVAILABLE",
                                                      "currency":"AED",
                                                      "amount":"100.25"
                                                   }
                                                ]
                                             },
                                             {
                                                "masked_card_number":"999851XXXXXX5440",
                                                "customer_id":"121230",
                                                "card_identifier_id":"99985104172027332275",
                                                "card_identifier_type":"EXID",
                                                "card_expiry_date":"2712",
                                                "cardholder_name":"TEST",
                                                "product_code":"982_AED_045_P_5",
                                                "product_name":"Corporate",
                                                "brand":"MC",
                                                "card_virtual_indicator":"Y",
                                                "statuses":[
                                                   {
                                                      "type":"BCC-CARD-982",
                                                      "value":"_",
                                                      "changed_date":"",
                                                      "description":"SPACE"
                                                   }
                                                ],
                                                "balances":[
                                                   {
                                                      "type":"AVAILABLE",
                                                      "currency":"AED",
                                                      "amount":"100.25"
                                                   }
                                                ]
                                             }
                                          ]
                                       }
                                    ]
                                 }
                              ]
                           }
                        ]
                     }
                  ]
               },
               {
                  "account_number":"0009822010000000022",
                  "customer_id":"121224",
                  "rbs_number":"11",
                  "product_code":"982_AED_045_C_1",
                  "balances":[
                     {
                        "type":"AVAILABLE",
                        "currency":"AED",
                        "amount":"100.25"
                     }
                  ],
                  "sub_accounts":[
                     {
                        "account_number":"0009822220000000261",
                        "customer_id":"121229",
                        "rbs_number":"112",
                        "product_code":"982_AED_045_A_2",
                        "cards":[
                           {
                              "masked_card_number":"999851XXXXXX0381",
                              "customer_id":"4345432",
                              "card_identifier_id":"99985104101264305462",
                              "card_identifier_type":"EXID",
                              "card_expiry_date":"2712",
                              "cardholder_name":"TEST",
                              "product_code":"982_AED_045_P_2",
                              "product_name":"Corporate",
                              "brand":"MC",
                              "card_virtual_indicator":"Y",
                              "statuses":[
                                 {
                                    "type":"BCC-CARD-982",
                                    "value":"_",
                                    "changed_date":"",
                                    "description":"SPACE"
                                 }
                              ],
                              "balances":[
                                 {
                                    "type":"AVAILABLE",
                                    "currency":"AED",
                                    "amount":"100.25"
                                 }
                              ]
                           }
                        ]
                     }
                  ]
               }
            ]
         }
      }
   }
}

Docs Navigation