AltScore
Borrower Central (BC)

Relationships API

This API allows managing relationships between borrowers. It provides endpoints to create, read, update, and delete relationships, as well as to perform queries and obtain relationship summaries.

The Relationship Object

The Relationship object represents a relationship between a borrower and a contact in the system.

{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "borrowerId": "b789-12d3-a456-426614174001",
  "contactId": "c123-45d6-b789-012345678902",
  "priority": 1,
  "isActive": true,
  "isLegalRepresentative": false,
  "relationship": "shareholder",
  "ownershipPct": 25.5,
  "createdAt": "2023-01-01T00:00:00Z",
  "updatedAt": "2023-04-01T12:00:00Z"
}

Attributes

AttributeDescriptionType
idUnique identifier of the relationshipString
borrowerIdID of the borrower associated with the relationshipString
contactIdID of the contact associated with the relationshipString
priorityPriority of the relationshipInteger
isActiveIndicates if the relationship is activeBoolean
isLegalRepresentativeIndicates if the contact is a legal representativeBoolean
relationshipType of relationship (shareholder, employee, family, other, unspecified)String
ownershipPctOwnership percentage (only for shareholders)Float
createdAtDate and time of relationship creationString (ISO 8601)
updatedAtDate and time of the last relationship updateString (ISO 8601)

Available Operations

Create a New Relationship

Creates a new relationship between a borrower and a contact.

POST /v1/relationships

Input Parameters:

ParameterDescriptionTypeRequired
borrowerIdID of the borrowerStringYes
contactIdID of the contactStringYes
priorityPriority of the relationshipIntegerNo
relationshipType of relationshipStringNo
isLegalRepresentativeIndicates if it is a legal representativeBooleanNo
isActiveIndicates if the relationship is activeBooleanNo
ownershipPctOwnership percentage (only for shareholders)FloatNo

Example Request:

{
  "borrowerId": "b789-12d3-a456-426614174001",
  "contactId": "c123-45d6-b789-012345678902",
  "priority": 1,
  "relationship": "shareholder",
  "isLegalRepresentative": false,
  "isActive": true,
  "ownershipPct": 25.5
}

Successful Response:

{
  "id": "123e4567-e89b-12d3-a456-426614174000"
}

Update a Relationship

Updates an existing relationship.

PATCH /v1/relationships/:relationship_id

Input Parameters:

ParameterDescriptionTypeRequired
priorityNew priority of the relationshipIntegerNo
relationshipNew type of relationshipStringNo
isLegalRepresentativeNew legal representative statusBooleanNo
isActiveNew activity statusBooleanNo
ownershipPctNew ownership percentageFloatNo

Example Request:

{
  "priority": 2,
  "isActive": false
}

Successful Response:

Returns the updated Relationship object.

Delete a Relationship

Deletes an existing relationship.

DELETE /v1/relationships/:relationship_id

Successful Response:

Status code 204 (No Content) if the deletion was successful.

Get a Relationship

Retrieves information about a specific relationship.

GET /v1/relationships/:relationship_id

Successful Response:

Returns the complete Relationship object.

List Relationships

Retrieves a paginated list of relationships with filtering and sorting options.

GET /v1/relationships

Query Parameters:

ParameterDescriptionType
borrower-idFilter by borrower IDString
priorityFilter by priorityString
is-legal-representativeFilter by legal representativeBoolean
searchText to searchString
pagePage numberInteger
per-pageItems per pageInteger
sort-byField to sort byString
sort-directionSorting direction (asc or desc)String

Successful Response:

Paginated list of Relationship objects.

Get Relationship Summary

Retrieves a summary of relationships with advanced filtering and grouping options.

GET /v1/relationships-summary

Query Parameters:

ParameterDescriptionType
borrower-idFilter by borrower IDString
pagePage numberInteger
per-pageItems per pageInteger
personaFilter by person typeString
sort-byField to sort byString
sort-directionSorting direction (asc or desc)String

Successful Response:

Summary of relationships according to specified criteria.

Error Handling

The API may return the following error codes:

CodeDescription
400Bad Request
401Unauthorized
403Forbidden
404Not Found
500Internal Server Error

Errors will include a descriptive message in the response body.

On this page