• tenant - (mandatory) - business tenant
  • device_id - (optional) - Id of device that chould be linked with account;
  • reference_id - (optional) - Id of reference that chould be linked with account;
  • reference_code - (optional) - code of reference that chould be linked with account;
  • is_ref_to_acc - (mandatory) - if false API shows all references that do not have reference to account, default value is true,
  • account_id - (optional) - If param set,API shows all references that account has
  • contract_id - (optional) - If param set,API shows all references that linked to contract
  • show_current - (optional; default true) - if only current references have to be returned

API предназначеня для выборки сущности "Reference" по аккаунту, контракту или идентификатору записи. В случае бизнес-кейсов Zegoal, достаточно будет указывать только account_id.


Example:


{
 		"tenant": "zegoal",
         "account_id": 10
}
CODE



 {
   "processing_result":    {
      "text": "",
      "status": "ok",
      "ctx_id": "qJQ8BNNj:0-qF",
      "code": 0
   },
   "processing_date": "2020-07-07 11:17:42",
   "GetReferenceInfo":    {
      "response":       {
         "TZ": "Europe/Minsk",
         "References": [         {
            "valid_to": "",
            "valid_from": "2020-07-07 11:17:33",
            "reference_type": "ordering_tenant",
            "reference_id": 62,
            "reference_code": "order023",
            "device_id": "",
            "description": "",
            "contract_num": "",
            "contract_id": "",
            "account_id": 10
         }]
      },
      "request":       {
         "tenant": "zegoal",
         "account_id": 10
      },
      "extra_logic": "",
      "enriched_request":       {
         "tenant": "zegoal",
         "show_current": true,
         "is_ref_to_acc": true,
         "account_id": 10
      }
   }
}
CODE