Starting a transaction
Every verification runs as a transaction. When you start it you declare the document type and the steps to run (controls); Prove ID returns a transaction ID and the gesture to use in the liveness step.
Gson gson = new Gson();JsonObject optionalData = new JsonObject();optionalData.add("idType", gson.toJsonTree("IDCARD"));optionalData.add("controls", gson.toJsonTree(Arrays.asList("FRONT", "BACK", "HOLOGRAM", "LIVENESS")));
ServerCall.startTransaction(new TransactionStartInputModel(optionalData), new TechsignServiceListener<TransactionStartReturnModel>() { @Override public void onSuccess(TransactionStartReturnModel data) { String transactionId = data.getTransactionId(); String gestureType = data.getGestureType(); // EYE, MOUTH, HEAD-VERTICAL, HEAD-HORIZONTAL // Continue with document capture }
@Override public void onFailure(Exception e) { // Show an error } });Use transactionId in every following step.
Steps (controls)
Section titled “Steps (controls)”| Document | Method | controls |
|---|---|---|
| Turkish ID card | Camera | FRONT, BACK, HOLOGRAM, LIVENESS |
| Turkish ID card | NFC | FRONT, BACK, NFC, LIVENESS |
| Driving licence | Camera | FRONT, HOLOGRAM, LIVENESS |
| Passport | Camera | FRONT, LIVENESS |
| Passport | NFC | FRONT, NFC, LIVENESS |
idType values: IDCARD, OLDIDCARD, DRIVERCARD, PASSPORT, BLUECARD, FOREIGNID.