add ACAO header
This commit is contained in:
@@ -29,6 +29,7 @@ app.post("/v1/messages", apiKeyAuth, (req, res) => {
|
||||
|
||||
req.on("end", async () => {
|
||||
res.setHeader("Content-Type", "text/event-stream;charset=utf-8");
|
||||
res.setHeader("Allow-Control-Allow-Origin", "*");
|
||||
try {
|
||||
let jsonBody = JSON.parse(req.rawBody);
|
||||
if (jsonBody.stream == false) {
|
||||
|
||||
Reference in New Issue
Block a user