Frontend API Change Impact Guide

This guide summarizes what frontend consumers need to change after recent pricing/import updates.

Scope

Applies to:


1) Pricing API updates

1.1 Admin vs Customer write endpoints

Use separate endpoints for pricing-selection save:

Both return pricing response in the same shape as GET /v1/itinerary/:id/price-details.

1.2 Category values

Category fields are numeric enum values (not string labels):

1.3 Slab banding rule

Vehicle slab auto-selection uses adults + children (infants excluded):

1.4 defaultHotelCategory removed

1.5 Markup source changed


2) Import Full Itinerary payload updates

Endpoint: POST /v1/itinerary/import-itinerary-full

2.1 Inventory references

Use IDs only:

Do not send old hotels[] / transfers[] create-resolve payloads.

2.2 Activities

activities[] are created and mapped day-wise.

Required fields per item:

Optional fields:

2.3 Hotel day-wise mapping

Explicit mapping supported via:

Validation:

Backward compatibility:

2.4 Transfer mapping


3) Inventory APIs response enrichments

3.1 Hotel inventory responses (import-related)

For check-inventory, search-inventory, and inventory responses, hotel objects now include:

POST /v1/hotel/check-inventory also returns:

3.2 Transfer inventory responses (import-related)

For check-by-name, search, and inventory responses, transfer objects now include:

POST /v1/transfer/check-by-name request is bulk:

{ "items": [{ "name": "Wagon R / Similar" }, { "name": "Innova / Similar" }] }

Response includes requestedName per item.


4) Existing GET APIs and break-risk

The following endpoints are not route-changed by these updates:

Potential response/data adjustments frontend should tolerate:


5) Markup management APIs (admin)

Base: /v1/markup

Behavior rules:

5.1 Create specific-trip markup

POST /v1/markup

{
  "name": "Summer promo - selected trips",
  "isGlobal": false,
  "itineraryIds": [948, 950, 958],
  "type": 2,
  "amount": 7.5,
  "notes": "Percentage markup for selected trips",
  "isActive": true
}

5.2 Create all-trips markup

POST /v1/markup

{
  "name": "Default all-trips fallback",
  "isGlobal": true,
  "type": 1,
  "amount": 1200,
  "notes": "Flat fallback markup for all trips",
  "isActive": true
}

5.3 Update markup

PUT /v1/markup/:id

{
  "name": "Summer promo - revised",
  "isActive": true,
  "type": 2,
  "amount": 8.25,
  "notes": "Revised percentage",
  "addItineraryIds": [970],
  "removeItineraryIds": [950]
}

5.4 Normalized list/detail response (appliesTo)

{
  "id": 12,
  "name": "Summer promo - revised",
  "isGlobal": false,
  "type": 2,
  "amount": "8.25",
  "isActive": true,
  "appliesTo": {
    "type": "SPECIFIC_TRIPS",
    "tripIds": [948, 958, 970],
    "trips": [
      { "id": 948, "name": "Sikkim Delight" },
      { "id": 958, "name": "North East Premium" },
      { "id": 970, "name": "Bhutan Escape" }
    ]
  }
}

For all-trips markup:

{
  "appliesTo": {
    "type": "ALL_TRIPS",
    "tripIds": [],
    "trips": []
  }
}

6) Frontend checklist