express-bus-booking

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Express Bus Booking (KOBUS)

高速巴士预订(KOBUS)

Overview

概述

Use this skill for Korean 고속버스 / KOBUS timetable lookup and reservation assistance. The preferred workflow is HTTP/API-first: resolve routes, query timetables, inspect remaining seats and fares, and only use browser automation when endpoint discovery or an official web-only step blocks progress.
This skill is intentionally separate from 시외버스. KOBUS terminal codes, route structures, and checkout pages differ from Tmoney 시외버스. Use
intercity-bus-booking
for 시외버스/Tmoney flows.
本技能用于协助查询韩国고속버스/KOBUS的时刻表并完成预订。优先采用HTTP/API优先的工作流程:解析路线、查询时刻表、查看剩余座位及票价,仅在无法发现接口或遇到仅支持网页的官方步骤时,才使用浏览器自动化工具。
本技能特意与시외버스(城际巴士)的技能区分开。KOBUS的终端代码、路线结构及结账页面与Tmoney 시외버斯不同。如需处理시외버스/Tmoney相关流程,请使用
intercity-bus-booking
技能。

When to Use

使用场景

  • The user asks for
    고속버스 예매
    ,
    고속버스 시간표
    ,
    고속버스 예약
    ,
    프리미엄 고속버스
    , or
    우등 고속버스
    .
  • The route is clearly a KOBUS 고속버스 route or the user names KOBUS/코버스/고속버스통합예매.
  • The user wants assisted reservation up to seat selection, temporary hold, or a payment-entry link.
Do not use this for:
  • 시외버스/Tmoney routes — use
    intercity-bus-booking
    .
  • Final card submission or payment without explicit, narrowly scoped confirmation.
  • Blind browser automation before trying the official HTTP flow.
当用户提出以下需求时使用:
  • 用户请求
    고속버스 예매
    (高速巴士预订)、
    고속버스 시간표
    (高速巴士时刻表)、
    고속버스 예약
    (高速巴士预订)、
    프리미엄 고속버스
    (Premium高速巴士)或
    우등 고속버스
    (优等高速巴士)。
  • 路线明确为KOBUS 고속버斯路线,或用户提及KOBUS/코버스/고속버스통합예매(高速巴士统一预订)。
  • 用户需要协助完成预订流程,直至选座、临时锁定座位或获取支付入口链接。
请勿在以下场景使用:
  • 시외버스/Tmoney路线——请使用
    intercity-bus-booking
    技能。
  • 用户未明确、精准确认的情况下,提交银行卡信息或完成支付。
  • 未尝试官方HTTP流程就直接使用浏览器自动化工具。

Core Principles

核心原则

  • Use official KOBUS surfaces:
    https://www.kobus.co.kr
    .
  • Keep a cookie jar and reuse referers. Stateless one-off POSTs are less reliable.
  • Prefer desktop User-Agent and HTTP/1.1 during probing if the server behaves differently under HTTP/2.
  • Default scope is assisted manual checkout: lookup, candidate presentation, seat-stage readiness, temporary seat hold, and official payment-entry page handoff.
  • Do not submit card fields, agree to terms, or complete payment unless the user explicitly confirms that exact action.
  • 使用KOBUS官方平台:
    https://www.kobus.co.kr
  • 保留Cookie罐并复用来源地址(referers)。无状态的单次POST请求可靠性较低。
  • 如果服务器在HTTP/2下表现异常,探测阶段优先使用桌面端User-Agent和HTTP/1.1协议。
  • 默认范围为协助手动结账:查询、展示候选选项、准备选座环节、临时锁定座位,以及跳转至官方支付入口页面。
  • 除非用户明确确认该操作,否则不得提交银行卡信息、同意条款或完成支付。

Known HTTP Flow

已知HTTP流程

See
references/kobus-http-flow.md
for session-proven endpoint details and parameter examples.
会话验证通过的接口详情及参数示例,请查看
references/kobus-http-flow.md

1. Start a Session

1. 启动会话

Fetch either the main page or route/search page with cookies enabled:
text
GET https://www.kobus.co.kr/main.do
GET https://www.kobus.co.kr/mrs/rotinf.do
Use a realistic desktop User-Agent and a cookie jar.
启用Cookie,获取主页或路线/搜索页面:
text
GET https://www.kobus.co.kr/main.do
GET https://www.kobus.co.kr/mrs/rotinf.do
使用真实的桌面端User-Agent及Cookie罐。

2. Resolve Route / Terminal Candidates

2. 解析路线/终端候选选项

text
POST /mrs/readRotLinInf.ajax
The response is JSON and can include
rotInfList
,
tfrInfList
,
len
, and
codeYn
. Prefer code-confirmed routes over display-name matching because terminal names are not always unique.
text
POST /mrs/readRotLinInf.ajax
响应为JSON格式,可能包含
rotInfList
tfrInfList
len
codeYn
。优先选择通过代码确认的路线,而非仅匹配显示名称,因为终端名称并非始终唯一。

3. Query Timetable

3. 查询时刻表

text
POST /mrs/alcnSrch.do
Typical fields include:
text
deprCd=010
arvlCd=700
pathDvs=sngl
pathStep=1
deprDtm=YYYYMMDD
busClsCd=0
rtrpChc=1
timeLinkMin=00
timeLinkMax=23
Parse the returned HTML for schedule rows/cards and
fnSatsChc(...)
onclick arguments. Respect
mrsPsbYn=N
or any equivalent booking-disabled marker.
text
POST /mrs/alcnSrch.do
典型字段包括:
text
deprCd=010
arvlCd=700
pathDvs=sngl
pathStep=1
deprDtm=YYYYMMDD
busClsCd=0
rtrpChc=1
timeLinkMin=00
timeLinkMax=23
解析返回的HTML中的时刻表行/卡片,以及
fnSatsChc(...)
的点击事件参数。注意
mrsPsbYn=N
或任何表示无法预订的标记。

4. Enter Seat / Fare Stage

4. 进入选座/票价环节

text
POST /mrs/satschc.do
Send the original search form fields plus selected values from
fnSatsChc(...)
, commonly including:
text
deprTime
alcnDeprTime
alcnDeprTrmlNo
alcnArvlTrmlNo
indVBusClsCd
cacmCd
dcDvsCd
prvtBbizEmpAcmtRt
chldSftySatsYn
dsprSatsYn
The response should include
form#satsChcFrm
and hidden fare/seat values such as
adltFee
,
rmnSatsNum
,
totSatsNum
, and terminal/time fields.
text
POST /mrs/satschc.do
发送原始搜索表单字段,加上从
fnSatsChc(...)
中选择的值,通常包括:
text
deprTime
alcnDeprTime
alcnDeprTrmlNo
alcnArvlTrmlNo
indVBusClsCd
cacmCd
dcDvsCd
prvtBbizEmpAcmtRt
chldSftySatsYn
dsprSatsYn
响应应包含
form#satsChcFrm
及隐藏的票价/座位字段,例如
adltFee
rmnSatsNum
totSatsNum
以及终端/时间字段。

5. Temporary Seat Hold

5. 临时锁定座位

text
POST /mrs/setPcpy.ajax
Submit the
satsChcFrm
hidden fields plus selected seat/count fields. A successful response includes:
text
MSG_CD=S0000
pcpyNoAll
satsNoAll
ESTM_AMT
DC_AMT
TISSU_AMT
Treat the hold as short-lived. If testing, if the user does not proceed, or if a new seat is chosen, release it explicitly.
text
POST /mrs/setPcpy.ajax
提交
satsChcFrm
的隐藏字段,加上所选的座位/数量字段。成功响应包含:
text
MSG_CD=S0000
pcpyNoAll
satsNoAll
ESTM_AMT
DC_AMT
TISSU_AMT
临时锁定的有效期较短。如果是测试场景、用户未继续操作或选择了新座位,请显式释放锁定。

6. Release Temporary Hold

6. 释放临时锁定

text
POST /mrs/cancPcpy.ajax
Use the same relevant form fields plus the returned
pcpyNoAll
and
satsNoAll
. A successful response returns
MSG_CD=S0000
.
text
POST /mrs/cancPcpy.ajax
使用相关的表单字段,加上返回的
pcpyNoAll
satsNoAll
。成功响应返回
MSG_CD=S0000

Helper Script

辅助脚本

Use the bundled helper for KOBUS lookup and optional temporary holds:
bash
python3 express-bus-booking/scripts/kobus_express_booking.py \
  --depart-code 021 \
  --arrive-code 500 \
  --date 20260520 \
  --select-index 1 \
  --hold-first-seat \
  --output-dir /tmp/kobus-hold
For Seoul to Gwangju, the verified KOBUS route is
센트럴시티(서울)
code
021
to
광주(유·스퀘어)
code
500
. A successful hold returns
MSG_CD=S0000
,
pcpyNoAll
,
satsNoAll
, fare amounts, and saves a local auto-submit helper for the official KOBUS payment-information page. Final card entry and payment remain manual. Cancel abandoned holds with
/mrs/cancPcpy.ajax
using the saved cancel fields.
使用内置辅助脚本进行KOBUS查询及可选的临时锁定:
bash
python3 express-bus-booking/scripts/kobus_express_booking.py \
  --depart-code 021 \
  --arrive-code 500 \
  --date 20260520 \
  --select-index 1 \
  --hold-first-seat \
  --output-dir /tmp/kobus-hold
首尔至光州的已验证KOBUS路线为
센트럴시티(서울)
(代码
021
)至
광주(유·스퀘어)
(代码
500
)。成功锁定后会返回
MSG_CD=S0000
pcpyNoAll
satsNoAll
、票价金额,并保存一个本地自动提交辅助工具,用于跳转至KOBUS官方支付信息页面。最终的银行卡信息录入及支付仍需手动完成。使用保存的取消字段,通过
/mrs/cancPcpy.ajax
取消已废弃的锁定。

Checkout-Entry Link Helper

结账入口链接辅助工具

A plain official checkout URL is not enough because KOBUS expects a POST body containing the selected schedule, seat, fare, and hold identifiers. The practical user-facing pattern is:
  1. Create the temporary hold server-side via
    setPcpy.ajax
    .
  2. Generate a short helper page that auto-submits a POST form to the official KOBUS checkout endpoint.
  3. Send the helper link to the user.
  4. The user completes card/payment fields manually on the official KOBUS page.
Desktop action:
text
https://www.kobus.co.kr/mrs/stplcfmpym.do
Mobile-friendly action:
text
https://www.kobus.co.kr/mrs/stplcfmpym.do?keep=/mrs/pay
The POST body should include the original seat form fields plus returned hold values such as
pcpyNoAll
,
satsNoAll
,
estmAmt
,
dcAmt
,
tissuAmt
, and
nonMbrsYn=Y
when using a non-member checkout flow.
单纯的官方结账链接并不足够,因为KOBUS要求POST请求体包含所选的时刻表、座位、票价及锁定标识。实用的用户操作流程如下:
  1. 通过
    setPcpy.ajax
    在服务器端创建临时锁定。
  2. 生成一个简易辅助页面,自动提交POST表单至KOBUS官方结账接口。
  3. 将辅助链接发送给用户。
  4. 用户在KOBUS官方页面手动完成银行卡/支付信息录入。
桌面端入口:
text
https://www.kobus.co.kr/mrs/stplcfmpym.do
移动端友好入口:
text
https://www.kobus.co.kr/mrs/stplcfmpym.do?keep=/mrs/pay
POST请求体应包含原始座位表单字段,加上返回的锁定值,例如
pcpyNoAll
satsNoAll
estmAmt
dcAmt
tissuAmt
,以及使用非会员结账流程时的
nonMbrsYn=Y

Mobile Redirect Caveat

移动端重定向注意事项

KOBUS common JavaScript can redirect narrow/mobile screens to
/mblIdx.do
unless
location.href
contains a mobile-allowed path fragment such as
/mrs/pay
. In testing, posting to:
text
/mrs/stplcfmpym.do?keep=/mrs/pay
preserved the same checkout POST body while making the final browser URL contain
/mrs/pay
, avoiding the client-side mobile-main redirect condition. Use this variant for Discord/mobile users, but still verify with the user because in-app browsers may add their own quirks.
If mobile still lands on the homepage, recommend opening the helper link in a normal external browser or desktop browser. Do not keep retrying holds indefinitely; cancel stale holds.
KOBUS通用JavaScript会将窄屏/移动端页面重定向至
/mblIdx.do
,除非
location.href
包含允许移动端访问的路径片段,例如
/mrs/pay
。测试中,提交至:
text
/mrs/stplcfmpym.do?keep=/mrs/pay
可保留相同的结账POST请求体,同时使最终浏览器URL包含
/mrs/pay
,避免客户端重定向至移动端主页。针对Discord/移动端用户使用该变体,但仍需与用户确认,因为内嵌浏览器可能存在特殊问题。
如果移动端仍跳转至主页,建议用户在普通外部浏览器或桌面浏览器中打开辅助链接。请勿无限次重试锁定;取消过期的锁定。

Suggested Output Format

建议输出格式

Keep candidate lists concise and actionable:
text
고속버스 서울경부 → 부산 / 2026-05-09
1. 00:30 심야우등 / 천일고속 / 잔여 10석 / 성인 47,600원
2. 13:50 우등 / ...
When a hold/checkout helper is created, state that the next step opens the official KOBUS payment page and that payment remains manual.
For Discord/mobile, provide links as normal text links, not fenced code blocks, so the user can tap them directly.
候选列表应简洁且具有可操作性:
text
고속버스 서울경부 → 부산 / 2026-05-09
1. 00:30 심야우등 / 천일고속 / 잔여 10석 / 성인 47,600원
2. 13:50 우등 / ...
当创建锁定/结账辅助工具时,需说明下一步将打开KOBUS官方支付页面,且支付仍需手动完成。
针对Discord/移动端用户,链接以普通文本形式提供,而非代码块,方便用户直接点击。

Common Pitfalls

常见陷阱

  1. Mixing KOBUS and Tmoney codes. KOBUS terminal codes are not Tmoney 시외버스 terminal codes.
  2. Assuming a cart exists. KOBUS does not expose a shopping-cart style hold list in the tested web flow. The realistic UX is temporary seat hold plus checkout-entry handoff.
  3. Ignoring hold cleanup. Always cancel test holds or abandoned holds with
    cancPcpy.ajax
    .
  4. Treating lookup success as payment permission. Lookup, seat-stage entry, and temporary hold are not authorization to submit payment.
  5. Mobile homepage redirects. Use the
    ?keep=/mrs/pay
    helper action for mobile; otherwise KOBUS JS may send the user to
    /mblIdx.do
    .
  6. Browser automation too early. Try direct HTTP first. Use browser tooling only to discover changed endpoints or verify final user-facing behavior.
  1. 混淆KOBUS与Tmoney代码:KOBUS的终端代码与Tmoney 시외버斯的终端代码不同。
  2. 假设存在购物车:在测试的Web流程中,KOBUS未提供购物车样式的锁定列表。实际用户体验为临时锁定座位加结账入口交接。
  3. 忽略锁定清理:务必使用
    cancPcpy.ajax
    取消测试锁定或已废弃的锁定。
  4. 将查询成功视为支付权限:查询、进入选座环节及临时锁定并不代表获得提交支付的授权。
  5. 移动端主页重定向:针对移动端用户使用
    ?keep=/mrs/pay
    辅助入口;否则KOBUS的JS可能将用户跳转至
    /mblIdx.do
  6. 过早使用浏览器自动化:先尝试直接HTTP请求。仅在发现接口变更或验证最终用户行为时,才使用浏览器工具。

Verification Checklist

验证清单

  • Route/terminal codes were resolved from KOBUS, not guessed.
  • Timetable was queried with cookies and a realistic User-Agent.
  • Candidate output includes date, departure/arrival terminals, time, class/operator when available, fare, and remaining seats.
  • Seat-stage response contains expected hidden fields before attempting a hold.
  • Temporary hold success was confirmed with
    MSG_CD=S0000
    before sending a checkout helper link.
  • Stale/test holds were cancelled with
    cancPcpy.ajax
    .
  • Payment/card fields were left for the user unless they explicitly confirmed otherwise.
  • Mobile helper links use the
    /mrs/pay
    marker variant when sent to mobile-heavy platforms.
  • 路线/终端代码来自KOBUS,而非猜测。
  • 查询时刻表时使用了Cookie及真实的User-Agent。
  • 候选输出包含日期、出发/到达终端、时间、可用的车型/运营商、票价及剩余座位。
  • 在尝试锁定座位前,选座环节响应包含预期的隐藏字段。
  • 确认临时锁定成功(
    MSG_CD=S0000
    )后,再发送结账辅助链接。
  • 使用
    cancPcpy.ajax
    取消过期/测试锁定。
  • 除非用户明确确认,否则将支付/银行卡信息录入环节留给用户完成。
  • 针对移动端占比高的平台,使用包含
    /mrs/pay
    标记的辅助链接变体。