diff --git a/packages/auth/src/auth.ts b/packages/auth/src/auth.ts index 6c553e52..53ee7bbf 100644 --- a/packages/auth/src/auth.ts +++ b/packages/auth/src/auth.ts @@ -42,7 +42,8 @@ export const initAuth = (db: dbClient) => { }, }, plugins: [ - apiKey(), + // @todo: hasing is disabled due to a bug in the api key plugin + apiKey({ disableKeyHashing: true }), magicLink({ expiresIn: 60 * 60 * 24 * 7, // 7 days sendMagicLink: async ({ email, url }) => { diff --git a/packages/db/src/schema/auth.ts b/packages/db/src/schema/auth.ts index f911a2c4..fe0786cb 100644 --- a/packages/db/src/schema/auth.ts +++ b/packages/db/src/schema/auth.ts @@ -51,7 +51,7 @@ export const verification = pgTable("verification", { updatedAt: timestamp("updatedAt"), }).enableRLS(); -export const apiKey = pgTable("apikey", { +export const apiKey = pgTable("apiKey", { id: bigserial("id", { mode: "number" }).primaryKey(), name: text("name"), start: text("start"),