Class LoginUrl
- java.lang.Object
-
- org.telegram.telegrambots.meta.api.objects.LoginUrl
-
- All Implemented Interfaces:
Serializable,BotApiObject,InputBotApiObject,Validable
public class LoginUrl extends Object implements InputBotApiObject, Validable
- Version:
- 4.3 This object represents a parameter of the inline keyboard button used to automatically authorize a user. Serves as a great replacement for the Telegram Login Widget when the user is coming from Telegram. All the user needs to do is tap/click a button and confirm that they want to log in.
- Author:
- Ruben Bermudez
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)StringgetBotUsername()StringgetForwardText()BooleangetRequestWriteAccess()StringgetUrl()inthashCode()LoginUrlsetBotUsername(String botUsername)LoginUrlsetForwardText(String forwardText)LoginUrlsetRequestWriteAccess(Boolean requestWriteAccess)LoginUrlsetUrl(String url)StringtoString()voidvalidate()Validates that mandatory fields are filled and optional objects
-
-
-
Constructor Detail
-
LoginUrl
public LoginUrl()
-
LoginUrl
public LoginUrl(String url)
-
-
Method Detail
-
getUrl
public String getUrl()
-
getForwardText
public String getForwardText()
-
getBotUsername
public String getBotUsername()
-
getRequestWriteAccess
public Boolean getRequestWriteAccess()
-
validate
public void validate() throws TelegramApiValidationExceptionDescription copied from interface:ValidableValidates that mandatory fields are filled and optional objects- Specified by:
validatein interfaceValidable- Throws:
TelegramApiValidationException- If any mandatory field is empty
-
-