I am trying to build a small REST API for one of our clients, who was wishing for that kind of API. It's the first time I read into that topic. Most of our services take quite some time for fully processing client orders. For that the client may create resources by POSTing xml data and retrieve results (much) later by GETting the corresponding resource. That was pretty straight forward.
Now though we want to create another service, which will typically evaluate results almost immediately and I really don't know, how to implement it with best practice. Since the request can be processed immediately I want to avoid using two requests for creating and retrieving the resource. It just seems unnecessary and laborious.
On the other hand one single fitting HTTP request method does not seem to exist for this problem since POST requests shouldn't respond with anything but a response-code and GET requests should be independent from their body (today it seems to be possible to send body data with GET requests, nevertheless it seems to be bad practice and should not influence the response. In other words the server is only allowed to use information, which is contained in the URL). Further I cannot send the data as query parameter in the GET-URL since the data contains very sensitive information - we have pretty strict laws regarding that topic in my country and I learned to be very careful .
What would be best practice for implementing such kind of responsive tool. Is the REST API maybe the wrong choice anyway?
Thanks