Get user's phone number from C++ using Firebase

微笑、不失礼 提交于 2019-12-25 18:57:49

问题


I'm trying to check user's phone number on the server side with C++. Client side looks ok, but on the server side I can only decode JWT from client and find out Firebase ID of the user, but of course this is not what I need.

I still need to know phone number of the user, and I understand that I can do this with user ID and Firebase admin SDK, but I can't find admin SDK for C++ or any web-API which I could use from everywhere. So, how can I know user's phone number from C++?


回答1:


There is no Firebase Admin SDK for C++.

What you could do is use Cloud Functions for Firebase to run the Admin SDK for Node.js on Google's servers and then expose what you need in a HTTP Function. You can then simply call this URL from your C++ code.

Just be sure to properly secure access to that HTTP endpoint, since otherwise you might be leaking sensitive information.



来源:https://stackoverflow.com/questions/45426837/get-users-phone-number-from-c-using-firebase

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!