# Actualizar propiedad

PATCH `https://api.bydomu.com/v1/properties/{id}`

Actualiza solo los campos enviados. Cambiar `price` o `status` emite los eventos de dominio correspondientes (`property.price_changed`, `property.status_changed`).

Permiso que pide

`properties:write`

Encabezado obligatorio

`X-API-Key` · clave secreta

Nivel de acceso

Nivel 3 · con revisión de soporte

## Parámetros de ruta

1 · obligatorios

`id` string · **obligatorio**

ID de la propiedad

## Encabezados

1 · todos opcionales

`Idempotency-Key` string · opcional

Clave única de la operación (8-128 caracteres de `[a-zA-Z0-9._:-]`). Un reintento con la misma clave y el mismo cuerpo devuelve la respuesta original sin repetir la operación. Vive 24 horas. 8–128 chars

## Cuerpo (JSON)

56 · todos opcionales

`title` string · opcional

5–200 chars

`type` string · opcional

APARTMENT · HOUSE · OFFICE · COMMERCIAL · LAND · WAREHOUSE · ROOM · FARM · OTHER

`transactionType` string · opcional

SALE · RENT · SALE_OR_RENT

`rentalServiceType` string · opcional

BROKERAGE · MANAGEMENT · nullable

`address` string · opcional

≤ 300 chars

`neighborhood` string · opcional

≤ 100 chars

**Ver los otros 50 parámetros**

`city` string · opcional

2–100 chars

`state` string · opcional

≤ 100 chars

`country` string · opcional

por defecto "CO"

`zipCode` string · opcional

≤ 20 chars

`latitude` number · opcional

-90–90 · nullable

`longitude` number · opcional

-180–180 · nullable

`locationPrecision` string · opcional

EXACT · APPROXIMATE

`price` number · opcional

≥ 0

`currency` string · opcional

COP · USD · EUR · MXN · BRL · ARS · BOB · CAD · CLP · CRC · CUP · DOP · GBP · GTQ · HNL · NIO · PEN · PYG · UYU · VES · por defecto "COP"

`rentPrice` number · opcional

≥ 0 · nullable

`adminFee` number · opcional

≥ 0 · nullable

`securityDeposit` number · opcional

≥ 0 · nullable

`bedrooms` integer · opcional

≥ 0 · nullable

`bathrooms` integer · opcional

≥ 0 · nullable

`halfBathrooms` integer · opcional

≥ 0 · nullable

`totalRooms` integer · opcional

≥ 0 · nullable

`closets` integer · opcional

≥ 0 · nullable

`parkingSpots` integer · opcional

≥ 0 · nullable

`area` number · opcional

≥ 0 · nullable

`builtArea` number · opcional

≥ 0 · nullable

`privateArea` number · opcional

≥ 0 · nullable

`floor` integer · opcional

nullable

`totalFloors` integer · opcional

≥ 0 · nullable

`yearBuilt` integer · opcional

1900–2035 · nullable

`stratum` integer · opcional

1–6 · nullable

`elevator` boolean · opcional

`furnished` string · opcional

UNFURNISHED · SEMI_FURNISHED · FURNISHED · nullable

`orientation` string · opcional

NORTH · SOUTH · EAST · WEST · NORTHEAST · NORTHWEST · SOUTHEAST · SOUTHWEST · nullable

`petFriendly` boolean · opcional

`garageType` string · opcional

NONE · COVERED · UNCOVERED · DOUBLE · UNDERGROUND · nullable

`heatingType` string · opcional

NONE · CENTRAL · ELECTRIC · GAS · RADIANT · nullable

`waterHeater` boolean · opcional

`gasConnection` boolean · opcional

`viewType` string · opcional

NONE · CITY · MOUNTAIN · SEA · GARDEN · POOL · INTERIOR · PANORAMIC · nullable

`securityLevel` string · opcional

NONE · BASIC · MEDIUM · HIGH · GATED_COMMUNITY · nullable

`propertyCondition` string · opcional

NEW · EXCELLENT · GOOD · FAIR · NEEDS_RENOVATION · UNDER_CONSTRUCTION · PRE_SALE · nullable

`legalStatus` string · opcional

CLEAR · MORTGAGE · LIEN · IN_PROCESS · INHERITANCE · nullable

`amenities` string[] · opcional

`customFields` object · opcional

`description` string · opcional

≤ 5000 chars

`virtualTourUrl` string | string · opcional

`tour3dUrl` string | string · opcional

`videoUrl` string | string · opcional

`internalNotes` string · opcional

≤ 2000 chars

`status` string · opcional

DRAFT · ACTIVE · RESERVED · SOLD · RENTED · INACTIVE · por defecto "DRAFT"

`agentId` string · opcional

`contactOwnerId` string · opcional

nullable

`ownerWhatsappConsent` boolean · opcional

`isFeatured` boolean · opcional

`images` object[] · opcional

## Respuesta 200

`PropertyRecord` · 51 campos

**`data` Propiedad del CRM tal como queda al crearla o actualizarla.**

`id` string

`code` string Código legible de la propiedad

`title` string

`description` string

`type` string APARTMENT, HOUSE, OFFICE, COMMERCIAL, LAND, WAREHOUSE

`transactionType` string SALE, RENT, SALE_OR_RENT

`rentalServiceType` string BROKERAGE, MANAGEMENT

`status` string DRAFT, ACTIVE, RESERVED, SOLD, RENTED, INACTIVE

`price` string Precio de venta, o canon si es solo arriendo. Número decimal serializado como texto.

`rentPrice` string Canon mensual, solo en SALE_OR_RENT. Número decimal serializado como texto.

`currency` string

`adminFee` string Administración mensual. Número decimal serializado como texto.

`securityDeposit` string Número decimal serializado como texto.

`neighborhood` string

`city` string

`state` string

`country` string

`bedrooms` integer

`bathrooms` integer

`halfBathrooms` integer

`parkingSpots` integer

`area` number Área en m²

`builtArea` number Área construida en m²

`floor` integer

`stratum` integer Estrato socioeconómico (1-6)

`yearBuilt` integer

`elevator` boolean

`petFriendly` boolean

`furnished` string UNFURNISHED, SEMI_FURNISHED, FURNISHED

`amenities` any IDs de amenidades

`virtualTourUrl` string

`videoUrl` string

`tour3dUrl` string

`isFeatured` boolean

`viewCount` integer

`agentId` string

`createdAt` string

`updatedAt` string

`address` string

`latitude` number

`longitude` number

`locationPrecision` string EXACT, APPROXIMATE

`internalNotes` string Notas internas: solo en el CRM

`customFields` any Campos personalizados

`publishToPortal` boolean

`contactOwnerId` string Propietario (contacto)

**`images[]` id · url · thumbUrl · order · isPrimary · caption · isVirtualStaging · propertyId**

`id` string

`url` string

`thumbUrl` string

`order` integer

`isPrimary` boolean

`caption` string

`isVirtualStaging` boolean

`propertyId` string

**`tourScenes[]` id · imageUrl · thumbUrl · label · order**

`id` string

`imageUrl` string

`thumbUrl` string

`label` string

`order` integer

**`agent` id · firstName · lastName · email**

`id` string

`firstName` string

`lastName` string

`email` string

**`contactOwner` id · firstName · lastName · phone · email · type · documentType · documentNumber**

`id` string

`firstName` string

`lastName` string

`phone` string `null` si el contacto llegó por un canal sin número (Instagram, Facebook, chat de la web, correo o WhatsApp con usuario y número oculto)

`email` string

`type` string CLIENT, OWNER, BOTH

`documentType` string CC, CE, NIT, PASSPORT, DNI, RUC

`documentNumber` string

**`tags[]` propertyId · tagId · tag**

`propertyId` string

`tagId` string

**`tag` id · name · color**

`id` string

`name` string

`color` string

## Errores posibles

con la forma `{ "error": { "code", "message" } }`

- **400** Datos inválidos: el cuerpo o la query no cumplen el esquema, o `Idempotency-Key` está mal formada.
- **401** UNAUTHORIZED
- **402** PAYMENT_REQUIRED
- **403** FORBIDDEN
- **404** NOT_FOUND
- **409** DUPLICATE
- **429** RATE_LIMITED
- **500** INTERNAL_ERROR

cURL:

```bash
curl -X PATCH "https://api.bydomu.com/v1/properties/clx1prop001" \
  -H "X-API-Key: $BYDOMU_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "price": 430000000,
  "status": "ACTIVE"
}'
```

JavaScript:

```js
import { ByDomu } from "@bydomu/sdk";

const bydomu = new ByDomu({
  apiKey: process.env.BYDOMU_API_KEY,
});

const { data } = await bydomu.properties.update("clx1prop001", {
  "price": 430000000,
  "status": "ACTIVE"
});
```

Python:

```python
import os, requests

r = requests.patch(
    "https://api.bydomu.com/v1/properties/clx1prop001",
    headers={"X-API-Key": os.environ["BYDOMU_API_KEY"]},
    json={
        "price": 430000000,
        "status": "ACTIVE"
    }
)
data = r.json()
```

**Respuesta · 200 · ejemplo**

```json
{
  "data": {
    "id": "clx1prop001",
    "code": "P-0042",
    "title": "Apartamento en Chapinero con vista",
    "description": "Apartamento de 85 m² con balcón y vista a los cerros.",
    "type": "APARTMENT",
    "transactionType": "SALE",
    "rentalServiceType": "BROKERAGE",
    "status": "DRAFT",
    "price": "450000000.00",
    "rentPrice": "3500000.00",
    "currency": "COP",
    "adminFee": "380000.00",
    "securityDeposit": "3500000.00",
    "neighborhood": "Chapinero",
    "city": "Bogotá",
    "state": "Cundinamarca",
    "country": "CO",
    "bedrooms": 3,
    "bathrooms": 2,
    "halfBathrooms": 1,
    "parkingSpots": 1,
    "area": 85,
    "builtArea": 80,
    "floor": 8,
    "stratum": 4,
    "yearBuilt": 2015,
    "elevator": true,
    "petFriendly": true,
    "furnished": "UNFURNISHED",
    "amenities": [
      "pool"
    ],
    "virtualTourUrl": "https://my.matterport.com/show/?m=abc123",
    "videoUrl": "https://youtu.be/abc123",
    "tour3dUrl": "https://cdn.bydomu.com/tours/clx1prop001/model.splat",
    "isFeatured": false,
    "viewCount": 128,
    "agentId": "clx1usr001",
    "createdAt": "2026-08-01T14:30:00.000Z",
    "updatedAt": "2026-09-20T10:00:00.000Z",
    "address": "Cra 7 #45-12",
    "latitude": 4.648625,
    "longitude": -74.062815,
    "locationPrecision": "EXACT",
    "internalNotes": "Llaves en portería.",
    "customFields": {},
    "publishToPortal": true,
    "contactOwnerId": "clx1con007",
    "images": [
      {
        "id": "clx1img001",
        "url": "https://cdn.bydomu.com/props/clx1prop001/1.jpg",
        "thumbUrl": "https://cdn.bydomu.com/props/clx1prop001/1-thumb.jpg",
        "order": 0,
        "isPrimary": true,
        "caption": "Sala comedor",
        "isVirtualStaging": false,
        "propertyId": "clx1prop001"
  …
```
