Re-factor WebPI Resource to use .NET Class