खास जानकारी

OAuth-based App Flip Linking (App Flip) allows your users to easily and quickly link their accounts in your authentication system to their Google accounts. If your app is installed on your user’s phone when they initiate the account linking process, they are seamlessly flipped to your app to obtain user authorization.

This approach provides a faster and easier linking process since the user does not have to re-enter their username and password to authenticate; instead, App Flip leverages the credentials from the user's account on your app. Once a user has linked their Google account with your app, they can take advantage of any integrations that you have developed.

You can set up App Flip for both iOS and Android apps.

This figure shows the steps for a user to link their Google account
            to your authentication system. The first screenshot shows how a user
            can select your app if their Google account is linked to your app.
            The second screenshot shows the confirmation for linking their
            Google account with your app. The third screenshot shows a
            successfully linked user account in the Google app.
Figure 1. Account linking on a user's phone with App Flip.

Requirements

To implement App Flip, you must fulfill the following requirements:

  • You must have an Android or iOS app.
  • You must own, manage and maintain an OAuth 2.0 server which supports the OAuth 2.0 authorization code flow.

OAuth लिंकिंग के ऑथराइज़ेशन कोड फ़्लो के बारे में ज़्यादा जानने के लिए, अपना OAuth सर्वर लागू करना लेख पढ़ें.

Design guidelines

This section describes the design requirements and recommendations for the App Flip account linking consent screen. After Google calls your app, your app displays the consent screen to the user.

Requirements

  1. You must communicate that the user’s account is being linked to Google, not to a specific Google product, such as Google Home or Google Assistant.

Recommendations

We recommend that you do the following:

  1. Display Google's Privacy Policy. Include a link to Google’s Privacy Policy on the consent screen.

  2. Data to be shared. Use clear and concise language to tell the user what data of theirs Google requires and why.

  3. Clear call-to-action. State a clear call-to-action on your consent screen, such as “Agree and link.” This is because users need to understand what data they're required to share with Google to link their accounts.

  4. Ability to cancel. Provide a way for users to go back or cancel, if they choose not to link.

  5. Ability to unlink. Offer a mechanism for users to unlink, such as a URL to their account settings on your platform. Alternatively, you can include a link to Google Account where users can manage their linked account.

  6. Ability to change user account. Suggest a method for users to switch their account(s). This is especially beneficial if users tend to have multiple accounts.

    • If a user must close the consent screen to switch accounts, send a recoverable error to Google so the user can sign in to the desired account with OAuth linking and the implicit flow.
  7. Include your logo. Display your company logo on the consent screen. Use your style guidelines to place your logo. If you wish to also display Google's logo, see Logos and trademarks.

This figure shows an example consent screen with call-outs to the
            individual requirements and recommendations to be followed when
            you design a user consent screen.
Figure 2. Account linking consent screen design guidelines.

OAuth पर आधारित ऐप्लिकेशन फ़्लिप की सुविधा सेट अप करना

यहां दिए गए सेक्शन में, OAuth पर आधारित ऐप्लिकेशन फ़्लिप की ज़रूरी शर्तों के बारे में बताया गया है. साथ ही, Actions console में ऐप्लिकेशन फ़्लिप प्रोजेक्ट को कॉन्फ़िगर करने का तरीका बताया गया है.

कार्रवाई बनाना और OAuth 2.0 सर्वर सेट अप करना

ऐप्लिकेशन फ़्लिप की सुविधा कॉन्फ़िगर करने से पहले, आपको ये काम करने होंगे:

Actions console में ऐप्लिकेशन फ़्लिप की सुविधा कॉन्फ़िगर करना

यहां दिए गए सेक्शन में, Actions console में ऐप्लिकेशन फ़्लिप को कॉन्फ़िगर करने का तरीका बताया गया है.

  1. सबसे ऊपर मौजूद नेविगेशन में जाकर, डेवलप करें पर क्लिक करें. इसके बाद, बाईं ओर मौजूद नेविगेशन में खाता लिंक करना पर क्लिक करें.
  2. खाता जोड़ना के बगल में मौजूद स्विच को टॉगल करके चालू करें.
  3. खाता बनाना में जाकर, नहीं, मुझे सिर्फ़ अपनी वेबसाइट पर खाता बनाने की अनुमति देनी है को चुनें.
  4. आगे बढ़ें पर क्लिक करें.
  5. लिंक करने का टाइप में जाकर, ड्रॉप-डाउन मेन्यू से OAuth और ऑथराइज़ेशन कोड चुनें.
  6. आगे बढ़ें पर क्लिक करें.
  7. OAuth क्लाइंट की जानकारी में दिए गए सभी फ़ील्ड भरें. (अगर ऐप्लिकेशन फ़्लिप की सुविधा काम नहीं करती है, तो फ़ॉलबैक के तौर पर सामान्य OAuth का इस्तेमाल किया जाता है.)
  8. आगे बढ़ें पर क्लिक करें.
  9. खाता लिंक करने के लिए अपने ऐप्लिकेशन का इस्तेमाल करें (ज़रूरी नहीं) में जाकर, iOS के लिए चालू करें को चुनें.
  10. यूनिवर्सल लिंक फ़ील्ड भरें. यूनिवर्सल लिंक के बारे में ज़्यादा जानकारी के लिए, ऐप्लिकेशन और वेबसाइटों को आपके कॉन्टेंट से लिंक करने की अनुमति देना लेख पढ़ें.
  11. अगर आपको अपने क्लाइंट को कॉन्फ़िगर करना है, तो स्कोप जोड़ें. इसके बाद, अपने क्लाइंट को कॉन्फ़िगर करें (ज़रूरी नहीं) में जाकर, स्कोप जोड़ें पर क्लिक करें. अगर नहीं दिखता है, तो आगे बढ़ें पर क्लिक करें.
  12. जांच के निर्देशों में, प्लेसहोल्डर के तौर पर test (या कोई अन्य स्ट्रिंग) टाइप करें. (अगर आपको वाकई में अपना ऐक्शन पब्लिश करने के लिए सबमिट करना है, तो ही इस फ़ील्ड में टेस्ट खाते की जानकारी भरें.)
  13. सेव करें पर क्लिक करें.

अब अपने iOS या Android ऐप्लिकेशन में ऐप्लिकेशन फ़्लिप की सुविधा लागू करने के लिए, अगले सेक्शन पर जाएं.

अपने नेटिव ऐप्लिकेशन में ऐप्लिकेशन फ़्लिप की सुविधा लागू करना

ऐप्लिकेशन फ़्लिप की सुविधा लागू करने के लिए, आपको अपने ऐप्लिकेशन में उपयोगकर्ता की अनुमति वाले कोड में बदलाव करना होगा, ताकि Google से डीप लिंक स्वीकार किया जा सके.

अपने डिवाइस पर ऐप्लिकेशन फ़्लिप की सुविधा आज़माना

आपने कंसोल और अपने ऐप्लिकेशन में, कार्रवाई बना ली है और ऐप्लिकेशन फ़्लिप की सुविधा कॉन्फ़िगर कर ली है. अब अपने मोबाइल डिवाइस पर ऐप्लिकेशन फ़्लिप की सुविधा की जांच की जा सकती है. ऐप्लिकेशन फ़्लिप की सुविधा को आज़माने के लिए, Google Assistant ऐप्लिकेशन का इस्तेमाल किया जा सकता है.

Assistant ऐप्लिकेशन से ऐप्लिकेशन फ़्लिप की सुविधा को आज़माने के लिए, यह तरीका अपनाएं:

  1. Actions console पर जाएं और अपना प्रोजेक्ट चुनें.
  2. सबसे ऊपर मौजूद नेविगेशन में, टेस्ट करें पर क्लिक करें.
  3. Assistant ऐप्लिकेशन से, खाते को लिंक करने की प्रोसेस शुरू करने के लिए:
    1. Google Assistant ऐप्लिकेशन खोलें.
    2. सेटिंग पर क्लिक करें.
    3. Assistant टैब पर, होम कंट्रोल पर क्लिक करें.
    4. जोड़ें(+) पर क्लिक करें.
    5. सेवा देने वाली कंपनियों की सूची में से, अपनी कार्रवाई चुनें. यह सूची में “[test]” के तौर पर दिखेगा. सूची से [test] कार्रवाई चुनने पर, आपका ऐप्लिकेशन खुलना चाहिए.
    6. पुष्टि करें कि आपका ऐप्लिकेशन लॉन्च हो गया है. इसके बाद, अनुमति पाने की प्रोसेस की जांच शुरू करें.