Class: Google::Apis::ResellerV1::Subscription::Plan

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/reseller_v1/classes.rb,
generated/google/apis/reseller_v1/representations.rb,
generated/google/apis/reseller_v1/representations.rb

Overview

The plan property is required. In this version of the API, the G Suite plans are the flexible plan, annual commitment plan, and the 30-day free trial plan. For more information about the API"s payment plans, see the API concepts.

Defined Under Namespace

Classes: CommitmentInterval

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Plan

Returns a new instance of Plan



567
568
569
# File 'generated/google/apis/reseller_v1/classes.rb', line 567

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#commitment_intervalGoogle::Apis::ResellerV1::Subscription::Plan::CommitmentInterval

In this version of the API, annual commitment plan's interval is one year. Corresponds to the JSON property commitmentInterval



541
542
543
# File 'generated/google/apis/reseller_v1/classes.rb', line 541

def commitment_interval
  @commitment_interval
end

#is_commitment_planBoolean Also known as: is_commitment_plan?

The isCommitmentPlan property's boolean value identifies the plan as an annual commitment plan:

  • true — The subscription's plan is an annual commitment plan.
  • false — The plan is not an annual commitment plan. Corresponds to the JSON property isCommitmentPlan

Returns:

  • (Boolean)


549
550
551
# File 'generated/google/apis/reseller_v1/classes.rb', line 549

def is_commitment_plan
  @is_commitment_plan
end

#plan_nameString

The planName property is required. This is the name of the subscription's plan. For more information about the Google payment plans, see the API concepts. Possible values are:

  • ANNUAL_MONTHLY_PAY — The annual commitment plan with monthly payments
  • ANNUAL_YEARLY_PAY — The annual commitment plan with yearly payments
  • FLEXIBLE — The flexible plan
  • TRIAL — The 30-day free trial plan. A subscription in trial will be suspended after the 30th free day if no payment plan is assigned. Calling changePlan will assign a payment plan to a trial but will not activate the plan. A trial will automatically begin its assigned payment plan after its 30th free day or immediately after calling startPaidService. Corresponds to the JSON property planName

Returns:

  • (String)


565
566
567
# File 'generated/google/apis/reseller_v1/classes.rb', line 565

def plan_name
  @plan_name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



572
573
574
575
576
# File 'generated/google/apis/reseller_v1/classes.rb', line 572

def update!(**args)
  @commitment_interval = args[:commitment_interval] if args.key?(:commitment_interval)
  @is_commitment_plan = args[:is_commitment_plan] if args.key?(:is_commitment_plan)
  @plan_name = args[:plan_name] if args.key?(:plan_name)
end