Public | Automated Build

Last pushed: a year ago
Short Description
GraphQL server wrapping the OpenWeatherMap weather API written in Scala using Sangria.
Full Description

graphql-weather-api

GraphQL server wrapping the OpenWeatherMap weather API written in Scala using Sangria.

Endpoint

You can use this online endpoint in your projects: https://api.graph.cool/relay/v1/weather

Schema

city(name: "Munich") {
  weather {
    temperature {
      celsius
      fahrenheit
      kelvin
    }
    pressure {
      seaLevel # [hPa]
      groundLevel # [hPa]
    }
    wind {
      speed # [meter/sec]
      direction # [degree] (meteorological)
    }
    cloudiness # [percentage]
    humidity # [percentage]
    precipitation {
      rainOneHour
      isRaining
      snowOneHour
      isSnowing
    }
    recordedAt # seconds passed since 1970-01-01T00:00:00Z in ISO 8601
  }
}

Run in Docker

docker run -p 9000:9000 -e OPEN_WEATHER_MAP_KEY="your key" graphcool/graphql-weather-api

Development

export OPEN_WEATHER_MAP_KEY="your key"
sbt run
Docker Pull Command
Owner
graphcool
Source Repository

Comments (0)