Skip to Content
Nov 13, 2020 at 01:21 AM

Starting workflow instance from CAP service

15191 Views Last edit Nov 19, 2020 at 03:19 PM 2 rev

I'm wondering if its possible (and if any examples exist) for starting a CF workflow instance from a CAP application?

I can see examples (and the open sap cap course - week 4) cover calling external services but these are always OData services with an edmx file that can be used with the `cds import` command.

(According to `cds help import`: "Currently only OData EDMX input is supported".)

The workflow APIs (∾tion=download&artifactType=REST) are REST API's only (not OData).

Alternative options would be to code the rest call directly in the UI5 app (though architecturally it seems better to do this from the cap service) or to fire an enterprise messaging event (which my cap service is doing anyway) and using CPI to capture that event and call the workflow api.