Search in sources :

Example 1 with Address

use of com.blockscore.models.Address in project workbench by all-of-us.

the class ProfileController method submitIdVerification.

@Override
public ResponseEntity<Profile> submitIdVerification(IdVerificationRequest request) {
    // TODO(dmohs): Prevent this if the user has already attempted verification?
    Person person = blockscoreService.createPerson(request.getFirstName(), request.getLastName(), new Address().setStreet1(request.getStreetLine1()).setStreet2(request.getStreetLine2()).setCity(request.getCity()).setSubdivision(request.getState()).setPostalCode(request.getZip()).setCountryCode("US"), request.getDob(), request.getDocumentType(), request.getDocumentNumber());
    User user = userService.setBlockscoreIdVerification(person.getId(), person.isValid());
    return getProfileResponse(user);
}
Also used : User(org.pmiops.workbench.db.model.User) Address(com.blockscore.models.Address) InternetAddress(javax.mail.internet.InternetAddress) Person(com.blockscore.models.Person)

Aggregations

Address (com.blockscore.models.Address)1 Person (com.blockscore.models.Person)1 InternetAddress (javax.mail.internet.InternetAddress)1 User (org.pmiops.workbench.db.model.User)1