start signing ceremony via authentication token
Tuesday, May 25, 2021 at 01:57pmHi,
for InPerson signing, we manually launch signing ceremony with
GET https://sandbox.e-signlive.ca/access?sessionToken=token
from Postman, I got the response as sessionId such as
{
"sessionId": "89d04e0a6e29341d2ddb102f4ca678805ce3b4b0e62ed4dd"
}
but from browser, when I monitor the response when using the same URL (https://sandbox.e-signlive.ca/access?sessionToken=token), the response seems like html page.
My question is for automation testing purpose, after start session, the next is to sign the document. how do I use that sessionId in the following request for signing the document? currently, once start session is successful with returned sessionId, and I request to sign, I got 401 (unauthroized) error.
thanks,
Cindy
Reply to: start signing ceremony via authentication token
Tuesday, May 25, 2021 at 04:21pmHi Cindy,
How Postman differs from the browser is the "User-Agent" header, however from the testing purpose, returning sessionId in JSON format would be more ideal. In the following signing call, add a cookie ESIGENLIVE_SESSION_ID={the_session_id} and this will authenticate the request.
Duo
Reply to: Hi Cindy, How Postman…
Tuesday, May 25, 2021 at 04:54pmI see. how about the signing/confirm call, is it different now?
I used to have signing request for v11.25 as
POST /packages/${packageId}/documents/${DOC_ID}/approvals/${approval_Id}/sign
confirm signing request as :
POST /packages/${packageId}/documents/${DOC_ID}/actions
seems they are not working anymore for SaaS.
thanks,
Cindy
Reply to: I see. how about the signing…
Wednesday, May 26, 2021 at 09:16amHi Cindy,
Because the New Signer Experience no longer invokes these two calls, and uses GraphQL APIs instead. Although these two calls still work from my test, it became less meaningful if you want to automate testing the UI functions through this process. I am not sure if you'd like to test the equivalent GraphQL API or another aspect like using Selenium to simulate user actions.
Duo
Reply to: Hi Cindy, Because the…
Wednesday, May 26, 2021 at 09:29amHi Duo,
I saw NSE is using GraphQL, and do you have any information about GraphQL API? if so, share with me so I can build my test cases.
thanks,
Cindy
Reply to: start signing ceremony via authentication token
Wednesday, May 26, 2021 at 02:08pmHi Duo,
when I try to write the negative test case for signer order, if the 2nd signer sign before the 1st one. the signing ceremony screen(see attached) has the message "it is not your turn", I am wondering that where this message coming from? when I monitor the network traffic for this scenario, I searched for the wording, but it seems not coming from any request/response. do you have any idea?
thanks,
cindy
Reply to: start signing ceremony via authentication token
Friday, June 4, 2021 at 09:37amHi Duo,
do you get chance to take a look at my last question posted in this thread?
thanks,
Cindy
Reply to: Hi Duo, do you get chance…
Friday, June 4, 2021 at 10:09amHi Cindy,
Sorry for the late reply. The UI message "It's not your turn to sign" is rendered by javascript code, which depends on the role attributes retrieved by GraphQL API.
Duo
Reply to: start signing ceremony via authentication token
Friday, June 4, 2021 at 11:14amHi Duo,
you are saying it's controlled by javascript code which I can't find it via monitoring the network traffic in the browser?
I am doing test case for this scenario, and from assertion perspective, what I expect is when signing order is wrong which showed 'it is not your turn to sign' from the response (maybe from js or GraphQL API etc), when I test the correct signing order which doesn't have the message returned from the response.
not sure if this is achievable or not?
thanks,
Cindy
Reply to: Hi Duo, you are saying it's…
Friday, June 4, 2021 at 11:59amYes, unfortunately it's not directly returned from GraphQL API but computed by javascript code.
Duo
Reply to: start signing ceremony via authentication token
Friday, June 4, 2021 at 12:37pmI see. thanks.