Skill: lyz1990/variflight (version 1.0.1)

--- name: variflight description: Query flight information, train tickets, and travel data using Variflight (飞常准) HTTP API. Use when the user needs to (1) search flights by route or flight number, (2) check flight status and punctuality, (3) find train tickets, (4) get airport weather forecasts, (5) check flight prices, (6) plan multi-modal trips (flight+train), or (7) get flight comfort metrics (happiness index). --- # Variflight HTTP API Tool Official Variflight Agent Skills enabling AI assistants to retrieve flight and railway data via zero-dependency tools. ## API Endpoint - **Base URL:** `https://ai.variflight.com/api/v1/mcp/data` - **Method:** POST - **Header:** `X-VARIFLIGHT-KEY: your_api_key` - **Content-Type:** `application/json` ## Configuration 支持多种配置方式（按优先级排序）： ### 1. 环境变量（推荐用于 CI/CD） ```bash export VARIFLIGHT_API_KEY="sk-xxxxxxxxxxxxxxxx" ``` ### 2. 配置文件 按以下顺序查找（找到即停止）： - `./.variflight.json`（项目级配置） - `~/.variflight.json`（用户级配置） - `~/.config/variflight/config.json`（XDG 标准） 配置格式： ```json { "api_key": "sk-xxxxxxxxxxxxxxxx" } ``` ### 3. 命令行参数 ```bash ./flights.sh --api-key sk-xxxx PEK SHA 2025-02-15 ``` ## Quick Start ### Installation ```bash # Clone or copy the skill git clone https://github.com/variflight-ai/variflight-skill.git # Or copy to your project cp -r variflight-skill/scripts ./scripts ``` ### Get API Key Visit https://ai.variflight.com ### Setup 方式一：环境变量 ```bash export VARIFLIGHT_API_KEY="sk-xxxxxxxxxxxxxxxx" ``` 方式二：配置文件 ```bash echo '{"api_key": "sk-xxxxxxxxxxxxxxxx"}' > ~/.variflight.json ``` ### Usage ```bash # Search flights ./scripts/flights.sh PEK SHA 2025-02-15 # Search by flight number ./scripts/flight.sh MU2157 2025-02-15 # Search train tickets ./scripts/train.sh "上海" "合肥" 2025-02-15 # Airport weather ./scripts/weather.sh PEK # With explicit API key ./scripts/flights.sh --api-key sk-xxxx PEK SHA 2025-02-15 ``` ## Available Endpoints | Endpoint | Description | Parameters | |----------|-------------|------------| | `flights` | Search by departure/arrival | dep, arr, date, depcity, arrcity | | `flight` | Search by flight number | fnum, date, dep, arr | | `transfer` | Flight transfer info | depcity, arrcity, depdate | | `happiness` | Flight comfort index | fnum, date, dep, arr | | `realtimeLocation` | Aircraft location | anum | | `futureAirportWeather` | Airport weather | code, type="1" | | `searchFlightItineraries` | Flight itineraries | depCityCode, arrCityCode, depDate | | `trainStanTicket` | Train tickets | cdep, carr, date | | `searchTrainStations` | Train stations | query | | `getFlightPriceByCities` | Flight prices | dep_city, arr_city, dep_date | ## Common Airport Codes | City | Airport | Code | |------|---------|------| | 北京 | 首都机场 | PEK | | 北京 | 大兴机场 | PKX | | 上海 | 虹桥机场 | SHA | | 上海 | 浦东机场 | PVG | | 广州 | 白云机场 | CAN | | 深圳 | 宝安机场 | SZX | | 成都 | 双流机场 | CTU | | 杭州 | 萧山机场 | HGH | | 合肥 | 新桥机场 | HFE | | 西安 | 咸阳机场 | XIY | ## Response Format ```json { "code": 200, "message": "Success", "data": { ... } } ``` ## Error Handling - `401` - Invalid API key - `400` - Bad request - `500` - Server error ## Integration Examples ### OpenClaw (特别支持) OpenClaw 会自动识别并加载本 skill。 **安装：** ```bash # 通过 ClawHub 安装 openclaw skill install variflight # 或手动安装 cp -r variflight-skill ~/.openclaw/workspace/skills/variflight ``` **配置：** ```bash # OpenClaw 专用环境文件 echo 'VARIFLIGHT_API_KEY=sk-xxxx' > ~/.openclaw/workspace/.env.variflight # 或使用通用配置 echo '{"api_key": "sk-xxxx"}' > ~/.variflight.json ``` **使用：** ```bash ./skills/variflight/scripts/flights.sh PEK SHA 2025-02-15 ./skills/variflight/scripts/train.sh "上海" "合肥" 2025-02-15 ``` ### Claude Code / Cursor Add to your settings: ```json { "variflight_api_key": "sk-xxxxxxxxxxxxxxxx" } ``` Or set environment variable in your shell config: ```bash export VARIFLIGHT_API_KEY="sk-xxxxxxxxxxxxxxxx" ``` ### GitHub Actions ```yaml - name: Setup Variflight env: VARIFLIGHT_API_KEY: ${{ secrets.VARIFLIGHT_API_KEY }} run: | ./scripts/flights.sh PEK SHA 2025-02-15 ``` ### Docker ```dockerfile ENV VARIFLIGHT_API_KEY=sk-xxxxxxxxxxxxxxxx COPY scripts/ /app/scripts/ ``` ## Links - Variflight AI: https://ai.variflight.com - ClawHub: https://clawhub.com

path: README.md
content: # Variflight Skill

飞常准 (Variflight) API 工具 - 支持 OpenClaw、Claude Code、Cursor 等所有 AI 客户端。

## 特性

- ✅ **零依赖** - 纯 Python 标准库，无需安装 MCP
- ✅ **多客户端支持** - OpenClaw、Claude Code、Cursor、GitHub Actions 等
- ✅ **灵活配置** - 环境变量、配置文件、命令行参数
- ✅ **完整功能** - 航班查询、火车票、天气、价格等

## 安装

```bash
# 克隆仓库
git clone https://github.com/variflight-ai/variflight-skill.git
cd variflight-skill

# 或使用特定目录
cp -r variflight-skill/scripts /path/to/your/project/
```

## 获取 API Key

访问 https://ai.variflight.com 获取 API Key。

## 配置

支持以下方式（按优先级排序）：

### 1. 命令行参数（最高优先级）

```bash
./scripts/flights.sh --api-key sk-xxxx PEK SHA 2025-02-15
```

### 2. 环境变量（推荐用于 CI/CD）

```bash
export VARIFLIGHT_API_KEY="sk-xxxxxxxxxxxxxxxx"
```

### 3. 配置文件

按以下顺序查找：
- `./.variflight.json`（项目级）
- `~/.variflight.json`（用户级）
- `~/.config/variflight/config.json`（XDG 标准）

配置格式：
```json
{
  "api_key": "sk-xxxxxxxxxxxxxxxx"
}
```

快速设置：
```bash
cp .variflight.json.example ~/.variflight.json
# 编辑 ~/.variflight.json 填入你的 API key
```

## 使用

### 航班查询

```bash
# 按航线查询
./scripts/flights.sh PEK SHA 2025-02-15

# 按航班号查询
./scripts/flight.sh MU2157 2025-02-15

# 中转方案
./scripts/transfer.sh BJS SHA 2025-02-15

# 舒适度指数
./scripts/happiness.sh MU2157 2025-02-15

# 机场天气
./scripts/weather.sh PEK

# 机票价格
./scripts/price.sh HFE CAN 2025-02-15
```

### 火车票查询

```bash
./scripts/train.sh "上海" "合肥" 2025-02-15

# 查询火车站
./scripts/station.sh "北京西"
```

## 客户端集成

### OpenClaw (特别支持)

OpenClaw 会自动识别 skill 并加载 SKILL.md 中的说明。

**安装方式：**
```bash
# 通过 ClawHub 安装
openclaw skill install variflight

# 或手动安装到 workspace
cp -r variflight-skill ~/.openclaw/workspace/skills/variflight
```

**配置方式：**
```bash
# 方式1: OpenClaw 环境变量文件
echo 'VARIFLIGHT_API_KEY=sk-xxxx' > ~/.openclaw/workspace/.env.variflight

# 方式2: 通用配置文件 (推荐)
echo '{"api_key": "sk-xxxx"}' > ~/.variflight.json
```

**使用示例：**
```bash
# OpenClaw 会自动识别这些命令
./skills/variflight/scripts/flights.sh PEK SHA 2025-02-15
./skills/variflight/scripts/train.sh "上海" "合肥" 2025-02-15
```

### Claude Code

在 `.claude/settings.json` 中添加：
```json
{
  "env": {
    "VARIFLIGHT_API_KEY": "sk-xxxxxxxxxxxxxxxx"
  }
}
```

或使用配置文件：
```bash
echo '{"api_key": "sk-xxxx"}' > ~/.variflight.json
```

### Cursor

在 Cursor Settings → General → Environment Variables 中添加：
```
VARIFLIGHT_API_KEY=sk-xxxxxxxxxxxxxxxx
```

### GitHub Actions

```yaml
- name: Query Flights
  env:
    VARIFLIGHT_API_KEY: ${{ secrets.VARIFLIGHT_API_KEY }}
  run: |
    ./scripts/flights.sh PEK SHA 2025-02-15
```

### Docker

```dockerfile
ENV VARIFLIGHT_API_KEY=sk-xxxxxxxxxxxxxxxx
COPY scripts/ /app/scripts/
```

## API Endpoints

| Endpoint | 描述 | 示例参数 |
|----------|------|----------|
| `flights` | 按航线查航班 | dep=PEK arr=SHA date=2025-02-15 |
| `flight` | 按航班号查询 | fnum=MU2157 date=2025-02-15 |
| `transfer` | 中转方案 | depcity=BJS arrcity=SHA depdate=2025-02-15 |
| `happiness` | 舒适度指数 | fnum=MU2157 date=2025-02-15 |
| `futureAirportWeather` | 机场天气 | code=PEK type=1 |
| `trainStanTicket` | 火车票 | cdep=上海 carr=合肥 date=2025-02-15 |
| `searchTrainStations` | 火车站 | query=北京西 |
| `getFlightPriceByCities` | 机票价格 | dep_city=HFE arr_city=CAN dep_date=2025-02-15 |

## 常见机场代码

| 城市 | 机场 | 代码 |
|------|------|------|
| 北京 | 首都机场 | PEK |
| 北京 | 大兴机场 | PKX |
| 上海 | 虹桥机场 | SHA |
| 上海 | 浦东机场 | PVG |
| 广州 | 白云机场 | CAN |
| 深圳 | 宝安机场 | SZX |
| 成都 | 双流机场 | CTU |
| 杭州 | 萧山机场 | HGH |
| 合肥 | 新桥机场 | HFE |
| 西安 | 咸阳机场 | XIY |

## 许可证

MIT

## 链接

- Variflight AI: https://ai.variflight.com
- ClawHub: https://clawhub.com


path: scripts/flight.sh
content: #!/bin/bash
# Search flight by flight number
# Usage: flight.sh [--api-key KEY] <fnum> <date> [dep] [arr]

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

FNUM="$1"
DATE="$2"
DEP="${3:-}"
ARR="${4:-}"

if [[ -z "$FNUM" || -z "$DATE" ]]; then
    echo "Usage: flight.sh [--api-key KEY] <flight_number> <YYYY-MM-DD> [dep_airport] [arr_airport]"
    echo "Example: flight.sh MU2157 2025-02-15"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

PARAMS="fnum=$FNUM date=$DATE"
[[ -n "$DEP" ]] && PARAMS="$PARAMS dep=$DEP"
[[ -n "$ARR" ]] && PARAMS="$PARAMS arr=$ARR"

$SCRIPT_DIR/variflight.sh $API_KEY_ARG flight $PARAMS


path: scripts/flights.sh
content: #!/bin/bash
# Search flights by departure and arrival
# Usage: flights.sh [--api-key KEY] <dep> <arr> <date> [depcity] [arrcity]

API_KEY_ARG=""

# Parse --api-key if present
while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

DEP="$1"
ARR="$2"
DATE="$3"
DEPCITY="${4:-}"
ARRCITY="${5:-}"

if [[ -z "$DEP" || -z "$ARR" || -z "$DATE" ]]; then
    echo "Usage: flights.sh [--api-key KEY] <dep_airport> <arr_airport> <YYYY-MM-DD> [depcity] [arrcity]"
    echo "Example: flights.sh PEK SHA 2025-02-15"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

PARAMS="dep=$DEP arr=$ARR date=$DATE"
[[ -n "$DEPCITY" ]] && PARAMS="$PARAMS depcity=$DEPCITY"
[[ -n "$ARRCITY" ]] && PARAMS="$PARAMS arrcity=$ARRCITY"

$SCRIPT_DIR/variflight.sh $API_KEY_ARG flights $PARAMS


path: scripts/happiness.sh
content: #!/bin/bash
# Get flight happiness index
# Usage: happiness.sh [--api-key KEY] <fnum> <date> [dep] [arr]

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

FNUM="$1"
DATE="$2"
DEP="${3:-}"
ARR="${4:-}"

if [[ -z "$FNUM" || -z "$DATE" ]]; then
    echo "Usage: happiness.sh [--api-key KEY] <flight_number> <YYYY-MM-DD> [dep_airport] [arr_airport]"
    echo "Example: happiness.sh MU2157 2025-02-15"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

PARAMS="fnum=$FNUM date=$DATE"
[[ -n "$DEP" ]] && PARAMS="$PARAMS dep=$DEP"
[[ -n "$ARR" ]] && PARAMS="$PARAMS arr=$ARR"

$SCRIPT_DIR/variflight.sh $API_KEY_ARG happiness $PARAMS


path: scripts/price.sh
content: #!/bin/bash
# Get flight price by cities
# Usage: price.sh [--api-key KEY] <dep_city> <arr_city> <date>

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

DEPCITY="$1"
ARRCITY="$2"
DATE="$3"

if [[ -z "$DEPCITY" || -z "$ARRCITY" || -z "$DATE" ]]; then
    echo "Usage: price.sh [--api-key KEY] <dep_city_code> <arr_city_code> <YYYY-MM-DD>"
    echo "Example: price.sh HFE CAN 2025-02-15"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
$SCRIPT_DIR/variflight.sh $API_KEY_ARG getFlightPriceByCities dep_city="$DEPCITY" arr_city="$ARRCITY" dep_date="$DATE"


path: scripts/station.sh
content: #!/bin/bash
# Search train stations
# Usage: station.sh [--api-key KEY] <query>

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

QUERY="$1"

if [[ -z "$QUERY" ]]; then
    echo "Usage: station.sh [--api-key KEY] <query>"
    echo "Example: station.sh \"北京西\""
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
$SCRIPT_DIR/variflight.sh $API_KEY_ARG searchTrainStations query="$QUERY"


path: scripts/train.sh
content: #!/bin/bash
# Search train tickets
# Usage: train.sh [--api-key KEY] <from_city> <to_city> <date>

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

FROM="$1"
TO="$2"
DATE="$3"

if [[ -z "$FROM" || -z "$TO" || -z "$DATE" ]]; then
    echo "Usage: train.sh [--api-key KEY] <from_city> <to_city> <YYYY-MM-DD>"
    echo "Example: train.sh \"上海\" \"合肥\" 2025-02-15"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
$SCRIPT_DIR/variflight.sh $API_KEY_ARG trainStanTicket cdep="$FROM" carr="$TO" date="$DATE"


path: scripts/transfer.sh
content: #!/bin/bash
# Get flight transfer info
# Usage: transfer.sh [--api-key KEY] <depcity> <arrcity> <depdate>

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

DEPCITY="$1"
ARRCITY="$2"
DEPDATE="$3"

if [[ -z "$DEPCITY" || -z "$ARRCITY" || -z "$DEPDATE" ]]; then
    echo "Usage: transfer.sh [--api-key KEY] <depcity> <arrcity> <YYYY-MM-DD>"
    echo "Example: transfer.sh BJS SHA 2025-02-15"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
$SCRIPT_DIR/variflight.sh $API_KEY_ARG transfer depcity="$DEPCITY" arrcity="$ARRCITY" depdate="$DEPDATE"


path: scripts/variflight.py
content: #!/usr/bin/env python3
"""
Variflight API wrapper - Universal version
Supports: OpenClaw, Claude Code, Cursor, and other AI clients

Configuration priority:
1. Command line --api-key
2. Environment variable VARIFLIGHT_API_KEY
3. ./.variflight.json (project config)
4. ~/.variflight.json (user config)
5. ~/.config/variflight/config.json (XDG standard)
"""

import sys
import os
import json
import urllib.request
import urllib.error
import argparse

BASE_URL = 'https://ai.variflight.com/api/v1/mcp/data'

def find_config_file():
    """Find config file in standard locations"""
    paths = [
        './.variflight.json',  # Project config
        os.path.expanduser('~/.variflight.json'),  # User config
        os.path.expanduser('~/.config/variflight/config.json'),  # XDG standard
    ]
    
    # Also check OpenClaw path for backward compatibility
    openclaw_path = os.path.expanduser('~/.openclaw/workspace/.env.variflight')
    if os.path.exists(openclaw_path):
        return openclaw_path
    
    for path in paths:
        if os.path.exists(path):
            return path
    return None

def load_api_key(args_api_key=None):
    """Load API key from various sources"""
    # 1. Command line argument (highest priority)
    if args_api_key:
        return args_api_key
    
    # 2. Environment variable
    if os.environ.get('VARIFLIGHT_API_KEY'):
        return os.environ.get('VARIFLIGHT_API_KEY')
    
    # 3. Config file
    config_path = find_config_file()
    if config_path:
        try:
            if config_path.endswith('.json'):
                with open(config_path) as f:
                    config = json.load(f)
                    if config.get('api_key'):
                        return config['api_key']
            elif config_path.endswith('.env.variflight'):
                # Legacy OpenClaw format
                with open(config_path) as f:
                    for line in f:
                        if '=' in line and not line.startswith('#'):
                            key, val = line.strip().split('=', 1)
                            if key == 'VARIFLIGHT_API_KEY':
                                return val
        except Exception as e:
            print(f"Warning: Failed to load config from {config_path}: {e}", file=sys.stderr)
    
    return None

def make_request(endpoint, params, api_key):
    """Make API request to Variflight"""
    body = json.dumps({
        "endpoint": endpoint,
        "params": params
    }).encode('utf-8')
    
    req = urllib.request.Request(
        BASE_URL,
        data=body,
        headers={
            'X-VARIFLIGHT-KEY': api_key,
            'Content-Type': 'application/json'
        },
        method='POST'
    )
    
    try:
        with urllib.request.urlopen(req, timeout=30) as resp:
            return json.loads(resp.read().decode('utf-8'))
    except urllib.error.HTTPError as e:
        return {"error": f"HTTP {e.code}: {e.reason}"}
    except Exception as e:
        return {"error": str(e)}

def parse_args_with_api_key():
    """Parse arguments, extracting --api-key if present"""
    api_key = None
    remaining = []
    
    i = 0
    while i < len(sys.argv):
        if sys.argv[i] in ('--api-key', '-k') and i + 1 < len(sys.argv):
            [REDACTED_SECRET] + 1]
            i += 2
        elif sys.argv[i].startswith('--api-key='):
            [REDACTED_SECRET]'=', 1)[1]
            i += 1
        else:
            remaining.append(sys.argv[i])
            i += 1
    
    return api_key, remaining

def main():
    # Parse --api-key from anywhere in args
    args_api_key, remaining_args = parse_args_with_api_key()
    
    if len(remaining_args) < 2:
        print("Usage: variflight.py [--api-key KEY] <endpoint> [key=value ...]")
        print("\nExamples:")
        print("  variflight.py flights dep=PEK arr=SHA date=2025-02-15")
        print("  variflight.py --api-key sk-xxxx flight fnum=MU2157 date=2025-02-15")
        sys.exit(1)
    
    endpoint = remaining_args[1]
    params = {}
    
    for arg in remaining_args[2:]:
        if '=' in arg:
            key, val = arg.split('=', 1)
            params[key] = val
    
    [REDACTED_SECRET])
    
    if not [REDACTED_SECRET]"Error: VARIFLIGHT_API_KEY not found", file=sys.stderr)
        print("\nPlease configure using one of:", file=sys.stderr)
        print("  1. export VARIFLIGHT_API_KEY=sk-xxxx", file=sys.stderr)
        print("  2. echo '{\"api_key\": \"sk-xxxx\"}' > ~/.variflight.json", file=sys.stderr)
        print("  3. Use --api-key flag", file=sys.stderr)
        sys.exit(1)
    
    result = make_request(endpoint, params, api_key)
    print(json.dumps(result, indent=2, ensure_ascii=False))

if __name__ == '__main__':
    main()


path: scripts/variflight.sh
content: #!/bin/bash
# Variflight API wrapper - Universal version
# Supports: OpenClaw, Claude Code, Cursor, and other AI clients
#
# Configuration priority:
# 1. Command line --api-key
# 2. Environment variable VARIFLIGHT_API_KEY
# 3. ./.variflight.json (project config)
# 4. ~/.variflight.json (user config)
# 5. ~/.config/variflight/config.json (XDG standard)
#
# Usage: variflight.sh [--api-key KEY] <endpoint> [key=value ...]

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
python3 "$SCRIPT_DIR/variflight.py" "$@"


path: scripts/weather.sh
content: #!/bin/bash
# Get airport weather forecast
# Usage: weather.sh [--api-key KEY] <airport_code>

API_KEY_ARG=""

while [[ $# -gt 0 ]]; do
    case "$1" in
        --api-key|-k)
            API_KEY_ARG="--api-key=$2"
            shift 2
            ;;
        --api-key=*)
            API_KEY_ARG="$1"
            shift
            ;;
        *)
            break
            ;;
    esac
done

AIRPORT="$1"

if [[ -z "$AIRPORT" ]]; then
    echo "Usage: weather.sh [--api-key KEY] <airport_code>"
    echo "Example: weather.sh PEK"
    exit 1
fi

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
$SCRIPT_DIR/variflight.sh $API_KEY_ARG futureAirportWeather code="$AIRPORT" type="1"


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: suspicious (HIGH)