Method: subscriptions.list
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
由转销商管理的订阅列表。列表可以是所有订阅、客户的所有订阅,或客户的所有可转让订阅。
(可选)此方法可以按 customerNamePrefix
过滤响应。如需了解详情,请参阅管理订阅。
HTTP 请求
GET https://reseller.googleapis.com/apps/reseller/v1/subscriptions
网址采用 gRPC 转码语法。
查询参数
参数 |
customerAuthToken |
string
创建转销账号时,必须提供 customerAuthToken 查询字符串,以便将直销客户的订阅转移到您的转销商账号,或将其他转销商客户的订阅转移到您的转销商账号。这是完成订阅转移所需的十六进制身份验证令牌。如需了解详情,请访问管理员帮助中心。
|
customerId |
string
这可以是客户的主域名,也可以是客户的唯一标识符。如果客户的域名发生变化,则无法使用旧域名访问该客户,但可以随时使用客户的唯一标识符(由 API 返回)。我们建议您在系统中存储唯一标识符(如果适用)。
|
customerNamePrefix |
string
检索所有订阅并过滤出特定客户时,您可以输入客户名称的前缀。使用包含 exam.com 、example20.com 和 example.com 的示例客户群组: exa - 返回以“exa”开头的所有客户名称,其中可能包括 exam.com 、example20.com 和 example.com 。名称前缀类似于使用正则表达式的星号,例如 exa*。 example - 返回 example20.com 和 example.com 。
|
maxResults |
integer (uint32 format)
检索大型列表时,maxResults 是每页的结果数上限。nextPageToken 值会将您转到下一页。默认值为 20。
|
pageToken |
string
用于指定列表中下一页的令牌
|
响应正文
订阅用于管理 Google 客户的付款方案与产品的 SKU、用户许可、30 天免费试用状态和续订选项之间的关系。转销商的主要角色是管理 Google 客户的订阅。
如果成功,响应正文将包含结构如下的数据:
JSON 表示法 |
{
"kind": string,
"subscriptions": [
{
object (Subscription )
}
],
"nextPageToken": string
} |
字段 |
kind |
string
将资源标识为订阅集合。值:reseller#subscriptions
|
subscriptions[] |
object (Subscription )
此结果页中的订阅。
|
nextPageToken |
string
用于对大型结果集进行分页的接续令牌。在后续请求中提供此值以返回下一页结果。
|
授权范围
需要以下 OAuth 范围之一:
https://www.googleapis.com/auth/apps.order
https://www.googleapis.com/auth/apps.order.readonly
如需了解详情,请参阅授权指南。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-25。
[null,null,["最后更新时间 (UTC):2025-07-25。"],[],[],null,["# Method: subscriptions.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.Subscriptions.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nLists of subscriptions managed by the reseller. The list can be all subscriptions, all of a customer's subscriptions, or all of a customer's transferable subscriptions.\n\nOptionally, this method can filter the response by a `customerNamePrefix`. For more information, see [manage subscriptions](https://developers.google.com/workspace/admin/reseller/v1/how-tos/manage_subscriptions).\n\n### HTTP request\n\n`GET https://reseller.googleapis.com/apps/reseller/v1/subscriptions`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Query parameters\n\n| Parameters ||\n|----------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `customerAuthToken` | `string` The `customerAuthToken` query string is required when creating a resold account that transfers a direct customer's subscription or transfers another reseller customer's subscription to your reseller management. This is a hexadecimal authentication token needed to complete the subscription transfer. For more information, see the [administrator help center](//support.google.com/a/bin/answer.py?answer=142336). |\n| `customerId` | `string` This can be either the customer's primary domain name or the customer's unique identifier. If the domain name for a customer changes, the old domain name cannot be used to access the customer, but the customer's unique identifier (as returned by the API) can always be used. We recommend storing the unique identifier in your systems where applicable. |\n| `customerNamePrefix` | `string` When retrieving all of your subscriptions and filtering for specific customers, you can enter a prefix for a customer name. Using an example customer group that includes `exam.com`, `example20.com` and `example.com`: - `exa` -- Returns all customer names that start with 'exa' which could include `exam.com`, `example20.com`, and `example.com`. A name prefix is similar to using a regular expression's asterisk, exa\\*. - `example` -- Returns `example20.com` and `example.com`. \u003cbr /\u003e |\n| `maxResults` | `integer (`[uint32](https://developers.google.com/discovery/v1/type-format)` format)` When retrieving a large list, the `maxResults` is the maximum number of results per page. The `nextPageToken` value takes you to the next page. The default is 20. |\n| `pageToken` | `string` Token to specify next page in the list |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nA subscription manages the relationship of a Google customer's payment plan with a product's SKU, user licenses, 30-day free trial status, and renewal options. A primary role of a reseller is to manage the Google customer's subscriptions.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"kind\": string, \"subscriptions\": [ { object (/workspace/admin/reseller/reference/rest/v1/subscriptions#Subscription) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|-------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `kind` | `string` Identifies the resource as a collection of subscriptions. Value: reseller#subscriptions |\n| `subscriptions[]` | `object (`[Subscription](/workspace/admin/reseller/reference/rest/v1/subscriptions#Subscription)`)` The subscriptions in this page of results. |\n| `nextPageToken` | `string` The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/apps.order`\n- `\n https://www.googleapis.com/auth/apps.order.readonly`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]