Skip to content
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
6 changes: 3 additions & 3 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,11 +107,11 @@ Page types are inferred from file paths:
`snippets/` contains shared MDX blocks. Import them in any page:

```mdx
import SandboxNote from '/snippets/sandbox-note.mdx';
<SandboxNote />
import AuthHeader from '/snippets/auth-header.mdx';
<AuthHeader />
```

Available: `auth-header`, `sandbox-note`, `idempotency-note`, `pagination-response`, `error-response`, `money-format`, `version-header`.
Available: `auth-header`, `idempotency-note`, `pagination-response`, `error-response`, `money-format`, `version-header`.

### CI (GitHub Actions)

Expand Down
408 changes: 399 additions & 9 deletions apis/fx-account/openapi.yml

Large diffs are not rendered by default.

17 changes: 3 additions & 14 deletions docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
"favicon": "/favicon.svg",
"logo": {
"light": "/logo/light.svg",
"dark": "/logo/dark.svg",
"href": "https://tracefinance.io"
"dark": "/logo/dark.svg"
},
"appearance": {
"default": "dark"
Expand Down Expand Up @@ -65,8 +64,7 @@
{
"group": "Journeys",
"pages": [
"journeys/open-brl-account",
"journeys/open-crypto-account",
"journeys/open-multi-currency-account",
"journeys/deposit",
"journeys/withdrawal",
"journeys/swap"
Expand Down Expand Up @@ -146,16 +144,7 @@
}
]
}
],
"global": {
"anchors": [
{
"anchor": "API Status",
"href": "https://status.tracefinance.io",
"icon": "signal"
}
]
}
]
},
"navbar": {
"links": [
Expand Down
7 changes: 2 additions & 5 deletions index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,16 @@
## Build with Trace

<CardGroup cols={2}>
<Card title="Open a BRL account" icon="building-columns" href="/journeys/open-brl-account">
Create and manage Brazilian Real accounts for your users.
</Card>
<Card title="Open a crypto account" icon="bitcoin" iconType="brands" href="/journeys/open-crypto-account">
Set up cryptocurrency accounts with full compliance.
<Card title="Open a multi-currency account" icon="wallet" href="/journeys/open-multi-currency-account">
Create accounts that hold fiat and crypto for your users.

Check warning on line 26 in index.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

index.mdx#L26

Did you really mean 'crypto'?
</Card>
<Card title="Deposit funds" icon="arrow-down-to-line" href="/journeys/deposit">
Accept deposits via PIX, wire transfer, and crypto networks.

Check warning on line 29 in index.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

index.mdx#L29

Did you really mean 'crypto'?
</Card>
<Card title="Withdraw funds" icon="arrow-up-from-line" href="/journeys/withdrawal">
Process withdrawals to bank accounts and crypto wallets.

Check warning on line 32 in index.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

index.mdx#L32

Did you really mean 'crypto'?
</Card>
<Card title="Swap currencies" icon="arrows-rotate" href="/journeys/swap">
Exchange between BRL, USD, and crypto assets.

Check warning on line 35 in index.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

index.mdx#L35

Did you really mean 'crypto'?
</Card>
</CardGroup>
6 changes: 1 addition & 5 deletions journeys/deposit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,13 @@
description: "How to create a deposit and track it through to completion."
---

import SandboxNote from '/snippets/sandbox-note.mdx';

<SandboxNote />

## Overview

Deposits fund an account with BRL (via PIX or bank transfer) or crypto (via blockchain transfer). There are two flows depending on whether you initiate the deposit through the API first or the funds arrive first.

Check warning on line 8 in journeys/deposit.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/deposit.mdx#L8

Did you really mean 'crypto'?

Check warning on line 8 in journeys/deposit.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/deposit.mdx#L8

Did you really mean 'blockchain'?

## Prerequisites

- An [active account](/journeys/open-brl-account) to deposit into.
- An [active account](/journeys/open-multi-currency-account) to deposit into.
- Valid [authentication credentials](/guides/authentication).

## Steps
Expand Down
50 changes: 0 additions & 50 deletions journeys/open-brl-account.mdx

This file was deleted.

51 changes: 0 additions & 51 deletions journeys/open-crypto-account.mdx

This file was deleted.

67 changes: 67 additions & 0 deletions journeys/open-multi-currency-account.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
title: "Open a multi-currency account"
description: "Step-by-step guide to opening an account that holds one or more currencies for an account owner."
---

## Overview

An account in Trace FX is multi-currency: every account includes crypto support by default, and you declare which fiat assets (like BRL) to enable when you create it. Each fiat asset and the crypto wallet run their own onboarding pipelines, and the account becomes `ACTIVE` as soon as the first one finishes — typically the crypto wallet, since it has no manual steps.

Check warning on line 8 in journeys/open-multi-currency-account.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/open-multi-currency-account.mdx#L8

Did you really mean 'crypto'?

Check warning on line 8 in journeys/open-multi-currency-account.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/open-multi-currency-account.mdx#L8

Did you really mean 'crypto'?

Check warning on line 8 in journeys/open-multi-currency-account.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/open-multi-currency-account.mdx#L8

Did you really mean 'crypto'?

## Prerequisites

- Valid [authentication credentials](/guides/authentication).
- Account owner details (company legal name, tax ID, industry, and address).

## Steps

<Steps>
<Step title="Create the account">
Submit a request with the fiat assets to enable and the account owner's details. Crypto support is always included — you don't need to declare it.

Check warning on line 19 in journeys/open-multi-currency-account.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/open-multi-currency-account.mdx#L19

Did you really mean 'Crypto'?

```bash
curl --request POST \
--url {{sandboxUrl}}/api/accounts \
--header 'Authorization: Bearer <token>' \
--header 'X-Idempotency-Key: <unique-key>' \
--header 'Content-Type: application/json' \
--data '{
"assets": [
{ "code": "BRL", "isVirtual": false }
],
"owner": {
"type": "COMPANY",
"legalName": "Acme Ltda",
"taxId": "12345678000101",
"industry": "INFORMATION_TECHNOLOGY",
"address": {
"addressLine1": "Rua das Flores, 100",
"addressLine2": "Suite 456",
"city": "São Paulo",
"state": "SP",
"country": "BR",
"postalCode": "01234-567"
}
}
}'
```

The response returns the account in `REQUESTED` status along with the document types required for onboarding. Fiat onboarding requires document uploads; crypto has none.
</Step>
<Step title="Upload required documents">
For each document type returned in the creation response, upload the file using [`POST /api/accounts/{accountId}/documents`](/api-reference/fx-account/documents/upload-account-document).
</Step>
<Step title="Submit for review">
Once all required documents are uploaded, call [`POST /api/accounts/{accountId}/review`](/api-reference/fx-account/accounts/submit-account-for-review) to trigger identity analysis. The account transitions to `REVIEWING`.
</Step>
<Step title="Wait for activation">
After analysis is approved, each asset activates on its own pipeline. Listen for the `account.activated` webhook event or poll [`GET /api/accounts/{accountId}`](/api-reference/fx-account/accounts/get-account) — the account becomes `ACTIVE` as soon as the first asset finishes onboarding.
</Step>
<Step title="Retrieve funding instructions">
Once the account is active, call [`GET /api/accounts/{accountId}/fundingInstructions`](/api-reference/fx-account/funding-instructions/list-funding-instructions) to retrieve incoming transfer details per active asset: PIX key and bank account for BRL, wallet address for crypto.

Check warning on line 60 in journeys/open-multi-currency-account.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/open-multi-currency-account.mdx#L60

Did you really mean 'crypto'?
</Step>
</Steps>

## What happens next

- [Make a deposit](/journeys/deposit) — fund the account with BRL or crypto.

Check warning on line 66 in journeys/open-multi-currency-account.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/open-multi-currency-account.mdx#L66

Did you really mean 'crypto'?
- [Execute a swap](/journeys/swap) — convert between the account's assets.
6 changes: 1 addition & 5 deletions journeys/swap.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,13 @@ title: "Execute a swap"
description: "How to convert between currencies using the swap endpoint."
---

import SandboxNote from '/snippets/sandbox-note.mdx';

<SandboxNote />

## Overview

Swaps convert funds between currencies within the platform — for example, BRL to USD or BTC to BRL. The flow is forward-only: once a swap is executed at the quoted rate, it cannot be reversed.

## Prerequisites

- An [active account](/journeys/open-brl-account) with sufficient balance in the source currency.
- An [active account](/journeys/open-multi-currency-account) with sufficient balance in the source currency.
- Valid [authentication credentials](/guides/authentication).

## Steps
Expand Down
6 changes: 1 addition & 5 deletions journeys/withdrawal.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,13 @@
description: "How to create a withdrawal and handle the review process."
---

import SandboxNote from '/snippets/sandbox-note.mdx';

<SandboxNote />

## Overview

Withdrawals move funds from an account to an external destination — a bank account (via TED or PIX) or a crypto wallet. Some withdrawals go through a compliance review before being processed.

Check warning on line 8 in journeys/withdrawal.mdx

View check run for this annotation

Mintlify / Mintlify Validation (tracefinance) - vale-spellcheck

journeys/withdrawal.mdx#L8

Did you really mean 'crypto'?

## Prerequisites

- An [active account](/journeys/open-brl-account) with sufficient balance.
- An [active account](/journeys/open-multi-currency-account) with sufficient balance.
- A registered **beneficiary** for the destination (bank account or wallet).
- Valid [authentication credentials](/guides/authentication).

Expand Down
6 changes: 1 addition & 5 deletions quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ title: "Quickstart"
description: "Make your first API request to Trace FX in under five minutes."
---

import SandboxNote from '/snippets/sandbox-note.mdx';

<SandboxNote />

## Prerequisites

- A **client ID** and **client secret** provided during onboarding.
Expand Down Expand Up @@ -47,6 +43,6 @@ import SandboxNote from '/snippets/sandbox-note.mdx';

## What's next

- [Open a BRL account](/journeys/open-brl-account) — create your first account
- [Open a multi-currency account](/journeys/open-multi-currency-account) — create your first account
- [Authentication](/guides/authentication) — learn about token management
- [Environments](/guides/environments) — understand sandbox vs production
4 changes: 0 additions & 4 deletions snippets/sandbox-note.mdx

This file was deleted.

Loading