Legacy Dev Forum Posts

 View Only

Sign Up

Sessions variables not while running within Genesys

  • 1.  Sessions variables not while running within Genesys

    Posted 06-05-2025 18:08

    chadmaggard95 | 2022-09-29 16:50:41 UTC | #1

    I created a flask python app using Code Authorization method. It's a azure web app that runs beautifully when running directly from the browser.. But if I launch it from within Genesys, suddenly the session variables are not available to me.

    I created functions (below) to set the tokens inside the sessions. the print statements are there for debugging out to the console. I see the token is set correcting .. but when I go to get the token.. it comes up as None. This only happens when running the app from within Genesys.. Desktop, chrome, edge.. doesnt matter. But running it outside of genesys, I can see the get statements are working..

    def settoken(value): session['value'] = value print(f"this is the value in settoken {value}") return

    def gettoken(): value = session.get('value') print(f"this is the value in gettoken {value}") return value


    Jerome.Saint-Marc | 2022-10-04 14:25:20 UTC | #2

    Hello,

    I don't think your problem specifically has to do with Genesys Cloud, but to the fact that custom client apps/interaction Widgets integrations (webapps) are embedded in an iframe element in the Genesys Desktop.

    Several browsers, like Chrome, are now enforcing security on management of cookies inside of an iframe.

    I don't know if it is the source of your problem, and if the following would be enough for Flask, but I'd set my cookies to "secure" and to "SameSite=None". Something like what's described in the this stackoverflow post.

    You may also have to set "allow-same-origin,allow-scripts" in the IFrame Sandbox Options of your Client App integration (in Genesys Desktop - Admin - Integrations).

    Regards,


    chadmaggard95 | 2022-09-30 17:45:31 UTC | #3

    Thank you very much .. That worked for me.


    system | 2022-10-31 17:46:26 UTC | #4

    This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.


    This post was migrated from the old Developer Forum.

    ref: 16518