> For the complete documentation index, see [llms.txt](https://docs.spadnext.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.spadnext.com/extending-and-apis/serial-connection/device-communication-flow/device-config-phase/device-profile-configuration.md).

# Device PROFILE configuration

Defines a device profile that shall be offered/loaded as default for the device, if no device profile exists in the current SPAD.neXt profile (Device not configured dialog)

Syntax: 0,PROFILE,\<SourceType>,\<id>

#### SOURCETYPE

|   |                                                                                                                                                                                             |
| - | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 0 | \<ID> will contain snippet-id(s) of a complete device snippet to load from SPAD.neXt online database                                                                                        |
| 1 | \<ID> will contain one snippet-id of a device snippet to load from SPAD.neXt online database, but the user will not be asked for confirmation.                                              |
| 2 | \<ID> will contain one snippet-id of a device snippet to load from SPAD.neXt online database. Any existing device profile in currently loaded SPAD.neXt profile will be **overwritten**.    |
| 3 | \<ID> will contain an url that will be downloaded. The url must return a valid SPAD.neXt device profile. If the url is not reachable or invalid, no default profile will be loaded/offered. |

To provide more than one snippet-id for the user to choose from, separate the id's by `#`\
`e.g. 123#456#12345`

{% hint style="info" %}
This command is only valid during the configuration phase of the device or from within the device configuration xml
{% endhint %}

Examples

`0,PROFILE,0,4567`

`0,PROFILE,3,http:////pastbin.com//a4JhSw`

{% hint style="danger" %}
`Note the escaped '/' in the URL!`
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.spadnext.com/extending-and-apis/serial-connection/device-communication-flow/device-config-phase/device-profile-configuration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
