ActivityDefinition for online applications, how to associate the launch URL

We are currently working on the new version of Koppeltaal (2.0), and we run into a mapping problem that started out simple and turned out to be more complicated.

What we want to achieve is to associate a launch URL with an ActivityDefinition. The launch URL is the URL where an online treatment is started. The only way we figured out doing this is by using an Endpoint entity and associate it via a Location resource. This works, however, the Location resource is merely used (or abused) to link the Endpoint to the ActivityDefinition. Also, the amount and complexity of calls to FHIR API to CRUD the entities on the model is high.

So we wonder, is this the only way to associate a launch URL to an ActivityDefinition? Are we missing something? Why can’t an ActivityDefinition not be directly associated with an Endpoint?

This seems like a good candidate for an extension, launchEndpoint (or even launch[x] (uri | Reference(Endpoint))). We’ve done similar things for activity definitions that reference questionnaires, using the collectWith extension in CPG, for example: FHIR Clinical Guidelines (v1.0.0) (STU 1)

If I understand your suggestion @Bryn_Rhodes, you mean to define an extension to the ActivityDefinition “schema” in the context of the specific project? We’d define a profile and we’d enforce that for the AD resources that are exchanged in the context of that project?