Package org.drinkless.tdlib

# Class TdApi.AcceptOauthRequest

java.lang.Object
org.drinkless.tdlib.TdApi.Object
org.drinkless.tdlib.TdApi.Function<TdApi.HttpUrl>
org.drinkless.tdlib.TdApi.AcceptOauthRequest

Enclosing class:
  `TdApi`

public static class TdApi.AcceptOauthRequest extends TdApi.Function<TdApi.HttpUrl>
Accepts an OAuth authorization request. Returns an HTTP URL to open after successful authorization. May return an empty link if just a toast about successful login has to be shown.

Returns `HttpUrl`

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from class org.drinkless.tdlib.TdApi.Function

  `TdApi.Function.Constructors`

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `boolean`
  `allowPhoneNumberAccess`
  Pass true if the current user allowed the bot that was returned in getOauthLinkInfo, to access their phone number.
  `boolean`
  `allowWriteAccess`
  Pass true if the current user allowed the bot that was returned in getOauthLinkInfo, to send them messages.
  `static final int`
  `CONSTRUCTOR`
  Identifier uniquely determining type of the object.
  `String`
  `matchCode`
  The matching code chosen by the user.
  `String`
  `url`
  URL of the OAuth deep link.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AcceptOauthRequest()`
  Default constructor for a function, which accepts an OAuth authorization request.
  `AcceptOauthRequest(String url, String matchCode, boolean allowWriteAccess, boolean allowPhoneNumberAccess)`
  Creates a function, which accepts an OAuth authorization request.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getConstructor()`
  Returns an identifier uniquely determining type of the object.

  ### Methods inherited from class org.drinkless.tdlib.TdApi.Function

  `toString`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Field Details

  - ### url

    public String url
    URL of the OAuth deep link.

  - ### matchCode

    public String matchCode
    The matching code chosen by the user.

  - ### allowWriteAccess

    public boolean allowWriteAccess
    Pass true if the current user allowed the bot that was returned in getOauthLinkInfo, to send them messages.

  - ### allowPhoneNumberAccess

    public boolean allowPhoneNumberAccess
    Pass true if the current user allowed the bot that was returned in getOauthLinkInfo, to access their phone number.

  - ### CONSTRUCTOR

    public static final int CONSTRUCTOR
    Identifier uniquely determining type of the object.
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### AcceptOauthRequest

    public AcceptOauthRequest()
    Default constructor for a function, which accepts an OAuth authorization request. Returns an HTTP URL to open after successful authorization. May return an empty link if just a toast about successful login has to be shown.

    Returns `HttpUrl`

  - ### AcceptOauthRequest

    public AcceptOauthRequest(String url, String matchCode, boolean allowWriteAccess, boolean allowPhoneNumberAccess)
    Creates a function, which accepts an OAuth authorization request. Returns an HTTP URL to open after successful authorization. May return an empty link if just a toast about successful login has to be shown.

    Returns `HttpUrl`

    Parameters:
      `url` - URL of the OAuth deep link.
      `matchCode` - The matching code chosen by the user.
      `allowWriteAccess` - Pass true if the current user allowed the bot that was returned in getOauthLinkInfo, to send them messages.
      `allowPhoneNumberAccess` - Pass true if the current user allowed the bot that was returned in getOauthLinkInfo, to access their phone number.

- ## Method Details

  - ### getConstructor

    public int getConstructor()
    Description copied from class: `TdApi.Object`
    Returns an identifier uniquely determining type of the object.
    Specified by:
      `getConstructor` in class `TdApi.Function<TdApi.HttpUrl>`
    Returns:
      this.CONSTRUCTOR