Skip to main content

Python SDK for WeChat iLink Bot protocol

Project description

wechat-ilink-python-sdk

Python SDK for the WeChat iLink Bot protocol.

Features

  • QR-code login flow for iLink bot accounts
  • Async HTTP client for iLink APIs
  • Long-polling message loop and dispatch
  • Local credential and state persistence
  • Example echo bot for quick start

Requirements

  • Python 3.10+

Installation

Install the published package from PyPI:

pip install wechat-ilink-sdk

Quick Start

Import the public SDK entry points from the ilink package:

from ilink import ILinkClient, login_with_qr

print(ILinkClient)
print(login_with_qr)

Run the bundled example from a cloned repository:

python example.py

On first run, the bot will ask for QR-code login and cache credentials locally.

Main Modules

  • ilink.auth: QR-code login flow
  • ilink.client: async API client and polling loop
  • ilink.store: local persistence for credentials and context tokens
  • ilink.types: protocol models and enums
  • ilink.utils: helper utilities

Development

Set up a local development environment with test dependencies:

uv sync --extra dev

Run the test suite through the installed package:

uv run pytest

Build release artifacts locally:

uv sync --extra release
uv run python -m build
uv run twine check dist/*

The manual PyPI release checklist lives in docs/releasing.md.

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

wechat_ilink_sdk-0.2.0.tar.gz (34.1 kB view details)

Uploaded Source

Built Distribution

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

wechat_ilink_sdk-0.2.0-py3-none-any.whl (30.4 kB view details)

Uploaded Python 3

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