az iot pnp model
Create, view, and publish device models in your company repository.
Commands
az iot pnp model create |
Create a new device model in your company repository. |
az iot pnp model list |
List or search for models in the PnP model repository. |
az iot pnp model publish |
Publish a device model located in your company repository. |
az iot pnp model show |
View a device model by ID. |
az iot pnp model create
Create a new device model in your company repository.
az iot pnp model create --model
[--pnp-dns-suffix]
Examples
Create a new model by uploading a JSON file
az iot pnp model create --model ./path/to/definition/file.json
Required Parameters
IoT Plug and Play capability-model definition written in DTDL (JSON-LD). Can either be directly input or a file path where the content is extracted from.
Optional Parameters
An optional PnP DNS suffix used to interact with different PnP environments.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
az iot pnp model list
List or search for models in the PnP model repository.
az iot pnp model list [--keyword]
[--model-state {Created, Listed}]
[--model-type {Interface, Undetermined}]
[--pnp-dns-suffix]
[--pub]
[--shared {false, true}]
[--top]
Examples
List all models in the repository
az iot pnp model list
Search for all 'Listed' models published by a specific tenant
az iot pnp model list --state Listed --publisher-id {tenant_id}
Search for shared interfaces with name or description matching `{keyword}`
az iot pnp model list -q {keyword} --shared --type Interface
Optional Parameters
Restrict model list to those matching a provided keyword.
Restrict model list to models with a specific state.
Restrict model list to models with a specific type.
An optional PnP DNS suffix used to interact with different PnP environments.
Restrict model list to models published by a specific tenant.
Restrict model list to shared models only.
Maximum number of elements to return. Use -1 for unlimited.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
az iot pnp model publish
Publish a device model located in your company repository.
az iot pnp model publish --dtmi
[--pnp-dns-suffix]
[--yes {false, true}]
Examples
Publish a model with the ID {dtmi:my:model}
az iot pnp model publish --model-id {dtmi:my:model}
Required Parameters
Digital Twins model Id. Example: dtmi:com:example:Room;2.
Optional Parameters
An optional PnP DNS suffix used to interact with different PnP environments.
Skip user prompts. Indicates acceptance of dependency installation (if required). Used primarily for automation scenarios. Default: false.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
az iot pnp model show
View a device model by ID.
az iot pnp model show --dtmi
[--def {false, true}]
[--pnp-dns-suffix]
Examples
View a model with the ID "dtmi:com:example:ClimateSensor;1"
az iot pnp model show --dtmi "dtmi:com:example:ClimateSensor;1"
Required Parameters
Digital Twins model Id. Example: dtmi:com:example:Room;2.
Optional Parameters
Expand the model’s referenced definitions inline.
An optional PnP DNS suffix used to interact with different PnP environments.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.