Trouble with inviting a user to organization through http API

Hi,

I’m trying to invite a user to my organization using the http API. I’m sending the request to ozhey.grafana.net/api/org/invites.
I keep getting an error “cannot invite when login is disabled”. There’s no problem doing it through the UI.
I don’t understand why I’m getting the error or how it can be fixed - I didn’t see anything about enabling / disabling login anywhere.

Still haven’t solved it

You have to invite a new user via https://grafana.com/orgs/ozhey/members