Skip to main content

PyPi License: MIT

uims-api

This is a Python library which scrapes https://uims.cuchd.in for account information. Our goal is to wrap commonly used web functionality as easy-to-use methods.

Installation

$ pip install uims-api

Running locally:

You need to have Python 3 installed on your system. Python 2 might work but we won't provide any support for it. You also need to have the command-line version for git installed, otherwise you could directly download and extract the ZIP file of this repository and follow along.

Open up a terminal and run: (The $ sign indicates the commands are to be run in a shell. It is not supposed to be a part of the command)

$ git clone https://github.com/cu-unofficial/uims-api
$ cd uims-api
$ pip install -e .

Usage Examples

from uims_api import SessionUIMS

# replace these with your credentials
my_account = SessionUIMS("YourUID", "YourPass")

# `my_acc.attendance` returns attendance info for available subjects in JSON format
subjects = my_account.attendance

# display attendance for each subject
for subject in subjects:
    subject_attendance = "{} - {}%".format(subject["Title"], subject["TotalPercentage"])
    print(subject_attendance)

Available Methods

Methods Description
full_name returns user's full name
attendance returns user's minimal attendance
full_attendance returns user's attendance including day-wise marked report history for each subject
timetable returns user's timetable
available_sessions returns user's available sessions
marks(session) returns marks for the session provided as argument

Documentation

Coming soon?

Contributing

Let's keep this as minimal as possible using requests and BeatifulSoup libraries.

Relying on browser automation tools (selenium) could work but isn't a very portable solution. It is slower and takes up more processing power. Also, setting up such tools could end up being a nightmare when attempting them to run on headless devices (such as a Raspberry Pi).

That said, if you know Python, any pull requests to enhance capabilities or cover up more end points that make use of requests and BeautifulSoup libraries are most welcome! Otherwise if you don't know Python, you could help me complete my assignments!

Metadata

Release files for uims-api 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for uims-api 0.1.2
File Size Uploaded Provenance Actions
uims-api-0.1.2.tar.gz 8.7 kB Without provenance Details for uims-api-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for uims-api 0.1.2
File Interpreter ABI Platform Actions
uims_api-0.1.2-py3-none-any.whl Python 3 none any Details for uims_api-0.1.2-py3-none-any.whl

Total release size: 16.6 kB

Release files / uims-api-0.1.2.tar.gz

Download URL uims-api-0.1.2.tar.gz
Size 8.7 kB
Tags Source
SHA-256 checksum
How to use checksums
7999d73a08aa449fdb72d8c4bad5b594deeb275deffb4423a6f78f465bdd2aaa
BLAKE2b-256 checksum
How to use checksums
99de63c163f3024c9a6e0adea270cb5b0ab22a7d9d23a4eff06b218753cf2104
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7

Release files / uims_api-0.1.2-py3-none-any.whl

Download URL uims_api-0.1.2-py3-none-any.whl
Size 7.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0a470b9a3eaafaa363fea6709e242198598b820ff652f6306ca2eeb4e3c8670e
BLAKE2b-256 checksum
How to use checksums
02a559f4c54e7b830cb86f1d9c772578b57459d6e747c472a98e47daa539247c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7

Security for uims-api 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page