Read a Telegram group's bot, and where it could move
The bot that serves the group now, and each bot it could move to in place (`POST …/bot`): the brand's own (the brand's, else the org's, `GET …/brands/{brand}/own-bots`) while Synq's serves it, and Synq's while an own bot does. Each says whether it's in the group, the rights it lacks there of those Synq uses (Invite users via link, Ban users, Pin messages), and Telegram's link that adds it as an admin with them. Read from Telegram now. Needs `org.integrations.view`, and an API with a Telegram bot (409 `telegram_unavailable`).
/v1/orgs/{org}/telegram-groups/{group}/botThe bot that serves the group now, and each bot it could move to in place (POST …/bot): the brand's own (the brand's, else the org's, GET …/brands/{brand}/own-bots) while Synq's serves it, and Synq's while an own bot does. Each says whether it's in the group, the rights it lacks there of those Synq uses (Invite users via link, Ban users, Pin messages), and Telegram's link that adds it as an admin with them. Read from Telegram now. Needs org.integrations.view, and an API with a Telegram bot (409 telegram_unavailable).
Authorization
bearer An org API key (sk_live_…, sk_test_…), or an access token from the Synq issuer (the synq brand, on the accounts host) for this API.
In: header
Path Parameters
The org's id
^org_[0-9a-hjkmnp-tv-z]{26}$The Telegram group's id
^tgg_[0-9a-hjkmnp-tv-z]{26}$Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X GET "https://api.synq.build/v1/orgs/org_01h455vb4pex5vsknk084sn02q/telegram-groups/tgg_01h455vb4pex5vsknk084sn02q/bot" \ -H "Authorization: Bearer $SYNQ_API_KEY"{ "current": { "own_bot_id": "string", "id": "7100000002", "name": "RODAI", "username": "RodaiGateBot" }, "options": [ { "to": "own", "bot": { "own_bot_id": "string", "id": "7100000002", "name": "RODAI", "username": "RodaiGateBot" }, "in_group": true, "missing": [ "invite_users" ], "ready": true, "add_link": "https://t.me/RodaiGateBot?startgroup=tgg_01h455vb4pex5vsknk084sn02q&admin=invite_users+restrict_members+pin_messages" } ]}Disconnect a Telegram group DELETE
Takes the bot out of the group and stops the org's gate there, from now on: whoever is in it stays, a muted person stays muted until an admin lifts it, and join requests wait for the group's other admins. Needs `org.integrations.edit`. Recorded as `telegram_group.disconnected`.
A Telegram group's announced window GET
The group's window: its settings (Synq's defaults for one never saved), its state, the topics Synq has seen, every reminder with when it goes, and the counts: verified, still to verify, and unknown to Synq, with the deadline's pacing. Needs `org.integrations.view`.