Listar movimentações do investimento
curl --request GET \
--url https://api.malvo.io/investments/{id}/transactions \
--header 'X-API-KEY: <api-key>'const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://api.malvo.io/investments/{id}/transactions', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.malvo.io/investments/{id}/transactions"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.malvo.io/investments/{id}/transactions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"total": 2,
"totalPages": 1,
"page": 1,
"results": [
{
"id": "910419d2-e833-41f2-af43-080693f7ef8a",
"amount": 60000,
"description": null,
"value": 1200,
"quantity": 50,
"tradeDate": "2021-09-15T00:00:00.000Z",
"date": "2021-09-15T00:00:00.000Z",
"type": "SELL",
"movementType": "DEBIT",
"netAmount": null,
"agreedRate": null,
"brokerageNumber": null,
"expenses": {}
},
{
"id": "f24f7eec-5a5b-4e54-8727-d40b0b91115a",
"amount": 110000,
"description": null,
"value": 1100,
"quantity": 100,
"tradeDate": "2021-09-01T00:00:00.000Z",
"date": "2021-09-01T00:00:00.000Z",
"type": "BUY",
"movementType": "CREDIT",
"netAmount": 10000,
"agreedRate": null,
"brokerageNumber": "1234",
"expenses": {}
}
]
}{
"code": 403,
"codeDescription": "API_KEY_MISSING_OR_INVALID",
"message": "Missing or invalid authorization token"
}{
"code": 500,
"codeDescription": "INTERNAL_SERVER_ERROR",
"message": "Internal Server Error"
}Investments
Listar movimentações do investimento
Lista as movimentações (aplicações, resgates, impostos, juros, amortizações) de um investimento. Resposta no formato de página { total, totalPages, page, results }.
GET
/
investments
/
{id}
/
transactions
Listar movimentações do investimento
curl --request GET \
--url https://api.malvo.io/investments/{id}/transactions \
--header 'X-API-KEY: <api-key>'const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://api.malvo.io/investments/{id}/transactions', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.malvo.io/investments/{id}/transactions"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.malvo.io/investments/{id}/transactions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"total": 2,
"totalPages": 1,
"page": 1,
"results": [
{
"id": "910419d2-e833-41f2-af43-080693f7ef8a",
"amount": 60000,
"description": null,
"value": 1200,
"quantity": 50,
"tradeDate": "2021-09-15T00:00:00.000Z",
"date": "2021-09-15T00:00:00.000Z",
"type": "SELL",
"movementType": "DEBIT",
"netAmount": null,
"agreedRate": null,
"brokerageNumber": null,
"expenses": {}
},
{
"id": "f24f7eec-5a5b-4e54-8727-d40b0b91115a",
"amount": 110000,
"description": null,
"value": 1100,
"quantity": 100,
"tradeDate": "2021-09-01T00:00:00.000Z",
"date": "2021-09-01T00:00:00.000Z",
"type": "BUY",
"movementType": "CREDIT",
"netAmount": 10000,
"agreedRate": null,
"brokerageNumber": "1234",
"expenses": {}
}
]
}{
"code": 403,
"codeDescription": "API_KEY_MISSING_OR_INVALID",
"message": "Missing or invalid authorization token"
}{
"code": 500,
"codeDescription": "INTERNAL_SERVER_ERROR",
"message": "Internal Server Error"
}Authorizations
Chave de API obrigatória em todos os endpoints. Envie no header X-API-KEY: <apiKey>.
Path Parameters
Identificador do investimento.
Query Parameters
Tamanho da página. Padrão 500.
Página (1-based). Padrão 1.
Response
Página de movimentações do investimento.
Envelope de paginação por página. Os campos são números (nunca strings). totalPages é 1 quando há uma única página.