Custom URL scheme from Workforce?

2558
13
02-27-2018 06:22 AM
Highlighted
New Contributor II

I know you can call Survey123 from Collector or Navigator. Is it possible to launch a specific form from Workforce and pass information like the asset ID or any other relevant info I would want to carry over to Survey123? Say I want our mobile workers to receive assignations in Workforce (on their worker maps) and launch a specific form in Survey123 when they select a layer from the map inside Workforce. I know this method works quite well in Collector, but what about in Workforce? BTW -  Many thanks to Ismael Chivite and James Tedrick for their fantastic contents on GeoNet

13 Replies
Highlighted
New Contributor II

Hi Jimmy, 

What I do is to launch the settings for the project, advance and app-integration. There I can set up the survey I want the workforce to work up with, and you can transfer relevant information. 

Is this what you are looking for?

Reply
0 Kudos
Highlighted
New Contributor II

Hi Jon, 

In fact, I just want to know if we can pass field parameters via the URL scheme under Workforce to Survey123. It's a way to shorten a specific workflow, not being force to use Collector to execute this, so by example, a survey will be related to a parent feature class directly from Workforce (specifically the worker map in our case). Thanks.

Updates: After having done some tests, it doesn't work. Workforce cannot pass field parameters to Survey123 via a custom url shceme. Can someone prove me wrong? 

Highlighted
Regular Contributor II

Jimmy,

Workforce supports launching Survey123 at the Project or Assignment Type level; the doc taking you through these steps is available here:

FAQs for project owners—Workforce for ArcGIS | ArcGIS 

Tips for project owners—Workforce for ArcGIS | ArcGIS 

This allows information to be passed from a Workforce Assignment to Survey123.

However, it sounds like you would like link Survey123 to a specific feature in a feature layer in the Worker web map and pass information from that feature to the Survey.

You mention in your first post the need to pass AssetID, are there other fields that you'd like to pass?

Craig

Highlighted
New Contributor II

Hi Craig, 

What I would like to do in fact is to call a specific form in Survey123 from the Workforce worker map; so when the workers start their assignment by selecting what they have on the map, a pop-up windows would appear (with the Custom URL parameters embedded passing values to Survey123  -- ideally in a related table representing the inspections linked to an assets layers). Collector do this in a wonderful way...so I was hoping to have the same functionality within a web map in Workforce. Here is what it would look like:

I hope to have stated my problem more clearly. I know the Esri mobile apps allow some very tailored workflows and the one I'm looking for is solely about Workforce--Survey123. Please, don't hesitate if you need more details.

Thanks,

Jimmy

Highlighted
Occasional Contributor III

Craig GillgrassJimmy Bernatchez‌ has there been any update on this? I also have a use case where I'd love to have this functionality available. It would be really great for streamlining my workflow and utilizing already capture information.

Thanks,
Erica

Highlighted
New Contributor III

Also I have the same issue, I want to pass specific attributes from assets into Survey123 form, it should be doable due to worker map can configure popups. The benefits will expand if we can populate assets details from Workforce directly.

Reply
0 Kudos
Highlighted
Esri Regular Contributor

One thing you can do right now, is add additional fields to your assignments layer. For example, you could add a field named "assetName". If you are creating your assignments automatically using scripts or whatever, then you would be able to populate this field (it currently won't show up in the Workforce Dispatcher Web Application). Then you can add a custom integration to survey123 which can be opened directly from the Workforce Mobile App. In the next release of the Python API (1.5), we have added an integration manager to the Workforce Module, this makes it easier to add custom integrations.

In the following example, I've added a new field titled "assetName" and then added an integration that passes this field directly to survey123 field named "field_0". The integration looks like:

{'id': 'survey123-custom',  'prompt': 'Open in Survey123',  'urlTemplate': 'arcgis-survey123://?itemID=a7d9a4895dc744feae0269d2cd43773a&field:field_0=${assignment.assetName}'}

Example code, using the new integration manager is available here: workforce-scripts/UC 2018 - 1 - Configuring A Project.ipynb at master · Esri/workforce-scripts · Git...

You can also add custom integrations (beyond what you can do in the Web App) by editing the project json manually in AGO Assistant.

Highlighted
Occasional Contributor II

Hi Aaron 

I am considering this as a solution to pass fields from workforce to survey123.  I am just wondering if there was any pitfalls or risks associated with using it that you are aware of , as it is not fully supported via the workforce website. 

Reply
0 Kudos
Highlighted
Esri Regular Contributor

Hi Paul,

The app integrations are quite resilient. I would recommend testing the scheme for launching Survey123 using Collector or Explorer first. Just add the assignments layer into a web map and configure the popup to launch Survey as you like. When working as you expect, then use the Python API to add the integration. If you do encounter problems, you can alway use the ArcGIS Online assistant and remove the integration from the project item.

Jeff