public static void PushSend(string oracleDBConnection, string receiver, string textMessage) { HttpResponse HttpResponse = new HttpResponse(); JavaScriptSerializer js = new JavaScriptSerializer(); int successSend = 0; List <string> MobileUrls = AdditionalFunc.GetMobileUrls(oracleDBConnection, receiver); if (MobileUrls.Count == 0) { MessageBox.Show("Не найден мобильный логин!", "Сообщение"); } else { for (int i = 0; i < MobileUrls.Count; i++) { HttpResponse = AdditionalFunc.HTTPRequest("POST", MobileUrls[i], "{\"phone\": \"" + receiver + "\" , \"data\" : { \"message\": \"" + textMessage + "\"}}", "admin", "admin"); if (HttpResponse.result == 0) { PushResponse resp = js.Deserialize <PushResponse>(HttpResponse.response); if (String.Equals(resp.sendState, "SENT") | String.Equals(resp.sendState, "SUCCESS")) { successSend++; } } } MessageBox.Show("Успешно отправлено Push-сообщений: " + successSend + " из " + MobileUrls.Count + "", "Сообщение"); } }