I am using the following confluence rest API to get attachments
https://{username}.atlassian.net/wiki/rest/api/content/{id}/child/attachment
I was getting the following image URL which is the image download link
https://{username}.atlassian.net/wiki/download/attachments/{id}/{image-name}.png
But the confluence has the following image URL
https://api.media.atlassian.com/file/a358c17c-46c4-40a6-9d3e-fc167a2b049a/image?mode=full-fit&client=9ce7f2cc-50c2-4c41-89a6-22a931da72c5&token=eyJhbGciOiJIUzI1NiJ9.eyJpc3MiOiI5Y2U3ZjJjYy01MGMyLTRjNDEtODlhNi0yMmE5MzFkYTcyYzUiLCJhY2Nlc3MiOnsidXJuOmZpbGVzdG9yZTpmaWxlOmEzNThjMTdjLTQ2YzQtNDBhNi05ZDNlLWZjMTY3YTJiMDQ5YSI6WyJyZWFkIl19LCJleHAiOjE1NDc2MzIwMDEsIm5iZiI6MTU0NzYyODY0MX0.nTFssKEFHXXGYT5Eydu8av5bxkZ3z7uWBt6hAWUHA94
How do I get the above URL instead of the image download link ?