Code Explainers

Code explainers tagged #api-proxy

javascript
import { NextResponse } from 'next/server'
 
const UPSTREAM = 'https://api.exchangerate.host/latest'
 

A cached exchange-rate proxy in Next.js

route-handler caching revalidation
Intermediate 7 steps