Update – Building & Debugging Custom Components for the Oracle Digital Assistant in Minutes!

Previously, i had summarized the steps to create and pack custom component to be deployed on the local container in ODA.

As for custom components built for ODA 19.4.1 and beyond, few changes were made. Here are the steps to create a CC.

  1. Globally install the Bots-node-sdk in your computer
npm install -g @oracle/bots-node-sdk

2. Create the custom component folder and cd into it, then;

bots-node-sdk init

3. Package the custom component.

bots-node-sdk pack

How do you debug CC code from your computer before deploying?

To run the code locally, you use;

 npm start

You have to create a tunnel to expose your localhost server to the internet. You can use ngrok or local tunnel to achieve this.

ie. If you use ngrok: >>> $ngrok http 3000

Now your url should be like below:

https://<your tunnel host>/components

Navigate to the components section in ODA select + Service button.

Select external as the deployment option as shown below: The username and password you write “none

Once connected you can now debug your code using your favorite code editor.

Happy Coding!

References:

About Laban Ndwaru

I am a Cloud Solutions Engineer working with a leading cloud solutions company. I have more than 5 years’ experience in the Tech ecosystem. I began my career as a software developer. I am a tech enthusiast, an autodidact whose interests includes Data Management, Cloud Native Development, Mobile and Bots Development, Integration, Low Code Development, AI, Analytics just to say the least.

View all posts by Laban Ndwaru →

Leave a Reply

avatar
  Subscribe  
Notify of