Cortana: Creating a skill that launches a local application

317 Views Asked by At

I am currently working on a skill that, when invoked, will return the serial number of your PC. Trying to figure out how, or if it is even possible, for Cortana to run a local program on the users machine, take the data from the execution, then speak it out.

To find the serial number of your system, you can use wmic bios get serialnumber, and it'll provide a stdout with desired information. Goal is to allow a Cortana skill to launch said process and read it out to an end user. When published, any user should be able to ask, "Hey Cortana, ask Serial Number finder what my serial number is" and get back the serial number of their machine.

1

There are 1 best solutions below

0
On

It is possible to do this, but it isn't straight forward.

To launch a local application from Cortana it needs to support portal activation (URL launching). Documentation on how to get Cortana to launch an app can be found here: https://learn.microsoft.com/en-us/cortana/tutorials/bot-skills/bot-entity-channel-data

From there you can have your app use the Bot Framework direct line to send the information you want to your bot service which can then pass that back to Cortana.