Interface Subscription.Builder

  • Method Details

    • appId

      The ID of the app that the subscription belongs to.

      Parameters:
      appId - The ID of the app that the subscription belongs to.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • userId

      Subscription.Builder userId(String userId)

      The opaque end-user identifier that the subscription belongs to.

      Parameters:
      userId - The opaque end-user identifier that the subscription belongs to.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • planId

      Subscription.Builder planId(String planId)

      The ID of the plan that the user is subscribed to.

      Parameters:
      planId - The ID of the plan that the user is subscribed to.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • effectiveAt

      Subscription.Builder effectiveAt(Instant effectiveAt)

      The time when the subscription took effect.

      Parameters:
      effectiveAt - The time when the subscription took effect.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • billingAnchorDate

      Subscription.Builder billingAnchorDate(Instant billingAnchorDate)

      The fixed reference instant the recurring billing cycle is measured from. It is set when the subscription first takes effect and stays fixed as periods roll forward, so it is normally an older date than the current period — not the start of the current period. For the end of the current cycle, use currentPeriodEndsAt on GetSubscriptionResponse (derived from this anchor and the billing cycle) rather than this value.

      Parameters:
      billingAnchorDate - The fixed reference instant the recurring billing cycle is measured from. It is set when the subscription first takes effect and stays fixed as periods roll forward, so it is normally an older date than the current period — not the start of the current period. For the end of the current cycle, use currentPeriodEndsAt on GetSubscriptionResponse (derived from this anchor and the billing cycle) rather than this value.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • billingCycle

      Subscription.Builder billingCycle(String billingCycle)

      The billing cycle of the subscription, such as monthly or annual.

      Parameters:
      billingCycle - The billing cycle of the subscription, such as monthly or annual.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • billingCycle

      Subscription.Builder billingCycle(BillingCycle billingCycle)

      The billing cycle of the subscription, such as monthly or annual.

      Parameters:
      billingCycle - The billing cycle of the subscription, such as monthly or annual.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also: