monogatari/php-apple-signin
Composer 安装命令:
composer create-project monogatari/php-apple-signin
包简介
php apple sign in,match php 5.6
README 文档
README
PHP library to manage Sign In with Apple identifier tokens, and validate them server side passed through by the iOS client. The liarary come from griffinledingham/php-apple-signin, original library require php version >= 7.0, According to my project needs, I need a libray match 5.6,so change => test => build this.
if you want to use origin library, Please use composer to install:
composer require griffinledingham/php-apple-signin
Installation
Use composer to manage your dependencies and download php-apple-signin:
composer require monogatari/php-apple-signin
Example
<?php use AppleSignIn\ASDecoder; $clientUser = "example_client_user"; $identityToken = "example_encoded_jwt"; $appleSignInPayload = ASDecoder::getAppleSignInPayload($identityToken); /** * Obtain the Sign In with Apple email and user creds. */ $email = $appleSignInPayload->getEmail(); $user = $appleSignInPayload->getUser(); /** * Determine whether the client-provided user is valid. */ $isValid = $appleSignInPayload->verifyUser($clientUser); ?>
统计信息
- 总下载量: 605
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-06-09