Restez organisé à l'aide des collections
Enregistrez et classez les contenus selon vos préférences.
Le programme Device Access permet aux utilisateurs d'accéder aux appareils Google Nest, de les contrôler et de les gérer à l'aide de l'API SDM.
Pour commencer à utiliser Device Access, vous devez effectuer les tâches suivantes:
Inscrivez-vous au Device Access programme.
Activez un appareil Nest compatible avec un compte Google.
Créez un projet Google Cloud pour activer l'API SDM et obtenir un ID client OAuth 2.0.
Créez un projet Device Access pour recevoir un ID de projet.
S'inscrire pour accéder à l'appareil
Avant de créer votre premier projet, vous devez vous inscrire à Device Access.
L'inscription consiste à accepter les conditions d'utilisation de l'API Google et du bac à sable Device Access, ainsi qu'à payer des frais uniques et non remboursables (5 $) par compte.
Vous ne pourrez pas créer de projet tant que vous n'aurez pas accepté les conditions d'utilisation et payé les frais d'inscription. Cette règle s'applique à tous les utilisateurs, qu'ils soient des utilisateurs individuels ou des utilisateurs qui souhaitent créer une offre commerciale.
Si ce n'est pas déjà fait, enregistrez-vous dans la console Device Access :
Les appareils suivants sont compatibles avec le programme Device Access :
Tous les thermostats Google Nest
Toutes les caméras Google Nest
Toutes les sonnettes Google Nest
Google Nest Hub Max
Consultez la page Appareils compatibles pour obtenir la liste des modèles d'appareils individuels.
Pour savoir comment activer votre appareil compatible, consultez les manuels de l'appareil.
Configurer Google Cloud Platform
L'accès à l'API SDM est fourni via Google Cloud. Pour activer l'API et autoriser un compte Google avec un appareil Nest compatible, vous avez besoin d'un projet Google Cloud.
Utilisez le bouton Activer l'API et obtenir un ID client OAuth 2.0 ci-dessous pour activer l'API Smart Device Management et obtenir un ID client OAuth 2.0:
Si vous disposez d'un projet Google Cloud que vous souhaitez utiliser pour Device Access, assurez-vous d'abord d'être connecté au compte administrateur de ce projet. Cliquez ensuite sur le bouton, puis sélectionnez le projet existant dans la liste des projets disponibles. Sinon, créez un projet.
Sélectionnez Web Server (Serveur Web) lorsque l'assistant vous demande "Where are you calling from?" (D'où appelez-vous ?).
Saisissez https://www.google.com comme valeur pour URI de redirection autorisés. Un URI de redirection est nécessaire pour obtenir un code d'autorisation à l'aide de PCM.
Une fois la configuration terminée, copiez les valeurs de l'ID client et du secret client OAuth 2.0, puis téléchargez les identifiants JSON sur votre ordinateur local.
Obtenez un ID client OAuth 2.0 sur la page Identifiants.
Créer un projet Device Access
Revenez à la Device Access console.
Sur l'écran d'accueil de la console, sélectionnez add_circle_outline Créer un projet.
Remplissez chaque écran du processus de création :
Saisissez le nom de votre projet.
Saisissez l'ID client OAuth 2.0 généré lors de la configuration de Google Cloud Platform. Si vous n'avez pas copié votre ID client OAuth précédemment, vous pouvez le trouver dans le fichier credentials.json que vous avez téléchargé.
Activez ou désactivez les événements. Les événements sont gérés par Google Cloud Pub/Sub et fournissent des mises à jour asynchrones pour tous les appareils et structures autorisés pour votre projet. Si vous souhaitez utiliser des événements, sélectionnez Activer les événements, puis Créer un projet, puis modifiez le sujet Pub/Sub et fournissez un ID de sujet. En cas de doute, sélectionnez Désactiver.
Vous pourrez toujours les activer plus tard.
Une fois le projet terminé, un ID de projet lui est attribué sous la forme d'un UUID, par exemple 32c4c2bc-fe0d-461b-b51c-f3885afff2f0. Notez cet ID, car vous en aurez besoin pour tous les appels d'API SDM.
Cet ID de projet est utilisé dans les appels OAuth et d'API. Il est spécifique à votre projetDevice Access et n'est pas associé à un ID de projet Google Cloud.
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 2025/06/03 (UTC).
[[["Facile à comprendre","easyToUnderstand","thumb-up"],["J'ai pu résoudre mon problème","solvedMyProblem","thumb-up"],["Autre","otherUp","thumb-up"]],[["Il n'y a pas l'information dont j'ai besoin","missingTheInformationINeed","thumb-down"],["Trop compliqué/Trop d'étapes","tooComplicatedTooManySteps","thumb-down"],["Obsolète","outOfDate","thumb-down"],["Problème de traduction","translationIssue","thumb-down"],["Mauvais exemple/Erreur de code","samplesCodeIssue","thumb-down"],["Autre","otherDown","thumb-down"]],["Dernière mise à jour le 2025/06/03 (UTC)."],[[["\u003cp\u003eThe Device Access program enables users to access and manage Google Nest devices via the SDM API.\u003c/p\u003e\n"],["\u003cp\u003eTo utilize Device Access, users must register for the program, activate a supported Nest device with a Google account, and set up a Google Cloud project for API access.\u003c/p\u003e\n"],["\u003cp\u003eA Device Access project needs to be created, requiring a unique Project ID for all SDM API calls, and users must use a consumer Google Account for registration.\u003c/p\u003e\n"],["\u003cp\u003eSupported devices include all Google Nest Thermostats, Cameras, Doorbells, and Google Nest Hub Max.\u003c/p\u003e\n"]]],[],null,["The Device Access program allows users to access, control, and manage\nGoogle Nest devices using the SDM API.\n\nTo get started with Device Access, you need to complete the following tasks:\n\n1. Register for the Device Access program.\n2. Activate a supported Nest device with a Google account.\n3. Create a Google Cloud project to enable the SDM API and get an OAuth 2.0 client ID.\n4. Create a Device Access project to receive a Project ID.\n\nRegister for Device Access\n\nBefore creating your first project, you must register for Device Access.\nRegistration consists of the acceptance of the [Google API](/terms) and [Device\nAccess Sandbox](/nest/device-access/tos) Terms of Service, along with a one-time,\nnon-refundable fee (US$5) per account.\n\nYou will not be able to create a project until you have accepted both Terms of\nService and paid the registration fee. This applies to all users, both\nindividual users and those looking to create a commercial\noffering.\n\nRegister in the Device Access Console, if you haven't already:\n\n[Go to the Device Access Console](https://console.nest.google.com/device-access)\n| **Warning:** You must use a [consumer Google Account](https://support.google.com/work/android/answer/6371476) (for example, a gmail.com account) to register for Device Access. You cannot use a Google Workspace account. If you work for an organization, we suggest registering for Device Access using an account for your team.\n| **Warning:** Once a Google Account is associated with your Device Access Project **it cannot be changed**, be sure you are signed into the correct Google Account before continuing.\n\nSee [Device Access Registration](/nest/device-access/registration) for more\ninformation.\n\nActivate a supported device\n\nThe following devices are supported in the Device Access program:\n\n- All Google Nest Thermostats\n- All Google Nest Cameras\n- All Google Nest Doorbells\n- Google Nest Hub Max\n\nSee the [Supported Devices](/nest/device-access/supported-devices) page for a\nlisting of individual device models.\n| **Note:** A supported device must be activated with a Google account. Legacy Nest accounts are **not** supported for Device Access. See the [FAQs\n| about accounts for the Nest app](https://support.google.com/googlenest/answer/9297676) for more information on migrating a legacy Nest account.\n\nSee the device manuals for information on how to activate your supported device.\n\nSet up Google Cloud Platform\n\nAccess to the SDM API is provided through\nGoogle Cloud. To enable the API and authorize a Google account with\na supported Nest device, you'll need a Google Cloud\nproject.\n\nUse the **Enable the API and get an OAuth 2.0 Client ID** button below to enable\nthe **Smart Device Management API** and get an OAuth 2.0 Client ID:\n\n1. If you have an existing Google Cloud project that you would like to use for Device Access, make sure you are logged into the admin account for that project first. Then select the existing project from the list of available projects after clicking the button. Otherwise, create a new project.\n2. Select **Web Server** when it asks \"Where are you calling from?\".\n3. Enter *https://www.google.com* as the value for **Authorized redirect\n URIs**. A redirect URI is required to obtain an Authorization Code using PCM.\n4. Once setup is complete, **copy the OAuth 2.0 Client ID and Client Secret\n values, and download the Credentials JSON to your local machine**.\n\nEnable the API and get an OAuth 2.0 Client ID\n\nIf you want to manually set up your Google Cloud project, or verify\nthe setup and retrieve your credentials again:\n\n1. Enable **Smart Device Management API** on the [API Enablement](https://console.developers.google.com/apis/library/smartdevicemanagement.googleapis.com) page.\n2. Get an OAuth 2.0 Client ID on the [Credentials](https://console.developers.google.com/apis/credentials) page.\n\nCreate a Device Access project\n\nReturn to the Device Access Console.\n\n1. At the Console home screen, select **add_circle_outline Create\n project**.\n2. Fill out each screen in the creation process:\n 1. Enter a name for your project.\n 2. Enter the OAuth 2.0 Client ID generated during [Set up Google Cloud Platform](#set_up_google_cloud_platform). If you didn't copy your OAuth Client ID earlier, you can find it in the `credentials.json` file you downloaded. **Note:** To use a project with the SDM API:\n | - You must specify a valid OAuth Client ID for the project.\n | - An OAuth Client ID must be valid and unique to a project, and cannot be shared with other projects.\n 3. Enable or disable events. Events are managed by Google Cloud Pub/Sub and provide asynchronous updates for all devices and structures authorized for your project. If you want events, select **Enable events** , then **Create Project** , and then edit the Pub/Sub topic and provide a Topic ID. If you're not sure, select **Disable**. They can always be enabled later.\n3. Upon completion, your project is assigned a Project ID, in the form of a UUID, such as `32c4c2bc-fe0d-461b-b51c-f3885afff2f0`. Make note of this ID, you need it for all SDM API calls.\n\nThis Project ID is used in OAuth and API calls. It is specific to your\nDevice Access project, and is not related to a Google Cloud\nProject ID."]]