Is it possible to send data back from Survey123 in a callback URL?

245
1
05-26-2021 01:28 PM
DougBrowning
MVP Notable Contributor

After hours of trying I think I know the answer but I wanted to check.

I finally got a callback URL (that double encoding is lots of fun) to work once I switched to hardcoding the values.  There are no help samples of this.

Here is my sample hardcodeing the callback values and feature globalid

arcgis-survey123://?itemID=9269d29cfc994accb9c3739c556ee345&field:LOCAL_ID={LOCAL_ID}&field:GeoGUID={globalid}&callback=https%3A%2F%2Ffieldmaps.arcgis.app%3FitemID%3D60898699d9194370985ba5d1b88ac966%26referenceContext%3DupdateFeature%26featureSourceURL%3Dhttps%3A%2F%2Fservices1.arcgis.com%2FHp6G80Pky0om7QvQ%2Farcgis%2Frest%2Fservices%2FPFCRCTest4%2FFeatureServer%2F0%26featureID%3D431c51d1-2570-4677-a13e-4a42d582cf66%26featureAttributes%3D%257B%2522LOCAL_ID%2522%3A%2522testhardcode%2522%2C%2522FormGUID%2522%3A%2522hardid%2522%257D

But what I would like to do is pull a field back from 123.  I am doing this to link the forms in both directions.  I want to send back a guid that I generate in 122.

I have tried this (unencoded).  Just the callback part works from 123 so I got that part right and I can use 123 fields just fine.

arcgis-survey123://?itemID=9269d29cfc994accb9c3739c556ee345&field:LOCAL_ID={LOCAL_ID}&field:GeoGUID={globalid}&callback=https://fieldmaps.arcgis.app?itemID=60898699d9194370985ba5d1b88ac966&referenceContext=updateFeature&...${LOCAL_ID}%22,%22FormGUID%22:%22${FormGUID}%22%7D

I have a feeling that the callback URL is hard generated at the time of the call in Field Maps.  That means referencing a field in 123 with ${LOCAL_ID} makes no sense since you are in Field Maps at the time the URL is generated.  Am I right?

If I am in right is there any way to send data to 123 via a URL then use callback to send 123 data back in to Field Maps?

thanks for any help

0 Kudos
1 Reply
DougBrowning
MVP Notable Contributor

Not seeing this covered still looking thanks  

https://doc.arcgis.com/en/survey123/reference/integratewithotherapps.htm 

0 Kudos