UNPKG

cms-web-apis

Version:

Biblioteca de APIs para CMS Web - Conjunto completo de funciones para interactuar con APIs de gestión de contenido

19 lines 720 B
import dotenv from 'dotenv'; import { fetchApi } from './api.js'; dotenv.config(); const API_BASE_URL = process.env['API_BASE_URL']; const getMotorizacionesProducto = async () => { const url = `${API_BASE_URL}/Atributos/GetMotorizacionesProductos`; console.log('=== getMotorizacionesProducto ==='); console.log('URL:', url); const response = await fetchApi(url, { method: 'GET', headers: { 'Content-Type': 'application/json' } }); console.log('Motorizaciones de producto obtenidas:', Array.isArray(response) ? response.length : 'No es array'); return response; }; export { getMotorizacionesProducto }; //# sourceMappingURL=apiMotorizacionesProductos.js.map