GenAuth DocsDocuments
Concepts
User Guide
Development Integration
AgentAuth
Metadata
Development Integration
Multi-tenant (beta)
Console Documentation
Multi-tenant Console
Tenant Console
Saas Application Demo
Concepts
User Guide
Development Integration
AgentAuth
Metadata
Development Integration
Multi-tenant (beta)
Console Documentation
Multi-tenant Console
Tenant Console
Saas Application Demo
Old version
  • Single Page Web Application

  • Mobile and Client Applications

    • Android

    • C#

    • Flutter

    • iOS

      • Quick Start
      • Hosted Pages
      • Components

      • APIs

      • Social Login

        • 微信登录
        • 企业微信登录
        • 飞书登录
        • 苹果帐号登录
        • 手机号一键登录
      • Typical Scenarios

      • Private Deployment
    • React Native
  • Standard Web Application

  • Framework Integration

  • Others

  1. Development Integration
  2. /
  3. Mobile and Client Applications
  4. /
  5. iOS
  6. /
  7. Social Login
  8. /
  9. 苹果帐号登录

¶ 苹果帐号登录

Update time: 2025-07-23 07:34:21
Edit

¶ 第一步:配置苹果帐号登录

首先登录到苹果开发者网站,然后参考这里进行配置:详细步骤


¶ 第二步:初始化 Guard SDK

通过 Swift Package Manager 引入 Guard 依赖并调用初始化函数。详细步骤


¶ 第三步:在工程里面启动 Sign in with Apple

¶ 第四步:发起苹果认证

通过我们提供的语义化 Hyper Component,只需要在 xib 里面放置一个:

AppleLoginButton

所有的逻辑由我们语义化引擎自动处理。如果想自己实现苹果帐号认证,在拿到授权码后可以调用下面接口:

func loginByApple(_ code: String, completion: @escaping(Int, String?, UserInfo?) -> Void)

参数

  • authCode 苹果授权码

示例

AuthClient().loginByApple(authCode) { code, message, userInfo in
    if (code == 200) {
        // userInfo:用户信息
    }
}
Previous article: 飞书登录 Next article: 手机号一键登录
  • 第一步:配置苹果帐号登录
  • 第二步:初始化 Guard SDK
  • 第三步:在工程里面启动 Sign in with Apple
  • 第四步:发起苹果认证

User identity management

Integrated third-party login
Customized authentication process

Enterprise internal management

Single sign-on
Multi-factor authentication
Permission management

Developer

Development Documentation
GitHub (opens new window)

Company

official@genauth.ai
16th Floor, Building B, Beichen Century Center, Chaoyang District, Beijing (Total)
Room 406, 4th Floor, Block B, No. 200, Tianfu Fifth Street, High-tech Zone, Chengdu (Branch)

© Beijing Steamory Technology Co., Ltd.