# π¦ InfinityStoreLib β Discord File Storage Library
A simple Python library that lets you **upload and download files or Python objects using Discord webhooks as cloud storage**.
Data is securely **encrypted with AES**, chunked, and distributed across multiple Discord channels.
---
## π Features
* β
Upload and download files using Discord webhooks
* β
Store and retrieve Python objects (via `json.dumps`)
* β
Automatic AES encryption/decryption
* β
Generates a unique SHA-512 hash as a file identifier
* β
Multi-channel uploads for larger data
* β
Simple, easy-to-use interface
---
## Installation
```bash
pip install .\infinitystorelib-0.0.1-py3-none-any.whl
```
### Dependencies
* `requests`
* `pyAesCrypt`
* `yaml`
* `faker`
* `json`
* `hashlib`
---
## π Usage Guide
### πΉ 1. Import and Setup
```python
from InfinityStoreLib.Discord.Uploader import *
channels = ["https://discord.com/api/webhooks/1382..."]
```
---
### πΉ 2. Upload a File
Uploads a local file to Discord and returns a unique **hash** (used to download it later).
```python
hash = upload_location("test.py", channels)
print("Uploaded file hash:", hash)
```
---
### πΉ 3. Download a File
Downloads the file using its hash and saves it to your specified location.
```python
download_location(hash, "C:/Users/PC/Desktop/test_downloaded.py")
```
---
### πΉ 4. Upload a Python Object
Stores a Python object (e.g., list, dict, etc.) as encrypted JSON.
```python
data = ["test1", "test2", "test3"]
hash = upload_data(data, channels)
print("Data hash:", hash)
```
---
### πΉ 5. Download a Python Object
Downloads and restores the original Python object.
```python
restored_data = download_data(hash)
print("First element:", restored_data[0])
```
---
## How It Works
| Step | Process | Description |
| ---- | -------------- |------------------------------------------------------------------------|
| 1 | **Encryption** | Data is encrypted with AES using a random key |
| 2 | **Chunking** | Data is split into 5β7 MB blocks |
| 3 | **Upload** | Each chunk is uploaded to Discord via webhook |
| 4 | **Index File** | The URLs + encryption key are saved locally, named after the data hash |
| 5 | **Download** | Downloads all chunks, decrypts, and reconstructs the data |
---
## Function Reference
### `upload_location(filepath, channels, key=None)`
Uploads a file to Discord.
**Returns:** file hash (used for download)
---
### `download_location(hash, save_path)`
Downloads a file using its hash and saves it locally.
---
### `upload_data(obj, channels, key=None)`
Uploads any JSON-serializable object.
**Returns:** hash of stored data
---
### `download_data(hash)`
Downloads and reconstructs a stored Python object.
---
## βοΈ Example Workflow
```python
from InfinityStoreLib.Discord.Uploader import *
channels = ["https://discord.com/api/webhooks/1382..."]
# Upload a Python file
hash = upload_location("script.py", channels)
# Download the same file
download_location(hash, "downloads/script_copy.py")
# Upload a Python object
obj = {"user": "Alice", "score": 120}
hash = upload_data(obj, channels)
# Retrieve the object
retrieved = download_data(hash)
print(retrieved)
```
## π§Ύ YAML Configuration (optional)
If you donβt want to hardcode your webhooks, you can use a `cannels.yaml` file:
```yaml
cannels:
- "https://discord.com/api/webhooks/1382..."
- "https://discord.com/api/webhooks/1383..."
```
## Architecture Overview
```text
ββββββββββββββββββββββββββββ
β Your File / Obj β
βββββββββββββ¬βββββββββββββββ
β
βΌ
[ AES Encryption ]
β
βΌ
[ Chunking ]
β
βΌ
ββββββββββββββββββββββββββββββββ
β Discord Webhooks (Channels) β
βββββββββββββββ¬βββββββββββββββββ
β
βΌ
[ Local Index File ]
β
βΌ
[ Download & Decrypt ]
```
---
## License
**MIT License** Β© 2025
Created by *Fabota51*
---
Raw data
{
"_id": null,
"home_page": null,
"name": "InfinityStoreLib",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": "Discord, Infinity, Python, Storage, Uploader",
"author": "Fabota51",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/21/9c/7c773e3fec1c6c538c072dce8506d44b8411c5f2fac90e549375a1eb66a3/infinitystorelib-0.0.1.tar.gz",
"platform": null,
"description": "\n# \ud83d\udce6 InfinityStoreLib \u2014 Discord File Storage Library\n\nA simple Python library that lets you **upload and download files or Python objects using Discord webhooks as cloud storage**.\nData is securely **encrypted with AES**, chunked, and distributed across multiple Discord channels.\n\n---\n\n## \ud83d\ude80 Features\n\n* \u2705 Upload and download files using Discord webhooks\n* \u2705 Store and retrieve Python objects (via `json.dumps`)\n* \u2705 Automatic AES encryption/decryption\n* \u2705 Generates a unique SHA-512 hash as a file identifier\n* \u2705 Multi-channel uploads for larger data\n* \u2705 Simple, easy-to-use interface\n\n---\n\n## Installation\n\n```bash\npip install .\\infinitystorelib-0.0.1-py3-none-any.whl\n```\n\n### Dependencies\n\n* `requests`\n* `pyAesCrypt`\n* `yaml`\n* `faker`\n* `json`\n* `hashlib`\n\n---\n\n## \ud83d\udcd6 Usage Guide\n\n### \ud83d\udd39 1. Import and Setup\n\n```python\nfrom InfinityStoreLib.Discord.Uploader import *\nchannels = [\"https://discord.com/api/webhooks/1382...\"]\n```\n\n---\n\n### \ud83d\udd39 2. Upload a File\n\nUploads a local file to Discord and returns a unique **hash** (used to download it later).\n\n```python\nhash = upload_location(\"test.py\", channels)\nprint(\"Uploaded file hash:\", hash)\n```\n\n---\n\n### \ud83d\udd39 3. Download a File\n\nDownloads the file using its hash and saves it to your specified location.\n\n```python\ndownload_location(hash, \"C:/Users/PC/Desktop/test_downloaded.py\")\n```\n\n---\n\n### \ud83d\udd39 4. Upload a Python Object\n\nStores a Python object (e.g., list, dict, etc.) as encrypted JSON.\n\n```python\ndata = [\"test1\", \"test2\", \"test3\"]\nhash = upload_data(data, channels)\nprint(\"Data hash:\", hash)\n```\n\n---\n\n### \ud83d\udd39 5. Download a Python Object\n\nDownloads and restores the original Python object.\n\n```python\nrestored_data = download_data(hash)\nprint(\"First element:\", restored_data[0])\n```\n\n---\n\n## How It Works\n\n| Step | Process | Description |\n| ---- | -------------- |------------------------------------------------------------------------|\n| 1 | **Encryption** | Data is encrypted with AES using a random key |\n| 2 | **Chunking** | Data is split into 5\u20137 MB blocks |\n| 3 | **Upload** | Each chunk is uploaded to Discord via webhook |\n| 4 | **Index File** | The URLs + encryption key are saved locally, named after the data hash |\n| 5 | **Download** | Downloads all chunks, decrypts, and reconstructs the data |\n\n---\n\n## Function Reference\n\n### `upload_location(filepath, channels, key=None)`\n\nUploads a file to Discord.\n**Returns:** file hash (used for download)\n\n---\n\n### `download_location(hash, save_path)`\n\nDownloads a file using its hash and saves it locally.\n\n---\n\n### `upload_data(obj, channels, key=None)`\n\nUploads any JSON-serializable object.\n**Returns:** hash of stored data\n\n---\n\n### `download_data(hash)`\n\nDownloads and reconstructs a stored Python object.\n\n---\n\n## \u2699\ufe0f Example Workflow\n\n```python\nfrom InfinityStoreLib.Discord.Uploader import *\n\nchannels = [\"https://discord.com/api/webhooks/1382...\"]\n\n# Upload a Python file\nhash = upload_location(\"script.py\", channels)\n\n# Download the same file\ndownload_location(hash, \"downloads/script_copy.py\")\n\n# Upload a Python object\nobj = {\"user\": \"Alice\", \"score\": 120}\nhash = upload_data(obj, channels)\n\n# Retrieve the object\nretrieved = download_data(hash)\nprint(retrieved)\n```\n\n\n## \ud83e\uddfe YAML Configuration (optional)\n\nIf you don\u2019t want to hardcode your webhooks, you can use a `cannels.yaml` file:\n\n```yaml\ncannels:\n - \"https://discord.com/api/webhooks/1382...\"\n - \"https://discord.com/api/webhooks/1383...\"\n```\n\n\n\n## Architecture Overview\n\n```text\n \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\n \u2502 Your File / Obj \u2502\n \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u252c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\n \u2502\n \u25bc\n [ AES Encryption ]\n \u2502\n \u25bc\n [ Chunking ]\n \u2502\n \u25bc\n \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\n \u2502 Discord Webhooks (Channels) \u2502\n \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u252c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\n \u2502\n \u25bc\n [ Local Index File ]\n \u2502\n \u25bc\n [ Download & Decrypt ]\n```\n\n---\n\n## License\n\n**MIT License** \u00a9 2025\nCreated by *Fabota51*\n\n---\n\n\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": null,
"version": "0.0.1",
"project_urls": null,
"split_keywords": [
"discord",
" infinity",
" python",
" storage",
" uploader"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "91cd6551cd17ab44b282a3656bf955c48659278c6d899b655609ea328ad30bd6",
"md5": "cb9cf541e54285988a387cfd322b5e87",
"sha256": "2610dacaa4dd83349cb05ee72163cb86300a76086a2436a039a86b6206e1c598"
},
"downloads": -1,
"filename": "infinitystorelib-0.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "cb9cf541e54285988a387cfd322b5e87",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 5690,
"upload_time": "2025-11-08T14:39:28",
"upload_time_iso_8601": "2025-11-08T14:39:28.270414Z",
"url": "https://files.pythonhosted.org/packages/91/cd/6551cd17ab44b282a3656bf955c48659278c6d899b655609ea328ad30bd6/infinitystorelib-0.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "219c7c773e3fec1c6c538c072dce8506d44b8411c5f2fac90e549375a1eb66a3",
"md5": "48a36bea0b20983925343439a086d7f9",
"sha256": "fc4e7903a039fda24f65231e58bdadd8ce669d8c84fba9bfa31667b20a4bbfca"
},
"downloads": -1,
"filename": "infinitystorelib-0.0.1.tar.gz",
"has_sig": false,
"md5_digest": "48a36bea0b20983925343439a086d7f9",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 6752,
"upload_time": "2025-11-08T14:39:29",
"upload_time_iso_8601": "2025-11-08T14:39:29.645726Z",
"url": "https://files.pythonhosted.org/packages/21/9c/7c773e3fec1c6c538c072dce8506d44b8411c5f2fac90e549375a1eb66a3/infinitystorelib-0.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-11-08 14:39:29",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "infinitystorelib"
}