The Telegram API is not as easy to use as a normal HTTP/Rest API, you have to interact with their MTProto protocol. You also have to do all sorts of encryption and decryption. Telegram recently released a new Bot API which abstracts all the complications behind a decent HTTP API. Usage example in NodeJS using https://github.com/arcturial/telegrambot:
var TelegramBot = require('telegrambot');
var api = new TelegramBot('<YOUR TOKEN HERE>');
api.getUpdates({ offset: 0 }, function (err, updates) {
// array of message updates since last poll
console.log(updates);
});
api.sendMessage({ chat_id: 0, text: 'test' }, function (err, message) {
// the chat_id is the id received in the getUpdates() call
});
The token can be generated using their BotFather application. You can also use their deep-linking feature to add a link to your website to initiate a conversation with the bot, like so:
https://telegram.me/triviabot?start=payload
The payload value can be anything you want, like a cache key you might use for validating a real person etc.
I know it doesn't directly answer your question, but from personal experience I found it's better to interact with the Bot API than trying to implement all the intricacies required for the normal API. If you are adamant about using their normal API, the IPs are 149.154.167.40:443 (test) and 149.154.167.50:443 (production). They provide the IP details under https://my.telegram.org/apps.