You can PUT a JSON array of documents in a body of the request. In a Curl command, use PUT with the –d option and ‘@‘ to upload a file from the command line.

PUT /service/v1/products
PUT /service/v1/articles
PUT /service/v1/help
PUT /service/v1/services

You can post a file of product information to the site that is in JSON format. This POST method is useful for posting files from a web page form.

POST /service/v1/products
POST /service/v1/articles
POST /service/v1/help
POST /service/v1/services

Parameter

Data Type

Description

file

File

JSON Array as shown below.

The file (or request body in the case of using the PUT method) shall contain a JSON array of documents. The full structure is shown below, same for all types.

Field

Data Type

Description

id

String

Required. Unique identifier for product. No colons, no ampersands.  URL encode URLS.

url

String

Fully Qualified Domain Named URL to a product/article/help/services page.

description*

JSON Object

Object describing content. Refer to * below.

brand

String

 

keywords

Array of Strings

 

media**

Array of JSON objects

Metadata for rich media related to product.

prices***

Array of JSON objects

Regular, special pricing and their scopes for a product

keywords

Array of Strings

Keywords associated with product or media.

attributes****

Array of JSON Objects

Attributes related to product

category

Ordered Array of Strings

Classification/category of product. Ordered from highest level to most granular.

location

Array of Strings

Strings that could indicate store identifiers where this document could be found.

language

String

String describing language for the document example: "en_US" Maybe used to filter content to user's language.

*: Description Object:

Field Name

Data Type

Description

display_name

String

Title/Primary name of product

short_description

String

Short description or header

long_description

String

Detailed description of product

thumbnails

Array of fully-qualified-domain-name URLs

URLs for image thumbnails of product

full_images

Array of fully-qualified-domain-name URLs

URLs for full sized images of product

**: Media Object Description

Field Name

Data Type

Description

 url

 String

 Fully-Qualified-Domain-Named URL to media

 mimeType

 String

 ContentType

 description

 JSON Object

 As described above in Description 

***: Price Object Description

Field Name

Data Type

Description

currency

String

Currency of product price

reg_price

Number

Regular price 2.99

sale_price

Number

Sale Price

sale_start_date

Date String in ISO Date Format “”

Date when sale on product begins

sale_end_date

Date String in ISO Date Format “”

Date when sale on product ends

****:Attribute Object Description

Field Name

Data Type

Description

name

String

Attribute name – valid attribute names are identifiers which contain upper and lower case letters (A-Za-z) and numbers (0-9) and spaces and underscores only.

values

Array of Strings

Attribute values

type

Enumeration. Possible values:”STRING”, “NUMBER”, “ISODATE", “FQDN_URL”

Attribute data type

Join The Discussion

Your email address will not be published. Required fields are marked *