להורדת Android Consumer SDK
קל לארגן דפים בעזרת אוספים
אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
כדי לשתף מסלולים של נסיעות לפי דרישה באפליקציות צרכניות ל-Android, צריך להשתמש ב-Consumer SDK. מידע נוסף על מעקב אחרי נסיעה באמצעות Consumer SDK זמין במאמר מעקב אחרי נסיעה ב-Android.
כדי להגדיר את Consumer SDK באפליקציית צרכנים ל-Android, פועלים לפי השלבים הבאים:
- בדיקת דרישות המינימום של המערכת
- קבלת Consumer SDK
- הגדרת פרויקט במסוף Google Cloud
- קבלת טוקנים של אימות
- אתחול של Consumer SDK
בדיקת דרישות המערכת המינימליות
אפשר לעיין בהערות לגבי הגרסה כדי לראות את הדרישות המינימליות של גרסת Consumer SDK שבה אתם משתמשים. לעיון בנתוני הגרסה
כדי להשתמש ב-Consumer SDK: האפליקציה צריכה לטרגט ל-minSdkVersion
23 ומעלה.
כדי להפעיל אפליקציה שמשתמשת ב-Consumer SDK: מכשירי Android לנייד צריכים לעמוד בדרישות המינימליות הבאות:
קבלת Consumer SDK ממאגר Google Maven
אפשר להוריד את גרסאות Consumer SDK 2.1.0 ואילך ממאגר Google Maven.
הערוץ של המאגר הפרטי שנעשה בו שימוש בעבר הוצא משימוש.
Gradle
מוסיפים לקובץ build.gradle
את הנתונים הבאים:
repositories {
...
google()
}
Maven
מוסיפים לקובץ pom.xml
את הנתונים הבאים:
<project>
...
<repositories>
<repository>
<id>google-maven-repository</id>
<url>https://maven.google.com</url>
</repository>
</repositories>
...
</project>
המאמרים הבאים
הגדרת פרויקט במסוף Google Cloud
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2025-09-10 (שעון UTC).
[[["התוכן קל להבנה","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\u003eThe Google Maps Platform Consumer SDK enables journey sharing for on-demand trips in Android consumer apps.\u003c/p\u003e\n"],["\u003cp\u003eAndroid apps using the SDK must target minSdkVersion 23 or higher and have Google Play services installed.\u003c/p\u003e\n"],["\u003cp\u003eThe Consumer SDK can be obtained from the Google Maven repository (versions 2.1.0 and later).\u003c/p\u003e\n"],["\u003cp\u003eBefore implementing, ensure the device meets minimum requirements including Android 6.0 (API level 23) or later.\u003c/p\u003e\n"],["\u003cp\u003eNext steps include configuring a Google Cloud Console project and obtaining authentication tokens.\u003c/p\u003e\n"]]],["To share on-demand journeys in Android apps, utilize the Consumer SDK. First, verify the minimum system requirements, which include Android 6.0 (API level 23) or later, and Google Play services. Next, retrieve the Consumer SDK (version 2.1.0 or later) from the Google Maven repository by modifying the `build.gradle` or `pom.xml` file to include the Google repository. Finally, configure a Google Cloud console project. Authentication and SDK initialization are also required.\n"],null,[]]