sign_in_with_huawei 0.0.2 copy "sign_in_with_huawei: ^0.0.2" to clipboard
sign_in_with_huawei: ^0.0.2 copied to clipboard

The Flutter plugin for Signing In with HUAWEI ID (on HarmonyOS)

sign_in_with_huawei #

用于 HarmonyOS 上华为账号登录的 Flutter 插件

安装 #

flutter pub add sign_in_with_huawei

或者将其添加到你的 pubspec.yaml 文件中

dependencies:
    sign_in_with_huawei: ^0.0.2

前提条件 #

在开始之前,请先阅读 开发准备华为账号登录(获取UnionID/OpenID)

使用方法 #

final response = await SignInWithHuawei.instance.authById(
  forceLogin: true,
  state: "any state",
  nonce: "any nonce",
  idTokenAlg: IdTokenSignAlgorithm.PS256,
);

print(response);
// response.state
// response.authCode
// response.idToken
// response.openID
// response.unionID

限制 #

当前插件仅实现了 华为账号登录(获取UnionID/OpenID)

华为账号一键登录(获取手机号和UnionID/OpenID) 尚未实现,欢迎 PR

0
likes
130
pub points
10%
popularity

Publisher

verified publisher0x0.ink

The Flutter plugin for Signing In with HUAWEI ID (on HarmonyOS)

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on sign_in_with_huawei