Skip to content

Conversation

@dlo
Copy link
Contributor

@dlo dlo commented Aug 14, 2025

It's helpful to see when the user actually signed up, versus just when the user was imported into Clerk. This change addresses this by allowing the createdAt value to be optionally provided in users.json. This parameter is already supported by the createUser function, so all I did was add the additional parameter to the zod schema and carry it over to the function call.

I've added a usage example in the sample file as well.

@dlo dlo changed the title add createdAt support add support for importing createdAt Aug 14, 2025
@royanger
Copy link
Member

Hi @dlo. Thanks for the PR. We had started a large refactor on this that got shelved. I recently picked that back up and am about to release it. While this PR is mostly out of date compared to #11 I did take the idea from here and added createdAt and many other fields like it to the validator and the createUser() function. Thank you very much for the PR and idea.

@royanger royanger merged commit 5214a94 into clerk:main Jan 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants