How would you go about enriching user names with Microsoft AD attributes like department, name, country, etc?

Enriching data using a resource is pretty straight forward with a CSV

Whether you have something like a list usernames you want to enrich with LDAP/Microsoft AD attributes or some other data source you would like to use for enrichment, the best method would be to create a CSV resource  (in this case from ldap info) that could then be pivoted against using the lookup module (!search/lookup/