Method: accounts.promotions.list
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-01-23 UTC
[null,null,["อัปเดตล่าสุด 2025-01-23 UTC"],[[["\u003cp\u003eLists all processed promotions for a given Merchant Center account, allowing pagination for large result sets.\u003c/p\u003e\n"],["\u003cp\u003eProvides detailed information about each promotion, including potential product restrictions and offer details.\u003c/p\u003e\n"],["\u003cp\u003eRequires authorization with the \u003ccode\u003ehttps://www.googleapis.com/auth/content\u003c/code\u003e scope for access.\u003c/p\u003e\n"],["\u003cp\u003eResponses may be delayed for recently created or updated promotions due to processing time.\u003c/p\u003e\n"],["\u003cp\u003eUtilizes HTTP GET requests with path and query parameters for specifying the target account and pagination control.\u003c/p\u003e\n"]]],["This document details how to retrieve a list of promotions from a Merchant Center account using an HTTP GET request. The URL requires the account ID as a `parent` path parameter. Optional query parameters include `pageSize` (maximum promotions to return, up to 250) and `pageToken` (for pagination). The request body must be empty. The response includes an array of `promotions` and an optional `nextPageToken` for subsequent pages. Authentication requires the `https://www.googleapis.com/auth/content` OAuth scope. Updated promotions might take time to be retrievable.\n"],null,["# Method: accounts.promotions.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.ListPromotionsResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nLists the promotions in your Merchant Center account. The response might contain fewer items than specified by `pageSize`. Rely on `pageToken` to determine if there are more items to be requested.\n\nAfter inserting or updating a promotion, it may take several minutes before the updated processed promotion can be retrieved.\n\n### HTTP request\n\n`GET https://merchantapi.googleapis.com/promotions/v1beta/{parent=accounts/*}/promotions`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|----------|-----------------------------------------------------------------------------------------------|\n| `parent` | `string` Required. The account to list processed promotions for. Format: `accounts/{account}` |\n\n### Query parameters\n\n| Parameters ||\n|-------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `pageSize` | `integer` Optional. The maximum number of promotions to return. The service may return fewer than this value. The maximum value is 250; values above 250 will be coerced to 250. If unspecified, the maximum number of promotions will be returned. |\n| `pageToken` | `string` Optional. A page token, received from a previous `promotions.list` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `promotions.list` must match the call that provided the page token. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nResponse message for the `promotions.list` method.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"promotions\": [ { object (/merchant/api/reference/rest/promotions_v1beta/accounts.promotions#Promotion) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|-----------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `promotions[]` | `object (`[Promotion](/merchant/api/reference/rest/promotions_v1beta/accounts.promotions#Promotion)`)` The processed promotions from the specified account. |\n| `nextPageToken` | `string` A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted, there are no subsequent pages. |\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/content`\n\nFor more information, see the [OAuth 2.0 Overview](/identity/protocols/OAuth2)."]]