Sign inSign up

penrithbeacon/wcp-widget-weather-ticker

By penrithbeacon

•Updated 5 months ago

Image
0

1.7K

penrithbeacon/wcp-widget-weather-ticker repository overview

⁠WCP Widget: Weather Ticker

A Widget Context Protocol (WCP)⁠ widget that displays live weather, date, and time for any location worldwide. Powered by Open-Meteo⁠ — free, no API key required.

Specification: widgetcontextprotocol.com⁠ | Part of the Penrith Beacon WCP⁠ widget suite.

WCP 2.1.0 certified. Full theme reception, orchestration-aware state, Publish to Web, WCP export.


⁠Components

ComponentDefault sizeDescription
Weather Ticker6x2Scrolling ticker with location, date, time, weather conditions
Weather FullFull pageDetailed weather display with forecast

⁠Quick Start

docker run -d \
  --name wcp-widget-weather-ticker \
  -p 3739:3739 \
  -v weather_config:/app/data \
  -v weather_published:/app/published \
  -e CONTAINER_NAME=wcp-widget-weather-ticker \
  --restart unless-stopped \
  docker.io/penrithbeacon/wcp-widget-weather-ticker:latest

⁠Docker Compose

services:
  weather-ticker:
    image: docker.io/penrithbeacon/wcp-widget-weather-ticker:latest
    container_name: wcp-widget-weather-ticker
    ports:
      - "3739:3739"
    volumes:
      - weather_config:/app/data
      - ./published:/app/published
    environment:
      - CONTAINER_NAME=wcp-widget-weather-ticker
    restart: unless-stopped

volumes:
  weather_config:

⁠Setup Guide

Configure through your WCP dashboard's settings panel. The dashboard reads the config array from the manifest and POSTs values to /widget/configure.

FieldTypeDescription
locationautocompleteLive search — returns matching cities from Open-Meteo geocoding
unitsselectcelsius or fahrenheit
refresh_intervalnumberRefresh interval in seconds (300-7200, default 900)

⁠WCP Request Headers

HeaderRequiredDescription
Wcp-Instance-IdYesUnique card instance identifier
Wcp-Dashboard-IdYesDashboard installation identifier
Wcp-VersionYesWCP protocol version of the requesting dashboard
Wcp-Widget-IdYesWidget identifier within the dashboard
Wcp-Orchestration-IdNoActive orchestration identifier (for state scoping)
Wcp-Application-IdNoActive application identifier (for state scoping)

⁠Endpoints

EndpointDescription
GET /wcpContainer Directory — WCP two-tier discovery
GET /widget/wcpWidget Manifest with runtime publish status
OPTIONS /wcpCORS preflight (all widget routes)
GET /widget/Compact scrolling ticker (iframe)
GET /widget/indexWidget Index — lists all controls
GET /widget/healthHealth check with container name
GET /widget/icon.svgWidget icon (SVG)
GET /widget/api/guidsComponent UUIDs for orchestration binding
GET /widget/fullFull-page weather detail
GET /widget/manifestLightweight manifest subset
POST /widget/configureSave widget configuration (per instance)
GET /widget/api/searchLocation autocomplete (query param: q)
GET /widget/api/weatherCurrent weather data (params: lat, lon, units)
GET /widget/export.wcpSelf-export as .wcp package
POST /widget/publishAccept SPA HTML for Publish to Web
DELETE /widget/publishRemove published SPA
GET /Serve published SPA (if present)

⁠WCP Compatibility

PropertyValue
WCP Version2.1.0
Widget Version1.6.0
Render modeiframe
AuthNone
Default card size6x2
Multi-instanceYes (config keyed by Instance-Id)

⁠Technical Details

PropertyValue
Base imagepython:3.12-slim
Platformslinux/amd64, linux/arm64
Port3739
FrameworkFlask
DependenciesFlask, requests
Persistent storageNamed volume for per-instance config

⁠Tags

TagDescription
latestMost recent stable release
1.6.0-wcp2.1.0/widget/index directory page, audit compliance
1.5.0-wcp2.1.0/widget/health returns container name
1.4.0-wcp2.1.0WCP 2.1.0 upgrade, orchestration ID context
1.3.0-wcp2.0.0Container block, manifest image source
1.2.1-wcp1.4.0Server UUID, Container Directory, Wcp-Widget-Id
1.2.0-wcp1.3.1Multi-instance headers, autocomplete config type
1.1.0-wcp1.3.0Components array, ticker role

⁠Source

Tag summary

Content type

Image

Digest

sha256:e0c0e3f94…

Size

47.1 MB

Last updated

5 months ago

docker pull penrithbeacon/wcp-widget-weather-ticker