Anviz CrossChex Cloud API Python integration library
Project description
crosschexcloudapi
CrossChexCloudAPI Python Library for Anviz Biometric Devices
crosschexcloudapi is a Python library that simplifies interaction with Anviz CrossChex Cloud API. It provides high-level methods for fetching attendance records, managing authentication tokens, and handling API communication securely.
Features
- Fetch and manage authentication tokens with automatic renewal.
- Retrieve attendance logs for employees between specific time ranges.
- Handle paginated API responses automatically.
- Lightweight and minimal dependencies (
requestsonly). - Fully compatible with Python 3.10+.
Installation
Install via pip:
pip install crosschexcloudapi
Usage
from crosschexcloudapi import CrossChexCloudAPI
from datetime import datetime
# Initialize the CrossChexCloudAPI client
api = CrossChexCloudAPI(
api_url="https://api.crosschexcloud.com",
api_key="YOUR_API_KEY",
api_secret="YOUR_API_SECRET",
anviz_request_id="REQUEST_ID"
)
# Test connection and fetch token
token_info = api.test_connection()
print(token_info)
# Fetch attendance records for a specific date range
records = api.get_attendance_records(
begin_time=datetime(2025, 10, 1, 0, 0, 0),
end_time=datetime(2025, 10, 18, 23, 59, 59)
)
print(records)
# Access token and expiry
print("Token:", records["token"])
print("Expires:", records["expires"])
Documentation
- Token Management:
get_token(),test_connection() - Attendance Records:
get_attendance_records(),get_attendance_payload() - Internal Methods:
_post(),_is_token_expired()
Dependencies
requests>=2.28.0
License
This project is licensed under the LGPL 3.0 License.
Author
Sreethul Krishna Email: sreethulkrishna24@gmail.com
Project Links
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file crosschexcloudapi-0.1.0.tar.gz.
File metadata
- Download URL: crosschexcloudapi-0.1.0.tar.gz
- Upload date:
- Size: 5.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bc6b8926901830eaec40fccdcc2301f577b78a877eb7a9ea4cf71e7f946a1400
|
|
| MD5 |
10387aafd19c7910c9529c269fb14acf
|
|
| BLAKE2b-256 |
beb938f893b0c370a5560009b670e3eeef603de9e2512d0e6ca791334e74501b
|
File details
Details for the file crosschexcloudapi-0.1.0-py3-none-any.whl.
File metadata
- Download URL: crosschexcloudapi-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5159f638cac1b6e5f61883b1c9459d761968f0e7abb9819b0fbdd4bc3004a089
|
|
| MD5 |
43910d90d65159bafc6cc9851cd17b94
|
|
| BLAKE2b-256 |
222e8b16632cc6b02ce26b7f00c2c8d1f04af801e34598d710f1af59569c43fd
|