搜索

PythonReactSEOPDF
OpenClaw

stormglass-surf-skill

Fetch surf-relevant ocean conditions from Stormglass by spot name or coordinates, including current snapshot and 1-3 day forecast windows with tides, gusts, and water temperature. Use when users ask for surf reports, wave or swell conditions, tide timing, wind, gusts, or water temperature for a beach or surf spot.

dgorissen0 来源安装数☆ 0 仓库 Starsv1.0.2

安装与使用

请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。

SkillHub CLI

skillhub install dgorissen/stormglass

打开来源仓库,查看说明和兼容环境后,按来源提供的命令或步骤安装。

将来源链接提供给你的 Agent,让它先读取说明、核对依赖,并向你说明将执行的安装步骤。

查看来源 ↗使用指南

技能说明

Stormglass Surf Skill

Purpose

Produce machine-readable surf condition data for cron-driven agent pipelines.

This skill resolves a surf spot name with Google Geocoding (or uses direct coordinates), queries Stormglass, and returns a stable JSON payload for downstream interpretation/rendering.

Inputs

Provide exactly one location mode:

  • --location "Spot name" (optional country/region in string), or
  • --lat <float> --lon <float>

Optional controls:

  • --horizon now|24h|48h|72h (default 72h)
  • --output json|pretty (default json, recommended for automation)
  • --source <comma-separated provider list>
  • --mock (offline deterministic data; useful for tests)

Required Environment Variables

  • STORMGLASS_API_KEY for Stormglass requests
  • GOOGLE_GEOCODING_API_KEY optional for --location (if absent, script falls back to OpenStreetMap Nominatim)

In --mock mode, no API keys are required.

Credential Matrix
Mode STORMGLASS_API_KEY GOOGLE_GEOCODING_API_KEY
--mock not required not required
live --lat/--lon required not required
live --location with Google required optional (preferred when set)
live --location with OSM fallback required not required

Primary credential is STORMGLASS_API_KEY.

Execution Commands

JSON output for cron:

python scripts/surf_report.py --location "Highcliffe Beach" --horizon 72h --output json

Direct coordinates:

python scripts/surf_report.py --lat 50.735 --lon -1.705 --horizon 24h --output json

Offline test run:

python scripts/surf_report.py --location "Highcliffe Beach" --horizon now --mock --output json

Output Contract (JSON-first)

Top-level keys are stable:

  • meta: request metadata, timestamps, input mode, optional warnings
  • location: resolved place details and coordinates
  • now: instantaneous surf-relevant metrics
  • forecast: horizon summaries and best windows
  • tides: tide extrem...

来源信息

Source
github
Repository
openclaw/skills
Path
skills/dgorissen/stormglass
Version
1.0.2
Commit
3f08df399eb143ef17e933660fafed80e8b45772
分类来源
rules
状态
active
可见性
public

这些信息来自收录时的来源分析,可能滞后;使用前请核对最新来源文件。

README

Stormglass Surf Skill

An OpenClaw-friendly surf data skill that fetches current and 1-3 day ocean forecasts from Stormglass, including:

  • wave height
  • swell height/period/direction
  • wind speed/direction
  • wind gusts
  • water temperature
  • high/low tide extremes

It supports querying by:

  • surf spot name (--location, with geocoding), or
  • direct coordinates (--lat + --lon).

Project Layout

  • SKILL.md - skill contract and agent handoff guidance
  • scripts/surf_report.py - main CLI
  • scripts/test_surf_report.py - CLI test runner
  • scripts/normalize_surf_data.py - optional schema normalizer
  • examples.md - practical command/pipeline examples
  • reference.md - API mapping, schema, and behavior details

Requirements

  • Python 3.10+
  • Stormglass API key for non-mock runs
  • Google Geocoding key optional (if absent, location mode falls back to OpenStreetMap Nominatim)

Environment Variables

  • STORMGLASS_API_KEY - required for live Stormglass requests
  • GOOGLE_GEOCODING_API_KEY - optional; used when present for --location
Credential Matrix
Mode STORMGLASS_API_KEY GOOGLE_GEOCODING_API_KEY
--mock (offline tests) not required not required
live with --lat/--lon required not required
live with --location + Google geocoder required optional (preferred when set)
live with --location + OSM fallback required not required

Primary credential for this skill is STORMGLASS_API_KEY.

Quick Start

From repository root:

# 1) Offline smoke test (no keys required)
python3 scripts/surf_report.py --location "Highcliffe Beach" --horizon now --mock --output pretty

# 2) Live request by coordinates (Stormglass key required)
export STORMGLASS_API_KEY="..."
python3 scripts/surf_report.py --lat 50.735 --lon -1.705 --horizon 24h --output json

# 3) Live request by location (Google optional; OSM fallback if missing)
python3 scripts/surf_report.py --location "Highcliffe Beach" --ho...

来源内容

SKILL.md
# Stormglass Surf Skill

## Purpose

Produce machine-readable surf condition data for cron-driven agent pipelines.

This skill resolves a surf spot name with Google Geocoding (or uses direct coordinates), queries Stormglass, and returns a stable JSON payload for downstream interpretation/rendering.

## Inputs

Provide exactly one location mode:

- `--location "Spot name"` (optional country/region in string), or
- `--lat <float> --lon <float>`

Optional controls:

- `--horizon now|24h|48h|72h` (default `72h`)
- `--output json|pretty` (default `json`, recommended for automation)
- `--source <comma-separated provider list>`
- `--mock` (offline deterministic data; useful for tests)

## Required Environment Variables

- `STORMGLASS_API_KEY` for Stormglass requests
- `GOOGLE_GEOCODING_API_KEY` optional for `--location` (if absent, script falls back to OpenStreetMap Nominatim)

In `--mock` mode, no API keys are required.

### Credential Matrix

| Mode | `STORMGLASS_API_KEY` | `GOOGLE_GEOCODING_API_KEY` |
|---|---|---|
| `--mock` | not required | not required |
| live `--lat/--lon` | required | not required |
| live `--location` with Google | required | optional (preferred when set) |
| live `--location` with OSM fallback | required | not required |

Primary credential is `STORMGLASS_API_KEY`.

## Execution Commands

JSON output for cron:

```bash
python scripts/surf_report.py --location "Highcliffe Beach" --horizon 72h --output json
```

Direct coordinates:

```bash
python scripts/surf_report.py --lat 50.735 --lon -1.705 --horizon 24h --output json
```

Offline test run:

```bash
python scripts/surf_report.py --location "Highcliffe Beach" --horizon now --mock --output json
```

## Output Contract (JSON-first)

Top-level keys are stable:

- `meta`: request metadata, timestamps, input mode, optional warnings
- `location`: resolved place details and coordinates
- `now`: instantaneous surf-relevant metrics
- `forecast`: horizon summaries and best windows
- `tides`: tide extrem...
README
# Stormglass Surf Skill

An OpenClaw-friendly surf data skill that fetches current and 1-3 day ocean forecasts from Stormglass, including:

- wave height
- swell height/period/direction
- wind speed/direction
- wind gusts
- water temperature
- high/low tide extremes

It supports querying by:

- surf spot name (`--location`, with geocoding), or
- direct coordinates (`--lat` + `--lon`).

## Project Layout

- `SKILL.md` - skill contract and agent handoff guidance
- `scripts/surf_report.py` - main CLI
- `scripts/test_surf_report.py` - CLI test runner
- `scripts/normalize_surf_data.py` - optional schema normalizer
- `examples.md` - practical command/pipeline examples
- `reference.md` - API mapping, schema, and behavior details

## Requirements

- Python 3.10+
- Stormglass API key for non-mock runs
- Google Geocoding key optional (if absent, location mode falls back to OpenStreetMap Nominatim)

## Environment Variables

- `STORMGLASS_API_KEY` - required for live Stormglass requests
- `GOOGLE_GEOCODING_API_KEY` - optional; used when present for `--location`

### Credential Matrix

| Mode | `STORMGLASS_API_KEY` | `GOOGLE_GEOCODING_API_KEY` |
|---|---|---|
| `--mock` (offline tests) | not required | not required |
| live with `--lat/--lon` | required | not required |
| live with `--location` + Google geocoder | required | optional (preferred when set) |
| live with `--location` + OSM fallback | required | not required |

Primary credential for this skill is `STORMGLASS_API_KEY`.

## Quick Start

From repository root:

```bash
# 1) Offline smoke test (no keys required)
python3 scripts/surf_report.py --location "Highcliffe Beach" --horizon now --mock --output pretty

# 2) Live request by coordinates (Stormglass key required)
export STORMGLASS_API_KEY="..."
python3 scripts/surf_report.py --lat 50.735 --lon -1.705 --horizon 24h --output json

# 3) Live request by location (Google optional; OSM fallback if missing)
python3 scripts/surf_report.py --location "Highcliffe Beach" --ho...

相关技能