Skip to main content

공공데이터 포털 ( [data.go.kr](https://www.data.go.kr/) ) 에서 제공하는 코로나19 예방접종 실적 통계 데이터 조회 서비스 API Wrapper

Project description

코로나 백신 예방 접종 통계 API Wrapper

test codecov lint

공공데이터 포털 ( data.go.kr ) 에서 제공하는 코로나19 예방접종 실적 통계 데이터 조회 서비스 API Wrapper

Usage

Install module

pip install git+https://github.com/zeroday0619/covid_vaccine_stat.git

Example

  1. Synchronous

import json
from covid_vaccine_stat import sync_request

api_key = "# data.go.kr 에서 발급 받은 API Key #"

res = sync_request.fetch(api_key=api_key)
json_data = json.dumps(
    res.data[0].json(), 
    ensure_ascii=False, 
    escape_forward_slashes=False
)
print(json_data)
  1. Asynchronous

import json
import asyncio
from covid_vaccine_stat import async_request

api_key = "# data.go.kr 에서 발급 받은 API Key #"

loop = asyncio.get_event_loop()
res = loop.run_until_complete(async_request.fetch(api_key=api_key))
json_data = json.dumps(
    res.data[0].json(),
    ensure_ascii=False,
    escape_forward_slashes=False
)
print(json_data)

License

Copyright (c) 2021 Euiseo Cha zeroday0619@kakao.com

Distributed under the MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

covid_vaccine_stat-0.0.1.tar.gz (5.0 kB view hashes)

Uploaded Source

Built Distribution

covid_vaccine_stat-0.0.1-py3-none-any.whl (6.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page