此為系統自動產生的翻譯

內容 API

取得租車據點及供應商的參考資料

簡介

使用 Content API 透過 Rapid 租車 API 及租車據點資料,查詢可用的供應商資訊,包括完整地址、地圖座標、聯絡資訊等。您可以利用這些資料來建立位置搜尋功能,或在購物流程中保留受支援位置的本地副本,無論是在查詢庫存前,還是與庫存查詢無關的情況下皆可。

呼叫 Locations 端點

「地點」端點會回傳單一國家內的租車據點。每個地點均隸屬於一名供應商,並包含該特定地點的相關資訊。

注意: 您必須包含country_code,且該網址必須為 two-letter 格式的 ISO 3166-1 字母代碼,例如CA 或 US。

使用位置資料

自 2027 年起,您將使用「region_id」(Rapid Geography API 識別碼) ,據此將地點按地區進行分組。

在此之前,您可以透過以下方式取得位置資料:

  • type: 說明租車櫃檯的所在地點
  • nearest_airport:three-letter 租車地點附近機場的 IATA 代碼

注意: 像email 和postal_code 這樣的選填欄位,並非每個地點都會顯示。

範例請求

GET https://api.ean.com/v2/cars/locations?country_code=US&vendor_id=US&vendor_id=NU

範例回應

[
  {
    "vendor": {
      "id": "US",
      "name": "U-Save Car Rental"
    },
    "nearest_airport": "SAN",
    "region_id": "5128531",
    "type": "off_terminal",
    "name": "San Diego Airport",
    "address": {
      "line_1": "2263 Pacific Highway",
      "city": "San Diego",
      "state_province_name": "California",
      "postal_code": "92101",
      "country_code": "US"
    },
    "coordinates": {
      "latitude": 32.72762,
      "longitude": -117.1724
    }
  },
  {
    "vendor": {
      "id": "NU",
      "name": "NÜ Car Rentals"
    },
    "nearest_airport": "OGG",
    "region_id": "4671311",
    "type": "city_center",
    "name": "Nu Car Rentals - Kihei Ma",
    "address": {
      "line_1": "177 Halekaui St Kihei, Maui",
      "city": "Kihei",
      "state_province_name": "Hawaii",
      "postal_code": "96753",
      "country_code": "US"
    },
    "coordinates": {
      "latitude": 20.77851,
      "longitude": -156.44787
    }
  }
]

呼叫「Vendors」端點

「供應商」端點會回傳可透過 Rapid 租車 API 存取的租車供應商清單。每個供應商記錄都包含一個識別碼 (vendor_id) 和一個名稱 (vendor_name)。使用此 ID 來篩選其他請求,例如「購物」請求或「內容位置」請求。

若要僅取得特定供應商,請在請求中加入vendor_id。您可以重複指定此參數,以包含多個供應商。若不指定,則會回傳所有供應商。

範例請求

GET https://api.ean.com/v2/cars/vendors?vendor_id=AL

範例回應

[
  {
    "id": "AL",
    "name": "Alamo Rent A Car"
  }
]

API 詳細資料

在這個頁面上探索內容相關端點的定義,然後使用 API Explorer 或其他測試軟體,了解範例和結構描述定義與實際輸出的比較。

其他資源

無論您是想試用所有 Rapid 租車 API 端點,還是想下載其 OpenAPI 規格,我們都能滿足您的需求。





這個頁面對您有幫助嗎?
我們能如何改善內容?
感謝您協助我們進行改善!