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
string
required
The JWT Access Token obtained from the
/login or /refresh-token endpoint.string
required
Unique idempotency key for the request to prevent duplicate processing.
string
required
The date and time at which the request was initiated (ISO 8601 format).
string
required
The IP address of the customer making the request.
string
required
Unique identifier for the interaction/session.
Query Parameters
string
Optional filter to show repayments for a specific loan application.
string
Optional filter by repayment status. Options:
PENDING_VERIFICATION, VERIFIED, REJECTED, ALL.number
default:"1"
Page number for pagination (starts from 1).
number
default:"10"
Number of items per page (maximum recommended: 50).
string
Optional start date filter (ISO 8601 format) to show repayments from a specific date.
string
Optional end date filter (ISO 8601 format) to show repayments up to a specific date.
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;
}
}
