"use strict";
/*
 * ATTENTION: An "eval-source-map" devtool has been used.
 * This devtool is neither made for production nor for readable output files.
 * It uses "eval()" calls to create a separate source file with attached SourceMaps in the browser devtools.
 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
 * or disable the default devtool with "devtool: false".
 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
 */
(() => {
var exports = {};
exports.id = "app/api/trips/route";
exports.ids = ["app/api/trips/route"];
exports.modules = {

/***/ "next/dist/compiled/next-server/app-page.runtime.dev.js":
/*!*************************************************************************!*\
  !*** external "next/dist/compiled/next-server/app-page.runtime.dev.js" ***!
  \*************************************************************************/
/***/ ((module) => {

module.exports = require("next/dist/compiled/next-server/app-page.runtime.dev.js");

/***/ }),

/***/ "next/dist/compiled/next-server/app-route.runtime.dev.js":
/*!**************************************************************************!*\
  !*** external "next/dist/compiled/next-server/app-route.runtime.dev.js" ***!
  \**************************************************************************/
/***/ ((module) => {

module.exports = require("next/dist/compiled/next-server/app-route.runtime.dev.js");

/***/ }),

/***/ "(rsc)/./node_modules/next/dist/build/webpack/loaders/next-app-loader.js?name=app%2Fapi%2Ftrips%2Froute&page=%2Fapi%2Ftrips%2Froute&appPaths=&pagePath=private-next-app-dir%2Fapi%2Ftrips%2Froute.ts&appDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App%5Capp&pageExtensions=tsx&pageExtensions=ts&pageExtensions=jsx&pageExtensions=js&rootDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App&isDev=true&tsconfigPath=tsconfig.json&basePath=&assetPrefix=&nextConfigOutput=&preferredRegion=&middlewareConfig=e30%3D!":
/*!***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** ./node_modules/next/dist/build/webpack/loaders/next-app-loader.js?name=app%2Fapi%2Ftrips%2Froute&page=%2Fapi%2Ftrips%2Froute&appPaths=&pagePath=private-next-app-dir%2Fapi%2Ftrips%2Froute.ts&appDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App%5Capp&pageExtensions=tsx&pageExtensions=ts&pageExtensions=jsx&pageExtensions=js&rootDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App&isDev=true&tsconfigPath=tsconfig.json&basePath=&assetPrefix=&nextConfigOutput=&preferredRegion=&middlewareConfig=e30%3D! ***!
  \***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   originalPathname: () => (/* binding */ originalPathname),\n/* harmony export */   patchFetch: () => (/* binding */ patchFetch),\n/* harmony export */   requestAsyncStorage: () => (/* binding */ requestAsyncStorage),\n/* harmony export */   routeModule: () => (/* binding */ routeModule),\n/* harmony export */   serverHooks: () => (/* binding */ serverHooks),\n/* harmony export */   staticGenerationAsyncStorage: () => (/* binding */ staticGenerationAsyncStorage)\n/* harmony export */ });\n/* harmony import */ var next_dist_server_future_route_modules_app_route_module_compiled__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! next/dist/server/future/route-modules/app-route/module.compiled */ \"(rsc)/./node_modules/next/dist/server/future/route-modules/app-route/module.compiled.js\");\n/* harmony import */ var next_dist_server_future_route_modules_app_route_module_compiled__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(next_dist_server_future_route_modules_app_route_module_compiled__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var next_dist_server_future_route_kind__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! next/dist/server/future/route-kind */ \"(rsc)/./node_modules/next/dist/server/future/route-kind.js\");\n/* harmony import */ var next_dist_server_lib_patch_fetch__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! next/dist/server/lib/patch-fetch */ \"(rsc)/./node_modules/next/dist/server/lib/patch-fetch.js\");\n/* harmony import */ var next_dist_server_lib_patch_fetch__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_dist_server_lib_patch_fetch__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var D_Projects_Dev_Holiday_Travel_App_app_api_trips_route_ts__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./app/api/trips/route.ts */ \"(rsc)/./app/api/trips/route.ts\");\n\n\n\n\n// We inject the nextConfigOutput here so that we can use them in the route\n// module.\nconst nextConfigOutput = \"\"\nconst routeModule = new next_dist_server_future_route_modules_app_route_module_compiled__WEBPACK_IMPORTED_MODULE_0__.AppRouteRouteModule({\n    definition: {\n        kind: next_dist_server_future_route_kind__WEBPACK_IMPORTED_MODULE_1__.RouteKind.APP_ROUTE,\n        page: \"/api/trips/route\",\n        pathname: \"/api/trips\",\n        filename: \"route\",\n        bundlePath: \"app/api/trips/route\"\n    },\n    resolvedPagePath: \"D:\\\\Projects\\\\Dev\\\\Holiday Travel App\\\\app\\\\api\\\\trips\\\\route.ts\",\n    nextConfigOutput,\n    userland: D_Projects_Dev_Holiday_Travel_App_app_api_trips_route_ts__WEBPACK_IMPORTED_MODULE_3__\n});\n// Pull out the exports that we need to expose from the module. This should\n// be eliminated when we've moved the other routes to the new format. These\n// are used to hook into the route.\nconst { requestAsyncStorage, staticGenerationAsyncStorage, serverHooks } = routeModule;\nconst originalPathname = \"/api/trips/route\";\nfunction patchFetch() {\n    return (0,next_dist_server_lib_patch_fetch__WEBPACK_IMPORTED_MODULE_2__.patchFetch)({\n        serverHooks,\n        staticGenerationAsyncStorage\n    });\n}\n\n\n//# sourceMappingURL=app-route.js.map//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiKHJzYykvLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2J1aWxkL3dlYnBhY2svbG9hZGVycy9uZXh0LWFwcC1sb2FkZXIuanM/bmFtZT1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%2Fapi%2Ftrips%2Froute&appPaths=&pagePath=private-next-app-dir%2Fapi%2Ftrips%2Froute.ts&appDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App%5Capp&pageExtensions=tsx&pageExtensions=ts&pageExtensions=jsx&pageExtensions=js&rootDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App&isDev=true&tsconfigPath=tsconfig.json&basePath=&assetPrefix=&nextConfigOutput=&preferredRegion=&middlewareConfig=e30%3D!\n");

/***/ }),

/***/ "(rsc)/./app/api/trips/route.ts":
/*!********************************!*\
  !*** ./app/api/trips/route.ts ***!
  \********************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   GET: () => (/* binding */ GET)\n/* harmony export */ });\n/* harmony import */ var _lib_trips__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @/lib/trips */ \"(rsc)/./lib/trips.ts\");\n\nasync function GET(req) {\n    try {\n        const { searchParams } = new URL(req.url);\n        const id = searchParams.get(\"id\");\n        const status = searchParams.get(\"status\");\n        const region = searchParams.get(\"region\");\n        // Get specific trip by ID\n        if (id) {\n            const trip = (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getTripById)(id);\n            if (!trip) {\n                return new Response(JSON.stringify({\n                    error: \"Trip not found\"\n                }), {\n                    status: 404,\n                    headers: {\n                        \"content-type\": \"application/json\"\n                    }\n                });\n            }\n            return new Response(JSON.stringify({\n                trip\n            }), {\n                headers: {\n                    \"content-type\": \"application/json\"\n                }\n            });\n        }\n        // Filter by status\n        if (status) {\n            const trips = (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getTripsByStatus)(status);\n            return new Response(JSON.stringify({\n                trips,\n                count: trips.length\n            }), {\n                headers: {\n                    \"content-type\": \"application/json\"\n                }\n            });\n        }\n        // Filter by region\n        if (region) {\n            const trips = (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getTripsByRegion)(region);\n            return new Response(JSON.stringify({\n                trips,\n                count: trips.length\n            }), {\n                headers: {\n                    \"content-type\": \"application/json\"\n                }\n            });\n        }\n        // Get all trips\n        const trips = (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getAllTrips)();\n        return new Response(JSON.stringify({\n            trips,\n            count: trips.length,\n            byStatus: {\n                planning: (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getTripsByStatus)(\"planning\").length,\n                booked: (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getTripsByStatus)(\"booked\").length,\n                completed: (0,_lib_trips__WEBPACK_IMPORTED_MODULE_0__.getTripsByStatus)(\"completed\").length\n            }\n        }), {\n            headers: {\n                \"content-type\": \"application/json\"\n            }\n        });\n    } catch (e) {\n        return new Response(JSON.stringify({\n            error: e?.message || \"Failed to retrieve trips\"\n        }), {\n            status: 500,\n            headers: {\n                \"content-type\": \"application/json\"\n            }\n        });\n    }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64, \n//# sourceURL=webpack-internal:///(rsc)/./app/api/trips/route.ts\n");

/***/ }),

/***/ "(rsc)/./lib/trips.ts":
/*!**********************!*\
  !*** ./lib/trips.ts ***!
  \**********************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   TRIP_PLANS: () => (/* binding */ TRIP_PLANS),\n/* harmony export */   getAllTrips: () => (/* binding */ getAllTrips),\n/* harmony export */   getTripById: () => (/* binding */ getTripById),\n/* harmony export */   getTripsByRegion: () => (/* binding */ getTripsByRegion),\n/* harmony export */   getTripsByStatus: () => (/* binding */ getTripsByStatus)\n/* harmony export */ });\n// Trip planning database\n// Sample trips\nconst TRIP_PLANS = {\n    1: {\n        id: 1,\n        name: \"Jan 2026 Caribbean Holiday\",\n        destination: \"Mexico & Dominican Republic\",\n        region: \"Caribbean\",\n        departureDate: \"2026-01-15\",\n        tripLength: 7,\n        budget: 5500,\n        currency: \"CAD\",\n        status: \"planning\",\n        preferences: {\n            food: 10,\n            pool: 9,\n            beach: 8,\n            nightlife: 7,\n            golf: 6,\n            spa: 5,\n            outdoor: 4\n        },\n        resorts: [\n            \"Dreams Onyx Resort & Spa\",\n            \"Excellence Riviera Cancun\",\n            \"Secrets Maroma Beach\",\n            \"Hyatt Ziva Cancun\",\n            \"Moon Palace Cancun\",\n            \"Barcelo Maya Riviera\",\n            \"Grand Sirenis Riviera Maya\",\n            \"Hotel Xcaret Mexico\"\n        ],\n        notes: \"All-inclusive beach vacation. Prefer adults-only or adult-focused resorts.\",\n        createdAt: \"2025-10-29T00:00:00Z\",\n        updatedAt: \"2025-10-29T00:00:00Z\"\n    },\n    2: {\n        id: 2,\n        name: \"Fall 2026 Japan Adventure\",\n        destination: \"Tokyo, Kyoto, Osaka\",\n        region: \"Asia\",\n        departureDate: \"2026-10-15\",\n        tripLength: 14,\n        budget: 8000,\n        currency: \"CAD\",\n        status: \"planning\",\n        preferences: {\n            culture: 10,\n            food: 10,\n            shopping: 8,\n            outdoor: 7,\n            nightlife: 6\n        },\n        notes: \"Cherry blossom season alternative. Focus on temples, food tours, and cultural experiences.\",\n        createdAt: \"2025-10-29T00:00:00Z\",\n        updatedAt: \"2025-10-29T00:00:00Z\"\n    }\n};\nfunction getAllTrips() {\n    return Object.values(TRIP_PLANS);\n}\nfunction getTripById(id) {\n    const numId = typeof id === \"string\" ? parseInt(id, 10) : id;\n    return TRIP_PLANS[numId];\n}\nfunction getTripsByStatus(status) {\n    return Object.values(TRIP_PLANS).filter((trip)=>trip.status === status);\n}\nfunction getTripsByRegion(region) {\n    return Object.values(TRIP_PLANS).filter((trip)=>trip.region.toLowerCase().includes(region.toLowerCase()));\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64, \n//# sourceURL=webpack-internal:///(rsc)/./lib/trips.ts\n");

/***/ })

};
;

// load runtime
var __webpack_require__ = require("../../../webpack-runtime.js");
__webpack_require__.C(exports);
var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
var __webpack_exports__ = __webpack_require__.X(0, ["vendor-chunks/next"], () => (__webpack_exec__("(rsc)/./node_modules/next/dist/build/webpack/loaders/next-app-loader.js?name=app%2Fapi%2Ftrips%2Froute&page=%2Fapi%2Ftrips%2Froute&appPaths=&pagePath=private-next-app-dir%2Fapi%2Ftrips%2Froute.ts&appDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App%5Capp&pageExtensions=tsx&pageExtensions=ts&pageExtensions=jsx&pageExtensions=js&rootDir=D%3A%5CProjects%5CDev%5CHoliday%20Travel%20App&isDev=true&tsconfigPath=tsconfig.json&basePath=&assetPrefix=&nextConfigOutput=&preferredRegion=&middlewareConfig=e30%3D!")));
module.exports = __webpack_exports__;

})();