訂購客戶帳戶後,您可以建立多個不同的訂閱項目:
- 年約訂閱方案
- 彈性訂閱方案
- 免費試用 30 天
- 以折扣價訂閱
如要進一步瞭解這些訂閱項目使用的產品,請參閱產品和 SKU 頁面。
如果您未訂購此客戶的帳戶,可轉移訂閱。
擁有 customerType = 'team'
的客戶只能購買 Google Workspace 的 Essentials 版本和 Enterprise Essentials 版本。如果您嘗試購買其他 Google Workspace 訂閱,就會收到 Customer is not eligible to purchase this subscription
錯誤訊息。客戶購買 Essentials 或依用量計費的訂閱項目可能無法處理年約,且具有有限的升級和降級選項。
建立訂閱項目
如要為新建立的客戶帳戶建立訂閱項目,請使用下列 POST
HTTP 要求並加入授權權杖:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/CUSTOMER_ID/subscriptions
CUSTOMER_ID
是客戶的主網域名稱或在擷取經銷商客戶帳戶時傳回的客戶專屬 ID。
建立年約方案
針對年約訂閱方案,並非所有 SKU 都會有相同的預設續約設定。建議您一律傳遞 renewalSettings
。建立包含 10 個名額的年約方案訂閱項目:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/CUSTOMER_ID/subscriptions { "kind": "reseller#subscription", "customerId": "CUSTOMER_ID", "skuId": "SKU_ID", "plan": { "planName": "ANNUAL_MONTHLY_PAY" }, "seats": { "kind": "subscriptions#seats", "numberOfSeats": 10 }, renewalSettings: { "renewalType": 'RENEW_CURRENT_USERS_MONTHLY_PAY' }, "purchaseOrderId": "PURCHASE_ORDER_ID" }
更改下列內容:
CUSTOMER_ID
:客戶的主網域名稱或客戶的專屬 ID。SKU_ID
:專屬的存貨單位 (SKU) ID。詳情請參閱產品與 SKU ID 一文。PURCHASE_ORDER_ID
:選用的訂購單 ID,可用於追蹤使用情況。
成功的回應會傳回 HTTP 200
狀態,以及新訂閱項目的年約方案設定。在所有 API 回應中,ANNUAL_MONTHLY_PAY
會傳回 ANNUAL
。
以下是年約方案回覆範例:
{
"kind": "reseller#subscription",
"customerId": "C0123456",
"subscriptionId": "123",
"billingMethod": "ONLINE",
"skuId": "1010020028",
"creationTime": "1331647980142",
"plan": {
"planName": "ANNUAL",
"isCommitmentPlan": true,
"commitmentInterval": {
"startTime": "1331647980142",
"endTime": "1363183980142"
}
},
"seats": {
"kind": "subscriptions#seats",
"numberOfSeats": 10,
"licensedNumberOfSeats": 10
},
"trialSettings": {
"isInTrial": false
},
"renewalSettings": {
"kind": "subscriptions#renewalSettings",
"renewalType": "SWITCH_TO_PAY_AS_YOU_GO"
},
"purchaseOrderId": "my_example.com_annual_1",
"status": "ACTIVE",
"customerDomain": "my_example.com",
"skuName": "Google Workspace Business Standard"
}
制定彈性方案
如要為新建立的客戶帳戶建立彈性訂閱,請使用下列 POST
HTTP 要求並加入授權權杖:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/CUSTOMER_ID/subscriptions { "kind": "reseller#subscription", "customerId": "CUSTOMER_ID", "skuId": "SKU_ID", "plan": { "planName": "FLEXIBLE" }, "seats": { "kind": "subscriptions#seats", "maximumNumberOfSeats": 10 }, "purchaseOrderId": "PURCHASE_ORDER_ID" }
更改下列內容:
CUSTOMER_ID
:客戶的主網域名稱或客戶的專屬 ID。SKU_ID
:專屬的存貨單位 (SKU) ID。詳情請參閱產品與 SKU ID 一文。PURCHASE_ORDER_ID
:選用的訂購單 ID,可用於追蹤使用情況。
以下是彈性方案的回應範例:
{
"kind": "reseller#subscription",
"customerId": "C0123456",
"subscriptionId": "123",
"billingMethod": "ONLINE",
"skuId": "1010020028",
"creationTime": "1331647980142",
"plan": {
"planName": "FLEXIBLE",
"isCommitmentPlan": false
},
"seats": {
"kind": "subscriptions#seats",
"maximumNumberOfSeats": 10,
"licensedNumberOfSeats": 0
},
"trialSettings": {
"isInTrial": false
},
"purchaseOrderId": "my_example_flex_1",
"status": "ACTIVE",
"customerDomain": "my_example.com",
"skuName": "Google Workspace Business Standard"
}
建立免費試用
如要為新建立的客戶帳戶建立 30 天的免費試用訂閱,請使用下列 POST
HTTP 要求並加入授權權杖:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/CUSTOMER_ID/subscriptions { "kind": "reseller#subscription", "customerId": "CUSTOMER_ID", "skuId": "SKU_ID", "plan": { "planName": "TRIAL" }, "seats": { "kind": "subscriptions#seats", "maximumNumberOfSeats": 10 }, "purchaseOrderId": "PURCHASE_ORDER_ID" }
更改下列內容:
CUSTOMER_ID
:客戶的主網域名稱或客戶的專屬 ID。SKU_ID
:專屬的存貨單位 (SKU) ID。詳情請參閱產品與 SKU ID 一文。PURCHASE_ORDER_ID
:選用的訂購單 ID,可用於追蹤使用情況。
以下是「30 天免費試用方案」的回應範例:
{
"kind": "reseller#subscription",
"customerId": "C0123456",
"subscriptionId": "123",
"billingMethod": "ONLINE",
"skuId": "1010020028",
"creationTime": "1331647980142",
"plan": {
"planName": "TRIAL",
"isCommitmentPlan": false
},
"seats": {
"kind": "subscriptions#seats",
"maximumNumberOfSeats": 10,
"licensedNumberOfSeats": 0
},
"trialSettings": {
"isInTrial": true,
"trialEndTime": "1331648420142"
},
"purchaseOrderId": "my_example_trial_1",
"status": "ACTIVE",
"customerDomain": "my_example.com",
"skuName": "Google Workspace Business Standard"
}
建立折扣訂閱方案
Google 可能會提供優惠代碼,讓您以折扣費率建立訂閱項目。如要針對訂閱項目提供折扣,您必須在訂閱 insert
呼叫中提供交易代碼。如果客戶是從原始 SKU 變更,則會移除折扣。
如要為新建的客戶帳戶建立折扣年約訂閱方案,請使用下列 POST
HTTP 要求並加入授權權杖:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/CUSTOMER_ID/subscriptions { "kind": "reseller#subscription", "customerId": "CUSTOMER_ID", "skuId": "SKU_ID", "plan": { "planName": "ANNUAL_MONTHLY_PAY" }, "seats": { "kind": "subscriptions#seats", "numberOfSeats": 10 }, renewalSettings: { "renewalType": 'RENEW_CURRENT_USERS_MONTHLY_PAY' }, "purchaseOrderId": "PURCHASE_ORDER_ID", "dealCode": "GOOGLE_CONTRACT_DEAL_CODE" }
更改下列內容:
CUSTOMER_ID
:客戶的主網域名稱或客戶的專屬 ID。SKU_ID
:專屬的存貨單位 (SKU) ID。詳情請參閱產品與 SKU ID 一文。PURCHASE_ORDER_ID
:選用的訂購單 ID,可用於追蹤使用情況。GOOGLE_CONTRACT_DEAL_CODE
:Google 提供的折扣代碼。
以下是折扣年約方案回覆的範例:
{
"kind": "reseller#subscription",
"customerId": "C0123456",
"subscriptionId": "123",
"billingMethod": "ONLINE",
"skuId": "1010020028",
"creationTime": "1331647980142",
"plan": {
"planName": "ANNUAL",
"isCommitmentPlan": true,
"commitmentInterval": {
"startTime": "1331647980142",
"endTime": "1363183980142"
}
},
"seats": {
"kind": "subscriptions#seats",
"numberOfSeats": 10,
"licensedNumberOfSeats": 10
},
"trialSettings": {
"isInTrial": false
},
"renewalSettings": {
"kind": "subscriptions#renewalSettings",
"renewalType": "SWITCH_TO_PAY_AS_YOU_GO"
},
"purchaseOrderId": "my_example.com_annual_1",
"status": "ACTIVE",
"customerDomain": "my_example.com",
"dealCode": "GOOGLE_CONTRACT_DEAL_CODE",
"skuName": "Google Workspace Business Standard"
}
轉移訂閱內容
如果您並未使用訂購新客戶帳戶的作業訂購客戶的帳戶,請在為該客戶建立訂閱項目時,使用客戶的轉移憑證。
如要為未訂購的客戶帳戶建立訂閱項目,請使用下列 POST
HTTP 要求:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/CUSTOMER_ID/subscriptions?customerAuthToken=TOKEN_VALUE
更改下列內容:
CUSTOMER_ID
:客戶的主網域名稱或客戶的專屬 ID。TOKEN_VALUE
:客戶提供的轉移權杖。權杖在客戶產生後的 30 天內有效。
如要進一步瞭解客戶如何取得轉移權杖,請參閱 Google Workspace 說明中心。
如要轉移年約方案客戶的訂閱項目,請使用下列 POST
HTTP 要求並加入授權權杖:
POST https://reseller.googleapis.com/apps/reseller/v1/customers/C0123456/subscriptions?customerAuthToken=auth token { "customerId": "CUSTOMER_ID", "skuId": "SKU_ID", "plan": { "planName": "ANNUAL_MONTHLY_PAY" }, "seats": { "numberOfSeats": 10, "licensedNumberOfSeats": 10 }, "purchaseOrderId": "PURCHASE_ORDER_ID" }
更改下列內容:
CUSTOMER_ID
:客戶的主網域名稱或客戶的專屬 ID。SKU_ID
:專屬的存貨單位 (SKU) ID。詳情請參閱產品與 SKU ID 一文。PURCHASE_ORDER_ID
:選用的訂購單 ID,可用於追蹤使用情況。
針對年約方案的成功回應,系統會傳回 HTTP 200
狀態碼,以及已轉移的訂閱項目設定:
{
"kind": "reseller#subscription",
"customerId": "C0123456",
"subscriptionId": "123",
"billingMethod": "ONLINE",
"skuId": "1010020028",
"creationTime": "1331647980142",
"plan": {
"planName": "ANNUAL",
"isCommitmentPlan": true,
"commitmentInterval": {
"startTime": "1331647980142",
"endTime": "1363183980142"
}
},
"seats": {
"kind": "subscriptions#seats",
"numberOfSeats": 10,
"licensedNumberOfSeats": 10
},
"trialSettings": {
"isInTrial": false
},
"renewalSettings": {
"kind": "subscriptions#renewalSettings",
"renewalType": "SWITCH_TO_PAY_AS_YOU_GO"
},
"purchaseOrderId": "example.com_annual_1",
"status": "ACTIVE",
"resourceUiUrl": "URL to customer's Admin console dashboard",
"skuName": "Google Workspace Business Standard"
}
傳輸限制
如果要轉移的 Google Workspace 訂閱與相關聯的 Google 雲端硬碟或 Google 保管箱訂閱相關聯,請使用 batch
作業轉移所有狀態為 ACTIVE
的訂閱項目。逐一轉移各項訂閱項目會導致錯誤。
只有在停權原因為 PENDING_TOS_ACCEPTANCE
、TRIAL_ENDED
或 RENEWAL_WITH_TYPE_CANCEL
時,您才能轉移已停權的訂閱項目。
轉移舊版 SKU 時,subscriptions.list
會傳回需要轉移的 SKU skuId
。客戶實際傳回的 SKU skuId
將顯示為 transferInfo.currentLegacySkuId
。如需 skuIds
以及這些方案使用的產品的完整清單,請參閱產品與 SKU。
無法轉移折扣交易代碼。