Genesys Cloud - Developer Community!

 View Only

Sign Up

  • 1.  loginPKCEGrant missing tokenExpiryTime

    Posted 05-12-2026 15:43

    Given the upcoming deprecation of loginImplcitGrant, we are trying to use the loginPKCEGrant from the Javascript SDK.  We noticed one difference is that the implicit grant returns an authData object which has tokenExpiryTime but when using the loginPKCEGrant, that field is not filled out.  Is that a problem with the PKCE function in the javascript SDK?

    Implicit Example

    {"accessToken":"qVnglPHpDG3_4...","tokenExpiryTime":1778264576162,"tokenExpiryTimeString":"Fri, 08 May 2026 18:22:56 GMT"}

    PKCE Example

    {"accessToken":"Fr1h_...",}


    #PlatformSDK

    ------------------------------
    Michael Shrall
    Director, Product Management
    ------------------------------


  • 2.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 05-13-2026 04:42

    Hello,

    Thanks for reporting this. I just had a look at the source and it is a miss (when persistent settings is turned on). It should be fixed in next release. I'll update this post when the build is done.

    Regards,



    ------------------------------
    Jerome Saint-Marc
    Senior Development Support Engineer
    ------------------------------



  • 3.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 05-13-2026 08:31

    Thanks for the quick review and reply!  



    ------------------------------
    Michael Shrall
    Director, Product Management
    ------------------------------



  • 4.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 05-18-2026 03:50

    Hello,

    The fix is available in the last version (built few minutes ago) - version 252.1.0

    Regards,



    ------------------------------
    Jerome Saint-Marc
    Senior Development Support Engineer
    ------------------------------



  • 5.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 05-21-2026 09:29

    I was able to verify the new version has fixed this issue.  Thanks for the quick turnaround!



    ------------------------------
    Michael Shrall
    Director, Product Management
    ------------------------------



  • 6.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 10 days ago

    Hi,

    This may be a very stupid question, and the answer may just be my own ignorance, but...

    If I use the non-minimised version of the SDK ("https://sdk-cdn.mypurecloud.com/javascript/latest/purecloud-platform-client-v2.js"), I get the "accessToken", the "tokenExpiryTime" and the "tokenExpiryTimeString" values returned.
    If I use the minimised version of the SDK ("https://sdk-cdn.mypurecloud.com/javascript/latest/purecloud-platform-client-v2.min.js"), I only get the "accessToken" value returned.

    This seems counter intuitive, but is it expected behaviour?

    The non-minimised version has:
    /**
    * @module purecloud-platform-client-v2/ApiClient
    * @version 258.2.0
    */
    I can't see a version identifier in the minimised version.

    Many thanks
    Andrew Watson



    ------------------------------
    Andrew Watson
    Architect
    ------------------------------



  • 7.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 10 days ago

    Hello,

    Yes, sorry. There is an issue with the CDN and the libraries identified with "latest" tag. I just noticed this earlier this week.

    The "https://sdk-cdn.mypurecloud.com/javascript/latest/purecloud-platform-client-v2.js" and "https://sdk-cdn.mypurecloud.com/javascript/latest/purecloud-platform-client-v2.min.js" don't point to the last and same SDK version.

    It is an issue with CLoudFront and caching I think. Until it gets solved, please use the SDK version number in the CDN url.

    I mean:

    • https://sdk-cdn.mypurecloud.com/javascript/258.2.0/purecloud-platform-client-v2.js
    • https://sdk-cdn.mypurecloud.com/javascript/258.2.0/purecloud-platform-client-v2.min.js

    regards,



    ------------------------------
    Jerome Saint-Marc
    Senior Development Support Engineer
    ------------------------------



  • 8.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 10 days ago

    Got it.

    Thanks for the quick response Jerome.

    Where will I find a notification when the issue is resolved?



    ------------------------------
    Andrew Watson
    Architect
    ------------------------------



  • 9.  RE: loginPKCEGrant missing tokenExpiryTime

    Posted 10 days ago
    Edited by Jerome Saint-Marc 10 days ago

    I'll update/reply on this post. It may take a while. Some are out of office at this time.

    Regards,



    ------------------------------
    Jerome Saint-Marc
    Senior Development Support Engineer
    ------------------------------