The Database API reference discovery
This page describes how the (version 6) University Map Database API can be used to navigate among geographical objects and thereby determine relevant ref codes.
API calls of the form
yield the geographical entities (buildings, sites, colleges, entrances and nonuniversity premises known to the map) with the given refs.
However, this assumes you know what the refs are.
For those buildings etc which have names, searching for them by name either with the API or the interactive map will provide the record from which its ref can be determined. But (a) colleges yield the institution not the geographical college site when looked up by name, and (b) many entities, especially entrances, do not have names at all.
Therefore, the API also provides the ability to look up all the subordinate geographical entities for some entity (the geographical entities are arranged in a hierarchy) using a wildcard and thereby determine related (and ultimately, if necessary, all) references.