AI-generated Key Takeaways
-
Enables batch operations (delete, fetch, get, insert, update) on multiple datafeeds using a single HTTP POST request.
-
Requires providing a
DatafeedsCustomBatchRequestobject in the request body, specifying individual operations within the batch. -
Responses are structured as a
DatafeedsCustomBatchResponse, containing individualDatafeedsCustomBatchResponseEntryobjects for each operation. -
Authorization is necessary using the
https://www.googleapis.com/auth/contentscope. -
Each batch entry requires a unique
batchId,merchantId, the desiredmethod, and optionallydatafeedIdand/ordatafeedobject depending on the operation.
- HTTP request
- Request body
- Response body
- Authorization scopes
- DatafeedsCustomBatchRequest
- DatafeedsCustomBatchRequestEntry
- DatafeedsCustomBatchResponseEntry
- Try it!
Deletes, fetches, gets, inserts and updates multiple datafeeds in a single request.
HTTP request
POST https://shoppingcontent.googleapis.com/content/v2.1/datafeeds/batch
Request body
The request body contains an instance of DatafeedsCustomBatchRequest
.
Response body
If successful, the response body contains data with the following structure:
| JSON representation |
|---|
{
"entries"
:
[
{
object (
|
| Fields | |
|---|---|
entries[]
|
The result of the execution of the batch requests. |
kind
|
Identifies what kind of resource this is. Value: the fixed string " |
Authorization scopes
Requires one of the following OAuth scopes:
-
https://www.googleapis.com/auth/content
For more information, see the OAuth 2.0 Overview .
DatafeedsCustomBatchRequest
| JSON representation |
|---|
{
"entries"
:
[
{
object (
|
| Fields | |
|---|---|
entries[]
|
The request entries to be processed in the batch. |
DatafeedsCustomBatchRequestEntry
A batch entry encoding a single non-batch datafeeds request.
| JSON representation |
|---|
{
"batchId"
:
integer
,
"merchantId"
:
string
,
"method"
:
string
,
"datafeedId"
:
string
,
"datafeed"
:
{
object (
|
batchId
integer ( uint32
format)
An entry ID, unique within the batch request.
merchantId
string
The ID of the managing account.
method
string
The method of the batch entry.
Acceptable values are:
- "
delete" - "
fetchNow" - "
get" - "
insert" - "
update"
datafeedId
string
The ID of the data feed to get, delete or fetch.
datafeed
object (
Datafeed
)
The data feed to insert.
DatafeedsCustomBatchResponseEntry
A batch entry encoding a single non-batch datafeeds response.
| JSON representation |
|---|
{ "batchId" : integer , "datafeed" : { object ( |
| Fields | |
|---|---|
batchId
|
The ID of the request entry this entry responds to. |
datafeed
|
The requested data feed. Defined if and only if the request was successful. |
errors
|
A list of errors for failed custombatch entries. |

