Skip to main content

Listings & Properties Admin API


Listings

Base path: /api/v1/admin/listings or /api/v1/pms/listings

List Listings

GET /api/v1/admin/listings
[
{
"id": "lst_abc",
"title": "Ocean View Villa",
"city": "Goa",
"state": "Goa",
"status": "ACTIVE",
"maxAdults": 8,
"propertyCount": 3
}
]

Create Listing

POST /api/v1/admin/listings
{
"id": "lst_new",
"title": "Hilltop Retreat",
"city": "Kasauli",
"state": "Himachal Pradesh",
"country": "India",
"locality": "Chattyan",
"latitude": 30.89,
"longitude": 76.96,
"status": "ACTIVE"
}

Update / Delete

PUT /api/v1/admin/listings/{id}
DELETE /api/v1/admin/listings/{id}

Add / Remove Property from Listing

POST /api/v1/admin/listings/{listingId}/properties/{propertyId}
DELETE /api/v1/admin/listings/{listingId}/properties/{propertyId}

Listing Sync

POST /api/v1/admin/listings/sync

Syncs all listings from channel manager. Returns sync summary.


Properties

Search Properties

GET /api/v1/admin/properties/search?city=Goa&adults=4&isPetFriendly=true
[
{
"id": "prop_1",
"name": "Deluxe Room",
"city": "Goa",
"type": "Villa",
"maxAdults": 4,
"price": 8500,
"isPetFriendly": true
}
]

Property Embeddings

Base path: /api/v1/admin/embeddings

Generate All Embeddings

POST /api/v1/admin/embeddings/generate

Generates vector embeddings for all active properties using text-embedding-3-small. Stores in property_embedding table for AI search.

Generate for Single Property

POST /api/v1/admin/embeddings/property/{propertyId}

Reindex All

POST /api/v1/admin/embeddings/reindex

Channels

Base path: /api/v1/admin/channels

List Channels

GET /api/v1/admin/channels
[
{
"channelId": "B2C",
"channelName": "Website",
"multiplier": 1.0
},
{
"channelId": "B2B",
"channelName": "Corporate",
"multiplier": 0.9
}
]

Clone Channel

POST /api/v1/admin/channels/{sourceChannelId}/clone

Clones a channel with all offer mappings (promotions, bank offers, cancellation plans, meals, VAS).


Listing Channel Promotions

Export as CSV

GET /api/v1/admin/listing-channel-promotions/export

Import from CSV

POST /api/v1/admin/listing-channel-promotions/upload-csv
Content-Type: multipart/form-data

Bulk Upsert

POST /api/v1/admin/listing-channel-promotions/bulk-upsert
[
{ "listingId": "lst_abc", "channelId": "B2C", "promotionId": "promo_1", "isEnabled": true },
{ "listingId": "lst_abc", "channelId": "B2C", "promotionId": "promo_2", "isEnabled": false }
]

Staah Sync

Sync All Properties

POST /api/v1/admin/staah/sync

Sync Single Property

POST /api/v1/admin/staah/sync/{propertyId}