telegram

基于prometheus + grafana + mysql + Telegram 监控告警

混江龙づ霸主 提交于 2019-11-29 22:31:47
Prometheus是什么 Prometheus (普罗米修斯)非常酷的开源监控系统。它支持多维度的指标数据模型,服务端通过HTTP协议定时拉取数据后,通过灵活的查询语言,实现监控的目的。 客户端记录相关指标数据,对外提供查询接口。Prometheus服务端通过服务器发现机制找到客户端,并定时抓取存储为时间序列数据。最后通过Grafana等图表工具集成展示。 Prometheus可以做什么 在业务层用作埋点系统 Prometheus支持各个 主流开发语言 (Go,java,python,ruby官方提供客户端,其他语言有第三方开源客户端)。我们可以通过客户端方面的对核心业务进行埋点。如下单流程、添加购物车流程。 在应用层用作应用监控系统 一些主流应用可以通过官方或第三方的 导出器 ,来对这些应用做核心指标的收集。如 redis , mysql 。 在系统层用作系统监控 除了常用软件, prometheus也有相关系统层和网络层exporter,用以监控服务器或网络。 集成其他的监控 prometheus还可以通过各种exporte,集成其他的监控系统,收集监控数据,如AWS CloudWatch,JMX,Pingdom等等。 开始安装 prometheus 1 下载 https://prometheus.io/download/ 2 解压安装 tar xf prometheus-2

How to interact with Telegram API

南楼画角 提交于 2019-11-29 19:43:13
I'm really confused as I'm trying to use Telegram's APIs after reading a lot of the documentation on http://core.telegram.org . I have registered my app and got a hash_id and all of that stuff. But I'm not sure where to begin with. I had worked with Spotify's API before, and was able to interact with it using http://api.spotify.com/v1/method?params:values form. I can't find the URL for Telegram's API. I also searched a lot on the internet but couldn't find any useful examples. Does anyone know anything about getting started to work with Telegram's API? Any help would be appreciated. Charles

send bold & italic text on telegram bot with html

限于喜欢 提交于 2019-11-29 16:09:05
问题 I've created a bot in telegram I want to send bold and italic text with HTML page to bot My HTML code is: <html> <head><title>Telegram</title></head> <body> <form method="GET" action="https://api.telegram.org/bot(token)/sendMessage"> <input type="hidden" name="chat_id" value="@testadminch"> <input type="hidden" name="parse_mod" value="markdown"> <textarea name="text"></textarea> <input type="submit" value="Submit"> </form> </body> </html> If I send *bold* the output should be bold but it

How to compile telegram jni folder

一个人想着一个人 提交于 2019-11-29 14:29:39
问题 I am trying to compile jni folder in telegram source code in github.com/DrKLO/Telegram/ with ndk But when i am write ndk-build in cmd in ndk folder like: F:\ndk\android-ndk-r10>ndk-build -C F:\Workspace\Android\Telegram-master-1-12-2016\Telegram-master\TMessagesProj\jni I get some error and libs folder not created When i add ndk path to android studio and add jni folder manually android studio say can not find some header files Following this question download Cygwin and use it, but again get

Is there any size limit to post a file using curl?

时间秒杀一切 提交于 2019-11-29 13:22:23
I need to post files up to 50mb to telegram bot api. Now I'm using Curl and everything tested and passed successfully. Means that I can only send small files (I coudn't send 8.1mb file in my test). So if I send large files (lets say more than 8mb) all $_POST variables are empty, means nothing posted. Question: Is there any limitation in sending file using curl? Because I asked my server administrator to increase related configuration in php.ini , but they replied that is not php.ini 's problem and there is no limitation in curl. thanks in advance. Upload limits are a security feature. Without

Keystore file D\Telegram-master\TMessagesProj\config\release.keystore not found for signing config 'debug'

若如初见. 提交于 2019-11-29 12:38:32
问题 I downloaded new version of Telegram. When run it,This error has shown: Keystore file D\Telegram-master\TMessagesProj\config\release.keystore not found for signing config 'debug'. How fix it? 回答1: Checkout the signingConfig part of build.gradle file: signingConfigs { debug { storeFile file("config/release.keystore") storePassword RELEASE_STORE_PASSWORD keyAlias RELEASE_KEY_ALIAS keyPassword RELEASE_KEY_PASSWORD } release { storeFile file("config/release.keystore") storePassword RELEASE_STORE

Send an image link to telegram without display image url

北战南征 提交于 2019-11-29 07:55:24
问题 I need send an image url to telegram without display image url and hidden url. I see a telegram bot and it's do it very well and send long message with image I'm attach this bot result image see it. Now how can do it in my custom bot? It's possible hidden url with MARKDOWN style or any way? I want hidden image url in my text but telegram display my image. see my sample attach image. thank you 回答1: Most of them use the dot (or some things like this character) for link description and you

Android - Send Telegram message to a specific number

纵然是瞬间 提交于 2019-11-29 03:51:31
I'm trying to send a Telegram message to a specific number from within my Android app. Right now my code launches Telegram app, and then the user has to select the destinatary. What I want to do is to send the message to the specified number, without having the user select the contact. My code is as follows: /** * Intent to send a telegram message * @param msg */ void intentMessageTelegram(String msg) { final String appName = "org.telegram.messenger"; final boolean isAppInstalled = isAppAvailable(mUIActivity.getApplicationContext(), appName); if (isAppInstalled) { Intent myIntent = new Intent

Telegram php example send message [closed]

ぃ、小莉子 提交于 2019-11-29 00:23:55
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 2 years ago . I can't find an example of sending message by telegram protocol from php. I tried to use this but failed. Can you give me any examples? 回答1: I use the following function: function sendMessage($chatID, $messaggio, $token) { echo "sending message to " . $chatID . "\n"; $url = "https://api.telegram.org/bot" .

How to set Telegram bot webhook?

拥有回忆 提交于 2019-11-28 21:37:01
I'm developing a Telegram bot, and I want to set the webhook to my domain's URL. I've already generated a self-signed certificate following the Telegram's guide . However, I'm not able to set the webhook. I've searched previous answers and found this one , but it doesn't work to me. Can anybody explain me how to upload the SSL certificate and set the webhook? I created a file on my server for conveniently setting up telegram webhooks. You can use the same file on your server. This should be on the same server from which you wish to run the Telegram Bot <html> <head> <title>Set Webhooks</title>