Ldap query for caller id

Im lost in how tos.
What is a good way to get a ldap query for the caller id?

I made a webhook to home assisant to say over mpd you have a call from … but stt isnt good in numbers.

I have a ldap sever with inetorgPerson contacts with several phone numbers set.

There is no such functionality in Asterisk. You would need to do something externally, for example using an AGI.