Skip to main content

Lark / Feishu channel plugin for Bub

Project description

bub-lark

Lark / Feishu chat channel plugin for Bub.

bub-lark adds a native lark channel that can receive bot events and send replies through the Lark / Feishu Open Platform.

Features

  • inbound bot messages through event subscription
  • outbound send, reply, edit, and card update flows
  • text, post, interactive card, image, file, audio, media, and sticker-aware message parsing
  • optional webhook mode for callback delivery
  • bundled lark skill for proactive sends

Install

Once published:

uv pip install bub-lark

For local development next to the Bub repo:

cd ../bub-lark
uv sync

Usage

Configure a Feishu / Lark bot app with message receive events.

Common settings:

  • BUB_LARK_APP_ID
  • BUB_LARK_APP_SECRET
  • BUB_LARK_DOMAIN=feishu or BUB_LARK_DOMAIN=lark
  • BUB_LARK_CONNECTION_MODE=websocket or BUB_LARK_CONNECTION_MODE=webhook

Webhook mode only:

  • BUB_LARK_VERIFICATION_TOKEN
  • BUB_LARK_ENCRYPT_KEY
  • BUB_LARK_WEBHOOK_PORT
  • BUB_LARK_WEBHOOK_PATH

Start the channel:

uv run bub gateway --enable-channel lark

Notes

  • websocket mode is the default for the Feishu domain.
  • webhook mode is available for deployments where callback delivery is preferred or required.
  • Bub ordinary replies are routed through the native outbound path once the inbound message enters the framework.

Research Basis

The plugin design follows Feishu / Lark's official bot-event and message-send model plus community integrations:

Development

uv run pytest -q
uv run ruff check .
uv build

Release

Publishing is driven by GitHub Actions. Create a GitHub Release on main with a tag like v0.1.0 or 0.1.0, and the release workflow will:

  1. normalize the tag to a package version
  2. build the sdist and wheel
  3. publish to PyPI through Trusted Publishing (GitHub OIDC)

No long-lived PYPI_TOKEN secret is required when PyPI Trusted Publisher is configured for .github/workflows/on-release-main.yml.

Contributing

See CONTRIBUTING.md for the local workflow, verification commands, and pull request process.

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

bub_lark-0.1.0.tar.gz (22.9 kB view details)

Uploaded Source

Built Distribution

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

bub_lark-0.1.0-py3-none-any.whl (20.1 kB view details)

Uploaded Python 3

File details

Details for the file bub_lark-0.1.0.tar.gz.

File metadata

  • Download URL: bub_lark-0.1.0.tar.gz
  • Upload date:
  • Size: 22.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for bub_lark-0.1.0.tar.gz
Algorithm Hash digest
SHA256 0ba3ac559f14901a6f6b70ec0f1555e0840a857d2b5dc2ed1a3e684556a02a15
MD5 7d0b9d0767fa5b0dd37461eae877389f
BLAKE2b-256 ce3a9f18f67d30bfae061cd5550f0c0092c1eeea8165b961125a1bb7c5e0f88c

See more details on using hashes here.

Provenance

The following attestation bundles were made for bub_lark-0.1.0.tar.gz:

Publisher: on-release-main.yml on ximenzun/bub-lark

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

File details

Details for the file bub_lark-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: bub_lark-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 20.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for bub_lark-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4e64785aaac2e01e7bcce0549ecb91487f66b7ca0b8eb43b82516507f7e99867
MD5 896701885a9ab3210d58793c97f9dece
BLAKE2b-256 db4c8ace6572f6b6354980e2a07a2aedcd6143bb7971513ade624365cb3cab7d

See more details on using hashes here.

Provenance

The following attestation bundles were made for bub_lark-0.1.0-py3-none-any.whl:

Publisher: on-release-main.yml on ximenzun/bub-lark

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