I believe there is a bug in FILE type TEA.
In Tracker Capture app you can’t use FILE type TEA
But in Capture app you can use it, upload data
And if you upload data in the moment of TEI creation, there is no link to the uploaded file. But if you upload it after creating TEI, you will get a link
So basically your download link will be
blob:https://play.im.dhis2.org/file_identificator
But I couldn’t find any way to retrieve file from the TEI on api/trackedEntityInstances/TEI_UID/attribute_ID/data point
also check here File Uploads Tracked Entity Attributes - #7 by Ulanbek