GET https://shoppingcontent.googleapis.com/content/v2.1/merchantId/products/productId
Xác minh rằng bạn nhận được mã trạng thái HTTP 200 và dữ liệu JSON cho
của Google.
Cập nhật sản phẩm
Tạo JSON mới cho một sản phẩm. Ví dụ: thay đổi một trường trong
JSON availability: in stock, đến availability: out of stock cho phần tử
sản phẩm bạn đã sử dụng để kiểm tra lệnh gọi insert.
Tạo một insert
yêu cầu
có dữ liệu sản phẩm mới và mã người bán của bạn:
POST https://shoppingcontent.googleapis.com/content/v2.1/merchantId/products
Xác minh rằng bạn nhận được mã trạng thái HTTP 200. Sau ít nhất năm
phút, bạn có thể thực hiện một yêu cầu get khác để xác nhận giá trị đã cập nhật,
Đã áp dụng availability: out of stock.
[null,null,["Cập nhật lần gần đây nhất: 2024-08-22 UTC."],[[["This page provides examples of how to interact with the `products` resource using the Content API for Shopping."],["You can add a new product by constructing valid JSON and making an `insert` request."],["View an existing product using a `get` request with your merchant ID and the product ID."],["Update a product's information by making an `insert` request with the updated JSON data."],["Delete a product using a `delete` request with your merchant ID and the product ID."]]],["To add a product, create valid JSON for it, then send an `insert` request via POST with the data and merchant ID, expecting an `HTTP 200` response. To view, send a `get` request via GET with the merchant ID and product ID, confirming an `HTTP 200` status and the JSON. To update, create new JSON, make an `insert` POST request, and verify `HTTP 200` then check with `get`. To delete, send a `delete` request via DELETE with the ID, verifying an `HTTP 204` status.\n"]]