So, does anyone know where to find the documentation on how to download the images, which are attached to a survey? I have been using the API Rest Service to do everything else for my C# application and I assume this might be the same. I will be saving the images to a SQL Server DB. Any assistance would be greatly appreciated.
Okay, so I was incorrect. QueryAttachments() only brings back the data pertaining to the images (length, datatype, name, etc.). I did also find that using ...FeatureServer/0/17/attachments/3?token=...., I can actually view the image. Not what I want though. I need to be able to bring the image back at least in a byte . I am doing this in C# .net. Help, Anyone???
Are you still working on this issue? I imagine you are doing something similar to what I am working on. I was able to get the images from Survey123 int a byte by doing the following.
var response = wb.UploadValues(ServiceUrl + "query", "POST", request);
byte vs = response;
I was able to figure this out after I started going through the "response" and looking for the data I needed. Each of the surveys could have multiple images attached. So, I needed to iterate through the Json response of a "queryattachments" request based on a Survey "Id" and then do an "attachments" request based on the "objectid" associated with each image. Thank you for replying. It's good to know someone else is out there working on the same thing.
I don't seem to have the option to use queryAttachments and can only use the query (Which works fine for the data in the table just not the attachments). I didn't know if there was a setting you used to set this up for the feature class. It's possible I am using the query incorrect but I followed the documentation.
This is the query that is after my service_"ID IS HERE" "/FeatureServer/0/queryAttachments?objectIds=50&globalIds=&definitionExpression=&attachmentTypes=&resultOffset=&resultRecordCount="
This is the result.
I totally understand the frustration. Documentation is very limited. I "stumbled" across a good majority of the solutions. It would be easier to talk with you than message back and forth. If you have a chance you can call me at 402-471-3991. I may be leaving early today because we have an icey/snowy forecast today, but please leave me a number to call if I am not here. I am sure I can get you going in the right direction.