English Version
Dollar Mep
The MEP Dollar module allows your platform to offer users the purchase and sale of dollars through the Argentine capital market, in a regulated and fully automated way. API Broker manages the entire operational cycle end-to-end: from instrument identification to final settlement, without you having to implement any operational logic or pricing calculations.
How does it work?
- MEP Purchase: the user buys a bond in pesos (e.g. AL30) and sells it in dollars (AL30D). The result is a USD credit in their brokerage account.
- MEP Sale: the user buys a bond in dollars and sells it in pesos. The result is an ARS credit in their brokerage account.
API Broker executes both operations on T+0, automatically handling regulatory validations, CNV quotas, authorized instruments, and reconciliation.
Key Features
- Integration 100% via APIs and webhooks.
- Buy and sell on T+0.
- Full management of CNV quotas, validations, and requirements.
- Automatic reconciliation of deposits and withdrawals.
- Revenue share per transaction.
- Compatible with PSP models and traditional bank collection.
Integration Flow
a. Onboarding
To operate MEP Dollar, the user must have completed onboarding. The steps are standard:
POST /v2/persons→ generates theperson_idPOST /identity-documents→ uploads identity documentationPOST /v2/investment-accounts→ generates theinvestment_account_idPOST /bank-accounts→ generates thebank_account_id(currently optional, mandatory as of May 2025)
Important: the bank account must be same-name, i.e. held by the same owner as the brokerage account. Validation is performed by CUIT.
b. Cash In
Adcap Securities provides collection bank accounts (CBU) in ARS and USD. The user transfers their funds to those accounts and API Broker automatically credits them to the brokerage account.
When the deposit is completed, API Broker notifies via webhook:
{
"topic": "deposit_create",
"items": [{
"investment_account_id": 43101,
"currency_id": "ARS",
"amount": 10.0,
"trade_date": "2024-09-03",
"status_id": "COMPLETED",
"deposit_id": 631184,
"tax_identification_value": "20415653825"
}]
}c. MEP Rate Quote
Before executing the operation, your platform can query the estimated MEP rate for the chosen instrument pair. GET /dollar-exchange-by-tickers/{ticker_ars}/{ticker_usd}
Typical example: GET /dollar-exchange-by-tickers/AL30/AL30D
Returns the estimated MEP rate, including the implicit value and the spread between both sides.
d. Creating a MEP Order (Buy / Sell)
The partner sends the buy or sell instruction: POST /market/mep-order
Example body:
{
"investment_account_id": 7403,
"amount": 12320,
"base_instrument_id": 41,
"market_operation_type": "buy",
"external_id": "extern123"
}Key parameters:
| Field | Type | Description |
|---|---|---|
investment_account_id | int | User's brokerage account ID |
amount | number | Amount in the base currency of the operation |
base_instrument_id | int | Instrument ID (e.g. AL30 = 41) |
market_operation_type | string | "buy" to purchase MEP (ARS → USD) / "sell" to sell MEP (USD → ARS) |
external_id | string | Client's unique identifier to prevent duplicates |
API Broker executes the buy on T+0 and the sell on T+0. Funds are credited in the final currency directly to the user's brokerage account.
e. Querying MEP Order Status
Once the MEP order is created, the partner can check its status at any time using the mep_market_order_id returned by POST /market/mep-order. GET /api/market/mep-order/{mep_market_order_id}
Parameters:
| Field | Type | Description |
|---|---|---|
mep_market_order_id | integer | MEP order ID (path param, required) |
Possible responses:
| Code | Description |
|---|---|
200 | Returns the full status and details of the order |
404 | Order not found |
422 | Validation error |
500 | Internal server error |
Note: While order status can also be tracked via webhooks, this endpoint allows for point-in-time queries or reconciliation from the partner's side.
f. Retrieving Market Order Tickets
After operations are executed, the partner can retrieve the tickets (market confirmations) associated with a brokerage account. This is useful for showing receipts to the user or for reconciliation processes. GET /api/market/stock-market-confirmations/confirmations-by-investment-account/{investment_account_id}
Path params:
| Field | Type | Description |
|---|---|---|
investment_account_id | integer | Brokerage account ID (required) |
Optional query params:
| Field | Type | Description |
|---|---|---|
page | integer (≥ 1) | Page number. Default: 1 |
size | integer (1–100) | Results per page. Default: 50 |
from_date | date | Filter start date (format YYYY-MM-DD) |
to_date | date | Filter end date (format YYYY-MM-DD) |
Example: GET /api/market/stock-market-confirmations/confirmations-by-investment-account/7403?from_date=2024-09-01&to_date=2024-09-30&page=1&size=50
Possible responses:
| Code | Description |
|---|---|
200 | Paginated list of confirmations/tickets for the account |
404 | Brokerage account not found |
422 | Validation error |
500 | Internal server error |
Note: Tickets include the detail of each leg of the MEP operation (bond purchase in ARS and sale in USD, or vice versa). This endpoint is recommended for generating downloadable receipts for the end user.
g. Portfolio Status Query (Post-Operation Position)
Once the MEP operation is completed, the partner can query the brokerage account statement to verify the crediting of dollars (on MEP purchase) or pesos (on MEP sale). GET /api/portfolio/account-statements/{investment_account_id}
Path params:
| Field | Type | Description |
|---|---|---|
investment_account_id | integer | Brokerage account ID (required) |
Optional query params:
| Field | Type | Default | Description |
|---|---|---|---|
position_discriminator_bcra | boolean | true | Discriminates position according to BCRA criteria |
compromised_holdings | boolean | false | Includes committed holdings (e.g. pending settlement) |
include_remunerated_balance | boolean | false | Includes available remunerated balance |
Example after MEP purchase: GET /api/portfolio/account-statements/7403
The response includes the monetary position (ARS and USD balances) and the available holdings of the account. After a successful MEP purchase, the USD balance should reflect the credited dollars.
Possible responses:
| Code | Description |
|---|---|
200 | Returns the account statement with monetary position and holdings |
422 | Validation error |
Recommended post-operation flow: execute
POST /market/mep-order→ wait for confirmation via webhook or polling withGET /api/market/mep-order/{mep_market_order_id}→ queryGET /api/portfolio/account-statements/{investment_account_id}to verify the USD balance has been credited.
h. Cash Out
Once funds are credited to the brokerage account, the user can withdraw them to a same-name bank account: POST /withdraw-requests
API Broker responds with the request in IN_PROGRESS status. The transfer may go out automatically within seconds or remain pending manual validation. The status is notified via webhook:
{
"topic": "withdraw_request_update",
"items": [{
"amount": 100,
"status_id": "COMPLETED",
"currency_id": "ARS",
"bank_account_id": 121535,
"withdraw_request_id": 984479,
"investment_account_id": 74659
}]
}Possible statuses: IN_PROGRESS → COMPLETED / REJECTED
Validations & Compliance
API Broker automatically performs the following validations. The partner does not need to implement any regulatory logic:
- Same-name ownership validation
- Blocked CUIT check
- Regulatory limits (CNV)
- Authorized instruments check
- Real fund availability verification
- Settlement and liquidity verification
Main Endpoints
| Method | Endpoint | Description |
|---|---|---|
| POST | /v2/persons | Create person |
| POST | /identity-documents | Upload identity documentation |
| POST | /v2/investment-accounts | Create brokerage account |
| POST | /bank-accounts | Create bank account |
| GET | /dollar-exchange-by-tickers/{ticker_ars}/{ticker_usd} | Estimated MEP rate |
| POST | /market/mep-order | Create MEP buy/sell order |
| GET | /api/market/mep-order/{mep_market_order_id} | Query MEP order status |
| GET | /api/market/stock-market-confirmations/confirmations-by-investment-account/{investment_account_id} | Get market confirmations/tickets by brokerage account |
| GET | /api/portfolio/account-statements/{investment_account_id} | Query portfolio status / post-operation balances |
| POST | /withdraw-requests | Withdraw funds |
Webhooks to Implement
Your platform must expose a URL to receive the following events:
deposit_create Notifies credited deposits: investment_account_id, currency, amount, and date.
withdraw_request_update Notifies withdrawal status: IN_PROGRESS, COMPLETED, or REJECTED, along with amount and destination account.
Key Points to Remember
- Onboarding is a prerequisite: the user needs an
investment_account_idbefore operating MEP. - Bank account will be mandatory as of May 2025: although currently optional, it's worth integrating from the start.
- API Broker handles all regulatory logic: no need to implement CNV validations or quota controls on the partner's side.
- Operations are T+0: buy and sell execute on the same business day.
external_idis key for idempotency: always send it to avoid duplicate orders.- Withdrawals are only to same-name accounts: transfers to third parties are not allowed.
- Everything is asynchronous: always track status via webhooks.
Updated 6 months ago
