Lojas - API Lojaz Delivery
GET
-
Listar Lojas
PATH
{{BASE_URL}}/stores
Headers
Authorization: Bearer Token
Exemplo em NodeJS:
const axios = require('axios');
const getStores = async () => {
try {
const { data } = await axios.get("BASE_URL/stores", {
headers: {
Authorization: `Bearer TOKEN`
}
});
// data contains response 200 model
} catch (error) {
// unauthorized
}
};
module.exports = getToken;
Response - OK (200)
{ "status": true, "data": [ { "address": { "latitude": "-22.89797417619252,", "longitude": "-43.344309345311174", "address": "Rua marangá, --, Praça Seca, Rio de Janeiro - RJ" }, "_id": "669e8d9468a769acaa7b53ba", "userId": "669e8d2d79c1e62ead6f3bc2", "name": "Lojaz", "document": "12345678901", "status": "active", "createdAt": "2024-07-22T16:49:21.638Z", "updatedAt": "2024-07-22T16:49:21.638Z", "__v": 0 } ] }
Content-Type: application/json