Hello
Have any of you figured out how to get a hierarchical list with an API/URL call?
Like lists with this url?
svi-datahub/admin/lists?name=OBJECTNAME
Example:
On the Viya Admin page (Manage Investigate and Search), on the "Data Object" tab and the "Reference Data" sub tab, I have created a list named "regions" which contains a list of districts.
If I enter the url into the browser "homepage/svi-datahub/admin/lists?name=regions, the list "regions" is returned as json.
So, now I try to get a hierarchical list as json via an API call. This hierarchical list has been created in "Reference Data" sub-tab, tab Hierarchies.
Thanks
So when you call svi-datahub/admin/lists?name=regions the items in the response are your districts which could be retrieved using svi-datahub/admin/lists?name=district_name. Would you be able to read the response from the first call and then iterate through those?
Edit: To answer your question, I don't think there is a separate API call that will return a flat response.
So when you call svi-datahub/admin/lists?name=regions the items in the response are your districts which could be retrieved using svi-datahub/admin/lists?name=district_name. Would you be able to read the response from the first call and then iterate through those?
Edit: To answer your question, I don't think there is a separate API call that will return a flat response.
Thanks much, that helped .../svi-datahub/admin/lists?name=region_districts_sub_lev did the trick.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.