Description
Create a REST API endpoint that gives the weather forecast for next day.
The forecast should be retrieved from any free third party provider (API) such as:
Your endpoint would receive as request parameters:
- the location (required).
- temperature unit with available values Fahrenheit or Celsius (required).
- a weather forecast provider identifier (optional).
And the response of this endpoint should include the following:
- the temperature.
- the weather description (e.g. "Overcast clouds").
- Unit testing.
- Option to retrieve weather forecast from more providers.
- Caching to reduce the requests to third party providers.
- Use Docker.
- Input validation.
Please keep in mind these coding standards:
- The JSON API specification.
- The PSR-1 and PSR-12 coding standards.
- A program written in
PHP 7.0+
using any Framework you like. - A brief document with an overview of your design.