We will sunset v2 of the Content API on March 29th, 2021. To avoid disruptions with your integration, please migrate to v2.1 as soon as possible. For more information, see Migrating to v2.1.

Method: orders.createtestorder

Sandbox only. Creates a test order.

HTTP request

POST https://shoppingcontent.googleapis.com/content/v2.1sandbox/{merchantId}/testorders

Path parameters

Parameters
merchantId

string

The ID of the account that should manage the order. This cannot be a multi-client account.

Request body

The request body contains an instance of OrdersCreateTestOrderRequest.

Response body

If successful, the response body contains data with the following structure:

JSON representation
{
  "orderId": string,
  "kind": string
}
Fields
orderId

string

The ID of the newly created test order.

kind

string

Identifies what kind of resource this is. Value: the fixed string

"content#ordersCreateTestOrderResponse"

.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/content

For more information, see the OAuth 2.0 Overview.

OrdersCreateTestOrderRequest

JSON representation
{
  "testOrder": {
    object (TestOrder)
  },
  "templateName": string,
  "country": string
}
Fields
testOrder

object (TestOrder)

The test order to create.

templateName

string

The test order template to use. Specify as an alternative to testOrder as a shortcut for retrieving a template and then creating an order using that template.

Acceptable values are:

  • "template1"
  • "template1a"
  • "template1b"
  • "template2"
  • "template3"

country

string

The CLDR territory code of the country of the test order to create. Affects the currency and addresses of orders created via templateName, or the addresses of orders created via testOrder.

Acceptable values are:

  • "US"
  • "FR"
Defaults to US.