Hide navigation sidebar
Hide table of contents sidebar
Skip to content
Back to top
View this page
Toggle table of contents sidebar

# PassportElementError

class telegram.PassportElementError(source, type, message, *, api_kwargs=None)

  Bases: `telegram.TelegramObject`

  Baseclass for the PassportElementError* classes.

  This object represents an error in the Telegram Passport element which was submitted that should be resolved by the user.

  Objects of this class are comparable in terms of equality. Two objects of this class are considered equal, if their `source` and `type` are equal.

  Use In

  `telegram.Bot.set_passport_data_errors()`

  Parameters:

    - source (`str`) – Error source.

    - type (`str`) – The section of the user’s Telegram Passport which has the error.

    - message (`str`) – Error message.

  source

    Error source.

    Type:

      `str`

  type

    The section of the user’s Telegram Passport which has the error.

    Type:

      `str`

  message

    Error message.

    Type:

      `str`