Menu
AWS Greengrass
API Reference

CreateDeviceDefinition

Creates a device definition. You may optinally provide the initial version of the device definition or use CreateDeviceDefinitionVersion at a later time.

URI: /greengrass/definition/devices

Operation: POST

Produces: application/json

Parameters:

  • CreateDeviceDefinitionRequestBody

    device definition request

    where used: body

    required: true

    schema:

    properties:

    • Name:

      the name of the device definition.

      type: string

    • InitialVersion:

      Information about the initial version of the device definition.

      DeviceDefinitionVersion

      type: object

      Information about a device definition version.

      properties:

      • Devices

        A list of devices in the definition version.

        type: array

        items:

        Information about the Greengrass device.

        Device

        type: object

        Information about a device.

        required: Id|ThingArn|CertificateArn

        properties:

        • Id:

          The id of the device.

          type: string

        • ThingArn:

          The thing arn of the device.

          type: string

        • CertificateArn:

          The arn of the certificate associated with the device.

          type: string

        • SyncShadow:

          If true, the device's local shadow is automatically synced with the cloud.

          type: boolean

    Example:

    Copy
    { "Name": "string", "InitialVersion": { "Devices": [ { "Id": "string", "ThingArn": "string", "CertificateArn": "string", "SyncShadow": true } ] } }
  • X-Amzn-Client-Token

    A client token used to correlate requests and responses.

    where used: header

    required: false

    type: string

Responses: