Authorization code grant flow is returning invalid authorization code

I have set up my client application with redirect URI and am able to generate the authorization_code

When I take the auth code and try to fetch the token using Postman client I am getting “authorization code is invalid or has expired”. Please find the screenshot below

Note: I am aware that the authorization code validity is 300 seconds and have used the valid auth code to generate the access token.

Note: I am using this reference link from the documentation to generate the access token - Documentation-Link

Where am I going wrong?

@pradeepkumarl Can you attach the full url to retrieve the code? What is the redirect URI?
I think you are currently following the correct guide. You just need to exchange code with the token.
In your postman, did you configure client_id and secret under authorization tab?
Also, the code is expired very soon. It is better to set up postman environment well first and then request a code. Once you get a code, fill it in postman soon and click send button.

I was able to troubleshoot the issue. The code was already used by the application to exchange the access token from the authorization server.