cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
14053
Views
0
Helpful
1
Replies

How do you make Finesse REST API calls with an OAuth access token from Contact Center Express?

starrychloe
Level 1
Level 1

I was able to authenticate through Contact Center Express (and Active Directory SAML) for a custom app using the SDK and documentation.

https://developer.cisco.com/docs/contact-center-express/#!cisco-identity-service-client-sdk-guide/during-agent-login

 

However, when I received the access token, I was unable to use it to make Finesse calls. 

 

$ curl -i -k -H "Authorization: Bearer eyJhbGciOiJkaXIiLCJjdHkiOiJKV1QiLCJlbmMiOiJBMTI4Q0JDLUhTMjU2In0..XRo877mQr3ljXGqOZCngfg.7ZxGrhaL4QfCHCIRhzEYK9AqTfyCfqEDKNpjVWEBR1nQ5ui2fEhUQZjblj35k6BfmmjmlrIZK9QUDxStXtvkvZuT2FzpsF68tuGhgkbcMvYa_nXE1RBX6wxbYBRqb5WMaPBTAwguxsJyf4wkGKsM3cMzBn07u1oB53mUCnwRanrVEyhTay6c87eHdH3H0CCLB6qq1QsIoFfnQoJWr_nb9nccr_dk4VGl8otxVWalptbvAf9VSEnV208hKgWtqQMQlRYLi6he1Bwiqm9-tRpH9f4i96Mpc0yJVAhRw3otDOmxyHjTv0CMU9c3W9p-501lrdTh-yA_Pa--n1CzyvAHkxjojDFn8b6dj4igfeINZmPP3LxO5yMmMOnV2cxB9tTlAyrFbp8HQ_0o-bUDg8XQWdBAFywt6nld9IKZFjRkx1s3w1TXj_xSZVOp_RUhnUXH743SvLdzOtNKxyEzpYPi2npx2H_MlZbLXUhcooFfk6ggQ6P2oBCbUxIkVtTAeO_mK05Sgp17AH0S_kEd0lsA0105ZGmMTksh1D3sAT-1dLJaLtZAShgN9TI0wpsMncF1RvKeiZmnZ_KHA6QrKAuM5sZ-AD37LmxEsxz6pXJFmDACdb0N7V4CoVYaVDwdUZUS04emU8Rs3FnkwbN_A6fv4FxoTBiW-QaHKKb-PGC4tRBg4Nd59dEetQAkMItBAoDlmsngEcFo1QzBdEscLvcjEIB-4VtoSbnhEFUlzYgNj2v_K_QKHQ1gB5WwzskZ8grIyI-dDKpFwshFAkhYtN-xU9kQK2THKojfIknsPhARztHNbg5r1W-gRCQtb2TpuSAtVTLU-d3yM8vvBzbSgPlCGU8jvNjsU5eZ8CPipQcpdc8-hcmit4Nnu8RXtOw-j8-Kklq_U4iIoH-jO9gqhk_FP066p1aUpoyGTcmAEQ4KF0Wus4Eq95tvES3CTHs1hQkUkO5CPa_UiERcAvgY8D_J5TwjTaquV2UxENt4EIvKjgTFwDycCE4846p_N7Kpma8i6nR35JgTw9BdjzQJcvQ9hw.GImaxfsA0-vEMtBb1b9zsg" https://vm-f-fin-a.dev.in.spinsci.com/finesse/api/User/rajit.k
HTTP/1.1 401 Unauthorized
Server: Apache-Coyote/1.1
Cache-Control: no-cache, no-store
Expires: Wed, 31 Dec 1969 18:00:00 CST
X-Frame-Options: SAMEORIGIN
X-Content-Type-Options: nosniff
Strict-Transport-Security: max-age=31536000; includeSubDomains
Access-Control-Allow-Credentials: true
Content-Type: application/xml
Transfer-Encoding: chunked
Date: Thu, 23 Aug 2018 23:41:59 GMT

<ApiErrors>
  <ApiError>
    <ErrorType>Invalid Authorization User Specified</ErrorType>
    <ErrorData>rajit.k</ErrorData>
    <ErrorMessage>The user specified in the authentication credentials and the uri don&apos;t match</ErrorMessage>
  </ApiError>
</ApiErrors>

How are you supposed to make Finesse calls with an OAuth token without using HTTP Basic Authentication (because you don't know the password)?

 

1 Reply 1

avodaqsamt
Level 1
Level 1

did anyone ever find a solution for this. i am currently running into the same issue - i want to run REST API requests onto the desktop API but using the username/password of the users is really not an option