Thursday, December 12, 2019

Unable To Fetch The affinityToken From SessionId API In Live Agent REST API


  • According to the salesforce documentation to get the affinityToken first in headers you  have to set the X-LIVEAGENT-AFFINITY as null.
  • If your not setting or if your not passing this header without null value in your request will not receive any affinityToken.


Sample request without X-LIVEAGENT-AFFINITY header:








Sample request with X-LIVEAGENT-AFFINITY header:








Hope this helps you..Enjoy..!