expose database via API REST

Hi, I would like to know if it's possible to access my elgg database from outside my server, by developing a REST service.

Thanks in advance