Thanks for your help, I managed to find the problem using some code to debug log the redirection.
In the stack trace, there was an homemade plugin which was intercepting the API call and redirecting to the home page.
Thanks, this ticket can be closed.