结合admin使用新的Firebase函数。
我想使用admin.auth().createCustomToken()函数。调用此函数将导致错误消息。
Error: createCustomToken() requires a certificate with "private_key" set.
at FirebaseAuthError.Error (native)
at FirebaseAuthError.FirebaseError [as constructor] (/user_code/node_modules/firebase-admin/lib/ut
我目前正在让我的项目在Firebase上运行。我已经在这里通过这个脚本完成了身份验证。 using System.Collections.Generic;
using UnityEngine;
using GooglePlayGames;
using GooglePlayGames.BasicApi;
using UnityEngine.SocialPlatforms;
using System.Threading.Tasks;
using Firebase;
using Firebase.Auth;
public class FirebaseManager : MonoBehaviour
一个月后,我回到了我的开发环境,运行了firebase serve --only functions。它给了我一些消息,我应该更新我的包。我只是按照说明,在开发机器上本地运行云函数被破坏了:(我从头开始重新启动所有的东西,并将所有依赖项更新到最新版本。不幸的是,我遇到了一些身份验证问题,我没有任何运气:(我得到了这个错误:
Error: Could not load the default credentials. Browse to https://cloud.google.com/docs/authentication/getting-started for more informatio
我有一个云函数驱动的后端架构,它与我的React Native App一起工作。现在,我正在尝试构建一个React应用程序仪表板,这样我就可以可视化我的应用程序的资源和用户行为。我的方法保持不变,将所有调用路由到云函数端点https://[region]-[project].cloudfunctions.net/[function_name]。
挑战是,我得到一个CORS阻止我的请求从浏览器:这是可以理解的,解决方案是set up a middleware to handle CORS,它已经做了,并运行良好。
import * as functions from 'firebase-