Skip to content

Add support for already KYB'd businesses#570

Merged
ebma merged 12 commits into
stagingfrom
kyc-round-2
Apr 17, 2025
Merged

Add support for already KYB'd businesses#570
ebma merged 12 commits into
stagingfrom
kyc-round-2

Conversation

@gianfra-t
Copy link
Copy Markdown
Contributor

No description provided.

@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 16, 2025

Deploy Preview for pendulum-pay ready!

Name Link
🔨 Latest commit 363548b
🔍 Latest deploy log https://app.netlify.com/sites/pendulum-pay/deploys/6801380eb4a8610008299d4c
😎 Deploy Preview https://deploy-preview-570--pendulum-pay.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

// Response can also fail due to invalid KYC. Nevertheless, this should never be the case, as when we create the user we wait for the KYC
// to be valid, or retry.
if (response.status === 404) {
if (response.status === 404 && !isValidCnpj(taxId) && isValidCpf(taxId)) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be enough to only check for a valid CPF. The same input cannot be a valid CPF and CNPJ.

Suggested change
if (response.status === 404 && !isValidCnpj(taxId) && isValidCpf(taxId)) {
if (response.status === 404 && isValidCpf(taxId)) {

Comment thread api/src/constants/constants.ts Outdated
const PENDULUM_EPHEMERAL_STARTING_BALANCE_UNITS = '0.1'; // Amount to send to the new pendulum ephemeral account created
const MOONBEAM_EPHEMERAL_STARTING_BALANCE_UNITS = '3'; // Amount to send to the new moonbeam ephemeral account created
const BRLA_BASE_URL = 'https://api.brla.digital:5567/v1/business';
const BRLA_BASE_URL = 'https://api.brla.digital:4567/v1/business';
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
const BRLA_BASE_URL = 'https://api.brla.digital:4567/v1/business';
const BRLA_BASE_URL = 'https://api.brla.digital:5567/v1/business';

ebma added 8 commits April 17, 2025 13:39
Refactored `RampFormValues` schema logic, moving it to a dedicated `ramp` hook and improving its modularity and reusability. Updated translations for CPF/CNPJ validation messages to support both identifiers consistently. Adjusted imports across components to reflect schema relocation.
Updated the ramp form schema and submission logic to incorporate `RampDirection`. Enhanced validation conditions for PIX ID based on ramp direction. Adjusted BRLA user fetching logic to use a dedicated service and improved error handling.
@ebma ebma marked this pull request as ready for review April 17, 2025 17:19
@ebma ebma changed the title Kyc round 2 Add support for already KYB'd businesses Apr 17, 2025
@ebma ebma merged commit 82e2e55 into staging Apr 17, 2025
4 of 5 checks passed
@ebma ebma deleted the kyc-round-2 branch April 17, 2025 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants