Top
Developers Your place to code all things handmade

Welcome to the Shopclues Developer Platform

We believe in code as craft. Join the community of developers, creators and build tools that enrich the ways you can shop, sell and connect with the India's largest merchant base most easily.

Get Started

Register, Upload, Search and Connect

Explore Shopclues' marketplace of over 8.5 million products from over 3.5 lakh merchants. Connect buyers with the items they'll love.

Learn More About Catalog Management

Login, Integrate and Create

Build the best tools for Shopclues merchants. Simply login, Integrate and start developing you own apps.

Learn More About Start Developing
<
>
Jump to: navigation, search

API Basics

Introduction

The Shopclues API provides a simple RESTful interface with lightweight JSON-formatted responses to use many of Shopclues website features, including billing, listings, cart, and , using OAuth to allow both read and write access to users' public and private data. This document provides information to developers on how to integrate with the Shopclues API.

Accessing the API

Introductory documentation for how to use version 1.0 of the shopclues API can temporarily be found here.

GET http://developer.shopclues.com/api/v1/order

To retrieve the all of your orders listing.

Authentication

The Shopclues API requires an client_id and Client Secret that is provided during app registration. The key identifies your application to the shopclues web service, and is used to track overall call usage. It's passed using the standard api_key parameter.


For write access and for accessing private user data, an OAuth access token is required. Your application key is required to start the OAuth authentication process.


New users register an application and receive a Production API key upon signup. These keys have full access to resources in the Shopclues API, however they are restricted to allow authentication only for the user who registered the application.

Rate Limiting

With the Shopclues APIs Payment Plan, application consumes “Credit Points”. One api hit consumes one credit point. Clients purchase the Credit points based upon the estimate of their application’s usage. Clients are allowed 10,000 free hits in a day. For additional hits one credit is consumed per hit. If all credits are consumed in a given day error response is shown. In that case credit points can be purchased.

If your application needs more than the allotted number of calls, contact us at developer@shopclues.com with a description of the application and an estimate on needed call usage. You might also want to investigate the use of caching to keep the number of calls to a minimum, and make your application more responsive.

API Requests

The Shopclues API uses a RESTful calling style that works with standard HTTP calls. It support web programming language (PHP, Java) should be able to make and receive HTTP networking calls; consult the documentation for your language of choice.

Request URLs

In a RESTful API, each resource or collection of resources is identified by a unique URL, such as:

GET http://developer.shopclues.com/api/v1/order

The prefix v1 is the version specifier and must be present. When significant changes are made to the API (changes that would break compatibility with existing applications) this value will change.

URL paths contain the unique IDs of resources. These are identified by a leading colon, as with :Order details above. Before making a call, you must substitute a valid ID value for these placeholders. ID parameters must appear in the URL and cannot be substituted for GET parameters. All ID parameters listed in the URL pattern must be present.

Output Formats


The Shopclues API handles multiple output formats. Currently, the only supported formats are JSON and XML (see JSON .) Output formats are selected with a specifier that is appended to the URL, like a filename extension:

Format Specifier Description
JSON .json JavaScript Object Notation

HTTP Methods

RESTful APIs use standard HTTP methods to denote actions against a resource:

 1.GET - Reads a resource. Returns HTTP 200 on success.
 2.POST - Creates a new resource. Returns HTTP 200 on success.
 3.PUT - Updates a resource. Returns HTTP 200 on success.
 4.DELETE - Deletes a resource. Returns HTTP 200 on success.

JSON Data

Data is returned using JSON, a lightweight serialization language that is compatible with many different languages. JSON is also syntactically correct php code, which means that it can be parsed with php own eval() function.

Standard Response Format

Shopclues API response is wrapped in a standard structure that holds the results of the API call request:

{
  "order_id": "76996265",
  "user_id": "11028919",
  "is_parent_order": "N",
  "exempt_from_billing": "0",
  "parent_order_id": "0",
  "company_id": "1",
  "timestamp": "1448879008",
  "firstname": "Lokesh",
  "lastname": "Singh",
  "email": "lokesh.mnit@gmail.com",
  "status": "E",
  "total": "34.00",
  "subtotal": "10.00",
  "details": "Delivery Region: Delhi NCR \n",
  "net_payout": null,
  "payment_id": "6",
  "s_city": "Gurgaon",
  "s_state": "HR",
  "s_zipcode": "122001",
  "label_printed": "n",
  "gift_it": "N",
  "items_list": [
    {
      "product": "Product-Test-Crestech-4",
      "product_id": "78363196",
      "amount": "1",
      "selling_price": "10.00",
      "image_path": "cdn.shopclues.com/images/thumbnails/18875/160/160/imagetest1433145582.jpg"
    }
  ]
}

Looking for ShopClues Apps?

Check out our new
App Gallery!

It's the best way to find cool and useful tools built upon Shopclues's API.