manifold/functions/src/health.ts
Marshall Polaris 7572e07489
Add a /health function for ease of benchmarking (#412)
* Slightly more defensive API endpoints

* Add health endpoint for benchmarking trivial Firebase fns
2022-06-03 14:49:09 -07:00

12 lines
231 B
TypeScript

import { newEndpoint } from './api'
export const health = newEndpoint(['GET'], async (_req, [user, _]) => {
return {
message: 'Server is working.',
user: {
id: user.id,
username: user.username,
},
}
})