Get lld neighbors via API?

Is it possible to get the lldp neighbours of a device via API?
The use case would be to get a serialnumber of a server enclosure interface (it presents it as lldp hostname) and find the connected switch.

@networkpadawan Yes it is possibe, check list_links and get_links API calls