FORUM CTRLX AUTOMATION
ctrlX World Partner Apps for ctrlX AUTOMATION
4 weeks ago
Hi guys, am developing a snap which is basically a webapp serving some files and getting protected using the jwt... at some point my menu.sidebar looks like this:
"menus": {
"sidebar": [
{
"id": "my-id",
"title": "Title1",
"icon": "my-icon",
"link": "/my-id?token=${bearertoken}",
"permissions": [...]
}
]...
and so far this is working fine since my link is getting created dynamically replacing the 'bearertoken' place-holder with the 'jwt' but then I decided to add also an "overview" using the same approach but in this case then the link is getting invalid since the replacement is not working, this is how my json looks like:
"overview": [
{
"id": "my-id-overview",
"title": "Title overview",
"icon": "my-icon",
"link": "/my-id/token=${bearertoken}",
"permissions": [...]
},...
this is resulting in an URL like: https://<foo>/<bar>?token=${bearertoken}
am I using the feature incorrectly? or there is another way to do it?
Thanks in advance
Best regards
José
4 weeks ago - last edited 4 weeks ago
Hi @Jipr311 ,
Might this just be a typo? It looks like you ommitted the query string seperator.
Try this instead and let me know!
"overview": [
{
"id": "my-id-overview",
"title": "Title overview",
"icon": "my-icon",
"link": "/my-id?token=${bearertoken}",
"permissions": [...]
},...
Example for reference: sdk-py-webserver
4 weeks ago
Hi Sgilk,
sorry it was a typo from me trying to obfuscate the json...
I actually tried with following json (including the query ?)
"overview": [ { "id": "my-id-overview", "title": "Title overview", "icon": "my-icon", "link": "/my-id?token=${bearertoken}", "permissions": [...] },...
with no results
3 weeks ago
Hi José,
which version of ctrlX OS are you using?
Best regards,
Nick