I'm trying to implement a Web API project that exposes some models. However, the way the model is retrieved isn't very RESTful.
1. Instead of having just one ID, it has a combination of 4 different ones to populate the model data by running a stored proc on the server.
Dim balance as New BalanceSheet(uid, mid, eid, fid)
The snippet above will use uid, mid, eid, fid to retrieve the correct record from the database.
How would I implement this in the controller so that /api/Balance?uid=1&mid=2&eid=3&fid=4 maps to GetBalance(ByVal uid As Integer, ByVal mid As Integer, ByVal eid As Integer, ByVal fid As Integer)
2.
Additionallly, I want to be able to filter specific members of BalanceSheet model or get some preprocessed object return like so:
/api/Balance/FundCredit?uid=1&mid=2&eid=3&fid=4 maps to GetFundcredit(ByVal uid As Integer, ByVal mid As Integer, ByVal eid As Integer, ByVal fid As Integer)