Add replyto option

This commit is contained in:
KMKoushik
2024-05-16 07:18:44 +10:00
parent 2b77ef3413
commit 3df022f6b2
8 changed files with 16 additions and 3 deletions

View File

@@ -15,6 +15,7 @@ const route = createRoute({
to: z.string().email(),
from: z.string().email(),
subject: z.string(),
replyTo: z.string().optional(),
text: z.string().optional(),
html: z.string().optional(),
attachments: z

View File

@@ -1,6 +1,7 @@
import { OpenAPIHono } from "@hono/zod-openapi";
import { swaggerUI } from "@hono/swagger-ui";
import { handleError } from "./api-error";
import { env } from "~/env";
export function getApp() {
const app = new OpenAPIHono().basePath("/api");
@@ -14,7 +15,7 @@ export function getApp() {
version: "1.0.0",
title: "Unsend API",
},
servers: [{ url: `${new URL(c.req.url).origin}/api` }],
servers: [{ url: `${env.APP_URL}/api` }],
}));
app.openAPIRegistry.registerComponent("securitySchemes", "Bearer", {