# Travel Query

> 查询火车、高铁、动车票务信息。支持车次查询、余票查询、站点信息获取。适用于用户询问出行方案、票价、时刻表等场景。

- **Type:** Skill
- **Install:** `agentstack add skill-shihan-1147-skillmcp-agent-travel`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [shihan-1147](https://agentstack.voostack.com/s/shihan-1147)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [shihan-1147](https://github.com/shihan-1147)
- **Source:** https://github.com/shihan-1147/SkillMCP-Agent/tree/main/src/skills/travel

## Install

```sh
agentstack add skill-shihan-1147-skillmcp-agent-travel
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# 火车票务查询技能

此技能用于查询中国铁路 12306 平台的票务信息，帮助用户规划出行。

## 能力范围

- **车次查询**: 查询两站之间的所有车次
- **余票查询**: 查询特定日期的余票信息
- **站点查询**: 获取城市/车站的站点代码
- **换乘查询**: 查询需要中转的路线

## 使用场景

当用户提出以下类型的问题时，应激活此技能：
- "明天从北京到上海的高铁有哪些？"
- "查一下下周三去杭州的火车票"
- "北京南站到上海虹桥还有票吗？"
- "帮我看看去成都的动车"

## 依赖工具

| 工具名称 | 用途 | 必需 |
|---------|------|-----|
| `12306_get_tickets` | 查询余票信息 | ✅ |
| `12306_get_station_code` | 获取站点代码 | ✅ |
| `12306_get_current_date` | 获取当前日期 | ✅ |

## 输入参数

| 参数 | 类型 | 必填 | 说明 |
|-----|------|-----|------|
| origin | string | ✅ | 出发城市/车站 |
| destination | string | ✅ | 到达城市/车站 |
| date | string | ❌ | 出发日期 (YYYY-MM-DD)，默认今天 |
| train_type | string | ❌ | 车型筛选: G(高铁)/D(动车)/K(快速) |

## 输出格式

```json
{
  "success": true,
  "data": {
    "origin": "北京南",
    "destination": "上海虹桥",
    "date": "2026-01-20",
    "trains": [
      {
        "train_no": "G1",
        "departure_time": "07:00",
        "arrival_time": "11:28",
        "duration": "4小时28分",
        "seats": {
          "商务座": "有",
          "一等座": "有",
          "二等座": "3张"
        }
      }
    ]
  }
}
```

## 处理流程

1. 解析用户意图，提取出发地、目的地、日期
2. 调用站点查询工具获取站点代码
3. 调用余票查询工具获取车次信息
4. 格式化输出结果

## 注意事项

- 日期必须是未来 15 天内
- 站点名称需要规范化（如"北京"→"北京南"或"北京西"）
- 节假日期间可能查询较慢

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [shihan-1147](https://github.com/shihan-1147)
- **Source:** [shihan-1147/SkillMCP-Agent](https://github.com/shihan-1147/SkillMCP-Agent)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-shihan-1147-skillmcp-agent-travel
- Seller: https://agentstack.voostack.com/s/shihan-1147
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
