Embargos Integration
note
Content migrating from alianza-hq/backend/karibe/ and database schema
Overview
The embargos integration scrapes and stores lien/embargo records from the Karibe (RIDPR) system. These records are used by CoquiTitle to identify encumbrances on properties during title studies.
Database Schema
Table: ridpr.embargos
| Column | Type | Description |
|---|---|---|
id | UUID | Primary key |
finca_id | String | Property finca identifier |
demarcacion_code | String | Registry demarcation code |
asiento | String | Registry entry number |
creditor | String | Creditor name/entity |
debtor | String | Debtor name/entity |
amount | Decimal | Embargo amount |
currency | String | Currency code (USD, etc.) |
inscription_date | Date | Date inscribed |
status | String | active/released/cancelled |
case_number | String | Legal case number |
court | String | Court name |
created_at | Timestamp | Record creation time |
updated_at | Timestamp | Last update time |
Data Source
Embargos are scraped from the Karibe portal using the document archiver system:
Karibe Portal --> Scraper --> Document Archiver --> S3 + Supabase
Usage in CoquiTitle
During title studies, the evidence gathering phase queries embargos:
SELECT * FROM ridpr.embargos
WHERE finca_id = ?
AND demarcacion_code = ?
AND status = 'active'
ORDER BY inscription_date DESC;
Active embargos are flagged as title defects requiring resolution.