How to solve long process rest API?

Let say we have a very long process API(it took more than 10s).

One solution was to make the process in background and return right
away, and we also need to create anther API to get_status whether the
process completed or still in progress.

I’m looking for a better solution.