I have a custom action in one of my scripts. I want to add it to 5 other scripts, but the custom action is complex and has multiple steps (like calling data action, execute different actions based on its result, etc.) so it's hard to create it from scratch in all 5 scripts, without making any mistakes.
Is there a way to create the custom action once and import it into other existing scripts? (like we do with component templates). I can use script templates, but I won't be able to add it to existing scripts.
Also, are there any APIs or SDKs for adding scripts dynamically?
The authorization/bearer token which is mentioned relates to the access token you will get after performing the usual OAuth login flow (using Client Credentials Grant - if it is a server app; or using Implicit Grant if an app running in your web client).
You'll of course need to Create an Oauth Client for this.
See here for Tutorials on performing login and calling API: https://developer.mypurecloud.com/api/tutorials/index.html