Interface CreateSubscriptionCheckoutSessionRequest.Builder

  • Method Details

    • appId

      The ID of the app the subscription is for.

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

      The ID of the end user being subscribed. Do not include personally identifiable or otherwise sensitive data in this value.

      Parameters:
      userId - The ID of the end user being subscribed. Do not include personally identifiable or otherwise sensitive data in this value.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • planId

      The plan to subscribe to or change to. Absent to open the hosted pricing page for the buyer to choose; the response then carries planSelectionRequired.pricingUrl.

      Parameters:
      planId - The plan to subscribe to or change to. Absent to open the hosted pricing page for the buyer to choose; the response then carries planSelectionRequired.pricingUrl.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • returnUrl

      The URL the buyer's browser is sent to after they complete payment at checkout. If the buyer is sent to a hosted checkout page, this is that page's success-redirect target. If you omit planId, the buyer chooses a plan on a hosted pricing page. After that checkout, the buyer returns to the hosted pages, not to this URL.

      Parameters:
      returnUrl - The URL the buyer's browser is sent to after they complete payment at checkout. If the buyer is sent to a hosted checkout page, this is that page's success-redirect target. If you omit planId, the buyer chooses a plan on a hosted pricing page. After that checkout, the buyer returns to the hosted pages, not to this URL.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • refreshUrl

      The URL the buyer's browser is sent to if they cancel or abandon the hosted checkout page without completing payment (the checkout page's cancel-redirect target). Point it at a page where the buyer can retry. If you omit planId, the buyer chooses a plan on a hosted pricing page. After that checkout, the buyer returns to the hosted pages, not to this URL.

      Parameters:
      refreshUrl - The URL the buyer's browser is sent to if they cancel or abandon the hosted checkout page without completing payment (the checkout page's cancel-redirect target). Point it at a page where the buyer can retry. If you omit planId, the buyer chooses a plan on a hosted pricing page. After that checkout, the buyer returns to the hosted pages, not to this URL.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • sessionDurationSeconds

      CreateSubscriptionCheckoutSessionRequest.Builder sessionDurationSeconds(Integer sessionDurationSeconds)

      The lifetime of the hosted session, in seconds, counted from this call. Omit to use the service default. It does not set how long pricingUrl works; see expiresAt.

      Parameters:
      sessionDurationSeconds - The lifetime of the hosted session, in seconds, counted from this call. Omit to use the service default. It does not set how long pricingUrl works; see expiresAt.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • clientToken

      A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, the service ignores the request but does not return an error.

      Parameters:
      clientToken - A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, the service ignores the request but does not return an error.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • scope

      Required. The environment: live or sandbox.

      Parameters:
      scope - Required. The environment: live or sandbox.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • scope

      Required. The environment: live or sandbox.

      Parameters:
      scope - Required. The environment: live or sandbox.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • overrideConfiguration

      Description copied from interface: AwsRequest.Builder
      Add an optional request override configuration.
      Specified by:
      overrideConfiguration in interface AwsRequest.Builder
      Parameters:
      overrideConfiguration - The override configuration.
      Returns:
      This object for method chaining.
    • overrideConfiguration

      Description copied from interface: AwsRequest.Builder
      Add an optional request override configuration.
      Specified by:
      overrideConfiguration in interface AwsRequest.Builder
      Parameters:
      builderConsumer - A Consumer to which an empty AwsRequestOverrideConfiguration.Builder will be given.
      Returns:
      This object for method chaining.