add query for resources to API