Conversations API: Retrieve and submit consumer-generated content (CGC), and retrieve your product catalog and statistics about your CGC.
Cross Domain Requests
The Conversations API lets you programmatically retrieve and submit Bazaarvoice Conversations data for use in your applications. To learn more, go to the Conversations API documentation home page.
Contents
This section contains tutorials specific to making cross domain requests with the Conversations API.
Overview
Attempts to use the Conversations API by JavaScript applications in a web browser will be subject to the Same Origin Policy, a security measure imposed by all modern browsers that restricts the ability of JavaScript applications to make HTTP requests across domains.
The following example summarizes the consequences of the Same Origin Policy for a request being made by a JavaScript application from https://www.example.com/product-page.html
Compared URL | Outcome | Reason |
---|---|---|
https://www.example.com/api/data.json | Success | Same host |
https://api.bazaarvoice.com/data/reviews.json | Failure | Different host |
The request represented by the first row works because the origin and the compared URL share the same host. The request represented by the second row fails because the origin and the compared URL have different hosts. For a more detailed explanation of the Same Origin Policy see http://en.wikipedia.org/wiki/Same-origin_policy
The Conversations API supports two techniques for making cross domain requests: CORS and JSONP.
Section contents
Use the links below or the menu to the left to navigate to the pages in this section.
CORS
This tutorial explains how developers can use Cross Origin Resource Sharing (CORS) to make cross-domain GET and POST requests to the Conversations API. |
JSONP
This tutorial explains how developers can use JavaScript Object Notation with Padding (JSONP) to make cross-domain GET requests to the Conversations API. |
Related resources
Refer to these resources for additional information related to cross domain requests.
Display fundamentals
Learn Conversations API display request fundamentals including filtering, sorting, searching and lots more. |
Submission Fundamentals
Learn Conversations API submission request fundamentals including content types, the |