add auth and payment api
This commit is contained in:
@@ -16,5 +16,41 @@ export const _env = z
|
||||
DATABASE_USERNAME: z.string("Must be string.").nonempty("Must not empty."),
|
||||
DATABASE_PASSWORD: z.string("Must be string.").nonempty("Must not empty."),
|
||||
DATABASE_NAME: z.string("Must be string.").nonempty("Must not empty."),
|
||||
|
||||
JWT_SECRET: z.string("Must be string.").nonempty("Must not empty."),
|
||||
JWT_ALGORITHM: z.enum(
|
||||
[
|
||||
"HS256",
|
||||
"HS384",
|
||||
"HS512",
|
||||
"RS256",
|
||||
"RS384",
|
||||
"RS512",
|
||||
"ES256",
|
||||
"ES384",
|
||||
"ES512",
|
||||
"PS256",
|
||||
"PS384",
|
||||
"PS512",
|
||||
],
|
||||
"Invalid value.",
|
||||
),
|
||||
JWT_ISSUER: z.string("Must be string.").nonempty("Must not empty."),
|
||||
|
||||
MIDTRANS_BASE_URL: z.url("Must be valid URL.").nonempty("Must not empty."),
|
||||
MIDTRANS_MERCHANT_ID: z
|
||||
.string("Must be string.")
|
||||
.nonempty("Must not empty."),
|
||||
MIDTRANS_SERVER_KEY: z
|
||||
.string("Must be string.")
|
||||
.nonempty("Must not empty."),
|
||||
|
||||
MAIL_HOST: z.string("Must be string.").nonempty("Must not empty."),
|
||||
MAIL_PORT: z.coerce
|
||||
.number("Must be number.")
|
||||
.int("Must be integer.")
|
||||
.min(0, "Min 0."),
|
||||
MAIL_USERNAME: z.string("Must be string.").nonempty("Must not empty."),
|
||||
MAIL_PASSWORD: z.string("Must be string.").nonempty("Must not empty."),
|
||||
})
|
||||
.parse(Bun.env);
|
||||
|
||||
Reference in New Issue
Block a user