Important : Nous n'acceptons plus de nouvelles inscriptions à l'API EMM Play.
En savoir plus
Devices: list
Restez organisé à l'aide des collections
Enregistrez et classez les contenus selon vos préférences.
Récupère les identifiants de tous les appareils d'un utilisateur.
Requête
Requête HTTP
GET https://www.googleapis.com/androidenterprise/v1/enterprises/enterpriseId/users/userId/devices
Paramètres
Nom du paramètre |
Valeur |
Description |
Paramètres de chemin d'accès |
enterpriseId |
string |
ID de l'entreprise.
|
userId |
string |
ID de l'utilisateur.
|
Autorisation
Cette requête nécessite une autorisation ayant le champ d'application suivant:
Champ d'application |
https://www.googleapis.com/auth/androidenterprise |
Pour en savoir plus, consultez la page Authentification et autorisation.
Corps de la requête
Ne spécifiez pas de corps de requête pour cette méthode.
Réponse
Si la requête aboutit, cette méthode renvoie un corps de réponse présentant la structure suivante :
{
"kind": "androidenterprise#devicesListResponse",
"device": [
devices Resource
]
}
Nom de propriété |
Valeur |
Description |
Remarques |
device[] |
list |
Un appareil géré |
|
kind |
string |
Identifie le type de ressource. Valeur: chaîne fixe "androidenterprise#devicesListResponse" . |
|
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2024/09/12 (UTC).
[null,null,["Dernière mise à jour le 2024/09/12 (UTC)."],[[["\u003cp\u003eRetrieves a list of device IDs associated with a specific user within a given enterprise.\u003c/p\u003e\n"],["\u003cp\u003eRequires authorization with the \u003ccode\u003ehttps://www.googleapis.com/auth/androidenterprise\u003c/code\u003e scope.\u003c/p\u003e\n"],["\u003cp\u003eThe request is made via a GET method to a specific endpoint, providing the enterprise and user IDs as path parameters.\u003c/p\u003e\n"],["\u003cp\u003eThe response includes an array of device resources, each representing a managed device linked to the user.\u003c/p\u003e\n"]]],[],null,["# Devices: list\n\n| **Note:** Requires [authorization](#auth).\n\nRetrieves the IDs of all of a user's devices.\n\nRequest\n-------\n\n### HTTP request\n\n```\nGET https://www.googleapis.com/androidenterprise/v1/enterprises/enterpriseId/users/userId/devices\n```\n\n### Parameters\n\n| Parameter name | Value | Description |\n|----------------|----------|---------------------------|\n| **Path parameters** |||\n| `enterpriseId` | `string` | The ID of the enterprise. |\n| `userId` | `string` | The ID of the user. |\n\n### Authorization\n\nThis request requires authorization with the following scope:\n\n| Scope |\n|-----------------------------------------------------|\n| `https://www.googleapis.com/auth/androidenterprise` |\n\nFor more information, see the [authentication and authorization](/android/work/play/emm-api/v1/how-tos/authorizing) page.\n\n### Request body\n\nDo not supply a request body with this method.\n\nResponse\n--------\n\nIf successful, this method returns a response body with the following structure:\n\n```objective-c\n{\n \"kind\": \"androidenterprise#devicesListResponse\",\n \"device\": [\n devices Resource\n ]\n}\n```\n\n| Property name | Value | Description | Notes |\n|---------------|----------|--------------------------------------------------------------------------------------------------------------|-------|\n| `device[]` | `list` | A managed device. | |\n| `kind` | `string` | Identifies what kind of resource this is. Value: the fixed string `\"androidenterprise#devicesListResponse\"`. | |"]]