wecom_auth_plus 0.0.1
wecom_auth_plus: ^0.0.1 copied to clipboard
Flutter plugin for WeCom (Enterprise WeChat) auth. Supports configure, app-installed check, register, auth, and auto login flow.
wecom_auth_plus #
A Flutter plugin scaffold for WeCom (Enterprise WeChat) login/auth integration.
Features #
configure(scheme, corpId, agentId)isAppInstalled()register()auth(state)authLoginAuto(...)
Quick Start #
final plugin = WecomAuthPlus();
final result = await plugin.authLoginAuto(
scheme: 'wwauth_your_corpid_agentid',
corpId: 'wwxxxxxxxxxxxxxxxx',
agentId: '1000004',
state: 'tenant_a',
);
API #
configure(scheme, corpId, agentId)isAppInstalled()register({scheme, corpId, agentId})auth({state})authLoginAuto(...)
Current Status #
- Android: reflection-based bridge is available (
configure/install-check/register/auth) and waits for WeCom callback result. - iOS: supports configure/install-check/register/auth with URL callback parsing, plus dynamic SDK invocation fallback when WeCom SDK is available at runtime.
- This package is scaffold-first; production apps should finish strict SDK integration and callback field mapping based on your enterprise account configuration.
Android Integration Notes #
- Ensure your host app has WeCom SDK runtime available.
- Ensure your app scheme/corpId/agentId are configured in WeCom open platform.
- Ensure your host app receives the WeCom callback intent (scheme callback).
iOS Integration Notes #
- Add URL scheme for your WeCom auth scheme in app
Info.plist. - Add
LSApplicationQueriesSchemesincludeswework(and optionallyweixin). - Ensure WeCom open platform config exactly matches your bundle id and scheme.