Impact Migration of POST/v2/proposals/{proposal_id}/alternative_transports to POST /v0/proposals/{proposal_id}/available_transports

  • Outdated
  • May 1, 2025
  • 1 related route

Upgrade from POST/v2/proposals/{proposal_id}/alternative_transports to POST /v0/proposals/{proposal_id}/available_transports

POST /v0/proposals/{proposal_id}/available_transports endpoint body is exactly the same as POST/v2/proposals/{proposal_id}/alternative_transports.

ℹ️ In the Response -> a new boolean has been added "is_applied_transportation"

⚠️ This new endpoint will always retrieve the proposal's already applied transportation in addition to alternative transports available.

Impacts

Call POST/v0/proposals/{proposal_id}/available_transports instead of POST/v2/proposals/{proposal_id}/alternative_transports

Output

[
  {
    "id": "73a6b:9ab5d",
+  "is_applied_transportation": true, 
    "price": {
      "amount": 0,
      "currency": "EUR"
    },
    "total_differential_price": {
      "amount": -200.5,
      "currency": "EUR",
      "is_best_differential_price": true
    },
    "journeys": [
      {
        "way": "INBOUND",
        "total_duration_in_min": 745,
        "travel_sections": [
          {
            "departure": {
              "city": {
                "id": "PAR",
                "label": "PARIS"
              },
              "date": "20160812",
              "time": "17:00:00",
              "location": {
                "id": "CDG",
                "label": "PARIS-ROISSY CDG",
                "terminal_code": "2A"
              }
            },
            "arrival": {
              "city": {
                "id": "PAR",
                "label": "PARIS"
              },
              "date": "20160812",
              "time": "17:00:00",
              "location": {
                "id": "CDG",
                "label": "PARIS-ROISSY CDG",
                "terminal_code": "2A"
              }
            },
            "transport": {
              "type": "PLANE",
              "class": "PLANE_ECONOMY",
              "company": {
                "operator": {
                  "id": "SQ",
                  "label": "SINGAPORE AIRLINES",
                  "logo": "http://www.airfrance.fr/logo",
                  "_links": [
                    {
                      "rel": "self",
                      "method": "GET",
                      "href": "https://api.clubmed.com/products",
                      "label": "A label"
                    }
                  ]
                },
                "exploiter": {
                  "id": "SQ",
                  "label": "SINGAPORE AIRLINES",
                  "logo": "http://www.airfrance.fr/logo",
                  "_links": [
                    {
                      "rel": "self",
                      "method": "GET",
                      "href": "https://api.clubmed.com/products",
                      "label": "A label"
                    }
                  ]
                }
              },
              "travel_number": "SQ1234",
              "baggage": {
                "quantity": 2,
                "weight": "23kg"
              },
              "vehicle_type": "BOEING 747",
              "fare_class": "U"
            },
            "technical_stops": 0,
            "connection_duration_in_min": 130,
            "stopover_duration_in_min": 130,
            "duration_in_min": 250,
            "clubmed_transport": false,
            "flight_code": "THEO9E",
            "cancellation_policy_type": "THEO"
          }
        ]
      }
    ]
  }
]

Model

Champ APITypeDescriptionExemple
is_applied_transportationBooléenIndicates if the retrieved transport is the one which is already applied to the proposal or notTrue