【发布时间】:2020-06-24 06:11:16
【问题描述】:
我是 nodejs 后端开发人员,我有一个带有 nodejs 后端的应用程序,客户端是 ios,swift。我需要做功能sign in with apple
我发现有两种方法可以使用 Apple 登录。一种是使用restful api,一种是使用本机设备登录。
我知道如何使用 restful api 登录苹果,因为我曾与passportjs 合作,并且我之前使用 fb、twitter 登录过。但是我不明白 sign in with apple (本机方式)如何在 nodejs 端工作。
这里是文章:https://auth0.com/docs/connections/apple-siwa/add-siwa-to-native-app
【问题讨论】:
-
你使用
Firebase认证吗? -
不,我不使用
Firebase进行身份验证 -
@Rob认证后,你知道如何将用户信息入库吗?
-
是的,有一个名为
didCompleteWithAuthorization authorization的delegate方法。tutorial中也提到了,一旦你获取了数据,你就可以调用一个 API,将数据传递给服务器,然后你就可以获取所需的数据并将其添加到你的数据库中。
标签: ios node.js swift typescript authentication