ThemedWeatherImages 1.0.1
dotnet add package ThemedWeatherImages --version 1.0.1
NuGet\Install-Package ThemedWeatherImages -Version 1.0.1
<PackageReference Include="ThemedWeatherImages" Version="1.0.1" />
<PackageVersion Include="ThemedWeatherImages" Version="1.0.1" />
<PackageReference Include="ThemedWeatherImages" />
paket add ThemedWeatherImages --version 1.0.1
#r "nuget: ThemedWeatherImages, 1.0.1"
#:package ThemedWeatherImages@1.0.1
#addin nuget:?package=ThemedWeatherImages&version=1.0.1
#tool nuget:?package=ThemedWeatherImages&version=1.0.1
ThemedWeatherImages
ThemedWeatherImages provides reusable ASP.NET Core services for pairing current weather data with pre-generated themed daily images.
The library ships no theme defaults: the consuming host supplies the theme, subject, WeatherAPI credentials, fallback IP, and blob image settings. (Before Forever After, for example, uses it to implement Weather Squirrel.)
dotnet add package ThemedWeatherImages
Service Overview
Hosts that register the library expose these public routes:
GET /api/weather-service/current- Returns a JSON payload describing the detected location, a human-readable summary, and aconditionCategorystring such asRain,Clear, orSnow.GET /api/weather-service/current?lat=32.8&lng=-96.8- Uses explicit coordinates instead of IP-based fallback.GET /api/weather-images/{fileName}- Proxies pre-rendered artwork from blob storage.
Read-Side Host Registration
ASP.NET Core hosts register the read-side API services with explicit options:
builder.Services.AddThemedWeatherImages(options =>
{
options.Theme.DisplayName = "Weather Fox";
options.Theme.SubjectName = "fox";
options.Theme.SubjectSlug = "fox";
options.Theme.ImageFileNamePrefix = "fox";
options.WeatherApi.ApiKey = builder.Configuration["WeatherApi:ApiKey"];
options.WeatherApi.DefaultIp = builder.Configuration["WeatherApi:DefaultIp"];
options.Images.BlobBaseUrl = builder.Configuration["WeatherImages:BlobBaseUrl"];
options.Images.BlobSasToken = builder.Configuration["WeatherImages:BlobSasToken"];
});
Required read-side values are validated during registration. Missing values fail startup instead of falling back to library defaults.
WeatherImages:BlobSasToken is optional and lets the backend image proxy read from a private Blob container without exposing direct Blob URLs to browsers.
Generation Support
Azure Functions hosts register shared generation helpers separately:
services.AddThemedWeatherImageGenerationSupport(options =>
{
options.Theme.DisplayName = configuration["ThemedWeatherImages:Theme:DisplayName"];
options.Theme.SubjectName = configuration["ThemedWeatherImages:Theme:SubjectName"];
options.Theme.SubjectSlug = configuration["ThemedWeatherImages:Theme:SubjectSlug"];
options.Theme.ImageFileNamePrefix = configuration["ThemedWeatherImages:Theme:ImageFileNamePrefix"];
options.Images.BlobContainerName = configuration["ThemedWeatherImages:Images:BlobContainerName"];
options.Generation.PromptTemplate = configuration["ThemedWeatherImages:Generation:PromptTemplate"];
options.Generation.Model = configuration["ThemedWeatherImages:Generation:Model"] ?? options.Generation.Model;
options.Generation.CfgScale = configuration.GetValue<double?>("ThemedWeatherImages:Generation:CfgScale") ?? options.Generation.CfgScale;
options.Generation.SamplerName = configuration["ThemedWeatherImages:Generation:SamplerName"] ?? options.Generation.SamplerName;
options.Generation.Width = configuration.GetValue<int?>("ThemedWeatherImages:Generation:Width") ?? options.Generation.Width;
options.Generation.Height = configuration.GetValue<int?>("ThemedWeatherImages:Generation:Height") ?? options.Generation.Height;
});
The website host should not pass Azure Function trigger URLs, function keys, AI Horde credentials, webhook secrets, or generation scheduling values.
Basic Frontend Consumption
The frontend remains ordinary HTTP consumption: call /api/weather-service/current, then probe image candidates such as:
/api/weather-images/fox-rain-20260525.webp
The frontend owns presentation and fallback UX. The backend owns weather lookup, condition mapping, image proxying, and cache headers.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- Newtonsoft.Json (>= 13.0.3)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on ThemedWeatherImages:
| Package | Downloads |
|---|---|
|
ThemedWeatherImages.Functions
Azure Functions isolated-worker function classes for ThemedWeatherImages background image generation: scheduled and manual AI Horde submissions, webhook ingestion of generated images, and a budget kill switch. Reference from a Functions host project that supplies theme configuration. |
GitHub repositories
This package is not used by any popular GitHub repositories.