onfido-python 4.6.0__py3-none-any.whl → 5.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (81) hide show
  1. onfido/__init__.py +7 -4
  2. onfido/api/default_api.py +541 -0
  3. onfido/api_client.py +2 -2
  4. onfido/configuration.py +151 -39
  5. onfido/exceptions.py +17 -0
  6. onfido/models/__init__.py +6 -3
  7. onfido/models/applicant_consent.py +111 -0
  8. onfido/models/applicant_consent_name.py +1 -0
  9. onfido/models/check.py +2 -2
  10. onfido/models/check_response.py +2 -2
  11. onfido/models/check_status.py +1 -0
  12. onfido/models/country_codes.py +1 -0
  13. onfido/models/device_intelligence_breakdown.py +7 -1
  14. onfido/models/device_intelligence_breakdown_breakdown.py +3 -3
  15. onfido/models/{device_intelligence_breakdown_breakdown_device.py → device_intelligence_breakdown_device.py} +6 -6
  16. onfido/models/{device_intelligence_breakdown_breakdown_device_breakdown.py → device_intelligence_breakdown_device_breakdown.py} +4 -4
  17. onfido/models/device_intelligence_breakdown_properties_device.py +13 -13
  18. onfido/models/device_intelligence_properties.py +116 -0
  19. onfido/models/device_intelligence_report.py +8 -12
  20. onfido/models/document.py +2 -12
  21. onfido/models/document_properties.py +15 -11
  22. onfido/models/{document_properties_driving_licence_information.py → document_properties_driving_licence_information_item.py} +4 -4
  23. onfido/models/document_report.py +3 -3
  24. onfido/models/document_report_shared.py +108 -0
  25. onfido/models/document_shared.py +2 -12
  26. onfido/models/document_types.py +1 -0
  27. onfido/models/document_video_report.py +3 -3
  28. onfido/models/document_video_with_address_information_report.py +3 -3
  29. onfido/models/document_with_address_information_report.py +3 -3
  30. onfido/models/document_with_driver_verification_report.py +3 -3
  31. onfido/models/document_with_driver_verification_report_all_of_properties.py +15 -11
  32. onfido/models/document_with_driving_licence_information_report.py +3 -3
  33. onfido/models/extraction_document_classification.py +2 -2
  34. onfido/models/extraction_extracted_data.py +2 -2
  35. onfido/models/facial_similarity_motion_report.py +3 -3
  36. onfido/models/facial_similarity_photo_fully_auto_report.py +3 -3
  37. onfido/models/facial_similarity_photo_report.py +3 -3
  38. onfido/models/facial_similarity_report_shared.py +11 -1
  39. onfido/models/facial_similarity_video_report.py +3 -3
  40. onfido/models/id_number.py +2 -2
  41. onfido/models/identity_enhanced_report.py +1 -11
  42. onfido/models/india_pan_report.py +1 -11
  43. onfido/models/known_faces_report.py +1 -11
  44. onfido/models/proof_of_address_properties.py +2 -2
  45. onfido/models/proof_of_address_report.py +1 -11
  46. onfido/models/repeat_attempts_list_repeat_attempts_inner.py +6 -6
  47. onfido/models/report_name.py +1 -0
  48. onfido/models/report_result.py +1 -0
  49. onfido/models/report_shared.py +1 -11
  50. onfido/models/report_status.py +1 -0
  51. onfido/models/report_sub_result.py +1 -0
  52. onfido/models/results_feedback.py +2 -2
  53. onfido/models/us_driving_licence_builder.py +6 -6
  54. onfido/models/us_driving_licence_report.py +1 -11
  55. onfido/models/us_driving_licence_shared.py +6 -6
  56. onfido/models/watchlist_aml_properties.py +2 -2
  57. onfido/models/watchlist_aml_report.py +1 -11
  58. onfido/models/watchlist_enhanced_report.py +1 -11
  59. onfido/models/watchlist_monitor.py +2 -2
  60. onfido/models/watchlist_monitor_builder.py +2 -2
  61. onfido/models/watchlist_monitor_shared.py +2 -2
  62. onfido/models/watchlist_peps_only_report.py +1 -11
  63. onfido/models/watchlist_sanctions_only_report.py +1 -11
  64. onfido/models/watchlist_standard_properties.py +2 -2
  65. onfido/models/watchlist_standard_report.py +1 -11
  66. onfido/models/webhook.py +11 -1
  67. onfido/models/webhook_builder.py +11 -1
  68. onfido/models/webhook_event_object_status.py +1 -0
  69. onfido/models/webhook_event_payload_object.py +1 -1
  70. onfido/models/webhook_event_resource_type.py +1 -0
  71. onfido/models/webhook_event_type.py +1 -1
  72. onfido/models/webhook_shared.py +12 -2
  73. onfido/models/webhook_updater.py +11 -1
  74. onfido/models/workflow_run_link.py +2 -2
  75. onfido/models/workflow_run_status.py +1 -0
  76. onfido/webhook_event_verifier.py +3 -2
  77. {onfido_python-4.6.0.dist-info → onfido_python-5.1.0.dist-info}/METADATA +3 -2
  78. {onfido_python-4.6.0.dist-info → onfido_python-5.1.0.dist-info}/RECORD +81 -78
  79. {onfido_python-4.6.0.dist-info → onfido_python-5.1.0.dist-info}/WHEEL +1 -1
  80. {onfido_python-4.6.0.dist-info → onfido_python-5.1.0.dist-info/licenses}/LICENSE +0 -0
  81. {onfido_python-4.6.0.dist-info → onfido_python-5.1.0.dist-info}/top_level.txt +0 -0
@@ -41,12 +41,12 @@ class DocumentVideoReport(BaseModel):
41
41
  result: Optional[ReportResult] = None
42
42
  sub_result: Optional[ReportSubResult] = None
43
43
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
44
  name: ReportName
45
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
46
46
  breakdown: Optional[DocumentBreakdown] = None
47
47
  properties: Optional[DocumentProperties] = None
48
48
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
49
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "breakdown", "properties"]
50
50
 
51
51
  model_config = ConfigDict(
52
52
  populate_by_name=True,
@@ -126,8 +126,8 @@ class DocumentVideoReport(BaseModel):
126
126
  "result": obj.get("result"),
127
127
  "sub_result": obj.get("sub_result"),
128
128
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
129
  "name": obj.get("name"),
130
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
131
131
  "breakdown": DocumentBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
132
  "properties": DocumentProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
133
133
  })
@@ -41,12 +41,12 @@ class DocumentVideoWithAddressInformationReport(BaseModel):
41
41
  result: Optional[ReportResult] = None
42
42
  sub_result: Optional[ReportSubResult] = None
43
43
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
44
  name: ReportName
45
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
46
46
  breakdown: Optional[DocumentBreakdown] = None
47
47
  properties: Optional[DocumentProperties] = None
48
48
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
49
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "breakdown", "properties"]
50
50
 
51
51
  model_config = ConfigDict(
52
52
  populate_by_name=True,
@@ -126,8 +126,8 @@ class DocumentVideoWithAddressInformationReport(BaseModel):
126
126
  "result": obj.get("result"),
127
127
  "sub_result": obj.get("sub_result"),
128
128
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
129
  "name": obj.get("name"),
130
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
131
131
  "breakdown": DocumentBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
132
  "properties": DocumentProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
133
133
  })
@@ -41,12 +41,12 @@ class DocumentWithAddressInformationReport(BaseModel):
41
41
  result: Optional[ReportResult] = None
42
42
  sub_result: Optional[ReportSubResult] = None
43
43
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
44
  name: ReportName
45
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
46
46
  breakdown: Optional[DocumentBreakdown] = None
47
47
  properties: Optional[DocumentProperties] = None
48
48
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
49
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "breakdown", "properties"]
50
50
 
51
51
  model_config = ConfigDict(
52
52
  populate_by_name=True,
@@ -126,8 +126,8 @@ class DocumentWithAddressInformationReport(BaseModel):
126
126
  "result": obj.get("result"),
127
127
  "sub_result": obj.get("sub_result"),
128
128
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
129
  "name": obj.get("name"),
130
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
131
131
  "breakdown": DocumentBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
132
  "properties": DocumentProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
133
133
  })
@@ -41,12 +41,12 @@ class DocumentWithDriverVerificationReport(BaseModel):
41
41
  result: Optional[ReportResult] = None
42
42
  sub_result: Optional[ReportSubResult] = None
43
43
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
44
  name: ReportName
45
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
46
46
  breakdown: Optional[DocumentBreakdown] = None
47
47
  properties: Optional[DocumentWithDriverVerificationReportAllOfProperties] = None
48
48
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
49
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "breakdown", "properties"]
50
50
 
51
51
  model_config = ConfigDict(
52
52
  populate_by_name=True,
@@ -126,8 +126,8 @@ class DocumentWithDriverVerificationReport(BaseModel):
126
126
  "result": obj.get("result"),
127
127
  "sub_result": obj.get("sub_result"),
128
128
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
129
  "name": obj.get("name"),
130
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
131
131
  "breakdown": DocumentBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
132
  "properties": DocumentWithDriverVerificationReportAllOfProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
133
133
  })
@@ -24,7 +24,7 @@ from onfido.models.document_properties_address_lines import DocumentPropertiesAd
24
24
  from onfido.models.document_properties_barcode_inner import DocumentPropertiesBarcodeInner
25
25
  from onfido.models.document_properties_document_classification import DocumentPropertiesDocumentClassification
26
26
  from onfido.models.document_properties_document_numbers_inner import DocumentPropertiesDocumentNumbersInner
27
- from onfido.models.document_properties_driving_licence_information import DocumentPropertiesDrivingLicenceInformation
27
+ from onfido.models.document_properties_driving_licence_information_item import DocumentPropertiesDrivingLicenceInformationItem
28
28
  from onfido.models.document_properties_extracted_data import DocumentPropertiesExtractedData
29
29
  from onfido.models.document_properties_nfc import DocumentPropertiesNfc
30
30
  from onfido.models.document_with_driver_verification_report_all_of_properties_all_of_passenger_vehicle import DocumentWithDriverVerificationReportAllOfPropertiesAllOfPassengerVehicle
@@ -78,7 +78,7 @@ class DocumentWithDriverVerificationReportAllOfProperties(BaseModel):
78
78
  address_lines: Optional[DocumentPropertiesAddressLines] = None
79
79
  barcode: Optional[List[DocumentPropertiesBarcodeInner]] = None
80
80
  nfc: Optional[DocumentPropertiesNfc] = None
81
- driving_licence_information: Optional[DocumentPropertiesDrivingLicenceInformation] = None
81
+ driving_licence_information: Optional[List[DocumentPropertiesDrivingLicenceInformationItem]] = None
82
82
  document_classification: Optional[DocumentPropertiesDocumentClassification] = None
83
83
  extracted_data: Optional[DocumentPropertiesExtractedData] = None
84
84
  drivers_licence: Optional[StrictBool] = Field(default=None, description="True for **non-restricted** driving licences")
@@ -96,8 +96,8 @@ class DocumentWithDriverVerificationReportAllOfProperties(BaseModel):
96
96
  if value is None:
97
97
  return value
98
98
 
99
- if value not in set(['superior', 'strong', 'fair', 'weak', 'unacceptable', 'unspecified_identity_evidence_strength']):
100
- raise ValueError("must be one of enum values ('superior', 'strong', 'fair', 'weak', 'unacceptable', 'unspecified_identity_evidence_strength')")
99
+ if value not in set(['superior', 'strong', 'fair', 'weak', 'unacceptable', 'unspecified_identity_evidence_strength', 'unknown_default_open_api']):
100
+ raise ValueError("must be one of enum values ('superior', 'strong', 'fair', 'weak', 'unacceptable', 'unspecified_identity_evidence_strength', 'unknown_default_open_api')")
101
101
  return value
102
102
 
103
103
  @field_validator('has_issuance_confirmation')
@@ -106,8 +106,8 @@ class DocumentWithDriverVerificationReportAllOfProperties(BaseModel):
106
106
  if value is None:
107
107
  return value
108
108
 
109
- if value not in set(['true', 'false', 'unspecified']):
110
- raise ValueError("must be one of enum values ('true', 'false', 'unspecified')")
109
+ if value not in set(['true', 'false', 'unspecified', 'unknown_default_open_api']):
110
+ raise ValueError("must be one of enum values ('true', 'false', 'unspecified', 'unknown_default_open_api')")
111
111
  return value
112
112
 
113
113
  @field_validator('security_tier')
@@ -116,8 +116,8 @@ class DocumentWithDriverVerificationReportAllOfProperties(BaseModel):
116
116
  if value is None:
117
117
  return value
118
118
 
119
- if value not in set(['tier_1', 'tier_2', 'tier_3', 'tier_4', 'tier_5', 'unspecified_security_tier']):
120
- raise ValueError("must be one of enum values ('tier_1', 'tier_2', 'tier_3', 'tier_4', 'tier_5', 'unspecified_security_tier')")
119
+ if value not in set(['tier_1', 'tier_2', 'tier_3', 'tier_4', 'tier_5', 'unspecified_security_tier', 'unknown_default_open_api']):
120
+ raise ValueError("must be one of enum values ('tier_1', 'tier_2', 'tier_3', 'tier_4', 'tier_5', 'unspecified_security_tier', 'unknown_default_open_api')")
121
121
  return value
122
122
 
123
123
  model_config = ConfigDict(
@@ -181,9 +181,13 @@ class DocumentWithDriverVerificationReportAllOfProperties(BaseModel):
181
181
  # override the default output from pydantic by calling `to_dict()` of nfc
182
182
  if self.nfc:
183
183
  _dict['nfc'] = self.nfc.to_dict()
184
- # override the default output from pydantic by calling `to_dict()` of driving_licence_information
184
+ # override the default output from pydantic by calling `to_dict()` of each item in driving_licence_information (list)
185
+ _items = []
185
186
  if self.driving_licence_information:
186
- _dict['driving_licence_information'] = self.driving_licence_information.to_dict()
187
+ for _item_driving_licence_information in self.driving_licence_information:
188
+ if _item_driving_licence_information:
189
+ _items.append(_item_driving_licence_information.to_dict())
190
+ _dict['driving_licence_information'] = _items
187
191
  # override the default output from pydantic by calling `to_dict()` of document_classification
188
192
  if self.document_classification:
189
193
  _dict['document_classification'] = self.document_classification.to_dict()
@@ -259,7 +263,7 @@ class DocumentWithDriverVerificationReportAllOfProperties(BaseModel):
259
263
  "address_lines": DocumentPropertiesAddressLines.from_dict(obj["address_lines"]) if obj.get("address_lines") is not None else None,
260
264
  "barcode": [DocumentPropertiesBarcodeInner.from_dict(_item) for _item in obj["barcode"]] if obj.get("barcode") is not None else None,
261
265
  "nfc": DocumentPropertiesNfc.from_dict(obj["nfc"]) if obj.get("nfc") is not None else None,
262
- "driving_licence_information": DocumentPropertiesDrivingLicenceInformation.from_dict(obj["driving_licence_information"]) if obj.get("driving_licence_information") is not None else None,
266
+ "driving_licence_information": [DocumentPropertiesDrivingLicenceInformationItem.from_dict(_item) for _item in obj["driving_licence_information"]] if obj.get("driving_licence_information") is not None else None,
263
267
  "document_classification": DocumentPropertiesDocumentClassification.from_dict(obj["document_classification"]) if obj.get("document_classification") is not None else None,
264
268
  "extracted_data": DocumentPropertiesExtractedData.from_dict(obj["extracted_data"]) if obj.get("extracted_data") is not None else None,
265
269
  "drivers_licence": obj.get("drivers_licence"),
@@ -41,12 +41,12 @@ class DocumentWithDrivingLicenceInformationReport(BaseModel):
41
41
  result: Optional[ReportResult] = None
42
42
  sub_result: Optional[ReportSubResult] = None
43
43
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
44
  name: ReportName
45
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
46
46
  breakdown: Optional[DocumentBreakdown] = None
47
47
  properties: Optional[DocumentProperties] = None
48
48
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
49
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "breakdown", "properties"]
50
50
 
51
51
  model_config = ConfigDict(
52
52
  populate_by_name=True,
@@ -126,8 +126,8 @@ class DocumentWithDrivingLicenceInformationReport(BaseModel):
126
126
  "result": obj.get("result"),
127
127
  "sub_result": obj.get("sub_result"),
128
128
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
129
  "name": obj.get("name"),
130
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
131
131
  "breakdown": DocumentBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
132
  "properties": DocumentProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
133
133
  })
@@ -42,8 +42,8 @@ class ExtractionDocumentClassification(BaseModel):
42
42
  if value is None:
43
43
  return value
44
44
 
45
- if value not in set(['full', 'not_full', 'provisional']):
46
- raise ValueError("must be one of enum values ('full', 'not_full', 'provisional')")
45
+ if value not in set(['full', 'not_full', 'provisional', 'unknown_default_open_api']):
46
+ raise ValueError("must be one of enum values ('full', 'not_full', 'provisional', 'unknown_default_open_api')")
47
47
  return value
48
48
 
49
49
  model_config = ConfigDict(
@@ -66,8 +66,8 @@ class ExtractionExtractedData(BaseModel):
66
66
  if value is None:
67
67
  return value
68
68
 
69
- if value not in set(['Male', 'Female']):
70
- raise ValueError("must be one of enum values ('Male', 'Female')")
69
+ if value not in set(['Male', 'Female', 'unknown_default_open_api']):
70
+ raise ValueError("must be one of enum values ('Male', 'Female', 'unknown_default_open_api')")
71
71
  return value
72
72
 
73
73
  @field_validator('nationality')
@@ -42,8 +42,8 @@ class FacialSimilarityMotionReport(BaseModel):
42
42
  result: Optional[ReportResult] = None
43
43
  sub_result: Optional[ReportSubResult] = None
44
44
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
45
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
46
45
  name: ReportName
46
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
47
47
  live_photos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live photo ids that were used in the Onfido engine.")
48
48
  live_videos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live video ids that were used in the Onfido engine.")
49
49
  motion_captures: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with motion capture ids that were used in the Onfido engine.")
@@ -51,7 +51,7 @@ class FacialSimilarityMotionReport(BaseModel):
51
51
  breakdown: Optional[FacialSimilarityMotionBreakdown] = None
52
52
  properties: Optional[FacialSimilarityMotionProperties] = None
53
53
  additional_properties: Dict[str, Any] = {}
54
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
54
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
55
55
 
56
56
  model_config = ConfigDict(
57
57
  populate_by_name=True,
@@ -159,8 +159,8 @@ class FacialSimilarityMotionReport(BaseModel):
159
159
  "result": obj.get("result"),
160
160
  "sub_result": obj.get("sub_result"),
161
161
  "check_id": obj.get("check_id"),
162
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
163
162
  "name": obj.get("name"),
163
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
164
164
  "live_photos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_photos"]] if obj.get("live_photos") is not None else None,
165
165
  "live_videos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_videos"]] if obj.get("live_videos") is not None else None,
166
166
  "motion_captures": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["motion_captures"]] if obj.get("motion_captures") is not None else None,
@@ -42,8 +42,8 @@ class FacialSimilarityPhotoFullyAutoReport(BaseModel):
42
42
  result: Optional[ReportResult] = None
43
43
  sub_result: Optional[ReportSubResult] = None
44
44
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
45
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
46
45
  name: ReportName
46
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
47
47
  live_photos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live photo ids that were used in the Onfido engine.")
48
48
  live_videos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live video ids that were used in the Onfido engine.")
49
49
  motion_captures: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with motion capture ids that were used in the Onfido engine.")
@@ -51,7 +51,7 @@ class FacialSimilarityPhotoFullyAutoReport(BaseModel):
51
51
  breakdown: Optional[FacialSimilarityPhotoFullyAutoBreakdown] = None
52
52
  properties: Optional[FacialSimilarityPhotoFullyAutoProperties] = None
53
53
  additional_properties: Dict[str, Any] = {}
54
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
54
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
55
55
 
56
56
  model_config = ConfigDict(
57
57
  populate_by_name=True,
@@ -159,8 +159,8 @@ class FacialSimilarityPhotoFullyAutoReport(BaseModel):
159
159
  "result": obj.get("result"),
160
160
  "sub_result": obj.get("sub_result"),
161
161
  "check_id": obj.get("check_id"),
162
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
163
162
  "name": obj.get("name"),
163
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
164
164
  "live_photos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_photos"]] if obj.get("live_photos") is not None else None,
165
165
  "live_videos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_videos"]] if obj.get("live_videos") is not None else None,
166
166
  "motion_captures": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["motion_captures"]] if obj.get("motion_captures") is not None else None,
@@ -42,8 +42,8 @@ class FacialSimilarityPhotoReport(BaseModel):
42
42
  result: Optional[ReportResult] = None
43
43
  sub_result: Optional[ReportSubResult] = None
44
44
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
45
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
46
45
  name: ReportName
46
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
47
47
  live_photos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live photo ids that were used in the Onfido engine.")
48
48
  live_videos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live video ids that were used in the Onfido engine.")
49
49
  motion_captures: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with motion capture ids that were used in the Onfido engine.")
@@ -51,7 +51,7 @@ class FacialSimilarityPhotoReport(BaseModel):
51
51
  breakdown: Optional[FacialSimilarityPhotoBreakdown] = None
52
52
  properties: Optional[FacialSimilarityPhotoProperties] = None
53
53
  additional_properties: Dict[str, Any] = {}
54
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
54
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
55
55
 
56
56
  model_config = ConfigDict(
57
57
  populate_by_name=True,
@@ -159,8 +159,8 @@ class FacialSimilarityPhotoReport(BaseModel):
159
159
  "result": obj.get("result"),
160
160
  "sub_result": obj.get("sub_result"),
161
161
  "check_id": obj.get("check_id"),
162
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
163
162
  "name": obj.get("name"),
163
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
164
164
  "live_photos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_photos"]] if obj.get("live_photos") is not None else None,
165
165
  "live_videos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_videos"]] if obj.get("live_videos") is not None else None,
166
166
  "motion_captures": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["motion_captures"]] if obj.get("motion_captures") is not None else None,
@@ -20,6 +20,7 @@ import json
20
20
  from pydantic import BaseModel, ConfigDict, Field
21
21
  from typing import Any, ClassVar, Dict, List, Optional
22
22
  from onfido.models.facial_similarity_report_media import FacialSimilarityReportMedia
23
+ from onfido.models.report_document import ReportDocument
23
24
  from typing import Optional, Set
24
25
  from typing_extensions import Self
25
26
 
@@ -27,12 +28,13 @@ class FacialSimilarityReportShared(BaseModel):
27
28
  """
28
29
  FacialSimilarityReportShared
29
30
  """ # noqa: E501
31
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
30
32
  live_photos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live photo ids that were used in the Onfido engine.")
31
33
  live_videos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live video ids that were used in the Onfido engine.")
32
34
  motion_captures: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with motion capture ids that were used in the Onfido engine.")
33
35
  id_photos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with id photo ids that were used in the Onfido engine.")
34
36
  additional_properties: Dict[str, Any] = {}
35
- __properties: ClassVar[List[str]] = ["live_photos", "live_videos", "motion_captures", "id_photos"]
37
+ __properties: ClassVar[List[str]] = ["documents", "live_photos", "live_videos", "motion_captures", "id_photos"]
36
38
 
37
39
  model_config = ConfigDict(
38
40
  populate_by_name=True,
@@ -75,6 +77,13 @@ class FacialSimilarityReportShared(BaseModel):
75
77
  exclude=excluded_fields,
76
78
  exclude_none=True,
77
79
  )
80
+ # override the default output from pydantic by calling `to_dict()` of each item in documents (list)
81
+ _items = []
82
+ if self.documents:
83
+ for _item_documents in self.documents:
84
+ if _item_documents:
85
+ _items.append(_item_documents.to_dict())
86
+ _dict['documents'] = _items
78
87
  # override the default output from pydantic by calling `to_dict()` of each item in live_photos (list)
79
88
  _items = []
80
89
  if self.live_photos:
@@ -120,6 +129,7 @@ class FacialSimilarityReportShared(BaseModel):
120
129
  return cls.model_validate(obj)
121
130
 
122
131
  _obj = cls.model_validate({
132
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
123
133
  "live_photos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_photos"]] if obj.get("live_photos") is not None else None,
124
134
  "live_videos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_videos"]] if obj.get("live_videos") is not None else None,
125
135
  "motion_captures": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["motion_captures"]] if obj.get("motion_captures") is not None else None,
@@ -42,8 +42,8 @@ class FacialSimilarityVideoReport(BaseModel):
42
42
  result: Optional[ReportResult] = None
43
43
  sub_result: Optional[ReportSubResult] = None
44
44
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
45
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
46
45
  name: ReportName
46
+ documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine.")
47
47
  live_photos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live photo ids that were used in the Onfido engine.")
48
48
  live_videos: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with live video ids that were used in the Onfido engine.")
49
49
  motion_captures: Optional[List[FacialSimilarityReportMedia]] = Field(default=None, description="Array of objects with motion capture ids that were used in the Onfido engine.")
@@ -51,7 +51,7 @@ class FacialSimilarityVideoReport(BaseModel):
51
51
  breakdown: Optional[FacialSimilarityVideoBreakdown] = None
52
52
  properties: Optional[FacialSimilarityVideoProperties] = None
53
53
  additional_properties: Dict[str, Any] = {}
54
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
54
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "documents", "live_photos", "live_videos", "motion_captures", "id_photos", "breakdown", "properties"]
55
55
 
56
56
  model_config = ConfigDict(
57
57
  populate_by_name=True,
@@ -159,8 +159,8 @@ class FacialSimilarityVideoReport(BaseModel):
159
159
  "result": obj.get("result"),
160
160
  "sub_result": obj.get("sub_result"),
161
161
  "check_id": obj.get("check_id"),
162
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
163
162
  "name": obj.get("name"),
163
+ "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
164
164
  "live_photos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_photos"]] if obj.get("live_photos") is not None else None,
165
165
  "live_videos": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["live_videos"]] if obj.get("live_videos") is not None else None,
166
166
  "motion_captures": [FacialSimilarityReportMedia.from_dict(_item) for _item in obj["motion_captures"]] if obj.get("motion_captures") is not None else None,
@@ -38,8 +38,8 @@ class IdNumber(BaseModel):
38
38
  if value is None:
39
39
  return value
40
40
 
41
- if value not in set(['ssn', 'social_insurance', 'tax_id', 'identity_card', 'driving_license', 'driving_licence', 'share_code', 'voter_id', 'passport', 'other']):
42
- raise ValueError("must be one of enum values ('ssn', 'social_insurance', 'tax_id', 'identity_card', 'driving_license', 'driving_licence', 'share_code', 'voter_id', 'passport', 'other')")
41
+ if value not in set(['ssn', 'social_insurance', 'tax_id', 'identity_card', 'driving_license', 'driving_licence', 'share_code', 'voter_id', 'passport', 'other', 'unknown_default_open_api']):
42
+ raise ValueError("must be one of enum values ('ssn', 'social_insurance', 'tax_id', 'identity_card', 'driving_license', 'driving_licence', 'share_code', 'voter_id', 'passport', 'other', 'unknown_default_open_api')")
43
43
  return value
44
44
 
45
45
  model_config = ConfigDict(
@@ -22,7 +22,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
22
  from typing import Any, ClassVar, Dict, List, Optional
23
23
  from onfido.models.identity_enhanced_breakdown import IdentityEnhancedBreakdown
24
24
  from onfido.models.identity_enhanced_properties import IdentityEnhancedProperties
25
- from onfido.models.report_document import ReportDocument
26
25
  from onfido.models.report_name import ReportName
27
26
  from onfido.models.report_result import ReportResult
28
27
  from onfido.models.report_status import ReportStatus
@@ -41,12 +40,11 @@ class IdentityEnhancedReport(BaseModel):
41
40
  result: Optional[ReportResult] = None
42
41
  sub_result: Optional[ReportSubResult] = None
43
42
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
43
  name: ReportName
46
44
  breakdown: Optional[IdentityEnhancedBreakdown] = None
47
45
  properties: Optional[IdentityEnhancedProperties] = None
48
46
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
47
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "breakdown", "properties"]
50
48
 
51
49
  model_config = ConfigDict(
52
50
  populate_by_name=True,
@@ -89,13 +87,6 @@ class IdentityEnhancedReport(BaseModel):
89
87
  exclude=excluded_fields,
90
88
  exclude_none=True,
91
89
  )
92
- # override the default output from pydantic by calling `to_dict()` of each item in documents (list)
93
- _items = []
94
- if self.documents:
95
- for _item_documents in self.documents:
96
- if _item_documents:
97
- _items.append(_item_documents.to_dict())
98
- _dict['documents'] = _items
99
90
  # override the default output from pydantic by calling `to_dict()` of breakdown
100
91
  if self.breakdown:
101
92
  _dict['breakdown'] = self.breakdown.to_dict()
@@ -126,7 +117,6 @@ class IdentityEnhancedReport(BaseModel):
126
117
  "result": obj.get("result"),
127
118
  "sub_result": obj.get("sub_result"),
128
119
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
120
  "name": obj.get("name"),
131
121
  "breakdown": IdentityEnhancedBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
122
  "properties": IdentityEnhancedProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
@@ -22,7 +22,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
22
  from typing import Any, ClassVar, Dict, List, Optional
23
23
  from onfido.models.india_pan_report_all_of_breakdown import IndiaPanReportAllOfBreakdown
24
24
  from onfido.models.india_pan_report_all_of_properties import IndiaPanReportAllOfProperties
25
- from onfido.models.report_document import ReportDocument
26
25
  from onfido.models.report_name import ReportName
27
26
  from onfido.models.report_result import ReportResult
28
27
  from onfido.models.report_status import ReportStatus
@@ -41,12 +40,11 @@ class IndiaPanReport(BaseModel):
41
40
  result: Optional[ReportResult] = None
42
41
  sub_result: Optional[ReportSubResult] = None
43
42
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
43
  name: ReportName
46
44
  breakdown: Optional[IndiaPanReportAllOfBreakdown] = None
47
45
  properties: Optional[IndiaPanReportAllOfProperties] = None
48
46
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
47
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "breakdown", "properties"]
50
48
 
51
49
  model_config = ConfigDict(
52
50
  populate_by_name=True,
@@ -89,13 +87,6 @@ class IndiaPanReport(BaseModel):
89
87
  exclude=excluded_fields,
90
88
  exclude_none=True,
91
89
  )
92
- # override the default output from pydantic by calling `to_dict()` of each item in documents (list)
93
- _items = []
94
- if self.documents:
95
- for _item_documents in self.documents:
96
- if _item_documents:
97
- _items.append(_item_documents.to_dict())
98
- _dict['documents'] = _items
99
90
  # override the default output from pydantic by calling `to_dict()` of breakdown
100
91
  if self.breakdown:
101
92
  _dict['breakdown'] = self.breakdown.to_dict()
@@ -126,7 +117,6 @@ class IndiaPanReport(BaseModel):
126
117
  "result": obj.get("result"),
127
118
  "sub_result": obj.get("sub_result"),
128
119
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
120
  "name": obj.get("name"),
131
121
  "breakdown": IndiaPanReportAllOfBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
122
  "properties": IndiaPanReportAllOfProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
@@ -22,7 +22,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
22
  from typing import Any, ClassVar, Dict, List, Optional
23
23
  from onfido.models.known_faces_breakdown import KnownFacesBreakdown
24
24
  from onfido.models.known_faces_properties import KnownFacesProperties
25
- from onfido.models.report_document import ReportDocument
26
25
  from onfido.models.report_name import ReportName
27
26
  from onfido.models.report_result import ReportResult
28
27
  from onfido.models.report_status import ReportStatus
@@ -41,12 +40,11 @@ class KnownFacesReport(BaseModel):
41
40
  result: Optional[ReportResult] = None
42
41
  sub_result: Optional[ReportSubResult] = None
43
42
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
43
  name: ReportName
46
44
  breakdown: Optional[KnownFacesBreakdown] = None
47
45
  properties: Optional[KnownFacesProperties] = None
48
46
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
47
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "breakdown", "properties"]
50
48
 
51
49
  model_config = ConfigDict(
52
50
  populate_by_name=True,
@@ -89,13 +87,6 @@ class KnownFacesReport(BaseModel):
89
87
  exclude=excluded_fields,
90
88
  exclude_none=True,
91
89
  )
92
- # override the default output from pydantic by calling `to_dict()` of each item in documents (list)
93
- _items = []
94
- if self.documents:
95
- for _item_documents in self.documents:
96
- if _item_documents:
97
- _items.append(_item_documents.to_dict())
98
- _dict['documents'] = _items
99
90
  # override the default output from pydantic by calling `to_dict()` of breakdown
100
91
  if self.breakdown:
101
92
  _dict['breakdown'] = self.breakdown.to_dict()
@@ -126,7 +117,6 @@ class KnownFacesReport(BaseModel):
126
117
  "result": obj.get("result"),
127
118
  "sub_result": obj.get("sub_result"),
128
119
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
120
  "name": obj.get("name"),
131
121
  "breakdown": KnownFacesBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
122
  "properties": KnownFacesProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None
@@ -44,8 +44,8 @@ class ProofOfAddressProperties(BaseModel):
44
44
  if value is None:
45
45
  return value
46
46
 
47
- if value not in set(['bank_building_society_statement', 'utility_bill', 'council_tax', 'benefit_letters', 'mortgage_statement', 'mobile_phone_bill', 'general_letter', 'insurance_statement', 'pension_property_statement_letter', 'identity_document_with_address', 'exchange_house_statement']):
48
- raise ValueError("must be one of enum values ('bank_building_society_statement', 'utility_bill', 'council_tax', 'benefit_letters', 'mortgage_statement', 'mobile_phone_bill', 'general_letter', 'insurance_statement', 'pension_property_statement_letter', 'identity_document_with_address', 'exchange_house_statement')")
47
+ if value not in set(['bank_building_society_statement', 'utility_bill', 'council_tax', 'benefit_letters', 'mortgage_statement', 'mobile_phone_bill', 'general_letter', 'insurance_statement', 'pension_property_statement_letter', 'identity_document_with_address', 'exchange_house_statement', 'unknown_default_open_api']):
48
+ raise ValueError("must be one of enum values ('bank_building_society_statement', 'utility_bill', 'council_tax', 'benefit_letters', 'mortgage_statement', 'mobile_phone_bill', 'general_letter', 'insurance_statement', 'pension_property_statement_letter', 'identity_document_with_address', 'exchange_house_statement', 'unknown_default_open_api')")
49
49
  return value
50
50
 
51
51
  model_config = ConfigDict(
@@ -22,7 +22,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
22
  from typing import Any, ClassVar, Dict, List, Optional
23
23
  from onfido.models.proof_of_address_breakdown import ProofOfAddressBreakdown
24
24
  from onfido.models.proof_of_address_properties import ProofOfAddressProperties
25
- from onfido.models.report_document import ReportDocument
26
25
  from onfido.models.report_name import ReportName
27
26
  from onfido.models.report_result import ReportResult
28
27
  from onfido.models.report_status import ReportStatus
@@ -41,12 +40,11 @@ class ProofOfAddressReport(BaseModel):
41
40
  result: Optional[ReportResult] = None
42
41
  sub_result: Optional[ReportSubResult] = None
43
42
  check_id: Optional[StrictStr] = Field(default=None, description="The ID of the check to which the report belongs. Read-only.")
44
- documents: Optional[List[ReportDocument]] = Field(default=None, description="Array of objects with document ids that were used in the Onfido engine. [ONLY POPULATED FOR DOCUMENT AND FACIAL SIMILARITY REPORTS]")
45
43
  name: ReportName
46
44
  breakdown: Optional[ProofOfAddressBreakdown] = None
47
45
  properties: Optional[ProofOfAddressProperties] = None
48
46
  additional_properties: Dict[str, Any] = {}
49
- __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "documents", "name", "breakdown", "properties"]
47
+ __properties: ClassVar[List[str]] = ["id", "created_at", "href", "status", "result", "sub_result", "check_id", "name", "breakdown", "properties"]
50
48
 
51
49
  model_config = ConfigDict(
52
50
  populate_by_name=True,
@@ -89,13 +87,6 @@ class ProofOfAddressReport(BaseModel):
89
87
  exclude=excluded_fields,
90
88
  exclude_none=True,
91
89
  )
92
- # override the default output from pydantic by calling `to_dict()` of each item in documents (list)
93
- _items = []
94
- if self.documents:
95
- for _item_documents in self.documents:
96
- if _item_documents:
97
- _items.append(_item_documents.to_dict())
98
- _dict['documents'] = _items
99
90
  # override the default output from pydantic by calling `to_dict()` of breakdown
100
91
  if self.breakdown:
101
92
  _dict['breakdown'] = self.breakdown.to_dict()
@@ -126,7 +117,6 @@ class ProofOfAddressReport(BaseModel):
126
117
  "result": obj.get("result"),
127
118
  "sub_result": obj.get("sub_result"),
128
119
  "check_id": obj.get("check_id"),
129
- "documents": [ReportDocument.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
130
120
  "name": obj.get("name"),
131
121
  "breakdown": ProofOfAddressBreakdown.from_dict(obj["breakdown"]) if obj.get("breakdown") is not None else None,
132
122
  "properties": ProofOfAddressProperties.from_dict(obj["properties"]) if obj.get("properties") is not None else None