aboutsummaryrefslogtreecommitdiffstats
path: root/src/routes/(app)/ecash/post/+server.ts
blob: 371582bc34e63b2a8ae48a51fd477204ee7bdfb5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
import { json } from "@sveltejs/kit";

export async function POST({ fetch, request }) {
  const { target, payload } = await request.json();
  const res = await fetch(target, {
    method: "POST",
    body: JSON.stringify(payload),
    headers: { "Content-Type": "application/json" },
  });
  return json(res);
}