Download files uploaded in event program (program without registration)

so I have an event with a data value

{'lastUpdated': '2025-06-28T11:21:28.533', 'created': '2025-06-28T19:13:03.144', 'dataElement': 'yzZEd2yEz2N', 'value': 'v4LgHeLntS8', 'providedElsewhere': False}

and want to download the file associated

I’ve found the metadata in api/fileResources/v4LgHeLntS8

{
    "name": "resized-MEDIUM-tempFile.png",
    "created": "2025-06-28T19:13:00.933",
    "lastUpdated": "2025-06-28T19:13:01.297",
    "translations": [],
    "createdBy": {
      "id": "PlhoUrBUAgj",
      "code": null
      ...
    },
    "favorites": [],
    "lastUpdatedBy": {
      "id": "PlhoUrBUAgj",
      "code": null
      ...
    },
    "sharing": {
      "external": false,
      "users": {},
      "userGroups": {}
    },
    "contentType": "image/png",
    "contentLength": 337946,
    "contentMd5": "9c18470b77af2761a2fb30afb5b8e223",
    "domain": "DATA_VALUE",
    "hasMultipleStorageFiles": true,
    "storageStatus": "STORED",
    "user": {
      "id": "PlhoUrBUAgj",
      ...
    },
    "displayName": "resized-MEDIUM-tempFile.png",
    "favorite": false,
    "id": "v4LgHeLntS8",
    "attributeValues": []
  }

I’ve tried api/fileResources/v4LgHeLntS8/data but get a 403 errors

  1. is this the correct endpoint ?
  2. what should I have as permissions on the data (my user is admin) ?

I made some progress to download the file I used this endpoint

/api/events/files?eventUid={event_id}&dataElementUid={data_element_id}"
2 Likes

Hi @Stephan_Mestach

Sorry for the delay. Do you think this topic is similar (Download Tracker File Using API - #2 by Gassim)?

Thanks!