Rocky_Mountain_Vending/.pnpm-store/v10/files/ec/d2dbf2f8346de7f575cf6fd689a6950a0dfa858e65f8c9745e4a964be0cca07089d1172f089aff2cd40f4c0116b3ee3bd5321bff973311c497a7283b01a728
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

12 lines
595 B
Text

import { EndpointError } from "../types";
import { evaluateExpression } from "./evaluateExpression";
export const getEndpointHeaders = (headers, options) => Object.entries(headers).reduce((acc, [headerKey, headerVal]) => ({
...acc,
[headerKey]: headerVal.map((headerValEntry) => {
const processedExpr = evaluateExpression(headerValEntry, "Header value entry", options);
if (typeof processedExpr !== "string") {
throw new EndpointError(`Header '${headerKey}' value '${processedExpr}' is not a string`);
}
return processedExpr;
}),
}), {});