faganchalabizada/apple-laravel-authorization-code
Composer 安装命令:
composer require faganchalabizada/apple-laravel-authorization-code
包简介
Get User Data with the result code of a apple sign in button
关键字:
README 文档
README
Getting Start!
composer require apple-laravel-authorization-code
Add Service Provider in config/app.php
'providers' => [ ... AnimusCoop\AppleTokenAuth\AppleTokenAuthServiceProvider::class, ] Use
Controller.
use AnimusCoop\AppleTokenAuth\Classes\AppleAuth; $data = [ "client_id" => "", "team_id" => "", "key_id" => "", "key" => storage_path('AuthKey.p8'), //path where is your p8 key example if your key is in storage "code" => "" //code sended by your front end guy ]; $appleAuth = new AppleAuth($data); // if you need only the jwt signed with your p8 key file $jwt = $appleAuth->getJwtSigned(); // Refresh Token and get user Data $user = $appleAuth->getUserData(); Response getUserData()
[ "authorization" => { "access_token": "" "token_type": "Bearer" "expires_in": 3600 "refresh_token": "" "id_token": "" } "user" => { "iss": "https://appleid.apple.com" "aud": "your client id" "exp": 1605393470 "iat": 1605307070 "sub": "" "at_hash": "" "email": "isaias@animus.com.ar" "email_verified": "true" "auth_time": 1605307067 "nonce_supported": true } ] 统计信息
- 总下载量: 500
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-01-04