How Sidekick works
Telegram examples. Choose your platform →
Sidekick selects an ad for a bot response. The integration controls how that response reaches Telegram.
Request and delivery
- 1Prepare a replyYour bot creates its normal response.
- 2Request an adSend the reply and user context to Sidekick.
- 3Send to TelegramSend the returned message or rich payload.
- 4Read reportingCheck recorded impressions, clicks and revenue.
Choose who assembles the message
Use inject() or POST /api/v1/ad to add an ad to a reply. Use /ad/fetch when your integration assembles a text or image placement from returned ad data. Rich formats are requested through /ad.
When no ad is available
An empty result is a normal outcome. For /ad, has_ad is false and message contains the original reply. Send that reply as usual.
When an impression is recorded
Serving an ad starts impression accounting before your bot sends it to Telegram. A successful API response does not confirm Telegram delivery. Retrying a request can serve another ad; reports may appear with a delay.