Closed Funk5Thousand closed 1 year ago
Hi, please check your curl arguments. It should be like this:
curl -X POST http://127.0.0.1/api/users/accessToken --header "Content-Type: application/json" --data '{"email":"test@test.com","password":"12345678"}'
{"token":"c1db7383-52cc-4b1f-af99-0653a8b94d4a:BEE4CA3CF9DC61B5FADF5BEDDC875152:888f65d729b9b547b9d315bce1bcc379","twoStepVerification":"none"}
Very good. You are right and my description is entirely inaccurate. The API functions well when used correctly. You have my sincerest apologies for the bother.
I can create a user (only through the admin API interface), but then am unable to sign that user in.
curl --location 'http://192.168.20.223/api/admin/createUser?email=user1@gmail.com&password=password1'
{"id":"2d9e30b1-34f0-493a-b959-d4f8f97fb3e0","createdAt":null,"updatedAt":null,"email":"user1@gmail.com","passwordHash":"f6fcb6c41e0c09a9112544a61b2913d7","passwordSalt":"7c45700c-0fe0-4448-b227-8c886bcd2078","twoStepVerificationType":null,"gotpSecret":null,"nickName":null}
curl --location 'http://192.168.20.223/api/users/accessToken' \ --header 'Content-Type: application/json' \ --data-raw '{ "SignInRequest": { "email": "user1@gmail.com", "password": "password1" } }'
{ "message": "401 UNAUTHORIZED \"email or password error\"" }