نظرة عامة على المهام المُجدوَلة لحِزم تطوير البرامج (SDK) المخصّصة للمستهلكين
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
خصِّص تجربة المستهلكين للمهام المجدوَلة من خلال السماح لهم بتتبُّع مستوى تقدّم عمليات التسليم أو طلبات الخدمة المجدوَلة.
ما هي حزمة تطوير البرامج (SDK) للمستهلكين الخاصة بالمهام المُجدوَلة؟
حزمة تطوير البرامج (SDK) الخاصة بالمستهلكين هي إحدى ميزات Fleet Engine للمهام المجدوَلة، وتتضمّن أيضًا مجموعات أدوات لإنشاء تجربة المستهلك. تتيح لك مجموعات الأدوات هذه إنشاء عروض مستندة إلى الخريطة لتصوّر تقدّم السائق وعرض حالة المهمة المرتبطة بمحطة توقّف مُجدوَلة. تم تصميم هذه الأداة لتناسب نوعَين أساسيَّين من الجمهور:
- المستخدمون النهائيون من المستهلكين الذين يريدون معرفة حالة تسليم طلب شحن فردي يتناول هذا المستند كيفية تنفيذ تجربة المستهلك هذه باستخدام حزمة Consumer SDK في JavaScript، والتي توفّر الفئة
FleetEngineShipmentLocationProvider
والواجهات المرتبطة بها.
- مشغّلو أساطيل المركبات الذين يريدون تتبُّع حالة التسليم والمركبة لأسطول كامل من المركبات للحصول على معلومات حول تتبُّع أساطيل المركبات، اطّلِع على دليل تتبُّع أساطيل المركبات.

لماذا يجب استخدام Consumer SDK للمهام المُجدوَلة؟
يتيح لك دمج حزمة تطوير البرامج (SDK) الخاصة بالمستهلكين في تطبيقات المستهلكين التي تتضمّن مهامًا مجدولة تقديم تجربة شاملة للمستهلكين، مع إمكانية تعديل المواقع الجغرافية في الوقت الفعلي تقريبًا وتحديد المواقع الجغرافية على الطرق. يمكن للمستهلكين الاطّلاع على الموقع الجغرافي لمركبة التوصيل وتفاصيل تقدّمها، ما يساعدهم في معرفة مكان شحنتهم.
الإجراءات التي يمكن تنفيذها باستخدام Consumer SDK
استخدِم حزمة SDK الخاصة بالمستهلكين لمشاركة معلومات الشحن التالية مع المستهلكين:
- موقع مركبة التوصيل في الوقت الفعلي على الخريطة
- الوقت المقدَّر لوصول الحزمة، مع تعديله حسب الظروف المتغيرة، مثل حركة المرور
- المسار الذي تسلكه المركبة
- المسافة وعدد المحطات المتبقية قبل تسليم الشحنة
يمكنك أيضًا إنشاء تجارب أخرى سلسة للمستهلكين تتضمّن ميزات الموقع الجغرافي داخل تطبيقك أو موقعك الإلكتروني المخصّصَين للمستهلكين استنادًا إلى معلومات الموقع الجغرافي من Driver SDK. للحصول على تفاصيل حول Driver SDK، راجِع نظرة عامة على المهام المُجدوَلة في Driver SDK.
مكوّنات حزمة تطوير البرامج (SDK) المخصّصة للمستهلكين
تحتوي حزمة تطوير البرامج (SDK) الخاصة بالمستهلكين في JavaScript على المكوّنات التالية:
- أحد مكوّنات خريطة JavaScript التي يمكن استخدامها بدلاً من كيان
google.maps.Map
عادي.
- مكوّنات البيانات التي يجب ربطها بخدمة Fleet Engine
- مكوّنات لعرض المركبة والمسار أثناء تقدّمهما نحو الوجهة
- خلاصات البيانات الأولية لوقت الوصول المقدَّر للسائق أو المسافة المتبقية للقيادة
يوضّح الجدول التالي المكوّنات.
المكوّن |
الوصف |
عرض الخريطة |
يعرض عرض الخريطة تقدّم المركبة، ويتم تعديل العرض أثناء تحرّك المركبة على طول مسارها. |
موفِّر الموقع الجغرافي للشحنة |
يوفّر مقدّم خدمة تتبُّع الشحنات خلاصة مواقع جغرافية كي تعرض الخريطة معلومات مفيدة عن الشحنة، مثل موقع استلام الشحنة أو تسليمها وموقع مركبة التسليم ومسارها.
|
أداة جلب الرمز المميز للمصادقة |
يحصل برنامج جلب رموز المصادقة المميّزة بتنسيق JSON Web Token (JWT) من خادم الخلفية للتحقّق من إذن الوصول إلى بيانات الموقع الجغرافي المخزّنة في Fleet Engine. يمكنك تنفيذ أداة جلب لرموز المصادقة كجزء من تطبيق الويب باستخدام مكتبة "مشاركة الرحلة" في JavaScript. يُرجى العِلم أنّه يجب أيضًا تنفيذ خدمة إنشاء رمز JSON المميّز للويب (JWT) في Fleet Engine على خادم الخلفية. |
خيارات نمط الخريطة |
يمكنك استخدام خيارات التنسيق المخصّص لتغيير التنسيق التلقائي للخريطة بما يتناسب مع تنسيق تطبيق الويب. |
كيفية استخدام حزمة تطوير البرامج (SDK) المخصّصة للمستهلكين
الخطوات التالية
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2025-08-31 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-08-31 (حسب التوقيت العالمي المتفَّق عليه)"],[[["\u003cp\u003eThe Consumer SDK enables businesses to provide customers with real-time visibility into the location and progress of their scheduled deliveries or service orders.\u003c/p\u003e\n"],["\u003cp\u003eThis SDK offers tools for creating map-based displays within consumer applications, showing the driver's location, estimated time of arrival, and route information.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can integrate the Consumer SDK to create a comprehensive and seamless delivery tracking experience for their customers, improving transparency and satisfaction.\u003c/p\u003e\n"],["\u003cp\u003eKey components of the SDK include a map view, a location provider, authentication mechanisms, and customizable styling options to tailor the experience.\u003c/p\u003e\n"],["\u003cp\u003eTo begin, developers need to set up the JavaScript Consumer SDK, follow a specific shipment for tracking, and customize the map interface as desired.\u003c/p\u003e\n"]]],[],null,["Tailor the consumer experience for scheduled tasks by allowing consumers to\nfollow the progress of their scheduled deliveries or service orders.\n\nWhat is the Consumer SDK for scheduled tasks?\n\nThe Consumer SDK is a feature of Fleet Engine for scheduled tasks that also\nincludes toolkits to create the consumer experience. These toolkits let you\ncreate map-based displays to visualize a driver's\nprogress and show the status of the task associated with a scheduled stop. It's\ndesigned for two primary audiences:\n\n- **Consumer end users** who want to know delivery status for an individual shipment order. This document covers how to implement that consumer experience with the Consumer SDK in JavaScript, which provides the `FleetEngineShipmentLocationProvider` class and associated interfaces.\n- **Fleet operators** who want to track the delivery and vehicle status for an entire fleet of vehicles. For information about tracking fleets, see the [Fleet tracking guide](/maps/documentation/mobility/operations/fleet-tracking).\n\nWhy use the Consumer SDK for scheduled tasks?\n\nIntegrating the Consumer SDK into your scheduled tasks consumer applications\nlets you provide a comprehensive consumer experience, with near real-time\nlocation updates and road-snapped positions. Your consumers can see the delivery\nvehicle's location and progress details that help them understand where their\nshipment is.\n\nWhat can you do with the Consumer SDK?\n\nUse the Consumer SDK to share the following shipment information with your\nconsumers:\n\n- Delivery vehicle's real-time position on a map.\n- ETA for package arrival, adjusted for changing circumstances, such as traffic.\n- Route the vehicle is taking.\n- Distance and number of stops remaining before their shipment is delivered.\n\nYou can also create other seamless geo-enabled consumer experiences inside your\nconsumer app or website based on location information from the Driver SDK. For\ndetails about the Driver SDK, see the\n[Driver SDK scheduled tasks overview](/maps/documentation/mobility/driver-sdk/scheduled).\n\nConsumer SDK components\n\nThe JavaScript Consumer SDK contains the following components:\n\n- A JavaScript map component that is a drop-in replacement for a standard `google.maps.Map` entity.\n- Data components to connect with Fleet Engine.\n- Components for visualization of the vehicle and route as it progresses to a destination.\n- Raw data feeds for a driver's ETA or the remaining distance to drive.\n\nThe following table describes the components.\n\n| Component | Description |\n|------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Map view | The map view illustrates the progress of the vehicle, updating the view as the vehicle moves along its route. |\n| Shipment location provider | The shipment tracking provider provides a location feed so that the map can display useful information about the shipment, such as the pickup or delivery location of the shipment and the location and route of the delivery vehicle. |\n| Authentication token fetcher | The authentication token fetcher gets JSON Web Tokens (JWTs) from your backend server to authenticate access to the location data stored in Fleet Engine. You implement an authentication token fetcher as part of your web application using the JavaScript Journey Sharing Library. Note that you must also implement a JSON Web Token (JWT) creation service for Fleet Engine on your backend server. |\n| Map style options | You can use custom styling options to change the default styling of your map to match the styling of your web application. |\n\nHow to use the Consumer SDK\n\n|---|----------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| 1 | **Set up the JavaScript Consumer SDK** | For more information, see [Set up the JavaScript Consumer SDK](/maps/documentation/mobility/journey-sharing/scheduled/shipment-tracking/setup). |\n| 2 | **Follow a shipment** | Learn how to initialize the map, start following a shipment, and stop following with appropriate clean up. See [Follow a shipment](/maps/documentation/mobility/journey-sharing/scheduled/shipment-tracking/follow). |\n| 3 | **Customize the map interface** | You can use the JavaScript Consumer SDK for scheduled tasks to customize the map interface, provide marker customization, or style polylines. See [Style a map](/maps/documentation/mobility/journey-sharing/scheduled/shipment-tracking/style-map), [Customize markers](/maps/documentation/mobility/journey-sharing/scheduled/shipment-tracking/customize-markers), and [Customize polylines](/maps/documentation/mobility/journey-sharing/scheduled/shipment-tracking/customize-polylines). |\n\nWhat's next\n\n- [Set up the JavaScript Consumer SDK](/maps/documentation/mobility/journey-sharing/scheduled/shipment-tracking/setup)"]]