This is just a quick guide, not a proper tutorial – I haven’t seen any, yet.
Setup your REST server that will respond to authentication by replying with either Success or Failure (and session key perhaps?). We did this in node.js with mysql back end, but other solutions are as viable (any web service that will serve request will do, even if it only supports GET and POST). Test it that it works when you use browser or any of the browser extensions to help with this. I use Postman for Chrome.
In UnrealEngine Create Widget with username and password fields and a button. Bind OnClicked action to this button, that creates request, and process response. You may want to disable the button after sending the request, until its processed. If request succeeds, you may want to ‘Remove From Parent’ the widget with login fields, and do whatever you plan to do next.
This post has a clear screenshot on how everything hangs together:
It is a little bit out of date since there were new features since the post, but overall principle is the same. Example doesn’t pass any input parameters, but it shows how to handle response. In your widget, this will be triggered from your OnClicked event.
This post from ufna clearly shows how to construct request parameters:
Once you get your OnComplete called, connect Request to GetResponseObject(), and from Response, GetStringField() – (or other types) that you need. Note that ‘OnRequestFail’ is called when there is 404 or 500 error, or timeout. NOT when user successfully typed wrong password. You’ll get OnRequestComplete, hopefully with message that it ‘failed’ – from step 1.
Something like this: