Skip to main content
POST
/
api
/
v1
/
br
/
loan-applications
/
{id}
/
capitalization-consents
Ingest BR capitalization clause consent
curl --request POST \
  --url https://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "acceptedAt": "2023-11-07T05:31:56Z",
  "clauseText": "<string>",
  "clauseTextHash": "<string>",
  "consentEvidence": "<string>"
}
'
import requests

url = "https://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents"

payload = {
"acceptedAt": "2023-11-07T05:31:56Z",
"clauseText": "<string>",
"clauseTextHash": "<string>",
"consentEvidence": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
acceptedAt: '2023-11-07T05:31:56Z',
clauseText: '<string>',
clauseTextHash: '<string>',
consentEvidence: '<string>'
})
};

fetch('https://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents', 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://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'acceptedAt' => '2023-11-07T05:31:56Z',
'clauseText' => '<string>',
'clauseTextHash' => '<string>',
'consentEvidence' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents"

payload := strings.NewReader("{\n \"acceptedAt\": \"2023-11-07T05:31:56Z\",\n \"clauseText\": \"<string>\",\n \"clauseTextHash\": \"<string>\",\n \"consentEvidence\": \"<string>\"\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"acceptedAt\": \"2023-11-07T05:31:56Z\",\n \"clauseText\": \"<string>\",\n \"clauseTextHash\": \"<string>\",\n \"consentEvidence\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://lender.sandbox.lerian.net/api/v1/br/loan-applications/{id}/capitalization-consents")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"acceptedAt\": \"2023-11-07T05:31:56Z\",\n \"clauseText\": \"<string>\",\n \"clauseTextHash\": \"<string>\",\n \"consentEvidence\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "acceptedAt": "<string>",
  "acceptedByActor": "<string>",
  "clauseTextHash": "<string>",
  "consentEvidence": "<string>",
  "createdAt": "<string>",
  "id": "<string>",
  "jurisdictionCode": "<string>",
  "loanApplicationId": "<string>",
  "profileVersion": "<string>"
}
{
"code": "<string>",
"detail": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
],
"instance": "<string>",
"status": 123,
"title": "<string>",
"type": "about:blank"
}

Authorizations

Authorization
string
header
required

JWT bearer token issued by the identity provider.

Path Parameters

id
string<uuid>
required

Loan application identifier.

Body

application/json
acceptedAt
string<date-time>
required

RFC3339 timestamp the borrower accepted the clause.

clauseText
string
required

Raw capitalization clause text presented to the borrower.

clauseTextHash
string
required

Client-computed SHA-256 hex digest of the canonicalized clause text.

Required string length: 64
Pattern: ^[a-f0-9]{64}$
Example:

"a3b1c2d4e5f60718293a4b5c6d7e8f90a1b2c3d4e5f60718293a4b5c6d7e8f90"

Opaque evidence reference proving the borrower accepted the clause.

Response

Created

acceptedAt
string
required

RFC3339 UTC timestamp when the borrower accepted the clause.

Example:

"2026-06-14T12:00:00Z"

acceptedByActor
string
required

Authenticated actor identity (resolved from request context) that accepted the clause.

clauseTextHash
string
required

Server-recomputed SHA-256 hex digest of the canonicalized clause text (64 lowercase hex chars).

Example:

"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"

Opaque evidence reference proving the borrower accepted the clause.

createdAt
string
required

RFC3339 UTC timestamp when the artifact was persisted.

Example:

"2026-06-14T12:00:00Z"

id
string
required

Server-generated UUID of the persisted consent artifact.

Example:

"550e8400-e29b-41d4-a716-446655440000"

jurisdictionCode
string
required

ISO 3166-1 alpha-2 jurisdiction code (e.g. "BR").

Example:

"BR"

loanApplicationId
string
required

UUID of the loan application this consent is attached to.

Example:

"550e8400-e29b-41d4-a716-446655440001"

profileVersion
string
required

Jurisdiction profile version in effect when the disclosure was presented (e.g. "1.0.0").

Example:

"1.0.0"