> For the complete documentation index, see [llms.txt](https://resources.atriptech.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://resources.atriptech.com/api-wen-dang/readme/yu-ding-liu-cheng-gai-lan/zuo-wei.md).

# 座位

{% hint style="info" %}
遇到 API 接入问题时，可登录 [Eva](https://www.atriptech.com/) 寻求帮助。
{% endhint %}

在支持的预订链路中，优先接入 Atlas 选座服务。

预订中选座能提升用户确认意愿。

它也能减少因座位不确定带来的流失。

{% hint style="warning" %}
`seatAvailability.do` 需要有效交易上下文。

标准搜索链路使用 `verify.do` 返回的 `sessionId`。

Get Offer 链路使用 `getOffers.do` 返回的 `offerId`。

不支持仅凭航班信息查询座位。
{% endhint %}

### 为什么推荐接入

* 在下单前展示真实座位图和价格
* 让用户在预订阶段完成座位决策
* 提高同行旅客和家庭旅客的下单确认率

### 什么时候使用

适合这些场景：

* 航司支持 Atlas API 选座能力
* 订单由 Atlas 出票
* 需要在下单前展示座位图并完成选座

### 主要 API

* `seatAvailability.do`

### 推荐流程

{% stepper %}
{% step %}

### 获取当前交易上下文

标准搜索链路先调用 `verify.do`。

Get Offer 链路先调用 `getOffers.do`。
{% endstep %}

{% step %}

### 查询座位图

调用 `seatAvailability.do`。

向用户展示可选座位和对应价格。
{% endstep %}

{% step %}

### 下单时提交座位

在 `order.do` 中提交已选座位对应的 `productCode`。
{% endstep %}
{% endstepper %}

### 调用规则

* `seatAvailability.do` 只支持交易绑定请求
* 可用标识只有 `sessionId` 或 `offerId`
* `Independent mode` 已下线
* 不支持 flight-only seat quote

如果上游只传来航班信息，没有 `sessionId`：

* 先缓存 `verify.do` 返回的 `sessionId`
* 再把上游航班映射到该 `sessionId`
* 如果无法匹配，不要发送 flight-only 的 `seatAvailability.do` 请求

### 最佳实践

* 行程确认后尽快展示座位图
* 使用当前有效的 `sessionId` 或 `offerId` 发起选座请求
* 在 `order.do` 前保持所选座位与当前预订上下文一致
* 把预订中选座作为支持场景下的标准预订能力

### 选座履约异常处理

如果下单时所选座位已被占用，可在 `order.do` 通过 `ifSeatOccupied` 指定处理模式。

* `STOP_TICKET`：不出票，整单取消退款
* `STOP_SEAT`：继续出票，退选座
* `SIMILAR_SEAT`：改选相似座位

建议在 `order.do` 显式传入 `ifSeatOccupied`。

相似座位匹配规则不在此页定义。

未能自动完成时，会转人工处理。

### 不支持的场景

* 非 Atlas 出票订单
* 出票后选座

### 相关页面

* [验价](/api-wen-dang/readme/yu-ding-liu-cheng-gai-lan/yan-jia.md)
* [创建订单](/api-wen-dang/readme/yu-ding-liu-cheng-gai-lan/chuang-jian-ding-dan.md)
* [出票后附加服务](/api-wen-dang/readme/yu-ding-hou-gai-lan/yu-ding-hou-cao-zuo/chu-piao-hou-fu-jia-fu-wu.md)

### 完整 API 参考

接口级详情见：

[预订中座位与行李](/api-wen-dang/api-can-kao/yu-ding-api/yu-ding-zhong-zuo-wei-yu-xing-li.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://resources.atriptech.com/api-wen-dang/readme/yu-ding-liu-cheng-gai-lan/zuo-wei.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
