10 lines
309 B
JavaScript
10 lines
309 B
JavaScript
import { paymentService } from '../../../services/paymentService';
|
|
import { connectDB } from '../../../lib/db';
|
|
|
|
export async function POST(req) {
|
|
await connectDB();
|
|
const data = await req.json();
|
|
const order = await paymentService.createOrder(data);
|
|
return Response.json({ success: true, order });
|
|
}
|