ianpaschal
CCConvex Community
•Created by ianpaschal on 2/23/2025 in #support-community
Convex Auth: How to add custom data to signIn() (or up)
Hello all,
I'm trying to add additional fields to my sign up form which will be added to the users table. But I can't figure out how to pass them onward. Adding them to the FormData object passed to
signIn()
doesn't seem to work. How can one add these arbitrary fields (such as username
)? I could also make it optional, but it shouldn't be, every account should have a username. So I'd prefer to set it via the sign up process.
Any help much appreciated here. Also, would be happy to make a PR improving the documentation once I figure out how it's done. The documentation states:
You can only change fields to be required or add new required fields to the users table if all your authentication methods will provide those fields during sign-up (see how to do this for OAuth and Passwords).But the linked page there doesn't actually explain how to pass that data to
signIn()
when the user submits the form. And evidently the FormData is not the correct method.
Thanks for all help in advance!31 replies