Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

A Python Module for get data from real KCOJ.

Project description

KCOJ_api

A Python Module for get data from real KCOJ.

Install

pip install KCOJ-api

Usage

Create a KCOJ object.

>>> from KCOJ_api import KCOJ
>>> kcoj = KCOJ("https://140.124.184.228/upload/")

Use login() to login real KCOJ.

>>> kcoj.login("username", "password", 4)
<Response [200]>

Check online status.

>>> kcoj.active
True

Get question list.

>>> kcoj.get_question()
{'001': {'deadline': '2018/09/19 23:59:59', 'expired': True, 'status': False, 'language': 'Python'}, '002': {'deadline': '2018/09/19 23:59:59', 'expired': True, 'status': False, 'language': 'Python'}, '003': {'deadline': '2018/09/19 23:59:59', 'expired': True, 'status': False, 'language': 'Python'}, '004': {'deadline': '2018/09/19 23:59:59', 'expired': True, 'status': False, 'language': 'Python'},
...

Project details


Download files

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

Files for KCOJ-api, version 1.6.1
Filename, size File type Python version Upload date Hashes
Filename, size KCOJ_api-1.6.1.tar.gz (3.9 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page