GOCheap Developers

Báo giá

POST
/quotes

Tính giá theo bảng giá GOCheap (dịch vụ, khu vực, quãng đường, khung giờ). Báo giá có hiệu lực 10 phút; tạo chuyến bằng quote_id sẽ giữ đúng giá này.

Authorization

ApiKeyAuth
headerAuthorization<token>

Authorization: ApiKey <key>. Key sandbox bắt đầu bằng gc_test_, production bằng gc_live_. Key chỉ hiện một lần lúc tạo. Không dùng key trong app di động hay trình duyệt.

Request Body

application/json
  1. body
service*ServiceId
  • thue-tai-xe: lái hộ ô tô
  • lai-ho-xe-may: lái hộ xe máy

Xe sân bay (taxi-san-bay) và xe hợp đồng (xe-hop-dong) sẽ mở ở phiên bản sau.

Value in"thue-tai-xe""lai-ho-xe-may"
pick_up*|

Gửi place_id (từ /places/search) hoặc bộ lat, lng, address.

destination*|

Gửi place_id (từ /places/search) hoặc bộ lat, lng, address.

pick_up_time?string

Bỏ trống là đi ngay (đón sau 20 phút).

Formatdate-time
ways?Ways
Default"one_way"
Value in"one_way""two_way"

Response Body

OK

application/json
  1. response
success*boolean
data*
Example Request
curl -X POST 'https://api-stag.gocheap.vn/open-api/v1/quotes' \  -H 'Content-Type: application/json' \  -d '{  "service": "thue-tai-xe",  "pick_up": {    "place_id": "ChIJ0T2NLikpdTERKxE8d61aX_E"  },  "destination": {    "lat": 21.0285,    "lng": 105.8542,    "address": "Hoàn Kiếm, Hà Nội"  },  "pick_up_time": "2026-11-12T19:30:00+07:00"}'
Example Response
{  "success": true,  "data": {    "quote_id": "qt_7Hc2kP9xLm",    "service": "thue-tai-xe",    "pick_up": {      "place_id": "ChIJ0T2NLikpdTERKxE8d61aX_E",      "name": "Sân bay Quốc tế Nội Bài",      "address": "Phú Minh, Sóc Sơn, Hà Nội",      "lat": 21.2187,      "lng": 105.8042    },    "destination": {      "place_id": null,      "name": null,      "address": "Hoàn Kiếm, Hà Nội",      "lat": 21.0285,      "lng": 105.8542    },    "pick_up_time": "2026-11-12T19:30:00+07:00",    "ways": "one_way",    "distance_m": 27450,    "duration_s": 2280,    "price": 385000,    "currency": "VND",    "expires_at": "2026-11-12T19:10:00+07:00"  }}