List Repayments
curl --request GET \
--url https://{your-domain}.fincode.software/api/v6/services/admin/repayments/listimport requests
url = "https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list")
.asString();require 'uri'
require 'net/http'
url = URI("https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyAPI Endpoints
List Repayments
Retrieves a paginated list of all repayments for a loan or across all loans.
GET
/
admin
/
repayments
/
list
List Repayments
curl --request GET \
--url https://{your-domain}.fincode.software/api/v6/services/admin/repayments/listimport requests
url = "https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list")
.asString();require 'uri'
require 'net/http'
url = URI("https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyFetches a paginated list of repayment records, allowing managers to view and track all loan repayments. Can be filtered by loan application ID to show repayments for a specific loan.
Request Headers
Query Parameters
Code Examples
curl --location 'https://{your-domain}.fincode.software/api/v6/services/admin/repayments/list?page=1&size=10&status=VERIFIED' \
--header 'X-Auth-Token: YOUR_JWT_ACCESS_TOKEN' \
--header 'x-idempotency-key: unique-key-12345' \
--header 'x-fapi-auth-date: 2024-01-15T10:30:00Z' \
--header 'x-fapi-customer-ip-address: 192.168.1.1' \
--header 'x-fapi-interaction-id: interaction-12345'
const axios = require('axios');
const BASE_URL = 'https://{your-domain}.fincode.software/api/v6/services/admin/repayments';
async function listRepayments(accessToken, filters = {}) {
try {
const params = {
page: filters.page || 1,
size: filters.size || 10,
};
if (filters.loanApplicationId) {
params.loanApplicationId = filters.loanApplicationId;
}
if (filters.status) {
params.status = filters.status;
}
if (filters.startDate) {
params.startDate = filters.startDate;
}
if (filters.endDate) {
params.endDate = filters.endDate;
}
const response = await axios.get(`${BASE_URL}/list`, {
params,
headers: {
'X-Auth-Token': accessToken,
'x-idempotency-key': `key-${Date.now()}`,
'x-fapi-auth-date': new Date().toISOString(),
'x-fapi-customer-ip-address': '192.168.1.1',
'x-fapi-interaction-id': `interaction-${Date.now()}`,
},
});
const repayments = response.data.data.content;
console.log(`Found ${repayments.length} repayments`);
console.log(`Total: ${response.data.data.totalElements} repayments`);
console.log(`Page ${response.data.data.currentPage} of ${response.data.data.totalPages}`);
repayments.forEach((repayment) => {
console.log(
`- ${repayment.repaymentId}: ${repayment.repaymentAmount} ` +
`(${repayment.paymentMethod}) - Status: ${repayment.status}`
);
});
return response.data.data;
} catch (error) {
console.error(
'Failed to list repayments:',
error.response?.data || error.message
);
throw error;
}
}
