budibase/packages/server/middleware/routeHandlers/saveRecord.js

7 lines
198 B
JavaScript

const StatusCodes = require("../../utilities/statusCodes")
module.exports = async ctx => {
ctx.body = await ctx.instance.recordApi.save(ctx.request.body)
ctx.response.status = StatusCodes.OK
}