Clarify few doubts in connectycube Flutter chat sdk - connectycube

We are developing a Flutter app with one to one chat, so the user is able to sign up with phone number, email, Google sign-in, Facebook sign-in, Apple sign in. So, regarding the chat we like to clarify few doubts from your development team:
How do you maintain the uniqueness for each user like auto-generating user-id?
Are we able to change the name of the users before chatting to the opponent?
Are we able to change the notification sound, Can we manage the notification with our own notification(we are using awesome notification flutter)?
Is there an API available to get the chat history for each user?

After getting the correct request for signup (https://developers.connectycube.com/flutter/authentication-and-users?id=user-signup) ConnectyCube's server creates a new user and generates an id for it, and returns newly created user in the response.
User can change their name any time via ‘Update profile’ https://developers.connectycube.com/flutter/authentication-and-users?id=user-profile-update request. The only current user can update the user’s name.
ConnectyCube SDK doesn’t provide any UI solutions. You can use any plugin(s) for displaying the notifications.
The user can fetch only chat history related to this user (https://developers.connectycube.com/flutter/messaging?id=chat-history).
The ConnectyCube has an API for login via Facebook, Firebase phone auth, e-mail, but for Google sign-in and Apple sign in you have to develop your own logic for creating a user and signup it on the ConnectyCube server.

Related

Django Web Application, Facebook login

I am building a basic social media web application and I would like my only login point to be via facebook login. After doing a fare amount of research, I have seen multiple third party authorization frameworks that plug in with facebook, but I was wondering if there were any opinions on what the best foot forward would be.
Additionally, how would I go about still being able to use sessions/cookies within Django if I use fb login?
All answers are appreciated!
You can use SocialAuth (https://github.com/python-social-auth/social-app-django), this app allows you to let users log in via many common SocialMedia-accounts, e.g. facebook. Upon login, the app will create a user in your database, which you can then use as if the user logged in with a local account. Therefore, the session will still be handled by django, fb only sends you some information about the user (e.g. first- and lastname, email, etc. [configurable in your settings.py])

How can I get the code from Server side using Instagram Basic Display API?

I am new to Instagram Basic Display API. All I need is to get the recent media published on my Instagram account. I have followed all the steps mentioned here until step 4. In step 4 when I am accessing the authorize URL it is asking me to log in to my test user instagram account first and then displaying the authorized window. Just imagine this from a user perspective. If a user is clicking on a button and if it is asking for entering the credentials of my account it seems to be like exposing my account details publicly.
Once I click on the authorize button it is redirecting to my redirect_uri and I can get the code.
How can I implement the same from the server-side? There will be no user interaction for the project I am working on. It should happen from the backend itself. I am using Django as the backend server. Please help me with this.
If this is just for your own project and your own Instagram account you can generate access token like it's described here: https://developers.facebook.com/docs/instagram-basic-display-api/overview/#user-token-generator
You don't need the authorization window in that case. On your server just write a code that will send the request to Basic Display API with token created via Token Generator.

AWS Cognito hosted UI integration with a payment system

I use AWS Cognito hosted UI to authenticate & register users on to my web platform.
The registration journey is as follows - I have a single subscription plan. A user wishes to purchase the subscription. He goes through the Cognito UI registration screens & in the end, the user completes the registration process. At the end of this process, I want to redirect the user to a payment portal to complete the payment.
I'm looking to achieve 2 things -
Integrate this registration journey with a payment portal
Once the payment is complete, get Cognito to mark the user as "registered". I'm fine if this has to be handled separately. I wouldn't mind maintaining a subscription status database myself if need be.
You can only customize the CSS of the hosted UI. To achieve what you want you would have to be able to edit the html and/or javascript

Parse-Server Facebook login - link users with Business Mapping API?

I'm Using ParseServer with two different client applications. Since each mobile app is associated with a different Facebook app (different app names, logos...), the current Facebook policy is to issue a foreign user id for same users when authenticating through different Facebook apps.
We'd like to link those two user ids in ParseServer so they will share a single user account. Even when authenticating via different Facebook apps.
According to Facebook documentation the way to do that is by using the token_for_business or "Business Mapping API" to match two user IDs that belong to a single user.
However, ParseServer documentation does not indicate how to use token_for_business or "Business Mapping API".
We are currently using the /users (POST) endpoint for login and registration passing the authData structure for Facebook when Facebook auth is performed.
Assuming ParseServer uses the authData.facebook.id attribute in order to look for existing users once a new login request arrives, its possible to call the facebook API GET /me/ids_for_business and substitute the id in authData with a previously existing user id.
Is this a recommended approach?
Ideally, I'd like to just add my token_for_business to the authData in the login request and have Parse do the rest of the work. Is that supported?
Lastly, is it at all possible to link two facebook users in ParseServer? the authData structure does not seem to allow is as the "facebook" id section is no in any type of array - it seems there is no way to express dual facebook ids under a single user.. Is this changed at any future parse version (currently using Parse 1.6.14 in the client and ParseServer 2.2.19)
Thanks,
Ron

Programatically setting the user and password for authentication. How to avoid the security question?

I'm developing an application for a Hotel where the costumers capture some snapshots and then upload them to their facebook.
Using the graph API it makes you identify yourself on facebook using the security question or identifying your friends.
I want to be able to identify the clients on facebook without the need of pop ups, specifying the user and password that they have previously given me
Is that possible?
If not, if I use the same computer to connect a lot of different people onto facebook, I get asked all the security questions. Can this be avoided with a digital certificate or anything like that?
Edited to add back info that was in an answer
The user 'Authorise my app' already. It's part of the facebook login process.
This should be right way:
The user captures a photo with the webcam.
The user introduces the email and password IN MY OWN FORM
I connect to facebook through my application, submitting the email & password and write some nice text in the user's wall.
This is what i'm doing now:
The user captures a photo with the webcam.
I connect to facebook using my desktop app. A facebook login window appears.
Sometimes, facebook indicates that this computer is login too much accounts, and ask for an aditional security ( phrase or friend's name).
The user grant access to my application.
My application write some nice text in the user's wall.
I need that the user write its own email & password in my form, because there is no keyboard ( it's a touch screen system) And if i show the Windows Touch Screen Window, there is some 'dangerous' keys like 'window' that i do not wan
What you need to do instead is have the user "Authorise your app" this way your application will be given an AccessToken which can then be used to perform the activities you need.
Look into the OAuth protocol and the Graph API
Start here:
http://oauth.net/2/
http://developers.facebook.com/docs/reference/api/
http://developers.facebook.com/tools/explorer/?method=GET&path=616612017