← 返回
效率工具 中文

Linz Public Transport

Query Linz public transport stops for IDs and fetch live upcoming departures using Linz Linien EFA endpoints.
查询林茨公交站点ID,使用林茨Linien EFA接口获取实时离站信息。
fjrevoredo
效率工具 clawhub v1.0.1 1 版本 99814.3 Key: 无需
★ 2
Stars
📥 1,035
下载
💾 12
安装
1
版本
#latest

概述

Linz Public Transport

Use this skill to interact with Linz Linien EFA endpoints:

  • GET /efa/XML_STOPFINDER_REQUEST
  • GET /efa/XML_DM_REQUEST

Read endpoint details in {baseDir}/references/endpoints.md before implementation.

Use {baseDir}/scripts/linz_transport.py as the default execution path.

Workflow

  1. Resolve the API base URL.
  2. Run the script subcommand that matches the task.
  3. Return a compact, user-facing summary.

Primary Tooling

  • Script path: {baseDir}/scripts/linz_transport.py
  • Runtime: Python 3, standard library only.
  • Base URL input:
  • --base-url argument, or
  • LINZ_TRANSPORT_API_BASE_URL environment variable, or
  • default http://www.linzag.at/linz2.

Preferred commands:

  • Search stops:
  • python {baseDir}/scripts/linz_transport.py stops "taubenmarkt"
  • Fetch departures by stop ID:
  • python {baseDir}/scripts/linz_transport.py departures --stop-id 60501160 --limit 10
  • Resolve stop and fetch departures in one call:
  • python {baseDir}/scripts/linz_transport.py next "taubenmarkt" --limit 10 --pick-first

Step 1: Resolve Base URL

  • Use user-provided base URL first.
  • Otherwise use LINZ_TRANSPORT_API_BASE_URL if available.
  • If neither exists, use http://www.linzag.at/linz2.

Step 2: Present Output

  • Sort by countdownInMinutes ascending if needed.
  • Show the next 5-10 departures unless user asks for more.
  • Include both relative (countdownInMinutes) and absolute (time) times.
  • Keep field names stable when returning JSON.

Error Handling

  • If stop search returns empty list, suggest nearby spellings and retry with a shorter query token.
  • If multiple stop matches are returned, rerun with explicit --stop-id or use next ... --pick-first only when ambiguity is acceptable.
  • If departures response is empty, state that no upcoming departures are currently available.
  • If HTTP request fails, report status code, endpoint, and retry guidance.
  • If EFA response includes a message code, include that code in diagnostics.

Minimal Examples

python {baseDir}/scripts/linz_transport.py stops "taubenmarkt"
python {baseDir}/scripts/linz_transport.py departures --stop-id 60501160 --limit 10
python {baseDir}/scripts/linz_transport.py next "taubenmarkt" --limit 10 --pick-first
python "{baseDir}/scripts/linz_transport.py" stops "taubenmarkt"
python "{baseDir}/scripts/linz_transport.py" departures --stop-id 60501160 --limit 10
python "{baseDir}/scripts/linz_transport.py" next "taubenmarkt" --limit 10 --pick-first

版本历史

共 1 个版本

  • v1.0.1 当前
    2026-03-29 06:15 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

content-creation

Simple Random Interaction Designer

fjrevoredo
决定OpenClaw是否应在定期检查时主动发送随意的消息,若应该发送,则选择自然的互动类型并提供简洁的回复。
★ 2 📥 933
productivity

Nano Pdf

steipete
使用nano-pdf CLI通过自然语言指令编辑PDF
★ 275 📥 114,838
productivity

Weather

steipete
获取当前天气和预报(无需API密钥)
★ 445 📥 226,292