Files
weatherapi/internal/adapters/inbound/httpapi/service.go
Eric Rakestraw ecea856e8e
All checks were successful
ci/woodpecker/push/build-image Pipeline was successful
Implemented weather stories support
2026-05-30 07:06:29 -05:00

23 lines
1004 B
Go

// service.go defines the inbound service contract consumed by HTTP handlers.
// Layer: adapters/inbound/httpapi boundary to application service.
package httpapi
import (
"context"
"gitea.maximumdirect.net/ejr/weatherapi/internal/app"
"gitea.maximumdirect.net/ejr/weatherfeeder/model"
)
// Service describes weather resource queries needed by the HTTP adapter.
type Service interface {
LatestObservation(ctx context.Context) (*model.WeatherObservation, error)
LatestHourlyForecast(ctx context.Context) (*model.WeatherForecastRun, error)
LatestNarrativeForecast(ctx context.Context) (*model.WeatherForecastRun, error)
LatestForecastDiscussion(ctx context.Context) (*model.WeatherForecastDiscussion, error)
LatestWeatherStoryRun(ctx context.Context) (*model.WeatherStoryRun, error)
LatestWeatherStory(ctx context.Context) (*model.WeatherStory, error)
LatestAlertRun(ctx context.Context) (*model.WeatherAlertRun, error)
CurrentConditions(ctx context.Context) (*app.CurrentConditions, error)
}