Skip to main content

PyPI Maintenance Code Style

Verox

Verox (inspired by discord-ext-ipc) is an implementation of IPC using websockets. It's designed to make dashboard development a lot easier and quicker. While it's aimed at the hikari community, it does not depend on it at all which means you can use it for any discord API wrapper you like.

Installation

pip install verox
Didn't work?
  • pip is not in PATH

    python -m pip install verox
    
  • Check if the path of your python executable matches the path of the interpreter you run your code with
    In UNIX-like systems:

    which python
    

Usage

Verox is split into client-side and server-side. The client-side is usually the web app, the server-side is the bot.

The following example uses quart and hikari:

webapp.py

from quart import Quart
from verox import Client

app = Quart(__name__)
client = Client("your_secret_key")

@app.route("/")
async def home():
    count = await client.request("guild_member_count", guild_id=1234567890)
    return str(count)

@app.after_serving
async def close_client():
    await client.close()

app.run(debug=True)

bot.py

import hikari
import verox

bot = hikari.GatewayBot(token="your_token", intents=hikari.Intents.ALL)
server = verox.Server("your_secret_key") #must match the secret key of your client

@verox.endpoint()
async def guild_member_count(context: verox.Context):
    return len(bot.cache.get_members_view_for_guild(context.data.guild_id))

@bot.listen()
async def close_server(event: hikari.StoppingEvent):
    await server.close()

server.start()
bot.run()

For more advanced examples, please take a look at examples and its README

Release files for verox 0.0.11

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

Source distribution (sdist)

Source distribution for verox 0.0.11
File Size Uploaded
verox-0.0.11.tar.gz 8.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for verox 0.0.11
File Interpreter ABI Platform
verox-0.0.11-py3-none-any.whl Python 3 none any Details

Total release size: 15.8 kB

Release files / verox-0.0.11.tar.gz

Download URL verox-0.0.11.tar.gz
Size 8.1 kB
Tags Source
SHA-256 checksum
How to use checksums
8a47eee78d6e389e65f71cefe01b19cc24ce9633b542fd9ae3b10df166dfff31
BLAKE2b-256 checksum
How to use checksums
5e56c9595f34604a716355d33c31c7b5d0e2db24a937396dcbac5e7f8ea5a536
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.2

Release files / verox-0.0.11-py3-none-any.whl

Download URL verox-0.0.11-py3-none-any.whl
Size 7.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e66f119012438733840032cfd0cae5db0bf3a3df835f73a77042e91e1050b7f6
BLAKE2b-256 checksum
How to use checksums
5772f05e684bdb4b5a1b12f68647d7c02018bc6cb03ae3ad6314648f56c38e5a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.2

Release history Release notifications | RSS feed

This release

0.0.11 This release

2 release files

0.0.10

2 release files

0.0.9

2 release files

0.0.8

2 release files

0.0.7

2 release files

0.0.6

2 release files

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