Telegram Bot API
🌐 Türkçe

editChatSubscriptionInviteLink

Kategori: Sohbet · Bot API 10.3 · Resmi dokümantasyon

Abonelik davet bağlantısını düzenler.

Dönüş değeri: Başarılı olduğunda ChatInviteLink döndürür.

Parametreler

ParametreTürZorunluAçıklama
chat_idInteger or StringEvetKanal ID'si
invite_linkStringEvetDüzenlenecek davet bağlantısı
nameStringİsteğe bağlıYeni bağlantı adı

Parametre açıklamaları kısa özetlerdir; tam metin için resmi dokümantasyona bakın.

Örnek istek

curl

curl -s -X POST "https://api.telegram.org/bot$TOKEN/editChatSubscriptionInviteLink" \
  -H "Content-Type: application/json" \
  -d '{"chat_id":123456789,"invite_link":"https://t.me/+AbCdEfGhIjKl"}'

Python

import requests

TOKEN = "123456789:AAEexampleTokenReplaceWithYours"
resp = requests.post(
    f"https://api.telegram.org/bot{TOKEN}/editChatSubscriptionInviteLink",
    json={
        "chat_id": 123456789,
        "invite_link": "https://t.me/+AbCdEfGhIjKl"
    },
    timeout=30,
)
print(resp.json())

JavaScript

const TOKEN = "123456789:AAEexampleTokenReplaceWithYours";
const res = await fetch(`https://api.telegram.org/bot${TOKEN}/editChatSubscriptionInviteLink`, {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    "chat_id": 123456789,
    "invite_link": "https://t.me/+AbCdEfGhIjKl"
  }),
});
console.log(await res.json());

Adım adım rehber: Telegram bot nasıl yapılır? BotFather ile adım adım bot oluşturma