Skip to content

[TRNF-8322] Feat(v2): Support the onboarding type and data create shape - #31

Merged
tlarrain merged 1 commit into
mainfrom
feat/entity-onboardings-type-and-data
Aug 25, 2026
Merged

[TRNF-8322] Feat(v2): Support the onboarding type and data create shape#31
tlarrain merged 1 commit into
mainfrom
feat/entity-onboardings-type-and-data

Conversation

@JoMarchant

Copy link
Copy Markdown
Contributor

Contexto

El API público v2 cambió el contrato de creación de onboardings de entities: ahora
exige un type (account_holder o settlement_recipient) y recibe el payload
anidado bajo data, en vez de las estructuras al nivel superior. El SDK quedó
documentando y testeando la forma antigua, que hoy responde 422.

¿Qué hay de nuevo?

  • Fintoc::V2::Onboarding expone type (el API ya lo devuelve en show e index)
  • README: create usa type: + data:, con valores MX reales y los enums vigentes
  • README: se documenta el accessor onboarding.type

Tests

  • Specs de Onboarding cubren type en la forma completa y en la liviana
  • Spec de OnboardingsManager arma el body de create con type + data

Safety Checks

  • Versión y CHANGELOG actualizados (si corresponde)

Consideraciones

  • El manager pasa los parámetros tal cual al API, así que create ya soportaba la
    nueva forma sin cambios: lo que estaba desactualizado eran las specs y el README.
  • El upload de documentos de representante legal ya venía de [ONB-2514] Feat(v2): Add legal representative document upload #27; acá solo se
    completa lo que faltaba del schema (type y data).

Rollback

Seguro. Es un cambio aditivo (un attr_reader nuevo) más documentación y specs;
revertir el commit deja el SDK como estaba.

The public API now requires a `type` on entity onboarding creation
(`account_holder` or `settlement_recipient`) and takes the company
information, legal representatives, transactional profile and shareholders
nested under `data` instead of at the top level.

Expose the `type` the API returns on the onboarding object, and move the
docs and specs to the current request shape.
@fin-hermes fin-hermes Bot added the size/M label Aug 24, 2026
@JoMarchant
JoMarchant marked this pull request as ready for review August 25, 2026 19:23
@JoMarchant
JoMarchant requested a review from tlarrain August 25, 2026 19:23
@tlarrain
tlarrain merged commit b6443f9 into main Aug 25, 2026
4 checks passed
@tlarrain
tlarrain deleted the feat/entity-onboardings-type-and-data branch August 25, 2026 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants