Open Weather Map Client

Package that communicates with Open Weather Map to obtain climate data in a model.

Getting Started

pub package

Get the current weather

See the full example at:

    future: openWeatherMap.currentWeather(const City(name: 'London')),
    builder: (_, snapshot) {
        if (snapshot.connectionState == ConnectionState.waiting) {
            return const Center(child: CircularProgressIndicator.adaptive());
        if (snapshot.hasError) {
            return ApiErrorCard(apiError: snapshot.error! as ApiError);
        if (!snapshot.hasData) {
            return const Center(
                child: Text(
                'Error obtained data, check internet connection',
        final CurrentWeather weather =!;
        return Center(
        child: Column(
            mainAxisAlignment: MainAxisAlignment.spaceAround,
                children: [
                    Text('City: ${}'),
                    Text('Temperature: ${weather.detail.temperatureCelsius.toStringAsFixed(2)} °C'),
                    Text('Speed: ${weather.wind.speed.toStringAsFixed(2)} m/s'),

Flutter Open Weather Map Client Example