public static IEnumerable <object> PostMail(IISMailQueue mail) { IEnumerable <IISMailQueue> item = new[] { mail }; return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_MAIL_TO_QUEUE, _authToken)); }
public static ServiceTimer GetScheduler(short serviceId, string apiKey) { Client referenceClient = GetClient(apiKey); ServiceTimer scheduler = WebOperations.WebGet <ServiceTimer>(WebOperations.WebMethod.GET_SCHEDULER_BY_CLIENTID_AND_SERVICEID, apiKey, referenceClient.Id, serviceId); return(scheduler ?? FileOperations.GetLocalScheduler(serviceId) as ServiceTimer); }
public static Client GetClient(string apiKey) { string machineName = Environment.MachineName; Client client = WebOperations.WebGet <Client>(WebOperations.WebMethod.GET_CLIENT_BY_MACHINE_NAME, apiKey, machineName); NewClient(apiKey); return(client); }
private static void NewClient(string apiKey) { string machineName = Environment.MachineName; Client client = new Client { AgentInstallDate = DateTime.Now, IsOnline = true, LastDataReceived = DateTime.Now, LastOnlineDate = DateTime.Now, Name = machineName }; _ = WebOperations.WebPost(client, WebOperations.WebMethod.POST_CLIENT, apiKey); }
private static bool NewClient(string apiKey) { string machineName = Environment.MachineName; Client client = new Client { AgentInstallDate = DateTime.Now, IsOnline = true, LastDataReceived = DateTime.Now, LastOnlineDate = DateTime.Now, Name = machineName }; dynamic result = WebOperations.WebPost(client, WebOperations.WebMethod.POST_CLIENT, apiKey); if (result > 0) { return(true); } return(false); }
public static SiteLog GetSiteLog(long siteId) { return(WebOperations .WebGet <SiteLog>(WebOperations.WebMethod.GET_EVENT_LOG_BY_SITEID, _authToken, siteId)); }
public static SiteWebConfiguration GetConfiguration(long siteId) { return(WebOperations .WebGet <SiteWebConfiguration>(WebOperations.WebMethod.GET_WEB_CONFIGURATION_BY_SITEID, _authToken, siteId)); }
public static IEnumerable <SitePackage> PostSitePackage(IEnumerable <SitePackage> item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_PACKAGE_MULTIPLE, _authToken)); }
public static SiteEndpoint GetSiteEndpoint(long siteId) { return(WebOperations .WebGet <SiteEndpoint>(WebOperations.WebMethod.GET_ENDPOINT_BY_SITEID, _authToken, siteId)); }
public static ISiteLogPosition GetLogPosition(long siteId) { return(WebOperations .WebGet <ISiteLogPosition>(WebOperations.WebMethod.GET_SITE_LOG_POSITON, _authToken, siteId)); }
public static ServiceTimer GetScheduler(short serviceId, int clientId, string apiKey) { ServiceTimer scheduler = WebOperations.WebGet <ServiceTimer>(WebOperations.WebMethod.GET_SCHEDULER_BY_CLIENTID_AND_SERVICEID, apiKey, clientId, serviceId); return(scheduler ?? FileOperations.GetLocalScheduler(serviceId) as ServiceTimer); // (scheduler'i return et null mu??) Local Scheduler'i return et }
public static IEnumerable <SiteWebConfiguration> PostSiteWebConfiguration(IEnumerable <SiteWebConfiguration> item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_WEB_CONFIGURATION_MULTIPLE, _authToken)); }
public static IEnumerable <Site> GetSites(string machineName) { return(WebOperations .WebGet <IEnumerable <Site> >(WebOperations.WebMethod.GET_SITES_BY_MACHINENAME, _authToken, machineName)); }
public static IEnumerable <SiteLog> PostSiteLog(IEnumerable <SiteLog> item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_TRANSACTION_MULTIPLE, _authToken)); }
public static SiteWebConfiguration PostSiteWebConfiguration(SiteWebConfiguration item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_WEB_CONFIGURATION, _authToken)); }
public static SiteLog PostSiteLog(SiteLog item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_TRANSACTION, _authToken)); }
public static IEnumerable <ISiteTracker> PostSiteTracker(IEnumerable <ISiteTracker> item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_SITE_TRACKER_MULTIPLE, _authToken)); }
public static ISiteTracker PostSiteTracker(ISiteTracker item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_SITE_TRACKER, _authToken)); }
public static IEnumerable <SiteEndpoint> GetSiteEndpoints(long siteId) { return(WebOperations .WebGet <IEnumerable <SiteEndpoint> >(WebOperations.WebMethod.GET_ENDPOINTS_BY_SITEID, _authToken, siteId)); }
public static SitePackage PostSitePackage(SitePackage item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_PACKAGE, _authToken)); }
public static IEnumerable <SiteLogFilter> GetSiteTransactionFilters() { return(WebOperations .WebGet <IEnumerable <SiteLogFilter> >(WebOperations.WebMethod.GET_TRANSACTION_FILTERS, _authToken)); }
public static IEnumerable <SiteEventLog> PostSiteEventLog(IEnumerable <SiteEventLog> item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_EVENT_LOG_MULTIPLE, _authToken)); }
public static bool GetSiteLogActivationStatus() { return(WebOperations .WebGet <bool>(WebOperations.WebMethod.GET_TRANSACTION_ACTIVATION_STATUS, _authToken)); }
public static IEnumerable <SiteEndpoint> PostSiteEndpoint(IEnumerable <SiteEndpoint> item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_ENDPOINT_MULTIPLE, _authToken)); }
public static SiteEventLog PostSiteEventLog(SiteEventLog item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_EVENT_LOG, _authToken)); }
public static IEnumerable <SiteConnectionString> GetSiteConnectionStrings(long siteId) { return(WebOperations .WebGet <IEnumerable <SiteConnectionString> >(WebOperations.WebMethod.GET_CONNECTION_STRINGS_BY_SITEID, _authToken, siteId)); }
public static SiteBinding GetSiteBinding(long siteId) { return(WebOperations .WebGet <SiteBinding>(WebOperations.WebMethod.GET_BINDING_BY_SITEID, _authToken, siteId)); }
public static Site GetSite(long siteId) { return(WebOperations .WebGet <Site>(WebOperations.WebMethod.GET_SITE_BY_ID, _authToken, siteId)); }
public static SiteConnectionString GetConnectionString(long siteId) { return(WebOperations .WebGet <SiteConnectionString>(WebOperations.WebMethod.GET_CONNECTION_STRING_BY_SITEID, _authToken, siteId)); }
public static SiteEndpoint PostSiteEndpoint(SiteEndpoint item) { return(WebOperations .WebPost(item, WebOperations.WebMethod.POST_ENDPOINT, _authToken)); }