Class: Google::Apis::ResellerV1::Subscription
- Inherits:
-
Object
- Object
- Google::Apis::ResellerV1::Subscription
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/reseller_v1/classes.rb,
lib/google/apis/reseller_v1/representations.rb,
lib/google/apis/reseller_v1/representations.rb
Overview
JSON template for a subscription.
Defined Under Namespace
Classes: Plan, TransferInfo, TrialSettings
Instance Attribute Summary collapse
-
#billing_method ⇒ String
Read-only field that returns the current billing method for a subscription.
-
#creation_time ⇒ Fixnum
The
creationTimeproperty is the date when subscription was created. -
#customer_domain ⇒ String
Primary domain name of the customer Corresponds to the JSON property
customerDomain. -
#customer_id ⇒ String
This property will always be returned in a response as the unique identifier generated by Google.
-
#deal_code ⇒ String
Google-issued code (100 char max) for discounted pricing on subscription plans.
-
#kind ⇒ String
Identifies the resource as a Subscription.
-
#plan ⇒ Google::Apis::ResellerV1::Subscription::Plan
The
planproperty is required. -
#purchase_order_id ⇒ String
This is an optional property.
-
#renewal_settings ⇒ Google::Apis::ResellerV1::RenewalSettings
JSON template for a subscription renewal settings.
-
#resource_ui_url ⇒ String
URL to customer's Subscriptions page in the Admin console.
-
#seats ⇒ Google::Apis::ResellerV1::Seats
JSON template for subscription seats.
-
#sku_id ⇒ String
A required property.
-
#sku_name ⇒ String
Read-only external display name for a product's SKU assigned to a customer in the subscription.
-
#status ⇒ String
This is an optional property.
-
#subscription_id ⇒ String
The
subscriptionIdis the subscription identifier and is unique for each customer. -
#suspension_reasons ⇒ Array<String>
Read-only field containing an enumerable of all the current suspension reasons for a subscription.
-
#transfer_info ⇒ Google::Apis::ResellerV1::Subscription::TransferInfo
Read-only transfer related information for the subscription.
-
#trial_settings ⇒ Google::Apis::ResellerV1::Subscription::TrialSettings
The G Suite annual commitment and flexible payment plans can be in a 30-day free trial.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Subscription
constructor
A new instance of Subscription.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Subscription
Returns a new instance of Subscription.
524 525 526 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 524 def initialize(**args) update!(**args) end |
Instance Attribute Details
#billing_method ⇒ String
Read-only field that returns the current billing method for a subscription.
Corresponds to the JSON property billingMethod
402 403 404 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 402 def billing_method @billing_method end |
#creation_time ⇒ Fixnum
The creationTime property is the date when subscription was created. It is
in milliseconds using the Epoch format. See an example Epoch converter.
Corresponds to the JSON property creationTime
408 409 410 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 408 def creation_time @creation_time end |
#customer_domain ⇒ String
Primary domain name of the customer
Corresponds to the JSON property customerDomain
413 414 415 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 413 def customer_domain @customer_domain end |
#customer_id ⇒ String
This property will always be returned in a response as the unique identifier
generated by Google. In a request, this property can be either the primary
domain or the unique identifier generated by Google.
Corresponds to the JSON property customerId
420 421 422 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 420 def customer_id @customer_id end |
#deal_code ⇒ String
Google-issued code (100 char max) for discounted pricing on subscription plans.
Deal code must be included in insert requests in order to receive
discounted rate. This property is optional, regular pricing applies if left
empty.
Corresponds to the JSON property dealCode
428 429 430 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 428 def deal_code @deal_code end |
#kind ⇒ String
Identifies the resource as a Subscription. Value: reseller#subscription
Corresponds to the JSON property kind
433 434 435 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 433 def kind @kind end |
#plan ⇒ Google::Apis::ResellerV1::Subscription::Plan
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.
Corresponds to the JSON property plan
440 441 442 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 440 def plan @plan end |
#purchase_order_id ⇒ String
This is an optional property. This purchase order (PO) information is for
resellers to use for their company tracking usage. If a purchaseOrderId
value is given it appears in the API responses and shows up in the invoice.
The property accepts up to 80 plain text characters.
Corresponds to the JSON property purchaseOrderId
448 449 450 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 448 def purchase_order_id @purchase_order_id end |
#renewal_settings ⇒ Google::Apis::ResellerV1::RenewalSettings
JSON template for a subscription renewal settings.
Corresponds to the JSON property renewalSettings
453 454 455 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 453 def renewal_settings @renewal_settings end |
#resource_ui_url ⇒ String
URL to customer's Subscriptions page in the Admin console. The read-only URL
is generated by the API service. This is used if your client application
requires the customer to complete a task using the Subscriptions page in the
Admin console.
Corresponds to the JSON property resourceUiUrl
461 462 463 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 461 def resource_ui_url @resource_ui_url end |
#seats ⇒ Google::Apis::ResellerV1::Seats
JSON template for subscription seats.
Corresponds to the JSON property seats
466 467 468 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 466 def seats @seats end |
#sku_id ⇒ String
A required property. The skuId is a unique system identifier for a product's
SKU assigned to a customer in the subscription. For products and SKUs
available in this version of the API, see Product and SKU IDs.
Corresponds to the JSON property skuId
473 474 475 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 473 def sku_id @sku_id end |
#sku_name ⇒ String
Read-only external display name for a product's SKU assigned to a customer in
the subscription. SKU names are subject to change at Google's discretion. For
products and SKUs available in this version of the API, see Product and SKU
IDs.
Corresponds to the JSON property skuName
481 482 483 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 481 def sku_name @sku_name end |
#status ⇒ String
This is an optional property.
Corresponds to the JSON property status
486 487 488 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 486 def status @status end |
#subscription_id ⇒ String
The subscriptionId is the subscription identifier and is unique for each
customer. This is a required property. Since a subscriptionId changes when a
subscription is updated, we recommend not using this ID as a key for
persistent data. Use the subscriptionId as described in retrieve all
reseller subscriptions.
Corresponds to the JSON property subscriptionId
495 496 497 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 495 def subscription_id @subscription_id end |
#suspension_reasons ⇒ Array<String>
Read-only field containing an enumerable of all the current suspension reasons
for a subscription. It is possible for a subscription to have many concurrent,
overlapping suspension reasons. A subscription's STATUS is SUSPENDED until
all pending suspensions are removed. Possible options include: -
PENDING_TOS_ACCEPTANCE - The customer has not logged in and accepted the G
Suite Resold Terms of Services. - RENEWAL_WITH_TYPE_CANCEL - The customer's
commitment ended and their service was cancelled at the end of their term. -
RESELLER_INITIATED - A manual suspension invoked by a Reseller. -
TRIAL_ENDED - The customer's trial expired without a plan selected. - OTHER
- The customer is suspended for an internal Google reason (e.g. abuse or
otherwise).
Corresponds to the JSON property
suspensionReasons
510 511 512 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 510 def suspension_reasons @suspension_reasons end |
#transfer_info ⇒ Google::Apis::ResellerV1::Subscription::TransferInfo
Read-only transfer related information for the subscription. For more
information, see retrieve transferable subscriptions for a customer.
Corresponds to the JSON property transferInfo
516 517 518 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 516 def transfer_info @transfer_info end |
#trial_settings ⇒ Google::Apis::ResellerV1::Subscription::TrialSettings
The G Suite annual commitment and flexible payment plans can be in a 30-day
free trial. For more information, see the API concepts.
Corresponds to the JSON property trialSettings
522 523 524 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 522 def trial_settings @trial_settings end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 |
# File 'lib/google/apis/reseller_v1/classes.rb', line 529 def update!(**args) @billing_method = args[:billing_method] if args.key?(:billing_method) @creation_time = args[:creation_time] if args.key?(:creation_time) @customer_domain = args[:customer_domain] if args.key?(:customer_domain) @customer_id = args[:customer_id] if args.key?(:customer_id) @deal_code = args[:deal_code] if args.key?(:deal_code) @kind = args[:kind] if args.key?(:kind) @plan = args[:plan] if args.key?(:plan) @purchase_order_id = args[:purchase_order_id] if args.key?(:purchase_order_id) @renewal_settings = args[:renewal_settings] if args.key?(:renewal_settings) @resource_ui_url = args[:resource_ui_url] if args.key?(:resource_ui_url) @seats = args[:seats] if args.key?(:seats) @sku_id = args[:sku_id] if args.key?(:sku_id) @sku_name = args[:sku_name] if args.key?(:sku_name) @status = args[:status] if args.key?(:status) @subscription_id = args[:subscription_id] if args.key?(:subscription_id) @suspension_reasons = args[:suspension_reasons] if args.key?(:suspension_reasons) @transfer_info = args[:transfer_info] if args.key?(:transfer_info) @trial_settings = args[:trial_settings] if args.key?(:trial_settings) end |