apiKey plugin `minimumNameLength` is not respected
apiKey plugin option of
minimumNameLength
works when there's at least one string character. But it does not work when the /api-key/create
— body.name
field is an empty string or when body = {}
2 Replies
There are cases where API keys do not need a name.
I'll open a PR to introduce a config option to pass
requireName
in the config option.Just opened the PR, you can track it here:
https://github.com/better-auth/better-auth/pull/3129