Package org.drinkless.tdlib

# Class TdApi.StarSubscription

java.lang.Object
org.drinkless.tdlib.TdApi.Object
org.drinkless.tdlib.TdApi.StarSubscription

Enclosing class:
  `TdApi`

public static class TdApi.StarSubscription extends TdApi.Object
Contains information about subscription to a channel chat, a bot, or a business account that was paid in Telegram Stars.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `long`
  `chatId`
  Identifier of the chat that is subscribed.
  `static final int`
  `CONSTRUCTOR`
  Identifier uniquely determining type of the object.
  `int`
  `expirationDate`
  Point in time (Unix timestamp) when the subscription will expire or expired.
  `String`
  `id`
  Unique identifier of the subscription.
  `boolean`
  `isCanceled`
  True, if the subscription was canceled.
  `boolean`
  `isExpiring`
  True, if the subscription expires soon and there are no enough Telegram Stars on the user's balance to extend it.
  `TdApi.StarSubscriptionPricing`
  `pricing`
  The subscription plan.
  `TdApi.StarSubscriptionType`
  `type`
  Type of the subscription.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `StarSubscription()`
  Contains information about subscription to a channel chat, a bot, or a business account that was paid in Telegram Stars.
  `StarSubscription(String id, long chatId, int expirationDate, boolean isCanceled, boolean isExpiring, TdApi.StarSubscriptionPricing pricing, TdApi.StarSubscriptionType type)`
  Contains information about subscription to a channel chat, a bot, or a business account that was paid in Telegram Stars.

- ## 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.Object

  `toString`

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

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

- ## Field Details

  - ### id

    public String id
    Unique identifier of the subscription.

  - ### chatId

    public long chatId
    Identifier of the chat that is subscribed.

  - ### expirationDate

    public int expirationDate
    Point in time (Unix timestamp) when the subscription will expire or expired.

  - ### isCanceled

    public boolean isCanceled
    True, if the subscription was canceled.

  - ### isExpiring

    public boolean isExpiring
    True, if the subscription expires soon and there are no enough Telegram Stars on the user's balance to extend it.

  - ### pricing

    public TdApi.StarSubscriptionPricing pricing
    The subscription plan.

  - ### type

    public TdApi.StarSubscriptionType type
    Type of the subscription.

  - ### CONSTRUCTOR

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

- ## Constructor Details

  - ### StarSubscription

    public StarSubscription()
    Contains information about subscription to a channel chat, a bot, or a business account that was paid in Telegram Stars.

  - ### StarSubscription

    public StarSubscription(String id, long chatId, int expirationDate, boolean isCanceled, boolean isExpiring, TdApi.StarSubscriptionPricing pricing, TdApi.StarSubscriptionType type)
    Contains information about subscription to a channel chat, a bot, or a business account that was paid in Telegram Stars.
    Parameters:
      `id` - Unique identifier of the subscription.
      `chatId` - Identifier of the chat that is subscribed.
      `expirationDate` - Point in time (Unix timestamp) when the subscription will expire or expired.
      `isCanceled` - True, if the subscription was canceled.
      `isExpiring` - True, if the subscription expires soon and there are no enough Telegram Stars on the user's balance to extend it.
      `pricing` - The subscription plan.
      `type` - Type of the subscription.

- ## 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.Object`
    Returns:
      this.CONSTRUCTOR