[null,null,["อัปเดตล่าสุด 2025-07-26 UTC"],[[["\u003cp\u003eThis guide explains how to register a device model with Google Assistant, providing necessary device information for Assistant's responses.\u003c/p\u003e\n"],["\u003cp\u003eDevice registration involves providing device details, downloading credentials for authorization, and (optionally) specifying device traits.\u003c/p\u003e\n"],["\u003cp\u003eYou can register a device model through the Actions Console UI, registration tool, or REST API, with the UI requiring prior 'Device registration' selection during project creation.\u003c/p\u003e\n"],["\u003cp\u003eFor Raspberry Pi, the downloaded credentials file (\u003ccode\u003eclient_secret_<client-id>.json\u003c/code\u003e) needs to be placed in the \u003ccode\u003e/home/pi\u003c/code\u003e directory using \u003ccode\u003escp\u003c/code\u003e command from a separate terminal, not within an SSH session.\u003c/p\u003e\n"],["\u003cp\u003eAfter registration, you can edit the model and download credentials again if needed; device model access is restricted to the associated Actions Console project.\u003c/p\u003e\n"]]],["Register a device model via the Actions Console's registration UI by filling out device details like type and manufacturer. This information is accessible to the Assistant, tied to your project. Download the `client_secret_\u003cclient-id\u003e.json` file containing your credentials and transfer it to your device, ensuring it's in `/home/pi` on a Raspberry Pi. You can skip specifying device traits for now, but edits and file re-downloads are available via the model list. Alternative methods for registration are the registration tool and REST API.\n"],null,["# Register the Device Model\n\n| **Warning:** The Google Assistant Library for Python is deprecated as of June 28th, 2019. Use the [Google Assistant Service](/assistant/sdk/guides/service/python) instead.\n\n\u003cbr /\u003e\n\nIn order for the Google Assistant to respond to commands appropriate to your\ndevice and the given context, the Assistant needs information about your\nparticular device. You provide this information, which includes fields like\ndevice type and manufacturer, as a device model. You can think of this model as\na general class of device -- such as a light, speaker, or toy robot.\n\nThis information is then accessible to the Assistant and is\nassociated with your\n\nActions Console project.\n\nNo other projects have access to your model and device information.\n\nUse the registration UI\n-----------------------\n\nUse the registration UI in the [Actions Console](https://console.actions.google.com/)\nto register a device model.\n| **Note:** The registration UI will not appear if you did not click the **Device\n| registration** box when creating the project (see the previous step).\n\nClick the **REGISTER MODEL** button.\n\n### Create model\n\n1. Fill out all of the fields for your device. Select any device type, such as\n **Light**.\n\n See the device model JSON\n\n [reference](/assistant/sdk/reference/device-registration/model-and-instance-schemas#device_model_json)\n\n for more information on these fields.\n2. When you are finished, click **REGISTER MODEL**.\n\n### Download credentials\n\nThe `client_secret_\u003cclient-id\u003e.json` file must be located on the device. This file contains\na client ID and client secret, but no access token. Later, you will run an\nauthorization tool and reference this file in order to authorize the Google\nAssistant SDK sample to make Google Assistant queries (see the [OAuth 2.0](/identity/protocols/OAuth2)\ndocumentation for more information). Do not rename this file.\n\nDownload this file and transfer it to the device. Click **NEXT**.\n\n#### For the Raspberry Pi only\n\nMake sure this file is located in `/home/pi`. If you want to upload the file\nto the device, do the following:\n\n1. Open a new terminal window. Run the following command in this new terminal:\n\n **Note:** Do **not** run the following command in an SSH session connected to the device. This command transfers the JSON file from a directory on your development machine to the device. An SSH session cannot access your local directories. \n\n ```\n scp ~/Downloads/client_secret_client-id.json pi@raspberry-pi-ip-address:/home/pi/\n ``` \n\n ```\n password: password-for-device\n ```\n2. Close this terminal window.\n\n### Specify traits\n\nLater, you will specify the different abilities that your device supports on\nthis screen. But for now, click the **SKIP** button.\n\n### Edit the model\n\nIf you need to edit the model, click its row in the list. Make sure to click **SAVE**\nafter any edits.\n\nIf you need to download the credentials file again, click the ellipses. You can\ndelete the model from this menu as well.\n\nAlternative ways to register\n----------------------------\n\nYou can also use the [registration tool](/assistant/sdk/reference/device-registration/device-tool)\n(included with the Google Assistant SDK samples) or the [REST API](/assistant/sdk/reference/device-registration/register-device-manual)\nto register a device model.\n\nYou must be an Owner or Editor of a given Actions Console project to register\nmodels for it. Add these roles for other users in the Cloud Platform Console---see the\n[IAM documentation](https://cloud.google.com/iam/docs/granting-changing-revoking-access).\n\nNext step\n---------\n\n[Install the SDK and Sample Code](/assistant/sdk/guides/library/python/embed/install-sample)"]]