Validator for data from social networks & messengers
Project description
Social validator
❓ What's this
This is a library for validating data from social networks and messengers, such as identifiers, usernames, etc.
⚡ Motivation
The motivation behind creating this library stemmed from the lack of a centralized database containing restrictions for each service. Often, validating data correctly requires thoroughly analyzing documentation or manually testing validation. This library aims to solve this problem but is currently available only for Python.
💽 Installation
You can use pip or fext to install the library:
fext install social-validator
✨ Usage
The interface for validating the values of each service looks like this:
from social_validator import telegram
# Functions starting with "is" are used for boolean value checking.
telegram.is_valid_id("test_user_id") # True
# Functions starting with "validate" perform full-fledged validation,
# formatting and raising "social_validator.exceptions.ValidationError" if the
# validation fails.
telegram.validate_id("test_user_ID") # "test_user_id"
# Note: Each validation function is based on a corresponding boolean check
# function, but not vice versa.
telegram.validate_command("cmd") and telegram.is_valid_command("cmd")
Documentation for each method is available via docstrings. If you really need documentation as a separate page, please open issue.
⚠️ Roadmap
The project is under development and is moving to a stable version. To track the status, you can follow the link.
🛠️ Contributing
If you want to contribute to development, request a feature, or report a bug, please open an issue with the appropriate label.
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
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
social_validator-0.3.1.tar.gz.File metadata
File hashes
8b9bffdbce19e8874931668557bbe837dc0e5332024c47874910f339e1148ee7f8ce483e744384ab959b97e57d048a42edd4e0f00a987921e1cae722d4a8286252642a51498b13226a6ded143e23dd02See more details on using hashes here.