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.1.tar.gz (24.5 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.1-py3-none-any.whl (21.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: bub_lark-0.1.1.tar.gz
  • Upload date:
  • Size: 24.5 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.1.tar.gz
Algorithm Hash digest
SHA256 42a73b2391d924fc91c61dfaf7fbb63cd2f2d48a1ccd1c9dc22dfbb513d0910a
MD5 a2b3cdec7e6ff37f5691d3c4ee2867f9
BLAKE2b-256 8484404be824b986c702eb0d5b7501c896addea2c975b7bbf9374508250e3e66

See more details on using hashes here.

Provenance

The following attestation bundles were made for bub_lark-0.1.1.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.1-py3-none-any.whl.

File metadata

  • Download URL: bub_lark-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 21.3 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.1-py3-none-any.whl
Algorithm Hash digest
SHA256 340cc6eeaf731ce65fe7fce2db62bfc20b740413760af8bb5f26fbba7cdf9eb7
MD5 f82ba6bb193117ca67f8d27fe193d9a4
BLAKE2b-256 f9a3f27f846274c254c98b1049cfbfa89b6f4259e4dc588361b14325a7cba8fd

See more details on using hashes here.

Provenance

The following attestation bundles were made for bub_lark-0.1.1-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