getManagedBotAccessSettings
Mendapatkan pengaturan akses bot terkelola (Bot API 10.0).
Nilai kembalian: Jika berhasil, mengembalikan BotAccessSettings.
Parameter
| Parameter | Tipe | Wajib | Deskripsi |
|---|---|---|---|
user_id | Integer | Ya | ID bot terkelola |
Contoh permintaan
curl
curl -s -X POST "https://api.telegram.org/bot$TOKEN/getManagedBotAccessSettings" \
-H "Content-Type: application/json" \
-d '{"user_id":123456789}'
Python
import requests
TOKEN = "123456789:AAEexampleTokenReplaceWithYours"
resp = requests.post(
f"https://api.telegram.org/bot{TOKEN}/getManagedBotAccessSettings",
json={
"user_id": 123456789
},
timeout=30,
)
print(resp.json())
JavaScript
const TOKEN = "123456789:AAEexampleTokenReplaceWithYours";
const res = await fetch(`https://api.telegram.org/bot${TOKEN}/getManagedBotAccessSettings`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"user_id": 123456789
}),
});
console.log(await res.json());
Panduan langkah demi langkah: Cara Membuat Bot Telegram: dari BotFather sampai Pesan Pertama
Metode terkait
getMeMengembalikan informasi bot.getMyCommandsMengembalikan daftar perintah bot saat ini.setMyCommandsMengatur daftar perintah bot.deleteMyCommandsMenghapus perintah bot.getMyNameMengembalikan nama bot.setMyNameMengatur nama bot.getMyDescriptionMengembalikan deskripsi bot.setMyDescriptionMengatur deskripsi bot.getMyShortDescriptionMengembalikan deskripsi singkat bot.setMyShortDescriptionMengatur deskripsi singkat bot.setMyProfilePhotoMengatur foto profil bot.removeMyProfilePhotoMenghapus foto profil bot.