We generate a unique identifier or a correlation ID when we are making the very first service request. The generated unique ID is passed downstream to other calling microservices. That way, we can use the uniquely generated ID coming from the response to get logs specified to any service request. For that, we have a so-called correlation identifier or uniquely generated UUID to pass it to all services that the transaction goes through. To generate a unique ID, NPM has module UUID (https://www.npmjs.com/package/uuid).