Skip to content

docs(api): sync fx-account spec with web source#27

Merged
leonisandes merged 3 commits into
mainfrom
docs/fx-account-sync-with-source
May 11, 2026
Merged

docs(api): sync fx-account spec with web source#27
leonisandes merged 3 commits into
mainfrom
docs/fx-account-sync-with-source

Conversation

@leonisandes
Copy link
Copy Markdown
Contributor

@leonisandes leonisandes commented May 11, 2026

Summary

Aligns apis/fx-account/openapi.yml with the request/response shapes exposed by fx-account's /api channel (web module). Drift was found in several areas — all corrected here.

Note: main was merged in to pick up #26 (Industry enum regen from IndustryV2). That change is no longer part of this PR's diff; the merge commit reconciled a duplicate Industry schema and the industry example in the create-account request (now SOFTWARE_DEVELOPMENT, matching #26).

Requests

  • AssetRequest — remove isVirtual (not present in AssetRequest.kt).
  • CompanyOwnerRequest — add isStartup: boolean (opt, default false); swap inline industry enum for a $ref to the shared Industry schema introduced by feat(api): sync Industry enum with IndustryV2 source #26.
  • UBORequest / UpdateUBORequest — add phone, email, isLegalRepresentative. Required on POST; optional on PATCH.
  • UploadDocumentRequestDocumentType enum extended with KYC_FORM, BAAS_ADHESION_FORM, PJ_PARTNER_DOCUMENTS, PJ_PARTNER_FINANCIAL_STATEMENT, SIGNING_AUTHORITY_PROOF.

Endpoints / parameters

  • GET /api/accounts/{id}/ubos — controller has no pagination or filters: removed PaginationLimit/Cursor/Direction/SortOrder/Filters. Response is now a plain array (the UBOList envelope was dropped).
  • GET /api/accounts/{id}/fundingInstructions — replaced pagination/filters with asset and rail query params (matching the controller). Response is now a plain array (the FundingInstructionList envelope was dropped).
  • GET /api/accounts/{id}/balances — removed entirely. No controller in fx-account exposes this route. Tag, schemas (BalanceResponse, BalanceEntryResponse), examples (BalanceMixed, BalanceUnsyncedSource, BalanceNotFound), docs.json group, and the get-balance.mdx page were removed too.

Responses

  • AssetResponse — field renamed assetcurrency to match the wire format (AssetResponse.kt).
  • UBOResponse — added phone, email, isLegalRepresentative.
  • CompanyOwnerResponse.industry — now references the shared Industry schema introduced by feat(api): sync Industry enum with IndustryV2 source #26.
  • RequirementResponse — rewritten as a oneOf with five concrete variants matching the sealed class hierarchy:
    • ACCOUNT_DOCUMENTAccountDocumentRequirement
    • UBO_DOCUMENTUboDocumentRequirement (with required uboId)
    • IDENTITY_VERIFICATIONIdentityVerificationRequirement (group with options)
    • ACCOUNT_FIELDAccountFieldRejection
    • UBO_FIELDUboFieldRejection
  • FundingInstructionResponse — discriminator changed from rail to type (the actual JsonSubTypes property); added missing PIX_BANK_INSTRUCTION variant; added new FundingInstructionType enum; each variant now constrains both type and rail (the latter is derived — e.g., type=CRYPTO_WALLET maps to rail=CRYPTO).

Test plan

  • mint validate passes.
  • mint broken-links passes.
  • navigation-coverage eval: 100% (63/63).
  • orphan-detector eval: 100% (63/63).
  • openapi-completeness eval: passes.
  • Industry enum verified equivalent to IndustryV2 from development-utils 2.81.0 (86 values, identical sets).
  • Spot-check the rendered API Reference pages once the branch deploys to the docs preview environment.

🤖 Generated with Claude Code

Aligns apis/fx-account/openapi.yml with the live request/response shapes
exposed by fx-account's /api channel:

- POST /api/accounts: drop AssetRequest.isVirtual (not in source); add
  CompanyOwnerRequest.isStartup; rewire industry to a shared Industry
  schema regenerated from IndustryV2 (87 values).
- POST/PATCH /api/accounts/{id}/ubos: add phone, email, and
  isLegalRepresentative to UBORequest, UpdateUBORequest, and UBOResponse.
- GET /api/accounts/{id}/ubos: drop spurious pagination/filter params;
  response is a plain array, not a paginated envelope.
- GET /api/accounts/{id}/fundingInstructions: drop pagination/filter
  params, add asset and rail query filters, response is a plain array.
  FundingInstructionResponse now uses type as discriminator, exposes
  both type and rail fields, and includes the missing
  PIX_BANK_INSTRUCTION variant.
- Remove the /api/accounts/{id}/balances endpoint and associated
  schemas/examples/navigation entry — the route does not exist in
  fx-account.
- Rewrite RequirementResponse as a oneOf with five concrete variants
  (ACCOUNT_DOCUMENT, UBO_DOCUMENT, IDENTITY_VERIFICATION, ACCOUNT_FIELD,
  UBO_FIELD) matching the sealed class hierarchy.
- AssetResponse.asset renamed to currency to match the wire format.
- Extend DocumentType with KYC_FORM, BAAS_ADHESION_FORM,
  PJ_PARTNER_DOCUMENTS, PJ_PARTNER_FINANCIAL_STATEMENT, and
  SIGNING_AUTHORITY_PROOF.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@mintlify
Copy link
Copy Markdown

mintlify Bot commented May 11, 2026

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
tracefinance 🟢 Ready View Preview May 11, 2026, 2:12 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

# Conflicts:
#	apis/fx-account/openapi.yml
The text-formatting eval flagged a soft-wrapped line inside a `|`
literal block, where the newline renders as a visible break in
Mintlify. Joining the intro sentence keeps the bullet list intact.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@leonisandes leonisandes merged commit 8b5a7ed into main May 11, 2026
8 checks passed
@leonisandes leonisandes deleted the docs/fx-account-sync-with-source branch May 11, 2026 14:48
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