Deploy this function on flows.network, and you will get a web service that using OpenWeatherMap to look weather.
This is a simple example to show how Lambda works on flows.network.
To install this weather lookup App, we will use flows.network, a serverless platform that makes deploying your own app quick and easy in just three steps.
You will need an OpenWeatherMap API key. If you do not already have one, sign up here.
Fork this repo.
- Sign up for an account for deploying flows on flows.network. It's free.
- Click on the "Create a Flow" button to start deploying the web service.
- Authenticate the flows.network to access the
wether-lookuprepo you just forked.
- Click on the Advanced text and you will see more settings including branch and environment variables. In this example, we have one variable
API_KEYto fill in, which is the OpenWeatherMap API key.
- Click the Deploy button to deploy your function.
After that, the flows.network will direct you to configure the SaaS integration required by your flow. Here we can see: there is no SaaS needs to be connected since it's a lambda service. Just click the Check button to see your flow details.
After the flow function's status becomes ready, you will see a link under the Lambda Endpoint. Copy and paste this url to your brower and add ?city=cityname to look up the city weather you want to know.
flows.network is still in its early stages. We would love to hear your feedback!
To build locally, make sure you have intsalled Rust and added wasm32-wasi target.
cargo build target wasm32-wasi --release




