11 Jan 2021 08:11 AM - last edited on 18 May 2023 06:08 AM by Michal_Gebacki
I'm writing an extensive ActiveGate Plugin and would require two things (best without any additional configuration to make it reusable in an automatic fashion).
Solved! Go to Solution.
1. That's not possible without calling the API from within the extension.
2. You can either request it in the configuration (that's what we usually do), or you could pick it up from the ruxitagent.conf file.
Thanks for confirming, Mike!
That's unfortunately what I feared, seems a bit counter intuitive to add the tenantid to the plugin configuration in the very same environment one configures the plugin. I will try to maybe find a more sophisticated way to automate it.
The user that executes extensions should have access to the ruxitagent.conf file. I'd go with that if I were you.
Seeing as you're on the AG and you have the tenant id you could route the API calls via the AG, that way the user only needs to provide an API token in the config.
In case you are routing requests via local ActiveGate you will likely encounter certificate issues as ActiveGates typically have self-signed cert (default). If you supply your own one, you will have to deal with the CA certificate in your extension code anyway, unless your ActiveGate has a certificate issued by a common CA.
Too bad the extension framework does not have the capability to access API directly ... I hope for improvements in the extensions 2.0.
When using localhost or 127.0.0.1 I think it's quite safe to ignore the SSL certificate.
Extensions Framework 2.0 is scheduled to add functionality such as sending data to any entity and custom configuration. That'll hopefully resolve most use cases already without having to go via the API.