onfido 3.4.0 → 4.6.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +43 -0
- data/Gemfile +1 -0
- data/MIGRATION.md +30 -0
- data/README.md +14 -12
- data/lib/onfido/api/default_api.rb +131 -68
- data/lib/onfido/api_client.rb +31 -25
- data/lib/onfido/api_error.rb +1 -1
- data/lib/onfido/configuration.rb +11 -1
- data/lib/onfido/models/address.rb +1 -1
- data/lib/onfido/models/address_builder.rb +1 -1
- data/lib/onfido/models/address_shared.rb +1 -1
- data/lib/onfido/models/addresses_list.rb +1 -1
- data/lib/onfido/models/applicant.rb +1 -1
- data/lib/onfido/models/applicant_builder.rb +6 -3
- data/lib/onfido/models/{consent_item.rb → applicant_consent_builder.rb} +5 -18
- data/lib/onfido/models/applicant_consent_name.rb +42 -0
- data/lib/onfido/models/applicant_create.rb +1 -1
- data/lib/onfido/models/applicant_request.rb +6 -3
- data/lib/onfido/models/applicant_response.rb +1 -1
- data/lib/onfido/models/applicant_shared.rb +1 -1
- data/lib/onfido/models/applicant_update.rb +1 -1
- data/lib/onfido/models/applicant_updater.rb +6 -3
- data/lib/onfido/models/applicants_list.rb +1 -1
- data/lib/onfido/models/check.rb +33 -19
- data/lib/onfido/models/check_builder.rb +11 -2
- data/lib/onfido/models/check_request.rb +1 -1
- data/lib/onfido/models/check_response.rb +24 -19
- data/lib/onfido/models/check_shared.rb +14 -5
- data/lib/onfido/models/check_status.rb +45 -0
- data/lib/onfido/models/checks_list.rb +1 -1
- data/lib/onfido/models/complete_task_builder.rb +1 -1
- data/lib/onfido/models/complete_task_data_builder.rb +1 -1
- data/lib/onfido/models/country_codes.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown_breakdown.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown_breakdown_device.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown_breakdown_device_breakdown.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown_properties.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown_properties_device.rb +2 -42
- data/lib/onfido/models/device_intelligence_breakdown_properties_geolocation.rb +1 -1
- data/lib/onfido/models/device_intelligence_breakdown_properties_ip.rb +5 -35
- data/lib/onfido/models/device_intelligence_report.rb +1 -1
- data/lib/onfido/models/document.rb +2 -2
- data/lib/onfido/models/document_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_age_validation.rb +1 -1
- data/lib/onfido/models/document_breakdown_age_validation_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_compromised_document.rb +1 -1
- data/lib/onfido/models/document_breakdown_compromised_document_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_comparison.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_comparison_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_comparison_breakdown_issuing_country.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_consistency.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_consistency_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_validation.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_validation_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_validation_breakdown_document_expiration.rb +1 -1
- data/lib/onfido/models/document_breakdown_data_validation_breakdown_expiry_date.rb +1 -1
- data/lib/onfido/models/document_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/document_breakdown_image_integrity_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_image_integrity_breakdown_colour_picture.rb +1 -1
- data/lib/onfido/models/document_breakdown_image_integrity_breakdown_conclusive_document_quality.rb +1 -1
- data/lib/onfido/models/document_breakdown_image_integrity_breakdown_image_quality.rb +1 -1
- data/lib/onfido/models/document_breakdown_image_integrity_breakdown_supported_document.rb +1 -1
- data/lib/onfido/models/document_breakdown_issuing_authority.rb +1 -1
- data/lib/onfido/models/document_breakdown_issuing_authority_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_issuing_authority_breakdown_nfc_active_authentication.rb +1 -1
- data/lib/onfido/models/document_breakdown_issuing_authority_breakdown_nfc_passive_authentication.rb +1 -1
- data/lib/onfido/models/document_breakdown_police_record.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_digital_tampering.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_face_detection.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_fonts.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_original_document_present.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_other.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_picture_face_integrity.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_security_features.rb +1 -1
- data/lib/onfido/models/document_breakdown_visual_authenticity_breakdown_template.rb +1 -1
- data/lib/onfido/models/document_cdq_reasons.rb +1 -1
- data/lib/onfido/models/document_iq_reasons.rb +1 -1
- data/lib/onfido/models/document_odp_reasons.rb +1 -1
- data/lib/onfido/models/document_properties.rb +1 -1
- data/lib/onfido/models/document_properties_address_lines.rb +1 -1
- data/lib/onfido/models/document_properties_barcode_inner.rb +1 -1
- data/lib/onfido/models/document_properties_document_classification.rb +1 -1
- data/lib/onfido/models/document_properties_document_numbers_inner.rb +1 -1
- data/lib/onfido/models/document_properties_driving_licence_information.rb +1 -1
- data/lib/onfido/models/document_properties_extracted_data.rb +1 -1
- data/lib/onfido/models/document_properties_nfc.rb +1 -1
- data/lib/onfido/models/document_report.rb +1 -1
- data/lib/onfido/models/document_response.rb +1 -1
- data/lib/onfido/models/document_shared.rb +2 -2
- data/lib/onfido/models/document_types.rb +53 -2
- data/lib/onfido/models/document_video_report.rb +1 -1
- data/lib/onfido/models/document_video_with_address_information_report.rb +1 -1
- data/lib/onfido/models/document_with_address_information_report.rb +1 -1
- data/lib/onfido/models/document_with_driver_verification_report.rb +1 -1
- data/lib/onfido/models/document_with_driver_verification_report_all_of_properties.rb +1 -1
- data/lib/onfido/models/document_with_driver_verification_report_all_of_properties_all_of_passenger_vehicle.rb +1 -1
- data/lib/onfido/models/document_with_driver_verification_report_all_of_properties_all_of_vehicle_class_details_inner.rb +1 -1
- data/lib/onfido/models/document_with_driving_licence_information_report.rb +1 -1
- data/lib/onfido/models/documents_list.rb +1 -1
- data/lib/onfido/models/error.rb +1 -1
- data/lib/onfido/models/error1.rb +1 -1
- data/lib/onfido/models/error_properties.rb +1 -1
- data/lib/onfido/models/error_properties1.rb +1 -1
- data/lib/onfido/models/extract_request.rb +1 -1
- data/lib/onfido/models/extraction.rb +1 -1
- data/lib/onfido/models/extraction_document_classification.rb +1 -1
- data/lib/onfido/models/extraction_extracted_data.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_face_comparison.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_image_integrity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_image_integrity_breakdown_face_detected.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_image_integrity_breakdown_source_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_visual_authenticity.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_visual_authenticity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_breakdown_visual_authenticity_breakdown_spoofing_detection.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_properties.rb +1 -1
- data/lib/onfido/models/facial_similarity_motion_report.rb +51 -2
- data/lib/onfido/models/facial_similarity_photo_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_face_comparison.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_face_comparison_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_face_comparison_breakdown_face_match.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_face_comparison_breakdown_face_match_properties.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_image_integrity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_image_integrity_breakdown_face_detected.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_image_integrity_breakdown_source_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_visual_authenticity.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_visual_authenticity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_visual_authenticity_breakdown_spoofing_detection.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_breakdown_visual_authenticity_breakdown_spoofing_detection_properties.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_fully_auto_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_fully_auto_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_fully_auto_breakdown_image_integrity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_fully_auto_breakdown_image_integrity_breakdown_source_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_fully_auto_properties.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_fully_auto_report.rb +51 -2
- data/lib/onfido/models/facial_similarity_photo_properties.rb +1 -1
- data/lib/onfido/models/facial_similarity_photo_report.rb +51 -2
- data/lib/onfido/models/{consents_builder.rb → facial_similarity_report_media.rb} +23 -6
- data/lib/onfido/models/facial_similarity_report_shared.rb +253 -0
- data/lib/onfido/models/facial_similarity_video_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_face_comparison.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_image_integrity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_image_integrity_breakdown_face_detected.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_image_integrity_breakdown_source_integrity.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_visual_authenticity.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_visual_authenticity_breakdown.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_visual_authenticity_breakdown_liveness_detected.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_breakdown_visual_authenticity_breakdown_spoofing_detection.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_properties.rb +1 -1
- data/lib/onfido/models/facial_similarity_video_report.rb +51 -2
- data/lib/onfido/models/id_number.rb +3 -3
- data/lib/onfido/models/id_photo.rb +1 -1
- data/lib/onfido/models/id_photo_response.rb +1 -1
- data/lib/onfido/models/id_photos_list.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_address.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_address_breakdown.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_address_breakdown_credit_agencies.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_address_breakdown_credit_agencies_properties.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_address_breakdown_telephone_database.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_address_breakdown_voting_register.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_date_of_birth.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_date_of_birth_breakdown.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_date_of_birth_breakdown_credit_agencies.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_date_of_birth_breakdown_voting_register.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_mortality.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_sources.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_sources_breakdown.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_sources_breakdown_total_sources.rb +1 -1
- data/lib/onfido/models/identity_enhanced_breakdown_sources_breakdown_total_sources_properties.rb +1 -1
- data/lib/onfido/models/identity_enhanced_properties.rb +1 -1
- data/lib/onfido/models/identity_enhanced_properties_matched_addresses_inner.rb +1 -1
- data/lib/onfido/models/identity_enhanced_report.rb +1 -1
- data/lib/onfido/models/india_pan_report.rb +1 -1
- data/lib/onfido/models/india_pan_report_all_of_breakdown.rb +1 -1
- data/lib/onfido/models/india_pan_report_all_of_breakdown_device.rb +1 -1
- data/lib/onfido/models/india_pan_report_all_of_breakdown_device_breakdown.rb +1 -1
- data/lib/onfido/models/india_pan_report_all_of_breakdown_device_breakdown_pan_valid.rb +1 -1
- data/lib/onfido/models/india_pan_report_all_of_properties.rb +1 -1
- data/lib/onfido/models/india_pan_report_all_of_properties_device.rb +1 -1
- data/lib/onfido/models/known_faces_breakdown.rb +1 -1
- data/lib/onfido/models/known_faces_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/known_faces_breakdown_previously_seen_faces.rb +1 -1
- data/lib/onfido/models/known_faces_properties.rb +1 -1
- data/lib/onfido/models/known_faces_properties_matches_inner.rb +1 -1
- data/lib/onfido/models/known_faces_report.rb +1 -1
- data/lib/onfido/models/live_photo.rb +1 -1
- data/lib/onfido/models/live_photo_response.rb +1 -1
- data/lib/onfido/models/live_photos_list.rb +1 -1
- data/lib/onfido/models/live_video.rb +1 -1
- data/lib/onfido/models/live_videos_list.rb +1 -1
- data/lib/onfido/models/location.rb +1 -1
- data/lib/onfido/models/location_builder.rb +1 -1
- data/lib/onfido/models/location_shared.rb +1 -1
- data/lib/onfido/models/motion_capture.rb +1 -1
- data/lib/onfido/models/motion_captures_list.rb +1 -1
- data/lib/onfido/models/photo_auto_reasons.rb +1 -1
- data/lib/onfido/models/photo_reasons.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown_data_comparison.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown_data_comparison_breakdown.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown_document_classification.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown_document_classification_breakdown.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown_image_integrity.rb +1 -1
- data/lib/onfido/models/proof_of_address_breakdown_image_integrity_breakdown.rb +1 -1
- data/lib/onfido/models/proof_of_address_properties.rb +1 -1
- data/lib/onfido/models/proof_of_address_report.rb +1 -1
- data/lib/onfido/models/repeat_attempts_list.rb +1 -1
- data/lib/onfido/models/repeat_attempts_list_repeat_attempts_inner.rb +1 -1
- data/lib/onfido/models/report.rb +1 -1
- data/lib/onfido/models/report_document.rb +1 -1
- data/lib/onfido/models/report_name.rb +1 -1
- data/lib/onfido/models/report_result.rb +1 -1
- data/lib/onfido/models/report_shared.rb +1 -1
- data/lib/onfido/models/report_status.rb +1 -1
- data/lib/onfido/models/report_sub_result.rb +1 -1
- data/lib/onfido/models/reports_list.rb +1 -1
- data/lib/onfido/models/results_feedback.rb +1 -1
- data/lib/onfido/models/sdk_token.rb +1 -1
- data/lib/onfido/models/sdk_token_builder.rb +1 -1
- data/lib/onfido/models/sdk_token_request.rb +1 -1
- data/lib/onfido/models/sdk_token_response.rb +1 -1
- data/lib/onfido/models/task.rb +2 -2
- data/lib/onfido/models/task_item.rb +23 -2
- data/lib/onfido/models/timeline_file_reference.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown_address.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown_address_breakdown.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown_document.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown_document_breakdown.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown_personal.rb +1 -1
- data/lib/onfido/models/us_driving_licence_breakdown_personal_breakdown.rb +1 -1
- data/lib/onfido/models/us_driving_licence_builder.rb +1 -1
- data/lib/onfido/models/us_driving_licence_report.rb +1 -1
- data/lib/onfido/models/us_driving_licence_shared.rb +1 -1
- data/lib/onfido/models/video_reasons.rb +1 -1
- data/lib/onfido/models/watchlist_aml_breakdown.rb +1 -1
- data/lib/onfido/models/watchlist_aml_breakdown_adverse_media.rb +1 -1
- data/lib/onfido/models/watchlist_aml_breakdown_legal_and_regulatory_warnings.rb +1 -1
- data/lib/onfido/models/watchlist_aml_breakdown_politically_exposed_person.rb +1 -1
- data/lib/onfido/models/watchlist_aml_breakdown_sanction.rb +1 -1
- data/lib/onfido/models/watchlist_aml_properties.rb +1 -1
- data/lib/onfido/models/watchlist_aml_report.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_breakdown.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_address_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_alias_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_associate_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_attribute_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_event_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_event_inner_source.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_properties_records_inner_source_inner.rb +1 -1
- data/lib/onfido/models/watchlist_enhanced_report.rb +1 -1
- data/lib/onfido/models/watchlist_monitor.rb +1 -1
- data/lib/onfido/models/watchlist_monitor_builder.rb +1 -1
- data/lib/onfido/models/watchlist_monitor_match.rb +1 -1
- data/lib/onfido/models/watchlist_monitor_matches_list.rb +1 -1
- data/lib/onfido/models/watchlist_monitor_matches_updater.rb +1 -1
- data/lib/onfido/models/watchlist_monitor_response.rb +1 -1
- data/lib/onfido/models/watchlist_monitor_shared.rb +1 -1
- data/lib/onfido/models/watchlist_monitors_list.rb +1 -1
- data/lib/onfido/models/watchlist_peps_only_report.rb +1 -1
- data/lib/onfido/models/watchlist_sanctions_only_report.rb +1 -1
- data/lib/onfido/models/watchlist_standard_breakdown.rb +1 -1
- data/lib/onfido/models/watchlist_standard_properties.rb +1 -1
- data/lib/onfido/models/watchlist_standard_report.rb +1 -1
- data/lib/onfido/models/webhook.rb +1 -1
- data/lib/onfido/models/webhook_builder.rb +1 -1
- data/lib/onfido/models/webhook_create.rb +1 -1
- data/lib/onfido/models/webhook_event.rb +1 -1
- data/lib/onfido/models/webhook_event_object_status.rb +58 -0
- data/lib/onfido/models/webhook_event_payload.rb +3 -4
- data/lib/onfido/models/webhook_event_payload_object.rb +24 -3
- data/lib/onfido/models/webhook_event_payload_resource.rb +409 -0
- data/lib/onfido/models/webhook_event_resource_type.rb +47 -0
- data/lib/onfido/models/webhook_event_type.rb +3 -2
- data/lib/onfido/models/webhook_resend.rb +1 -1
- data/lib/onfido/models/webhook_response.rb +1 -1
- data/lib/onfido/models/webhook_shared.rb +1 -1
- data/lib/onfido/models/webhook_update.rb +1 -1
- data/lib/onfido/models/webhook_updater.rb +1 -1
- data/lib/onfido/models/webhooks_list.rb +1 -1
- data/lib/onfido/models/webhooks_resend_item.rb +1 -1
- data/lib/onfido/models/workflow_run.rb +6 -16
- data/lib/onfido/models/workflow_run_builder.rb +3 -2
- data/lib/onfido/models/{workflow_run_response_error.rb → workflow_run_error.rb} +4 -5
- data/lib/onfido/models/{workflow_run_shared_link.rb → workflow_run_link.rb} +8 -5
- data/lib/onfido/models/workflow_run_request.rb +1 -1
- data/lib/onfido/models/workflow_run_response.rb +4 -15
- data/lib/onfido/models/workflow_run_shared.rb +3 -2
- data/lib/onfido/models/workflow_run_status.rb +47 -0
- data/lib/onfido/version.rb +2 -2
- data/lib/onfido.rb +12 -5
- data/onfido.gemspec +1 -1
- data/spec/{webhook_event_verifier_spec.rb → classic_webhook_event_verifier_spec.rb} +4 -4
- data/spec/integrations/applicant_spec.rb +5 -1
- data/spec/integrations/check_spec.rb +4 -4
- data/spec/integrations/document_spec.rb +1 -1
- data/spec/integrations/qualified_electronic_signature_spec.rb +1 -1
- data/spec/integrations/report_schema_spec.rb +17 -0
- data/spec/integrations/report_spec.rb +4 -2
- data/spec/integrations/workflow_run_spec.rb +14 -3
- data/spec/media/studio_webhook_event_with_list_in_output.json +31 -0
- data/spec/media/studio_webhook_event_with_object_in_output.json +264 -0
- data/spec/shared_contexts/with_check.rb +1 -0
- data/spec/shared_contexts/with_document.rb +1 -1
- data/spec/spec_helper.rb +3 -3
- data/spec/studio_webhook_event_verifier_spec.rb +78 -0
- metadata +42 -28
@@ -0,0 +1,409 @@
|
|
1
|
+
=begin
|
2
|
+
#Onfido API v3.6
|
3
|
+
|
4
|
+
#The Onfido API (v3.6)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v3.6
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module Onfido
|
17
|
+
# The resource affected by this event.
|
18
|
+
class WebhookEventPayloadResource
|
19
|
+
# The identifier of the resource.
|
20
|
+
attr_accessor :id
|
21
|
+
|
22
|
+
# The unique identifier for the Applicant.
|
23
|
+
attr_accessor :applicant_id
|
24
|
+
|
25
|
+
# The date and time when the resource was created.
|
26
|
+
attr_accessor :created_at
|
27
|
+
|
28
|
+
# The date and time when the resource was last updated.
|
29
|
+
attr_accessor :updated_at
|
30
|
+
|
31
|
+
# The URL for viewing the resource on Onfido Dashboard.
|
32
|
+
attr_accessor :dashboard_url
|
33
|
+
|
34
|
+
# The unique identifier for the Workflow.
|
35
|
+
attr_accessor :workflow_id
|
36
|
+
|
37
|
+
attr_accessor :workflow_run_id
|
38
|
+
|
39
|
+
# The identifier for the Workflow version.
|
40
|
+
attr_accessor :workflow_version_id
|
41
|
+
|
42
|
+
# The identifier for the Task Definition.
|
43
|
+
attr_accessor :task_def_id
|
44
|
+
|
45
|
+
# The task definition version.
|
46
|
+
attr_accessor :task_def_version
|
47
|
+
|
48
|
+
# Input object with the fields used by the Task execution.
|
49
|
+
attr_accessor :input
|
50
|
+
|
51
|
+
# Value field (it can be an Object, List, etc.) with the fields produced by the Task execution.
|
52
|
+
attr_accessor :output
|
53
|
+
|
54
|
+
# The reasons the Workflow Run outcome was reached. Configurable when creating the Workflow Version.
|
55
|
+
attr_accessor :reasons
|
56
|
+
|
57
|
+
# Object for the configuration of the Workflow Run link.
|
58
|
+
attr_accessor :link
|
59
|
+
|
60
|
+
# Error object that details why a Workflow Run is in Error status.
|
61
|
+
attr_accessor :error
|
62
|
+
|
63
|
+
# Customer-provided user identifier.
|
64
|
+
attr_accessor :customer_user_id
|
65
|
+
|
66
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
67
|
+
def self.attribute_map
|
68
|
+
{
|
69
|
+
:'id' => :'id',
|
70
|
+
:'applicant_id' => :'applicant_id',
|
71
|
+
:'created_at' => :'created_at',
|
72
|
+
:'updated_at' => :'updated_at',
|
73
|
+
:'dashboard_url' => :'dashboard_url',
|
74
|
+
:'workflow_id' => :'workflow_id',
|
75
|
+
:'workflow_run_id' => :'workflow_run_id',
|
76
|
+
:'workflow_version_id' => :'workflow_version_id',
|
77
|
+
:'task_def_id' => :'task_def_id',
|
78
|
+
:'task_def_version' => :'task_def_version',
|
79
|
+
:'input' => :'input',
|
80
|
+
:'output' => :'output',
|
81
|
+
:'reasons' => :'reasons',
|
82
|
+
:'link' => :'link',
|
83
|
+
:'error' => :'error',
|
84
|
+
:'customer_user_id' => :'customer_user_id'
|
85
|
+
}
|
86
|
+
end
|
87
|
+
|
88
|
+
# Returns all the JSON keys this model knows about
|
89
|
+
def self.acceptable_attributes
|
90
|
+
attribute_map.values
|
91
|
+
end
|
92
|
+
|
93
|
+
# Attribute type mapping.
|
94
|
+
def self.openapi_types
|
95
|
+
{
|
96
|
+
:'id' => :'String',
|
97
|
+
:'applicant_id' => :'String',
|
98
|
+
:'created_at' => :'Time',
|
99
|
+
:'updated_at' => :'Time',
|
100
|
+
:'dashboard_url' => :'String',
|
101
|
+
:'workflow_id' => :'String',
|
102
|
+
:'workflow_run_id' => :'String',
|
103
|
+
:'workflow_version_id' => :'Integer',
|
104
|
+
:'task_def_id' => :'String',
|
105
|
+
:'task_def_version' => :'String',
|
106
|
+
:'input' => :'Object',
|
107
|
+
:'output' => :'Object',
|
108
|
+
:'reasons' => :'Array<String>',
|
109
|
+
:'link' => :'WorkflowRunLink',
|
110
|
+
:'error' => :'WorkflowRunError',
|
111
|
+
:'customer_user_id' => :'String'
|
112
|
+
}
|
113
|
+
end
|
114
|
+
|
115
|
+
# List of attributes with nullable: true
|
116
|
+
def self.openapi_nullable
|
117
|
+
Set.new([
|
118
|
+
:'task_def_version',
|
119
|
+
:'output',
|
120
|
+
])
|
121
|
+
end
|
122
|
+
|
123
|
+
# Initializes the object
|
124
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
125
|
+
def initialize(attributes = {})
|
126
|
+
if (!attributes.is_a?(Hash))
|
127
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Onfido::WebhookEventPayloadResource` initialize method"
|
128
|
+
end
|
129
|
+
|
130
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
131
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
132
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
133
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Onfido::WebhookEventPayloadResource`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
134
|
+
end
|
135
|
+
h[k.to_sym] = v
|
136
|
+
}
|
137
|
+
|
138
|
+
if attributes.key?(:'id')
|
139
|
+
self.id = attributes[:'id']
|
140
|
+
end
|
141
|
+
|
142
|
+
if attributes.key?(:'applicant_id')
|
143
|
+
self.applicant_id = attributes[:'applicant_id']
|
144
|
+
end
|
145
|
+
|
146
|
+
if attributes.key?(:'created_at')
|
147
|
+
self.created_at = attributes[:'created_at']
|
148
|
+
end
|
149
|
+
|
150
|
+
if attributes.key?(:'updated_at')
|
151
|
+
self.updated_at = attributes[:'updated_at']
|
152
|
+
end
|
153
|
+
|
154
|
+
if attributes.key?(:'dashboard_url')
|
155
|
+
self.dashboard_url = attributes[:'dashboard_url']
|
156
|
+
end
|
157
|
+
|
158
|
+
if attributes.key?(:'workflow_id')
|
159
|
+
self.workflow_id = attributes[:'workflow_id']
|
160
|
+
end
|
161
|
+
|
162
|
+
if attributes.key?(:'workflow_run_id')
|
163
|
+
self.workflow_run_id = attributes[:'workflow_run_id']
|
164
|
+
end
|
165
|
+
|
166
|
+
if attributes.key?(:'workflow_version_id')
|
167
|
+
self.workflow_version_id = attributes[:'workflow_version_id']
|
168
|
+
end
|
169
|
+
|
170
|
+
if attributes.key?(:'task_def_id')
|
171
|
+
self.task_def_id = attributes[:'task_def_id']
|
172
|
+
end
|
173
|
+
|
174
|
+
if attributes.key?(:'task_def_version')
|
175
|
+
self.task_def_version = attributes[:'task_def_version']
|
176
|
+
end
|
177
|
+
|
178
|
+
if attributes.key?(:'input')
|
179
|
+
self.input = attributes[:'input']
|
180
|
+
end
|
181
|
+
|
182
|
+
if attributes.key?(:'output')
|
183
|
+
self.output = attributes[:'output']
|
184
|
+
end
|
185
|
+
|
186
|
+
if attributes.key?(:'reasons')
|
187
|
+
if (value = attributes[:'reasons']).is_a?(Array)
|
188
|
+
self.reasons = value
|
189
|
+
end
|
190
|
+
end
|
191
|
+
|
192
|
+
if attributes.key?(:'link')
|
193
|
+
self.link = attributes[:'link']
|
194
|
+
end
|
195
|
+
|
196
|
+
if attributes.key?(:'error')
|
197
|
+
self.error = attributes[:'error']
|
198
|
+
end
|
199
|
+
|
200
|
+
if attributes.key?(:'customer_user_id')
|
201
|
+
self.customer_user_id = attributes[:'customer_user_id']
|
202
|
+
end
|
203
|
+
end
|
204
|
+
|
205
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
206
|
+
# @return Array for valid properties with the reasons
|
207
|
+
def list_invalid_properties
|
208
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
209
|
+
invalid_properties = Array.new
|
210
|
+
pattern = Regexp.new(/^[0-9a-z_-]+$/)
|
211
|
+
if !@task_def_id.nil? && @task_def_id !~ pattern
|
212
|
+
invalid_properties.push("invalid value for \"task_def_id\", must conform to the pattern #{pattern}.")
|
213
|
+
end
|
214
|
+
|
215
|
+
if !@customer_user_id.nil? && @customer_user_id.to_s.length > 256
|
216
|
+
invalid_properties.push('invalid value for "customer_user_id", the character length must be smaller than or equal to 256.')
|
217
|
+
end
|
218
|
+
|
219
|
+
invalid_properties
|
220
|
+
end
|
221
|
+
|
222
|
+
# Check to see if the all the properties in the model are valid
|
223
|
+
# @return true if the model is valid
|
224
|
+
def valid?
|
225
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
226
|
+
return false if !@task_def_id.nil? && @task_def_id !~ Regexp.new(/^[0-9a-z_-]+$/)
|
227
|
+
return false if !@customer_user_id.nil? && @customer_user_id.to_s.length > 256
|
228
|
+
true
|
229
|
+
end
|
230
|
+
|
231
|
+
# Custom attribute writer method with validation
|
232
|
+
# @param [Object] task_def_id Value to be assigned
|
233
|
+
def task_def_id=(task_def_id)
|
234
|
+
if task_def_id.nil?
|
235
|
+
fail ArgumentError, 'task_def_id cannot be nil'
|
236
|
+
end
|
237
|
+
|
238
|
+
pattern = Regexp.new(/^[0-9a-z_-]+$/)
|
239
|
+
if task_def_id !~ pattern
|
240
|
+
fail ArgumentError, "invalid value for \"task_def_id\", must conform to the pattern #{pattern}."
|
241
|
+
end
|
242
|
+
|
243
|
+
@task_def_id = task_def_id
|
244
|
+
end
|
245
|
+
|
246
|
+
# Custom attribute writer method with validation
|
247
|
+
# @param [Object] customer_user_id Value to be assigned
|
248
|
+
def customer_user_id=(customer_user_id)
|
249
|
+
if customer_user_id.nil?
|
250
|
+
fail ArgumentError, 'customer_user_id cannot be nil'
|
251
|
+
end
|
252
|
+
|
253
|
+
if customer_user_id.to_s.length > 256
|
254
|
+
fail ArgumentError, 'invalid value for "customer_user_id", the character length must be smaller than or equal to 256.'
|
255
|
+
end
|
256
|
+
|
257
|
+
@customer_user_id = customer_user_id
|
258
|
+
end
|
259
|
+
|
260
|
+
# Checks equality by comparing each attribute.
|
261
|
+
# @param [Object] Object to be compared
|
262
|
+
def ==(o)
|
263
|
+
return true if self.equal?(o)
|
264
|
+
self.class == o.class &&
|
265
|
+
id == o.id &&
|
266
|
+
applicant_id == o.applicant_id &&
|
267
|
+
created_at == o.created_at &&
|
268
|
+
updated_at == o.updated_at &&
|
269
|
+
dashboard_url == o.dashboard_url &&
|
270
|
+
workflow_id == o.workflow_id &&
|
271
|
+
workflow_run_id == o.workflow_run_id &&
|
272
|
+
workflow_version_id == o.workflow_version_id &&
|
273
|
+
task_def_id == o.task_def_id &&
|
274
|
+
task_def_version == o.task_def_version &&
|
275
|
+
input == o.input &&
|
276
|
+
output == o.output &&
|
277
|
+
reasons == o.reasons &&
|
278
|
+
link == o.link &&
|
279
|
+
error == o.error &&
|
280
|
+
customer_user_id == o.customer_user_id
|
281
|
+
end
|
282
|
+
|
283
|
+
# @see the `==` method
|
284
|
+
# @param [Object] Object to be compared
|
285
|
+
def eql?(o)
|
286
|
+
self == o
|
287
|
+
end
|
288
|
+
|
289
|
+
# Calculates hash code according to all attributes.
|
290
|
+
# @return [Integer] Hash code
|
291
|
+
def hash
|
292
|
+
[id, applicant_id, created_at, updated_at, dashboard_url, workflow_id, workflow_run_id, workflow_version_id, task_def_id, task_def_version, input, output, reasons, link, error, customer_user_id].hash
|
293
|
+
end
|
294
|
+
|
295
|
+
# Builds the object from hash
|
296
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
297
|
+
# @return [Object] Returns the model itself
|
298
|
+
def self.build_from_hash(attributes)
|
299
|
+
return nil unless attributes.is_a?(Hash)
|
300
|
+
attributes = attributes.transform_keys(&:to_sym)
|
301
|
+
transformed_hash = {}
|
302
|
+
openapi_types.each_pair do |key, type|
|
303
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
304
|
+
transformed_hash["#{key}"] = nil
|
305
|
+
elsif type =~ /\AArray<(.*)>/i
|
306
|
+
# check to ensure the input is an array given that the attribute
|
307
|
+
# is documented as an array but the input is not
|
308
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
309
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
310
|
+
end
|
311
|
+
elsif !attributes[attribute_map[key]].nil?
|
312
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
313
|
+
end
|
314
|
+
end
|
315
|
+
new(transformed_hash)
|
316
|
+
end
|
317
|
+
|
318
|
+
# Deserializes the data based on type
|
319
|
+
# @param string type Data type
|
320
|
+
# @param string value Value to be deserialized
|
321
|
+
# @return [Object] Deserialized data
|
322
|
+
def self._deserialize(type, value)
|
323
|
+
case type.to_sym
|
324
|
+
when :Time
|
325
|
+
Time.parse(value)
|
326
|
+
when :Date
|
327
|
+
Date.parse(value)
|
328
|
+
when :String
|
329
|
+
value.to_s
|
330
|
+
when :Integer
|
331
|
+
value.to_i
|
332
|
+
when :Float
|
333
|
+
value.to_f
|
334
|
+
when :Boolean
|
335
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
336
|
+
true
|
337
|
+
else
|
338
|
+
false
|
339
|
+
end
|
340
|
+
when :Object
|
341
|
+
# generic object (usually a Hash), return directly
|
342
|
+
value
|
343
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
344
|
+
inner_type = Regexp.last_match[:inner_type]
|
345
|
+
value.map { |v| _deserialize(inner_type, v) }
|
346
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
347
|
+
k_type = Regexp.last_match[:k_type]
|
348
|
+
v_type = Regexp.last_match[:v_type]
|
349
|
+
{}.tap do |hash|
|
350
|
+
value.each do |k, v|
|
351
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
352
|
+
end
|
353
|
+
end
|
354
|
+
else # model
|
355
|
+
# models (e.g. Pet) or oneOf
|
356
|
+
klass = Onfido.const_get(type)
|
357
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
358
|
+
end
|
359
|
+
end
|
360
|
+
|
361
|
+
# Returns the string representation of the object
|
362
|
+
# @return [String] String presentation of the object
|
363
|
+
def to_s
|
364
|
+
to_hash.to_s
|
365
|
+
end
|
366
|
+
|
367
|
+
# to_body is an alias to to_hash (backward compatibility)
|
368
|
+
# @return [Hash] Returns the object in the form of hash
|
369
|
+
def to_body
|
370
|
+
to_hash
|
371
|
+
end
|
372
|
+
|
373
|
+
# Returns the object in the form of hash
|
374
|
+
# @return [Hash] Returns the object in the form of hash
|
375
|
+
def to_hash
|
376
|
+
hash = {}
|
377
|
+
self.class.attribute_map.each_pair do |attr, param|
|
378
|
+
value = self.send(attr)
|
379
|
+
if value.nil?
|
380
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
381
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
382
|
+
end
|
383
|
+
|
384
|
+
hash[param] = _to_hash(value)
|
385
|
+
end
|
386
|
+
hash
|
387
|
+
end
|
388
|
+
|
389
|
+
# Outputs non-array value in the form of hash
|
390
|
+
# For object, use to_hash. Otherwise, just return the value
|
391
|
+
# @param [Object] value Any valid value
|
392
|
+
# @return [Hash] Returns the value in the form of hash
|
393
|
+
def _to_hash(value)
|
394
|
+
if value.is_a?(Array)
|
395
|
+
value.compact.map { |v| _to_hash(v) }
|
396
|
+
elsif value.is_a?(Hash)
|
397
|
+
{}.tap do |hash|
|
398
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
399
|
+
end
|
400
|
+
elsif value.respond_to? :to_hash
|
401
|
+
value.to_hash
|
402
|
+
else
|
403
|
+
value
|
404
|
+
end
|
405
|
+
end
|
406
|
+
|
407
|
+
end
|
408
|
+
|
409
|
+
end
|
@@ -0,0 +1,47 @@
|
|
1
|
+
=begin
|
2
|
+
#Onfido API v3.6
|
3
|
+
|
4
|
+
#The Onfido API (v3.6)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v3.6
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module Onfido
|
17
|
+
class WebhookEventResourceType
|
18
|
+
CHECK = "check".freeze
|
19
|
+
REPORT = "report".freeze
|
20
|
+
AUDIT_LOG = "audit_log".freeze
|
21
|
+
WORKFLOW_RUN = "workflow_run".freeze
|
22
|
+
WORKFLOW_TASK = "workflow_task".freeze
|
23
|
+
WATCHLIST_MONITOR = "watchlist_monitor".freeze
|
24
|
+
WORKFLOW_TIMELINE_FILE = "workflow_timeline_file".freeze
|
25
|
+
WORKFLOW_RUN_EVIDENCE_FOLDER = "workflow_run_evidence_folder".freeze
|
26
|
+
UNKNOWN_DEFAULT_OPEN_API = "unknown_default_open_api".freeze
|
27
|
+
|
28
|
+
def self.all_vars
|
29
|
+
@all_vars ||= [CHECK, REPORT, AUDIT_LOG, WORKFLOW_RUN, WORKFLOW_TASK, WATCHLIST_MONITOR, WORKFLOW_TIMELINE_FILE, WORKFLOW_RUN_EVIDENCE_FOLDER, UNKNOWN_DEFAULT_OPEN_API].freeze
|
30
|
+
end
|
31
|
+
|
32
|
+
# Builds the enum from string
|
33
|
+
# @param [String] The enum value in the form of the string
|
34
|
+
# @return [String] The enum value
|
35
|
+
def self.build_from_hash(value)
|
36
|
+
new.build_from_hash(value)
|
37
|
+
end
|
38
|
+
|
39
|
+
# Builds the enum from string
|
40
|
+
# @param [String] The enum value in the form of the string
|
41
|
+
# @return [String] The enum value
|
42
|
+
def build_from_hash(value)
|
43
|
+
return value if WebhookEventResourceType.all_vars.include?(value)
|
44
|
+
raise "Invalid ENUM value #{value} for class #WebhookEventResourceType"
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: v3.6
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.9.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -32,10 +32,11 @@ module Onfido
|
|
32
32
|
REPORT_COMPLETED = "report.completed".freeze
|
33
33
|
WORKFLOW_TIMELINE_FILE_CREATED = "workflow_timeline_file.created".freeze
|
34
34
|
WORKFLOW_SIGNED_EVIDENCE_FILE_CREATED = "workflow_signed_evidence_file.created".freeze
|
35
|
+
WORKFLOW_RUN_EVIDENCE_FOLDER_CREATED = "workflow_run_evidence_folder.created".freeze
|
35
36
|
UNKNOWN_DEFAULT_OPEN_API = "unknown_default_open_api".freeze
|
36
37
|
|
37
38
|
def self.all_vars
|
38
|
-
@all_vars ||= [AUDIT_LOG_CREATED, WATCHLIST_MONITOR_MATCHES_UPDATED, WORKFLOW_RUN_COMPLETED, WORKFLOW_TASK_STARTED, WORKFLOW_TASK_COMPLETED, CHECK_STARTED, CHECK_REOPENED, CHECK_WITHDRAWN, CHECK_COMPLETED, CHECK_FORM_COMPLETED, REPORT_WITHDRAWN, REPORT_RESUMED, REPORT_CANCELLED, REPORT_AWAITING_APPROVAL, REPORT_COMPLETED, WORKFLOW_TIMELINE_FILE_CREATED, WORKFLOW_SIGNED_EVIDENCE_FILE_CREATED, UNKNOWN_DEFAULT_OPEN_API].freeze
|
39
|
+
@all_vars ||= [AUDIT_LOG_CREATED, WATCHLIST_MONITOR_MATCHES_UPDATED, WORKFLOW_RUN_COMPLETED, WORKFLOW_TASK_STARTED, WORKFLOW_TASK_COMPLETED, CHECK_STARTED, CHECK_REOPENED, CHECK_WITHDRAWN, CHECK_COMPLETED, CHECK_FORM_COMPLETED, REPORT_WITHDRAWN, REPORT_RESUMED, REPORT_CANCELLED, REPORT_AWAITING_APPROVAL, REPORT_COMPLETED, WORKFLOW_TIMELINE_FILE_CREATED, WORKFLOW_SIGNED_EVIDENCE_FILE_CREATED, WORKFLOW_RUN_EVIDENCE_FOLDER_CREATED, UNKNOWN_DEFAULT_OPEN_API].freeze
|
39
40
|
end
|
40
41
|
|
41
42
|
# Builds the enum from string
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: v3.6
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.9.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,6 +27,7 @@ module Onfido
|
|
27
27
|
# Customer-provided user identifier.
|
28
28
|
attr_accessor :customer_user_id
|
29
29
|
|
30
|
+
# Object for the configuration of the Workflow Run link.
|
30
31
|
attr_accessor :link
|
31
32
|
|
32
33
|
# The date and time when the Workflow Run was created.
|
@@ -53,6 +54,7 @@ module Onfido
|
|
53
54
|
# The reasons the Workflow Run outcome was reached. Configurable when creating the Workflow version.
|
54
55
|
attr_accessor :reasons
|
55
56
|
|
57
|
+
# Error object. Only set when the Workflow Run status is 'error'.
|
56
58
|
attr_accessor :error
|
57
59
|
|
58
60
|
# Client token to use when loading this workflow run in the Onfido SDK.
|
@@ -113,16 +115,16 @@ module Onfido
|
|
113
115
|
:'workflow_id' => :'String',
|
114
116
|
:'tags' => :'Array<String>',
|
115
117
|
:'customer_user_id' => :'String',
|
116
|
-
:'link' => :'
|
118
|
+
:'link' => :'WorkflowRunLink',
|
117
119
|
:'created_at' => :'Time',
|
118
120
|
:'updated_at' => :'Time',
|
119
121
|
:'id' => :'String',
|
120
122
|
:'workflow_version_id' => :'Integer',
|
121
123
|
:'dashboard_url' => :'String',
|
122
|
-
:'status' => :'
|
124
|
+
:'status' => :'WorkflowRunStatus',
|
123
125
|
:'output' => :'Object',
|
124
126
|
:'reasons' => :'Array<String>',
|
125
|
-
:'error' => :'
|
127
|
+
:'error' => :'WorkflowRunError',
|
126
128
|
:'sdk_token' => :'String'
|
127
129
|
}
|
128
130
|
end
|
@@ -266,8 +268,6 @@ module Onfido
|
|
266
268
|
return false if !@tags.nil? && @tags.length > 30
|
267
269
|
return false if !@customer_user_id.nil? && @customer_user_id.to_s.length > 256
|
268
270
|
return false if @id.nil?
|
269
|
-
status_validator = EnumAttributeValidator.new('String', ["awaiting_input", "processing", "abandoned", "error", "approved", "review", "declined", "unknown_default_open_api"])
|
270
|
-
return false unless status_validator.valid?(@status)
|
271
271
|
true
|
272
272
|
end
|
273
273
|
|
@@ -295,16 +295,6 @@ module Onfido
|
|
295
295
|
@customer_user_id = customer_user_id
|
296
296
|
end
|
297
297
|
|
298
|
-
# Custom attribute writer method checking allowed values (enum).
|
299
|
-
# @param [Object] status Object to be assigned
|
300
|
-
def status=(status)
|
301
|
-
validator = EnumAttributeValidator.new('String', ["awaiting_input", "processing", "abandoned", "error", "approved", "review", "declined", "unknown_default_open_api"])
|
302
|
-
unless validator.valid?(status)
|
303
|
-
fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
|
304
|
-
end
|
305
|
-
@status = status
|
306
|
-
end
|
307
|
-
|
308
298
|
# Checks equality by comparing each attribute.
|
309
299
|
# @param [Object] Object to be compared
|
310
300
|
def ==(o)
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: v3.6
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.9.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,6 +27,7 @@ module Onfido
|
|
27
27
|
# Customer-provided user identifier.
|
28
28
|
attr_accessor :customer_user_id
|
29
29
|
|
30
|
+
# Object for the configuration of the Workflow Run link.
|
30
31
|
attr_accessor :link
|
31
32
|
|
32
33
|
# The date and time when the Workflow Run was created.
|
@@ -64,7 +65,7 @@ module Onfido
|
|
64
65
|
:'workflow_id' => :'String',
|
65
66
|
:'tags' => :'Array<String>',
|
66
67
|
:'customer_user_id' => :'String',
|
67
|
-
:'link' => :'
|
68
|
+
:'link' => :'WorkflowRunLink',
|
68
69
|
:'created_at' => :'Time',
|
69
70
|
:'updated_at' => :'Time',
|
70
71
|
:'custom_data' => :'Hash<String, Object>'
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: v3.6
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.9.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -14,8 +14,7 @@ require 'date'
|
|
14
14
|
require 'time'
|
15
15
|
|
16
16
|
module Onfido
|
17
|
-
|
18
|
-
class WorkflowRunResponseError
|
17
|
+
class WorkflowRunError
|
19
18
|
# The type of error.
|
20
19
|
attr_accessor :type
|
21
20
|
|
@@ -53,13 +52,13 @@ module Onfido
|
|
53
52
|
# @param [Hash] attributes Model attributes in the form of hash
|
54
53
|
def initialize(attributes = {})
|
55
54
|
if (!attributes.is_a?(Hash))
|
56
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `Onfido::
|
55
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Onfido::WorkflowRunError` initialize method"
|
57
56
|
end
|
58
57
|
|
59
58
|
# check to see if the attribute exists and convert string to symbol for hash key
|
60
59
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
61
60
|
if (!self.class.attribute_map.key?(k.to_sym))
|
62
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `Onfido::
|
61
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Onfido::WorkflowRunError`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
63
62
|
end
|
64
63
|
h[k.to_sym] = v
|
65
64
|
}
|