getUpdates inspector

The way that works for every chat, private or not: let a bot receive one message, then read the IDs out of the update.

getUpdates inspector

Paste what getUpdates returned (or a single update or message). Every ID in it is listed. Read in your browser — nothing is uploaded.

1 · Fetch your bot's updates in a terminal
TOKEN='paste-your-token-here'
curl -s "https://api.telegram.org/bot$TOKEN/getUpdates"

Where each ID sits

Chatmessage.chat.id
Sendermessage.from.id
Channel postchannel_post.chat.id
Forum topicmessage.message_thread_id
Forwarded frommessage.forward_origin
Bot added to a chatmy_chat_member.chat.id

FAQ

Where is the chat ID in getUpdates?

In result[n].message.chat.id. For a channel post it is result[n].channel_post.chat.id. The sender's user ID is message.from.id.

Why is my getUpdates result empty?

Either nobody has written to the bot since the last call, or a webhook is set (then getUpdates does not work), or the bot is in a group with privacy mode on and only receives commands, mentions and replies. Send /start to the bot and call it again.

How long does Telegram keep updates?

Up to 24 hours. An update that was already confirmed with a higher offset is gone.

Is my pasted JSON sent anywhere?

No. It is parsed by JavaScript in your browser. The page makes no request with it.