# Copyright 2026 Randy W
# Licensed under the Apache License, Version 2.0

# Github Author: https://github.com/TeamKillerX/
# Code: @zxyeor

# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at

# http://www.apache.org/licenses/LICENSE-2.0

# AUTO-GENERATED FILE. DO NOT EDIT MANUALLY.
# Generated by generate_sdk.py

from __future__ import annotations

from typing import Any, Dict

from .core import CoreBotAuth, RequestCall


class TelegramNamespace:
    def __init__(self, client: CoreBotAuth) -> None:
        self._c = client

    async def add_sticker_to_set(self, **kw: Any) -> Dict[str, Any]:
        """Add sticker to set

Use this method to add a new sticker to a set created by the bot. Emoji sticker sets can have up to 200 stickers. Other sticker sets can have up to 120 stickers. Returns True on success.

Source: https://core.telegram.org/bots/api#addstickertoset

        Simple call for POST /api/v2/addStickerToSet.
        """
        return await self._c._post("/api/v2/addStickerToSet", kw)

    def add_sticker_to_set_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Add sticker to set

Use this method to add a new sticker to a set created by the bot. Emoji sticker sets can have up to 200 stickers. Other sticker sets can have up to 120 stickers. Returns True on success.

Source: https://core.telegram.org/bots/api#addstickertoset

        Builder call for POST /api/v2/addStickerToSet.
        """
        return RequestCall(self._c, "POST", "/api/v2/addStickerToSet", kw)

    async def approve_chat_join_request(self, **kw: Any) -> Dict[str, Any]:
        """Approve chat join request

Use this method to approve a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success. Source: https://core.telegram.org/bots/api#approvechatjoinrequest

        Simple call for POST /api/v2/approveChatJoinRequest.
        """
        return await self._c._post("/api/v2/approveChatJoinRequest", kw)

    def approve_chat_join_request_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Approve chat join request

Use this method to approve a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success. Source: https://core.telegram.org/bots/api#approvechatjoinrequest

        Builder call for POST /api/v2/approveChatJoinRequest.
        """
        return RequestCall(self._c, "POST", "/api/v2/approveChatJoinRequest", kw)

    async def ban_chat_member(self, **kw: Any) -> Dict[str, Any]:
        """Ban chat member

Use this method to ban a user in a group, a supergroup or a channel. In the case of supergroups and channels, the user will not be able to return to the chat on their own using invite links, etc., unless [unbanned](https://core.telegram.org/bots/api#unbanchatmember) first. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.

        Simple call for POST /api/v2/banChatMember.
        """
        return await self._c._post("/api/v2/banChatMember", kw)

    def ban_chat_member_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Ban chat member

Use this method to ban a user in a group, a supergroup or a channel. In the case of supergroups and channels, the user will not be able to return to the chat on their own using invite links, etc., unless [unbanned](https://core.telegram.org/bots/api#unbanchatmember) first. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.

        Builder call for POST /api/v2/banChatMember.
        """
        return RequestCall(self._c, "POST", "/api/v2/banChatMember", kw)

    async def ban_chat_sender_chat(self, **kw: Any) -> Dict[str, Any]:
        """Ban chat sender chat

Use this method to ban a channel chat in a supergroup or a channel. Until the chat is [unbanned](https://core.telegram.org/bots/api#unbanchatsenderchat), the owner of the banned chat won’t be able to send messages on behalf of any of their channels. The bot must be an administrator in the supergroup or channel for this to work and must have the appropriate administrator rights. Returns True on success.

        Simple call for POST /api/v2/banChatSenderChat.
        """
        return await self._c._post("/api/v2/banChatSenderChat", kw)

    def ban_chat_sender_chat_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Ban chat sender chat

Use this method to ban a channel chat in a supergroup or a channel. Until the chat is [unbanned](https://core.telegram.org/bots/api#unbanchatsenderchat), the owner of the banned chat won’t be able to send messages on behalf of any of their channels. The bot must be an administrator in the supergroup or channel for this to work and must have the appropriate administrator rights. Returns True on success.

        Builder call for POST /api/v2/banChatSenderChat.
        """
        return RequestCall(self._c, "POST", "/api/v2/banChatSenderChat", kw)

    async def copy_message(self, **kw: Any) -> Dict[str, Any]:
        """Copy message

Source: https://core.telegram.org/bots/api#copymessage

        Simple call for POST /api/v2/copyMessage.
        """
        return await self._c._post("/api/v2/copyMessage", kw)

    def copy_message_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Copy message

Source: https://core.telegram.org/bots/api#copymessage

        Builder call for POST /api/v2/copyMessage.
        """
        return RequestCall(self._c, "POST", "/api/v2/copyMessage", kw)

    async def copy_messages(self, **kw: Any) -> Dict[str, Any]:
        """Copy messages

Source: https://core.telegram.org/bots/api#copymessages

        Simple call for POST /api/v2/copyMessages.
        """
        return await self._c._post("/api/v2/copyMessages", kw)

    def copy_messages_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Copy messages

Source: https://core.telegram.org/bots/api#copymessages

        Builder call for POST /api/v2/copyMessages.
        """
        return RequestCall(self._c, "POST", "/api/v2/copyMessages", kw)

    async def create_new_sticker_set(self, **kw: Any) -> Dict[str, Any]:
        """Create new sticker set

Use this method to create a new sticker set owned by a user. The bot will be able to edit the sticker set thus created. Returns True on success.

Source: https://core.telegram.org/bots/api#createnewstickerset

        Simple call for POST /api/v2/createNewStickerSet.
        """
        return await self._c._post("/api/v2/createNewStickerSet", kw)

    def create_new_sticker_set_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Create new sticker set

Use this method to create a new sticker set owned by a user. The bot will be able to edit the sticker set thus created. Returns True on success.

Source: https://core.telegram.org/bots/api#createnewstickerset

        Builder call for POST /api/v2/createNewStickerSet.
        """
        return RequestCall(self._c, "POST", "/api/v2/createNewStickerSet", kw)

    async def decline_chat_join_request(self, **kw: Any) -> Dict[str, Any]:
        """Decline chat join request

Use this method to decline a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success. Source: https://core.telegram.org/bots/api#declinechatjoinrequest

        Simple call for POST /api/v2/declineChatJoinRequest.
        """
        return await self._c._post("/api/v2/declineChatJoinRequest", kw)

    def decline_chat_join_request_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Decline chat join request

Use this method to decline a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success. Source: https://core.telegram.org/bots/api#declinechatjoinrequest

        Builder call for POST /api/v2/declineChatJoinRequest.
        """
        return RequestCall(self._c, "POST", "/api/v2/declineChatJoinRequest", kw)

    async def delete_message(self, **kw: Any) -> Dict[str, Any]:
        """Delete message

Use this method to delete a message, including service messages, with the following limitations:

A message can only be deleted if it was sent less than 48 hours ago.
Service messages about a supergroup, channel, or forum topic creation can’t be deleted.
A dice message in a private chat can only be deleted if it was sent more than 24 hours ago.
Bots can delete outgoing messages in private chats, groups, and supergroups.
Bots can delete incoming messages in private chats.
Bots granted can_post_messages permissions can delete outgoing messages in channels.
If the bot is an administrator of a group, it can delete any message there.
If the bot has can_delete_messages administrator right in a supergroup or a channel, it can delete any message there.
If the bot has can_manage_direct_messages administrator right in a channel, it can delete any message in the corresponding direct messages chat.

Returns True on success.

Source: https://core.telegram.org/bots/api#deletemessage

        Simple call for POST /api/v2/deleteMessage.
        """
        return await self._c._post("/api/v2/deleteMessage", kw)

    def delete_message_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Delete message

Use this method to delete a message, including service messages, with the following limitations:

A message can only be deleted if it was sent less than 48 hours ago.
Service messages about a supergroup, channel, or forum topic creation can’t be deleted.
A dice message in a private chat can only be deleted if it was sent more than 24 hours ago.
Bots can delete outgoing messages in private chats, groups, and supergroups.
Bots can delete incoming messages in private chats.
Bots granted can_post_messages permissions can delete outgoing messages in channels.
If the bot is an administrator of a group, it can delete any message there.
If the bot has can_delete_messages administrator right in a supergroup or a channel, it can delete any message there.
If the bot has can_manage_direct_messages administrator right in a channel, it can delete any message in the corresponding direct messages chat.

Returns True on success.

Source: https://core.telegram.org/bots/api#deletemessage

        Builder call for POST /api/v2/deleteMessage.
        """
        return RequestCall(self._c, "POST", "/api/v2/deleteMessage", kw)

    async def delete_messages(self, **kw: Any) -> Dict[str, Any]:
        """Delete messages

Use this method to delete multiple messages simultaneously. If some of the specified messages can’t be found, they are skipped. Returns True on success.

Source: https://core.telegram.org/bots/api#deletemessages

        Simple call for POST /api/v2/deleteMessages.
        """
        return await self._c._post("/api/v2/deleteMessages", kw)

    def delete_messages_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Delete messages

Use this method to delete multiple messages simultaneously. If some of the specified messages can’t be found, they are skipped. Returns True on success.

Source: https://core.telegram.org/bots/api#deletemessages

        Builder call for POST /api/v2/deleteMessages.
        """
        return RequestCall(self._c, "POST", "/api/v2/deleteMessages", kw)

    async def delete_sticker_from_set(self, **kw: Any) -> Dict[str, Any]:
        """Delete sticker from set

Use this method to delete a sticker from a set created by the bot. Returns True on success.

Source: https://core.telegram.org/bots/api#deletestickerfromset

        Simple call for POST /api/v2/deleteStickerFromSet.
        """
        return await self._c._post("/api/v2/deleteStickerFromSet", kw)

    def delete_sticker_from_set_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Delete sticker from set

Use this method to delete a sticker from a set created by the bot. Returns True on success.

Source: https://core.telegram.org/bots/api#deletestickerfromset

        Builder call for POST /api/v2/deleteStickerFromSet.
        """
        return RequestCall(self._c, "POST", "/api/v2/deleteStickerFromSet", kw)

    async def delete_sticker_set(self, **kw: Any) -> Dict[str, Any]:
        """Delete sticker set

Use this method to delete a sticker set that was created by the bot. Returns True on success.

Source: https://core.telegram.org/bots/api#deletestickerset

        Simple call for POST /api/v2/deleteStickerSet.
        """
        return await self._c._post("/api/v2/deleteStickerSet", kw)

    def delete_sticker_set_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Delete sticker set

Use this method to delete a sticker set that was created by the bot. Returns True on success.

Source: https://core.telegram.org/bots/api#deletestickerset

        Builder call for POST /api/v2/deleteStickerSet.
        """
        return RequestCall(self._c, "POST", "/api/v2/deleteStickerSet", kw)

    async def delete_webhook(self, **kw: Any) -> Dict[str, Any]:
        """Delete Webhook

        Simple call for DELETE /api/v2/deleteWebhook.
        """
        return await self._c._post("/api/v2/deleteWebhook", kw)

    def delete_webhook_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Delete Webhook

        Builder call for DELETE /api/v2/deleteWebhook.
        """
        return RequestCall(self._c, "DELETE", "/api/v2/deleteWebhook", kw)

    async def forward_message(self, **kw: Any) -> Dict[str, Any]:
        """Forward message

Source: https://core.telegram.org/bots/api#forwardmessage

        Simple call for POST /api/v2/forwardMessage.
        """
        return await self._c._post("/api/v2/forwardMessage", kw)

    def forward_message_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Forward message

Source: https://core.telegram.org/bots/api#forwardmessage

        Builder call for POST /api/v2/forwardMessage.
        """
        return RequestCall(self._c, "POST", "/api/v2/forwardMessage", kw)

    async def forward_messages(self, **kw: Any) -> Dict[str, Any]:
        """Forward messages

Source: https://core.telegram.org/bots/api#forwardmessages

        Simple call for POST /api/v2/forwardMessages.
        """
        return await self._c._post("/api/v2/forwardMessages", kw)

    def forward_messages_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Forward messages

Source: https://core.telegram.org/bots/api#forwardmessages

        Builder call for POST /api/v2/forwardMessages.
        """
        return RequestCall(self._c, "POST", "/api/v2/forwardMessages", kw)

    async def get_chat(self, **kw: Any) -> Dict[str, Any]:
        """Get Chat

Source: https://core.telegram.org/bots/api#getchat

        Simple call for GET /api/v2/getChat.
        """
        return await self._c._get("/api/v2/getChat", kw)

    def get_chat_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Get Chat

Source: https://core.telegram.org/bots/api#getchat

        Builder call for GET /api/v2/getChat.
        """
        return RequestCall(self._c, "GET", "/api/v2/getChat", kw)

    async def get_custom_emoji_stickers(self, **kw: Any) -> Dict[str, Any]:
        """Get custom emoji stickers

Source: https://core.telegram.org/bots/api#getcustomemojistickers

        Simple call for POST /api/v2/getCustomEmojiStickers.
        """
        return await self._c._post("/api/v2/getCustomEmojiStickers", kw)

    def get_custom_emoji_stickers_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Get custom emoji stickers

Source: https://core.telegram.org/bots/api#getcustomemojistickers

        Builder call for POST /api/v2/getCustomEmojiStickers.
        """
        return RequestCall(self._c, "POST", "/api/v2/getCustomEmojiStickers", kw)

    async def get_sticker_set(self, **kw: Any) -> Dict[str, Any]:
        """Get sticker set

Source: https://core.telegram.org/bots/api#getstickerset

        Simple call for POST /api/v2/getStickerSet.
        """
        return await self._c._post("/api/v2/getStickerSet", kw)

    def get_sticker_set_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Get sticker set

Source: https://core.telegram.org/bots/api#getstickerset

        Builder call for POST /api/v2/getStickerSet.
        """
        return RequestCall(self._c, "POST", "/api/v2/getStickerSet", kw)

    async def getme(self, **kw: Any) -> Dict[str, Any]:
        """Getme

        Simple call for GET /api/v2/getme.
        """
        return await self._c._get("/api/v2/getMe", kw)

    def getme_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Getme

        Builder call for GET /api/v2/getMe.
        """
        return RequestCall(self._c, "GET", "/api/v2/getme", kw)

    async def pin_chat_message(self, **kw: Any) -> Dict[str, Any]:
        """Pin chat message

Use this method to add a message to the list of pinned messages in a chat. In private chats and channel direct messages chats, all non-service messages can be pinned. Conversely, the bot must be an administrator with the ‘can_pin_messages’ right or the ‘can_edit_messages’ right to pin messages in groups and channels respectively. Returns True on success. Source: https://core.telegram.org/bots/api#pinchatmessage

        Simple call for POST /api/v2/pinChatMessage.
        """
        return await self._c._post("/api/v2/pinChatMessage", kw)

    def pin_chat_message_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Pin chat message

Use this method to add a message to the list of pinned messages in a chat. In private chats and channel direct messages chats, all non-service messages can be pinned. Conversely, the bot must be an administrator with the ‘can_pin_messages’ right or the ‘can_edit_messages’ right to pin messages in groups and channels respectively. Returns True on success. Source: https://core.telegram.org/bots/api#pinchatmessage

        Builder call for POST /api/v2/pinChatMessage.
        """
        return RequestCall(self._c, "POST", "/api/v2/pinChatMessage", kw)

    async def replace_sticker_in_set(self, **kw: Any) -> Dict[str, Any]:
        """Replace sticker in set

Source: https://core.telegram.org/bots/api#replacestickerinset

        Simple call for POST /api/v2/replaceStickerInSet.
        """
        return await self._c._post("/api/v2/replaceStickerInSet", kw)

    def replace_sticker_in_set_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Replace sticker in set

Source: https://core.telegram.org/bots/api#replacestickerinset

        Builder call for POST /api/v2/replaceStickerInSet.
        """
        return RequestCall(self._c, "POST", "/api/v2/replaceStickerInSet", kw)

    async def send_animation(self, **kw: Any) -> Dict[str, Any]:
        """Send animation

Source: https://core.telegram.org/bots/api#sendanimation

        Simple call for POST /api/v2/sendAnimation.
        """
        return await self._c._post("/api/v2/sendAnimation", kw)

    def send_animation_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Send animation

Source: https://core.telegram.org/bots/api#sendanimation

        Builder call for POST /api/v2/sendAnimation.
        """
        return RequestCall(self._c, "POST", "/api/v2/sendAnimation", kw)

    async def send_media_group(self, **kw: Any) -> Dict[str, Any]:
        """Send media group

Source: https://core.telegram.org/bots/api#sendmediagroup

        Simple call for POST /api/v2/sendMediaGroup.
        """
        return await self._c._post("/api/v2/sendMediaGroup", kw)

    def send_media_group_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Send media group

Source: https://core.telegram.org/bots/api#sendmediagroup

        Builder call for POST /api/v2/sendMediaGroup.
        """
        return RequestCall(self._c, "POST", "/api/v2/sendMediaGroup", kw)

    async def send_message(self, **kw: Any) -> Dict[str, Any]:
        """Send message

Source: https://core.telegram.org/bots/api#sendmessage

        Simple call for POST /api/v2/sendMessage.
        """
        return await self._c._post("/api/v2/sendMessage", kw)

    def send_message_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Send message

Source: https://core.telegram.org/bots/api#sendmessage

        Builder call for POST /api/v2/sendMessage.
        """
        return RequestCall(self._c, "POST", "/api/v2/sendMessage", kw)

    async def send_photo(self, **kw: Any) -> Dict[str, Any]:
        """Send photo message

Source: https://core.telegram.org/bots/api#sendphoto

        Simple call for POST /api/v2/sendPhoto.
        """
        return await self._c._post("/api/v2/sendPhoto", kw)

    def send_photo_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Send photo message

Source: https://core.telegram.org/bots/api#sendphoto

        Builder call for POST /api/v2/sendPhoto.
        """
        return RequestCall(self._c, "POST", "/api/v2/sendPhoto", kw)

    async def send_sticker(self, **kw: Any) -> Dict[str, Any]:
        """Send sticker message

Use this method to send static .WEBP, [animated](https://telegram.org/blog/animated-stickers) .TGS, or [video](https://telegram.org/blog/video-stickers-better-reactions) .WEBM stickers. Source: https://core.telegram.org/bots/api#sendsticker

        Simple call for POST /api/v2/sendSticker.
        """
        return await self._c._post("/api/v2/sendSticker", kw)

    def send_sticker_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Send sticker message

Use this method to send static .WEBP, [animated](https://telegram.org/blog/animated-stickers) .TGS, or [video](https://telegram.org/blog/video-stickers-better-reactions) .WEBM stickers. Source: https://core.telegram.org/bots/api#sendsticker

        Builder call for POST /api/v2/sendSticker.
        """
        return RequestCall(self._c, "POST", "/api/v2/sendSticker", kw)

    async def send_video(self, **kw: Any) -> Dict[str, Any]:
        """Send video message

Source: https://core.telegram.org/bots/api#sendvideo

        Simple call for POST /api/v2/sendVideo.
        """
        return await self._c._post("/api/v2/sendVideo", kw)

    def send_video_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Send video message

Source: https://core.telegram.org/bots/api#sendvideo

        Builder call for POST /api/v2/sendVideo.
        """
        return RequestCall(self._c, "POST", "/api/v2/sendVideo", kw)

    async def set_custom_emoji_sticker_set_thumbnail(self, **kw: Any) -> Dict[str, Any]:
        """Set custom emoji sticker set thumbnail

Use this method to set the thumbnail of a custom emoji sticker set. Returns True on success.

Source: https://core.telegram.org/bots/api#setcustomemojistickersetthumbnail

        Simple call for POST /api/v2/setCustomEmojiStickerSetThumbnail.
        """
        return await self._c._post("/api/v2/setCustomEmojiStickerSetThumbnail", kw)

    def set_custom_emoji_sticker_set_thumbnail_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Set custom emoji sticker set thumbnail

Use this method to set the thumbnail of a custom emoji sticker set. Returns True on success.

Source: https://core.telegram.org/bots/api#setcustomemojistickersetthumbnail

        Builder call for POST /api/v2/setCustomEmojiStickerSetThumbnail.
        """
        return RequestCall(self._c, "POST", "/api/v2/setCustomEmojiStickerSetThumbnail", kw)

    async def users(self, **kw: Any) -> Dict[str, Any]:
        """Users

        Simple call for GET /api/v2/users.
        """
        return await self._c._get("/api/v2/users", kw)

    def users_call(self, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Users

        Builder call for GET /api/v2/users.
        """
        return RequestCall(self._c, "GET", "/api/v2/users", kw)

    async def create_webhook(self, **kw: Any) -> Dict[str, Any]:
        """Create Webhook

        Simple call for POST /api/v2/webhook/{public_id}.
        """
        return await self._c._post(
            "/api/v2/webhook/{public_id}",
            {"public_id": public_id, **kw},
        )

    def create_webhook_call(self, public_id: str, **kw: Any) -> RequestCall[Dict[str, Any]]:
        """Create Webhook

        Builder call for POST /api/v2/webhook/{public_id}.
        """
        return RequestCall(
            self._c,
            "POST",
            "/api/v2/webhook/{public_id}",
            {"public_id": public_id, **kw},
        )
