custom fields for credential signup

Is it possible to change the fields for registration?

maybe something like this?
export const auth = betterAuth({
    database: prismaAdapter(prisma, {
        provider: "postgresql",
    }),
    emailAndPassword: {
        enabled: true,
    },
    user: {
        fields: {
            email: "email",
            firstName: "firstName",
            lastName: "lastName",
            password: "password",
        },
    },
});
image.png
Was this page helpful?