Execute MEP operation
Executes a buy or sell operation of USD-MEP dollars for a client account.
POST
/v1/operations/usd-mep/{side}Request
Headers
| Field | Type | Required | Description |
|---|---|---|---|
Authorization | string | Yes | Access token in Bearer ACCESS_TOKEN format |
Content-Type | string | Yes | Must be application/json |
Path Parameters
| Field | Type | Required | Description |
|---|---|---|---|
side | string | Yes | Operation side. Possible values: buy, sell. |
Not applicable: Query Parameters.
Body
| Field | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Client-generated idempotency ID for the operation. |
account_id | string | Yes | Client account number the operation is executed on. The account must be enabled. |
amount | number | Yes | Amount of the operation, in ARS. |
estimated_price | number | Yes | Price quoted for the operation (as returned by Get MEP quote) at the moment the client confirms it. |
person_type | string | No | Type of the account holder. Possible values: NATURAL, NATURAL_NON_RESIDENT, JURIDICAL. |
Response
2XX Success
| Field | Type | Description |
|---|---|---|
id | string | Client-generated idempotency ID of the executed operation. |
executed_at | string (ISO 8601 datetime) | Timestamp when the operation was executed. |
estimated_price | number | Price used to execute the operation. |
Error Codes
| Status | Description |
|---|---|
400 | Bad Request — id is missing, side is not buy/sell, or the account is not enabled |
401 | Unauthorized — invalid or missing access token |
403 | Forbidden — the token does not have permission to access this resource |
500 | Internal Server Error |
Error structure:
{
"code": "BAD_REQUEST",
"description": "Invalid request parameters, id is needed"
}
Code Example
- cURL
- JavaScript
- Python
- Node.js
curl -X POST https://b2b.allaria.cloud/v1/operations/usd-mep/buy \
-H "Authorization: Bearer ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"id": "3f1c2b4a-5d6e-4f7a-8b9c-0d1e2f3a4b5c",
"account_id": "12345",
"amount": 100000.00,
"estimated_price": 1245.50,
"person_type": "NATURAL"
}'
const side = 'buy';
const response = await fetch(`https://b2b.allaria.cloud/v1/operations/usd-mep/${side}`, {
method: 'POST',
headers: {
'Authorization': 'Bearer ACCESS_TOKEN',
'Content-Type': 'application/json'
},
body: JSON.stringify({
id: '3f1c2b4a-5d6e-4f7a-8b9c-0d1e2f3a4b5c',
account_id: '12345',
amount: 100000.00,
estimated_price: 1245.50,
person_type: 'NATURAL'
})
});
const data = await response.json();
console.log(data);
import requests
side = 'buy'
response = requests.post(
f'https://b2b.allaria.cloud/v1/operations/usd-mep/{side}',
headers={
'Authorization': 'Bearer ACCESS_TOKEN',
'Content-Type': 'application/json'
},
json={
'id': '3f1c2b4a-5d6e-4f7a-8b9c-0d1e2f3a4b5c',
'account_id': '12345',
'amount': 100000.00,
'estimated_price': 1245.50,
'person_type': 'NATURAL'
}
)
data = response.json()
print(data)
const axios = require('axios');
const side = 'buy';
const response = await axios.post(
`https://b2b.allaria.cloud/v1/operations/usd-mep/${side}`,
{
id: '3f1c2b4a-5d6e-4f7a-8b9c-0d1e2f3a4b5c',
account_id: '12345',
amount: 100000.00,
estimated_price: 1245.50,
person_type: 'NATURAL'
},
{
headers: {
Authorization: 'Bearer ACCESS_TOKEN',
'Content-Type': 'application/json'
}
}
);
console.log(response.data);
2XX Success
{
"id": "3f1c2b4a-5d6e-4f7a-8b9c-0d1e2f3a4b5c",
"executed_at": "2026-07-21T09:10:15",
"estimated_price": 1245.50
}