با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
هنگامی که پیوند حساب را در Action خود پیاده سازی می کنید، داده های کاربر را مدیریت می کنید، بنابراین رعایت بهترین شیوه های پیوند حساب بسیار مهم است. علاوه بر این، پیروی از بهترین شیوهها، تجربه کاربری کم اصطکاک را فراهم میکند که تعداد کاربرانی را که با موفقیت حساب خود را پیوند میدهند، به حداکثر میرساند. Action شما باید از دستورالعملهای مکالمه عمومی Google، علاوه بر بهترین شیوههای ارائهشده در اینجا برای بهترین تجربه کاربری، پیروی کند.
این صفحه به بهترین شیوه های مکالمه و پیاده سازی برای Action شما که از پیوند حساب استفاده می کند، می پردازد.
گفتگو
وقتی مکالمه ای را برای Action خود طراحی می کنید که از پیوند حساب استفاده می کند، حتماً این دستورالعمل ها را دنبال کنید:
فقط در صورتی از پیوند حساب استفاده کنید که دسترسی به داده های حساب کاربران تجربه غنی تری را برای Action شما فراهم کند. برای مثال، استفاده از پیوند حساب میتواند یک اقدام سفارش نوشیدنی را با اجازه دادن به Action برای به خاطر سپردن نوشیدنیهای مورد علاقه کاربر و پیشنهاد نوشیدنیهای جدید برای امتحان بر اساس سفارشهای گذشته، افزایش دهد. اگر میخواهید فقط یک حساب را پیوند دهید تا Action شما بتواند به نام کاربر اشاره کند، پیوند حساب ضروری نیست.
از درخواست پیوند حساب به عنوان اولین درخواست Action خود استفاده نکنید. الزام کاربران به پیوند دادن حساب خود قبل از اینکه بتوانند Action شما را شروع کنند، میتواند باعث ایجاد یک تجربه ناامیدکننده شود. درعوض، از کاربر بخواهید تا حساب خود را در زمانی که جمع آوری داده ها برای ادامه کار کاربران ضروری است، پیوند دهد.
به عنوان مثال، اولین پیام Action برای سفارش نوشیدنی به کاربر می تواند این باشد: "به Boba Bonanza خوش آمدید! آیا آماده سفارش هستید یا می خواهید نوشیدنی ها را با شما مرور کنم؟" در این حالت، کاربر باید بتواند گزینههای نوشیدنی را بدون ورود به سیستم بشنود. هنگامی که درخواست سفارش نوشیدنی میکند، Action باید از کاربر بخواهد تا حساب خود را پیوند دهد.
رشته زمینه را در راهنمای ورود به حساب کاربری سفارشی کنید تا بگویید چرا باید کاربر حساب خود را پیوند دهد. لازم است زمینه ای فراهم شود تا اطمینان حاصل شود که کاربران با نحوه استفاده از داده هایشان احساس راحتی می کنند.
برای نمونه اقدام سفارش نوشیدنی ما، می توانید رشته زمینه زیر را ارائه دهید: "برای به خاطر سپردن نوشیدنی های مورد علاقه خود و ارائه پیشنهادهای سفارشی..."
پیوند دادن حساب نباید به فراخوانی صریح از طرف کاربر نیاز داشته باشد . به عبارت دیگر، کاربر هرگز نباید برای پیوند دادن حساب خود بگوید "ورود به سیستم". در عوض، باید به کاربر این امکان داده شود که کاری را انجام دهد که نیاز به پیوند حساب دارد. سپس Action شما باید به آنها بگوید که برای انجام این کار باید حساب خود را پیوند دهند.
این دستورالعمل بهترین روش عمومی برای احراز هویت و مجوز است. زمانی که کاربران بدانند چرا به اطلاعات حسابشان نیاز دارید، احتمال بیشتری وجود دارد که حساب خود را پیوند دهند.
به عنوان مثال، در اکشن فرضی سفارش نوشیدنی، تا زمانی که کاربر درخواست سفارش نوشیدنی ندهد، نباید از کاربر خواسته شود حساب خود را پیوند دهد، که لازم است حساب خود را پیوند دهد.
پس از اینکه کاربر حساب خود را پیوند داد، باید همه گزینه هایی را که کاربر در حال حاضر پس از پیوند دادن حساب خود دارد، تکرار کنید. به عنوان مثال، هنگامی که کاربر حساب خود را در Action فرضی سفارش نوشیدنی پیوند داد، Action شما میتواند چیزی شبیه به زیر بگوید: «اکنون که حساب شما پیوند شده است، میتوانید نوشیدنی سفارش دهید، پیشنهادات نوشیدنیهایی را که ممکن است دوست داشته باشید بررسی کنید، یا ببینید چه چیز جدیدی در منو است. پس، دوست دارید چه کار کنید؟"
اگر کاربر شما رضایت Google را برای دسترسی به حساب خود نمی دهد، می توانید یک «جریان مهمان» جایگزین و محدود از طریق Action خود به او ارائه دهید. در این صورت، باید به کاربر اطلاع دهید که بدون پیوند دادن حساب خود چه کاری می تواند انجام دهد.
برای مثال، اگر کاربر رضایت ندهد، مکالمه با Action سفارش نوشیدنی شما میتواند به شکل زیر باشد:
دستیار
برای دریافت سفارش معمول شما، به نام شما و غیره نیاز دارم. آیا می توانم آن ها را از Google داشته باشم؟
کاربر
خیر
دستیار
بسیار خوب، همچنان می توانید منو را ببینید یا تخفیف های امروز را بررسی کنید. دوست دارید چه کار کنید؟
تاریخ آخرین بهروزرسانی 2025-07-24 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-24 بهوقت ساعت هماهنگ جهانی."],[[["\u003cp\u003eAccount linking should only be used to enhance user experience with personalized features, not for basic functionalities like addressing the user by name.\u003c/p\u003e\n"],["\u003cp\u003eThe account linking prompt should be integrated naturally into the conversation flow, triggered when user actions require account access, rather than being the initial interaction.\u003c/p\u003e\n"],["\u003cp\u003eTransparency is crucial; clearly explain why account linking is needed using the context string in the Account Sign-in helper intent to foster user trust.\u003c/p\u003e\n"],["\u003cp\u003eUsers should not have to explicitly request account linking; the Action should guide them through the process when necessary based on their chosen actions.\u003c/p\u003e\n"],["\u003cp\u003eOffer a limited 'guest flow' for users who decline account linking, ensuring they still have access to basic functionalities and outlining the limitations.\u003c/p\u003e\n"]]],["Account linking should enhance user experience, not be a barrier. Prompt users to link accounts only when necessary for features, like remembering preferences. Provide context for why linking is needed, using a customized string. Avoid requiring explicit \"sign in\" commands; instead, offer account-linked actions. After linking, showcase new options. If users decline consent, provide a limited 'guest flow' with alternative functionalities, outlining its capabilities. If issues related to account linking cause users to consistently leave the Action, Google will not actively promote it.\n"],null,["# Best practices (Dialogflow)\n\nWhen you implement account linking in your Action, you are handling user data,\nso it's especially important to comply with account linking best practices.\nAdditionally, following best practices provides a low-friction user experience\nthat maximizes the number of users who successfully link their account. Your\nAction should follow Google's general\n[conversational guidelines](https://designguidelines.withgoogle.com/conversation/)\nin addition to the best practices presented here for the best user experience.\n\nThis page goes over both conversational and implementation best practices for\nyour Action that uses account linking.\n| **Note:** If users are leaving your Action consistently because of account linking issues, Google will not actively promote your Action.\n\nConversation\n------------\n\nWhen you design the conversation for your Action that uses account linking, be\nsure to follow these guidelines:\n\n- **Only use account linking if accessing users' account data provides a\n richer experience for your Action.** For example, using account linking could enhance a drink-ordering Action by allowing the Action to remember a user's favorite drinks and suggest new drinks to try based on their past orders. If you only want to link an account so your Action can refer to the user by name, then account linking isn't necessary.\n- **Don't use the account linking prompt as the first prompt of your Action.**\n Requiring users to link their account before they can start your Action can\n cause a frustrating experience. Instead, prompt the user to link their\n account when collecting the data is necessary for users to continue.\n\n For example, a drink-ordering Action's first message to the user could be,\n *\"Welcome to Boba Bonanza! Are you ready to order or do you want me to go\n through the drinks with you?\"* In this case, the user should be able to hear\n the drink options without signing in. When they ask to order a drink,\n the Action should then ask the user to link their account.\n- **Customize the context string in the [Account Sign-in helper intent](/assistant/df-asdk/helpers#account_sign-in)\n to communicate why you need the user to link their account.** It's necessary\n to provide context to make sure users feel comfortable with how their data\n is being used.\n\n For our example drink-ordering Action, you could provide the following\n context string: *\"To remember your favorite drinks and offer customized suggestions...\"*\n- **Account linking should not require an explicit invocation from the user's\n end**. In other words, the user should never have to say \"sign in\" to link\n their account; instead, the user should be given the option to do something\n that requires account linking. Your Action should then tell them that they\n need to link their account to do so.\n\n This guideline is a general best practice for authentication and\n authorization. Users are more likely to link their account when they know\n why you need their account information.\n\n For example, in the hypothetical drink-ordering Action, the user should not\n be asked to link their account until they ask to order a drink, which\n requires them to link their account.\n- **After the user links their account, you should reiterate all the options\n the user has now that their account is linked.** For example, once the user\n has linked their account in the hypothetical drink-ordering Action, your\n Action could say something like the following: *\"Now that your account's\n linked, you can order a drink, check out suggestions for drinks you might\n like, or see what's new on the menu. So, what would you like to do?\"*\n\n- **If your user doesn't give consent for Google to access their account, you\n could provide them with an alternate, limited 'guest flow' through your\n Action.** In this case, you should communicate to the user\n what they can do without linking their account.\n\n For example, if the user doesn't give consent, the conversation with your\n drink-ordering Action could look like the following:\n\n| Assistant | To get your usual order, I need your name, etc. Can I have those from Google? |\n| User | No |\n| Assistant | Okay, you can still see the menu or check out today's discounts. What would you like to do? |\n|-----------|---------------------------------------------------------------------------------------------|"]]