REST server library with dependency injection