Skip to main content

hikari adapter for Mochi - auto-instruments commands, guild joins/leaves, and health snapshots

Project description

mochi-analytics-hikari

hikari adapter for Mochi analytics.

Install

pip install mochi-analytics mochi-analytics-hikari hikari

Usage

import hikari
from mochi_analytics import MochiClient
from mochi_analytics_hikari import attach_mochi

mochi = MochiClient(url="https://mochi.example.com", api_key="mochi_sk_...")

bot = hikari.GatewayBot(token="...")
detach = attach_mochi(bot, mochi)

bot.run()

hikari runs every shard inside one process, so one snapshot is sent per shard, each carrying that shard's own guild count.

hikari has no built-in command framework, so attach_mochi records commands straight off InteractionCreateEvent. For accurate success and duration, pass auto_track_commands=False and wrap your handlers with wrap_command.

See the hikari guide for the full documentation.

License

Apache-2.0

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

mochi_analytics_hikari-0.2.0.tar.gz (11.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mochi_analytics_hikari-0.2.0-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file mochi_analytics_hikari-0.2.0.tar.gz.

File metadata

  • Download URL: mochi_analytics_hikari-0.2.0.tar.gz
  • Upload date:
  • Size: 11.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mochi_analytics_hikari-0.2.0.tar.gz
Algorithm Hash digest
SHA256 aa796d07078ec9173518037839ce9b1b84666e607242914942d0c978d1ee156c
MD5 03ea918db56e6d4b77b6802caa464772
BLAKE2b-256 93ea99bfe9c5dc8260d96a6cffcd421060872e52ffcec70e5e9edd0f8f6c48a0

See more details on using hashes here.

Provenance

The following attestation bundles were made for mochi_analytics_hikari-0.2.0.tar.gz:

Publisher: release-please.yml on mochi-analytics/mochi-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file mochi_analytics_hikari-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mochi_analytics_hikari-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ecffe0401ec3ab46988b78863796d9f005e8042ee4def65142306f163457728a
MD5 dec7c5180e4c6f5cfa6760ed2c107b57
BLAKE2b-256 67bfa62fdf3b1afca3a3d0424247854783dbbed27d285cafcefeec288577d781

See more details on using hashes here.

Provenance

The following attestation bundles were made for mochi_analytics_hikari-0.2.0-py3-none-any.whl:

Publisher: release-please.yml on mochi-analytics/mochi-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page