אסימוני סשן הם מחרוזות (או אובייקטים) שנוצרים על ידי המשתמשים ועוקבים אחרי קריאות של השלמה אוטומטית (חדש) כסשנים. ההשלמה האוטומטית (חדש) משתמשת באסימוני סשן כדי לקבץ את שלבי השאילתה והבחירה של חיפוש השלמה אוטומטית של משתמש לסשן נפרד למטרות חיוב.
המשתמשים אחראים ליצירת טוקנים של סשנים לכל סשן. אסימוני סשן
חייבים להיות מחרוזות Base64 בטוחות לשימוש בכתובות URL ובשמות קבצים. המשתמשים יכולים ליצור אסימוני סשן בכל דרך, אבל Google ממליצה להשתמש במזהים ייחודיים אוניברסליים (UUID) בגרסה 4 לאסימוני סשן.
הסשן מתחיל בקריאה ל-Autocomplete (New) ומסתיים בקריאה ל-Place Details (New) או ל-Address Validation. בכל סשן יכולות להיות כמה שאילתות של השלמה אוטומטית (חדשה), ואחריהן בקשה אחת של פרטי מקום (חדש) או אימות כתובת. מפתחות ה-API שמשמשים לכל בקשה בסשן צריכים להיות שייכים לאותו פרויקט במסוף Google Cloud.
אסימוני סשן מסתיימים בדרכים הבאות:
מתבצעת קריאה ל-Place Details (New).
הפונקציה Address Validation מופעלת.
הסשן ננטש.
אחרי שהסשן מסתיים, האסימון כבר לא תקף. האפליקציה צריכה ליצור אסימון חדש לכל סשן חדש. אם הפרמטר sessionToken לא מצוין, או אם משתמשים מחדש באסימון סשן, הסשן החדש יחויב כאילו לא סופק אסימון סשן (כל בקשה תחויב בנפרד).
[[["התוכן קל להבנה","easyToUnderstand","thumb-up"],["התוכן עזר לי לפתור בעיה","solvedMyProblem","thumb-up"],["סיבה אחרת","otherUp","thumb-up"]],[["חסרים לי מידע או פרטים","missingTheInformationINeed","thumb-down"],["התוכן מורכב מדי או עם יותר מדי שלבים","tooComplicatedTooManySteps","thumb-down"],["התוכן לא עדכני","outOfDate","thumb-down"],["בעיה בתרגום","translationIssue","thumb-down"],["בעיה בדוגמאות/בקוד","samplesCodeIssue","thumb-down"],["סיבה אחרת","otherDown","thumb-down"]],["עדכון אחרון: 2025-09-10 (שעון UTC)."],[[["\u003cp\u003eSession tokens group Autocomplete (New) queries and selection phases into a session for billing purposes, ending with a call to Place Details (New) or Address Validation.\u003c/p\u003e\n"],["\u003cp\u003eSession tokens must be URL- and filename-safe base64 strings, with Google recommending the use of version 4 universally unique identifiers (UUIDs).\u003c/p\u003e\n"],["\u003cp\u003eA session begins with an Autocomplete (New) call, allowing for multiple queries within the session before concluding with Place Details (New) or Address Validation.\u003c/p\u003e\n"],["\u003cp\u003eEach request within a session must utilize API keys associated with the same Google Cloud Console project, with sessions terminating upon calling Place Details (New), Address Validation, or abandonment.\u003c/p\u003e\n"],["\u003cp\u003eOmitting or reusing session tokens results in individual request billing, while fresh tokens are required for each new session to leverage session-based pricing.\u003c/p\u003e\n"]]],["Session tokens, user-generated strings, track Autocomplete (New) calls as sessions for billing. Users create tokens, ideally UUIDs, for each session. A session starts with Autocomplete (New) and ends with Place Details (New) or Address Validation, allowing multiple Autocomplete queries. The API keys must be from the same project. Omitting the token or reusing it results in per-request billing. Session tokens are invalid after use and can not be exchanged between places API and places API (new) or Address Validation.\n"],null,[]]