From 421ad531dca9576c08da4b8c8953854888b108ef Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Fri, 18 Nov 2022 15:17:44 -0300 Subject: [PATCH 1/7] feat: Brazilian standard require idNumber, back document and email for kyc validation --- fiatconnect-api.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index 356d6a3..64fe31b 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2226,12 +2226,15 @@ A KYC schema containing personal data about a user, as well as documents such as postalCode?: `string` }, phoneNumber: `string`, + idNumber?: `string`, + email?: `string`, selfieDocument: `string`, - identificationDocument: `string` + identificationDocument: `string`, + identificationDocumentBack?: `string` } ``` -The `selfieDocument` and `identificationDocument` fields should be base64 encoded binary blobs representing images. +The `selfieDocument`, `identificationDocument` and `identificationDocumentBack` fields should be base64 encoded binary blobs representing images. ### 9.3.2. Fiat Account Schemas From e834177673cb3244f6e1df55710a79dfdeed3bbe Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Mon, 21 Nov 2022 17:07:16 -0300 Subject: [PATCH 2/7] fix: indentation --- fiatconnect-api.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index 64fe31b..56df450 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2226,11 +2226,11 @@ A KYC schema containing personal data about a user, as well as documents such as postalCode?: `string` }, phoneNumber: `string`, - idNumber?: `string`, - email?: `string`, + idNumber?: `string`, + email?: `string`, selfieDocument: `string`, identificationDocument: `string`, - identificationDocumentBack?: `string` + identificationDocumentBack?: `string`, } ``` From 0ff71de59ebabb603b6fac1ecbbc95d9b109353c Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Fri, 25 Nov 2022 07:36:51 -0300 Subject: [PATCH 3/7] feat(kyc): new kyc schema with back doc --- fiatconnect-api.md | 39 ++++++++++++++++++++++++++++++++++----- swagger.yaml | 1 + 2 files changed, 35 insertions(+), 5 deletions(-) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index 56df450..42bd695 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2148,7 +2148,8 @@ An enum listing the KYC schema types recognized by the FiatConnect specification ``` [ - `PersonalDataAndDocuments` + `PersonalDataAndDocuments`, + `PersonalDataAndDocumentsWithBack` ] ``` @@ -2226,11 +2227,39 @@ A KYC schema containing personal data about a user, as well as documents such as postalCode?: `string` }, phoneNumber: `string`, - idNumber?: `string`, - email?: `string`, selfieDocument: `string`, - identificationDocument: `string`, - identificationDocumentBack?: `string`, + identificationDocument: `string` +} +``` + +The `selfieDocument` and `identificationDocument` fields should be base64 encoded binary blobs representing images. + +#### 9.3.1.2. `PersonalDataAndDocumentsWithBack` + +A brasilian standard KYC schema containing personal data about a user, as well as documents such as an ID photo and selfie. + +``` +{ + fullName: `string`, + dateOfBirth: { + day: `string`, + month: `string`, + year: `string` + }, + address: { + address1: `string`, + address2?: `string`, + isoCountryCode: `string`, + isoRegionCode: `string`, + city: `string`, + postalCode?: `string` + }, + phoneNumber: `string`, + idNumber: `string`, + email: `string`, + selfieDocument: `string`, + identificationDocumentFront: `string`, + identificationDocumentBack: `string`, } ``` diff --git a/swagger.yaml b/swagger.yaml index 7e7c74b..8c5f4d8 100644 --- a/swagger.yaml +++ b/swagger.yaml @@ -36,6 +36,7 @@ definitions: - NameAndAddress - IdAndSelfie - PersonalDataAndDocuments + - PersonalDataAndDocumentsWithBack FiatType: type: "string" enum: &FiatType From 48d216c893ff6c7e682ec4d3429987ef6f9f8e74 Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Fri, 25 Nov 2022 07:41:08 -0300 Subject: [PATCH 4/7] fix: indentation --- fiatconnect-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index 42bd695..7b8ac49 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2149,7 +2149,7 @@ An enum listing the KYC schema types recognized by the FiatConnect specification ``` [ `PersonalDataAndDocuments`, - `PersonalDataAndDocumentsWithBack` + `PersonalDataAndDocumentsWithBack` ] ``` From e2c9d58093b2d3503d2b055defb2e18c1ea9a596 Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Tue, 29 Nov 2022 13:42:10 -0300 Subject: [PATCH 5/7] fix: add more info about fields --- fiatconnect-api.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index 7b8ac49..ad629fb 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2263,6 +2263,9 @@ A brasilian standard KYC schema containing personal data about a user, as well a } ``` +`idNumber` MUST be a [CPF number](https://en.wikipedia.org/wiki/CPF_number). +`email` MUST be a [valid email](https://en.wikipedia.org/wiki/Email_address#Syntax). +`phoneNumber` MUST be an 11-digit [Brazilian mobile phone number](https://en.wikipedia.org/wiki/Telephone_numbers_in_Brazil) including area code. The string MUST match the regex `/[0-9]{11}/`. The `selfieDocument`, `identificationDocument` and `identificationDocumentBack` fields should be base64 encoded binary blobs representing images. ### 9.3.2. Fiat Account Schemas From b29d8303502bc1fe8a602109f545bd2401c13c64 Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Wed, 4 Jan 2023 11:51:14 -0300 Subject: [PATCH 6/7] feat(kyc): add accepted docs --- fiatconnect-api.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index ad629fb..32ab4be 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2236,7 +2236,8 @@ The `selfieDocument` and `identificationDocument` fields should be base64 encode #### 9.3.1.2. `PersonalDataAndDocumentsWithBack` -A brasilian standard KYC schema containing personal data about a user, as well as documents such as an ID photo and selfie. +A brasilian standard KYC schema containing personal data about a user, as well as documents such as an ID, photo and selfie. +The accepted documents are [RG](https://en.wikipedia.org/wiki/Brazilian_identity_card), [CNH](https://en.wikipedia.org/wiki/Driving_licence_in_Brazil) and [RNM](https://en.wikipedia.org/wiki/Registro_Nacional_de_Estrangeiros) ``` { From 795dc7870e3745e8d65662aac52ab85984e15aa5 Mon Sep 17 00:00:00 2001 From: Ailson da Cruz Date: Fri, 6 Jan 2023 11:59:46 -0300 Subject: [PATCH 7/7] feat(kyc): remove idNumber --- fiatconnect-api.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/fiatconnect-api.md b/fiatconnect-api.md index 32ab4be..972768c 100644 --- a/fiatconnect-api.md +++ b/fiatconnect-api.md @@ -2236,7 +2236,7 @@ The `selfieDocument` and `identificationDocument` fields should be base64 encode #### 9.3.1.2. `PersonalDataAndDocumentsWithBack` -A brasilian standard KYC schema containing personal data about a user, as well as documents such as an ID, photo and selfie. +A KYC schema containing personal data about a user, as well as documents such as an ID, photo and selfie. The accepted documents are [RG](https://en.wikipedia.org/wiki/Brazilian_identity_card), [CNH](https://en.wikipedia.org/wiki/Driving_licence_in_Brazil) and [RNM](https://en.wikipedia.org/wiki/Registro_Nacional_de_Estrangeiros) ``` @@ -2256,7 +2256,6 @@ The accepted documents are [RG](https://en.wikipedia.org/wiki/Brazilian_identity postalCode?: `string` }, phoneNumber: `string`, - idNumber: `string`, email: `string`, selfieDocument: `string`, identificationDocumentFront: `string`, @@ -2264,7 +2263,6 @@ The accepted documents are [RG](https://en.wikipedia.org/wiki/Brazilian_identity } ``` -`idNumber` MUST be a [CPF number](https://en.wikipedia.org/wiki/CPF_number). `email` MUST be a [valid email](https://en.wikipedia.org/wiki/Email_address#Syntax). `phoneNumber` MUST be an 11-digit [Brazilian mobile phone number](https://en.wikipedia.org/wiki/Telephone_numbers_in_Brazil) including area code. The string MUST match the regex `/[0-9]{11}/`. The `selfieDocument`, `identificationDocument` and `identificationDocumentBack` fields should be base64 encoded binary blobs representing images.