mirror of
https://github.com/Nezumi-2711/multitenant-ecommerce.git
synced 2026-09-22 13:38:34 +00:00
15 lines
283 B
TypeScript
15 lines
283 B
TypeScript
import configPromise from '@payload-config'
|
|
import { getPayload } from 'payload'
|
|
|
|
export const GET = async () => {
|
|
const payload = await getPayload({
|
|
config: configPromise,
|
|
})
|
|
|
|
const data = await payload.find({
|
|
collection: 'users',
|
|
})
|
|
|
|
return Response.json(data)
|
|
}
|