Get recent shops

GET /shops/recent

Request

Authentication

This endpoint requires authentication.

Header Value
Authorization Set the value to Bearer + + access_token

Query string (URL)

Append the querystring with following properties to the URL.

A dictionary with fields

Field Type Description
company_id Int Optional. Only return shops of this company ID

Example request 1 Not authenticated

GET /shops/recent HTTP/1.1
Host: api.bakeronline.be
X-VERSION: 1.5.0
Accept-Language: en-US,en;q=0.5

Example request 2 User without orders

GET /shops/recent HTTP/1.1
Host: api.bakeronline.be
Authorization: Bearer 4147cdd0cefc65480d37c7cc337f5720d4a78eeccef5e0be14b06979bcbf00c512b04acb2a054746449bcfdb3feaefc438cf607cc3cd139938bf6ffe0d1d4f1d14cf5a03a932433236ecca0d026ea41c2ab25fa45d72cc0e97bbd3224b5e4fb86fce4de4
X-VERSION: 1.5.0
Accept-Language: en-US,en;q=0.5

Example request 3 User with orders

GET /shops/recent HTTP/1.1
Host: api.bakeronline.be
Authorization: Bearer 3b5fc6e205d2266eb5a7fe1939869a80962b5a6449ed547b98b70862ce4a498fe434908e14cb83be811cd06f79c99043f731101d2bdebd0ab86e596c22682c6bd902205222d776ee71acf579153d94a669337e1438bbc55a17999344457c6f9a4572fac9
X-VERSION: 1.5.0
Accept-Language: en-US,en;q=0.5

Example request 4 User with orders filtered on company id

GET /shops/recent?company_id=191 HTTP/1.1
Host: api.bakeronline.be
Authorization: Bearer 3b5fc6e205d2266eb5a7fe1939869a80962b5a6449ed547b98b70862ce4a498fe434908e14cb83be811cd06f79c99043f731101d2bdebd0ab86e596c22682c6bd902205222d776ee71acf579153d94a669337e1438bbc55a17999344457c6f9a4572fac9
X-VERSION: 1.5.0
Accept-Language: en-US,en;q=0.5

Response

Array of Shop.extended: [Shop.extended]

Shop.extended

Field Type Description
id Int Id of the shop
name String Name of the shop (translated)
address Address.detailed An address
allow_comments Bool A boolean value
offers [Offer] Array of Offer
images [String: Image] Dictionary of Image with keys of type String
allow_orders Bool A boolean value
delivery_use_intervals Bool A boolean value
categories [Category.simple] Array of Category.simple
category_groups [CategoryGroup] List of category groups. The ids refer to a category in the categories field. Categories without a CategoryGroup should also get displayed.
hours [MethodHours] Information about the opening hours, delivery hours... for all available methods and machines
contact Contact Contact details of a shop
messages [Message] You are required to keep track of the messages the user saw. When you receive new messages, you should indicate this in the app with a bubble icon (e.g. red circle with number of new messages)
info [Message] Same as messages, but you shouldn't notify the user when this changes or is received for the first time
currency Currency 3 letter ISO 4217 currency name (string)

Example response 1 Not authenticated

HTTP/1.1 401 Unauthorized
Content-Type: application/json; charset=utf-8
Content-Length: 98

{
    "code": "not_authorized",
    "message": "Please provide a token to access this endpoint."
}

Example response 2 User without orders

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: 2

[]

Example response 3 User with orders

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: 17803

[
    {
        "id": 199,
        "name": "Cakey Bakey",
        "address": {
            "street": "Servaisbaan",
            "nr": "75",
            "zipcode": "5555",
            "city": "Ottignies",
            "country": "BE",
            "position": {
                "latitude": 51.260197,
                "longitude": 4.402771
            }
        },
        "allow_comments": true,
        "currency": "EUR",
        "images": {
            "avatar": {
                "resolutions": [
                    {
                        "src": "https://bakeronline.be/uploads/shop-avatars/199/180x180/patisserie-andy.jpg",
                        "width": 180,
                        "height": 208
                    },
                    {
                        "src": "https://bakeronline.be/uploads/shop-avatars/199/360x360/patisserie-andy.jpg",
                        "width": 260,
                        "height": 300
                    }
                ]
            }
        },
        "allow_orders": true,
        "delivery_use_intervals": false,
        "categories": [
            {
                "id": 305,
                "name": "Snow",
                "banner": null,
                "seo": {
                    "title": [],
                    "description": [],
                    "url": []
                }
            }
        ],
        "offers": [],
        "category_groups": [],
        "hours": [
            {
                "name": "6572",
                "description": null,
                "type": "open",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "16:45 - 17:45",
                            "17:45 - 18:15",
                            "18:30 - 19:00",
                            "19:00 - 19:45"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "07:15 - 19:00"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "05:45 - 12:45",
                            "05:45 - 12:45"
                        ]
                    },
                    {
                        "days": "2128",
                        "times": [
                            "05:45 - 12:45"
                        ]
                    },
                    {
                        "days": "2129",
                        "times": [
                            "11:30 - 12:00",
                            "11:30 - 12:00"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "11:30 - 12:00"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "09:45 - 13:45"
                        ]
                    }
                ]
            },
            {
                "name": "6573",
                "description": null,
                "type": "takeout",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "14:30 - 17:00",
                            "18:15 - 19:00",
                            "14:30 - 17:00",
                            "18:15 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "14:30 - 17:00",
                            "18:15 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "11:45 - 15:45",
                            "11:45 - 15:45",
                            "11:45 - 15:45",
                            "3841"
                        ]
                    },
                    {
                        "days": "2121 - 2122",
                        "times": [
                            "11:45 - 15:45",
                            "3841"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "06:00 - 08:15",
                            "09:15 - 12:30",
                            "06:00 - 08:15",
                            "09:15 - 12:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "06:00 - 08:15",
                            "09:15 - 12:30",
                            "3841"
                        ]
                    }
                ]
            },
            {
                "name": "6574",
                "description": null,
                "type": "delivery",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "05:00 - 05:15",
                            "07:00 - 09:30",
                            "09:30 - 11:15",
                            "11:30 - 12:00",
                            "12:30 - 13:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "16:45 - 17:30",
                            "18:00 - 19:30",
                            "19:30 - 20:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "14:45 - 15:15",
                            "15:30 - 16:00",
                            "16:30 - 17:30",
                            "17:30 - 17:45",
                            "18:00 - 19:00",
                            "14:45 - 15:15",
                            "15:30 - 16:00",
                            "16:30 - 17:30",
                            "17:30 - 17:45",
                            "18:00 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2128",
                        "times": [
                            "14:45 - 15:15",
                            "15:30 - 16:00",
                            "16:30 - 17:30",
                            "17:30 - 17:45",
                            "18:00 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2129",
                        "times": [
                            "16:30 - 17:30",
                            "17:45 - 18:00",
                            "18:15 - 18:30",
                            "19:00 - 19:45",
                            "19:45 - 20:15",
                            "16:30 - 17:30",
                            "17:45 - 18:00",
                            "18:15 - 18:30",
                            "19:00 - 19:45",
                            "19:45 - 20:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "16:30 - 17:30",
                            "17:45 - 18:00",
                            "18:15 - 18:30",
                            "19:00 - 19:45",
                            "19:45 - 20:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "12:00 - 12:30",
                            "12:45 - 13:15",
                            "13:15 - 14:00",
                            "14:45 - 15:00",
                            "15:15 - 16:00",
                            "16:30 - 17:15",
                            "3841"
                        ]
                    }
                ]
            },
            {
                "name": "Marion Urbain",
                "description": "Mathieustraat 81, 7800 Herstal (1903)",
                "type": "latch",
                "hours": [
                    {
                        "days": "2118 - 2124",
                        "times": [
                            "3507"
                        ]
                    }
                ]
            }
        ],
        "contact": {
            "address": {
                "street": "Servaisbaan",
                "nr": "75",
                "zipcode": "5555",
                "city": "Ottignies",
                "country": "BE"
            },
            "telephone": "+32 479 44 77 88",
            "vat": "BE 0323280106",
            "social": {},
            "website": null,
            "email": "arthur.collin@example.org"
        },
        "messages": [],
        "info": []
    },
    {
        "id": 198,
        "name": "Dough Re Mi",
        "address": {
            "street": "Gilleslaan",
            "nr": "37",
            "zipcode": "8511",
            "city": "Sankt Vith",
            "country": "BE",
            "position": {
                "latitude": 50.8503396,
                "longitude": 4.3517103
            }
        },
        "allow_comments": true,
        "currency": "EUR",
        "images": {
            "avatar": {
                "resolutions": [
                    {
                        "src": "https://bakeronline.be/uploads/shop-avatars/198/180x180/brood-en-banket-t-bieke.jpg",
                        "width": 256,
                        "height": 180
                    },
                    {
                        "src": "https://bakeronline.be/uploads/shop-avatars/198/360x360/brood-en-banket-t-bieke.jpg",
                        "width": 300,
                        "height": 211
                    }
                ]
            }
        },
        "allow_orders": true,
        "delivery_use_intervals": false,
        "categories": [
            {
                "id": 303,
                "name": "Snow",
                "banner": null,
                "seo": {
                    "title": [],
                    "description": [],
                    "url": []
                }
            }
        ],
        "offers": [],
        "category_groups": [],
        "hours": [
            {
                "name": "6572",
                "description": null,
                "type": "open",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "07:45 - 08:30",
                            "12:15 - 16:00",
                            "07:45 - 08:30",
                            "12:15 - 16:00",
                            "07:45 - 08:30",
                            "12:15 - 16:00",
                            "07:45 - 08:30",
                            "12:15 - 16:00",
                            "07:45 - 08:30",
                            "12:15 - 16:00"
                        ]
                    },
                    {
                        "days": "2119 - 2122",
                        "times": [
                            "07:45 - 08:30",
                            "12:15 - 16:00"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "13:30 - 14:00",
                            "14:30 - 15:15",
                            "15:30 - 16:00",
                            "16:00 - 16:15",
                            "16:15 - 16:30"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "08:45 - 09:00",
                            "09:15 - 09:30",
                            "09:45 - 11:45",
                            "13:00 - 13:30"
                        ]
                    }
                ]
            },
            {
                "name": "6573",
                "description": null,
                "type": "takeout",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "06:45 - 09:15",
                            "09:15 - 09:45",
                            "10:00 - 10:45",
                            "11:00 - 11:45",
                            "12:45 - 14:15",
                            "14:15 - 15:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "07:45 - 09:00",
                            "10:30 - 11:30",
                            "12:00 - 12:30",
                            "14:00 - 14:45",
                            "3841"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "16:00 - 16:45",
                            "3841"
                        ]
                    },
                    {
                        "days": "2128",
                        "times": [
                            "16:45 - 21:30",
                            "16:45 - 21:30",
                            "16:45 - 21:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2122 - 2123",
                        "times": [
                            "16:45 - 21:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "15:30 - 16:00",
                            "3841"
                        ]
                    }
                ]
            },
            {
                "name": "6574",
                "description": null,
                "type": "delivery",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "15:00 - 15:45",
                            "16:00 - 16:45",
                            "18:15 - 18:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "10:30 - 11:15",
                            "12:45 - 13:15",
                            "14:30 - 15:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "07:45 - 09:15",
                            "10:00 - 10:45",
                            "12:00 - 13:15",
                            "13:30 - 14:00",
                            "14:15 - 15:15",
                            "15:15 - 15:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2128",
                        "times": [
                            "12:45 - 14:00",
                            "14:00 - 15:00",
                            "16:15 - 17:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2129",
                        "times": [
                            "10:15 - 11:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "14:30 - 15:30",
                            "15:45 - 16:45",
                            "16:45 - 17:15",
                            "17:30 - 18:00",
                            "18:00 - 18:30",
                            "18:30 - 19:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "13:00 - 13:15",
                            "13:30 - 13:45",
                            "13:45 - 14:00",
                            "14:00 - 14:45",
                            "15:00 - 15:30",
                            "3841"
                        ]
                    }
                ]
            }
        ],
        "contact": {
            "address": {
                "street": "Gilleslaan",
                "nr": "37",
                "zipcode": "8511",
                "city": "Sankt Vith",
                "country": "BE"
            },
            "telephone": "+32 479 44 77 88",
            "vat": "BE 0248474137",
            "social": {},
            "website": null,
            "email": "elisa45@example.com"
        },
        "messages": [],
        "info": []
    }
]

Example response 4 User with orders filtered on company id

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: 9494

[
    {
        "id": 199,
        "name": "Cakey Bakey",
        "address": {
            "street": "Servaisbaan",
            "nr": "75",
            "zipcode": "5555",
            "city": "Ottignies",
            "country": "BE",
            "position": {
                "latitude": 51.260197,
                "longitude": 4.402771
            }
        },
        "allow_comments": true,
        "currency": "EUR",
        "images": {
            "avatar": {
                "resolutions": [
                    {
                        "src": "https://bakeronline.be/uploads/shop-avatars/199/180x180/patisserie-andy.jpg",
                        "width": 180,
                        "height": 208
                    },
                    {
                        "src": "https://bakeronline.be/uploads/shop-avatars/199/360x360/patisserie-andy.jpg",
                        "width": 260,
                        "height": 300
                    }
                ]
            }
        },
        "allow_orders": true,
        "delivery_use_intervals": false,
        "categories": [
            {
                "id": 305,
                "name": "Snow",
                "banner": null,
                "seo": {
                    "title": [],
                    "description": [],
                    "url": []
                }
            }
        ],
        "offers": [],
        "category_groups": [],
        "hours": [
            {
                "name": "6572",
                "description": null,
                "type": "open",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "16:45 - 17:45",
                            "17:45 - 18:15",
                            "18:30 - 19:00",
                            "19:00 - 19:45"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "07:15 - 19:00"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "05:45 - 12:45",
                            "05:45 - 12:45"
                        ]
                    },
                    {
                        "days": "2128",
                        "times": [
                            "05:45 - 12:45"
                        ]
                    },
                    {
                        "days": "2129",
                        "times": [
                            "11:30 - 12:00",
                            "11:30 - 12:00"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "11:30 - 12:00"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "09:45 - 13:45"
                        ]
                    }
                ]
            },
            {
                "name": "6573",
                "description": null,
                "type": "takeout",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "14:30 - 17:00",
                            "18:15 - 19:00",
                            "14:30 - 17:00",
                            "18:15 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "14:30 - 17:00",
                            "18:15 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "11:45 - 15:45",
                            "11:45 - 15:45",
                            "11:45 - 15:45",
                            "3841"
                        ]
                    },
                    {
                        "days": "2121 - 2122",
                        "times": [
                            "11:45 - 15:45",
                            "3841"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "06:00 - 08:15",
                            "09:15 - 12:30",
                            "06:00 - 08:15",
                            "09:15 - 12:30",
                            "3841"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "06:00 - 08:15",
                            "09:15 - 12:30",
                            "3841"
                        ]
                    }
                ]
            },
            {
                "name": "6574",
                "description": null,
                "type": "delivery",
                "hours": [
                    {
                        "days": "2125",
                        "times": [
                            "05:00 - 05:15",
                            "07:00 - 09:30",
                            "09:30 - 11:15",
                            "11:30 - 12:00",
                            "12:30 - 13:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2126",
                        "times": [
                            "16:45 - 17:30",
                            "18:00 - 19:30",
                            "19:30 - 20:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2127",
                        "times": [
                            "14:45 - 15:15",
                            "15:30 - 16:00",
                            "16:30 - 17:30",
                            "17:30 - 17:45",
                            "18:00 - 19:00",
                            "14:45 - 15:15",
                            "15:30 - 16:00",
                            "16:30 - 17:30",
                            "17:30 - 17:45",
                            "18:00 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2128",
                        "times": [
                            "14:45 - 15:15",
                            "15:30 - 16:00",
                            "16:30 - 17:30",
                            "17:30 - 17:45",
                            "18:00 - 19:00",
                            "3841"
                        ]
                    },
                    {
                        "days": "2129",
                        "times": [
                            "16:30 - 17:30",
                            "17:45 - 18:00",
                            "18:15 - 18:30",
                            "19:00 - 19:45",
                            "19:45 - 20:15",
                            "16:30 - 17:30",
                            "17:45 - 18:00",
                            "18:15 - 18:30",
                            "19:00 - 19:45",
                            "19:45 - 20:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2130",
                        "times": [
                            "16:30 - 17:30",
                            "17:45 - 18:00",
                            "18:15 - 18:30",
                            "19:00 - 19:45",
                            "19:45 - 20:15",
                            "3841"
                        ]
                    },
                    {
                        "days": "2131",
                        "times": [
                            "12:00 - 12:30",
                            "12:45 - 13:15",
                            "13:15 - 14:00",
                            "14:45 - 15:00",
                            "15:15 - 16:00",
                            "16:30 - 17:15",
                            "3841"
                        ]
                    }
                ]
            },
            {
                "name": "Marion Urbain",
                "description": "Mathieustraat 81, 7800 Herstal (1903)",
                "type": "latch",
                "hours": [
                    {
                        "days": "2118 - 2124",
                        "times": [
                            "3507"
                        ]
                    }
                ]
            }
        ],
        "contact": {
            "address": {
                "street": "Servaisbaan",
                "nr": "75",
                "zipcode": "5555",
                "city": "Ottignies",
                "country": "BE"
            },
            "telephone": "+32 479 44 77 88",
            "vat": "BE 0323280106",
            "social": {},
            "website": null,
            "email": "arthur.collin@example.org"
        },
        "messages": [],
        "info": []
    }
]
1.5.0 stable