Migrated from Redmine #597 | Author: John Guntenaar
Status: Feedback | Priority: Normal | Created: 2020-10-22
When I login using the API: POST https://user-api-v2.simplybook.me/admin/auth
I get the following response (secret data removed):
{
"token": "*******",
"company": "***",
"login": "john.***@****.com",
"refresh_token": "dea9b802b49c2dc9f94 etc.etc.etc.",
"domain": "simplybook.me",
"require2fa": false,
"allowed2fa_providers": [],
"auth_session_id": "",
"id": null
}
When I use the refresh_token to get a new user token (directly after this initial response): POST https://user-api-v2.simplybook.me/admin/auth/refresh-token
I always get a 401 with using the following payload/curl command:
curl --location --request POST 'https://user-api-v2.simplybook.me/admin/auth/refresh-token' \
--header 'Content-Type: application/json' \
--data-raw '{
"company": "***",
"refresh_token": "dea9b802b49c2dc9f94 etc.etc.etc."
}'