getBusinessConnection

Returns: BusinessConnection

class aiogram.methods.get_business_connection.GetBusinessConnection(*, business_connection_id: str, **extra_data: Any)[source]

Use this method to get information about the connection of the bot with a business account. Returns a aiogram.types.business_connection.BusinessConnection object on success.

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

business_connection_id: str

Unique identifier of the business connection

model_computed_fields: ClassVar[Dict[str, ComputedFieldInfo]] = {}

A dictionary of computed field names and their corresponding ComputedFieldInfo objects.

model_post_init(context: Any, /) None

We need to both initialize private attributes and call the user-defined model_post_init method.

Usage

As bot method

result: BusinessConnection = await bot.get_business_connection(...)

Method as object

Imports:

  • from aiogram.methods.get_business_connection import GetBusinessConnection

  • alias: from aiogram.methods import GetBusinessConnection

With specific bot

result: BusinessConnection = await bot(GetBusinessConnection(...))