Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Version History

« Previous Version 3 Next »

This documentation aims to guide developers in implementing Second Hand functionality on a website.

In this documentation, you will find instructions on how to add Second Hand to your website, as well as code examples to help you get started.

AddtoCart

The Web Service for adding an item to the shopping cart remains the same, except that a "secondHandFictive" field has been added. This field will take as value the EAN of Medialog. To find this EAN, there are two possibilities: either by using the following Web Service with the "eanf" field, or by using the "dbpGroup" of the SearchEngine response.

Cart lines - Add Product

infoSecondHand

The Web Service provided at this URL allows you to check the real-time stock in the bookstore to verify the availability of a second-hand product. It is recommended to use it in verification of the SearchEngine search, as the data provided by the latter is only generated every 24 hours. By using this Web Service, you can ensure that stock information is accurate and up-to-date. An ordered item is removed when it is processed in the ERP (Medialog)

The Web Service uses the actual (new) EAN of the article in the "ean" field.

Example

https://wsmedia.tlsecure.com/api/json/00000/product/infoSecondHand?ean=9789076174112

Request

Parameters

Location

Type

Required

Default

Accepted

token

Header

String(26)

v

ean

Params

String(26)

v

image

QueryParams

Boolean

shop

QueryParams

Integer

Response

Success

{
    "response": {
        "success": true,
        "code": 0,
        "message": "product retrieved",
        "object": {
            "shops": {
                "shop": [
                    {
                        "id": 16,
                        "name": "TiteLive Benelux",
                        "addressLine1": "Rue terre à briques 6",
                        "postcode": "7500",
                        "city": "Tournai",
                        "country": 1,
                        "phone": "015 45 16 12",
                        "email": "mediaweb@titelive.be",
                        "defaultShop": true,
                        "product": [
                            {
                                "ean": 9789076174112,
                                "origin": "MEDIALOG",
                                "known": 1,
                                "price": 10.0,
                                "headGroup": "2DEHANDS BOEKEN",
                                "group": "2DEHANDS BOEKEN",
                                "category": "91",
                                "message": "",
                                "rating": 3,
                                "eanf": 2100000003860
                            },
                            {
                                "ean": 9789076174112,
                                "origin": "MEDIALOG",
                                "stock": 1,
                                "available": 1,
                                "known": 1,
                                "price": 20.0,
                                "headGroup": "2DEHANDS BOEKEN",
                                "group": "2DEHANDS BOEKEN",
                                "category": "91",
                                "message": "goeie staat",
                                "rating": 5,
                                "eanf": 2100000010615
                            }
                        ]
                    }
                ]
            }
        }
    }
}
  • No labels