discquist
discquist
BABetter Auth
Created by discquist on 5/20/2025 in #help
Inferred type of betterAuth client exceed compiler serialization
@Ping Yeah, not possilbe for me to disbale declaration in my projet. So i htink one solution would be if i can set the type of the instance or something?
15 replies
BABetter Auth
Created by discquist on 5/20/2025 in #help
Inferred type of betterAuth client exceed compiler serialization
Yeah i'll try that.But unsure if i want to do that since i use a ackend framework (encore.ts) that allows me to generate fully typed client to consume in my frontend.
15 replies
BABetter Auth
Created by discquist on 5/20/2025 in #help
Inferred type of betterAuth client exceed compiler serialization
Is there any type i can vast the betterAuth isntance as? That would probably help, but couldn't find.
15 replies
BABetter Auth
Created by discquist on 5/20/2025 in #help
Inferred type of betterAuth client exceed compiler serialization
Yes that's enabled
15 replies
BABetter Auth
Created by discquist on 5/20/2025 in #help
Inferred type of betterAuth client exceed compiler serialization
Anyone stumbled into the same issue? 🤔
15 replies
BABetter Auth
Created by discquist on 5/13/2025 in #help
Getting auth data in react server component when auth is handled by express backend
thanks!
3 replies
BABetter Auth
Created by discquist on 5/12/2025 in #help
Api key plugin with Prisma and express server
Hi! Thanks for the quick investigation, was pulling my hair a little bit. Rolled back to rolling my own api keys for now but will give this another try as soon as the PR is merged.
5 replies
BABetter Auth
Created by discquist on 5/12/2025 in #help
Api key plugin with Prisma and express server
And for reference here is how i configured my plugin server-side:
plugins: [
apiKey({
schema: {
apikey: {
modelName: "apiKey",
fields: {
userId: "user_id",
refillInterval: "refill_interval",
refillAmount: "refill_amount",
lastRefillAt: "last_refill_at",
rateLimitEnabled: "rate_limit_enabled",
rateLimitTimeWindow: "rate_limit_time_window",
rateLimitMax: "rate_limit_max",
requestCount: "request_count",
lastRequest: "last_request",
expiresAt: "expires_at",
createdAt: "created_at",
updatedAt: "updated_at",
},
},
},
}),
],
plugins: [
apiKey({
schema: {
apikey: {
modelName: "apiKey",
fields: {
userId: "user_id",
refillInterval: "refill_interval",
refillAmount: "refill_amount",
lastRefillAt: "last_refill_at",
rateLimitEnabled: "rate_limit_enabled",
rateLimitTimeWindow: "rate_limit_time_window",
rateLimitMax: "rate_limit_max",
requestCount: "request_count",
lastRequest: "last_request",
expiresAt: "expires_at",
createdAt: "created_at",
updatedAt: "updated_at",
},
},
},
}),
],
5 replies