yayasanvitka/covid19-module
Composer 安装命令:
composer require yayasanvitka/covid19-module
包简介
README 文档
README
Introduction
yayasanvitka/covid19-module is a Laravel package which was created to easily publish and consume the API for live information about Novel Coronavirus-19.
This module is based on API from javieraviles/covidAPI.
Documentation
Requirement
This module is created as laravel-modules, and require the following:
- Laravel > 5.8.*
- laravel-modules >= 5.1
Installation & Setup
composer require yayasanvitka/covid19-module
Web Route
- /api/covid19: Global Data
- /api/covid19/countries: List of countries
- /api/covid19/countries/{COUNTRY}: Data per Country
Facade Methods
Covid::fetch()
Fetch data from endpointCovid::get()
Get The Data. Returns \Illuminate\Support\Collection. Can be chained with country() method.Covid::country()
Get the country data.Covid::total()->cases
Get total data (Global) for casesCovid::total()->todayCases
Get total data (Global) for todayCasesCovid::total()->todayDeath
Get total data (Global) for todayDeathCovid::total()->recovered
Get total data (Global) for recoveredCovid::total()->deaths
Get total data (Global) for deathsCovid::total()->active
Get total data (Global) for activeCovid::total()->critical
Get total data (Global) for criticalCovid::total()->casesPerOneMillion
Get total data (Global) for casesPerOneMillion
Facade Methods
php artisan covid19-update
Run this to update the database
License
MIT License 2020, IT Yayasan Vitka. Based on API from javieraviles, the data may not be used for commercial purposes.
统计信息
- 总下载量: 22
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-03-20