Creating and activating users from the API

It looks like 2.5.0.beta3 was released on April 22, 2020 and the fix I made for this issue was released on April 14, 2020 so you should be able to create an active user via the API with a single request.

Can you verify your requests and response look similar to this curl command:

curl -i -sS -X POST "http://localhost:3000/users"  \
-H "Content-Type: multipart/form-data;"  \
-H "Api-Key: 079fb2bb12d3b436bb11bde8eb58aaa9a36560fa7d79b14b3087aa40b1ebc2c4"  \
-H "Api-Username: blake.erickson"  \
-F "name=8fe87241ca91a69f5ccd"  \
-F "username=8fe87241ca91a69f5ccd"  \
-F "email=8fe87241ca91a69f5ccd@example.com"  \
-F "password=c9193506a8f5e402a88cf2f8cee3f258"  \
-F "active=true"  \
-F "approved=true"

HTTP/1.1 200 OK

{
  "success": true,
  "active": true,
  "message": "Your account is activated and ready to use.",
  "user_id": 10
}
2 Likes