using MindRockets.WebTools.Client; using MindRockets.WebTools.Contracts; using System; using System.Collections.Generic; public class SignLanguageReportApiClient : ModernAPIClient { public SignLanguageReportApiClient(string endPointHost) : base(endPointHost) { } public Guid RegisterUser(string username, string pwd) { var data = new Dictionary { { "username", username }, { "pwd", pwd } }; return PostAction("slrep", "reguser", data.Secure(), true); } public bool RegisterClient(string cid, string srv) { var data = new Dictionary { { "cid", cid }, { "srv", srv } }; return PostAction("slrep", "regclient", data.Secure(), true); } public bool MapUser(Guid userId, string cid, string srv) { var data = new Dictionary { { "userid", userId.ToString() }, { "cid", cid }, { "srv", srv } }; return PostAction("slrep", "mapuser", data.Secure(), true); } public bool Capture(string cid, string srv) { var data = new Dictionary { { "cid", cid }, { "srv", srv } }; return PostAction("slrep", "capt", data.Secure(), true); } public List ReportAllClientHistory(string cid, string srv) { var data = new Dictionary { { "cid", cid }, { "srv", srv } }; return PostAction>("slrep", "repallcid", data.Secure(), true); } public List ReportClientHistory( string cid, string srv, DateTime from, DateTime to) { var data = new Dictionary { { "cid", cid }, { "srv", srv }, { "from", from }, { "to", to } }; return PostAction>("slrep", "repcid", data.Secure(), true); } public List ListAllClients() { return PostAction>("slrep", "listallclients", NoParams.Secure(), true); } } public class ClientInfo { public string cid { get; set; } public string srv { get; set; } public DateTime addingDate { get; set; } public DateTime? lastCaptDate { get; set; } public int NoOfCapt { get; set; } } public class ClientHistory { public DateTime captDate { get; set; } public int NoOfSessions { get; set; } }