Using JSON scripts to extract image attachments from existing feature layers

09-23-2022 06:55 AM
New Contributor II

I have a survey where the user will draw a polygon and the survey (using a JSON script) will query and existing point feature layer and extracts the object_id of the points that area located within the drawn polygon.

I want to be able to extract the photos attached to these overlapped points but so far far have only comes across ways to extract attachment metadata but not the attachment itself.

0 Kudos
1 Reply
Esri Regular Contributor

Hello @JamesRichardson_SK

Since you have the Object ID you can return the URL for the attachmentInfos resource for that feature the user will need to select the URL to open the attachmentInfos page in a browser, Survey123 won't be able to directly import the attachment(s) from the URL to a photo question. 

Thank you,
0 Kudos