feat: subdocument rest api

@valmy check this out, give your feedback