Execution Result API
Endpoint to query result once the device session is complete i.e. flow is completed (success / error / skipped) on the user's device.
Request
Type | URL |
---|---|
GET | https://api.attestr.com/api/{version}/public/flowx/handshake/{handshakeId} |
Request Header Parameters
Type | Name | Value / Description | Optional | Min Version | Max Version | |
---|---|---|---|---|---|---|
String | Content-Type | application/json | Required | v1 | ||
String | Authorization | Basic {authToken} | Required | v1 |
Response
HTTP status code 200
Key | Description | Type | Min Version | Max Version |
---|---|---|---|---|
_id | Id of the handshake | String | v1 | |
number | Unique number associated with handshake | String | v1 | |
tag | Unique tag as provided in createHandshake API | String | v1 | |
requestId | Unique request Id generated by Attestr for tracing purposes | String | v1 | |
consumed | Flag to check if handshake was consumed i.e. the particular handshake Id was used to execute the flow once on the user's device. | Boolean | v1 | |
archived | Returns the unix timestamp of archival if the handshake is archived | Number | v1 | |
result | Result object containing final result of execution. Null if handshake is archived. | DeviceSessionResult | v1 | |
resultSignature | Signature string generated using hmacHexDigest of result object and client secret. Null if archived. | String | v1 |
DeviceSessionResult
DeviceSessionResult is the final result object which contains the input and output for every stage traversed in the flow. It follows the below described structure. The object contains stage Id values as its keys. For every stage Id, it stores input and output. The structure of input and output varies for every stage type.
result: {
<StageId_1>: {
input: {
.. key, values
},
output: {
.. key, values
}
},
<StageId_2>: {
input: {
.. key, values
},
output: {
.. key, values
}
}
}
Sample Response
{
"_id": "DS02zfeuv6n4gkq51hvw6",
"number": "3804-324489-8469",
"tag": "290846",
"requestId": "c500f555-0dd3-4368-b5e3-c039ddb144ee",
"consumed": true,
"result": {
"FS02zfeuv3tcnkq2mond2": {
"input": {
"uuid": "4802xxxx9083",
"secret": "FxxBb",
"otp": "3xx839",
"email": null,
"mobile": null,
"code": "Rxxz"
},
"output": {
"birthDate": "26-12-1985",
"hashedEmail": null,
"hashedMobile": "c579da924e97da8605782210ff68a631ae94114f0a48115e353f2e2c47e95669",
"gender": "M",
"name": "Prajakt Goel",
"careOf": "S/O Akhilesh Goel",
"country": "India",
"district": "Hyderabad",
"houseNumber": "FLAT 101 SAI RESIDENCY",
"landmark": null,
"location": "SRINAGAR COLONY PHASE 3",
"zip": "500073",
"postOffice": "Srinagar Colony",
"state": "Telangana",
"street": null,
"subdistrict": null,
"vtc": "Khairatabad",
"pht": "/9j/4AAQSkZJRgABAgAAAQABAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMj........",
"signature": "XiHv/Bi6InvaLEulxX7e2Fb6V1o76y88TyRcW/iErzGD14+J63B5zmvh5utmRDWR4yvdQ+p2T66c\nV55OCLZ8ih4z/yWfJbPAEvKWU0/RV2yZMXt1BWSdyKmMLARWJdN3Gx+7waT6Cx7/MJ9yZZoWrfmjW8lRHVvMKJY0ahNnVNGgC0nxzzNF99dw\nbpbAQY7S0PV4m4xvj+RWlg+AGO5R2ShSstPV8vefF9CT7BNeAge3B74kg1eEjWm9UiY5tZhU5iDt\nwy8NFyjONTgf0oWfGGWKLKKSDtj57/3syuAu7g==",
"digest": "8ZFZSoSOA4sOyqsjJhPeX70aBFWEy9BBU5LeE="
}
}
},
"resultSignature": "28220f548b7ea59b25525da901d026573bccffb3692ec04fa125aeec9f7fbe42"
}