Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refresh onfido-ruby after onfido-openapi-spec update (c72181c) #69

Merged
merged 1 commit into from
Nov 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .release.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"source": {
"repo_url": "https://github.com/onfido/onfido-openapi-spec",
"short_sha": "d180edd",
"long_sha": "d180eddd168dd95bf84bf7c8fe9f8c7e3c0c5494",
"version": "v4.1.0"
"short_sha": "c72181c",
"long_sha": "c72181cc5e450bf727fc5eae2639c58ba45831ac",
"version": "v4.2.0"
},
"release": "v4.1.0"
"release": "v4.2.0"
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This version uses Onfido API v3.6. Refer to our [API versioning guide](https://d
### Installation

```ruby
gem onfido, '~> 4.1.0'
gem onfido, '~> 4.2.0'
```

Configure with your API token, region and optional timeout (default value is 30):
Expand Down
2 changes: 2 additions & 0 deletions lib/onfido.rb
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,8 @@
require 'onfido/models/facial_similarity_photo_fully_auto_report'
require 'onfido/models/facial_similarity_photo_properties'
require 'onfido/models/facial_similarity_photo_report'
require 'onfido/models/facial_similarity_report_media'
require 'onfido/models/facial_similarity_report_shared'
require 'onfido/models/facial_similarity_video_breakdown'
require 'onfido/models/facial_similarity_video_breakdown_face_comparison'
require 'onfido/models/facial_similarity_video_breakdown_image_integrity'
Expand Down
2 changes: 1 addition & 1 deletion lib/onfido/api_client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class ApiClient
# @option config [Configuration] Configuration for initializing the object, default to Configuration.default
def initialize(config = Configuration.default)
@config = config
@user_agent = "onfido-ruby/4.1.0"
@user_agent = "onfido-ruby/4.2.0"
@default_headers = {
'Content-Type' => 'application/json',
'User-Agent' => @user_agent
Expand Down
48 changes: 47 additions & 1 deletion lib/onfido/models/document_types.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,56 @@ class DocumentTypes
VEHICLE_REGISTRATION_CERTIFICATE = "vehicle_registration_certificate".freeze
FORM_FOR_AFFIXING_THE_VISA = "form_for_affixing_the_visa".freeze
IDENTIFICATION_NUMBER_DOCUMENT = "identification_number_document".freeze
ADOPTION_CERTIFICATE = "adoption_certificate".freeze
BANK_BUILDING_SOCIETY_STATEMENT = "bank_building_society_statement".freeze
BANK_STATEMENT = "bank_statement".freeze
BENEFIT_LETTERS = "benefit_letters".freeze
CBT = "cbt".freeze
CERTIFICATE_OF_SPONSORSHIP = "certificate_of_sponsorship".freeze
CHARACTER_REFERENCE = "character_reference".freeze
CIVIL_PARTNERSHIP_CERTIFICATE = "civil_partnership_certificate".freeze
COUNCIL_TAX = "council_tax".freeze
CREDIT_CARD_STATEMENT = "credit_card_statement".freeze
DEED_POLL = "deed_poll".freeze
DIVORCE_ABSOLUTE_DECREE = "divorce_absolute_decree".freeze
EDUCATIONAL_STATEMENT = "educational_statement".freeze
ELECTRICITY_BILL = "electricity_bill".freeze
GAS_BILL = "gas_bill".freeze
GOVERNMENT_LETTER = "government_letter".freeze
INTERNET_BILL = "internet_bill".freeze
MARRIAGE_CERTIFICATE = "marriage_certificate".freeze
MOTORCYCLE_INSURANCE = "motorcycle_insurance".freeze
NATIONAL_INSURANCE_CARD = "national_insurance_card".freeze
NATURALISATION_CERTIFICATE = "naturalisation_certificate".freeze
NON_UK_DRIVING_LICENCE = "non_uk_driving_licence".freeze
P45_P60 = "p45_p60".freeze
PAYSLIP = "payslip".freeze
PHONE_BILL = "phone_bill".freeze
PROFESSIONAL_IDENTIFICATION_CARD = "professional_identification_card".freeze
RIGHT_TO_WORK_SHARE_CODE_RESULT = "right_to_work_share_code_result".freeze
STATEMENT_FACT = "statement_fact".freeze
T4_STUDENT_UNIVERSITY_TERM_DATES_EVIDENCE = "t4_student_university_term_dates_evidence".freeze
UK_BIOMETRIC_RESIDENCE_PERMIT = "uk_biometric_residence_permit".freeze
UK_DRIVING_LICENCE = "uk_driving_licence".freeze
UNKNOWN = "unknown".freeze
UTILITY_BILL = "utility_bill".freeze
UTILITY_BILL_ELECTRIC = "utility_bill_electric".freeze
UTILITY_BILL_GAS = "utility_bill_gas".freeze
UTILITY_BILL_OTHER = "utility_bill_other".freeze
WATER_BILL = "water_bill".freeze
ADDRESS_CERTIFICATE = "address_certificate".freeze
GENERAL_LETTER = "general_letter".freeze
INSURANCE_STATEMENT = "insurance_statement".freeze
PENSION_PROPERTY_STATEMENT_LETTER = "pension_property_statement_letter".freeze
MORTGAGE_STATEMENT = "mortgage_statement".freeze
MOBILE_PHONE_BILL = "mobile_phone_bill".freeze
IDENTITY_DOCUMENT_WITH_ADDRESS = "identity_document_with_address".freeze
EXCHANGE_HOUSE_STATEMENT = "exchange_house_statement".freeze
ACCOMMODATION_TENANCY_CERTIFICATE = "accommodation_tenancy_certificate".freeze
UNKNOWN_DEFAULT_OPEN_API = "unknown_default_open_api".freeze

def self.all_vars
@all_vars ||= [PASSPORT, DRIVING_LICENCE, NATIONAL_IDENTITY_CARD, RESIDENCE_PERMIT, PASSPORT_CARD, TAX_ID, VISA, VOTER_ID, RESIDENCE_STATUS_DOCUMENT, POSTAL_IDENTITY_CARD, SOCIAL_SECURITY_CARD, WORK_PERMIT, ASYLUM_REGISTRATION_CARD, NATIONAL_HEALTH_INSURANCE_CARD, MUNICIPALITY_IDENTITY_CARD, PRIVATE_OPERATORS_CARD, PROOF_OF_CITIZENSHIP, SERVICE_ID_CARD, IMMIGRATION_STATUS_DOCUMENT, INDIGENOUS_CARD, VEHICLE_REGISTRATION_CARD, CERTIFICATE_OF_NATURALISATION, PROFESSIONAL_QUALIFICATION_CARD, CONSULAR_ID, INTERNATIONAL_DRIVING_LICENCE, HOME_OFFICE_LETTER, BIRTH_CERTIFICATE, VEHICLE_REGISTRATION_CERTIFICATE, FORM_FOR_AFFIXING_THE_VISA, IDENTIFICATION_NUMBER_DOCUMENT, UNKNOWN_DEFAULT_OPEN_API].freeze
@all_vars ||= [PASSPORT, DRIVING_LICENCE, NATIONAL_IDENTITY_CARD, RESIDENCE_PERMIT, PASSPORT_CARD, TAX_ID, VISA, VOTER_ID, RESIDENCE_STATUS_DOCUMENT, POSTAL_IDENTITY_CARD, SOCIAL_SECURITY_CARD, WORK_PERMIT, ASYLUM_REGISTRATION_CARD, NATIONAL_HEALTH_INSURANCE_CARD, MUNICIPALITY_IDENTITY_CARD, PRIVATE_OPERATORS_CARD, PROOF_OF_CITIZENSHIP, SERVICE_ID_CARD, IMMIGRATION_STATUS_DOCUMENT, INDIGENOUS_CARD, VEHICLE_REGISTRATION_CARD, CERTIFICATE_OF_NATURALISATION, PROFESSIONAL_QUALIFICATION_CARD, CONSULAR_ID, INTERNATIONAL_DRIVING_LICENCE, HOME_OFFICE_LETTER, BIRTH_CERTIFICATE, VEHICLE_REGISTRATION_CERTIFICATE, FORM_FOR_AFFIXING_THE_VISA, IDENTIFICATION_NUMBER_DOCUMENT, ADOPTION_CERTIFICATE, BANK_BUILDING_SOCIETY_STATEMENT, BANK_STATEMENT, BENEFIT_LETTERS, CBT, CERTIFICATE_OF_SPONSORSHIP, CHARACTER_REFERENCE, CIVIL_PARTNERSHIP_CERTIFICATE, COUNCIL_TAX, CREDIT_CARD_STATEMENT, DEED_POLL, DIVORCE_ABSOLUTE_DECREE, EDUCATIONAL_STATEMENT, ELECTRICITY_BILL, GAS_BILL, GOVERNMENT_LETTER, INTERNET_BILL, MARRIAGE_CERTIFICATE, MOTORCYCLE_INSURANCE, NATIONAL_INSURANCE_CARD, NATURALISATION_CERTIFICATE, NON_UK_DRIVING_LICENCE, P45_P60, PAYSLIP, PHONE_BILL, PROFESSIONAL_IDENTIFICATION_CARD, RIGHT_TO_WORK_SHARE_CODE_RESULT, STATEMENT_FACT, T4_STUDENT_UNIVERSITY_TERM_DATES_EVIDENCE, UK_BIOMETRIC_RESIDENCE_PERMIT, UK_DRIVING_LICENCE, UNKNOWN, UTILITY_BILL, UTILITY_BILL_ELECTRIC, UTILITY_BILL_GAS, UTILITY_BILL_OTHER, WATER_BILL, ADDRESS_CERTIFICATE, GENERAL_LETTER, INSURANCE_STATEMENT, PENSION_PROPERTY_STATEMENT_LETTER, MORTGAGE_STATEMENT, MOBILE_PHONE_BILL, IDENTITY_DOCUMENT_WITH_ADDRESS, EXCHANGE_HOUSE_STATEMENT, ACCOMMODATION_TENANCY_CERTIFICATE, UNKNOWN_DEFAULT_OPEN_API].freeze
end

# Builds the enum from string
Expand Down
51 changes: 50 additions & 1 deletion lib/onfido/models/facial_similarity_motion_report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,18 @@ class FacialSimilarityMotionReport

attr_accessor :name

# Array of objects with live photo ids that were used in the Onfido engine.
attr_accessor :live_photos

# Array of objects with live video ids that were used in the Onfido engine.
attr_accessor :live_videos

# Array of objects with motion capture ids that were used in the Onfido engine.
attr_accessor :motion_captures

# Array of objects with id photo ids that were used in the Onfido engine.
attr_accessor :id_photos

attr_accessor :breakdown

attr_accessor :properties
Expand Down Expand Up @@ -76,6 +88,10 @@ def self.attribute_map
:'check_id' => :'check_id',
:'documents' => :'documents',
:'name' => :'name',
:'live_photos' => :'live_photos',
:'live_videos' => :'live_videos',
:'motion_captures' => :'motion_captures',
:'id_photos' => :'id_photos',
:'breakdown' => :'breakdown',
:'properties' => :'properties'
}
Expand All @@ -98,6 +114,10 @@ def self.openapi_types
:'check_id' => :'String',
:'documents' => :'Array<ReportDocument>',
:'name' => :'ReportName',
:'live_photos' => :'Array<FacialSimilarityReportMedia>',
:'live_videos' => :'Array<FacialSimilarityReportMedia>',
:'motion_captures' => :'Array<FacialSimilarityReportMedia>',
:'id_photos' => :'Array<FacialSimilarityReportMedia>',
:'breakdown' => :'FacialSimilarityMotionBreakdown',
:'properties' => :'FacialSimilarityMotionProperties'
}
Expand All @@ -112,6 +132,7 @@ def self.openapi_nullable
# List of class defined in allOf (OpenAPI v3)
def self.openapi_all_of
[
:'FacialSimilarityReportShared',
:'ReportShared'
]
end
Expand Down Expand Up @@ -173,6 +194,30 @@ def initialize(attributes = {})
self.name = nil
end

if attributes.key?(:'live_photos')
if (value = attributes[:'live_photos']).is_a?(Array)
self.live_photos = value
end
end

if attributes.key?(:'live_videos')
if (value = attributes[:'live_videos']).is_a?(Array)
self.live_videos = value
end
end

if attributes.key?(:'motion_captures')
if (value = attributes[:'motion_captures']).is_a?(Array)
self.motion_captures = value
end
end

if attributes.key?(:'id_photos')
if (value = attributes[:'id_photos']).is_a?(Array)
self.id_photos = value
end
end

if attributes.key?(:'breakdown')
self.breakdown = attributes[:'breakdown']
end
Expand Down Expand Up @@ -221,6 +266,10 @@ def ==(o)
check_id == o.check_id &&
documents == o.documents &&
name == o.name &&
live_photos == o.live_photos &&
live_videos == o.live_videos &&
motion_captures == o.motion_captures &&
id_photos == o.id_photos &&
breakdown == o.breakdown &&
properties == o.properties
end
Expand All @@ -234,7 +283,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[id, created_at, href, status, result, sub_result, check_id, documents, name, breakdown, properties].hash
[id, created_at, href, status, result, sub_result, check_id, documents, name, live_photos, live_videos, motion_captures, id_photos, breakdown, properties].hash
end

# Builds the object from hash
Expand Down
51 changes: 50 additions & 1 deletion lib/onfido/models/facial_similarity_photo_fully_auto_report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,18 @@ class FacialSimilarityPhotoFullyAutoReport

attr_accessor :name

# Array of objects with live photo ids that were used in the Onfido engine.
attr_accessor :live_photos

# Array of objects with live video ids that were used in the Onfido engine.
attr_accessor :live_videos

# Array of objects with motion capture ids that were used in the Onfido engine.
attr_accessor :motion_captures

# Array of objects with id photo ids that were used in the Onfido engine.
attr_accessor :id_photos

attr_accessor :breakdown

attr_accessor :properties
Expand Down Expand Up @@ -76,6 +88,10 @@ def self.attribute_map
:'check_id' => :'check_id',
:'documents' => :'documents',
:'name' => :'name',
:'live_photos' => :'live_photos',
:'live_videos' => :'live_videos',
:'motion_captures' => :'motion_captures',
:'id_photos' => :'id_photos',
:'breakdown' => :'breakdown',
:'properties' => :'properties'
}
Expand All @@ -98,6 +114,10 @@ def self.openapi_types
:'check_id' => :'String',
:'documents' => :'Array<ReportDocument>',
:'name' => :'ReportName',
:'live_photos' => :'Array<FacialSimilarityReportMedia>',
:'live_videos' => :'Array<FacialSimilarityReportMedia>',
:'motion_captures' => :'Array<FacialSimilarityReportMedia>',
:'id_photos' => :'Array<FacialSimilarityReportMedia>',
:'breakdown' => :'FacialSimilarityPhotoFullyAutoBreakdown',
:'properties' => :'FacialSimilarityPhotoFullyAutoProperties'
}
Expand All @@ -112,6 +132,7 @@ def self.openapi_nullable
# List of class defined in allOf (OpenAPI v3)
def self.openapi_all_of
[
:'FacialSimilarityReportShared',
:'ReportShared'
]
end
Expand Down Expand Up @@ -173,6 +194,30 @@ def initialize(attributes = {})
self.name = nil
end

if attributes.key?(:'live_photos')
if (value = attributes[:'live_photos']).is_a?(Array)
self.live_photos = value
end
end

if attributes.key?(:'live_videos')
if (value = attributes[:'live_videos']).is_a?(Array)
self.live_videos = value
end
end

if attributes.key?(:'motion_captures')
if (value = attributes[:'motion_captures']).is_a?(Array)
self.motion_captures = value
end
end

if attributes.key?(:'id_photos')
if (value = attributes[:'id_photos']).is_a?(Array)
self.id_photos = value
end
end

if attributes.key?(:'breakdown')
self.breakdown = attributes[:'breakdown']
end
Expand Down Expand Up @@ -221,6 +266,10 @@ def ==(o)
check_id == o.check_id &&
documents == o.documents &&
name == o.name &&
live_photos == o.live_photos &&
live_videos == o.live_videos &&
motion_captures == o.motion_captures &&
id_photos == o.id_photos &&
breakdown == o.breakdown &&
properties == o.properties
end
Expand All @@ -234,7 +283,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[id, created_at, href, status, result, sub_result, check_id, documents, name, breakdown, properties].hash
[id, created_at, href, status, result, sub_result, check_id, documents, name, live_photos, live_videos, motion_captures, id_photos, breakdown, properties].hash
end

# Builds the object from hash
Expand Down
51 changes: 50 additions & 1 deletion lib/onfido/models/facial_similarity_photo_report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,18 @@ class FacialSimilarityPhotoReport

attr_accessor :name

# Array of objects with live photo ids that were used in the Onfido engine.
attr_accessor :live_photos

# Array of objects with live video ids that were used in the Onfido engine.
attr_accessor :live_videos

# Array of objects with motion capture ids that were used in the Onfido engine.
attr_accessor :motion_captures

# Array of objects with id photo ids that were used in the Onfido engine.
attr_accessor :id_photos

attr_accessor :breakdown

attr_accessor :properties
Expand Down Expand Up @@ -76,6 +88,10 @@ def self.attribute_map
:'check_id' => :'check_id',
:'documents' => :'documents',
:'name' => :'name',
:'live_photos' => :'live_photos',
:'live_videos' => :'live_videos',
:'motion_captures' => :'motion_captures',
:'id_photos' => :'id_photos',
:'breakdown' => :'breakdown',
:'properties' => :'properties'
}
Expand All @@ -98,6 +114,10 @@ def self.openapi_types
:'check_id' => :'String',
:'documents' => :'Array<ReportDocument>',
:'name' => :'ReportName',
:'live_photos' => :'Array<FacialSimilarityReportMedia>',
:'live_videos' => :'Array<FacialSimilarityReportMedia>',
:'motion_captures' => :'Array<FacialSimilarityReportMedia>',
:'id_photos' => :'Array<FacialSimilarityReportMedia>',
:'breakdown' => :'FacialSimilarityPhotoBreakdown',
:'properties' => :'FacialSimilarityPhotoProperties'
}
Expand All @@ -112,6 +132,7 @@ def self.openapi_nullable
# List of class defined in allOf (OpenAPI v3)
def self.openapi_all_of
[
:'FacialSimilarityReportShared',
:'ReportShared'
]
end
Expand Down Expand Up @@ -173,6 +194,30 @@ def initialize(attributes = {})
self.name = nil
end

if attributes.key?(:'live_photos')
if (value = attributes[:'live_photos']).is_a?(Array)
self.live_photos = value
end
end

if attributes.key?(:'live_videos')
if (value = attributes[:'live_videos']).is_a?(Array)
self.live_videos = value
end
end

if attributes.key?(:'motion_captures')
if (value = attributes[:'motion_captures']).is_a?(Array)
self.motion_captures = value
end
end

if attributes.key?(:'id_photos')
if (value = attributes[:'id_photos']).is_a?(Array)
self.id_photos = value
end
end

if attributes.key?(:'breakdown')
self.breakdown = attributes[:'breakdown']
end
Expand Down Expand Up @@ -221,6 +266,10 @@ def ==(o)
check_id == o.check_id &&
documents == o.documents &&
name == o.name &&
live_photos == o.live_photos &&
live_videos == o.live_videos &&
motion_captures == o.motion_captures &&
id_photos == o.id_photos &&
breakdown == o.breakdown &&
properties == o.properties
end
Expand All @@ -234,7 +283,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[id, created_at, href, status, result, sub_result, check_id, documents, name, breakdown, properties].hash
[id, created_at, href, status, result, sub_result, check_id, documents, name, live_photos, live_videos, motion_captures, id_photos, breakdown, properties].hash
end

# Builds the object from hash
Expand Down
Loading