Authentication
Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
google.maps.journeySharing.AuthToken
Benutzeroberfläche
Das Autorisierungstoken, das vom Token-Abrufer zurückgegeben wird.
Attribute |
expiresInSeconds |
Typ:number
Die Ablaufzeit in Sekunden. Ein Token läuft nach diesem Zeitraum nach dem Abrufen ab. |
token |
Typ:string
Das Token. |
google.maps.journeySharing.AuthTokenContext
Benutzeroberfläche
Enthält zusätzliche Informationen, die zum Erstellen von JSON Web Tokens erforderlich sind.
Attribute |
deliveryVehicleId optional |
Typ:string optional
Sofern vorhanden, sollte das erstellte Token einen privaten DeliveryVehicleId -Anspruch für die angegebene deliveryVehicleId haben. |
taskId optional |
Typ:string optional
Falls angegeben, sollte das erstellte Token einen privaten TaskId -Anspruch für die angegebene taskId haben. |
trackingId optional |
Typ:string optional
Falls angegeben, sollte das erstellte Token einen privaten TrackingId -Anspruch für die angegebene trackingId haben. |
tripId optional |
Typ:string optional
Falls angegeben, sollte das erstellte Token einen privaten TripId -Anspruch für die angegebene tripId haben. |
vehicleId optional |
Typ:string optional
Falls angegeben, sollte das erstellte Token eine private VehicleId -Anforderung für die angegebene vehicleId haben. |
google.maps.journeySharing.AuthTokenFetcher
typedef
Auth-Token-Funktionstyp.
Eine Funktion, die ein AuthTokenFetcherOptions
-Objekt mit Details zum zu erstellenden Authentifizierungstoken akzeptiert. Diese Funktion sollte das Token erstellen und ein AuthToken
mit dem Token und seiner Ablaufzeit zurückgeben.
function(AuthTokenFetcherOptions): Promise<AuthToken>
google.maps.journeySharing.AuthTokenFetcherOptions
Benutzeroberfläche
Optionen für den Authentifizierungstoken-Abruf.
Attribute |
context |
Der Auth-Token-Kontext. Die im Kontext angegebenen IDs müssen der Anfrage hinzugefügt werden, die an den JSON Web Token-Minting-Endpunkt gesendet wird. |
serviceType |
Der Diensttyp der Fahrzeugflotte. |
google.maps.journeySharing.FleetEngineServiceType
constants
Arten von Fleet Engine-Diensten
Rufe const {FleetEngineServiceType} = await google.maps.importLibrary("journeySharing")
auf, um auf die Daten zuzugreifen. Weitere Informationen finden Sie unter Bibliotheken in der Maps JavaScript API.
Konstanten |
DELIVERY_VEHICLE_SERVICE |
Fleet Engine-Dienst, der für den Zugriff auf Lieferfahrzeuge verwendet wird. |
TASK_SERVICE |
Fleet Engine-Dienst, der für den Zugriff auf Aufgabeninformationen verwendet wird. |
TRIP_SERVICE |
Fleet Engine-Dienst, der für den Zugriff auf Fahrtinformationen verwendet wird. |
UNKNOWN_SERVICE |
Unbekannter Fleet Engine-Dienst. |
Sofern nicht anders angegeben, sind die Inhalte dieser Seite unter der Creative Commons Attribution 4.0 License und Codebeispiele unter der Apache 2.0 License lizenziert. Weitere Informationen finden Sie in den Websiterichtlinien von Google Developers. Java ist eine eingetragene Marke von Oracle und/oder seinen Partnern.
Zuletzt aktualisiert: 2024-12-22 (UTC).
[null,null,["Zuletzt aktualisiert: 2024-12-22 (UTC)."],[],[],null,["# Authentication\n\nThe documentation for has moved to a different page.\n\nThe documentation for the linked item could not be found. \n\n[AuthToken](#AuthToken)\ninterface\n---------------------------------\n\n\ngoogle.maps.journeySharing`.`AuthToken\ninterface\n\nThe auth token returned by the token fetcher.\n\n| ### Properties ||\n|-------------------------------------------------|-----------------------------------------------------------------------------------------------------------|\n| [expiresInSeconds](#AuthToken.expiresInSeconds) | **Type:** `number` The expiration time in seconds. A token expires in this amount of time after fetching. |\n| [token](#AuthToken.token) | **Type:** `string` The token. |\n\n[AuthTokenContext](#AuthTokenContext)\ninterface\n-----------------------------------------------\n\n\ngoogle.maps.journeySharing`.`AuthTokenContext\ninterface\n\nContains additional information needed to mint JSON Web Tokens.\n\n| ### Properties ||\n|---------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------|\n| [deliveryVehicleId](#AuthTokenContext.deliveryVehicleId)` `optional | **Type:** `string `optional When provided, the minted token should have a private `DeliveryVehicleId` claim for the provided deliveryVehicleId. |\n| [taskId](#AuthTokenContext.taskId)` `optional | **Type:** `string `optional When provided, the minted token should have a private `TaskId` claim for the provided taskId. |\n| [trackingId](#AuthTokenContext.trackingId)` `optional | **Type:** `string `optional When provided, the minted token should have a private `TrackingId` claim for the provided trackingId. |\n| [tripId](#AuthTokenContext.tripId)` `optional | **Type:** `string `optional When provided, the minted token should have a private `TripId` claim for the provided tripId. |\n| [vehicleId](#AuthTokenContext.vehicleId)` `optional | **Type:** `string `optional When provided, the minted token should have a private `VehicleId` claim for the provided vehicleId. |\n\n[AuthTokenFetcher](#AuthTokenFetcher)\ntypedef\n---------------------------------------------\n\n\ngoogle.maps.journeySharing`.`AuthTokenFetcher\ntypedef\n\nAuth token function type. \n\nA function that accepts a [AuthTokenFetcherOptions](/maps/documentation/javascript/reference/journey-sharing-authentication#AuthTokenFetcherOptions) object, containing details about the auth token to be minted. This function should mint the token and return a [AuthToken](/maps/documentation/javascript/reference/journey-sharing-authentication#AuthToken) containing the token and its expiry time.\n\n`function(`[AuthTokenFetcherOptions](/maps/documentation/javascript/reference/journey-sharing-authentication#AuthTokenFetcherOptions)`): `[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)`\u003c`[AuthToken](/maps/documentation/javascript/reference/journey-sharing-authentication#AuthToken)`\u003e` \n\n[AuthTokenFetcherOptions](#AuthTokenFetcherOptions)\ninterface\n-------------------------------------------------------------\n\n\ngoogle.maps.journeySharing`.`AuthTokenFetcherOptions\ninterface\n\nOptions for the auth token fetcher.\n\n| ### Properties ||\n|-----------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [context](#AuthTokenFetcherOptions.context) | **Type:** [AuthTokenContext](/maps/documentation/javascript/reference/journey-sharing-authentication#AuthTokenContext) The auth token context. IDs specified in the context should be added to the request sent to the JSON Web Token minting endpoint. |\n| [serviceType](#AuthTokenFetcherOptions.serviceType) | **Type:** [FleetEngineServiceType](/maps/documentation/javascript/reference/journey-sharing-authentication#FleetEngineServiceType) The Fleet Engine service type. |\n\n[FleetEngineServiceType](#FleetEngineServiceType)\nconstants\n-----------------------------------------------------------\n\n\ngoogle.maps.journeySharing`.`FleetEngineServiceType\nconstants\n\nTypes of Fleet Engine services.\n\nAccess by calling `const {FleetEngineServiceType} = await google.maps.importLibrary(\"journeySharing\")`. \nSee [Libraries in the Maps JavaScript API](/maps/documentation/javascript/libraries).\n\n| ### Constants ||\n|------------------------------------------------------------------------------|--------------------------------------------------------|\n| [DELIVERY_VEHICLE_SERVICE](#FleetEngineServiceType.DELIVERY_VEHICLE_SERVICE) | Fleet Engine service used to access delivery vehicles. |\n| [TASK_SERVICE](#FleetEngineServiceType.TASK_SERVICE) | Fleet Engine service used to access task information. |\n| [TRIP_SERVICE](#FleetEngineServiceType.TRIP_SERVICE) | Fleet Engine service used to access trip information. |\n| [UNKNOWN_SERVICE](#FleetEngineServiceType.UNKNOWN_SERVICE) | Unknown Fleet Engine service. |"]]