diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ClaimDetail.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ClaimDetail.java index aa96ffe08..0ae81f0b1 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ClaimDetail.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ClaimDetail.java @@ -18,7 +18,7 @@ @AllArgsConstructor @NoArgsConstructor @JsonIgnoreProperties(ignoreUnknown = true) -public class ClaimDetail implements Serializable { +public class ClaimDetail extends VerifiedClaimDetail implements Serializable { private String value; private String[] values; diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/DocumentDetail.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/DocumentDetail.java index 68a5fbe0e..3cf674538 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/DocumentDetail.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/DocumentDetail.java @@ -5,15 +5,19 @@ */ package io.mosip.esignet.api.dto.claim; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import lombok.Data; +import java.io.Serializable; + @Data -public class DocumentDetail { +@JsonIgnoreProperties(ignoreUnknown = true) +public class DocumentDetail implements Serializable { private FilterCriteria type; - private String documentNumber; - private FilterTime dateOfIssuance; - private FilterTime dateOfExpiry; + private String document_number; + private FilterDateTime date_of_issuance; + private FilterDateTime date_of_expiry; private EvidenceIssuer issuer; diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicRecord.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicRecord.java index 0095d0fb6..fddd3f213 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicRecord.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicRecord.java @@ -5,15 +5,19 @@ */ package io.mosip.esignet.api.dto.claim; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import lombok.Data; +import java.io.Serializable; + @Data -public class ElectronicRecord extends Evidence{ +@JsonIgnoreProperties(ignoreUnknown = true) +public class ElectronicRecord implements Serializable { private FilterCriteria type; - private String personalNumber; - private FilterTime createdAt; - private FilterTime dateOfExpiry; + private String personal_number; + private FilterDateTime created_at; + private FilterDateTime date_of_expiry; private EvidenceIssuer source; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicSignature.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicSignature.java deleted file mode 100644 index 44a2b4e77..000000000 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/ElectronicSignature.java +++ /dev/null @@ -1,16 +0,0 @@ -/* - * This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at https://mozilla.org/MPL/2.0/. - */ -package io.mosip.esignet.api.dto.claim; - -import lombok.Data; - -@Data -public class ElectronicSignature{ - private FilterCriteria signatureType; - private FilterCriteria issuer; - private String serialNumber; - private FilterTime createdAt; -} diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Evidence.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Evidence.java index 2b2a267b4..99d124195 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Evidence.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Evidence.java @@ -5,21 +5,26 @@ */ package io.mosip.esignet.api.dto.claim; -import io.mosip.esignet.api.util.EvidenceType; import lombok.Data; +import java.io.Serializable; import java.util.List; @Data -public class Evidence extends ElectronicSignature{ +public class Evidence implements Serializable { - private EvidenceType evidenceType; + private FilterCriteria type; private FilterCriteria method; - private FilterTime time; - private VerificationMethod verificationMethod; - private List checkDetails; - private DocumentDetail documentDetail; + private FilterDateTime time; + private VerificationMethod verification_method; + private List check_details; + private DocumentDetail document_details; private String attestation; private ElectronicRecord record; + private FilterCriteria signature_type; + private FilterCriteria issuer; + private String serial_number; + private FilterDateTime created_at; + } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceCheckDetail.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceCheckDetail.java index 0eebec3e7..31d59c973 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceCheckDetail.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceCheckDetail.java @@ -5,14 +5,18 @@ */ package io.mosip.esignet.api.dto.claim; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import lombok.Data; +import java.io.Serializable; + @Data -public class EvidenceCheckDetail { +@JsonIgnoreProperties(ignoreUnknown = true) +public class EvidenceCheckDetail implements Serializable { - private String checkMethod; + private String check_method; private String organisation; private String txn; - private FilterTime time; + private FilterDateTime time; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceIssuer.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceIssuer.java index afd0e7eeb..6dd1ddeab 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceIssuer.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/EvidenceIssuer.java @@ -12,7 +12,7 @@ public class EvidenceIssuer { private String name; private String country; - private String countryCode; + private String country_code; private String jurisdiction; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterCriteria.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterCriteria.java index e3848df87..051f5d4d0 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterCriteria.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterCriteria.java @@ -11,12 +11,14 @@ import lombok.NoArgsConstructor; import java.io.Serializable; +import java.util.List; @Data @AllArgsConstructor @NoArgsConstructor @JsonIgnoreProperties(ignoreUnknown = true) public class FilterCriteria implements Serializable { + private String value; - private String[] values; + private List values; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterTime.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterDateTime.java similarity index 86% rename from esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterTime.java rename to esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterDateTime.java index f6aab4231..8454aa441 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterTime.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/FilterDateTime.java @@ -16,8 +16,8 @@ @AllArgsConstructor @NoArgsConstructor @JsonIgnoreProperties(ignoreUnknown = true) -public class FilterTime implements Serializable { +public class FilterDateTime implements Serializable { - private int maxAge; + private int max_age; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Verification.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Verification.java index 4d221e159..7ab3cebec 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Verification.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/Verification.java @@ -1,17 +1,15 @@ -package io.mosip.esignet.api.dto.claim; - /* * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ +package io.mosip.esignet.api.dto.claim; + import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import io.mosip.esignet.api.util.ErrorConstants; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; -import javax.validation.constraints.NotBlank; import java.io.Serializable; import java.util.List; @@ -21,10 +19,9 @@ @JsonIgnoreProperties(ignoreUnknown = true) public class Verification implements Serializable { - @NotBlank(message=ErrorConstants.INVALID_TRUST_FRAMEWORK) - private FilterCriteria trustFramework; - private FilterTime time; - private FilterCriteria assuranceLevel; + private FilterCriteria trust_framework; + private FilterDateTime time; + private FilterCriteria assurance_level; private List evidence; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerificationMethod.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerificationMethod.java index 48bfaac21..50ae46146 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerificationMethod.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerificationMethod.java @@ -5,10 +5,15 @@ */ package io.mosip.esignet.api.dto.claim; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import lombok.Data; +import java.io.Serializable; + @Data -public class VerificationMethod { +@JsonIgnoreProperties(ignoreUnknown = true) +public class VerificationMethod implements Serializable { + private FilterCriteria type; } diff --git a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerifiedClaimDetail.java b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerifiedClaimDetail.java index 4d9d0490a..daccc4816 100644 --- a/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerifiedClaimDetail.java +++ b/esignet-integration-api/src/main/java/io/mosip/esignet/api/dto/claim/VerifiedClaimDetail.java @@ -17,7 +17,7 @@ @AllArgsConstructor @NoArgsConstructor @JsonIgnoreProperties(ignoreUnknown = true) -public class VerifiedClaimDetail extends ClaimDetail implements Serializable { +public class VerifiedClaimDetail implements Serializable { private Verification verification;