定義所有使用者歷程
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
本頁說明如何定義及對應 Google Chat 應用程式的使用者歷程。使用者歷程是指使用者與 Chat 應用程式之間的一系列動作和互動,可協助使用者達成目標。在建構 Chat 應用程式前,請先定義這些歷程,以便找出下列項目:
- 提供錯誤訊息的時機。
- 建議指令的時間點,以協助使用者使用 Chat 應用程式。
- 可簡化使用者流程。
建立所有使用者歷程的流程圖
流程圖是用來將所有使用者 Chat 應用程式互動情形視覺化,並加以思考的實用工具。如果 Chat 應用程式可與其他 Google 服務或 Google 以外的服務搭配使用,請務必一併納入這些互動。理想情況下,流程圖會顯示所有可能的互動,如果工作流程較複雜,則每個使用者歷程都會有流程圖。
下圖是 Chat 應用程式的使用者歷程,可協助使用者透過 Chat 管理 Google 日曆:

上圖顯示使用者想使用 Chat 應用程式查看日曆的步驟:
使用者將 Chat 應用程式新增至聊天室。
Chat 應用程式會傳送歡迎訊息,提示使用者授予存取權。
- 如果使用者拒絕授權存取權,系統會重新傳送先前的歡迎訊息。
- 如果使用者同意授權存取權,就會點選「登入」。
系統會透過對話方塊訊息要求使用者登入。
- 如果使用者無法登入,系統會傳送錯誤訊息,要求使用者嘗試重新登入。
- 如果使用者能夠順利登入,系統會傳送新手上路訊息,說明如何使用 Chat 應用程式。
使用者輸入 /checkCalendar
斜線指令,即可從日曆取得今天的行程。
- 如果 Chat 應用程式無法擷取使用者的日曆,系統會傳送錯誤訊息。
- 如果成功,Chat 應用程式會透過資訊卡訊息傳送今天的時間表。
撰寫使用者故事,引導使用者歷程
使用者故事代表使用者目標,並以清楚的語句描述使用者、工作和故事目的。使用者故事的設計是開放式的,因為滿足所述需求的方法通常不只一種。使用者故事可協助您設定使用者在使用 Chat 應用程式時的操作路徑。
使用者故事的格式如下:身為使用者,我想要執行任務,以便達成目標。在前述範例中,使用者故事如下:身為跨職能員工,我想查看自己的日曆,以便與他人協同合作。
大多數的 Chat 應用程式都有多個使用者案例。舉例來說,Chat 應用程式範例的另一個使用者故事是:身為主管,我希望安排每週會議,邀請所有直屬下屬參加,這樣我們就能共同合作完成專案。針對每個使用者故事,請找出使用者在 Chat 應用程式中的歷程,並建立流程圖,找出與 Chat 應用程式所有可能的互動。
加入圖例
為了協助他人閱讀使用者歷程,請加入圖例,說明哪個形狀代表哪種類型的互動。舉例來說,請為使用者決策點、使用者輸入內容、Chat 應用程式中的成功和失敗結果,以及 Chat 應用程式中的任何訊息,指定獨特的形狀。
考量所有錯誤情境
為確保使用者在使用 Chat 應用程式時不會卡住,請在使用者歷程地圖中加入錯誤情境。定義錯誤發生的方式、撰寫可採行的錯誤訊息,以及使用者如何回應錯誤以達成目標。例如:「使用者名稱或密碼錯誤,請再次嘗試登入。」
找出 Chat 應用程式傳送給使用者的訊息
每個互動結束時,聊天室應用程式都應向使用者傳送訊息,即使只是確認聊天室應用程式已成功完成使用者要求,也要傳送訊息。例如:「歡迎使用排程應用程式。我可以為您安排、重新安排或移除日曆中的活動。輸入 /checkCalendar
即可查看今天的行程。」
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-03-06 (世界標準時間)。
[null,null,["上次更新時間:2025-03-06 (世界標準時間)。"],[[["\u003cp\u003eDefine user journeys with flowcharts to visualize user interactions and potential pain points within your Google Chat app.\u003c/p\u003e\n"],["\u003cp\u003eUtilize user stories (As a \u003cem\u003euser\u003c/em\u003e, I want to \u003cem\u003edo a task\u003c/em\u003e, so I can \u003cem\u003eachieve a goal\u003c/em\u003e) to guide the development of user journeys and ensure alignment with user needs.\u003c/p\u003e\n"],["\u003cp\u003eAccount for all error scenarios within user journeys, crafting actionable error messages to help users recover and continue their workflow.\u003c/p\u003e\n"],["\u003cp\u003eEnsure each user interaction within the journey concludes with a message from the Chat app, providing feedback or guidance to the user.\u003c/p\u003e\n"],["\u003cp\u003eInclude a legend with your user journey flowcharts to clarify the meaning of different shapes and symbols, making them easier to understand.\u003c/p\u003e\n"]]],["Define user journeys as sets of actions between users and a Chat app to achieve goals. Create flowcharts to visualize all interactions, including those with external services. Write user stories in the format: \"As a *user*, I want to *do a task*, so I can *achieve a goal*.\" Include a legend for the flowchart. Map out error scenarios, defining the error, message, and user response. Detail each interaction with a message from the Chat app.\n"],null,["# Define all user journeys\n\nThis page describes how to define and map the user journeys of your\nGoogle Chat app. A *user journey* is a set of actions and\ninteractions between a user and a Chat app that helps\nthe user achieve a goal. Define these journeys before building the\nChat app to identify the following:\n\n- When to provide error messages.\n- When to suggest commands to help users use the Chat app.\n- Where the user flow might be simplified.\n\nCreate a flowchart of all user journeys\n---------------------------------------\n\nFlowcharts are useful tools for both visualizing and thinking through all user\nChat app interactions. If your\nChat app works with other Google services, or\nservices outside of Google, be sure to include these interactions too. Ideally,\nyour flowchart depicts every possible interaction, or for more complicated\nworkflows, a flowchart for every user journey.\n\nThe following flowchart shows the user journey for a\nChat app that helps people manage their\nGoogle Calendar from Chat:\n\nThe preceding diagram shows the following steps of a user wanting to use a\nChat app to check their Calendar:\n\n1. A user adds the Chat app to a space.\n\n2. The Chat app sends a welcome message that prompts\n the user to [authorize access](/workspace/chat/authenticate-authorize).\n\n - If the user refuses to authorize access, the previous welcome message is resent.\n - If the user agrees to authorize access, they click **Sign in**.\n3. The user is asked to sign in from a\n [dialog message](/workspace/chat/dialogs).\n\n - If the user is unable to sign in, an error message is sent asking the user to try signing in again.\n - If the user is able to successfully sign in, an onboarding message is sent that describes how to use the Chat app.\n4. The user types the `/checkCalendar`\n [slash command](/workspace/chat/commands)\n to get today's schedule from Calendar.\n\n - If the Chat app is unable to retrieve the user's calendar, an error message is sent.\n - If successful, the Chat app sends today's schedule in a card message.\n\nWrite user stories to guide your user journeys\n----------------------------------------------\n\nA *user story* represents a user goal, and is written so that the user, task,\nand purpose of the story is clear. User stories are meant to be open-ended\nbecause there's usually more than one way to satisfy the requirements that they\ndescribe. User stories help you set paths for users to follow as they work with\nChat app.\n\nUser stories have the following format: As a *user* , I want to *do a task* , so I\ncan *achieve a goal* . In the previous example, the user story is: As a\n*cross-functional worker* , I want to *check my calendar* so I can\n*collaborate on projects with others*.\n\nMost Chat apps have multiple user stories. For example, another\nuser story for the example Chat app is: As a *manager* ,\nI want to *schedule a weekly meeting that includes all my direct reports* , so we\ncan *collaborate on projects*. For each user story, identify the users' journey\nfor your Chat app and create a flowchart to identify\nall potential interactions with your Chat app.\n\nInclude a legend\n----------------\n\nTo help others read your user journeys, include a legend that describes which\nshape represents which type of interaction. For example, identify a unique shape\nfor user decision points, user input, successful and unsuccessful results from\nyour Chat app, and any messages from the\nChat app.\n\nAccount for all error scenarios\n-------------------------------\n\nTo ensure users never get stuck while working with your\nChat app, include error scenarios in your user journey\nmap. Define how the error occurs,\n[write an actionable error message](/workspace/chat/write-error-messages),\nand identify how the user might respond to the error in order to achieve their\ngoal. For example, \"Wrong username or password. Try signing in again.\"\n\nIdentify the messages your Chat app sends to users\n--------------------------------------------------\n\nEach interaction should end with a message from your\nChat app to the user, even if it's only a message\nconfirming that the Chat app successfully completed the\nuser's request. For example, \"Welcome to the scheduling app. I can schedule,\nreschedule, or remove events from your calendar. Take a look at today's schedule\nby typing `/checkCalendar`.\"\n\nRelated topics\n--------------\n\n- [Set up slash commands to interact with Google Chat users](/workspace/chat/slash-commands)\n- [Write an actionable error message](/workspace/chat/write-error-messages)\n- [Design user interactions](/workspace/chat/interactivity)"]]