E-Signatures
Get Loan Schedule
Download the loan schedule annex as a PDF
GET
/
lending-external-securities-v2
/
api
/
markets
/
{marketId}
/
loan-agreements
/
{ref}
/
schedule.pdf
Get Loan Schedule
curl --request GET \
--url https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf \
--header 'x-api-key: <api-key>'import requests
url = "https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf', 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://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf",
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;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyReturns the loan schedule as a one-page PDF annex for the bank’s contract. It shows the agreement reference and the
scheduleHash on every page, and carries no name and no salt. A REQUESTED agreement returns its provisional figures; the frozen schedule exists once the bank issues it.
The answer is application/pdf with a Content-Disposition of Loan-Schedule-{ref}.pdf.
Path Parameters
Error Codes
| Code | HTTP | Cause |
|---|---|---|
AGREEMENT_NOT_FOUND | 404 | No agreement with this reference on this market, or your instance is not a party to it. List the agreements to find it |
MARKET_NOT_FOUND | 404 | No market with this ID on your instance |
CHAIN_UNAVAILABLE, SERVICE_UNAVAILABLE | 503 | The market or your instance’s wallets could not be read just now. Nothing was decided. Retry shortly |
⌘I
Get Loan Schedule
curl --request GET \
--url https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf \
--header 'x-api-key: <api-key>'import requests
url = "https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf', 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://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf",
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;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.trusset.org/lending-external-securities-v2/api/markets/{marketId}/loan-agreements/{ref}/schedule.pdf")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body