{"version":3,"file":"apiClient.Do5jSgFq.mjs","names":[],"sources":["https:/framerusercontent.com/modules/pBL9xlYciLON0IYG5ZYl/DxVDlqShaJhwCL9j7jVb/apiClient.js"],"sourcesContent":["/**\n * FILE: apiClient.ts\n * LOCATION: framer/api/apiClient.ts\n * LAYER: API (HTTP Transport Layer)\n *\n * RESPONSIBILITY:\n * - Provide a centralized wrapper around fetch\n * - Apply base API URL configuration\n * - Ensure credentials: \"include\" for cookie-based auth\n * - Normalize error handling for frontend\n *\n * DOES NOT:\n * - Store application state\n * - Contain business logic\n * - Transform domain data\n *\n * AUTHORITY:\n * - Backend API at https://api.importa-coffee.com\n *\n * DATA FLOW:\n * Override / Controller → apiClient → Backend API → JSON Response\n */import{API_BASE}from\"https://framerusercontent.com/modules/6XP7Q2uMwCNydLEakM1u/S7U0HWM4zsiU1wkCO9V8/constants.js\";export async function apiFetch(path,options={}){try{const res=await fetch(`${API_BASE}${path}`,{credentials:\"include\",headers:{Accept:\"application/json\",\"Content-Type\":\"application/json\",...options.headers||{}},...options});const data=await res.json().catch(()=>({}));return{ok:res.ok,status:res.status,data};}catch(error){return{ok:false,status:0,data:{error:\"network_error\"}};}}\nexport const __FramerMetadata__ = {\"exports\":{\"apiFetch\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],"mappings":"yGAqBsH,eAAsB,EAAS,EAAK,EAAQ,EAAE,CAAC,CAAC,GAAG,CAAC,IAAM,EAAI,MAAM,MAAM,GAAG,IAAW,IAAO,CAAC,YAAY,UAAU,QAAQ,CAAC,OAAO,mBAAmB,eAAe,mBAAmB,GAAG,EAAQ,SAAS,EAAE,CAAC,CAAC,GAAG,EAAQ,CAAC,CAAO,EAAK,MAAM,EAAI,MAAM,CAAC,WAAW,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,EAAI,GAAG,OAAO,EAAI,OAAO,OAAK,MAAc,CAAC,MAAM,CAAC,GAAG,GAAM,OAAO,EAAE,KAAK,CAAC,MAAM,gBAAgB,CAAC,mBAAzX"}