Get

Get a specific subscription

2 variables
33 variables

Get a specific subscription

Authorization

To use this building block you will have to grant access to at least one of the following scopes:

  • Manage users on your domain
  • Manage users on your domain

Input

This building block consumes 2 input parameters

  = Parameter name
  = Format

customerId STRING Required

Either the customer's primary domain name or the customer's unique identifier. If using the domain name, we do not recommend using a customerId as a key for persistent data. If the domain name for a customerId is changed, the Google system automatically updates

subscriptionId STRING Required

This is a required property. The subscriptionId is the subscription identifier and is unique for each customer. Since a subscriptionId changes when a subscription is updated, we recommend to not use this ID as a key for persistent data. And the subscriptionId can be found using the retrieve all reseller subscriptions method

Output

This building block provides 33 output parameters

  = Parameter name
  = Format

billingMethod STRING

Read-only field that returns the current billing method for a subscription

creationTime INTEGER

The creationTime property is the date when subscription was created. It is in milliseconds using the Epoch format. See an example Epoch converter

customerDomain STRING

Primary domain name of the customer

customerId 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

dealCode 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

kind STRING

Identifies the resource as a Subscription. Value: reseller#subscription

plan OBJECT

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

plan.commitmentInterval OBJECT

In this version of the API, annual commitment plan's interval is one year. Note: When billingMethod value is OFFLINE, the subscription property object plan.commitmentInterval is omitted in all API responses

plan.commitmentInterval.endTime INTEGER

An annual commitment plan's interval's endTime in milliseconds using the UNIX Epoch format. See an example Epoch converter

plan.commitmentInterval.startTime INTEGER

An annual commitment plan's interval's startTime in milliseconds using UNIX Epoch format. See an example Epoch converter

plan.isCommitmentPlan BOOLEAN

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.

plan.planName STRING

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. Caution: ANNUAL_MONTHLY_PAY is returned as ANNUAL in all API responses.
  • 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.
  • FREE — The free plan is exclusive to the Cloud Identity SKU and does not incur any billing.

purchaseOrderId 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

renewalSettings OBJECT

JSON template for a subscription renewal settings

renewalSettings.kind STRING

Identifies the resource as a subscription renewal setting. Value: subscriptions#renewalSettings

renewalSettings.renewalType STRING

Renewal settings for the annual commitment plan. For more detailed information, see renewal options in the administrator help center. When renewing a subscription, the renewalType is a required property

resourceUiUrl 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

seats OBJECT

JSON template for subscription seats

seats.kind STRING

Identifies the resource as a subscription seat setting. Value: subscriptions#seats

seats.licensedNumberOfSeats INTEGER

Read-only field containing the current number of users that are assigned a license for the product defined in skuId. This field's value is equivalent to the numerical count of users returned by the Enterprise License Manager API method: listForProductAndSku

seats.maximumNumberOfSeats INTEGER

This is a required property and is exclusive to subscriptions with FLEXIBLE or TRIAL plans. This property sets the maximum number of licensed users allowed on a subscription. This quantity can be increased up to the maximum limit defined in the reseller's contract. The minimum quantity is the current number of users in the customer account. Note: G Suite subscriptions automatically assign a license to every user

seats.numberOfSeats INTEGER

This is a required property and is exclusive to subscriptions with ANNUAL_MONTHLY_PAY and ANNUAL_YEARLY_PAY plans. This property sets the maximum number of licenses assignable to users on a subscription. The reseller can add more licenses, but once set, the numberOfSeats cannot be reduced until renewal. The reseller is invoiced based on the numberOfSeats value regardless of how many of these user licenses are assigned. Note: G Suite subscriptions automatically assign a license to every user

skuId 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

skuName 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

status STRING

This is an optional property

subscriptionId 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

suspensionReasons[] STRING

transferInfo OBJECT

Read-only transfer related information for the subscription. For more information, see retrieve transferable subscriptions for a customer

transferInfo.minimumTransferableSeats INTEGER

When inserting a subscription, this is the minimum number of seats listed in the transfer order for this product. For example, if the customer has 20 users, the reseller cannot place a transfer order of 15 seats. The minimum is 20 seats

transferInfo.transferabilityExpirationTime INTEGER

The time when transfer token or intent to transfer will expire. The time is in milliseconds using UNIX Epoch format

trialSettings OBJECT

The G Suite annual commitment and flexible payment plans can be in a 30-day free trial. For more information, see the API concepts

trialSettings.isInTrial BOOLEAN

Determines if a subscription's plan is in a 30-day free trial or not:

  • true — The plan is in trial.
  • false — The plan is not in trial.

trialSettings.trialEndTime INTEGER

Date when the trial ends. The value is in milliseconds using the UNIX Epoch format. See an example Epoch converter